diff --git a/.openapi-generator/FILES b/.openapi-generator/FILES
index be924b7..e0ace29 100644
--- a/.openapi-generator/FILES
+++ b/.openapi-generator/FILES
@@ -62,10 +62,14 @@ conekta/models/checkout_order_template_customer_info.py
conekta/models/checkout_request.py
conekta/models/checkout_response.py
conekta/models/checkouts_response.py
-conekta/models/company_fiscal_info_address_response.py
-conekta/models/company_fiscal_info_response.py
-conekta/models/company_payout_destination_response.py
+conekta/models/company_document_request.py
+conekta/models/company_document_response.py
conekta/models/company_response.py
+conekta/models/company_response_documents_inner.py
+conekta/models/create_company_request.py
+conekta/models/create_company_request_bank_account_info.py
+conekta/models/create_company_request_comercial_info.py
+conekta/models/create_company_request_fiscal_info.py
conekta/models/create_customer_fiscal_entities_response.py
conekta/models/create_customer_payment_methods_request.py
conekta/models/create_customer_payment_methods_response.py
@@ -251,10 +255,14 @@ docs/CheckoutRequest.md
docs/CheckoutResponse.md
docs/CheckoutsResponse.md
docs/CompaniesApi.md
-docs/CompanyFiscalInfoAddressResponse.md
-docs/CompanyFiscalInfoResponse.md
-docs/CompanyPayoutDestinationResponse.md
+docs/CompanyDocumentRequest.md
+docs/CompanyDocumentResponse.md
docs/CompanyResponse.md
+docs/CompanyResponseDocumentsInner.md
+docs/CreateCompanyRequest.md
+docs/CreateCompanyRequestBankAccountInfo.md
+docs/CreateCompanyRequestComercialInfo.md
+docs/CreateCompanyRequestFiscalInfo.md
docs/CreateCustomerFiscalEntitiesResponse.md
docs/CreateCustomerPaymentMethodsRequest.md
docs/CreateCustomerPaymentMethodsResponse.md
diff --git a/README.md b/README.md
index 62a11aa..4b9357d 100644
--- a/README.md
+++ b/README.md
@@ -4,7 +4,7 @@ Conekta sdk
This Python package is automatically generated by the [OpenAPI Generator](https://openapi-generator.tech) project:
- API version: 2.2.0
-- Package version: 7.0.1
+- Package version: 7.0.2
- Generator version: 7.9.0
- Build package: org.openapitools.codegen.languages.PythonClientCodegen
For more information, please visit [https://github.com/conekta/openapi/issues](https://github.com/conekta/openapi/issues)
@@ -111,8 +111,12 @@ Class | Method | HTTP request | Description
*ChargesApi* | [**orders_create_charge**](docs/ChargesApi.md#orders_create_charge) | **POST** /orders/{id}/charges | Create charge
*ChargesApi* | [**orders_create_charges**](docs/ChargesApi.md#orders_create_charges) | **POST** /orders/{id}/add_charges | Create charges
*ChargesApi* | [**update_charge**](docs/ChargesApi.md#update_charge) | **PUT** /charges/{id} | Update a charge
+*CompaniesApi* | [**create_company**](docs/CompaniesApi.md#create_company) | **POST** /companies | Create Company
*CompaniesApi* | [**get_companies**](docs/CompaniesApi.md#get_companies) | **GET** /companies | Get List of Companies
*CompaniesApi* | [**get_company**](docs/CompaniesApi.md#get_company) | **GET** /companies/{id} | Get Company
+*CompaniesApi* | [**get_company_documents**](docs/CompaniesApi.md#get_company_documents) | **GET** /companies/{company_id}/documents | Get Company Documents
+*CompaniesApi* | [**update_company_document**](docs/CompaniesApi.md#update_company_document) | **PATCH** /companies/{company_id}/document | Update Company Document
+*CompaniesApi* | [**upload_company_document**](docs/CompaniesApi.md#upload_company_document) | **POST** /companies/{company_id}/document | Upload Company Document
*CustomersApi* | [**create_customer**](docs/CustomersApi.md#create_customer) | **POST** /customers | Create customer
*CustomersApi* | [**create_customer_fiscal_entities**](docs/CustomersApi.md#create_customer_fiscal_entities) | **POST** /customers/{id}/fiscal_entities | Create Fiscal Entity
*CustomersApi* | [**delete_customer_by_id**](docs/CustomersApi.md#delete_customer_by_id) | **DELETE** /customers/{id} | Delete Customer
@@ -232,10 +236,14 @@ Class | Method | HTTP request | Description
- [CheckoutRequest](docs/CheckoutRequest.md)
- [CheckoutResponse](docs/CheckoutResponse.md)
- [CheckoutsResponse](docs/CheckoutsResponse.md)
- - [CompanyFiscalInfoAddressResponse](docs/CompanyFiscalInfoAddressResponse.md)
- - [CompanyFiscalInfoResponse](docs/CompanyFiscalInfoResponse.md)
- - [CompanyPayoutDestinationResponse](docs/CompanyPayoutDestinationResponse.md)
+ - [CompanyDocumentRequest](docs/CompanyDocumentRequest.md)
+ - [CompanyDocumentResponse](docs/CompanyDocumentResponse.md)
- [CompanyResponse](docs/CompanyResponse.md)
+ - [CompanyResponseDocumentsInner](docs/CompanyResponseDocumentsInner.md)
+ - [CreateCompanyRequest](docs/CreateCompanyRequest.md)
+ - [CreateCompanyRequestBankAccountInfo](docs/CreateCompanyRequestBankAccountInfo.md)
+ - [CreateCompanyRequestComercialInfo](docs/CreateCompanyRequestComercialInfo.md)
+ - [CreateCompanyRequestFiscalInfo](docs/CreateCompanyRequestFiscalInfo.md)
- [CreateCustomerFiscalEntitiesResponse](docs/CreateCustomerFiscalEntitiesResponse.md)
- [CreateCustomerPaymentMethodsRequest](docs/CreateCustomerPaymentMethodsRequest.md)
- [CreateCustomerPaymentMethodsResponse](docs/CreateCustomerPaymentMethodsResponse.md)
diff --git a/VERSION b/VERSION
index 9fe9ff9..a8907c0 100644
--- a/VERSION
+++ b/VERSION
@@ -1 +1 @@
-7.0.1
+7.0.2
diff --git a/conekta/__init__.py b/conekta/__init__.py
index f4f13b3..d877cae 100644
--- a/conekta/__init__.py
+++ b/conekta/__init__.py
@@ -15,7 +15,7 @@
""" # noqa: E501
-__version__ = "7.0.1"
+__version__ = "7.0.2"
# import apis into sdk package
from conekta.api.antifraud_api import AntifraudApi
@@ -82,10 +82,14 @@
from conekta.models.checkout_request import CheckoutRequest
from conekta.models.checkout_response import CheckoutResponse
from conekta.models.checkouts_response import CheckoutsResponse
-from conekta.models.company_fiscal_info_address_response import CompanyFiscalInfoAddressResponse
-from conekta.models.company_fiscal_info_response import CompanyFiscalInfoResponse
-from conekta.models.company_payout_destination_response import CompanyPayoutDestinationResponse
+from conekta.models.company_document_request import CompanyDocumentRequest
+from conekta.models.company_document_response import CompanyDocumentResponse
from conekta.models.company_response import CompanyResponse
+from conekta.models.company_response_documents_inner import CompanyResponseDocumentsInner
+from conekta.models.create_company_request import CreateCompanyRequest
+from conekta.models.create_company_request_bank_account_info import CreateCompanyRequestBankAccountInfo
+from conekta.models.create_company_request_comercial_info import CreateCompanyRequestComercialInfo
+from conekta.models.create_company_request_fiscal_info import CreateCompanyRequestFiscalInfo
from conekta.models.create_customer_fiscal_entities_response import CreateCustomerFiscalEntitiesResponse
from conekta.models.create_customer_payment_methods_request import CreateCustomerPaymentMethodsRequest
from conekta.models.create_customer_payment_methods_response import CreateCustomerPaymentMethodsResponse
diff --git a/conekta/api/companies_api.py b/conekta/api/companies_api.py
index a75498f..0486db9 100644
--- a/conekta/api/companies_api.py
+++ b/conekta/api/companies_api.py
@@ -18,9 +18,12 @@
from typing_extensions import Annotated
from pydantic import Field, StrictStr, field_validator
-from typing import Optional
+from typing import List, Optional
from typing_extensions import Annotated
+from conekta.models.company_document_request import CompanyDocumentRequest
+from conekta.models.company_document_response import CompanyDocumentResponse
from conekta.models.company_response import CompanyResponse
+from conekta.models.create_company_request import CreateCompanyRequest
from conekta.models.get_companies_response import GetCompaniesResponse
from conekta.api_client import ApiClient, RequestSerialized
@@ -41,6 +44,286 @@ def __init__(self, api_client=None) -> None:
self.api_client = api_client
+ @validate_call
+ def create_company(
+ self,
+ create_company_request: Annotated[CreateCompanyRequest, Field(description="Company data")],
+ _request_timeout: Union[
+ None,
+ Annotated[StrictFloat, Field(gt=0)],
+ Tuple[
+ Annotated[StrictFloat, Field(gt=0)],
+ Annotated[StrictFloat, Field(gt=0)]
+ ]
+ ] = None,
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _content_type: Optional[StrictStr] = None,
+ _headers: Optional[Dict[StrictStr, Any]] = None,
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
+ ) -> CompanyResponse:
+ """Create Company
+
+ Create a new company.
+
+ :param create_company_request: Company data (required)
+ :type create_company_request: CreateCompanyRequest
+ :param _request_timeout: timeout setting for this request. If one
+ number provided, it will be total request
+ timeout. It can also be a pair (tuple) of
+ (connection, read) timeouts.
+ :type _request_timeout: int, tuple(int, int), optional
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the
+ authentication in the spec for a single request.
+ :type _request_auth: dict, optional
+ :param _content_type: force content-type for the request.
+ :type _content_type: str, Optional
+ :param _headers: set to override the headers for a single
+ request; this effectively ignores the headers
+ in the spec for a single request.
+ :type _headers: dict, optional
+ :param _host_index: set to override the host_index for a single
+ request; this effectively ignores the host_index
+ in the spec for a single request.
+ :type _host_index: int, optional
+ :return: Returns the result object.
+ """ # noqa: E501
+
+ _param = self._create_company_serialize(
+ create_company_request=create_company_request,
+ _request_auth=_request_auth,
+ _content_type=_content_type,
+ _headers=_headers,
+ _host_index=_host_index
+ )
+
+ _response_types_map: Dict[str, Optional[str]] = {
+ '201': "CompanyResponse",
+ '401': "Error",
+ '500': "Error",
+ }
+ response_data = self.api_client.call_api(
+ *_param,
+ _request_timeout=_request_timeout
+ )
+ response_data.read()
+ return self.api_client.response_deserialize(
+ response_data=response_data,
+ response_types_map=_response_types_map,
+ ).data
+
+
+ @validate_call
+ def create_company_with_http_info(
+ self,
+ create_company_request: Annotated[CreateCompanyRequest, Field(description="Company data")],
+ _request_timeout: Union[
+ None,
+ Annotated[StrictFloat, Field(gt=0)],
+ Tuple[
+ Annotated[StrictFloat, Field(gt=0)],
+ Annotated[StrictFloat, Field(gt=0)]
+ ]
+ ] = None,
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _content_type: Optional[StrictStr] = None,
+ _headers: Optional[Dict[StrictStr, Any]] = None,
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
+ ) -> ApiResponse[CompanyResponse]:
+ """Create Company
+
+ Create a new company.
+
+ :param create_company_request: Company data (required)
+ :type create_company_request: CreateCompanyRequest
+ :param _request_timeout: timeout setting for this request. If one
+ number provided, it will be total request
+ timeout. It can also be a pair (tuple) of
+ (connection, read) timeouts.
+ :type _request_timeout: int, tuple(int, int), optional
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the
+ authentication in the spec for a single request.
+ :type _request_auth: dict, optional
+ :param _content_type: force content-type for the request.
+ :type _content_type: str, Optional
+ :param _headers: set to override the headers for a single
+ request; this effectively ignores the headers
+ in the spec for a single request.
+ :type _headers: dict, optional
+ :param _host_index: set to override the host_index for a single
+ request; this effectively ignores the host_index
+ in the spec for a single request.
+ :type _host_index: int, optional
+ :return: Returns the result object.
+ """ # noqa: E501
+
+ _param = self._create_company_serialize(
+ create_company_request=create_company_request,
+ _request_auth=_request_auth,
+ _content_type=_content_type,
+ _headers=_headers,
+ _host_index=_host_index
+ )
+
+ _response_types_map: Dict[str, Optional[str]] = {
+ '201': "CompanyResponse",
+ '401': "Error",
+ '500': "Error",
+ }
+ response_data = self.api_client.call_api(
+ *_param,
+ _request_timeout=_request_timeout
+ )
+ response_data.read()
+ return self.api_client.response_deserialize(
+ response_data=response_data,
+ response_types_map=_response_types_map,
+ )
+
+
+ @validate_call
+ def create_company_without_preload_content(
+ self,
+ create_company_request: Annotated[CreateCompanyRequest, Field(description="Company data")],
+ _request_timeout: Union[
+ None,
+ Annotated[StrictFloat, Field(gt=0)],
+ Tuple[
+ Annotated[StrictFloat, Field(gt=0)],
+ Annotated[StrictFloat, Field(gt=0)]
+ ]
+ ] = None,
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _content_type: Optional[StrictStr] = None,
+ _headers: Optional[Dict[StrictStr, Any]] = None,
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
+ ) -> RESTResponseType:
+ """Create Company
+
+ Create a new company.
+
+ :param create_company_request: Company data (required)
+ :type create_company_request: CreateCompanyRequest
+ :param _request_timeout: timeout setting for this request. If one
+ number provided, it will be total request
+ timeout. It can also be a pair (tuple) of
+ (connection, read) timeouts.
+ :type _request_timeout: int, tuple(int, int), optional
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the
+ authentication in the spec for a single request.
+ :type _request_auth: dict, optional
+ :param _content_type: force content-type for the request.
+ :type _content_type: str, Optional
+ :param _headers: set to override the headers for a single
+ request; this effectively ignores the headers
+ in the spec for a single request.
+ :type _headers: dict, optional
+ :param _host_index: set to override the host_index for a single
+ request; this effectively ignores the host_index
+ in the spec for a single request.
+ :type _host_index: int, optional
+ :return: Returns the result object.
+ """ # noqa: E501
+
+ _param = self._create_company_serialize(
+ create_company_request=create_company_request,
+ _request_auth=_request_auth,
+ _content_type=_content_type,
+ _headers=_headers,
+ _host_index=_host_index
+ )
+
+ _response_types_map: Dict[str, Optional[str]] = {
+ '201': "CompanyResponse",
+ '401': "Error",
+ '500': "Error",
+ }
+ response_data = self.api_client.call_api(
+ *_param,
+ _request_timeout=_request_timeout
+ )
+ return response_data.response
+
+
+ def _create_company_serialize(
+ self,
+ create_company_request,
+ _request_auth,
+ _content_type,
+ _headers,
+ _host_index,
+ ) -> RequestSerialized:
+
+ _host = None
+
+ _collection_formats: Dict[str, str] = {
+ }
+
+ _path_params: Dict[str, str] = {}
+ _query_params: List[Tuple[str, str]] = []
+ _header_params: Dict[str, Optional[str]] = _headers or {}
+ _form_params: List[Tuple[str, str]] = []
+ _files: Dict[
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ ] = {}
+ _body_params: Optional[bytes] = None
+
+ # process the path parameters
+ # process the query parameters
+ # process the header parameters
+ # process the form parameters
+ # process the body parameter
+ if create_company_request is not None:
+ _body_params = create_company_request
+
+
+ # set the HTTP header `Accept`
+ if 'Accept' not in _header_params:
+ _header_params['Accept'] = self.api_client.select_header_accept(
+ [
+ 'application/vnd.conekta-v2.2.0+json'
+ ]
+ )
+
+ # set the HTTP header `Content-Type`
+ if _content_type:
+ _header_params['Content-Type'] = _content_type
+ else:
+ _default_content_type = (
+ self.api_client.select_header_content_type(
+ [
+ 'application/json'
+ ]
+ )
+ )
+ if _default_content_type is not None:
+ _header_params['Content-Type'] = _default_content_type
+
+ # authentication setting
+ _auth_settings: List[str] = [
+ 'bearerAuth'
+ ]
+
+ return self.api_client.param_serialize(
+ method='POST',
+ resource_path='/companies',
+ path_params=_path_params,
+ query_params=_query_params,
+ header_params=_header_params,
+ body=_body_params,
+ post_params=_form_params,
+ files=_files,
+ auth_settings=_auth_settings,
+ collection_formats=_collection_formats,
+ _host=_host,
+ _request_auth=_request_auth
+ )
+
+
+
+
@validate_call
def get_companies(
self,
@@ -656,3 +939,914 @@ def _get_company_serialize(
)
+
+
+ @validate_call
+ def get_company_documents(
+ self,
+ company_id: Annotated[StrictStr, Field(description="The unique identifier of the company.")],
+ accept_language: Annotated[Optional[StrictStr], Field(description="Use for knowing which language to use")] = None,
+ _request_timeout: Union[
+ None,
+ Annotated[StrictFloat, Field(gt=0)],
+ Tuple[
+ Annotated[StrictFloat, Field(gt=0)],
+ Annotated[StrictFloat, Field(gt=0)]
+ ]
+ ] = None,
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _content_type: Optional[StrictStr] = None,
+ _headers: Optional[Dict[StrictStr, Any]] = None,
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
+ ) -> List[CompanyDocumentResponse]:
+ """Get Company Documents
+
+ Retrieve a list of documents associated with a specific company.
+
+ :param company_id: The unique identifier of the company. (required)
+ :type company_id: str
+ :param accept_language: Use for knowing which language to use
+ :type accept_language: str
+ :param _request_timeout: timeout setting for this request. If one
+ number provided, it will be total request
+ timeout. It can also be a pair (tuple) of
+ (connection, read) timeouts.
+ :type _request_timeout: int, tuple(int, int), optional
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the
+ authentication in the spec for a single request.
+ :type _request_auth: dict, optional
+ :param _content_type: force content-type for the request.
+ :type _content_type: str, Optional
+ :param _headers: set to override the headers for a single
+ request; this effectively ignores the headers
+ in the spec for a single request.
+ :type _headers: dict, optional
+ :param _host_index: set to override the host_index for a single
+ request; this effectively ignores the host_index
+ in the spec for a single request.
+ :type _host_index: int, optional
+ :return: Returns the result object.
+ """ # noqa: E501
+
+ _param = self._get_company_documents_serialize(
+ company_id=company_id,
+ accept_language=accept_language,
+ _request_auth=_request_auth,
+ _content_type=_content_type,
+ _headers=_headers,
+ _host_index=_host_index
+ )
+
+ _response_types_map: Dict[str, Optional[str]] = {
+ '200': "List[CompanyDocumentResponse]",
+ '401': "Error",
+ '404': "Error",
+ '500': "Error",
+ }
+ response_data = self.api_client.call_api(
+ *_param,
+ _request_timeout=_request_timeout
+ )
+ response_data.read()
+ return self.api_client.response_deserialize(
+ response_data=response_data,
+ response_types_map=_response_types_map,
+ ).data
+
+
+ @validate_call
+ def get_company_documents_with_http_info(
+ self,
+ company_id: Annotated[StrictStr, Field(description="The unique identifier of the company.")],
+ accept_language: Annotated[Optional[StrictStr], Field(description="Use for knowing which language to use")] = None,
+ _request_timeout: Union[
+ None,
+ Annotated[StrictFloat, Field(gt=0)],
+ Tuple[
+ Annotated[StrictFloat, Field(gt=0)],
+ Annotated[StrictFloat, Field(gt=0)]
+ ]
+ ] = None,
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _content_type: Optional[StrictStr] = None,
+ _headers: Optional[Dict[StrictStr, Any]] = None,
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
+ ) -> ApiResponse[List[CompanyDocumentResponse]]:
+ """Get Company Documents
+
+ Retrieve a list of documents associated with a specific company.
+
+ :param company_id: The unique identifier of the company. (required)
+ :type company_id: str
+ :param accept_language: Use for knowing which language to use
+ :type accept_language: str
+ :param _request_timeout: timeout setting for this request. If one
+ number provided, it will be total request
+ timeout. It can also be a pair (tuple) of
+ (connection, read) timeouts.
+ :type _request_timeout: int, tuple(int, int), optional
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the
+ authentication in the spec for a single request.
+ :type _request_auth: dict, optional
+ :param _content_type: force content-type for the request.
+ :type _content_type: str, Optional
+ :param _headers: set to override the headers for a single
+ request; this effectively ignores the headers
+ in the spec for a single request.
+ :type _headers: dict, optional
+ :param _host_index: set to override the host_index for a single
+ request; this effectively ignores the host_index
+ in the spec for a single request.
+ :type _host_index: int, optional
+ :return: Returns the result object.
+ """ # noqa: E501
+
+ _param = self._get_company_documents_serialize(
+ company_id=company_id,
+ accept_language=accept_language,
+ _request_auth=_request_auth,
+ _content_type=_content_type,
+ _headers=_headers,
+ _host_index=_host_index
+ )
+
+ _response_types_map: Dict[str, Optional[str]] = {
+ '200': "List[CompanyDocumentResponse]",
+ '401': "Error",
+ '404': "Error",
+ '500': "Error",
+ }
+ response_data = self.api_client.call_api(
+ *_param,
+ _request_timeout=_request_timeout
+ )
+ response_data.read()
+ return self.api_client.response_deserialize(
+ response_data=response_data,
+ response_types_map=_response_types_map,
+ )
+
+
+ @validate_call
+ def get_company_documents_without_preload_content(
+ self,
+ company_id: Annotated[StrictStr, Field(description="The unique identifier of the company.")],
+ accept_language: Annotated[Optional[StrictStr], Field(description="Use for knowing which language to use")] = None,
+ _request_timeout: Union[
+ None,
+ Annotated[StrictFloat, Field(gt=0)],
+ Tuple[
+ Annotated[StrictFloat, Field(gt=0)],
+ Annotated[StrictFloat, Field(gt=0)]
+ ]
+ ] = None,
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _content_type: Optional[StrictStr] = None,
+ _headers: Optional[Dict[StrictStr, Any]] = None,
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
+ ) -> RESTResponseType:
+ """Get Company Documents
+
+ Retrieve a list of documents associated with a specific company.
+
+ :param company_id: The unique identifier of the company. (required)
+ :type company_id: str
+ :param accept_language: Use for knowing which language to use
+ :type accept_language: str
+ :param _request_timeout: timeout setting for this request. If one
+ number provided, it will be total request
+ timeout. It can also be a pair (tuple) of
+ (connection, read) timeouts.
+ :type _request_timeout: int, tuple(int, int), optional
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the
+ authentication in the spec for a single request.
+ :type _request_auth: dict, optional
+ :param _content_type: force content-type for the request.
+ :type _content_type: str, Optional
+ :param _headers: set to override the headers for a single
+ request; this effectively ignores the headers
+ in the spec for a single request.
+ :type _headers: dict, optional
+ :param _host_index: set to override the host_index for a single
+ request; this effectively ignores the host_index
+ in the spec for a single request.
+ :type _host_index: int, optional
+ :return: Returns the result object.
+ """ # noqa: E501
+
+ _param = self._get_company_documents_serialize(
+ company_id=company_id,
+ accept_language=accept_language,
+ _request_auth=_request_auth,
+ _content_type=_content_type,
+ _headers=_headers,
+ _host_index=_host_index
+ )
+
+ _response_types_map: Dict[str, Optional[str]] = {
+ '200': "List[CompanyDocumentResponse]",
+ '401': "Error",
+ '404': "Error",
+ '500': "Error",
+ }
+ response_data = self.api_client.call_api(
+ *_param,
+ _request_timeout=_request_timeout
+ )
+ return response_data.response
+
+
+ def _get_company_documents_serialize(
+ self,
+ company_id,
+ accept_language,
+ _request_auth,
+ _content_type,
+ _headers,
+ _host_index,
+ ) -> RequestSerialized:
+
+ _host = None
+
+ _collection_formats: Dict[str, str] = {
+ }
+
+ _path_params: Dict[str, str] = {}
+ _query_params: List[Tuple[str, str]] = []
+ _header_params: Dict[str, Optional[str]] = _headers or {}
+ _form_params: List[Tuple[str, str]] = []
+ _files: Dict[
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ ] = {}
+ _body_params: Optional[bytes] = None
+
+ # process the path parameters
+ if company_id is not None:
+ _path_params['company_id'] = company_id
+ # process the query parameters
+ # process the header parameters
+ if accept_language is not None:
+ _header_params['Accept-Language'] = accept_language
+ # process the form parameters
+ # process the body parameter
+
+
+ # set the HTTP header `Accept`
+ if 'Accept' not in _header_params:
+ _header_params['Accept'] = self.api_client.select_header_accept(
+ [
+ 'application/vnd.conekta-v2.2.0+json'
+ ]
+ )
+
+
+ # authentication setting
+ _auth_settings: List[str] = [
+ 'bearerAuth'
+ ]
+
+ return self.api_client.param_serialize(
+ method='GET',
+ resource_path='/companies/{company_id}/documents',
+ path_params=_path_params,
+ query_params=_query_params,
+ header_params=_header_params,
+ body=_body_params,
+ post_params=_form_params,
+ files=_files,
+ auth_settings=_auth_settings,
+ collection_formats=_collection_formats,
+ _host=_host,
+ _request_auth=_request_auth
+ )
+
+
+
+
+ @validate_call
+ def update_company_document(
+ self,
+ company_id: Annotated[StrictStr, Field(description="The unique identifier of the company.")],
+ company_document_request: Annotated[CompanyDocumentRequest, Field(description="Document information to update.")],
+ accept_language: Annotated[Optional[StrictStr], Field(description="Use for knowing which language to use")] = None,
+ _request_timeout: Union[
+ None,
+ Annotated[StrictFloat, Field(gt=0)],
+ Tuple[
+ Annotated[StrictFloat, Field(gt=0)],
+ Annotated[StrictFloat, Field(gt=0)]
+ ]
+ ] = None,
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _content_type: Optional[StrictStr] = None,
+ _headers: Optional[Dict[StrictStr, Any]] = None,
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
+ ) -> CompanyDocumentResponse:
+ """Update Company Document
+
+ Updates an existing document associated with a specific company.
+
+ :param company_id: The unique identifier of the company. (required)
+ :type company_id: str
+ :param company_document_request: Document information to update. (required)
+ :type company_document_request: CompanyDocumentRequest
+ :param accept_language: Use for knowing which language to use
+ :type accept_language: str
+ :param _request_timeout: timeout setting for this request. If one
+ number provided, it will be total request
+ timeout. It can also be a pair (tuple) of
+ (connection, read) timeouts.
+ :type _request_timeout: int, tuple(int, int), optional
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the
+ authentication in the spec for a single request.
+ :type _request_auth: dict, optional
+ :param _content_type: force content-type for the request.
+ :type _content_type: str, Optional
+ :param _headers: set to override the headers for a single
+ request; this effectively ignores the headers
+ in the spec for a single request.
+ :type _headers: dict, optional
+ :param _host_index: set to override the host_index for a single
+ request; this effectively ignores the host_index
+ in the spec for a single request.
+ :type _host_index: int, optional
+ :return: Returns the result object.
+ """ # noqa: E501
+
+ _param = self._update_company_document_serialize(
+ company_id=company_id,
+ company_document_request=company_document_request,
+ accept_language=accept_language,
+ _request_auth=_request_auth,
+ _content_type=_content_type,
+ _headers=_headers,
+ _host_index=_host_index
+ )
+
+ _response_types_map: Dict[str, Optional[str]] = {
+ '200': "CompanyDocumentResponse",
+ '401': "Error",
+ '404': "Error",
+ '500': "Error",
+ }
+ response_data = self.api_client.call_api(
+ *_param,
+ _request_timeout=_request_timeout
+ )
+ response_data.read()
+ return self.api_client.response_deserialize(
+ response_data=response_data,
+ response_types_map=_response_types_map,
+ ).data
+
+
+ @validate_call
+ def update_company_document_with_http_info(
+ self,
+ company_id: Annotated[StrictStr, Field(description="The unique identifier of the company.")],
+ company_document_request: Annotated[CompanyDocumentRequest, Field(description="Document information to update.")],
+ accept_language: Annotated[Optional[StrictStr], Field(description="Use for knowing which language to use")] = None,
+ _request_timeout: Union[
+ None,
+ Annotated[StrictFloat, Field(gt=0)],
+ Tuple[
+ Annotated[StrictFloat, Field(gt=0)],
+ Annotated[StrictFloat, Field(gt=0)]
+ ]
+ ] = None,
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _content_type: Optional[StrictStr] = None,
+ _headers: Optional[Dict[StrictStr, Any]] = None,
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
+ ) -> ApiResponse[CompanyDocumentResponse]:
+ """Update Company Document
+
+ Updates an existing document associated with a specific company.
+
+ :param company_id: The unique identifier of the company. (required)
+ :type company_id: str
+ :param company_document_request: Document information to update. (required)
+ :type company_document_request: CompanyDocumentRequest
+ :param accept_language: Use for knowing which language to use
+ :type accept_language: str
+ :param _request_timeout: timeout setting for this request. If one
+ number provided, it will be total request
+ timeout. It can also be a pair (tuple) of
+ (connection, read) timeouts.
+ :type _request_timeout: int, tuple(int, int), optional
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the
+ authentication in the spec for a single request.
+ :type _request_auth: dict, optional
+ :param _content_type: force content-type for the request.
+ :type _content_type: str, Optional
+ :param _headers: set to override the headers for a single
+ request; this effectively ignores the headers
+ in the spec for a single request.
+ :type _headers: dict, optional
+ :param _host_index: set to override the host_index for a single
+ request; this effectively ignores the host_index
+ in the spec for a single request.
+ :type _host_index: int, optional
+ :return: Returns the result object.
+ """ # noqa: E501
+
+ _param = self._update_company_document_serialize(
+ company_id=company_id,
+ company_document_request=company_document_request,
+ accept_language=accept_language,
+ _request_auth=_request_auth,
+ _content_type=_content_type,
+ _headers=_headers,
+ _host_index=_host_index
+ )
+
+ _response_types_map: Dict[str, Optional[str]] = {
+ '200': "CompanyDocumentResponse",
+ '401': "Error",
+ '404': "Error",
+ '500': "Error",
+ }
+ response_data = self.api_client.call_api(
+ *_param,
+ _request_timeout=_request_timeout
+ )
+ response_data.read()
+ return self.api_client.response_deserialize(
+ response_data=response_data,
+ response_types_map=_response_types_map,
+ )
+
+
+ @validate_call
+ def update_company_document_without_preload_content(
+ self,
+ company_id: Annotated[StrictStr, Field(description="The unique identifier of the company.")],
+ company_document_request: Annotated[CompanyDocumentRequest, Field(description="Document information to update.")],
+ accept_language: Annotated[Optional[StrictStr], Field(description="Use for knowing which language to use")] = None,
+ _request_timeout: Union[
+ None,
+ Annotated[StrictFloat, Field(gt=0)],
+ Tuple[
+ Annotated[StrictFloat, Field(gt=0)],
+ Annotated[StrictFloat, Field(gt=0)]
+ ]
+ ] = None,
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _content_type: Optional[StrictStr] = None,
+ _headers: Optional[Dict[StrictStr, Any]] = None,
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
+ ) -> RESTResponseType:
+ """Update Company Document
+
+ Updates an existing document associated with a specific company.
+
+ :param company_id: The unique identifier of the company. (required)
+ :type company_id: str
+ :param company_document_request: Document information to update. (required)
+ :type company_document_request: CompanyDocumentRequest
+ :param accept_language: Use for knowing which language to use
+ :type accept_language: str
+ :param _request_timeout: timeout setting for this request. If one
+ number provided, it will be total request
+ timeout. It can also be a pair (tuple) of
+ (connection, read) timeouts.
+ :type _request_timeout: int, tuple(int, int), optional
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the
+ authentication in the spec for a single request.
+ :type _request_auth: dict, optional
+ :param _content_type: force content-type for the request.
+ :type _content_type: str, Optional
+ :param _headers: set to override the headers for a single
+ request; this effectively ignores the headers
+ in the spec for a single request.
+ :type _headers: dict, optional
+ :param _host_index: set to override the host_index for a single
+ request; this effectively ignores the host_index
+ in the spec for a single request.
+ :type _host_index: int, optional
+ :return: Returns the result object.
+ """ # noqa: E501
+
+ _param = self._update_company_document_serialize(
+ company_id=company_id,
+ company_document_request=company_document_request,
+ accept_language=accept_language,
+ _request_auth=_request_auth,
+ _content_type=_content_type,
+ _headers=_headers,
+ _host_index=_host_index
+ )
+
+ _response_types_map: Dict[str, Optional[str]] = {
+ '200': "CompanyDocumentResponse",
+ '401': "Error",
+ '404': "Error",
+ '500': "Error",
+ }
+ response_data = self.api_client.call_api(
+ *_param,
+ _request_timeout=_request_timeout
+ )
+ return response_data.response
+
+
+ def _update_company_document_serialize(
+ self,
+ company_id,
+ company_document_request,
+ accept_language,
+ _request_auth,
+ _content_type,
+ _headers,
+ _host_index,
+ ) -> RequestSerialized:
+
+ _host = None
+
+ _collection_formats: Dict[str, str] = {
+ }
+
+ _path_params: Dict[str, str] = {}
+ _query_params: List[Tuple[str, str]] = []
+ _header_params: Dict[str, Optional[str]] = _headers or {}
+ _form_params: List[Tuple[str, str]] = []
+ _files: Dict[
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ ] = {}
+ _body_params: Optional[bytes] = None
+
+ # process the path parameters
+ if company_id is not None:
+ _path_params['company_id'] = company_id
+ # process the query parameters
+ # process the header parameters
+ if accept_language is not None:
+ _header_params['Accept-Language'] = accept_language
+ # process the form parameters
+ # process the body parameter
+ if company_document_request is not None:
+ _body_params = company_document_request
+
+
+ # set the HTTP header `Accept`
+ if 'Accept' not in _header_params:
+ _header_params['Accept'] = self.api_client.select_header_accept(
+ [
+ 'application/vnd.conekta-v2.2.0+json'
+ ]
+ )
+
+ # set the HTTP header `Content-Type`
+ if _content_type:
+ _header_params['Content-Type'] = _content_type
+ else:
+ _default_content_type = (
+ self.api_client.select_header_content_type(
+ [
+ 'application/json'
+ ]
+ )
+ )
+ if _default_content_type is not None:
+ _header_params['Content-Type'] = _default_content_type
+
+ # authentication setting
+ _auth_settings: List[str] = [
+ 'bearerAuth'
+ ]
+
+ return self.api_client.param_serialize(
+ method='PATCH',
+ resource_path='/companies/{company_id}/document',
+ path_params=_path_params,
+ query_params=_query_params,
+ header_params=_header_params,
+ body=_body_params,
+ post_params=_form_params,
+ files=_files,
+ auth_settings=_auth_settings,
+ collection_formats=_collection_formats,
+ _host=_host,
+ _request_auth=_request_auth
+ )
+
+
+
+
+ @validate_call
+ def upload_company_document(
+ self,
+ company_id: Annotated[StrictStr, Field(description="The unique identifier of the company.")],
+ company_document_request: Annotated[CompanyDocumentRequest, Field(description="Document information to upload.")],
+ accept_language: Annotated[Optional[StrictStr], Field(description="Use for knowing which language to use")] = None,
+ _request_timeout: Union[
+ None,
+ Annotated[StrictFloat, Field(gt=0)],
+ Tuple[
+ Annotated[StrictFloat, Field(gt=0)],
+ Annotated[StrictFloat, Field(gt=0)]
+ ]
+ ] = None,
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _content_type: Optional[StrictStr] = None,
+ _headers: Optional[Dict[StrictStr, Any]] = None,
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
+ ) -> CompanyDocumentResponse:
+ """Upload Company Document
+
+ Uploads a document associated with a specific company.
+
+ :param company_id: The unique identifier of the company. (required)
+ :type company_id: str
+ :param company_document_request: Document information to upload. (required)
+ :type company_document_request: CompanyDocumentRequest
+ :param accept_language: Use for knowing which language to use
+ :type accept_language: str
+ :param _request_timeout: timeout setting for this request. If one
+ number provided, it will be total request
+ timeout. It can also be a pair (tuple) of
+ (connection, read) timeouts.
+ :type _request_timeout: int, tuple(int, int), optional
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the
+ authentication in the spec for a single request.
+ :type _request_auth: dict, optional
+ :param _content_type: force content-type for the request.
+ :type _content_type: str, Optional
+ :param _headers: set to override the headers for a single
+ request; this effectively ignores the headers
+ in the spec for a single request.
+ :type _headers: dict, optional
+ :param _host_index: set to override the host_index for a single
+ request; this effectively ignores the host_index
+ in the spec for a single request.
+ :type _host_index: int, optional
+ :return: Returns the result object.
+ """ # noqa: E501
+
+ _param = self._upload_company_document_serialize(
+ company_id=company_id,
+ company_document_request=company_document_request,
+ accept_language=accept_language,
+ _request_auth=_request_auth,
+ _content_type=_content_type,
+ _headers=_headers,
+ _host_index=_host_index
+ )
+
+ _response_types_map: Dict[str, Optional[str]] = {
+ '201': "CompanyDocumentResponse",
+ '401': "Error",
+ '404': "Error",
+ '500': "Error",
+ }
+ response_data = self.api_client.call_api(
+ *_param,
+ _request_timeout=_request_timeout
+ )
+ response_data.read()
+ return self.api_client.response_deserialize(
+ response_data=response_data,
+ response_types_map=_response_types_map,
+ ).data
+
+
+ @validate_call
+ def upload_company_document_with_http_info(
+ self,
+ company_id: Annotated[StrictStr, Field(description="The unique identifier of the company.")],
+ company_document_request: Annotated[CompanyDocumentRequest, Field(description="Document information to upload.")],
+ accept_language: Annotated[Optional[StrictStr], Field(description="Use for knowing which language to use")] = None,
+ _request_timeout: Union[
+ None,
+ Annotated[StrictFloat, Field(gt=0)],
+ Tuple[
+ Annotated[StrictFloat, Field(gt=0)],
+ Annotated[StrictFloat, Field(gt=0)]
+ ]
+ ] = None,
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _content_type: Optional[StrictStr] = None,
+ _headers: Optional[Dict[StrictStr, Any]] = None,
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
+ ) -> ApiResponse[CompanyDocumentResponse]:
+ """Upload Company Document
+
+ Uploads a document associated with a specific company.
+
+ :param company_id: The unique identifier of the company. (required)
+ :type company_id: str
+ :param company_document_request: Document information to upload. (required)
+ :type company_document_request: CompanyDocumentRequest
+ :param accept_language: Use for knowing which language to use
+ :type accept_language: str
+ :param _request_timeout: timeout setting for this request. If one
+ number provided, it will be total request
+ timeout. It can also be a pair (tuple) of
+ (connection, read) timeouts.
+ :type _request_timeout: int, tuple(int, int), optional
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the
+ authentication in the spec for a single request.
+ :type _request_auth: dict, optional
+ :param _content_type: force content-type for the request.
+ :type _content_type: str, Optional
+ :param _headers: set to override the headers for a single
+ request; this effectively ignores the headers
+ in the spec for a single request.
+ :type _headers: dict, optional
+ :param _host_index: set to override the host_index for a single
+ request; this effectively ignores the host_index
+ in the spec for a single request.
+ :type _host_index: int, optional
+ :return: Returns the result object.
+ """ # noqa: E501
+
+ _param = self._upload_company_document_serialize(
+ company_id=company_id,
+ company_document_request=company_document_request,
+ accept_language=accept_language,
+ _request_auth=_request_auth,
+ _content_type=_content_type,
+ _headers=_headers,
+ _host_index=_host_index
+ )
+
+ _response_types_map: Dict[str, Optional[str]] = {
+ '201': "CompanyDocumentResponse",
+ '401': "Error",
+ '404': "Error",
+ '500': "Error",
+ }
+ response_data = self.api_client.call_api(
+ *_param,
+ _request_timeout=_request_timeout
+ )
+ response_data.read()
+ return self.api_client.response_deserialize(
+ response_data=response_data,
+ response_types_map=_response_types_map,
+ )
+
+
+ @validate_call
+ def upload_company_document_without_preload_content(
+ self,
+ company_id: Annotated[StrictStr, Field(description="The unique identifier of the company.")],
+ company_document_request: Annotated[CompanyDocumentRequest, Field(description="Document information to upload.")],
+ accept_language: Annotated[Optional[StrictStr], Field(description="Use for knowing which language to use")] = None,
+ _request_timeout: Union[
+ None,
+ Annotated[StrictFloat, Field(gt=0)],
+ Tuple[
+ Annotated[StrictFloat, Field(gt=0)],
+ Annotated[StrictFloat, Field(gt=0)]
+ ]
+ ] = None,
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _content_type: Optional[StrictStr] = None,
+ _headers: Optional[Dict[StrictStr, Any]] = None,
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
+ ) -> RESTResponseType:
+ """Upload Company Document
+
+ Uploads a document associated with a specific company.
+
+ :param company_id: The unique identifier of the company. (required)
+ :type company_id: str
+ :param company_document_request: Document information to upload. (required)
+ :type company_document_request: CompanyDocumentRequest
+ :param accept_language: Use for knowing which language to use
+ :type accept_language: str
+ :param _request_timeout: timeout setting for this request. If one
+ number provided, it will be total request
+ timeout. It can also be a pair (tuple) of
+ (connection, read) timeouts.
+ :type _request_timeout: int, tuple(int, int), optional
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the
+ authentication in the spec for a single request.
+ :type _request_auth: dict, optional
+ :param _content_type: force content-type for the request.
+ :type _content_type: str, Optional
+ :param _headers: set to override the headers for a single
+ request; this effectively ignores the headers
+ in the spec for a single request.
+ :type _headers: dict, optional
+ :param _host_index: set to override the host_index for a single
+ request; this effectively ignores the host_index
+ in the spec for a single request.
+ :type _host_index: int, optional
+ :return: Returns the result object.
+ """ # noqa: E501
+
+ _param = self._upload_company_document_serialize(
+ company_id=company_id,
+ company_document_request=company_document_request,
+ accept_language=accept_language,
+ _request_auth=_request_auth,
+ _content_type=_content_type,
+ _headers=_headers,
+ _host_index=_host_index
+ )
+
+ _response_types_map: Dict[str, Optional[str]] = {
+ '201': "CompanyDocumentResponse",
+ '401': "Error",
+ '404': "Error",
+ '500': "Error",
+ }
+ response_data = self.api_client.call_api(
+ *_param,
+ _request_timeout=_request_timeout
+ )
+ return response_data.response
+
+
+ def _upload_company_document_serialize(
+ self,
+ company_id,
+ company_document_request,
+ accept_language,
+ _request_auth,
+ _content_type,
+ _headers,
+ _host_index,
+ ) -> RequestSerialized:
+
+ _host = None
+
+ _collection_formats: Dict[str, str] = {
+ }
+
+ _path_params: Dict[str, str] = {}
+ _query_params: List[Tuple[str, str]] = []
+ _header_params: Dict[str, Optional[str]] = _headers or {}
+ _form_params: List[Tuple[str, str]] = []
+ _files: Dict[
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ ] = {}
+ _body_params: Optional[bytes] = None
+
+ # process the path parameters
+ if company_id is not None:
+ _path_params['company_id'] = company_id
+ # process the query parameters
+ # process the header parameters
+ if accept_language is not None:
+ _header_params['Accept-Language'] = accept_language
+ # process the form parameters
+ # process the body parameter
+ if company_document_request is not None:
+ _body_params = company_document_request
+
+
+ # set the HTTP header `Accept`
+ if 'Accept' not in _header_params:
+ _header_params['Accept'] = self.api_client.select_header_accept(
+ [
+ 'application/vnd.conekta-v2.2.0+json'
+ ]
+ )
+
+ # set the HTTP header `Content-Type`
+ if _content_type:
+ _header_params['Content-Type'] = _content_type
+ else:
+ _default_content_type = (
+ self.api_client.select_header_content_type(
+ [
+ 'application/json'
+ ]
+ )
+ )
+ if _default_content_type is not None:
+ _header_params['Content-Type'] = _default_content_type
+
+ # authentication setting
+ _auth_settings: List[str] = [
+ 'bearerAuth'
+ ]
+
+ return self.api_client.param_serialize(
+ method='POST',
+ resource_path='/companies/{company_id}/document',
+ path_params=_path_params,
+ query_params=_query_params,
+ header_params=_header_params,
+ body=_body_params,
+ post_params=_form_params,
+ files=_files,
+ auth_settings=_auth_settings,
+ collection_formats=_collection_formats,
+ _host=_host,
+ _request_auth=_request_auth
+ )
+
+
diff --git a/conekta/api_client.py b/conekta/api_client.py
index b319531..e08b7e4 100644
--- a/conekta/api_client.py
+++ b/conekta/api_client.py
@@ -74,7 +74,7 @@ class ApiClient:
'lang': 'python',
'lang_version': platform.python_version(),
'publisher': 'conekta',
- 'bindings_version': '7.0.1',
+ 'bindings_version': '7.0.2',
'uname': platform.uname()
}
_pool = None
@@ -97,7 +97,7 @@ def __init__(
self.default_headers[header_name] = header_value
self.cookie = cookie
# Set default User-Agent.
- self.user_agent = 'Conekta/v2 PythonBindings/7.0.1'
+ self.user_agent = 'Conekta/v2 PythonBindings/7.0.2'
self.conekta_user_agent = json.dumps(self.data)
self.client_side_validation = configuration.client_side_validation
diff --git a/conekta/configuration.py b/conekta/configuration.py
index acce865..bf6c7d7 100644
--- a/conekta/configuration.py
+++ b/conekta/configuration.py
@@ -393,7 +393,7 @@ def to_debug_report(self):
"OS: {env}\n"\
"Python Version: {pyversion}\n"\
"Version of the API: 2.2.0\n"\
- "SDK Package Version: 7.0.1".\
+ "SDK Package Version: 7.0.2".\
format(env=sys.platform, pyversion=sys.version)
def get_host_settings(self):
diff --git a/conekta/models/__init__.py b/conekta/models/__init__.py
index ab06e47..a16e77a 100644
--- a/conekta/models/__init__.py
+++ b/conekta/models/__init__.py
@@ -42,10 +42,14 @@
from conekta.models.checkout_request import CheckoutRequest
from conekta.models.checkout_response import CheckoutResponse
from conekta.models.checkouts_response import CheckoutsResponse
-from conekta.models.company_fiscal_info_address_response import CompanyFiscalInfoAddressResponse
-from conekta.models.company_fiscal_info_response import CompanyFiscalInfoResponse
-from conekta.models.company_payout_destination_response import CompanyPayoutDestinationResponse
+from conekta.models.company_document_request import CompanyDocumentRequest
+from conekta.models.company_document_response import CompanyDocumentResponse
from conekta.models.company_response import CompanyResponse
+from conekta.models.company_response_documents_inner import CompanyResponseDocumentsInner
+from conekta.models.create_company_request import CreateCompanyRequest
+from conekta.models.create_company_request_bank_account_info import CreateCompanyRequestBankAccountInfo
+from conekta.models.create_company_request_comercial_info import CreateCompanyRequestComercialInfo
+from conekta.models.create_company_request_fiscal_info import CreateCompanyRequestFiscalInfo
from conekta.models.create_customer_fiscal_entities_response import CreateCustomerFiscalEntitiesResponse
from conekta.models.create_customer_payment_methods_request import CreateCustomerPaymentMethodsRequest
from conekta.models.create_customer_payment_methods_response import CreateCustomerPaymentMethodsResponse
diff --git a/conekta/models/company_document_request.py b/conekta/models/company_document_request.py
new file mode 100644
index 0000000..2f55c49
--- /dev/null
+++ b/conekta/models/company_document_request.py
@@ -0,0 +1,103 @@
+# coding: utf-8
+
+"""
+ Conekta API
+
+ Conekta sdk
+
+ The version of the OpenAPI document: 2.2.0
+ Contact: engineering@conekta.com
+ Generated by OpenAPI Generator (https://openapi-generator.tech)
+
+ Do not edit the class manually.
+""" # noqa: E501
+
+
+from __future__ import annotations
+import pprint
+import re # noqa: F401
+import json
+
+from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictBytes, StrictStr, field_validator
+from typing import Any, ClassVar, Dict, List, Optional, Union
+from typing import Optional, Set
+from typing_extensions import Self
+
+class CompanyDocumentRequest(BaseModel):
+ """
+ Request body for uploading a company document.
+ """ # noqa: E501
+ file_classification: StrictStr = Field(description="Classification of the document. | Tipo de archivo | Descripción | | :--------------------------- | :-------------------------------------------------------- | | `id_legal_representative` | identificación oficial frente | | `id_legal_representative_back` | identificación oficial atrás | | `cfdi` | Prueba de situación fiscal | | `constitutive_act_basic` | Acta constitutiva | | `proof_of_address` | Comprobante de domicilio del negocio | | `power_of_attonery` | Poderes de representación | | `deposit_account_cover` | Carátula de la cuenta de depósito | | `permit_casino` | Permiso ante SEGOB | | `license_sanitation` | Licencia sanitaria de COFEPRIS | | `registration_tourism` | Inscripción ante el Registro Nacional de Turismo (SECTUR) | ")
+ content_type: StrictStr = Field(description="MIME type of the file. Allowed values depend on the `file_classification`. - `image/jpeg` - `image/png` - `application/pdf` ")
+ international: Optional[StrictBool] = Field(default=None, description="Indicates if the document is international. Defaults to false.")
+ file_name: StrictStr = Field(description="Name of the file being uploaded.")
+ file_data: Union[StrictBytes, StrictStr] = Field(description="Base64 encoded content of the file.")
+ __properties: ClassVar[List[str]] = ["file_classification", "content_type", "international", "file_name", "file_data"]
+
+ @field_validator('file_classification')
+ def file_classification_validate_enum(cls, value):
+ """Validates the enum"""
+ if value not in set(['id_legal_representative', 'id_legal_representative_back', 'cfdi', 'constitutive_act_basic', 'proof_of_address', 'power_of_attonery', 'deposit_account_cover', 'permit_casino', 'license_sanitation', 'registration_tourism']):
+ raise ValueError("must be one of enum values ('id_legal_representative', 'id_legal_representative_back', 'cfdi', 'constitutive_act_basic', 'proof_of_address', 'power_of_attonery', 'deposit_account_cover', 'permit_casino', 'license_sanitation', 'registration_tourism')")
+ return value
+
+ model_config = ConfigDict(
+ populate_by_name=True,
+ validate_assignment=True,
+ protected_namespaces=(),
+ )
+
+
+ def to_str(self) -> str:
+ """Returns the string representation of the model using alias"""
+ return pprint.pformat(self.model_dump(by_alias=True))
+
+ def to_json(self) -> str:
+ """Returns the JSON representation of the model using alias"""
+ # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead
+ return json.dumps(self.to_dict())
+
+ @classmethod
+ def from_json(cls, json_str: str) -> Optional[Self]:
+ """Create an instance of CompanyDocumentRequest from a JSON string"""
+ return cls.from_dict(json.loads(json_str))
+
+ def to_dict(self) -> Dict[str, Any]:
+ """Return the dictionary representation of the model using alias.
+
+ This has the following differences from calling pydantic's
+ `self.model_dump(by_alias=True)`:
+
+ * `None` is only added to the output dict for nullable fields that
+ were set at model initialization. Other fields with value `None`
+ are ignored.
+ """
+ excluded_fields: Set[str] = set([
+ ])
+
+ _dict = self.model_dump(
+ by_alias=True,
+ exclude=excluded_fields,
+ exclude_none=True,
+ )
+ return _dict
+
+ @classmethod
+ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ """Create an instance of CompanyDocumentRequest from a dict"""
+ if obj is None:
+ return None
+
+ if not isinstance(obj, dict):
+ return cls.model_validate(obj)
+
+ _obj = cls.model_validate({
+ "file_classification": obj.get("file_classification"),
+ "content_type": obj.get("content_type"),
+ "international": obj.get("international"),
+ "file_name": obj.get("file_name"),
+ "file_data": obj.get("file_data")
+ })
+ return _obj
+
+
diff --git a/conekta/models/company_document_response.py b/conekta/models/company_document_response.py
new file mode 100644
index 0000000..473edf3
--- /dev/null
+++ b/conekta/models/company_document_response.py
@@ -0,0 +1,99 @@
+# coding: utf-8
+
+"""
+ Conekta API
+
+ Conekta sdk
+
+ The version of the OpenAPI document: 2.2.0
+ Contact: engineering@conekta.com
+ Generated by OpenAPI Generator (https://openapi-generator.tech)
+
+ Do not edit the class manually.
+""" # noqa: E501
+
+
+from __future__ import annotations
+import pprint
+import re # noqa: F401
+import json
+
+from pydantic import BaseModel, ConfigDict, Field, StrictStr, field_validator
+from typing import Any, ClassVar, Dict, List
+from typing import Optional, Set
+from typing_extensions import Self
+
+class CompanyDocumentResponse(BaseModel):
+ """
+ Response body after uploading a company document.
+ """ # noqa: E501
+ file_classification: StrictStr = Field(description="Classification of the document. | Tipo de archivo | Descripción | | :--------------------------- | :-------------------------------------------------------- | | `id_legal_representative` | identificación oficial frente | | `id_legal_representative_back` | identificación oficial atrás | | `cfdi` | Prueba de situación fiscal | | `constitutive_act_basic` | Acta constitutiva | | `proof_of_address` | Comprobante de domicilio del negocio | | `power_of_attonery` | Poderes de representación | | `deposit_account_cover` | Carátula de la cuenta de depósito | | `permit_casino` | Permiso ante SEGOB | | `license_sanitation` | Licencia sanitaria de COFEPRIS | | `registration_tourism` | Inscripción ante el Registro Nacional de Turismo (SECTUR) | ")
+ file_name: StrictStr = Field(description="Name of the file as stored or processed.")
+ status: StrictStr = Field(description="Current status of the document.")
+ __properties: ClassVar[List[str]] = ["file_classification", "file_name", "status"]
+
+ @field_validator('file_classification')
+ def file_classification_validate_enum(cls, value):
+ """Validates the enum"""
+ if value not in set(['id_legal_representative', 'id_legal_representative_back', 'cfdi', 'constitutive_act_basic', 'proof_of_address', 'power_of_attonery', 'deposit_account_cover', 'permit_casino', 'license_sanitation', 'registration_tourism']):
+ raise ValueError("must be one of enum values ('id_legal_representative', 'id_legal_representative_back', 'cfdi', 'constitutive_act_basic', 'proof_of_address', 'power_of_attonery', 'deposit_account_cover', 'permit_casino', 'license_sanitation', 'registration_tourism')")
+ return value
+
+ model_config = ConfigDict(
+ populate_by_name=True,
+ validate_assignment=True,
+ protected_namespaces=(),
+ )
+
+
+ def to_str(self) -> str:
+ """Returns the string representation of the model using alias"""
+ return pprint.pformat(self.model_dump(by_alias=True))
+
+ def to_json(self) -> str:
+ """Returns the JSON representation of the model using alias"""
+ # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead
+ return json.dumps(self.to_dict())
+
+ @classmethod
+ def from_json(cls, json_str: str) -> Optional[Self]:
+ """Create an instance of CompanyDocumentResponse from a JSON string"""
+ return cls.from_dict(json.loads(json_str))
+
+ def to_dict(self) -> Dict[str, Any]:
+ """Return the dictionary representation of the model using alias.
+
+ This has the following differences from calling pydantic's
+ `self.model_dump(by_alias=True)`:
+
+ * `None` is only added to the output dict for nullable fields that
+ were set at model initialization. Other fields with value `None`
+ are ignored.
+ """
+ excluded_fields: Set[str] = set([
+ ])
+
+ _dict = self.model_dump(
+ by_alias=True,
+ exclude=excluded_fields,
+ exclude_none=True,
+ )
+ return _dict
+
+ @classmethod
+ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ """Create an instance of CompanyDocumentResponse from a dict"""
+ if obj is None:
+ return None
+
+ if not isinstance(obj, dict):
+ return cls.model_validate(obj)
+
+ _obj = cls.model_validate({
+ "file_classification": obj.get("file_classification"),
+ "file_name": obj.get("file_name"),
+ "status": obj.get("status")
+ })
+ return _obj
+
+
diff --git a/conekta/models/company_response.py b/conekta/models/company_response.py
index 9075fd9..713df1d 100644
--- a/conekta/models/company_response.py
+++ b/conekta/models/company_response.py
@@ -18,36 +18,26 @@
import re # noqa: F401
import json
-from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt, StrictStr, field_validator
+from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt, StrictStr
from typing import Any, ClassVar, Dict, List, Optional
-from conekta.models.company_fiscal_info_response import CompanyFiscalInfoResponse
-from conekta.models.company_payout_destination_response import CompanyPayoutDestinationResponse
+from conekta.models.company_response_documents_inner import CompanyResponseDocumentsInner
from typing import Optional, Set
from typing_extensions import Self
class CompanyResponse(BaseModel):
"""
- Company model
+ CompanyResponse
""" # noqa: E501
- id: Optional[StrictStr] = Field(default=None, description="The child company's unique identifier")
- created_at: Optional[StrictInt] = Field(default=None, description="The resource's creation date (unix timestamp)")
- name: Optional[StrictStr] = Field(default=None, description="The child company's name")
- object: Optional[StrictStr] = Field(default=None, description="The resource's type")
- parent_company_id: Optional[StrictStr] = Field(default=None, description="Id of the parent company")
- use_parent_fiscal_data: Optional[StrictBool] = Field(default=None, description="Whether the parent company's fiscal data is to be used for liquidation and tax purposes")
- payout_destination: Optional[CompanyPayoutDestinationResponse] = None
- fiscal_info: Optional[CompanyFiscalInfoResponse] = None
- __properties: ClassVar[List[str]] = ["id", "created_at", "name", "object", "parent_company_id", "use_parent_fiscal_data", "payout_destination", "fiscal_info"]
-
- @field_validator('object')
- def object_validate_enum(cls, value):
- """Validates the enum"""
- if value is None:
- return value
-
- if value not in set(['company']):
- raise ValueError("must be one of enum values ('company')")
- return value
+ id: StrictStr = Field(description="The unique identifier for the company.")
+ name: StrictStr = Field(description="The name of the company.")
+ active: StrictBool = Field(description="Indicates if the company is active.")
+ account_status: StrictStr = Field(description="The current status of the company's account.")
+ parent_company_id: Optional[StrictStr] = Field(default=None, description="The identifier of the parent company, if any.")
+ onboarding_status: StrictStr = Field(description="The current status of the company's onboarding process.")
+ documents: List[CompanyResponseDocumentsInner] = Field(description="A list of documents related to the company.")
+ created_at: StrictInt = Field(description="Timestamp of when the company was created.")
+ object: StrictStr = Field(description="The type of object, typically \"company\".")
+ __properties: ClassVar[List[str]] = ["id", "name", "active", "account_status", "parent_company_id", "onboarding_status", "documents", "created_at", "object"]
model_config = ConfigDict(
populate_by_name=True,
@@ -88,12 +78,18 @@ def to_dict(self) -> Dict[str, Any]:
exclude=excluded_fields,
exclude_none=True,
)
- # override the default output from pydantic by calling `to_dict()` of payout_destination
- if self.payout_destination:
- _dict['payout_destination'] = self.payout_destination.to_dict()
- # override the default output from pydantic by calling `to_dict()` of fiscal_info
- if self.fiscal_info:
- _dict['fiscal_info'] = self.fiscal_info.to_dict()
+ # override the default output from pydantic by calling `to_dict()` of each item in documents (list)
+ _items = []
+ if self.documents:
+ for _item_documents in self.documents:
+ if _item_documents:
+ _items.append(_item_documents.to_dict())
+ _dict['documents'] = _items
+ # set to None if parent_company_id (nullable) is None
+ # and model_fields_set contains the field
+ if self.parent_company_id is None and "parent_company_id" in self.model_fields_set:
+ _dict['parent_company_id'] = None
+
return _dict
@classmethod
@@ -107,13 +103,14 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
_obj = cls.model_validate({
"id": obj.get("id"),
- "created_at": obj.get("created_at"),
"name": obj.get("name"),
- "object": obj.get("object"),
+ "active": obj.get("active"),
+ "account_status": obj.get("account_status"),
"parent_company_id": obj.get("parent_company_id"),
- "use_parent_fiscal_data": obj.get("use_parent_fiscal_data"),
- "payout_destination": CompanyPayoutDestinationResponse.from_dict(obj["payout_destination"]) if obj.get("payout_destination") is not None else None,
- "fiscal_info": CompanyFiscalInfoResponse.from_dict(obj["fiscal_info"]) if obj.get("fiscal_info") is not None else None
+ "onboarding_status": obj.get("onboarding_status"),
+ "documents": [CompanyResponseDocumentsInner.from_dict(_item) for _item in obj["documents"]] if obj.get("documents") is not None else None,
+ "created_at": obj.get("created_at"),
+ "object": obj.get("object")
})
return _obj
diff --git a/conekta/models/company_response_documents_inner.py b/conekta/models/company_response_documents_inner.py
new file mode 100644
index 0000000..f58ce00
--- /dev/null
+++ b/conekta/models/company_response_documents_inner.py
@@ -0,0 +1,107 @@
+# coding: utf-8
+
+"""
+ Conekta API
+
+ Conekta sdk
+
+ The version of the OpenAPI document: 2.2.0
+ Contact: engineering@conekta.com
+ Generated by OpenAPI Generator (https://openapi-generator.tech)
+
+ Do not edit the class manually.
+""" # noqa: E501
+
+
+from __future__ import annotations
+import pprint
+import re # noqa: F401
+import json
+
+from pydantic import BaseModel, ConfigDict, Field, StrictStr, field_validator
+from typing import Any, ClassVar, Dict, List, Optional
+from typing import Optional, Set
+from typing_extensions import Self
+
+class CompanyResponseDocumentsInner(BaseModel):
+ """
+ CompanyResponseDocumentsInner
+ """ # noqa: E501
+ file_classification: Optional[StrictStr] = Field(default=None, description="Classification of the document. | Tipo de archivo | Descripción | | :--------------------------- | :-------------------------------------------------------- | | `id_legal_representative` | identificación oficial frente | | `id_legal_representative_back` | identificación oficial atrás | | `cfdi` | Prueba de situación fiscal | | `constitutive_act_basic` | Acta constitutiva | | `proof_of_address` | Comprobante de domicilio del negocio | | `power_of_attonery` | Poderes de representación | | `deposit_account_cover` | Carátula de la cuenta de depósito | | `permit_casino` | Permiso ante SEGOB | | `license_sanitation` | Licencia sanitaria de COFEPRIS | | `registration_tourism` | Inscripción ante el Registro Nacional de Turismo (SECTUR) | ")
+ status: Optional[StrictStr] = Field(default=None, description="The status of the document.")
+ file_name: Optional[StrictStr] = Field(default=None, description="The name of the file.")
+ __properties: ClassVar[List[str]] = ["file_classification", "status", "file_name"]
+
+ @field_validator('file_classification')
+ def file_classification_validate_enum(cls, value):
+ """Validates the enum"""
+ if value is None:
+ return value
+
+ if value not in set(['id_legal_representative', 'id_legal_representative_back', 'cfdi', 'constitutive_act_basic', 'proof_of_address', 'power_of_attonery', 'deposit_account_cover', 'permit_casino', 'license_sanitation', 'registration_tourism']):
+ raise ValueError("must be one of enum values ('id_legal_representative', 'id_legal_representative_back', 'cfdi', 'constitutive_act_basic', 'proof_of_address', 'power_of_attonery', 'deposit_account_cover', 'permit_casino', 'license_sanitation', 'registration_tourism')")
+ return value
+
+ model_config = ConfigDict(
+ populate_by_name=True,
+ validate_assignment=True,
+ protected_namespaces=(),
+ )
+
+
+ def to_str(self) -> str:
+ """Returns the string representation of the model using alias"""
+ return pprint.pformat(self.model_dump(by_alias=True))
+
+ def to_json(self) -> str:
+ """Returns the JSON representation of the model using alias"""
+ # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead
+ return json.dumps(self.to_dict())
+
+ @classmethod
+ def from_json(cls, json_str: str) -> Optional[Self]:
+ """Create an instance of CompanyResponseDocumentsInner from a JSON string"""
+ return cls.from_dict(json.loads(json_str))
+
+ def to_dict(self) -> Dict[str, Any]:
+ """Return the dictionary representation of the model using alias.
+
+ This has the following differences from calling pydantic's
+ `self.model_dump(by_alias=True)`:
+
+ * `None` is only added to the output dict for nullable fields that
+ were set at model initialization. Other fields with value `None`
+ are ignored.
+ """
+ excluded_fields: Set[str] = set([
+ ])
+
+ _dict = self.model_dump(
+ by_alias=True,
+ exclude=excluded_fields,
+ exclude_none=True,
+ )
+ # set to None if file_name (nullable) is None
+ # and model_fields_set contains the field
+ if self.file_name is None and "file_name" in self.model_fields_set:
+ _dict['file_name'] = None
+
+ return _dict
+
+ @classmethod
+ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ """Create an instance of CompanyResponseDocumentsInner from a dict"""
+ if obj is None:
+ return None
+
+ if not isinstance(obj, dict):
+ return cls.model_validate(obj)
+
+ _obj = cls.model_validate({
+ "file_classification": obj.get("file_classification"),
+ "status": obj.get("status"),
+ "file_name": obj.get("file_name")
+ })
+ return _obj
+
+
diff --git a/conekta/models/company_fiscal_info_response.py b/conekta/models/create_company_request.py
similarity index 50%
rename from conekta/models/company_fiscal_info_response.py
rename to conekta/models/create_company_request.py
index 6adc99e..ed456a7 100644
--- a/conekta/models/company_fiscal_info_response.py
+++ b/conekta/models/create_company_request.py
@@ -18,34 +18,24 @@
import re # noqa: F401
import json
-from pydantic import BaseModel, ConfigDict, Field, StrictStr, field_validator
+from pydantic import BaseModel, ConfigDict, Field, StrictStr
from typing import Any, ClassVar, Dict, List, Optional
-from conekta.models.company_fiscal_info_address_response import CompanyFiscalInfoAddressResponse
+from conekta.models.create_company_request_bank_account_info import CreateCompanyRequestBankAccountInfo
+from conekta.models.create_company_request_comercial_info import CreateCompanyRequestComercialInfo
+from conekta.models.create_company_request_fiscal_info import CreateCompanyRequestFiscalInfo
from typing import Optional, Set
from typing_extensions import Self
-class CompanyFiscalInfoResponse(BaseModel):
+class CreateCompanyRequest(BaseModel):
"""
- Company fiscal info model
+ CreateCompanyRequest
""" # noqa: E501
- object: Optional[StrictStr] = Field(default=None, description="The resource's type")
- tax_id: Optional[StrictStr] = Field(default=None, description="Tax ID of the company")
- legal_entity_name: Optional[StrictStr] = Field(default=None, description="Legal name of the company")
- business_type: Optional[StrictStr] = Field(default=None, description="Business type of the company")
- phone: Optional[StrictStr] = Field(default=None, description="Phone number of the company")
- physical_person_business_type: Optional[StrictStr] = Field(default=None, description="Business type if 'persona_fisica'")
- address: Optional[CompanyFiscalInfoAddressResponse] = None
- __properties: ClassVar[List[str]] = ["object", "tax_id", "legal_entity_name", "business_type", "phone", "physical_person_business_type", "address"]
-
- @field_validator('object')
- def object_validate_enum(cls, value):
- """Validates the enum"""
- if value is None:
- return value
-
- if value not in set(['fiscal_info']):
- raise ValueError("must be one of enum values ('fiscal_info')")
- return value
+ name: Optional[StrictStr] = Field(default=None, description="The name of the company.")
+ type_company: Optional[StrictStr] = Field(default=None, description="The type of company, 'owner'")
+ comercial_info: Optional[CreateCompanyRequestComercialInfo] = None
+ fiscal_info: Optional[CreateCompanyRequestFiscalInfo] = None
+ bank_account_info: Optional[CreateCompanyRequestBankAccountInfo] = None
+ __properties: ClassVar[List[str]] = ["name", "type_company", "comercial_info", "fiscal_info", "bank_account_info"]
model_config = ConfigDict(
populate_by_name=True,
@@ -65,7 +55,7 @@ def to_json(self) -> str:
@classmethod
def from_json(cls, json_str: str) -> Optional[Self]:
- """Create an instance of CompanyFiscalInfoResponse from a JSON string"""
+ """Create an instance of CreateCompanyRequest from a JSON string"""
return cls.from_dict(json.loads(json_str))
def to_dict(self) -> Dict[str, Any]:
@@ -86,14 +76,20 @@ def to_dict(self) -> Dict[str, Any]:
exclude=excluded_fields,
exclude_none=True,
)
- # override the default output from pydantic by calling `to_dict()` of address
- if self.address:
- _dict['address'] = self.address.to_dict()
+ # override the default output from pydantic by calling `to_dict()` of comercial_info
+ if self.comercial_info:
+ _dict['comercial_info'] = self.comercial_info.to_dict()
+ # override the default output from pydantic by calling `to_dict()` of fiscal_info
+ if self.fiscal_info:
+ _dict['fiscal_info'] = self.fiscal_info.to_dict()
+ # override the default output from pydantic by calling `to_dict()` of bank_account_info
+ if self.bank_account_info:
+ _dict['bank_account_info'] = self.bank_account_info.to_dict()
return _dict
@classmethod
def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
- """Create an instance of CompanyFiscalInfoResponse from a dict"""
+ """Create an instance of CreateCompanyRequest from a dict"""
if obj is None:
return None
@@ -101,13 +97,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
return cls.model_validate(obj)
_obj = cls.model_validate({
- "object": obj.get("object"),
- "tax_id": obj.get("tax_id"),
- "legal_entity_name": obj.get("legal_entity_name"),
- "business_type": obj.get("business_type"),
- "phone": obj.get("phone"),
- "physical_person_business_type": obj.get("physical_person_business_type"),
- "address": CompanyFiscalInfoAddressResponse.from_dict(obj["address"]) if obj.get("address") is not None else None
+ "name": obj.get("name"),
+ "type_company": obj.get("type_company"),
+ "comercial_info": CreateCompanyRequestComercialInfo.from_dict(obj["comercial_info"]) if obj.get("comercial_info") is not None else None,
+ "fiscal_info": CreateCompanyRequestFiscalInfo.from_dict(obj["fiscal_info"]) if obj.get("fiscal_info") is not None else None,
+ "bank_account_info": CreateCompanyRequestBankAccountInfo.from_dict(obj["bank_account_info"]) if obj.get("bank_account_info") is not None else None
})
return _obj
diff --git a/conekta/models/company_fiscal_info_address_response.py b/conekta/models/create_company_request_bank_account_info.py
similarity index 51%
rename from conekta/models/company_fiscal_info_address_response.py
rename to conekta/models/create_company_request_bank_account_info.py
index 0e3ac4c..272a030 100644
--- a/conekta/models/company_fiscal_info_address_response.py
+++ b/conekta/models/create_company_request_bank_account_info.py
@@ -18,35 +18,17 @@
import re # noqa: F401
import json
-from pydantic import BaseModel, ConfigDict, Field, StrictStr, field_validator
+from pydantic import BaseModel, ConfigDict, Field, StrictStr
from typing import Any, ClassVar, Dict, List, Optional
from typing import Optional, Set
from typing_extensions import Self
-class CompanyFiscalInfoAddressResponse(BaseModel):
+class CreateCompanyRequestBankAccountInfo(BaseModel):
"""
- Company fiscal info address model
+ Bank account information for the company.
""" # noqa: E501
- object: Optional[StrictStr] = Field(default=None, description="The resource's type")
- street1: Optional[StrictStr] = Field(default=None, description="Street Address")
- street2: Optional[StrictStr] = Field(default=None, description="Colonia")
- city: Optional[StrictStr] = Field(default=None, description="City")
- state: Optional[StrictStr] = Field(default=None, description="State")
- country: Optional[StrictStr] = Field(default=None, description="Country")
- postal_code: Optional[StrictStr] = Field(default=None, description="Postal code")
- external_number: Optional[StrictStr] = Field(default=None, description="Street number")
- internal_number: Optional[StrictStr] = Field(default=None, description="Unit / apartment number")
- __properties: ClassVar[List[str]] = ["object", "street1", "street2", "city", "state", "country", "postal_code", "external_number", "internal_number"]
-
- @field_validator('object')
- def object_validate_enum(cls, value):
- """Validates the enum"""
- if value is None:
- return value
-
- if value not in set(['address']):
- raise ValueError("must be one of enum values ('address')")
- return value
+ clabe: Optional[StrictStr] = Field(default=None, description="The 18-digit CLABE for the bank account.")
+ __properties: ClassVar[List[str]] = ["clabe"]
model_config = ConfigDict(
populate_by_name=True,
@@ -66,7 +48,7 @@ def to_json(self) -> str:
@classmethod
def from_json(cls, json_str: str) -> Optional[Self]:
- """Create an instance of CompanyFiscalInfoAddressResponse from a JSON string"""
+ """Create an instance of CreateCompanyRequestBankAccountInfo from a JSON string"""
return cls.from_dict(json.loads(json_str))
def to_dict(self) -> Dict[str, Any]:
@@ -91,7 +73,7 @@ def to_dict(self) -> Dict[str, Any]:
@classmethod
def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
- """Create an instance of CompanyFiscalInfoAddressResponse from a dict"""
+ """Create an instance of CreateCompanyRequestBankAccountInfo from a dict"""
if obj is None:
return None
@@ -99,15 +81,7 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
return cls.model_validate(obj)
_obj = cls.model_validate({
- "object": obj.get("object"),
- "street1": obj.get("street1"),
- "street2": obj.get("street2"),
- "city": obj.get("city"),
- "state": obj.get("state"),
- "country": obj.get("country"),
- "postal_code": obj.get("postal_code"),
- "external_number": obj.get("external_number"),
- "internal_number": obj.get("internal_number")
+ "clabe": obj.get("clabe")
})
return _obj
diff --git a/conekta/models/company_payout_destination_response.py b/conekta/models/create_company_request_comercial_info.py
similarity index 51%
rename from conekta/models/company_payout_destination_response.py
rename to conekta/models/create_company_request_comercial_info.py
index 452003c..cb150d3 100644
--- a/conekta/models/company_payout_destination_response.py
+++ b/conekta/models/create_company_request_comercial_info.py
@@ -18,42 +18,20 @@
import re # noqa: F401
import json
-from pydantic import BaseModel, ConfigDict, Field, StrictStr, field_validator
+from pydantic import BaseModel, ConfigDict, Field, StrictStr
from typing import Any, ClassVar, Dict, List, Optional
from typing import Optional, Set
from typing_extensions import Self
-class CompanyPayoutDestinationResponse(BaseModel):
+class CreateCompanyRequestComercialInfo(BaseModel):
"""
- Company payout destination model
+ Commercial information for the company.
""" # noqa: E501
- object: Optional[StrictStr] = Field(default=None, description="The resource's type")
- currency: Optional[StrictStr] = Field(default=None, description="currency of the receiving account")
- account_holder_name: Optional[StrictStr] = Field(default=None, description="Name of the account holder")
- bank: Optional[StrictStr] = Field(default=None, description="Name of the bank")
- type: Optional[StrictStr] = Field(default=None, description="Type of the payout destination")
- account_number: Optional[StrictStr] = Field(default=None, description="Account number of the receiving account")
- __properties: ClassVar[List[str]] = ["object", "currency", "account_holder_name", "bank", "type", "account_number"]
-
- @field_validator('object')
- def object_validate_enum(cls, value):
- """Validates the enum"""
- if value is None:
- return value
-
- if value not in set(['payout_destination']):
- raise ValueError("must be one of enum values ('payout_destination')")
- return value
-
- @field_validator('type')
- def type_validate_enum(cls, value):
- """Validates the enum"""
- if value is None:
- return value
-
- if value not in set(['bank_account']):
- raise ValueError("must be one of enum values ('bank_account')")
- return value
+ website: Optional[StrictStr] = Field(default=None, description="The company's website URL.")
+ mcc: Optional[StrictStr] = Field(default=None, description="The Merchant Category Code (MCC) for the company.")
+ merchant_support_email: Optional[StrictStr] = Field(default=None, description="Email address for merchant support.")
+ merchant_support_phone: Optional[StrictStr] = Field(default=None, description="Phone number for merchant support.")
+ __properties: ClassVar[List[str]] = ["website", "mcc", "merchant_support_email", "merchant_support_phone"]
model_config = ConfigDict(
populate_by_name=True,
@@ -73,7 +51,7 @@ def to_json(self) -> str:
@classmethod
def from_json(cls, json_str: str) -> Optional[Self]:
- """Create an instance of CompanyPayoutDestinationResponse from a JSON string"""
+ """Create an instance of CreateCompanyRequestComercialInfo from a JSON string"""
return cls.from_dict(json.loads(json_str))
def to_dict(self) -> Dict[str, Any]:
@@ -98,7 +76,7 @@ def to_dict(self) -> Dict[str, Any]:
@classmethod
def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
- """Create an instance of CompanyPayoutDestinationResponse from a dict"""
+ """Create an instance of CreateCompanyRequestComercialInfo from a dict"""
if obj is None:
return None
@@ -106,12 +84,10 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
return cls.model_validate(obj)
_obj = cls.model_validate({
- "object": obj.get("object"),
- "currency": obj.get("currency"),
- "account_holder_name": obj.get("account_holder_name"),
- "bank": obj.get("bank"),
- "type": obj.get("type"),
- "account_number": obj.get("account_number")
+ "website": obj.get("website"),
+ "mcc": obj.get("mcc"),
+ "merchant_support_email": obj.get("merchant_support_email"),
+ "merchant_support_phone": obj.get("merchant_support_phone")
})
return _obj
diff --git a/conekta/models/create_company_request_fiscal_info.py b/conekta/models/create_company_request_fiscal_info.py
new file mode 100644
index 0000000..11423f8
--- /dev/null
+++ b/conekta/models/create_company_request_fiscal_info.py
@@ -0,0 +1,90 @@
+# coding: utf-8
+
+"""
+ Conekta API
+
+ Conekta sdk
+
+ The version of the OpenAPI document: 2.2.0
+ Contact: engineering@conekta.com
+ Generated by OpenAPI Generator (https://openapi-generator.tech)
+
+ Do not edit the class manually.
+""" # noqa: E501
+
+
+from __future__ import annotations
+import pprint
+import re # noqa: F401
+import json
+
+from pydantic import BaseModel, ConfigDict, Field, StrictStr
+from typing import Any, ClassVar, Dict, List, Optional
+from typing import Optional, Set
+from typing_extensions import Self
+
+class CreateCompanyRequestFiscalInfo(BaseModel):
+ """
+ Fiscal information for the company.
+ """ # noqa: E501
+ business_phone: Optional[StrictStr] = Field(default=None, description="The business phone number for fiscal purposes.")
+ fiscal_type: Optional[StrictStr] = Field(default=None, description="The fiscal type of the company (e.g., 'moral', 'persona_fisica').")
+ __properties: ClassVar[List[str]] = ["business_phone", "fiscal_type"]
+
+ model_config = ConfigDict(
+ populate_by_name=True,
+ validate_assignment=True,
+ protected_namespaces=(),
+ )
+
+
+ def to_str(self) -> str:
+ """Returns the string representation of the model using alias"""
+ return pprint.pformat(self.model_dump(by_alias=True))
+
+ def to_json(self) -> str:
+ """Returns the JSON representation of the model using alias"""
+ # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead
+ return json.dumps(self.to_dict())
+
+ @classmethod
+ def from_json(cls, json_str: str) -> Optional[Self]:
+ """Create an instance of CreateCompanyRequestFiscalInfo from a JSON string"""
+ return cls.from_dict(json.loads(json_str))
+
+ def to_dict(self) -> Dict[str, Any]:
+ """Return the dictionary representation of the model using alias.
+
+ This has the following differences from calling pydantic's
+ `self.model_dump(by_alias=True)`:
+
+ * `None` is only added to the output dict for nullable fields that
+ were set at model initialization. Other fields with value `None`
+ are ignored.
+ """
+ excluded_fields: Set[str] = set([
+ ])
+
+ _dict = self.model_dump(
+ by_alias=True,
+ exclude=excluded_fields,
+ exclude_none=True,
+ )
+ return _dict
+
+ @classmethod
+ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ """Create an instance of CreateCompanyRequestFiscalInfo from a dict"""
+ if obj is None:
+ return None
+
+ if not isinstance(obj, dict):
+ return cls.model_validate(obj)
+
+ _obj = cls.model_validate({
+ "business_phone": obj.get("business_phone"),
+ "fiscal_type": obj.get("fiscal_type")
+ })
+ return _obj
+
+
diff --git a/conekta/models/payment_method_bnpl_request.py b/conekta/models/payment_method_bnpl_request.py
index 39c5bb6..39d776c 100644
--- a/conekta/models/payment_method_bnpl_request.py
+++ b/conekta/models/payment_method_bnpl_request.py
@@ -38,8 +38,8 @@ class PaymentMethodBnplRequest(BaseModel):
@field_validator('product_type')
def product_type_validate_enum(cls, value):
"""Validates the enum"""
- if value not in set(['klarna_bnpl', 'creditea_bnpl']):
- raise ValueError("must be one of enum values ('klarna_bnpl', 'creditea_bnpl')")
+ if value not in set(['aplazo_bnpl', 'creditea_bnpl']):
+ raise ValueError("must be one of enum values ('aplazo_bnpl', 'creditea_bnpl')")
return value
model_config = ConfigDict(
diff --git a/conekta/models/payment_method_spei_recurrent.py b/conekta/models/payment_method_spei_recurrent.py
index 18d72ff..346a482 100644
--- a/conekta/models/payment_method_spei_recurrent.py
+++ b/conekta/models/payment_method_spei_recurrent.py
@@ -18,7 +18,7 @@
import re # noqa: F401
import json
-from pydantic import BaseModel, ConfigDict, StrictInt, StrictStr
+from pydantic import BaseModel, ConfigDict, Field, StrictInt, StrictStr
from typing import Any, ClassVar, Dict, List, Optional
from typing import Optional, Set
from typing_extensions import Self
@@ -32,9 +32,10 @@ class PaymentMethodSpeiRecurrent(BaseModel):
object: StrictStr
created_at: StrictInt
parent_id: Optional[StrictStr] = None
+ bank: Optional[StrictStr] = Field(default=None, description="Bank name for the SPEI payment method")
reference: Optional[StrictStr] = None
expires_at: Optional[StrictStr] = None
- __properties: ClassVar[List[str]] = ["type", "id", "object", "created_at", "parent_id", "reference", "expires_at"]
+ __properties: ClassVar[List[str]] = ["type", "id", "object", "created_at", "parent_id", "bank", "reference", "expires_at"]
model_config = ConfigDict(
populate_by_name=True,
@@ -92,6 +93,7 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
"object": obj.get("object"),
"created_at": obj.get("created_at"),
"parent_id": obj.get("parent_id"),
+ "bank": obj.get("bank"),
"reference": obj.get("reference"),
"expires_at": obj.get("expires_at")
})
diff --git a/config-python.json b/config-python.json
index cdf3f21..df54493 100644
--- a/config-python.json
+++ b/config-python.json
@@ -7,14 +7,14 @@
"licenseName": "MIT License",
"licenseUrl": "https://www.opensource.org/licenses/mit-license.php",
"generateSourceCodeOnly": "false",
- "packageVersion": "7.0.1",
+ "packageVersion": "7.0.2",
"packageUrl": "https://github.com/conekta/conekta-python",
"projectName": "conekta",
"templateDir": "/local/templates/python",
"hasBearerMethods" : true,
"useOneOfDiscriminatorLookup" : true,
"nonCompliantUseDiscriminatorIfCompositionFails" : false,
- "httpUserAgent": "Conekta/v2 PythonBindings/7.0.1",
+ "httpUserAgent": "Conekta/v2 PythonBindings/7.0.2",
"files": {
"/local/AUTHORS.md" : {},
"/local/CODE_OF_CONDUCT.md": {},
diff --git a/docs/CheckoutRequest.md b/docs/CheckoutRequest.md
index c6fb3fa..046d175 100644
--- a/docs/CheckoutRequest.md
+++ b/docs/CheckoutRequest.md
@@ -7,7 +7,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**allowed_payment_methods** | **List[str]** | Are the payment methods available for this link. For subscriptions, only 'card' is allowed due to the recurring nature of the payments. |
-**plan_ids** | **List[str]** | List of plan IDs that will be available for subscription. This field is required for subscription payments but optional for other types of payments. |
+**plan_ids** | **List[str]** | List of plan IDs that will be available for subscription. This field is required for subscription payments. | [optional]
**expires_at** | **int** | Unix timestamp of checkout expiration | [optional]
**failure_url** | **str** | Redirection url back to the site in case of failed payment, applies only to HostedPayment. | [optional]
**monthly_installments_enabled** | **bool** | | [optional]
diff --git a/docs/CompaniesApi.md b/docs/CompaniesApi.md
index 3aca56e..4114f42 100644
--- a/docs/CompaniesApi.md
+++ b/docs/CompaniesApi.md
@@ -4,10 +4,95 @@ All URIs are relative to *https://api.conekta.io*
Method | HTTP request | Description
------------- | ------------- | -------------
+[**create_company**](CompaniesApi.md#create_company) | **POST** /companies | Create Company
[**get_companies**](CompaniesApi.md#get_companies) | **GET** /companies | Get List of Companies
[**get_company**](CompaniesApi.md#get_company) | **GET** /companies/{id} | Get Company
+[**get_company_documents**](CompaniesApi.md#get_company_documents) | **GET** /companies/{company_id}/documents | Get Company Documents
+[**update_company_document**](CompaniesApi.md#update_company_document) | **PATCH** /companies/{company_id}/document | Update Company Document
+[**upload_company_document**](CompaniesApi.md#upload_company_document) | **POST** /companies/{company_id}/document | Upload Company Document
+# **create_company**
+> CompanyResponse create_company(create_company_request)
+
+Create Company
+
+Create a new company.
+
+### Example
+
+* Bearer Authentication (bearerAuth):
+
+```python
+import conekta
+from conekta.models.company_response import CompanyResponse
+from conekta.models.create_company_request import CreateCompanyRequest
+from conekta.rest import ApiException
+from pprint import pprint
+
+# Defining the host is optional and defaults to https://api.conekta.io
+# See configuration.py for a list of all supported configuration parameters.
+configuration = conekta.Configuration(
+ host = "https://api.conekta.io"
+)
+
+# The client must configure the authentication and authorization parameters
+# in accordance with the API server security policy.
+# Examples for each auth method are provided below, use the example that
+# satisfies your auth use case.
+
+# Configure Bearer authorization: bearerAuth
+configuration = conekta.Configuration(
+ access_token = os.environ["BEARER_TOKEN"]
+)
+
+# Enter a context with an instance of the API client
+with conekta.ApiClient(configuration) as api_client:
+ # Create an instance of the API class
+ api_instance = conekta.CompaniesApi(api_client)
+ create_company_request = conekta.CreateCompanyRequest() # CreateCompanyRequest | Company data
+
+ try:
+ # Create Company
+ api_response = api_instance.create_company(create_company_request)
+ print("The response of CompaniesApi->create_company:\n")
+ pprint(api_response)
+ except Exception as e:
+ print("Exception when calling CompaniesApi->create_company: %s\n" % e)
+```
+
+
+
+### Parameters
+
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **create_company_request** | [**CreateCompanyRequest**](CreateCompanyRequest.md)| Company data |
+
+### Return type
+
+[**CompanyResponse**](CompanyResponse.md)
+
+### Authorization
+
+[bearerAuth](../README.md#bearerAuth)
+
+### HTTP request headers
+
+ - **Content-Type**: application/json
+ - **Accept**: application/vnd.conekta-v2.2.0+json
+
+### HTTP response details
+
+| Status code | Description | Response headers |
+|-------------|-------------|------------------|
+**201** | Company created successfully | * Date - The date and time that the response was sent
* Content-Type - The format of the response body
* Content-Length - The length of the response body in bytes
* Connection - The type of connection used to transfer the response
* Conekta-Media-Type -
|
+**401** | authentication error | - |
+**500** | internal server error | - |
+
+[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
+
# **get_companies**
> GetCompaniesResponse get_companies(accept_language=accept_language, limit=limit, search=search, next=next, previous=previous)
@@ -177,3 +262,258 @@ Name | Type | Description | Notes
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
+# **get_company_documents**
+> List[CompanyDocumentResponse] get_company_documents(company_id, accept_language=accept_language)
+
+Get Company Documents
+
+Retrieve a list of documents associated with a specific company.
+
+### Example
+
+* Bearer Authentication (bearerAuth):
+
+```python
+import conekta
+from conekta.models.company_document_response import CompanyDocumentResponse
+from conekta.rest import ApiException
+from pprint import pprint
+
+# Defining the host is optional and defaults to https://api.conekta.io
+# See configuration.py for a list of all supported configuration parameters.
+configuration = conekta.Configuration(
+ host = "https://api.conekta.io"
+)
+
+# The client must configure the authentication and authorization parameters
+# in accordance with the API server security policy.
+# Examples for each auth method are provided below, use the example that
+# satisfies your auth use case.
+
+# Configure Bearer authorization: bearerAuth
+configuration = conekta.Configuration(
+ access_token = os.environ["BEARER_TOKEN"]
+)
+
+# Enter a context with an instance of the API client
+with conekta.ApiClient(configuration) as api_client:
+ # Create an instance of the API class
+ api_instance = conekta.CompaniesApi(api_client)
+ company_id = '6307a60c41de27127515a575' # str | The unique identifier of the company.
+ accept_language = es # str | Use for knowing which language to use (optional) (default to es)
+
+ try:
+ # Get Company Documents
+ api_response = api_instance.get_company_documents(company_id, accept_language=accept_language)
+ print("The response of CompaniesApi->get_company_documents:\n")
+ pprint(api_response)
+ except Exception as e:
+ print("Exception when calling CompaniesApi->get_company_documents: %s\n" % e)
+```
+
+
+
+### Parameters
+
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **company_id** | **str**| The unique identifier of the company. |
+ **accept_language** | **str**| Use for knowing which language to use | [optional] [default to es]
+
+### Return type
+
+[**List[CompanyDocumentResponse]**](CompanyDocumentResponse.md)
+
+### Authorization
+
+[bearerAuth](../README.md#bearerAuth)
+
+### HTTP request headers
+
+ - **Content-Type**: Not defined
+ - **Accept**: application/vnd.conekta-v2.2.0+json
+
+### HTTP response details
+
+| Status code | Description | Response headers |
+|-------------|-------------|------------------|
+**200** | A list of documents for the company. | * Date - The date and time that the response was sent
* Content-Type - The format of the response body
* Content-Length - The length of the response body in bytes
* Connection - The type of connection used to transfer the response
* Conekta-Media-Type -
|
+**401** | authentication error | - |
+**404** | not found entity | - |
+**500** | internal server error | - |
+
+[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
+
+# **update_company_document**
+> CompanyDocumentResponse update_company_document(company_id, company_document_request, accept_language=accept_language)
+
+Update Company Document
+
+Updates an existing document associated with a specific company.
+
+### Example
+
+* Bearer Authentication (bearerAuth):
+
+```python
+import conekta
+from conekta.models.company_document_request import CompanyDocumentRequest
+from conekta.models.company_document_response import CompanyDocumentResponse
+from conekta.rest import ApiException
+from pprint import pprint
+
+# Defining the host is optional and defaults to https://api.conekta.io
+# See configuration.py for a list of all supported configuration parameters.
+configuration = conekta.Configuration(
+ host = "https://api.conekta.io"
+)
+
+# The client must configure the authentication and authorization parameters
+# in accordance with the API server security policy.
+# Examples for each auth method are provided below, use the example that
+# satisfies your auth use case.
+
+# Configure Bearer authorization: bearerAuth
+configuration = conekta.Configuration(
+ access_token = os.environ["BEARER_TOKEN"]
+)
+
+# Enter a context with an instance of the API client
+with conekta.ApiClient(configuration) as api_client:
+ # Create an instance of the API class
+ api_instance = conekta.CompaniesApi(api_client)
+ company_id = '6827206b1ec60400015eb09a' # str | The unique identifier of the company.
+ company_document_request = conekta.CompanyDocumentRequest() # CompanyDocumentRequest | Document information to update.
+ accept_language = es # str | Use for knowing which language to use (optional) (default to es)
+
+ try:
+ # Update Company Document
+ api_response = api_instance.update_company_document(company_id, company_document_request, accept_language=accept_language)
+ print("The response of CompaniesApi->update_company_document:\n")
+ pprint(api_response)
+ except Exception as e:
+ print("Exception when calling CompaniesApi->update_company_document: %s\n" % e)
+```
+
+
+
+### Parameters
+
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **company_id** | **str**| The unique identifier of the company. |
+ **company_document_request** | [**CompanyDocumentRequest**](CompanyDocumentRequest.md)| Document information to update. |
+ **accept_language** | **str**| Use for knowing which language to use | [optional] [default to es]
+
+### Return type
+
+[**CompanyDocumentResponse**](CompanyDocumentResponse.md)
+
+### Authorization
+
+[bearerAuth](../README.md#bearerAuth)
+
+### HTTP request headers
+
+ - **Content-Type**: application/json
+ - **Accept**: application/vnd.conekta-v2.2.0+json
+
+### HTTP response details
+
+| Status code | Description | Response headers |
+|-------------|-------------|------------------|
+**200** | Document updated successfully. | * Date - The date and time that the response was sent
* Content-Type - The format of the response body
* Content-Length - The length of the response body in bytes
* Connection - The type of connection used to transfer the response
* Conekta-Media-Type -
|
+**401** | authentication error | - |
+**404** | not found entity | - |
+**500** | internal server error | - |
+
+[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
+
+# **upload_company_document**
+> CompanyDocumentResponse upload_company_document(company_id, company_document_request, accept_language=accept_language)
+
+Upload Company Document
+
+Uploads a document associated with a specific company.
+
+### Example
+
+* Bearer Authentication (bearerAuth):
+
+```python
+import conekta
+from conekta.models.company_document_request import CompanyDocumentRequest
+from conekta.models.company_document_response import CompanyDocumentResponse
+from conekta.rest import ApiException
+from pprint import pprint
+
+# Defining the host is optional and defaults to https://api.conekta.io
+# See configuration.py for a list of all supported configuration parameters.
+configuration = conekta.Configuration(
+ host = "https://api.conekta.io"
+)
+
+# The client must configure the authentication and authorization parameters
+# in accordance with the API server security policy.
+# Examples for each auth method are provided below, use the example that
+# satisfies your auth use case.
+
+# Configure Bearer authorization: bearerAuth
+configuration = conekta.Configuration(
+ access_token = os.environ["BEARER_TOKEN"]
+)
+
+# Enter a context with an instance of the API client
+with conekta.ApiClient(configuration) as api_client:
+ # Create an instance of the API class
+ api_instance = conekta.CompaniesApi(api_client)
+ company_id = '6827206b1ec60400015eb09a' # str | The unique identifier of the company.
+ company_document_request = conekta.CompanyDocumentRequest() # CompanyDocumentRequest | Document information to upload.
+ accept_language = es # str | Use for knowing which language to use (optional) (default to es)
+
+ try:
+ # Upload Company Document
+ api_response = api_instance.upload_company_document(company_id, company_document_request, accept_language=accept_language)
+ print("The response of CompaniesApi->upload_company_document:\n")
+ pprint(api_response)
+ except Exception as e:
+ print("Exception when calling CompaniesApi->upload_company_document: %s\n" % e)
+```
+
+
+
+### Parameters
+
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **company_id** | **str**| The unique identifier of the company. |
+ **company_document_request** | [**CompanyDocumentRequest**](CompanyDocumentRequest.md)| Document information to upload. |
+ **accept_language** | **str**| Use for knowing which language to use | [optional] [default to es]
+
+### Return type
+
+[**CompanyDocumentResponse**](CompanyDocumentResponse.md)
+
+### Authorization
+
+[bearerAuth](../README.md#bearerAuth)
+
+### HTTP request headers
+
+ - **Content-Type**: application/json
+ - **Accept**: application/vnd.conekta-v2.2.0+json
+
+### HTTP response details
+
+| Status code | Description | Response headers |
+|-------------|-------------|------------------|
+**201** | Document uploaded successfully. | * Date - The date and time that the response was sent
* Content-Type - The format of the response body
* Content-Length - The length of the response body in bytes
* Connection - The type of connection used to transfer the response
* Conekta-Media-Type -
|
+**401** | authentication error | - |
+**404** | not found entity | - |
+**500** | internal server error | - |
+
+[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
+
diff --git a/docs/CompanyDocumentRequest.md b/docs/CompanyDocumentRequest.md
new file mode 100644
index 0000000..2234cdb
--- /dev/null
+++ b/docs/CompanyDocumentRequest.md
@@ -0,0 +1,34 @@
+# CompanyDocumentRequest
+
+Request body for uploading a company document.
+
+## Properties
+
+Name | Type | Description | Notes
+------------ | ------------- | ------------- | -------------
+**file_classification** | **str** | Classification of the document. | Tipo de archivo | Descripción | | :--------------------------- | :-------------------------------------------------------- | | `id_legal_representative` | identificación oficial frente | | `id_legal_representative_back` | identificación oficial atrás | | `cfdi` | Prueba de situación fiscal | | `constitutive_act_basic` | Acta constitutiva | | `proof_of_address` | Comprobante de domicilio del negocio | | `power_of_attonery` | Poderes de representación | | `deposit_account_cover` | Carátula de la cuenta de depósito | | `permit_casino` | Permiso ante SEGOB | | `license_sanitation` | Licencia sanitaria de COFEPRIS | | `registration_tourism` | Inscripción ante el Registro Nacional de Turismo (SECTUR) | |
+**content_type** | **str** | MIME type of the file. Allowed values depend on the `file_classification`. - `image/jpeg` - `image/png` - `application/pdf` |
+**international** | **bool** | Indicates if the document is international. Defaults to false. | [optional]
+**file_name** | **str** | Name of the file being uploaded. |
+**file_data** | **bytearray** | Base64 encoded content of the file. |
+
+## Example
+
+```python
+from conekta.models.company_document_request import CompanyDocumentRequest
+
+# TODO update the JSON string below
+json = "{}"
+# create an instance of CompanyDocumentRequest from a JSON string
+company_document_request_instance = CompanyDocumentRequest.from_json(json)
+# print the JSON string representation of the object
+print(CompanyDocumentRequest.to_json())
+
+# convert the object into a dict
+company_document_request_dict = company_document_request_instance.to_dict()
+# create an instance of CompanyDocumentRequest from a dict
+company_document_request_from_dict = CompanyDocumentRequest.from_dict(company_document_request_dict)
+```
+[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
+
+
diff --git a/docs/CompanyDocumentResponse.md b/docs/CompanyDocumentResponse.md
new file mode 100644
index 0000000..85ef16c
--- /dev/null
+++ b/docs/CompanyDocumentResponse.md
@@ -0,0 +1,32 @@
+# CompanyDocumentResponse
+
+Response body after uploading a company document.
+
+## Properties
+
+Name | Type | Description | Notes
+------------ | ------------- | ------------- | -------------
+**file_classification** | **str** | Classification of the document. | Tipo de archivo | Descripción | | :--------------------------- | :-------------------------------------------------------- | | `id_legal_representative` | identificación oficial frente | | `id_legal_representative_back` | identificación oficial atrás | | `cfdi` | Prueba de situación fiscal | | `constitutive_act_basic` | Acta constitutiva | | `proof_of_address` | Comprobante de domicilio del negocio | | `power_of_attonery` | Poderes de representación | | `deposit_account_cover` | Carátula de la cuenta de depósito | | `permit_casino` | Permiso ante SEGOB | | `license_sanitation` | Licencia sanitaria de COFEPRIS | | `registration_tourism` | Inscripción ante el Registro Nacional de Turismo (SECTUR) | |
+**file_name** | **str** | Name of the file as stored or processed. |
+**status** | **str** | Current status of the document. |
+
+## Example
+
+```python
+from conekta.models.company_document_response import CompanyDocumentResponse
+
+# TODO update the JSON string below
+json = "{}"
+# create an instance of CompanyDocumentResponse from a JSON string
+company_document_response_instance = CompanyDocumentResponse.from_json(json)
+# print the JSON string representation of the object
+print(CompanyDocumentResponse.to_json())
+
+# convert the object into a dict
+company_document_response_dict = company_document_response_instance.to_dict()
+# create an instance of CompanyDocumentResponse from a dict
+company_document_response_from_dict = CompanyDocumentResponse.from_dict(company_document_response_dict)
+```
+[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
+
+
diff --git a/docs/CompanyFiscalInfoAddressResponse.md b/docs/CompanyFiscalInfoAddressResponse.md
deleted file mode 100644
index a57161a..0000000
--- a/docs/CompanyFiscalInfoAddressResponse.md
+++ /dev/null
@@ -1,38 +0,0 @@
-# CompanyFiscalInfoAddressResponse
-
-Company fiscal info address model
-
-## Properties
-
-Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
-**object** | **str** | The resource's type | [optional]
-**street1** | **str** | Street Address | [optional]
-**street2** | **str** | Colonia | [optional]
-**city** | **str** | City | [optional]
-**state** | **str** | State | [optional]
-**country** | **str** | Country | [optional]
-**postal_code** | **str** | Postal code | [optional]
-**external_number** | **str** | Street number | [optional]
-**internal_number** | **str** | Unit / apartment number | [optional]
-
-## Example
-
-```python
-from conekta.models.company_fiscal_info_address_response import CompanyFiscalInfoAddressResponse
-
-# TODO update the JSON string below
-json = "{}"
-# create an instance of CompanyFiscalInfoAddressResponse from a JSON string
-company_fiscal_info_address_response_instance = CompanyFiscalInfoAddressResponse.from_json(json)
-# print the JSON string representation of the object
-print(CompanyFiscalInfoAddressResponse.to_json())
-
-# convert the object into a dict
-company_fiscal_info_address_response_dict = company_fiscal_info_address_response_instance.to_dict()
-# create an instance of CompanyFiscalInfoAddressResponse from a dict
-company_fiscal_info_address_response_from_dict = CompanyFiscalInfoAddressResponse.from_dict(company_fiscal_info_address_response_dict)
-```
-[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
-
-
diff --git a/docs/CompanyFiscalInfoResponse.md b/docs/CompanyFiscalInfoResponse.md
deleted file mode 100644
index 3c95cc9..0000000
--- a/docs/CompanyFiscalInfoResponse.md
+++ /dev/null
@@ -1,36 +0,0 @@
-# CompanyFiscalInfoResponse
-
-Company fiscal info model
-
-## Properties
-
-Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
-**object** | **str** | The resource's type | [optional]
-**tax_id** | **str** | Tax ID of the company | [optional]
-**legal_entity_name** | **str** | Legal name of the company | [optional]
-**business_type** | **str** | Business type of the company | [optional]
-**phone** | **str** | Phone number of the company | [optional]
-**physical_person_business_type** | **str** | Business type if 'persona_fisica' | [optional]
-**address** | [**CompanyFiscalInfoAddressResponse**](CompanyFiscalInfoAddressResponse.md) | | [optional]
-
-## Example
-
-```python
-from conekta.models.company_fiscal_info_response import CompanyFiscalInfoResponse
-
-# TODO update the JSON string below
-json = "{}"
-# create an instance of CompanyFiscalInfoResponse from a JSON string
-company_fiscal_info_response_instance = CompanyFiscalInfoResponse.from_json(json)
-# print the JSON string representation of the object
-print(CompanyFiscalInfoResponse.to_json())
-
-# convert the object into a dict
-company_fiscal_info_response_dict = company_fiscal_info_response_instance.to_dict()
-# create an instance of CompanyFiscalInfoResponse from a dict
-company_fiscal_info_response_from_dict = CompanyFiscalInfoResponse.from_dict(company_fiscal_info_response_dict)
-```
-[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
-
-
diff --git a/docs/CompanyPayoutDestinationResponse.md b/docs/CompanyPayoutDestinationResponse.md
deleted file mode 100644
index 9997c58..0000000
--- a/docs/CompanyPayoutDestinationResponse.md
+++ /dev/null
@@ -1,35 +0,0 @@
-# CompanyPayoutDestinationResponse
-
-Company payout destination model
-
-## Properties
-
-Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
-**object** | **str** | The resource's type | [optional]
-**currency** | **str** | currency of the receiving account | [optional]
-**account_holder_name** | **str** | Name of the account holder | [optional]
-**bank** | **str** | Name of the bank | [optional]
-**type** | **str** | Type of the payout destination | [optional]
-**account_number** | **str** | Account number of the receiving account | [optional]
-
-## Example
-
-```python
-from conekta.models.company_payout_destination_response import CompanyPayoutDestinationResponse
-
-# TODO update the JSON string below
-json = "{}"
-# create an instance of CompanyPayoutDestinationResponse from a JSON string
-company_payout_destination_response_instance = CompanyPayoutDestinationResponse.from_json(json)
-# print the JSON string representation of the object
-print(CompanyPayoutDestinationResponse.to_json())
-
-# convert the object into a dict
-company_payout_destination_response_dict = company_payout_destination_response_instance.to_dict()
-# create an instance of CompanyPayoutDestinationResponse from a dict
-company_payout_destination_response_from_dict = CompanyPayoutDestinationResponse.from_dict(company_payout_destination_response_dict)
-```
-[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
-
-
diff --git a/docs/CompanyResponse.md b/docs/CompanyResponse.md
index c1c7427..a5cfb43 100644
--- a/docs/CompanyResponse.md
+++ b/docs/CompanyResponse.md
@@ -1,19 +1,19 @@
# CompanyResponse
-Company model
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**id** | **str** | The child company's unique identifier | [optional]
-**created_at** | **int** | The resource's creation date (unix timestamp) | [optional]
-**name** | **str** | The child company's name | [optional]
-**object** | **str** | The resource's type | [optional]
-**parent_company_id** | **str** | Id of the parent company | [optional]
-**use_parent_fiscal_data** | **bool** | Whether the parent company's fiscal data is to be used for liquidation and tax purposes | [optional]
-**payout_destination** | [**CompanyPayoutDestinationResponse**](CompanyPayoutDestinationResponse.md) | | [optional]
-**fiscal_info** | [**CompanyFiscalInfoResponse**](CompanyFiscalInfoResponse.md) | | [optional]
+**id** | **str** | The unique identifier for the company. |
+**name** | **str** | The name of the company. |
+**active** | **bool** | Indicates if the company is active. |
+**account_status** | **str** | The current status of the company's account. |
+**parent_company_id** | **str** | The identifier of the parent company, if any. | [optional]
+**onboarding_status** | **str** | The current status of the company's onboarding process. |
+**documents** | [**List[CompanyResponseDocumentsInner]**](CompanyResponseDocumentsInner.md) | A list of documents related to the company. |
+**created_at** | **int** | Timestamp of when the company was created. |
+**object** | **str** | The type of object, typically \"company\". |
## Example
diff --git a/docs/CompanyResponseDocumentsInner.md b/docs/CompanyResponseDocumentsInner.md
new file mode 100644
index 0000000..d15fead
--- /dev/null
+++ b/docs/CompanyResponseDocumentsInner.md
@@ -0,0 +1,31 @@
+# CompanyResponseDocumentsInner
+
+
+## Properties
+
+Name | Type | Description | Notes
+------------ | ------------- | ------------- | -------------
+**file_classification** | **str** | Classification of the document. | Tipo de archivo | Descripción | | :--------------------------- | :-------------------------------------------------------- | | `id_legal_representative` | identificación oficial frente | | `id_legal_representative_back` | identificación oficial atrás | | `cfdi` | Prueba de situación fiscal | | `constitutive_act_basic` | Acta constitutiva | | `proof_of_address` | Comprobante de domicilio del negocio | | `power_of_attonery` | Poderes de representación | | `deposit_account_cover` | Carátula de la cuenta de depósito | | `permit_casino` | Permiso ante SEGOB | | `license_sanitation` | Licencia sanitaria de COFEPRIS | | `registration_tourism` | Inscripción ante el Registro Nacional de Turismo (SECTUR) | | [optional]
+**status** | **str** | The status of the document. | [optional]
+**file_name** | **str** | The name of the file. | [optional]
+
+## Example
+
+```python
+from conekta.models.company_response_documents_inner import CompanyResponseDocumentsInner
+
+# TODO update the JSON string below
+json = "{}"
+# create an instance of CompanyResponseDocumentsInner from a JSON string
+company_response_documents_inner_instance = CompanyResponseDocumentsInner.from_json(json)
+# print the JSON string representation of the object
+print(CompanyResponseDocumentsInner.to_json())
+
+# convert the object into a dict
+company_response_documents_inner_dict = company_response_documents_inner_instance.to_dict()
+# create an instance of CompanyResponseDocumentsInner from a dict
+company_response_documents_inner_from_dict = CompanyResponseDocumentsInner.from_dict(company_response_documents_inner_dict)
+```
+[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
+
+
diff --git a/docs/CreateCompanyRequest.md b/docs/CreateCompanyRequest.md
new file mode 100644
index 0000000..27ff671
--- /dev/null
+++ b/docs/CreateCompanyRequest.md
@@ -0,0 +1,33 @@
+# CreateCompanyRequest
+
+
+## Properties
+
+Name | Type | Description | Notes
+------------ | ------------- | ------------- | -------------
+**name** | **str** | The name of the company. | [optional]
+**type_company** | **str** | The type of company, 'owner' | [optional]
+**comercial_info** | [**CreateCompanyRequestComercialInfo**](CreateCompanyRequestComercialInfo.md) | | [optional]
+**fiscal_info** | [**CreateCompanyRequestFiscalInfo**](CreateCompanyRequestFiscalInfo.md) | | [optional]
+**bank_account_info** | [**CreateCompanyRequestBankAccountInfo**](CreateCompanyRequestBankAccountInfo.md) | | [optional]
+
+## Example
+
+```python
+from conekta.models.create_company_request import CreateCompanyRequest
+
+# TODO update the JSON string below
+json = "{}"
+# create an instance of CreateCompanyRequest from a JSON string
+create_company_request_instance = CreateCompanyRequest.from_json(json)
+# print the JSON string representation of the object
+print(CreateCompanyRequest.to_json())
+
+# convert the object into a dict
+create_company_request_dict = create_company_request_instance.to_dict()
+# create an instance of CreateCompanyRequest from a dict
+create_company_request_from_dict = CreateCompanyRequest.from_dict(create_company_request_dict)
+```
+[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
+
+
diff --git a/docs/CreateCompanyRequestBankAccountInfo.md b/docs/CreateCompanyRequestBankAccountInfo.md
new file mode 100644
index 0000000..ed21515
--- /dev/null
+++ b/docs/CreateCompanyRequestBankAccountInfo.md
@@ -0,0 +1,30 @@
+# CreateCompanyRequestBankAccountInfo
+
+Bank account information for the company.
+
+## Properties
+
+Name | Type | Description | Notes
+------------ | ------------- | ------------- | -------------
+**clabe** | **str** | The 18-digit CLABE for the bank account. | [optional]
+
+## Example
+
+```python
+from conekta.models.create_company_request_bank_account_info import CreateCompanyRequestBankAccountInfo
+
+# TODO update the JSON string below
+json = "{}"
+# create an instance of CreateCompanyRequestBankAccountInfo from a JSON string
+create_company_request_bank_account_info_instance = CreateCompanyRequestBankAccountInfo.from_json(json)
+# print the JSON string representation of the object
+print(CreateCompanyRequestBankAccountInfo.to_json())
+
+# convert the object into a dict
+create_company_request_bank_account_info_dict = create_company_request_bank_account_info_instance.to_dict()
+# create an instance of CreateCompanyRequestBankAccountInfo from a dict
+create_company_request_bank_account_info_from_dict = CreateCompanyRequestBankAccountInfo.from_dict(create_company_request_bank_account_info_dict)
+```
+[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
+
+
diff --git a/docs/CreateCompanyRequestComercialInfo.md b/docs/CreateCompanyRequestComercialInfo.md
new file mode 100644
index 0000000..60d7b7b
--- /dev/null
+++ b/docs/CreateCompanyRequestComercialInfo.md
@@ -0,0 +1,33 @@
+# CreateCompanyRequestComercialInfo
+
+Commercial information for the company.
+
+## Properties
+
+Name | Type | Description | Notes
+------------ | ------------- | ------------- | -------------
+**website** | **str** | The company's website URL. | [optional]
+**mcc** | **str** | The Merchant Category Code (MCC) for the company. | [optional]
+**merchant_support_email** | **str** | Email address for merchant support. | [optional]
+**merchant_support_phone** | **str** | Phone number for merchant support. | [optional]
+
+## Example
+
+```python
+from conekta.models.create_company_request_comercial_info import CreateCompanyRequestComercialInfo
+
+# TODO update the JSON string below
+json = "{}"
+# create an instance of CreateCompanyRequestComercialInfo from a JSON string
+create_company_request_comercial_info_instance = CreateCompanyRequestComercialInfo.from_json(json)
+# print the JSON string representation of the object
+print(CreateCompanyRequestComercialInfo.to_json())
+
+# convert the object into a dict
+create_company_request_comercial_info_dict = create_company_request_comercial_info_instance.to_dict()
+# create an instance of CreateCompanyRequestComercialInfo from a dict
+create_company_request_comercial_info_from_dict = CreateCompanyRequestComercialInfo.from_dict(create_company_request_comercial_info_dict)
+```
+[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
+
+
diff --git a/docs/CreateCompanyRequestFiscalInfo.md b/docs/CreateCompanyRequestFiscalInfo.md
new file mode 100644
index 0000000..9678765
--- /dev/null
+++ b/docs/CreateCompanyRequestFiscalInfo.md
@@ -0,0 +1,31 @@
+# CreateCompanyRequestFiscalInfo
+
+Fiscal information for the company.
+
+## Properties
+
+Name | Type | Description | Notes
+------------ | ------------- | ------------- | -------------
+**business_phone** | **str** | The business phone number for fiscal purposes. | [optional]
+**fiscal_type** | **str** | The fiscal type of the company (e.g., 'moral', 'persona_fisica'). | [optional]
+
+## Example
+
+```python
+from conekta.models.create_company_request_fiscal_info import CreateCompanyRequestFiscalInfo
+
+# TODO update the JSON string below
+json = "{}"
+# create an instance of CreateCompanyRequestFiscalInfo from a JSON string
+create_company_request_fiscal_info_instance = CreateCompanyRequestFiscalInfo.from_json(json)
+# print the JSON string representation of the object
+print(CreateCompanyRequestFiscalInfo.to_json())
+
+# convert the object into a dict
+create_company_request_fiscal_info_dict = create_company_request_fiscal_info_instance.to_dict()
+# create an instance of CreateCompanyRequestFiscalInfo from a dict
+create_company_request_fiscal_info_from_dict = CreateCompanyRequestFiscalInfo.from_dict(create_company_request_fiscal_info_dict)
+```
+[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
+
+
diff --git a/docs/CreateCustomerPaymentMethodsResponse.md b/docs/CreateCustomerPaymentMethodsResponse.md
index 6922cdd..6e93d1e 100644
--- a/docs/CreateCustomerPaymentMethodsResponse.md
+++ b/docs/CreateCustomerPaymentMethodsResponse.md
@@ -26,6 +26,7 @@ Name | Type | Description | Notes
**default** | **bool** | | [optional]
**visible_on_checkout** | **bool** | | [optional]
**payment_source_status** | **str** | | [optional]
+**bank** | **str** | Bank name for the SPEI payment method | [optional]
## Example
diff --git a/docs/CustomerPaymentMethodsData.md b/docs/CustomerPaymentMethodsData.md
index 7b155c6..f64d063 100644
--- a/docs/CustomerPaymentMethodsData.md
+++ b/docs/CustomerPaymentMethodsData.md
@@ -26,6 +26,7 @@ Name | Type | Description | Notes
**default** | **bool** | | [optional]
**visible_on_checkout** | **bool** | | [optional]
**payment_source_status** | **str** | | [optional]
+**bank** | **str** | Bank name for the SPEI payment method | [optional]
## Example
diff --git a/docs/GetCustomerPaymentMethodDataResponse.md b/docs/GetCustomerPaymentMethodDataResponse.md
index 431d21d..ef03375 100644
--- a/docs/GetCustomerPaymentMethodDataResponse.md
+++ b/docs/GetCustomerPaymentMethodDataResponse.md
@@ -26,6 +26,7 @@ Name | Type | Description | Notes
**default** | **bool** | | [optional]
**visible_on_checkout** | **bool** | | [optional]
**payment_source_status** | **str** | | [optional]
+**bank** | **str** | Bank name for the SPEI payment method | [optional]
## Example
diff --git a/docs/PaymentMethodSpeiRecurrent.md b/docs/PaymentMethodSpeiRecurrent.md
index 31f3e44..88301bf 100644
--- a/docs/PaymentMethodSpeiRecurrent.md
+++ b/docs/PaymentMethodSpeiRecurrent.md
@@ -10,6 +10,7 @@ Name | Type | Description | Notes
**object** | **str** | |
**created_at** | **int** | |
**parent_id** | **str** | | [optional]
+**bank** | **str** | Bank name for the SPEI payment method | [optional]
**reference** | **str** | | [optional]
**expires_at** | **str** | | [optional]
diff --git a/docs/UpdateCustomerPaymentMethodsResponse.md b/docs/UpdateCustomerPaymentMethodsResponse.md
index ccfa142..1dcb43f 100644
--- a/docs/UpdateCustomerPaymentMethodsResponse.md
+++ b/docs/UpdateCustomerPaymentMethodsResponse.md
@@ -26,6 +26,7 @@ Name | Type | Description | Notes
**default** | **bool** | | [optional]
**visible_on_checkout** | **bool** | | [optional]
**payment_source_status** | **str** | | [optional]
+**bank** | **str** | Bank name for the SPEI payment method | [optional]
## Example
diff --git a/examples/one_time_charge_bnpl.py b/examples/one_time_charge_bnpl.py
new file mode 100644
index 0000000..6a44481
--- /dev/null
+++ b/examples/one_time_charge_bnpl.py
@@ -0,0 +1,62 @@
+
+import time
+import os
+import conekta
+from conekta.rest import ApiException
+from pprint import pprint
+
+# The client must configure the authentication and authorization parameters
+# in accordance with the API server security policy.
+# Examples for each auth method are provided below, use the example that
+# satisfies your auth use case.
+
+# Configure Bearer authorization: bearerAuth
+configuration = conekta.Configuration(
+ access_token = os.environ["CONEKTA_PRIVATE_API_KEY"]
+)
+
+
+# Enter a context with an instance of the API client
+with conekta.ApiClient(configuration) as api_client:
+ # Create an instance of the API class
+ api_instance = conekta.OrdersApi(api_client)
+ order = conekta.OrderRequest(
+ line_items=[
+ conekta.Product(
+ name='Test Product',
+ quantity=1,
+ unit_price=10000
+ )
+ ],
+ customer_info=conekta.OrderRequestCustomerInfo(
+ conekta.CustomerInfo(
+ name='John Doe',
+ email='john.doe@example.com',
+ phone='555-555-5555'
+ )
+ ),
+ currency='MXN',
+ charges=[
+ conekta.ChargeRequest(
+ payment_method=conekta.ChargeRequestPaymentMethod(
+ oneof_schema_1_validator=conekta.PaymentMethodBnplRequest(
+ product_type='aplazo_bnpl',
+ type= 'bnpl',
+ success_url= 'https://www.example.com/success',
+ failure_url= 'https://www.example.com/failure',
+ cancel_url= 'https://www.example.com/cancel',
+ )
+ )
+ )
+ ]
+
+ )
+ accept_language = 'es' # str | Use for knowing which language to use (optional) (default to 'es')
+
+ try:
+ # Create order
+ api_response = api_instance.create_order(order, accept_language=accept_language)
+ print("The response of OrdersApi->create_order:\n")
+ pprint(api_response)
+ except ApiException as e:
+ print("Exception when calling OrdersApi->create_order: %s\n" % e)
diff --git a/pyproject.toml b/pyproject.toml
index d4ad3ab..74a24f7 100644
--- a/pyproject.toml
+++ b/pyproject.toml
@@ -1,6 +1,6 @@
[tool.poetry]
name = "conekta"
-version = "7.0.1"
+version = "7.0.2"
description = "Conekta API"
authors = ["Engineering Conekta "]
license = "MIT-LICENSE"
diff --git a/setup.py b/setup.py
index 621a22b..79d34fd 100644
--- a/setup.py
+++ b/setup.py
@@ -22,7 +22,7 @@
# prerequisite: setuptools
# http://pypi.python.org/pypi/setuptools
NAME = "conekta"
-VERSION = "7.0.1"
+VERSION = "7.0.2"
PYTHON_REQUIRES = ">= 3.8"
REQUIRES = [
"urllib3 >= 1.25.3, < 3.0.0",
diff --git a/test/test_companies_api.py b/test/test_companies_api.py
index 056d4e5..6498a78 100644
--- a/test/test_companies_api.py
+++ b/test/test_companies_api.py
@@ -27,6 +27,13 @@ def setUp(self) -> None:
def tearDown(self) -> None:
pass
+ def test_create_company(self) -> None:
+ """Test case for create_company
+
+ Create Company
+ """
+ pass
+
def test_get_companies(self) -> None:
"""Test case for get_companies
@@ -41,6 +48,27 @@ def test_get_company(self) -> None:
"""
pass
+ def test_get_company_documents(self) -> None:
+ """Test case for get_company_documents
+
+ Get Company Documents
+ """
+ pass
+
+ def test_update_company_document(self) -> None:
+ """Test case for update_company_document
+
+ Update Company Document
+ """
+ pass
+
+ def test_upload_company_document(self) -> None:
+ """Test case for upload_company_document
+
+ Upload Company Document
+ """
+ pass
+
if __name__ == '__main__':
unittest.main()