@pronesoft-rd/ecf-sdk 0.0.1 → 0.0.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.openapi-generator/FILES +104 -2
- package/README.md +90 -24
- package/dist/apis/AssociatedCompaniesApi.d.ts +195 -40
- package/dist/apis/AssociatedCompaniesApi.js +252 -23
- package/dist/apis/AuthenticationApi.d.ts +11 -11
- package/dist/apis/AuthenticationApi.js +7 -7
- package/dist/apis/AutomatedCertificationApi.d.ts +164 -0
- package/dist/apis/AutomatedCertificationApi.js +232 -0
- package/dist/apis/CommercialApprovalsApi.d.ts +120 -0
- package/dist/apis/CommercialApprovalsApi.js +141 -0
- package/dist/apis/DigitalCertificatesApi.d.ts +17 -17
- package/dist/apis/DigitalCertificatesApi.js +7 -7
- package/dist/apis/DocumentsReceivedApi.d.ts +117 -0
- package/dist/apis/DocumentsReceivedApi.js +152 -0
- package/dist/apis/DocumentsSentApi.d.ts +216 -0
- package/dist/apis/DocumentsSentApi.js +286 -0
- package/dist/apis/ECFSubmissionApi.d.ts +130 -13
- package/dist/apis/ECFSubmissionApi.js +168 -8
- package/dist/apis/ReportsApi.d.ts +143 -0
- package/dist/apis/ReportsApi.js +193 -0
- package/dist/apis/TaxSequencesApi.d.ts +120 -38
- package/dist/apis/TaxSequencesApi.js +129 -22
- package/dist/apis/WebhookConfigurationApi.d.ts +60 -53
- package/dist/apis/WebhookConfigurationApi.js +49 -41
- package/dist/apis/index.d.ts +5 -0
- package/dist/apis/index.js +5 -0
- package/dist/esm/apis/AssociatedCompaniesApi.d.ts +195 -40
- package/dist/esm/apis/AssociatedCompaniesApi.js +253 -24
- package/dist/esm/apis/AuthenticationApi.d.ts +11 -11
- package/dist/esm/apis/AuthenticationApi.js +7 -7
- package/dist/esm/apis/AutomatedCertificationApi.d.ts +164 -0
- package/dist/esm/apis/AutomatedCertificationApi.js +228 -0
- package/dist/esm/apis/CommercialApprovalsApi.d.ts +120 -0
- package/dist/esm/apis/CommercialApprovalsApi.js +137 -0
- package/dist/esm/apis/DigitalCertificatesApi.d.ts +17 -17
- package/dist/esm/apis/DigitalCertificatesApi.js +7 -7
- package/dist/esm/apis/DocumentsReceivedApi.d.ts +117 -0
- package/dist/esm/apis/DocumentsReceivedApi.js +148 -0
- package/dist/esm/apis/DocumentsSentApi.d.ts +216 -0
- package/dist/esm/apis/DocumentsSentApi.js +282 -0
- package/dist/esm/apis/ECFSubmissionApi.d.ts +130 -13
- package/dist/esm/apis/ECFSubmissionApi.js +169 -9
- package/dist/esm/apis/ReportsApi.d.ts +143 -0
- package/dist/esm/apis/ReportsApi.js +189 -0
- package/dist/esm/apis/TaxSequencesApi.d.ts +120 -38
- package/dist/esm/apis/TaxSequencesApi.js +130 -23
- package/dist/esm/apis/WebhookConfigurationApi.d.ts +60 -53
- package/dist/esm/apis/WebhookConfigurationApi.js +49 -41
- package/dist/esm/apis/index.d.ts +5 -0
- package/dist/esm/apis/index.js +5 -0
- package/dist/esm/models/AccountType.d.ts +4 -8
- package/dist/esm/models/AccountType.js +4 -8
- package/dist/esm/models/AdditionalInfo.d.ts +60 -12
- package/dist/esm/models/AdditionalInfo.js +23 -7
- package/dist/esm/models/AlternativeCurrency.d.ts +78 -8
- package/dist/esm/models/AlternativeCurrency.js +27 -3
- package/dist/esm/models/ApprovalItem.d.ts +74 -0
- package/dist/esm/models/ApprovalItem.js +55 -0
- package/dist/esm/models/ApprovalListResponse.d.ts +40 -0
- package/dist/esm/models/ApprovalListResponse.js +45 -0
- package/dist/esm/models/AssociatedCompany.d.ts +33 -14
- package/dist/esm/models/AssociatedCompany.js +18 -11
- package/dist/esm/models/AssociatedCompanySubscription.d.ts +5 -5
- package/dist/esm/models/AssociatedCompanySubscription.js +3 -3
- package/dist/esm/models/AssociatedCompanySubscriptionPlan.d.ts +4 -4
- package/dist/esm/models/AssociatedCompanySubscriptionPlan.js +3 -3
- package/dist/esm/models/BillingIndicator.d.ts +4 -10
- package/dist/esm/models/BillingIndicator.js +4 -10
- package/dist/esm/models/Buyer.d.ts +71 -11
- package/dist/esm/models/Buyer.js +23 -3
- package/dist/esm/models/CertificationNiche.d.ts +51 -0
- package/dist/esm/models/CertificationNiche.js +48 -0
- package/dist/esm/models/CertificationNicheNicheItemsInner.d.ts +38 -0
- package/dist/esm/models/CertificationNicheNicheItemsInner.js +43 -0
- package/dist/esm/models/CertificationStatus.d.ts +54 -0
- package/dist/esm/models/CertificationStatus.js +54 -0
- package/dist/esm/models/CompanyDocumentMetrics.d.ts +53 -0
- package/dist/esm/models/CompanyDocumentMetrics.js +50 -0
- package/dist/esm/models/CompanyDocumentMetricsGroupByStatusInner.d.ts +39 -0
- package/dist/esm/models/CompanyDocumentMetricsGroupByStatusInner.js +44 -0
- package/dist/esm/models/CompanyDocumentMetricsGroupByStatusInnerCount.d.ts +32 -0
- package/dist/esm/models/CompanyDocumentMetricsGroupByStatusInnerCount.js +41 -0
- package/dist/esm/models/CompanyDocumentMetricsMainBusiness.d.ts +44 -0
- package/dist/esm/models/CompanyDocumentMetricsMainBusiness.js +45 -0
- package/dist/esm/models/CompanyDocumentMetricsTotals.d.ts +38 -0
- package/dist/esm/models/CompanyDocumentMetricsTotals.js +43 -0
- package/dist/esm/models/CompanyMetrics.d.ts +81 -0
- package/dist/esm/models/CompanyMetrics.js +58 -0
- package/dist/esm/models/CompanyMetricsDocumentsStatus.d.ts +44 -0
- package/dist/esm/models/CompanyMetricsDocumentsStatus.js +45 -0
- package/dist/esm/models/CreateAssociatedCompany201Response.d.ts +3 -3
- package/dist/esm/models/CreateAssociatedCompany201Response.js +3 -3
- package/dist/esm/models/CreateTaxSequence201Response.d.ts +39 -0
- package/dist/esm/models/CreateTaxSequence201Response.js +44 -0
- package/dist/esm/models/CreateTaxSequenceRequest.d.ts +27 -10
- package/dist/esm/models/CreateTaxSequenceRequest.js +13 -6
- package/dist/esm/models/DeleteAssociatedCompany200Response.d.ts +32 -0
- package/dist/esm/models/DeleteAssociatedCompany200Response.js +41 -0
- package/dist/esm/models/DiscountOrSurcharge.d.ts +31 -19
- package/dist/esm/models/DiscountOrSurcharge.js +16 -7
- package/dist/esm/models/DocumentStatsResponse.d.ts +54 -0
- package/dist/esm/models/DocumentStatsResponse.js +47 -0
- package/dist/esm/models/DocumentStatus.d.ts +28 -0
- package/dist/esm/models/DocumentStatus.js +46 -0
- package/dist/esm/models/EcfHistoryItem.d.ts +83 -0
- package/dist/esm/models/EcfHistoryItem.js +60 -0
- package/dist/esm/models/EcfStatsResponse.d.ts +80 -0
- package/dist/esm/models/EcfStatsResponse.js +57 -0
- package/dist/esm/models/EcfStatusResponse.d.ts +110 -0
- package/dist/esm/models/EcfStatusResponse.js +74 -0
- package/dist/esm/models/EcfStatusResponseMensajesInner.d.ts +38 -0
- package/dist/esm/models/EcfStatusResponseMensajesInner.js +43 -0
- package/dist/esm/models/EcfSubmissionResponse.d.ts +68 -11
- package/dist/esm/models/EcfSubmissionResponse.js +25 -8
- package/dist/esm/models/EcfSubmissionResponseDgiiResponse.d.ts +50 -0
- package/dist/esm/models/EcfSubmissionResponseDgiiResponse.js +47 -0
- package/dist/esm/models/ElectronicDocument.d.ts +166 -64
- package/dist/esm/models/ElectronicDocument.js +66 -22
- package/dist/esm/models/Environment.d.ts +4 -8
- package/dist/esm/models/Environment.js +4 -8
- package/dist/esm/models/ErrorResponse.d.ts +13 -7
- package/dist/esm/models/ErrorResponse.js +5 -3
- package/dist/esm/models/GetNextNumber200Response.d.ts +3 -3
- package/dist/esm/models/GetNextNumber200Response.js +3 -3
- package/dist/esm/models/GetNextNumber200ResponseData.d.ts +11 -5
- package/dist/esm/models/GetNextNumber200ResponseData.js +5 -3
- package/dist/esm/models/InvoiceType.d.ts +6 -14
- package/dist/esm/models/InvoiceType.js +6 -14
- package/dist/esm/models/InvoiceTypeSequence.d.ts +33 -0
- package/dist/esm/models/InvoiceTypeSequence.js +51 -0
- package/dist/esm/models/Item.d.ts +118 -21
- package/dist/esm/models/Item.js +45 -9
- package/dist/esm/models/ItemAdditionalTax.d.ts +7 -7
- package/dist/esm/models/ItemAdditionalTax.js +4 -6
- package/dist/esm/models/ItemAlternativeCurrency.d.ts +50 -0
- package/dist/esm/models/ItemAlternativeCurrency.js +47 -0
- package/dist/esm/models/ItemCodesInner.d.ts +38 -0
- package/dist/esm/models/ItemCodesInner.js +43 -0
- package/dist/esm/models/ItemDiscountInner.d.ts +44 -0
- package/dist/esm/models/ItemDiscountInner.js +45 -0
- package/dist/esm/models/ItemMiningInfo.d.ts +50 -0
- package/dist/esm/models/ItemMiningInfo.js +47 -0
- package/dist/esm/models/ListTaxSequences200Response.d.ts +10 -3
- package/dist/esm/models/ListTaxSequences200Response.js +6 -3
- package/dist/esm/models/OAuthTokenRequest.d.ts +6 -11
- package/dist/esm/models/OAuthTokenRequest.js +3 -3
- package/dist/esm/models/OAuthTokenResponse.d.ts +7 -9
- package/dist/esm/models/OAuthTokenResponse.js +3 -3
- package/dist/esm/models/Page.d.ts +15 -15
- package/dist/esm/models/Page.js +10 -16
- package/dist/esm/models/PaginationMeta.d.ts +50 -0
- package/dist/esm/models/PaginationMeta.js +47 -0
- package/dist/esm/models/PaymentForm.d.ts +39 -0
- package/dist/esm/models/PaymentForm.js +48 -0
- package/dist/esm/models/PaymentMethod.d.ts +4 -13
- package/dist/esm/models/PaymentMethod.js +4 -13
- package/dist/esm/models/PrintFormat.d.ts +3 -7
- package/dist/esm/models/PrintFormat.js +3 -7
- package/dist/esm/models/ProcessingLog.d.ts +54 -0
- package/dist/esm/models/ProcessingLog.js +54 -0
- package/dist/esm/models/RateLimitErrorResponse.d.ts +50 -0
- package/dist/esm/models/RateLimitErrorResponse.js +47 -0
- package/dist/esm/models/ReceivedDocument.d.ts +81 -0
- package/dist/esm/models/ReceivedDocument.js +58 -0
- package/dist/esm/models/ReceivedDocumentListResponse.d.ts +46 -0
- package/dist/esm/models/ReceivedDocumentListResponse.js +47 -0
- package/dist/esm/models/ReceivedDocumentStatsResponse.d.ts +46 -0
- package/dist/esm/models/ReceivedDocumentStatsResponse.js +45 -0
- package/dist/esm/models/ReferenceInfo.d.ts +9 -18
- package/dist/esm/models/ReferenceInfo.js +4 -4
- package/dist/esm/models/SentDocumentDetail.d.ts +107 -0
- package/dist/esm/models/SentDocumentDetail.js +68 -0
- package/dist/esm/models/SentDocumentListResponse.d.ts +46 -0
- package/dist/esm/models/SentDocumentListResponse.js +47 -0
- package/dist/esm/models/SentDocumentSummary.d.ts +94 -0
- package/dist/esm/models/SentDocumentSummary.js +63 -0
- package/dist/esm/models/SentDocumentSummaryBusiness.d.ts +38 -0
- package/dist/esm/models/SentDocumentSummaryBusiness.js +43 -0
- package/dist/esm/models/StartCertification200Response.d.ts +32 -0
- package/dist/esm/models/StartCertification200Response.js +41 -0
- package/dist/esm/models/StartCertificationRequest.d.ts +51 -0
- package/dist/esm/models/StartCertificationRequest.js +54 -0
- package/dist/esm/models/Subquantity.d.ts +6 -6
- package/dist/esm/models/Subquantity.js +3 -3
- package/dist/esm/models/Subtotal.d.ts +18 -12
- package/dist/esm/models/Subtotal.js +8 -10
- package/dist/esm/models/TaxSequence.d.ts +68 -10
- package/dist/esm/models/TaxSequence.js +33 -8
- package/dist/esm/models/TaxSequenceCreated.d.ts +64 -0
- package/dist/esm/models/TaxSequenceCreated.js +53 -0
- package/dist/esm/models/Totals.d.ts +29 -32
- package/dist/esm/models/Totals.js +5 -6
- package/dist/esm/models/Transport.d.ts +26 -14
- package/dist/esm/models/Transport.js +11 -7
- package/dist/esm/models/UpdateTaxSequenceRequest.d.ts +64 -0
- package/dist/esm/models/UpdateTaxSequenceRequest.js +53 -0
- package/dist/esm/models/UploadCertificateResponse.d.ts +7 -7
- package/dist/esm/models/UploadCertificateResponse.js +3 -3
- package/dist/esm/models/VoidTaxSequence200Response.d.ts +39 -0
- package/dist/esm/models/VoidTaxSequence200Response.js +44 -0
- package/dist/esm/models/VoidTaxSequence200ResponseData.d.ts +44 -0
- package/dist/esm/models/VoidTaxSequence200ResponseData.js +45 -0
- package/dist/esm/models/VoidTaxSequenceRequest.d.ts +50 -0
- package/dist/esm/models/VoidTaxSequenceRequest.js +55 -0
- package/dist/esm/models/WebhookConfigDetail.d.ts +81 -0
- package/dist/esm/models/WebhookConfigDetail.js +58 -0
- package/dist/esm/models/WebhookConfigResponse.d.ts +21 -9
- package/dist/esm/models/WebhookConfigResponse.js +7 -3
- package/dist/esm/models/WebhookEventType.d.ts +9 -8
- package/dist/esm/models/WebhookEventType.js +9 -8
- package/dist/esm/models/WebhookNotificationPayload.d.ts +10 -9
- package/dist/esm/models/WebhookNotificationPayload.js +3 -3
- package/dist/esm/models/WebhookStats.d.ts +45 -0
- package/dist/esm/models/WebhookStats.js +46 -0
- package/dist/esm/models/WebhookStatsStats.d.ts +62 -0
- package/dist/esm/models/WebhookStatsStats.js +51 -0
- package/dist/esm/models/index.d.ts +47 -1
- package/dist/esm/models/index.js +47 -1
- package/dist/esm/runtime.d.ts +3 -3
- package/dist/esm/runtime.js +3 -3
- package/dist/models/AccountType.d.ts +4 -8
- package/dist/models/AccountType.js +4 -8
- package/dist/models/AdditionalInfo.d.ts +60 -12
- package/dist/models/AdditionalInfo.js +23 -7
- package/dist/models/AlternativeCurrency.d.ts +78 -8
- package/dist/models/AlternativeCurrency.js +27 -3
- package/dist/models/ApprovalItem.d.ts +74 -0
- package/dist/models/ApprovalItem.js +62 -0
- package/dist/models/ApprovalListResponse.d.ts +40 -0
- package/dist/models/ApprovalListResponse.js +52 -0
- package/dist/models/AssociatedCompany.d.ts +33 -14
- package/dist/models/AssociatedCompany.js +18 -11
- package/dist/models/AssociatedCompanySubscription.d.ts +5 -5
- package/dist/models/AssociatedCompanySubscription.js +3 -3
- package/dist/models/AssociatedCompanySubscriptionPlan.d.ts +4 -4
- package/dist/models/AssociatedCompanySubscriptionPlan.js +3 -3
- package/dist/models/BillingIndicator.d.ts +4 -10
- package/dist/models/BillingIndicator.js +4 -10
- package/dist/models/Buyer.d.ts +71 -11
- package/dist/models/Buyer.js +23 -3
- package/dist/models/CertificationNiche.d.ts +51 -0
- package/dist/models/CertificationNiche.js +55 -0
- package/dist/models/CertificationNicheNicheItemsInner.d.ts +38 -0
- package/dist/models/CertificationNicheNicheItemsInner.js +50 -0
- package/dist/models/CertificationStatus.d.ts +54 -0
- package/dist/models/CertificationStatus.js +62 -0
- package/dist/models/CompanyDocumentMetrics.d.ts +53 -0
- package/dist/models/CompanyDocumentMetrics.js +57 -0
- package/dist/models/CompanyDocumentMetricsGroupByStatusInner.d.ts +39 -0
- package/dist/models/CompanyDocumentMetricsGroupByStatusInner.js +51 -0
- package/dist/models/CompanyDocumentMetricsGroupByStatusInnerCount.d.ts +32 -0
- package/dist/models/CompanyDocumentMetricsGroupByStatusInnerCount.js +48 -0
- package/dist/models/CompanyDocumentMetricsMainBusiness.d.ts +44 -0
- package/dist/models/CompanyDocumentMetricsMainBusiness.js +52 -0
- package/dist/models/CompanyDocumentMetricsTotals.d.ts +38 -0
- package/dist/models/CompanyDocumentMetricsTotals.js +50 -0
- package/dist/models/CompanyMetrics.d.ts +81 -0
- package/dist/models/CompanyMetrics.js +65 -0
- package/dist/models/CompanyMetricsDocumentsStatus.d.ts +44 -0
- package/dist/models/CompanyMetricsDocumentsStatus.js +52 -0
- package/dist/models/CreateAssociatedCompany201Response.d.ts +3 -3
- package/dist/models/CreateAssociatedCompany201Response.js +3 -3
- package/dist/models/CreateTaxSequence201Response.d.ts +39 -0
- package/dist/models/CreateTaxSequence201Response.js +51 -0
- package/dist/models/CreateTaxSequenceRequest.d.ts +27 -10
- package/dist/models/CreateTaxSequenceRequest.js +13 -6
- package/dist/models/DeleteAssociatedCompany200Response.d.ts +32 -0
- package/dist/models/DeleteAssociatedCompany200Response.js +48 -0
- package/dist/models/DiscountOrSurcharge.d.ts +31 -19
- package/dist/models/DiscountOrSurcharge.js +17 -8
- package/dist/models/DocumentStatsResponse.d.ts +54 -0
- package/dist/models/DocumentStatsResponse.js +54 -0
- package/dist/models/DocumentStatus.d.ts +28 -0
- package/dist/models/DocumentStatus.js +54 -0
- package/dist/models/EcfHistoryItem.d.ts +83 -0
- package/dist/models/EcfHistoryItem.js +67 -0
- package/dist/models/EcfStatsResponse.d.ts +80 -0
- package/dist/models/EcfStatsResponse.js +64 -0
- package/dist/models/EcfStatusResponse.d.ts +110 -0
- package/dist/models/EcfStatusResponse.js +82 -0
- package/dist/models/EcfStatusResponseMensajesInner.d.ts +38 -0
- package/dist/models/EcfStatusResponseMensajesInner.js +50 -0
- package/dist/models/EcfSubmissionResponse.d.ts +68 -11
- package/dist/models/EcfSubmissionResponse.js +25 -8
- package/dist/models/EcfSubmissionResponseDgiiResponse.d.ts +50 -0
- package/dist/models/EcfSubmissionResponseDgiiResponse.js +54 -0
- package/dist/models/ElectronicDocument.d.ts +166 -64
- package/dist/models/ElectronicDocument.js +67 -23
- package/dist/models/Environment.d.ts +4 -8
- package/dist/models/Environment.js +4 -8
- package/dist/models/ErrorResponse.d.ts +13 -7
- package/dist/models/ErrorResponse.js +5 -3
- package/dist/models/GetNextNumber200Response.d.ts +3 -3
- package/dist/models/GetNextNumber200Response.js +3 -3
- package/dist/models/GetNextNumber200ResponseData.d.ts +11 -5
- package/dist/models/GetNextNumber200ResponseData.js +5 -3
- package/dist/models/InvoiceType.d.ts +6 -14
- package/dist/models/InvoiceType.js +6 -14
- package/dist/models/InvoiceTypeSequence.d.ts +33 -0
- package/dist/models/InvoiceTypeSequence.js +59 -0
- package/dist/models/Item.d.ts +118 -21
- package/dist/models/Item.js +45 -9
- package/dist/models/ItemAdditionalTax.d.ts +7 -7
- package/dist/models/ItemAdditionalTax.js +4 -6
- package/dist/models/ItemAlternativeCurrency.d.ts +50 -0
- package/dist/models/ItemAlternativeCurrency.js +54 -0
- package/dist/models/ItemCodesInner.d.ts +38 -0
- package/dist/models/ItemCodesInner.js +50 -0
- package/dist/models/ItemDiscountInner.d.ts +44 -0
- package/dist/models/ItemDiscountInner.js +52 -0
- package/dist/models/ItemMiningInfo.d.ts +50 -0
- package/dist/models/ItemMiningInfo.js +54 -0
- package/dist/models/ListTaxSequences200Response.d.ts +10 -3
- package/dist/models/ListTaxSequences200Response.js +6 -3
- package/dist/models/OAuthTokenRequest.d.ts +6 -11
- package/dist/models/OAuthTokenRequest.js +3 -3
- package/dist/models/OAuthTokenResponse.d.ts +7 -9
- package/dist/models/OAuthTokenResponse.js +3 -3
- package/dist/models/Page.d.ts +15 -15
- package/dist/models/Page.js +10 -16
- package/dist/models/PaginationMeta.d.ts +50 -0
- package/dist/models/PaginationMeta.js +54 -0
- package/dist/models/PaymentForm.d.ts +39 -0
- package/dist/models/PaymentForm.js +55 -0
- package/dist/models/PaymentMethod.d.ts +4 -13
- package/dist/models/PaymentMethod.js +4 -13
- package/dist/models/PrintFormat.d.ts +3 -7
- package/dist/models/PrintFormat.js +3 -7
- package/dist/models/ProcessingLog.d.ts +54 -0
- package/dist/models/ProcessingLog.js +62 -0
- package/dist/models/RateLimitErrorResponse.d.ts +50 -0
- package/dist/models/RateLimitErrorResponse.js +54 -0
- package/dist/models/ReceivedDocument.d.ts +81 -0
- package/dist/models/ReceivedDocument.js +65 -0
- package/dist/models/ReceivedDocumentListResponse.d.ts +46 -0
- package/dist/models/ReceivedDocumentListResponse.js +54 -0
- package/dist/models/ReceivedDocumentStatsResponse.d.ts +46 -0
- package/dist/models/ReceivedDocumentStatsResponse.js +52 -0
- package/dist/models/ReferenceInfo.d.ts +9 -18
- package/dist/models/ReferenceInfo.js +4 -4
- package/dist/models/SentDocumentDetail.d.ts +107 -0
- package/dist/models/SentDocumentDetail.js +75 -0
- package/dist/models/SentDocumentListResponse.d.ts +46 -0
- package/dist/models/SentDocumentListResponse.js +54 -0
- package/dist/models/SentDocumentSummary.d.ts +94 -0
- package/dist/models/SentDocumentSummary.js +70 -0
- package/dist/models/SentDocumentSummaryBusiness.d.ts +38 -0
- package/dist/models/SentDocumentSummaryBusiness.js +50 -0
- package/dist/models/StartCertification200Response.d.ts +32 -0
- package/dist/models/StartCertification200Response.js +48 -0
- package/dist/models/StartCertificationRequest.d.ts +51 -0
- package/dist/models/StartCertificationRequest.js +61 -0
- package/dist/models/Subquantity.d.ts +6 -6
- package/dist/models/Subquantity.js +3 -3
- package/dist/models/Subtotal.d.ts +18 -12
- package/dist/models/Subtotal.js +8 -10
- package/dist/models/TaxSequence.d.ts +68 -10
- package/dist/models/TaxSequence.js +34 -8
- package/dist/models/TaxSequenceCreated.d.ts +64 -0
- package/dist/models/TaxSequenceCreated.js +60 -0
- package/dist/models/Totals.d.ts +29 -32
- package/dist/models/Totals.js +5 -6
- package/dist/models/Transport.d.ts +26 -14
- package/dist/models/Transport.js +11 -7
- package/dist/models/UpdateTaxSequenceRequest.d.ts +64 -0
- package/dist/models/UpdateTaxSequenceRequest.js +60 -0
- package/dist/models/UploadCertificateResponse.d.ts +7 -7
- package/dist/models/UploadCertificateResponse.js +3 -3
- package/dist/models/VoidTaxSequence200Response.d.ts +39 -0
- package/dist/models/VoidTaxSequence200Response.js +51 -0
- package/dist/models/VoidTaxSequence200ResponseData.d.ts +44 -0
- package/dist/models/VoidTaxSequence200ResponseData.js +52 -0
- package/dist/models/VoidTaxSequenceRequest.d.ts +50 -0
- package/dist/models/VoidTaxSequenceRequest.js +62 -0
- package/dist/models/WebhookConfigDetail.d.ts +81 -0
- package/dist/models/WebhookConfigDetail.js +65 -0
- package/dist/models/WebhookConfigResponse.d.ts +21 -9
- package/dist/models/WebhookConfigResponse.js +7 -3
- package/dist/models/WebhookEventType.d.ts +9 -8
- package/dist/models/WebhookEventType.js +9 -8
- package/dist/models/WebhookNotificationPayload.d.ts +10 -9
- package/dist/models/WebhookNotificationPayload.js +3 -3
- package/dist/models/WebhookStats.d.ts +45 -0
- package/dist/models/WebhookStats.js +53 -0
- package/dist/models/WebhookStatsStats.d.ts +62 -0
- package/dist/models/WebhookStatsStats.js +58 -0
- package/dist/models/index.d.ts +47 -1
- package/dist/models/index.js +47 -1
- package/dist/runtime.d.ts +3 -3
- package/dist/runtime.js +3 -3
- package/docs/AccountType.md +2 -2
- package/docs/AdditionalInfo.md +21 -6
- package/docs/AlternativeCurrency.md +26 -3
- package/docs/ApprovalItem.md +48 -0
- package/docs/ApprovalListResponse.md +36 -0
- package/docs/AssociatedCompaniesApi.md +350 -42
- package/docs/AssociatedCompany.md +15 -10
- package/docs/AssociatedCompanySubscription.md +1 -1
- package/docs/AssociatedCompanySubscriptionPlan.md +1 -1
- package/docs/AuthenticationApi.md +8 -8
- package/docs/AutomatedCertificationApi.md +294 -0
- package/docs/BillingIndicator.md +2 -2
- package/docs/Buyer.md +24 -5
- package/docs/CertificationNiche.md +40 -0
- package/docs/CertificationNicheNicheItemsInner.md +36 -0
- package/docs/CertificationStatus.md +38 -0
- package/docs/CommercialApprovalsApi.md +114 -0
- package/docs/CompanyDocumentMetrics.md +40 -0
- package/docs/CompanyDocumentMetricsGroupByStatusInner.md +36 -0
- package/docs/CompanyDocumentMetricsGroupByStatusInnerCount.md +34 -0
- package/docs/CompanyDocumentMetricsMainBusiness.md +38 -0
- package/docs/CompanyDocumentMetricsTotals.md +36 -0
- package/docs/CompanyMetrics.md +50 -0
- package/docs/CompanyMetricsDocumentsStatus.md +38 -0
- package/docs/CreateAssociatedCompany201Response.md +1 -1
- package/docs/CreateTaxSequence201Response.md +36 -0
- package/docs/CreateTaxSequenceRequest.md +9 -4
- package/docs/DeleteAssociatedCompany200Response.md +34 -0
- package/docs/DigitalCertificatesApi.md +18 -16
- package/docs/DiscountOrSurcharge.md +7 -6
- package/docs/DocumentStatsResponse.md +40 -0
- package/docs/DocumentStatus.md +32 -0
- package/docs/DocumentsReceivedApi.md +175 -0
- package/docs/DocumentsSentApi.md +330 -0
- package/docs/ECFSubmissionApi.md +245 -13
- package/docs/EcfHistoryItem.md +50 -0
- package/docs/EcfStatsResponse.md +50 -0
- package/docs/EcfStatusResponse.md +56 -0
- package/docs/EcfStatusResponseMensajesInner.md +36 -0
- package/docs/EcfSubmissionResponse.md +22 -4
- package/docs/EcfSubmissionResponseDgiiResponse.md +40 -0
- package/docs/ElectronicDocument.md +52 -12
- package/docs/Environment.md +2 -2
- package/docs/ErrorResponse.md +6 -5
- package/docs/GetNextNumber200Response.md +1 -1
- package/docs/GetNextNumber200ResponseData.md +5 -3
- package/docs/InvoiceType.md +2 -2
- package/docs/InvoiceTypeSequence.md +33 -0
- package/docs/Item.md +42 -11
- package/docs/ItemAdditionalTax.md +1 -2
- package/docs/ItemAlternativeCurrency.md +40 -0
- package/docs/ItemCodesInner.md +36 -0
- package/docs/ItemDiscountInner.md +38 -0
- package/docs/ItemMiningInfo.md +40 -0
- package/docs/ListTaxSequences200Response.md +3 -1
- package/docs/OAuthTokenRequest.md +4 -4
- package/docs/OAuthTokenResponse.md +4 -4
- package/docs/Page.md +5 -6
- package/docs/PaginationMeta.md +40 -0
- package/docs/PaymentForm.md +36 -0
- package/docs/PaymentMethod.md +2 -2
- package/docs/PrintFormat.md +1 -2
- package/docs/ProcessingLog.md +38 -0
- package/docs/RateLimitErrorResponse.md +40 -0
- package/docs/ReceivedDocument.md +50 -0
- package/docs/ReceivedDocumentListResponse.md +38 -0
- package/docs/ReceivedDocumentStatsResponse.md +38 -0
- package/docs/ReferenceInfo.md +2 -2
- package/docs/ReportsApi.md +186 -0
- package/docs/SentDocumentDetail.md +58 -0
- package/docs/SentDocumentListResponse.md +38 -0
- package/docs/SentDocumentSummary.md +54 -0
- package/docs/SentDocumentSummaryBusiness.md +36 -0
- package/docs/StartCertification200Response.md +34 -0
- package/docs/StartCertificationRequest.md +40 -0
- package/docs/Subquantity.md +1 -2
- package/docs/Subtotal.md +5 -4
- package/docs/TaxSequence.md +21 -6
- package/docs/TaxSequenceCreated.md +44 -0
- package/docs/TaxSequencesApi.md +197 -38
- package/docs/Totals.md +2 -3
- package/docs/Transport.md +9 -6
- package/docs/UpdateTaxSequenceRequest.md +44 -0
- package/docs/UploadCertificateResponse.md +2 -3
- package/docs/VoidTaxSequence200Response.md +36 -0
- package/docs/VoidTaxSequence200ResponseData.md +38 -0
- package/docs/VoidTaxSequenceRequest.md +40 -0
- package/docs/WebhookConfigDetail.md +50 -0
- package/docs/WebhookConfigResponse.md +6 -3
- package/docs/WebhookConfigurationApi.md +47 -50
- package/docs/WebhookEventType.md +1 -2
- package/docs/WebhookNotificationPayload.md +3 -3
- package/docs/WebhookStats.md +38 -0
- package/docs/WebhookStatsStats.md +44 -0
- package/package.json +1 -1
- package/src/apis/AssociatedCompaniesApi.ts +455 -57
- package/src/apis/AuthenticationApi.ts +11 -11
- package/src/apis/AutomatedCertificationApi.ts +382 -0
- package/src/apis/CommercialApprovalsApi.ts +234 -0
- package/src/apis/DigitalCertificatesApi.ts +17 -17
- package/src/apis/DocumentsReceivedApi.ts +256 -0
- package/src/apis/DocumentsSentApi.ts +481 -0
- package/src/apis/ECFSubmissionApi.ts +309 -17
- package/src/apis/ReportsApi.ts +323 -0
- package/src/apis/TaxSequencesApi.ts +264 -63
- package/src/apis/WebhookConfigurationApi.ts +90 -76
- package/src/apis/index.ts +5 -0
- package/src/models/AccountType.ts +4 -8
- package/src/models/AdditionalInfo.ts +80 -16
- package/src/models/AlternativeCurrency.ts +102 -8
- package/src/models/ApprovalItem.ts +121 -0
- package/src/models/ApprovalListResponse.ts +88 -0
- package/src/models/AssociatedCompany.ts +53 -22
- package/src/models/AssociatedCompanySubscription.ts +5 -5
- package/src/models/AssociatedCompanySubscriptionPlan.ts +4 -4
- package/src/models/BillingIndicator.ts +4 -10
- package/src/models/Buyer.ts +91 -11
- package/src/models/CertificationNiche.ts +97 -0
- package/src/models/CertificationNicheNicheItemsInner.ts +73 -0
- package/src/models/CertificationStatus.ts +94 -0
- package/src/models/CompanyDocumentMetrics.ts +111 -0
- package/src/models/CompanyDocumentMetricsGroupByStatusInner.ts +81 -0
- package/src/models/CompanyDocumentMetricsGroupByStatusInnerCount.ts +65 -0
- package/src/models/CompanyDocumentMetricsMainBusiness.ts +81 -0
- package/src/models/CompanyDocumentMetricsTotals.ts +73 -0
- package/src/models/CompanyMetrics.ts +137 -0
- package/src/models/CompanyMetricsDocumentsStatus.ts +81 -0
- package/src/models/CreateAssociatedCompany201Response.ts +3 -3
- package/src/models/CreateTaxSequence201Response.ts +81 -0
- package/src/models/CreateTaxSequenceRequest.ts +46 -17
- package/src/models/DeleteAssociatedCompany200Response.ts +65 -0
- package/src/models/DiscountOrSurcharge.ts +38 -23
- package/src/models/DocumentStatsResponse.ts +89 -0
- package/src/models/DocumentStatus.ts +56 -0
- package/src/models/EcfHistoryItem.ts +153 -0
- package/src/models/EcfStatsResponse.ts +129 -0
- package/src/models/EcfStatusResponse.ts +193 -0
- package/src/models/EcfStatusResponseMensajesInner.ts +73 -0
- package/src/models/EcfSubmissionResponse.ts +96 -15
- package/src/models/EcfSubmissionResponseDgiiResponse.ts +89 -0
- package/src/models/ElectronicDocument.ts +252 -97
- package/src/models/Environment.ts +4 -8
- package/src/models/ErrorResponse.ts +15 -7
- package/src/models/GetNextNumber200Response.ts +3 -3
- package/src/models/GetNextNumber200ResponseData.ts +13 -5
- package/src/models/InvoiceType.ts +6 -14
- package/src/models/InvoiceTypeSequence.ts +61 -0
- package/src/models/Item.ts +180 -27
- package/src/models/ItemAdditionalTax.ts +8 -9
- package/src/models/ItemAlternativeCurrency.ts +89 -0
- package/src/models/ItemCodesInner.ts +73 -0
- package/src/models/ItemDiscountInner.ts +81 -0
- package/src/models/ItemMiningInfo.ts +89 -0
- package/src/models/ListTaxSequences200Response.ts +18 -3
- package/src/models/OAuthTokenRequest.ts +6 -11
- package/src/models/OAuthTokenResponse.ts +7 -9
- package/src/models/Page.ts +22 -25
- package/src/models/PaginationMeta.ts +89 -0
- package/src/models/PaymentForm.ts +85 -0
- package/src/models/PaymentMethod.ts +4 -13
- package/src/models/PrintFormat.ts +3 -7
- package/src/models/ProcessingLog.ts +94 -0
- package/src/models/RateLimitErrorResponse.ts +89 -0
- package/src/models/ReceivedDocument.ts +137 -0
- package/src/models/ReceivedDocumentListResponse.ts +96 -0
- package/src/models/ReceivedDocumentStatsResponse.ts +81 -0
- package/src/models/ReferenceInfo.ts +10 -19
- package/src/models/SentDocumentDetail.ts +185 -0
- package/src/models/SentDocumentListResponse.ts +96 -0
- package/src/models/SentDocumentSummary.ts +162 -0
- package/src/models/SentDocumentSummaryBusiness.ts +73 -0
- package/src/models/StartCertification200Response.ts +65 -0
- package/src/models/StartCertificationRequest.ts +102 -0
- package/src/models/Subquantity.ts +6 -6
- package/src/models/Subtotal.ts +23 -17
- package/src/models/TaxSequence.ts +94 -19
- package/src/models/TaxSequenceCreated.ts +122 -0
- package/src/models/Totals.ts +31 -41
- package/src/models/Transport.ts +34 -18
- package/src/models/UpdateTaxSequenceRequest.ts +122 -0
- package/src/models/UploadCertificateResponse.ts +7 -7
- package/src/models/VoidTaxSequence200Response.ts +81 -0
- package/src/models/VoidTaxSequence200ResponseData.ts +81 -0
- package/src/models/VoidTaxSequenceRequest.ts +93 -0
- package/src/models/WebhookConfigDetail.ts +137 -0
- package/src/models/WebhookConfigResponse.ts +25 -9
- package/src/models/WebhookEventType.ts +9 -8
- package/src/models/WebhookNotificationPayload.ts +10 -9
- package/src/models/WebhookStats.ts +89 -0
- package/src/models/WebhookStatsStats.ts +105 -0
- package/src/models/index.ts +47 -1
- package/src/runtime.ts +3 -3
|
@@ -2,10 +2,10 @@
|
|
|
2
2
|
/* eslint-disable */
|
|
3
3
|
/**
|
|
4
4
|
* eCF-Pronesoft Integration API
|
|
5
|
-
* ## Overview Production-grade API for issuing Electronic Tax Receipts (e-CF) in the Dominican Republic through the Pronesoft platform
|
|
5
|
+
* ## Overview Production-grade API for issuing Electronic Tax Receipts (e-CF) in the Dominican Republic through the Pronesoft platform. ## Authentication — OAuth 2.0 Client Credentials ### Steps 1. Get credentials from the portal: - Sandbox: https://ecf.sandbox.pronesoft.com -> Apps -> Default Sandbox App - Production: https://ecf.pronesoft.com -> Integrations -> Apps -> Create App 2. Request a token via POST /oauth/token — valid for 24 hours (86400s). 3. Use: Authorization: Bearer <accessToken> on every request. 4. Renew on HTTP 401. Best practice: renew 5 minutes before expiry. ### Multi-company delegation To act on behalf of an associated company (branch), add: x-tenant-id: <business-uuid> Do NOT send x-tenant-id when acting as the main company. ### Sandbox specifics - Use any RNC starting with SBX (e.g. SBX123456) — no real certificate needed. - Sequences are automatic — no need to create them manually. - The environment field in the document body MUST be TesteCF. ### Scopes business:read, business:create, business:update, members:read, members:invite, members:revoke, certificates:read, certificates:upload, certificates:update, documents:read, documents:create, documents:send, documents:receive, documents:update, approvals:read, approvals:commercial, sequences:read, sequences:create, sequences:update, sequences:cancel, business_info:read, certification:read, certification:write, reports:read
|
|
6
6
|
*
|
|
7
|
-
* The version of the OpenAPI document:
|
|
8
|
-
* Contact:
|
|
7
|
+
* The version of the OpenAPI document: 1.1.0
|
|
8
|
+
* Contact: support@pronesoft.com
|
|
9
9
|
*
|
|
10
10
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
11
11
|
* https://openapi-generator.tech
|
|
@@ -16,15 +16,24 @@
|
|
|
16
16
|
import * as runtime from '../runtime';
|
|
17
17
|
import type {
|
|
18
18
|
AssociatedCompany,
|
|
19
|
+
CompanyDocumentMetrics,
|
|
20
|
+
CompanyMetrics,
|
|
19
21
|
CreateAssociatedCompany201Response,
|
|
22
|
+
DeleteAssociatedCompany200Response,
|
|
20
23
|
ErrorResponse,
|
|
21
24
|
PrintFormat,
|
|
22
25
|
} from '../models/index';
|
|
23
26
|
import {
|
|
24
27
|
AssociatedCompanyFromJSON,
|
|
25
28
|
AssociatedCompanyToJSON,
|
|
29
|
+
CompanyDocumentMetricsFromJSON,
|
|
30
|
+
CompanyDocumentMetricsToJSON,
|
|
31
|
+
CompanyMetricsFromJSON,
|
|
32
|
+
CompanyMetricsToJSON,
|
|
26
33
|
CreateAssociatedCompany201ResponseFromJSON,
|
|
27
34
|
CreateAssociatedCompany201ResponseToJSON,
|
|
35
|
+
DeleteAssociatedCompany200ResponseFromJSON,
|
|
36
|
+
DeleteAssociatedCompany200ResponseToJSON,
|
|
28
37
|
ErrorResponseFromJSON,
|
|
29
38
|
ErrorResponseToJSON,
|
|
30
39
|
PrintFormatFromJSON,
|
|
@@ -32,7 +41,6 @@ import {
|
|
|
32
41
|
} from '../models/index';
|
|
33
42
|
|
|
34
43
|
export interface CreateAssociatedCompanyRequest {
|
|
35
|
-
xTenantId: string;
|
|
36
44
|
email: string;
|
|
37
45
|
password: string;
|
|
38
46
|
name: string;
|
|
@@ -41,18 +49,41 @@ export interface CreateAssociatedCompanyRequest {
|
|
|
41
49
|
address: string;
|
|
42
50
|
city: string;
|
|
43
51
|
country: string;
|
|
52
|
+
printerType: PrintFormat;
|
|
44
53
|
firstName?: string;
|
|
45
54
|
lastName?: string;
|
|
46
55
|
jobTitle?: string;
|
|
47
56
|
website?: string;
|
|
48
57
|
category?: string;
|
|
49
58
|
monthlySalesRange?: string;
|
|
50
|
-
printerType?: PrintFormat;
|
|
51
59
|
logo?: Blob;
|
|
52
60
|
}
|
|
53
61
|
|
|
62
|
+
export interface DeleteAssociatedCompanyRequest {
|
|
63
|
+
companyId: string;
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
export interface GetCompanyDocumentMetricsRequest {
|
|
67
|
+
companyId: string;
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
export interface GetCompanyMetricsRequest {
|
|
71
|
+
companyId: string;
|
|
72
|
+
}
|
|
73
|
+
|
|
54
74
|
export interface ListAssociatedCompaniesRequest {
|
|
55
|
-
|
|
75
|
+
page?: number;
|
|
76
|
+
limit?: number;
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
export interface UpdateAssociatedCompanyRequest {
|
|
80
|
+
companyId: string;
|
|
81
|
+
name?: string;
|
|
82
|
+
phone?: string;
|
|
83
|
+
website?: string;
|
|
84
|
+
city?: string;
|
|
85
|
+
country?: string;
|
|
86
|
+
logo?: Blob;
|
|
56
87
|
}
|
|
57
88
|
|
|
58
89
|
/**
|
|
@@ -64,48 +95,46 @@ export interface ListAssociatedCompaniesRequest {
|
|
|
64
95
|
export interface AssociatedCompaniesApiInterface {
|
|
65
96
|
/**
|
|
66
97
|
* Creates request options for createAssociatedCompany without sending the request
|
|
67
|
-
* @param {string}
|
|
68
|
-
* @param {string}
|
|
69
|
-
* @param {string}
|
|
70
|
-
* @param {string}
|
|
71
|
-
* @param {string} rnc Company RNC (9 digits) or personal cedula (11 digits).
|
|
98
|
+
* @param {string} email
|
|
99
|
+
* @param {string} password
|
|
100
|
+
* @param {string} name
|
|
101
|
+
* @param {string} rnc
|
|
72
102
|
* @param {string} phone
|
|
73
103
|
* @param {string} address
|
|
74
104
|
* @param {string} city
|
|
75
105
|
* @param {string} country
|
|
106
|
+
* @param {PrintFormat} printerType
|
|
76
107
|
* @param {string} [firstName]
|
|
77
108
|
* @param {string} [lastName]
|
|
78
109
|
* @param {string} [jobTitle]
|
|
79
110
|
* @param {string} [website]
|
|
80
|
-
* @param {string} [category]
|
|
81
|
-
* @param {string} [monthlySalesRange]
|
|
82
|
-
* @param {
|
|
83
|
-
* @param {Blob} [logo] Company logo image file (multipart upload).
|
|
111
|
+
* @param {string} [category]
|
|
112
|
+
* @param {string} [monthlySalesRange]
|
|
113
|
+
* @param {Blob} [logo]
|
|
84
114
|
* @throws {RequiredError}
|
|
85
115
|
* @memberof AssociatedCompaniesApiInterface
|
|
86
116
|
*/
|
|
87
117
|
createAssociatedCompanyRequestOpts(requestParameters: CreateAssociatedCompanyRequest): Promise<runtime.RequestOpts>;
|
|
88
118
|
|
|
89
119
|
/**
|
|
90
|
-
*
|
|
91
|
-
* @summary Create
|
|
92
|
-
* @param {string}
|
|
93
|
-
* @param {string}
|
|
94
|
-
* @param {string}
|
|
95
|
-
* @param {string}
|
|
96
|
-
* @param {string} rnc Company RNC (9 digits) or personal cedula (11 digits).
|
|
120
|
+
*
|
|
121
|
+
* @summary Create associated company / branch
|
|
122
|
+
* @param {string} email
|
|
123
|
+
* @param {string} password
|
|
124
|
+
* @param {string} name
|
|
125
|
+
* @param {string} rnc
|
|
97
126
|
* @param {string} phone
|
|
98
127
|
* @param {string} address
|
|
99
128
|
* @param {string} city
|
|
100
129
|
* @param {string} country
|
|
130
|
+
* @param {PrintFormat} printerType
|
|
101
131
|
* @param {string} [firstName]
|
|
102
132
|
* @param {string} [lastName]
|
|
103
133
|
* @param {string} [jobTitle]
|
|
104
134
|
* @param {string} [website]
|
|
105
|
-
* @param {string} [category]
|
|
106
|
-
* @param {string} [monthlySalesRange]
|
|
107
|
-
* @param {
|
|
108
|
-
* @param {Blob} [logo] Company logo image file (multipart upload).
|
|
135
|
+
* @param {string} [category]
|
|
136
|
+
* @param {string} [monthlySalesRange]
|
|
137
|
+
* @param {Blob} [logo]
|
|
109
138
|
* @param {*} [options] Override http request option.
|
|
110
139
|
* @throws {RequiredError}
|
|
111
140
|
* @memberof AssociatedCompaniesApiInterface
|
|
@@ -113,23 +142,94 @@ export interface AssociatedCompaniesApiInterface {
|
|
|
113
142
|
createAssociatedCompanyRaw(requestParameters: CreateAssociatedCompanyRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<CreateAssociatedCompany201Response>>;
|
|
114
143
|
|
|
115
144
|
/**
|
|
116
|
-
*
|
|
117
|
-
* Create new associated company
|
|
145
|
+
* Create associated company / branch
|
|
118
146
|
*/
|
|
119
147
|
createAssociatedCompany(requestParameters: CreateAssociatedCompanyRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<CreateAssociatedCompany201Response>;
|
|
120
148
|
|
|
149
|
+
/**
|
|
150
|
+
* Creates request options for deleteAssociatedCompany without sending the request
|
|
151
|
+
* @param {string} companyId
|
|
152
|
+
* @throws {RequiredError}
|
|
153
|
+
* @memberof AssociatedCompaniesApiInterface
|
|
154
|
+
*/
|
|
155
|
+
deleteAssociatedCompanyRequestOpts(requestParameters: DeleteAssociatedCompanyRequest): Promise<runtime.RequestOpts>;
|
|
156
|
+
|
|
157
|
+
/**
|
|
158
|
+
* Permanently deletes an associated company. This action is irreversible.
|
|
159
|
+
* @summary Delete associated company
|
|
160
|
+
* @param {string} companyId
|
|
161
|
+
* @param {*} [options] Override http request option.
|
|
162
|
+
* @throws {RequiredError}
|
|
163
|
+
* @memberof AssociatedCompaniesApiInterface
|
|
164
|
+
*/
|
|
165
|
+
deleteAssociatedCompanyRaw(requestParameters: DeleteAssociatedCompanyRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<DeleteAssociatedCompany200Response>>;
|
|
166
|
+
|
|
167
|
+
/**
|
|
168
|
+
* Permanently deletes an associated company. This action is irreversible.
|
|
169
|
+
* Delete associated company
|
|
170
|
+
*/
|
|
171
|
+
deleteAssociatedCompany(requestParameters: DeleteAssociatedCompanyRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<DeleteAssociatedCompany200Response>;
|
|
172
|
+
|
|
173
|
+
/**
|
|
174
|
+
* Creates request options for getCompanyDocumentMetrics without sending the request
|
|
175
|
+
* @param {string} companyId
|
|
176
|
+
* @throws {RequiredError}
|
|
177
|
+
* @memberof AssociatedCompaniesApiInterface
|
|
178
|
+
*/
|
|
179
|
+
getCompanyDocumentMetricsRequestOpts(requestParameters: GetCompanyDocumentMetricsRequest): Promise<runtime.RequestOpts>;
|
|
180
|
+
|
|
181
|
+
/**
|
|
182
|
+
*
|
|
183
|
+
* @summary Get company document metrics
|
|
184
|
+
* @param {string} companyId
|
|
185
|
+
* @param {*} [options] Override http request option.
|
|
186
|
+
* @throws {RequiredError}
|
|
187
|
+
* @memberof AssociatedCompaniesApiInterface
|
|
188
|
+
*/
|
|
189
|
+
getCompanyDocumentMetricsRaw(requestParameters: GetCompanyDocumentMetricsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<CompanyDocumentMetrics>>;
|
|
190
|
+
|
|
191
|
+
/**
|
|
192
|
+
* Get company document metrics
|
|
193
|
+
*/
|
|
194
|
+
getCompanyDocumentMetrics(requestParameters: GetCompanyDocumentMetricsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<CompanyDocumentMetrics>;
|
|
195
|
+
|
|
196
|
+
/**
|
|
197
|
+
* Creates request options for getCompanyMetrics without sending the request
|
|
198
|
+
* @param {string} companyId
|
|
199
|
+
* @throws {RequiredError}
|
|
200
|
+
* @memberof AssociatedCompaniesApiInterface
|
|
201
|
+
*/
|
|
202
|
+
getCompanyMetricsRequestOpts(requestParameters: GetCompanyMetricsRequest): Promise<runtime.RequestOpts>;
|
|
203
|
+
|
|
204
|
+
/**
|
|
205
|
+
*
|
|
206
|
+
* @summary Get company metrics
|
|
207
|
+
* @param {string} companyId
|
|
208
|
+
* @param {*} [options] Override http request option.
|
|
209
|
+
* @throws {RequiredError}
|
|
210
|
+
* @memberof AssociatedCompaniesApiInterface
|
|
211
|
+
*/
|
|
212
|
+
getCompanyMetricsRaw(requestParameters: GetCompanyMetricsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<CompanyMetrics>>;
|
|
213
|
+
|
|
214
|
+
/**
|
|
215
|
+
* Get company metrics
|
|
216
|
+
*/
|
|
217
|
+
getCompanyMetrics(requestParameters: GetCompanyMetricsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<CompanyMetrics>;
|
|
218
|
+
|
|
121
219
|
/**
|
|
122
220
|
* Creates request options for listAssociatedCompanies without sending the request
|
|
123
|
-
* @param {
|
|
221
|
+
* @param {number} [page]
|
|
222
|
+
* @param {number} [limit]
|
|
124
223
|
* @throws {RequiredError}
|
|
125
224
|
* @memberof AssociatedCompaniesApiInterface
|
|
126
225
|
*/
|
|
127
226
|
listAssociatedCompaniesRequestOpts(requestParameters: ListAssociatedCompaniesRequest): Promise<runtime.RequestOpts>;
|
|
128
227
|
|
|
129
228
|
/**
|
|
130
|
-
*
|
|
229
|
+
*
|
|
131
230
|
* @summary List associated companies / branches
|
|
132
|
-
* @param {
|
|
231
|
+
* @param {number} [page]
|
|
232
|
+
* @param {number} [limit]
|
|
133
233
|
* @param {*} [options] Override http request option.
|
|
134
234
|
* @throws {RequiredError}
|
|
135
235
|
* @memberof AssociatedCompaniesApiInterface
|
|
@@ -137,11 +237,45 @@ export interface AssociatedCompaniesApiInterface {
|
|
|
137
237
|
listAssociatedCompaniesRaw(requestParameters: ListAssociatedCompaniesRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<Array<AssociatedCompany>>>;
|
|
138
238
|
|
|
139
239
|
/**
|
|
140
|
-
* Returns all companies and branches linked to the current tenant.
|
|
141
240
|
* List associated companies / branches
|
|
142
241
|
*/
|
|
143
242
|
listAssociatedCompanies(requestParameters: ListAssociatedCompaniesRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<Array<AssociatedCompany>>;
|
|
144
243
|
|
|
244
|
+
/**
|
|
245
|
+
* Creates request options for updateAssociatedCompany without sending the request
|
|
246
|
+
* @param {string} companyId
|
|
247
|
+
* @param {string} [name]
|
|
248
|
+
* @param {string} [phone]
|
|
249
|
+
* @param {string} [website]
|
|
250
|
+
* @param {string} [city]
|
|
251
|
+
* @param {string} [country]
|
|
252
|
+
* @param {Blob} [logo]
|
|
253
|
+
* @throws {RequiredError}
|
|
254
|
+
* @memberof AssociatedCompaniesApiInterface
|
|
255
|
+
*/
|
|
256
|
+
updateAssociatedCompanyRequestOpts(requestParameters: UpdateAssociatedCompanyRequest): Promise<runtime.RequestOpts>;
|
|
257
|
+
|
|
258
|
+
/**
|
|
259
|
+
*
|
|
260
|
+
* @summary Update associated company
|
|
261
|
+
* @param {string} companyId
|
|
262
|
+
* @param {string} [name]
|
|
263
|
+
* @param {string} [phone]
|
|
264
|
+
* @param {string} [website]
|
|
265
|
+
* @param {string} [city]
|
|
266
|
+
* @param {string} [country]
|
|
267
|
+
* @param {Blob} [logo]
|
|
268
|
+
* @param {*} [options] Override http request option.
|
|
269
|
+
* @throws {RequiredError}
|
|
270
|
+
* @memberof AssociatedCompaniesApiInterface
|
|
271
|
+
*/
|
|
272
|
+
updateAssociatedCompanyRaw(requestParameters: UpdateAssociatedCompanyRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<CreateAssociatedCompany201Response>>;
|
|
273
|
+
|
|
274
|
+
/**
|
|
275
|
+
* Update associated company
|
|
276
|
+
*/
|
|
277
|
+
updateAssociatedCompany(requestParameters: UpdateAssociatedCompanyRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<CreateAssociatedCompany201Response>;
|
|
278
|
+
|
|
145
279
|
}
|
|
146
280
|
|
|
147
281
|
/**
|
|
@@ -153,13 +287,6 @@ export class AssociatedCompaniesApi extends runtime.BaseAPI implements Associate
|
|
|
153
287
|
* Creates request options for createAssociatedCompany without sending the request
|
|
154
288
|
*/
|
|
155
289
|
async createAssociatedCompanyRequestOpts(requestParameters: CreateAssociatedCompanyRequest): Promise<runtime.RequestOpts> {
|
|
156
|
-
if (requestParameters['xTenantId'] == null) {
|
|
157
|
-
throw new runtime.RequiredError(
|
|
158
|
-
'xTenantId',
|
|
159
|
-
'Required parameter "xTenantId" was null or undefined when calling createAssociatedCompany().'
|
|
160
|
-
);
|
|
161
|
-
}
|
|
162
|
-
|
|
163
290
|
if (requestParameters['email'] == null) {
|
|
164
291
|
throw new runtime.RequiredError(
|
|
165
292
|
'email',
|
|
@@ -216,14 +343,17 @@ export class AssociatedCompaniesApi extends runtime.BaseAPI implements Associate
|
|
|
216
343
|
);
|
|
217
344
|
}
|
|
218
345
|
|
|
346
|
+
if (requestParameters['printerType'] == null) {
|
|
347
|
+
throw new runtime.RequiredError(
|
|
348
|
+
'printerType',
|
|
349
|
+
'Required parameter "printerType" was null or undefined when calling createAssociatedCompany().'
|
|
350
|
+
);
|
|
351
|
+
}
|
|
352
|
+
|
|
219
353
|
const queryParameters: any = {};
|
|
220
354
|
|
|
221
355
|
const headerParameters: runtime.HTTPHeaders = {};
|
|
222
356
|
|
|
223
|
-
if (requestParameters['xTenantId'] != null) {
|
|
224
|
-
headerParameters['x-tenant-id'] = String(requestParameters['xTenantId']);
|
|
225
|
-
}
|
|
226
|
-
|
|
227
357
|
if (this.configuration && this.configuration.accessToken) {
|
|
228
358
|
// oauth required
|
|
229
359
|
headerParameters["Authorization"] = await this.configuration.accessToken("oauth2", ["business:create"]);
|
|
@@ -330,8 +460,7 @@ export class AssociatedCompaniesApi extends runtime.BaseAPI implements Associate
|
|
|
330
460
|
}
|
|
331
461
|
|
|
332
462
|
/**
|
|
333
|
-
*
|
|
334
|
-
* Create new associated company
|
|
463
|
+
* Create associated company / branch
|
|
335
464
|
*/
|
|
336
465
|
async createAssociatedCompanyRaw(requestParameters: CreateAssociatedCompanyRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<CreateAssociatedCompany201Response>> {
|
|
337
466
|
const requestOptions = await this.createAssociatedCompanyRequestOpts(requestParameters);
|
|
@@ -341,8 +470,7 @@ export class AssociatedCompaniesApi extends runtime.BaseAPI implements Associate
|
|
|
341
470
|
}
|
|
342
471
|
|
|
343
472
|
/**
|
|
344
|
-
*
|
|
345
|
-
* Create new associated company
|
|
473
|
+
* Create associated company / branch
|
|
346
474
|
*/
|
|
347
475
|
async createAssociatedCompany(requestParameters: CreateAssociatedCompanyRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<CreateAssociatedCompany201Response> {
|
|
348
476
|
const response = await this.createAssociatedCompanyRaw(requestParameters, initOverrides);
|
|
@@ -350,13 +478,131 @@ export class AssociatedCompaniesApi extends runtime.BaseAPI implements Associate
|
|
|
350
478
|
}
|
|
351
479
|
|
|
352
480
|
/**
|
|
353
|
-
* Creates request options for
|
|
481
|
+
* Creates request options for deleteAssociatedCompany without sending the request
|
|
354
482
|
*/
|
|
355
|
-
async
|
|
356
|
-
if (requestParameters['
|
|
483
|
+
async deleteAssociatedCompanyRequestOpts(requestParameters: DeleteAssociatedCompanyRequest): Promise<runtime.RequestOpts> {
|
|
484
|
+
if (requestParameters['companyId'] == null) {
|
|
485
|
+
throw new runtime.RequiredError(
|
|
486
|
+
'companyId',
|
|
487
|
+
'Required parameter "companyId" was null or undefined when calling deleteAssociatedCompany().'
|
|
488
|
+
);
|
|
489
|
+
}
|
|
490
|
+
|
|
491
|
+
const queryParameters: any = {};
|
|
492
|
+
|
|
493
|
+
const headerParameters: runtime.HTTPHeaders = {};
|
|
494
|
+
|
|
495
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
496
|
+
// oauth required
|
|
497
|
+
headerParameters["Authorization"] = await this.configuration.accessToken("oauth2", ["business:update"]);
|
|
498
|
+
}
|
|
499
|
+
|
|
500
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
501
|
+
const token = this.configuration.accessToken;
|
|
502
|
+
const tokenString = await token("bearerAuth", []);
|
|
503
|
+
|
|
504
|
+
if (tokenString) {
|
|
505
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
506
|
+
}
|
|
507
|
+
}
|
|
508
|
+
|
|
509
|
+
let urlPath = `/associated-companies/{companyId}`;
|
|
510
|
+
urlPath = urlPath.replace(`{${"companyId"}}`, encodeURIComponent(String(requestParameters['companyId'])));
|
|
511
|
+
|
|
512
|
+
return {
|
|
513
|
+
path: urlPath,
|
|
514
|
+
method: 'DELETE',
|
|
515
|
+
headers: headerParameters,
|
|
516
|
+
query: queryParameters,
|
|
517
|
+
};
|
|
518
|
+
}
|
|
519
|
+
|
|
520
|
+
/**
|
|
521
|
+
* Permanently deletes an associated company. This action is irreversible.
|
|
522
|
+
* Delete associated company
|
|
523
|
+
*/
|
|
524
|
+
async deleteAssociatedCompanyRaw(requestParameters: DeleteAssociatedCompanyRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<DeleteAssociatedCompany200Response>> {
|
|
525
|
+
const requestOptions = await this.deleteAssociatedCompanyRequestOpts(requestParameters);
|
|
526
|
+
const response = await this.request(requestOptions, initOverrides);
|
|
527
|
+
|
|
528
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => DeleteAssociatedCompany200ResponseFromJSON(jsonValue));
|
|
529
|
+
}
|
|
530
|
+
|
|
531
|
+
/**
|
|
532
|
+
* Permanently deletes an associated company. This action is irreversible.
|
|
533
|
+
* Delete associated company
|
|
534
|
+
*/
|
|
535
|
+
async deleteAssociatedCompany(requestParameters: DeleteAssociatedCompanyRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<DeleteAssociatedCompany200Response> {
|
|
536
|
+
const response = await this.deleteAssociatedCompanyRaw(requestParameters, initOverrides);
|
|
537
|
+
return await response.value();
|
|
538
|
+
}
|
|
539
|
+
|
|
540
|
+
/**
|
|
541
|
+
* Creates request options for getCompanyDocumentMetrics without sending the request
|
|
542
|
+
*/
|
|
543
|
+
async getCompanyDocumentMetricsRequestOpts(requestParameters: GetCompanyDocumentMetricsRequest): Promise<runtime.RequestOpts> {
|
|
544
|
+
if (requestParameters['companyId'] == null) {
|
|
545
|
+
throw new runtime.RequiredError(
|
|
546
|
+
'companyId',
|
|
547
|
+
'Required parameter "companyId" was null or undefined when calling getCompanyDocumentMetrics().'
|
|
548
|
+
);
|
|
549
|
+
}
|
|
550
|
+
|
|
551
|
+
const queryParameters: any = {};
|
|
552
|
+
|
|
553
|
+
const headerParameters: runtime.HTTPHeaders = {};
|
|
554
|
+
|
|
555
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
556
|
+
// oauth required
|
|
557
|
+
headerParameters["Authorization"] = await this.configuration.accessToken("oauth2", ["business:read"]);
|
|
558
|
+
}
|
|
559
|
+
|
|
560
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
561
|
+
const token = this.configuration.accessToken;
|
|
562
|
+
const tokenString = await token("bearerAuth", []);
|
|
563
|
+
|
|
564
|
+
if (tokenString) {
|
|
565
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
566
|
+
}
|
|
567
|
+
}
|
|
568
|
+
|
|
569
|
+
let urlPath = `/associated-companies/{companyId}/documents-metrics`;
|
|
570
|
+
urlPath = urlPath.replace(`{${"companyId"}}`, encodeURIComponent(String(requestParameters['companyId'])));
|
|
571
|
+
|
|
572
|
+
return {
|
|
573
|
+
path: urlPath,
|
|
574
|
+
method: 'GET',
|
|
575
|
+
headers: headerParameters,
|
|
576
|
+
query: queryParameters,
|
|
577
|
+
};
|
|
578
|
+
}
|
|
579
|
+
|
|
580
|
+
/**
|
|
581
|
+
* Get company document metrics
|
|
582
|
+
*/
|
|
583
|
+
async getCompanyDocumentMetricsRaw(requestParameters: GetCompanyDocumentMetricsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<CompanyDocumentMetrics>> {
|
|
584
|
+
const requestOptions = await this.getCompanyDocumentMetricsRequestOpts(requestParameters);
|
|
585
|
+
const response = await this.request(requestOptions, initOverrides);
|
|
586
|
+
|
|
587
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => CompanyDocumentMetricsFromJSON(jsonValue));
|
|
588
|
+
}
|
|
589
|
+
|
|
590
|
+
/**
|
|
591
|
+
* Get company document metrics
|
|
592
|
+
*/
|
|
593
|
+
async getCompanyDocumentMetrics(requestParameters: GetCompanyDocumentMetricsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<CompanyDocumentMetrics> {
|
|
594
|
+
const response = await this.getCompanyDocumentMetricsRaw(requestParameters, initOverrides);
|
|
595
|
+
return await response.value();
|
|
596
|
+
}
|
|
597
|
+
|
|
598
|
+
/**
|
|
599
|
+
* Creates request options for getCompanyMetrics without sending the request
|
|
600
|
+
*/
|
|
601
|
+
async getCompanyMetricsRequestOpts(requestParameters: GetCompanyMetricsRequest): Promise<runtime.RequestOpts> {
|
|
602
|
+
if (requestParameters['companyId'] == null) {
|
|
357
603
|
throw new runtime.RequiredError(
|
|
358
|
-
'
|
|
359
|
-
'Required parameter "
|
|
604
|
+
'companyId',
|
|
605
|
+
'Required parameter "companyId" was null or undefined when calling getCompanyMetrics().'
|
|
360
606
|
);
|
|
361
607
|
}
|
|
362
608
|
|
|
@@ -364,10 +610,65 @@ export class AssociatedCompaniesApi extends runtime.BaseAPI implements Associate
|
|
|
364
610
|
|
|
365
611
|
const headerParameters: runtime.HTTPHeaders = {};
|
|
366
612
|
|
|
367
|
-
if (
|
|
368
|
-
|
|
613
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
614
|
+
// oauth required
|
|
615
|
+
headerParameters["Authorization"] = await this.configuration.accessToken("oauth2", ["business:read"]);
|
|
616
|
+
}
|
|
617
|
+
|
|
618
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
619
|
+
const token = this.configuration.accessToken;
|
|
620
|
+
const tokenString = await token("bearerAuth", []);
|
|
621
|
+
|
|
622
|
+
if (tokenString) {
|
|
623
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
624
|
+
}
|
|
625
|
+
}
|
|
626
|
+
|
|
627
|
+
let urlPath = `/associated-companies/{companyId}/metrics`;
|
|
628
|
+
urlPath = urlPath.replace(`{${"companyId"}}`, encodeURIComponent(String(requestParameters['companyId'])));
|
|
629
|
+
|
|
630
|
+
return {
|
|
631
|
+
path: urlPath,
|
|
632
|
+
method: 'GET',
|
|
633
|
+
headers: headerParameters,
|
|
634
|
+
query: queryParameters,
|
|
635
|
+
};
|
|
636
|
+
}
|
|
637
|
+
|
|
638
|
+
/**
|
|
639
|
+
* Get company metrics
|
|
640
|
+
*/
|
|
641
|
+
async getCompanyMetricsRaw(requestParameters: GetCompanyMetricsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<CompanyMetrics>> {
|
|
642
|
+
const requestOptions = await this.getCompanyMetricsRequestOpts(requestParameters);
|
|
643
|
+
const response = await this.request(requestOptions, initOverrides);
|
|
644
|
+
|
|
645
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => CompanyMetricsFromJSON(jsonValue));
|
|
646
|
+
}
|
|
647
|
+
|
|
648
|
+
/**
|
|
649
|
+
* Get company metrics
|
|
650
|
+
*/
|
|
651
|
+
async getCompanyMetrics(requestParameters: GetCompanyMetricsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<CompanyMetrics> {
|
|
652
|
+
const response = await this.getCompanyMetricsRaw(requestParameters, initOverrides);
|
|
653
|
+
return await response.value();
|
|
654
|
+
}
|
|
655
|
+
|
|
656
|
+
/**
|
|
657
|
+
* Creates request options for listAssociatedCompanies without sending the request
|
|
658
|
+
*/
|
|
659
|
+
async listAssociatedCompaniesRequestOpts(requestParameters: ListAssociatedCompaniesRequest): Promise<runtime.RequestOpts> {
|
|
660
|
+
const queryParameters: any = {};
|
|
661
|
+
|
|
662
|
+
if (requestParameters['page'] != null) {
|
|
663
|
+
queryParameters['page'] = requestParameters['page'];
|
|
664
|
+
}
|
|
665
|
+
|
|
666
|
+
if (requestParameters['limit'] != null) {
|
|
667
|
+
queryParameters['limit'] = requestParameters['limit'];
|
|
369
668
|
}
|
|
370
669
|
|
|
670
|
+
const headerParameters: runtime.HTTPHeaders = {};
|
|
671
|
+
|
|
371
672
|
if (this.configuration && this.configuration.accessToken) {
|
|
372
673
|
// oauth required
|
|
373
674
|
headerParameters["Authorization"] = await this.configuration.accessToken("oauth2", ["business:read"]);
|
|
@@ -393,7 +694,6 @@ export class AssociatedCompaniesApi extends runtime.BaseAPI implements Associate
|
|
|
393
694
|
}
|
|
394
695
|
|
|
395
696
|
/**
|
|
396
|
-
* Returns all companies and branches linked to the current tenant.
|
|
397
697
|
* List associated companies / branches
|
|
398
698
|
*/
|
|
399
699
|
async listAssociatedCompaniesRaw(requestParameters: ListAssociatedCompaniesRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<Array<AssociatedCompany>>> {
|
|
@@ -404,12 +704,110 @@ export class AssociatedCompaniesApi extends runtime.BaseAPI implements Associate
|
|
|
404
704
|
}
|
|
405
705
|
|
|
406
706
|
/**
|
|
407
|
-
* Returns all companies and branches linked to the current tenant.
|
|
408
707
|
* List associated companies / branches
|
|
409
708
|
*/
|
|
410
|
-
async listAssociatedCompanies(requestParameters: ListAssociatedCompaniesRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<Array<AssociatedCompany>> {
|
|
709
|
+
async listAssociatedCompanies(requestParameters: ListAssociatedCompaniesRequest = {}, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<Array<AssociatedCompany>> {
|
|
411
710
|
const response = await this.listAssociatedCompaniesRaw(requestParameters, initOverrides);
|
|
412
711
|
return await response.value();
|
|
413
712
|
}
|
|
414
713
|
|
|
714
|
+
/**
|
|
715
|
+
* Creates request options for updateAssociatedCompany without sending the request
|
|
716
|
+
*/
|
|
717
|
+
async updateAssociatedCompanyRequestOpts(requestParameters: UpdateAssociatedCompanyRequest): Promise<runtime.RequestOpts> {
|
|
718
|
+
if (requestParameters['companyId'] == null) {
|
|
719
|
+
throw new runtime.RequiredError(
|
|
720
|
+
'companyId',
|
|
721
|
+
'Required parameter "companyId" was null or undefined when calling updateAssociatedCompany().'
|
|
722
|
+
);
|
|
723
|
+
}
|
|
724
|
+
|
|
725
|
+
const queryParameters: any = {};
|
|
726
|
+
|
|
727
|
+
const headerParameters: runtime.HTTPHeaders = {};
|
|
728
|
+
|
|
729
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
730
|
+
// oauth required
|
|
731
|
+
headerParameters["Authorization"] = await this.configuration.accessToken("oauth2", ["business:update"]);
|
|
732
|
+
}
|
|
733
|
+
|
|
734
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
735
|
+
const token = this.configuration.accessToken;
|
|
736
|
+
const tokenString = await token("bearerAuth", []);
|
|
737
|
+
|
|
738
|
+
if (tokenString) {
|
|
739
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
740
|
+
}
|
|
741
|
+
}
|
|
742
|
+
const consumes: runtime.Consume[] = [
|
|
743
|
+
{ contentType: 'multipart/form-data' },
|
|
744
|
+
];
|
|
745
|
+
// @ts-ignore: canConsumeForm may be unused
|
|
746
|
+
const canConsumeForm = runtime.canConsumeForm(consumes);
|
|
747
|
+
|
|
748
|
+
let formParams: { append(param: string, value: any): any };
|
|
749
|
+
let useForm = false;
|
|
750
|
+
// use FormData to transmit files using content-type "multipart/form-data"
|
|
751
|
+
useForm = canConsumeForm;
|
|
752
|
+
if (useForm) {
|
|
753
|
+
formParams = new FormData();
|
|
754
|
+
} else {
|
|
755
|
+
formParams = new URLSearchParams();
|
|
756
|
+
}
|
|
757
|
+
|
|
758
|
+
if (requestParameters['name'] != null) {
|
|
759
|
+
formParams.append('name', requestParameters['name'] as any);
|
|
760
|
+
}
|
|
761
|
+
|
|
762
|
+
if (requestParameters['phone'] != null) {
|
|
763
|
+
formParams.append('phone', requestParameters['phone'] as any);
|
|
764
|
+
}
|
|
765
|
+
|
|
766
|
+
if (requestParameters['website'] != null) {
|
|
767
|
+
formParams.append('website', requestParameters['website'] as any);
|
|
768
|
+
}
|
|
769
|
+
|
|
770
|
+
if (requestParameters['city'] != null) {
|
|
771
|
+
formParams.append('city', requestParameters['city'] as any);
|
|
772
|
+
}
|
|
773
|
+
|
|
774
|
+
if (requestParameters['country'] != null) {
|
|
775
|
+
formParams.append('country', requestParameters['country'] as any);
|
|
776
|
+
}
|
|
777
|
+
|
|
778
|
+
if (requestParameters['logo'] != null) {
|
|
779
|
+
formParams.append('logo', requestParameters['logo'] as any);
|
|
780
|
+
}
|
|
781
|
+
|
|
782
|
+
|
|
783
|
+
let urlPath = `/associated-companies/{companyId}`;
|
|
784
|
+
urlPath = urlPath.replace(`{${"companyId"}}`, encodeURIComponent(String(requestParameters['companyId'])));
|
|
785
|
+
|
|
786
|
+
return {
|
|
787
|
+
path: urlPath,
|
|
788
|
+
method: 'PUT',
|
|
789
|
+
headers: headerParameters,
|
|
790
|
+
query: queryParameters,
|
|
791
|
+
body: formParams,
|
|
792
|
+
};
|
|
793
|
+
}
|
|
794
|
+
|
|
795
|
+
/**
|
|
796
|
+
* Update associated company
|
|
797
|
+
*/
|
|
798
|
+
async updateAssociatedCompanyRaw(requestParameters: UpdateAssociatedCompanyRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<CreateAssociatedCompany201Response>> {
|
|
799
|
+
const requestOptions = await this.updateAssociatedCompanyRequestOpts(requestParameters);
|
|
800
|
+
const response = await this.request(requestOptions, initOverrides);
|
|
801
|
+
|
|
802
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => CreateAssociatedCompany201ResponseFromJSON(jsonValue));
|
|
803
|
+
}
|
|
804
|
+
|
|
805
|
+
/**
|
|
806
|
+
* Update associated company
|
|
807
|
+
*/
|
|
808
|
+
async updateAssociatedCompany(requestParameters: UpdateAssociatedCompanyRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<CreateAssociatedCompany201Response> {
|
|
809
|
+
const response = await this.updateAssociatedCompanyRaw(requestParameters, initOverrides);
|
|
810
|
+
return await response.value();
|
|
811
|
+
}
|
|
812
|
+
|
|
415
813
|
}
|