vayu-ts 0.2.15 → 0.3.7
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/dist/example/index.d.ts +1 -0
- package/dist/example/index.js +74 -0
- package/dist/openapi/apis/AuthApi.js +8 -4
- package/dist/openapi/apis/CatalogProductsApi.d.ts +89 -0
- package/dist/openapi/apis/CatalogProductsApi.js +377 -0
- package/dist/openapi/apis/CloudUsageSubmissionApi.d.ts +25 -0
- package/dist/openapi/apis/CloudUsageSubmissionApi.js +89 -0
- package/dist/openapi/apis/ContractsApi.d.ts +21 -3
- package/dist/openapi/apis/ContractsApi.js +119 -21
- package/dist/openapi/apis/CreditsApi.js +24 -12
- package/dist/openapi/apis/CustomFieldsApi.d.ts +89 -0
- package/dist/openapi/apis/CustomFieldsApi.js +377 -0
- package/dist/openapi/apis/CustomersApi.d.ts +63 -0
- package/dist/openapi/apis/CustomersApi.js +360 -38
- package/dist/openapi/apis/EventsApi.d.ts +132 -1
- package/dist/openapi/apis/EventsApi.js +660 -25
- package/dist/openapi/apis/InvoicesApi.d.ts +19 -3
- package/dist/openapi/apis/InvoicesApi.js +91 -12
- package/dist/openapi/apis/MeasurementsApi.js +36 -18
- package/dist/openapi/apis/MetersApi.js +38 -19
- package/dist/openapi/apis/PlansApi.d.ts +56 -0
- package/dist/openapi/apis/PlansApi.js +225 -0
- package/dist/openapi/apis/ProductConsumptionsApi.js +10 -5
- package/dist/openapi/apis/WebhooksApi.js +10 -5
- package/dist/openapi/http/http.d.ts +6 -18
- package/dist/openapi/http/http.js +25 -13
- package/dist/openapi/http/isomorphic-fetch.d.ts +1 -0
- package/dist/openapi/http/isomorphic-fetch.js +4 -7
- package/dist/openapi/index.d.ts +1 -1
- package/dist/openapi/index.js +5 -1
- package/dist/openapi/models/Address.d.ts +5 -5
- package/dist/openapi/models/BillingInterval.d.ts +18 -0
- package/dist/openapi/models/BillingInterval.js +22 -0
- package/dist/openapi/models/CloudUsageResult.d.ts +83 -0
- package/dist/openapi/models/CloudUsageResult.js +103 -0
- package/dist/openapi/models/ConflictErrorResponse.d.ts +42 -0
- package/dist/openapi/models/ConflictErrorResponse.js +52 -0
- package/dist/openapi/models/Contact.d.ts +3 -1
- package/dist/openapi/models/Contact.js +13 -1
- package/dist/openapi/models/ContractStatus.d.ts +23 -0
- package/dist/openapi/models/ContractStatus.js +27 -0
- package/dist/openapi/models/CreateCatalogProductRequest.d.ts +42 -0
- package/dist/openapi/models/CreateCatalogProductRequest.js +44 -0
- package/dist/openapi/models/CreateCatalogProductResponse.d.ts +32 -0
- package/dist/openapi/models/CreateCatalogProductResponse.js +32 -0
- package/dist/openapi/models/CreateCatalogProductResponseCatalogProduct.d.ts +45 -0
- package/dist/openapi/models/CreateCatalogProductResponseCatalogProduct.js +62 -0
- package/dist/openapi/models/CreateContractRequest.d.ts +53 -5
- package/dist/openapi/models/CreateContractRequest.js +76 -4
- package/dist/openapi/models/CreateCustomFieldRequest.d.ts +71 -0
- package/dist/openapi/models/CreateCustomFieldRequest.js +90 -0
- package/dist/openapi/models/CreateCustomFieldResponse.d.ts +32 -0
- package/dist/openapi/models/CreateCustomFieldResponse.js +32 -0
- package/dist/openapi/models/CreateCustomFieldResponseCustomField.d.ts +74 -0
- package/dist/openapi/models/CreateCustomFieldResponseCustomField.js +108 -0
- package/dist/openapi/models/CreateCustomerRelationRequest.d.ts +38 -0
- package/dist/openapi/models/CreateCustomerRelationRequest.js +38 -0
- package/dist/openapi/models/CreateCustomerRelationResponse.d.ts +32 -0
- package/dist/openapi/models/CreateCustomerRelationResponse.js +32 -0
- package/dist/openapi/models/CreateCustomerRelationResponseCustomerRelation.d.ts +41 -0
- package/dist/openapi/models/CreateCustomerRelationResponseCustomerRelation.js +56 -0
- package/dist/openapi/models/CreateCustomerRequest.d.ts +70 -2
- package/dist/openapi/models/CreateCustomerRequest.js +112 -6
- package/dist/openapi/models/CreateCustomerResponseCustomer.d.ts +70 -2
- package/dist/openapi/models/CreateCustomerResponseCustomer.js +112 -6
- package/dist/openapi/models/CreditLedgerEntry.d.ts +3 -1
- package/dist/openapi/models/CreditLedgerEntry.js +8 -2
- package/dist/openapi/models/Currency.d.ts +24 -0
- package/dist/openapi/models/Currency.js +28 -0
- package/dist/openapi/models/CustomField.d.ts +65 -0
- package/dist/openapi/models/CustomField.js +78 -0
- package/dist/openapi/models/CustomFieldEntities.d.ts +20 -0
- package/dist/openapi/models/CustomFieldEntities.js +24 -0
- package/dist/openapi/models/CustomFieldValue.d.ts +33 -0
- package/dist/openapi/models/CustomFieldValue.js +44 -0
- package/dist/openapi/models/CustomFieldValueTypes.d.ts +20 -0
- package/dist/openapi/models/CustomFieldValueTypes.js +24 -0
- package/dist/openapi/models/CustomerCloudProviderSettings.d.ts +39 -0
- package/dist/openapi/models/CustomerCloudProviderSettings.js +51 -0
- package/dist/openapi/models/CustomerSource.d.ts +21 -0
- package/dist/openapi/models/CustomerSource.js +25 -0
- package/dist/openapi/models/DeleteCatalogProductResponse.d.ts +32 -0
- package/dist/openapi/models/DeleteCatalogProductResponse.js +32 -0
- package/dist/openapi/models/DeleteCatalogProductResponseCatalogProduct.d.ts +46 -0
- package/dist/openapi/models/DeleteCatalogProductResponseCatalogProduct.js +68 -0
- package/dist/openapi/models/DeleteContractResponseContract.d.ts +53 -5
- package/dist/openapi/models/DeleteContractResponseContract.js +76 -4
- package/dist/openapi/models/DeleteCustomFieldResponse.d.ts +32 -0
- package/dist/openapi/models/DeleteCustomFieldResponse.js +32 -0
- package/dist/openapi/models/DeleteCustomFieldResponseCustomField.d.ts +75 -0
- package/dist/openapi/models/DeleteCustomFieldResponseCustomField.js +114 -0
- package/dist/openapi/models/DeleteCustomerResponseCustomer.d.ts +70 -2
- package/dist/openapi/models/DeleteCustomerResponseCustomer.js +112 -6
- package/dist/openapi/models/DeleteEventsByRefsRequest.d.ts +31 -0
- package/dist/openapi/models/DeleteEventsByRefsRequest.js +32 -0
- package/dist/openapi/models/DeleteEventsByRefsResponse.d.ts +35 -0
- package/dist/openapi/models/DeleteEventsByRefsResponse.js +32 -0
- package/dist/openapi/models/DeleteEventsByRefsResponseEventsInner.d.ts +56 -0
- package/dist/openapi/models/DeleteEventsByRefsResponseEventsInner.js +80 -0
- package/dist/openapi/models/DeletePlanResponse.d.ts +32 -0
- package/dist/openapi/models/DeletePlanResponse.js +32 -0
- package/dist/openapi/models/DeletePlanResponsePlan.d.ts +42 -0
- package/dist/openapi/models/DeletePlanResponsePlan.js +68 -0
- package/dist/openapi/models/EventsDryRunResponseObjectMeterWithValuesInner.d.ts +1 -1
- package/dist/openapi/models/ExternalOverageStrategy.d.ts +20 -0
- package/dist/openapi/models/ExternalOverageStrategy.js +24 -0
- package/dist/openapi/models/GetCatalogProductResponse.d.ts +32 -0
- package/dist/openapi/models/GetCatalogProductResponse.js +32 -0
- package/dist/openapi/models/GetContractByIntegrationIdResponse.d.ts +32 -0
- package/dist/openapi/models/GetContractByIntegrationIdResponse.js +32 -0
- package/dist/openapi/models/GetContractResponseContract.d.ts +53 -5
- package/dist/openapi/models/GetContractResponseContract.js +76 -4
- package/dist/openapi/models/GetCustomFieldResponse.d.ts +32 -0
- package/dist/openapi/models/GetCustomFieldResponse.js +32 -0
- package/dist/openapi/models/GetCustomerByIntegrationIdResponse.d.ts +32 -0
- package/dist/openapi/models/GetCustomerByIntegrationIdResponse.js +32 -0
- package/dist/openapi/models/GetCustomerByNameResponse.d.ts +32 -0
- package/dist/openapi/models/GetCustomerByNameResponse.js +32 -0
- package/dist/openapi/models/GetCustomerByNameResponseCustomer.d.ts +123 -0
- package/dist/openapi/models/GetCustomerByNameResponseCustomer.js +183 -0
- package/dist/openapi/models/GetCustomerRelationResponse.d.ts +32 -0
- package/dist/openapi/models/GetCustomerRelationResponse.js +32 -0
- package/dist/openapi/models/GetInvoiceResponseInvoice.d.ts +14 -0
- package/dist/openapi/models/GetInvoiceResponseInvoice.js +30 -0
- package/dist/openapi/models/GetInvoiceResponseInvoiceRevenueBreakdown.d.ts +39 -0
- package/dist/openapi/models/GetInvoiceResponseInvoiceRevenueBreakdown.js +65 -0
- package/dist/openapi/models/GetPlanResponse.d.ts +32 -0
- package/dist/openapi/models/GetPlanResponse.js +32 -0
- package/dist/openapi/models/GetPlanResponsePlan.d.ts +41 -0
- package/dist/openapi/models/GetPlanResponsePlan.js +62 -0
- package/dist/openapi/models/IntegrationEntity.d.ts +42 -0
- package/dist/openapi/models/IntegrationEntity.js +62 -0
- package/dist/openapi/models/IntegrationEntityTypes.d.ts +23 -0
- package/dist/openapi/models/IntegrationEntityTypes.js +27 -0
- package/dist/openapi/models/IntegrationProviders.d.ts +26 -0
- package/dist/openapi/models/IntegrationProviders.js +30 -0
- package/dist/openapi/models/IntegrationType.d.ts +26 -0
- package/dist/openapi/models/IntegrationType.js +30 -0
- package/dist/openapi/models/InternalServerErrorResponse.d.ts +42 -0
- package/dist/openapi/models/InternalServerErrorResponse.js +52 -0
- package/dist/openapi/models/InvoiceBillingStatus.d.ts +21 -0
- package/dist/openapi/models/InvoiceBillingStatus.js +25 -0
- package/dist/openapi/models/InvoicePaymentStatusResponse.d.ts +39 -0
- package/dist/openapi/models/InvoicePaymentStatusResponse.js +74 -0
- package/dist/openapi/models/ListCatalogProductsResponse.d.ts +35 -0
- package/dist/openapi/models/ListCatalogProductsResponse.js +50 -0
- package/dist/openapi/models/ListCustomFieldsResponse.d.ts +35 -0
- package/dist/openapi/models/ListCustomFieldsResponse.js +50 -0
- package/dist/openapi/models/ListPlansResponse.d.ts +35 -0
- package/dist/openapi/models/ListPlansResponse.js +50 -0
- package/dist/openapi/models/NotFoundErrorResponse.d.ts +42 -0
- package/dist/openapi/models/NotFoundErrorResponse.js +52 -0
- package/dist/openapi/models/NotificationEventType.d.ts +7 -1
- package/dist/openapi/models/NotificationEventType.js +6 -0
- package/dist/openapi/models/ObjectSerializer.d.ts +112 -0
- package/dist/openapi/models/ObjectSerializer.js +367 -0
- package/dist/openapi/models/PartnerSubmissionDetail.d.ts +46 -0
- package/dist/openapi/models/PartnerSubmissionDetail.js +49 -0
- package/dist/openapi/models/PaymentInfo.d.ts +45 -0
- package/dist/openapi/models/PaymentInfo.js +89 -0
- package/dist/openapi/models/PaymentInfoDepositTo.d.ts +32 -0
- package/dist/openapi/models/PaymentInfoDepositTo.js +38 -0
- package/dist/openapi/models/PaymentTerm.d.ts +18 -0
- package/dist/openapi/models/PaymentTerm.js +22 -0
- package/dist/openapi/models/PlanBillingData.d.ts +41 -0
- package/dist/openapi/models/PlanBillingData.js +59 -0
- package/dist/openapi/models/PlanDuration.d.ts +30 -0
- package/dist/openapi/models/PlanDuration.js +25 -0
- package/dist/openapi/models/PlanStatus.d.ts +19 -0
- package/dist/openapi/models/PlanStatus.js +23 -0
- package/dist/openapi/models/ProductCloudProviderSettings.d.ts +39 -0
- package/dist/openapi/models/ProductCloudProviderSettings.js +51 -0
- package/dist/openapi/models/ProductGroup.d.ts +65 -0
- package/dist/openapi/models/ProductGroup.js +80 -0
- package/dist/openapi/models/ProductGroupCommitment.d.ts +53 -0
- package/dist/openapi/models/ProductGroupCommitment.js +64 -0
- package/dist/openapi/models/ProductGroupProductsInner.d.ts +68 -0
- package/dist/openapi/models/ProductGroupProductsInner.js +98 -0
- package/dist/openapi/models/ProductGroupProductsInnerCommitment.d.ts +53 -0
- package/dist/openapi/models/ProductGroupProductsInnerCommitment.js +64 -0
- package/dist/openapi/models/ProductGroupProductsInnerCommitmentScheduling.d.ts +39 -0
- package/dist/openapi/models/ProductGroupProductsInnerCommitmentScheduling.js +41 -0
- package/dist/openapi/models/ProductGroupProductsInnerCommitmentSchedulingDuration.d.ts +41 -0
- package/dist/openapi/models/ProductGroupProductsInnerCommitmentSchedulingDuration.js +48 -0
- package/dist/openapi/models/ProductGroupProductsInnerPricing.d.ts +38 -0
- package/dist/openapi/models/ProductGroupProductsInnerPricing.js +24 -0
- package/dist/openapi/models/ProductGroupProductsInnerPricingOneOf.d.ts +41 -0
- package/dist/openapi/models/ProductGroupProductsInnerPricingOneOf.js +54 -0
- package/dist/openapi/models/ProductGroupProductsInnerPricingOneOf1.d.ts +39 -0
- package/dist/openapi/models/ProductGroupProductsInnerPricingOneOf1.js +54 -0
- package/dist/openapi/models/ProductGroupProductsInnerPricingOneOf1InstallmentsInner.d.ts +32 -0
- package/dist/openapi/models/ProductGroupProductsInnerPricingOneOf1InstallmentsInner.js +38 -0
- package/dist/openapi/models/ProductGroupProductsInnerPricingOneOf2.d.ts +39 -0
- package/dist/openapi/models/ProductGroupProductsInnerPricingOneOf2.js +54 -0
- package/dist/openapi/models/ProductGroupProductsInnerPricingOneOf2SubscriptionCadence.d.ts +38 -0
- package/dist/openapi/models/ProductGroupProductsInnerPricingOneOf2SubscriptionCadence.js +45 -0
- package/dist/openapi/models/ProductGroupProductsInnerPricingOneOf3.d.ts +46 -0
- package/dist/openapi/models/ProductGroupProductsInnerPricingOneOf3.js +78 -0
- package/dist/openapi/models/ProductGroupProductsInnerPricingOneOf3SubscriptionCadence.d.ts +38 -0
- package/dist/openapi/models/ProductGroupProductsInnerPricingOneOf3SubscriptionCadence.js +45 -0
- package/dist/openapi/models/ProductGroupProductsInnerPricingOneOf3TiersInner.d.ts +35 -0
- package/dist/openapi/models/ProductGroupProductsInnerPricingOneOf3TiersInner.js +56 -0
- package/dist/openapi/models/ProductGroupProductsInnerPricingOneOf4.d.ts +41 -0
- package/dist/openapi/models/ProductGroupProductsInnerPricingOneOf4.js +60 -0
- package/dist/openapi/models/ProductGroupProductsInnerPricingOneOf5.d.ts +42 -0
- package/dist/openapi/models/ProductGroupProductsInnerPricingOneOf5.js +48 -0
- package/dist/openapi/models/ProductGroupProductsInnerPricingOneOf6.d.ts +42 -0
- package/dist/openapi/models/ProductGroupProductsInnerPricingOneOf6.js +48 -0
- package/dist/openapi/models/ProductGroupProductsInnerPricingOneOfDiscount.d.ts +53 -0
- package/dist/openapi/models/ProductGroupProductsInnerPricingOneOfDiscount.js +58 -0
- package/dist/openapi/models/ProductGroupProductsInnerScheduling.d.ts +39 -0
- package/dist/openapi/models/ProductGroupProductsInnerScheduling.js +41 -0
- package/dist/openapi/models/ProductGroupProductsInnerSchedulingDuration.d.ts +41 -0
- package/dist/openapi/models/ProductGroupProductsInnerSchedulingDuration.js +48 -0
- package/dist/openapi/models/QueryEventsResponse.d.ts +3 -3
- package/dist/openapi/models/QueryEventsResponse.js +18 -0
- package/dist/openapi/models/RateLimitErrorResponse.d.ts +42 -0
- package/dist/openapi/models/RateLimitErrorResponse.js +52 -0
- package/dist/openapi/models/RequestTooLongErrorResponse.d.ts +42 -0
- package/dist/openapi/models/RequestTooLongErrorResponse.js +52 -0
- package/dist/openapi/models/SubmitCloudUsageRequest.d.ts +39 -0
- package/dist/openapi/models/SubmitCloudUsageRequest.js +38 -0
- package/dist/openapi/models/SyncStatus.d.ts +16 -0
- package/dist/openapi/models/SyncStatus.js +20 -0
- package/dist/openapi/models/UnauthorizedErrorResponse.d.ts +42 -0
- package/dist/openapi/models/UnauthorizedErrorResponse.js +52 -0
- package/dist/openapi/models/UnlimitedDuration.d.ts +14 -0
- package/dist/openapi/models/UnlimitedDuration.js +18 -0
- package/dist/openapi/models/UpdateCatalogProductRequest.d.ts +42 -0
- package/dist/openapi/models/UpdateCatalogProductRequest.js +44 -0
- package/dist/openapi/models/UpdateCatalogProductResponse.d.ts +32 -0
- package/dist/openapi/models/UpdateCatalogProductResponse.js +32 -0
- package/dist/openapi/models/UpdateCustomFieldRequest.d.ts +71 -0
- package/dist/openapi/models/UpdateCustomFieldRequest.js +90 -0
- package/dist/openapi/models/UpdateCustomFieldResponse.d.ts +32 -0
- package/dist/openapi/models/UpdateCustomFieldResponse.js +32 -0
- package/dist/openapi/models/UpdateCustomerRequest.d.ts +70 -2
- package/dist/openapi/models/UpdateCustomerRequest.js +112 -6
- package/dist/openapi/models/UsageWindow.d.ts +41 -0
- package/dist/openapi/models/UsageWindow.js +41 -0
- package/dist/openapi/models/V2DeleteEventResponse.d.ts +32 -0
- package/dist/openapi/models/V2DeleteEventResponse.js +32 -0
- package/dist/openapi/models/V2DeleteEventsByRefsRequest.d.ts +31 -0
- package/dist/openapi/models/V2DeleteEventsByRefsRequest.js +32 -0
- package/dist/openapi/models/V2DeleteEventsByRefsResponse.d.ts +35 -0
- package/dist/openapi/models/V2DeleteEventsByRefsResponse.js +32 -0
- package/dist/openapi/models/V2EventsDryRunRequest.d.ts +32 -0
- package/dist/openapi/models/V2EventsDryRunRequest.js +32 -0
- package/dist/openapi/models/V2EventsDryRunResponse.d.ts +32 -0
- package/dist/openapi/models/V2EventsDryRunResponse.js +32 -0
- package/dist/openapi/models/V2GetEventResponse.d.ts +32 -0
- package/dist/openapi/models/V2GetEventResponse.js +32 -0
- package/dist/openapi/models/V2QueryEventsAggregationRequest.d.ts +45 -0
- package/dist/openapi/models/V2QueryEventsAggregationRequest.js +70 -0
- package/dist/openapi/models/V2QueryEventsAggregationRequestMetersInner.d.ts +39 -0
- package/dist/openapi/models/V2QueryEventsAggregationRequestMetersInner.js +62 -0
- package/dist/openapi/models/V2QueryEventsAggregationRequestMetersInnerAggregation.d.ts +35 -0
- package/dist/openapi/models/V2QueryEventsAggregationRequestMetersInnerAggregation.js +44 -0
- package/dist/openapi/models/V2QueryEventsAggregationRequestMetersInnerAggregationFieldArithmetic.d.ts +38 -0
- package/dist/openapi/models/V2QueryEventsAggregationRequestMetersInnerAggregationFieldArithmetic.js +45 -0
- package/dist/openapi/models/V2QueryEventsAggregationRequestMetersInnerFiltersInner.d.ts +43 -0
- package/dist/openapi/models/V2QueryEventsAggregationRequestMetersInnerFiltersInner.js +54 -0
- package/dist/openapi/models/V2QueryEventsAggregationRequestMetersInnerFiltersInnerValue.d.ts +30 -0
- package/dist/openapi/models/V2QueryEventsAggregationRequestMetersInnerFiltersInnerValue.js +25 -0
- package/dist/openapi/models/V2QueryEventsAggregationRequestMetersInnerSqlFullQuery.d.ts +34 -0
- package/dist/openapi/models/V2QueryEventsAggregationRequestMetersInnerSqlFullQuery.js +38 -0
- package/dist/openapi/models/V2QueryEventsAggregationRequestPeriod.d.ts +32 -0
- package/dist/openapi/models/V2QueryEventsAggregationRequestPeriod.js +38 -0
- package/dist/openapi/models/V2QueryEventsAggregationResponse.d.ts +42 -0
- package/dist/openapi/models/V2QueryEventsAggregationResponse.js +52 -0
- package/dist/openapi/models/V2QueryEventsAggregationResponseDataPointsInner.d.ts +34 -0
- package/dist/openapi/models/V2QueryEventsAggregationResponseDataPointsInner.js +38 -0
- package/dist/openapi/models/V2QueryEventsResponse.d.ts +35 -0
- package/dist/openapi/models/V2QueryEventsResponse.js +50 -0
- package/dist/openapi/models/V2SendEventsRequest.d.ts +32 -0
- package/dist/openapi/models/V2SendEventsRequest.js +32 -0
- package/dist/openapi/models/V2SendEventsResponse.d.ts +40 -0
- package/dist/openapi/models/V2SendEventsResponse.js +38 -0
- package/dist/openapi/models/ValidationErrorResponse.d.ts +51 -0
- package/dist/openapi/models/ValidationErrorResponse.js +60 -0
- package/dist/openapi/models/ValidationErrorResponseParamsInner.d.ts +38 -0
- package/dist/openapi/models/ValidationErrorResponseParamsInner.js +38 -0
- package/dist/openapi/models/WebhookSubscribeRequest.d.ts +1 -0
- package/dist/openapi/models/WebhookSubscribeRequest.js +6 -0
- package/dist/openapi/models/all.d.ts +112 -0
- package/dist/openapi/models/all.js +112 -0
- package/dist/openapi/types/ObservableAPI.d.ts +447 -14
- package/dist/openapi/types/ObservableAPI.js +907 -29
- package/dist/openapi/types/PromiseAPI.d.ts +439 -14
- package/dist/openapi/types/PromiseAPI.js +600 -38
- package/dist/sdk/clients/CatalogProductsClient.d.ts +11 -0
- package/dist/sdk/clients/CatalogProductsClient.js +28 -0
- package/dist/sdk/clients/CloudUsageSubmissionClient.d.ts +6 -0
- package/dist/sdk/clients/CloudUsageSubmissionClient.js +14 -0
- package/dist/sdk/clients/ContractsClient.d.ts +2 -1
- package/dist/sdk/clients/ContractsClient.js +3 -0
- package/dist/sdk/clients/CreditsClient.d.ts +9 -0
- package/dist/sdk/clients/CreditsClient.js +22 -0
- package/dist/sdk/clients/CustomersClient.d.ts +5 -1
- package/dist/sdk/clients/CustomersClient.js +12 -0
- package/dist/sdk/clients/EventsClient.d.ts +2 -1
- package/dist/sdk/clients/EventsClient.js +4 -1
- package/dist/sdk/clients/InvoicesClient.d.ts +1 -0
- package/dist/sdk/clients/InvoicesClient.js +3 -0
- package/dist/sdk/clients/MeasurementsClient.d.ts +10 -0
- package/dist/sdk/clients/MeasurementsClient.js +25 -0
- package/dist/sdk/clients/WebhooksClient.d.ts +2 -0
- package/dist/sdk/clients/WebhooksClient.js +14 -0
- package/dist/sdk/clients/index.d.ts +4 -0
- package/dist/sdk/clients/index.js +4 -0
- package/dist/sdk/index.d.ts +6 -1
- package/dist/sdk/index.js +13 -0
- package/dist/sdk/services/authenticated-http-library.d.ts +11 -0
- package/dist/sdk/services/authenticated-http-library.js +29 -0
- package/dist/sdk/services/authenticator.d.ts +11 -0
- package/dist/sdk/services/authenticator.js +57 -0
- package/dist/sdk/services/configuration.service.d.ts +7 -6
- package/dist/sdk/services/configuration.service.js +12 -44
- package/dist/sdk/types/CatalogProducts.d.ts +1 -0
- package/dist/sdk/types/CatalogProducts.js +2 -0
- package/dist/sdk/types/CloudUsageSubmission.d.ts +1 -0
- package/dist/sdk/types/CloudUsageSubmission.js +2 -0
- package/dist/sdk/types/Contracts.d.ts +1 -1
- package/dist/sdk/types/Credits.d.ts +1 -0
- package/dist/sdk/types/Credits.js +2 -0
- package/dist/sdk/types/Customers.d.ts +1 -1
- package/dist/sdk/types/Events.d.ts +1 -1
- package/dist/sdk/types/Invoices.d.ts +1 -1
- package/dist/sdk/types/Measurements.d.ts +1 -0
- package/dist/sdk/types/Measurements.js +2 -0
- package/dist/sdk/types/index.d.ts +4 -0
- package/dist/sdk/types/index.js +4 -0
- package/dist/sdk-v2/services/configuration.service.js +16 -8
- package/package.json +3 -4
|
@@ -2,6 +2,7 @@ import { BaseAPIRequestFactory } from './baseapi';
|
|
|
2
2
|
import { Configuration } from '../configuration';
|
|
3
3
|
import { RequestContext, ResponseContext, HttpInfo } from '../http/http';
|
|
4
4
|
import { GetInvoiceResponse } from '../models/GetInvoiceResponse';
|
|
5
|
+
import { InvoicePaymentStatusResponse } from '../models/InvoicePaymentStatusResponse';
|
|
5
6
|
import { ListInvoicesResponse } from '../models/ListInvoicesResponse';
|
|
6
7
|
/**
|
|
7
8
|
* no description
|
|
@@ -14,12 +15,19 @@ export declare class InvoicesApiRequestFactory extends BaseAPIRequestFactory {
|
|
|
14
15
|
*/
|
|
15
16
|
getInvoice(invoiceId: string, _options?: Configuration): Promise<RequestContext>;
|
|
16
17
|
/**
|
|
17
|
-
*
|
|
18
|
-
*
|
|
18
|
+
* Use this endpoint to retrieve payment status information for a specific invoice, including payment status, amount due, amount paid, total, due date, paid date, and invoice PDF URL.
|
|
19
|
+
* Get invoice payment status
|
|
20
|
+
* @param invoiceId
|
|
21
|
+
*/
|
|
22
|
+
getInvoicePaymentStatus(invoiceId: string, _options?: Configuration): Promise<RequestContext>;
|
|
23
|
+
/**
|
|
24
|
+
* List invoices for the account. Optionally filter by customerId to retrieve invoices for a specific customer.
|
|
25
|
+
* List invoices
|
|
19
26
|
* @param limit
|
|
20
27
|
* @param cursor
|
|
28
|
+
* @param customerId
|
|
21
29
|
*/
|
|
22
|
-
listInvoices(limit?: number, cursor?: string, _options?: Configuration): Promise<RequestContext>;
|
|
30
|
+
listInvoices(limit?: number, cursor?: string, customerId?: string, _options?: Configuration): Promise<RequestContext>;
|
|
23
31
|
}
|
|
24
32
|
export declare class InvoicesApiResponseProcessor {
|
|
25
33
|
/**
|
|
@@ -30,6 +38,14 @@ export declare class InvoicesApiResponseProcessor {
|
|
|
30
38
|
* @throws ApiException if the response code was not in [200, 299]
|
|
31
39
|
*/
|
|
32
40
|
getInvoiceWithHttpInfo(response: ResponseContext): Promise<HttpInfo<GetInvoiceResponse>>;
|
|
41
|
+
/**
|
|
42
|
+
* Unwraps the actual response sent by the server from the response context and deserializes the response content
|
|
43
|
+
* to the expected objects
|
|
44
|
+
*
|
|
45
|
+
* @params response Response returned by the server for a request to getInvoicePaymentStatus
|
|
46
|
+
* @throws ApiException if the response code was not in [200, 299]
|
|
47
|
+
*/
|
|
48
|
+
getInvoicePaymentStatusWithHttpInfo(response: ResponseContext): Promise<HttpInfo<InvoicePaymentStatusResponse>>;
|
|
33
49
|
/**
|
|
34
50
|
* Unwraps the actual response sent by the server from the response context and deserializes the response content
|
|
35
51
|
* to the expected objects
|
|
@@ -41,12 +41,42 @@ class InvoicesApiRequestFactory extends baseapi_1.BaseAPIRequestFactory {
|
|
|
41
41
|
return requestContext;
|
|
42
42
|
}
|
|
43
43
|
/**
|
|
44
|
-
*
|
|
45
|
-
*
|
|
44
|
+
* Use this endpoint to retrieve payment status information for a specific invoice, including payment status, amount due, amount paid, total, due date, paid date, and invoice PDF URL.
|
|
45
|
+
* Get invoice payment status
|
|
46
|
+
* @param invoiceId
|
|
47
|
+
*/
|
|
48
|
+
async getInvoicePaymentStatus(invoiceId, _options) {
|
|
49
|
+
let _config = _options || this.configuration;
|
|
50
|
+
// verify required parameter 'invoiceId' is not null or undefined
|
|
51
|
+
if (invoiceId === null || invoiceId === undefined) {
|
|
52
|
+
throw new baseapi_1.RequiredError("InvoicesApi", "getInvoicePaymentStatus", "invoiceId");
|
|
53
|
+
}
|
|
54
|
+
// Path Params
|
|
55
|
+
const localVarPath = '/invoices/{invoiceId}/payment-status'
|
|
56
|
+
.replace('{' + 'invoiceId' + '}', encodeURIComponent(String(invoiceId)));
|
|
57
|
+
// Make Request Context
|
|
58
|
+
const requestContext = _config.baseServer.makeRequestContext(localVarPath, http_1.HttpMethod.GET);
|
|
59
|
+
requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8");
|
|
60
|
+
let authMethod;
|
|
61
|
+
// Apply auth methods
|
|
62
|
+
authMethod = _config.authMethods["BearerAuthorizer"];
|
|
63
|
+
if (authMethod?.applySecurityAuthentication) {
|
|
64
|
+
await authMethod?.applySecurityAuthentication(requestContext);
|
|
65
|
+
}
|
|
66
|
+
const defaultAuth = _options?.authMethods?.default || this.configuration?.authMethods?.default;
|
|
67
|
+
if (defaultAuth?.applySecurityAuthentication) {
|
|
68
|
+
await defaultAuth?.applySecurityAuthentication(requestContext);
|
|
69
|
+
}
|
|
70
|
+
return requestContext;
|
|
71
|
+
}
|
|
72
|
+
/**
|
|
73
|
+
* List invoices for the account. Optionally filter by customerId to retrieve invoices for a specific customer.
|
|
74
|
+
* List invoices
|
|
46
75
|
* @param limit
|
|
47
76
|
* @param cursor
|
|
77
|
+
* @param customerId
|
|
48
78
|
*/
|
|
49
|
-
async listInvoices(limit, cursor, _options) {
|
|
79
|
+
async listInvoices(limit, cursor, customerId, _options) {
|
|
50
80
|
let _config = _options || this.configuration;
|
|
51
81
|
// Path Params
|
|
52
82
|
const localVarPath = '/invoices';
|
|
@@ -61,6 +91,10 @@ class InvoicesApiRequestFactory extends baseapi_1.BaseAPIRequestFactory {
|
|
|
61
91
|
if (cursor !== undefined) {
|
|
62
92
|
requestContext.setQueryParam("cursor", ObjectSerializer_1.ObjectSerializer.serialize(cursor, "string", ""));
|
|
63
93
|
}
|
|
94
|
+
// Query Params
|
|
95
|
+
if (customerId !== undefined) {
|
|
96
|
+
requestContext.setQueryParam("customerId", ObjectSerializer_1.ObjectSerializer.serialize(customerId, "string", ""));
|
|
97
|
+
}
|
|
64
98
|
let authMethod;
|
|
65
99
|
// Apply auth methods
|
|
66
100
|
authMethod = _config.authMethods["BearerAuthorizer"];
|
|
@@ -90,19 +124,24 @@ class InvoicesApiResponseProcessor {
|
|
|
90
124
|
return new http_1.HttpInfo(response.httpStatusCode, response.headers, response.body, body);
|
|
91
125
|
}
|
|
92
126
|
if ((0, util_1.isCodeInRange)("400", response.httpStatusCode)) {
|
|
93
|
-
|
|
127
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(await response.body.text(), contentType), "ValidationErrorResponse", "");
|
|
128
|
+
throw new exception_1.ApiException(response.httpStatusCode, "Bad Request", body, response.headers);
|
|
94
129
|
}
|
|
95
130
|
if ((0, util_1.isCodeInRange)("401", response.httpStatusCode)) {
|
|
96
|
-
|
|
131
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(await response.body.text(), contentType), "UnauthorizedErrorResponse", "");
|
|
132
|
+
throw new exception_1.ApiException(response.httpStatusCode, "Unauthorized", body, response.headers);
|
|
97
133
|
}
|
|
98
134
|
if ((0, util_1.isCodeInRange)("404", response.httpStatusCode)) {
|
|
99
|
-
|
|
135
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(await response.body.text(), contentType), "NotFoundErrorResponse", "");
|
|
136
|
+
throw new exception_1.ApiException(response.httpStatusCode, "Not Found", body, response.headers);
|
|
100
137
|
}
|
|
101
138
|
if ((0, util_1.isCodeInRange)("429", response.httpStatusCode)) {
|
|
102
|
-
|
|
139
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(await response.body.text(), contentType), "RateLimitErrorResponse", "");
|
|
140
|
+
throw new exception_1.ApiException(response.httpStatusCode, "Too Many Requests", body, response.headers);
|
|
103
141
|
}
|
|
104
142
|
if ((0, util_1.isCodeInRange)("500", response.httpStatusCode)) {
|
|
105
|
-
|
|
143
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(await response.body.text(), contentType), "InternalServerErrorResponse", "");
|
|
144
|
+
throw new exception_1.ApiException(response.httpStatusCode, "Internal Server Error", body, response.headers);
|
|
106
145
|
}
|
|
107
146
|
// Work around for missing responses in specification, e.g. for petstore.yaml
|
|
108
147
|
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
|
|
@@ -111,6 +150,42 @@ class InvoicesApiResponseProcessor {
|
|
|
111
150
|
}
|
|
112
151
|
throw new exception_1.ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers);
|
|
113
152
|
}
|
|
153
|
+
/**
|
|
154
|
+
* Unwraps the actual response sent by the server from the response context and deserializes the response content
|
|
155
|
+
* to the expected objects
|
|
156
|
+
*
|
|
157
|
+
* @params response Response returned by the server for a request to getInvoicePaymentStatus
|
|
158
|
+
* @throws ApiException if the response code was not in [200, 299]
|
|
159
|
+
*/
|
|
160
|
+
async getInvoicePaymentStatusWithHttpInfo(response) {
|
|
161
|
+
const contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
|
|
162
|
+
if ((0, util_1.isCodeInRange)("200", response.httpStatusCode)) {
|
|
163
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(await response.body.text(), contentType), "InvoicePaymentStatusResponse", "");
|
|
164
|
+
return new http_1.HttpInfo(response.httpStatusCode, response.headers, response.body, body);
|
|
165
|
+
}
|
|
166
|
+
if ((0, util_1.isCodeInRange)("400", response.httpStatusCode)) {
|
|
167
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(await response.body.text(), contentType), "ValidationErrorResponse", "");
|
|
168
|
+
throw new exception_1.ApiException(response.httpStatusCode, "Bad Request", body, response.headers);
|
|
169
|
+
}
|
|
170
|
+
if ((0, util_1.isCodeInRange)("401", response.httpStatusCode)) {
|
|
171
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(await response.body.text(), contentType), "UnauthorizedErrorResponse", "");
|
|
172
|
+
throw new exception_1.ApiException(response.httpStatusCode, "Unauthorized", body, response.headers);
|
|
173
|
+
}
|
|
174
|
+
if ((0, util_1.isCodeInRange)("429", response.httpStatusCode)) {
|
|
175
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(await response.body.text(), contentType), "RateLimitErrorResponse", "");
|
|
176
|
+
throw new exception_1.ApiException(response.httpStatusCode, "Too Many Requests", body, response.headers);
|
|
177
|
+
}
|
|
178
|
+
if ((0, util_1.isCodeInRange)("500", response.httpStatusCode)) {
|
|
179
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(await response.body.text(), contentType), "InternalServerErrorResponse", "");
|
|
180
|
+
throw new exception_1.ApiException(response.httpStatusCode, "Internal Server Error", body, response.headers);
|
|
181
|
+
}
|
|
182
|
+
// Work around for missing responses in specification, e.g. for petstore.yaml
|
|
183
|
+
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
|
|
184
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(await response.body.text(), contentType), "InvoicePaymentStatusResponse", "");
|
|
185
|
+
return new http_1.HttpInfo(response.httpStatusCode, response.headers, response.body, body);
|
|
186
|
+
}
|
|
187
|
+
throw new exception_1.ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers);
|
|
188
|
+
}
|
|
114
189
|
/**
|
|
115
190
|
* Unwraps the actual response sent by the server from the response context and deserializes the response content
|
|
116
191
|
* to the expected objects
|
|
@@ -125,16 +200,20 @@ class InvoicesApiResponseProcessor {
|
|
|
125
200
|
return new http_1.HttpInfo(response.httpStatusCode, response.headers, response.body, body);
|
|
126
201
|
}
|
|
127
202
|
if ((0, util_1.isCodeInRange)("400", response.httpStatusCode)) {
|
|
128
|
-
|
|
203
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(await response.body.text(), contentType), "ValidationErrorResponse", "");
|
|
204
|
+
throw new exception_1.ApiException(response.httpStatusCode, "Bad Request", body, response.headers);
|
|
129
205
|
}
|
|
130
206
|
if ((0, util_1.isCodeInRange)("401", response.httpStatusCode)) {
|
|
131
|
-
|
|
207
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(await response.body.text(), contentType), "UnauthorizedErrorResponse", "");
|
|
208
|
+
throw new exception_1.ApiException(response.httpStatusCode, "Unauthorized", body, response.headers);
|
|
132
209
|
}
|
|
133
210
|
if ((0, util_1.isCodeInRange)("429", response.httpStatusCode)) {
|
|
134
|
-
|
|
211
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(await response.body.text(), contentType), "RateLimitErrorResponse", "");
|
|
212
|
+
throw new exception_1.ApiException(response.httpStatusCode, "Too Many Requests", body, response.headers);
|
|
135
213
|
}
|
|
136
214
|
if ((0, util_1.isCodeInRange)("500", response.httpStatusCode)) {
|
|
137
|
-
|
|
215
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(await response.body.text(), contentType), "InternalServerErrorResponse", "");
|
|
216
|
+
throw new exception_1.ApiException(response.httpStatusCode, "Internal Server Error", body, response.headers);
|
|
138
217
|
}
|
|
139
218
|
// Work around for missing responses in specification, e.g. for petstore.yaml
|
|
140
219
|
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
|
|
@@ -154,16 +154,20 @@ class MeasurementsApiResponseProcessor {
|
|
|
154
154
|
return new http_1.HttpInfo(response.httpStatusCode, response.headers, response.body, body);
|
|
155
155
|
}
|
|
156
156
|
if ((0, util_1.isCodeInRange)("400", response.httpStatusCode)) {
|
|
157
|
-
|
|
157
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(await response.body.text(), contentType), "ValidationErrorResponse", "");
|
|
158
|
+
throw new exception_1.ApiException(response.httpStatusCode, "Bad Request", body, response.headers);
|
|
158
159
|
}
|
|
159
160
|
if ((0, util_1.isCodeInRange)("401", response.httpStatusCode)) {
|
|
160
|
-
|
|
161
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(await response.body.text(), contentType), "UnauthorizedErrorResponse", "");
|
|
162
|
+
throw new exception_1.ApiException(response.httpStatusCode, "Unauthorized", body, response.headers);
|
|
161
163
|
}
|
|
162
164
|
if ((0, util_1.isCodeInRange)("429", response.httpStatusCode)) {
|
|
163
|
-
|
|
165
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(await response.body.text(), contentType), "RateLimitErrorResponse", "");
|
|
166
|
+
throw new exception_1.ApiException(response.httpStatusCode, "Too Many Requests", body, response.headers);
|
|
164
167
|
}
|
|
165
168
|
if ((0, util_1.isCodeInRange)("500", response.httpStatusCode)) {
|
|
166
|
-
|
|
169
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(await response.body.text(), contentType), "InternalServerErrorResponse", "");
|
|
170
|
+
throw new exception_1.ApiException(response.httpStatusCode, "Internal Server Error", body, response.headers);
|
|
167
171
|
}
|
|
168
172
|
// Work around for missing responses in specification, e.g. for petstore.yaml
|
|
169
173
|
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
|
|
@@ -186,19 +190,24 @@ class MeasurementsApiResponseProcessor {
|
|
|
186
190
|
return new http_1.HttpInfo(response.httpStatusCode, response.headers, response.body, body);
|
|
187
191
|
}
|
|
188
192
|
if ((0, util_1.isCodeInRange)("400", response.httpStatusCode)) {
|
|
189
|
-
|
|
193
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(await response.body.text(), contentType), "ValidationErrorResponse", "");
|
|
194
|
+
throw new exception_1.ApiException(response.httpStatusCode, "Bad Request", body, response.headers);
|
|
190
195
|
}
|
|
191
196
|
if ((0, util_1.isCodeInRange)("401", response.httpStatusCode)) {
|
|
192
|
-
|
|
197
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(await response.body.text(), contentType), "UnauthorizedErrorResponse", "");
|
|
198
|
+
throw new exception_1.ApiException(response.httpStatusCode, "Unauthorized", body, response.headers);
|
|
193
199
|
}
|
|
194
200
|
if ((0, util_1.isCodeInRange)("404", response.httpStatusCode)) {
|
|
195
|
-
|
|
201
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(await response.body.text(), contentType), "NotFoundErrorResponse", "");
|
|
202
|
+
throw new exception_1.ApiException(response.httpStatusCode, "Not Found", body, response.headers);
|
|
196
203
|
}
|
|
197
204
|
if ((0, util_1.isCodeInRange)("429", response.httpStatusCode)) {
|
|
198
|
-
|
|
205
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(await response.body.text(), contentType), "RateLimitErrorResponse", "");
|
|
206
|
+
throw new exception_1.ApiException(response.httpStatusCode, "Too Many Requests", body, response.headers);
|
|
199
207
|
}
|
|
200
208
|
if ((0, util_1.isCodeInRange)("500", response.httpStatusCode)) {
|
|
201
|
-
|
|
209
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(await response.body.text(), contentType), "InternalServerErrorResponse", "");
|
|
210
|
+
throw new exception_1.ApiException(response.httpStatusCode, "Internal Server Error", body, response.headers);
|
|
202
211
|
}
|
|
203
212
|
// Work around for missing responses in specification, e.g. for petstore.yaml
|
|
204
213
|
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
|
|
@@ -221,19 +230,24 @@ class MeasurementsApiResponseProcessor {
|
|
|
221
230
|
return new http_1.HttpInfo(response.httpStatusCode, response.headers, response.body, body);
|
|
222
231
|
}
|
|
223
232
|
if ((0, util_1.isCodeInRange)("400", response.httpStatusCode)) {
|
|
224
|
-
|
|
233
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(await response.body.text(), contentType), "ValidationErrorResponse", "");
|
|
234
|
+
throw new exception_1.ApiException(response.httpStatusCode, "Bad Request", body, response.headers);
|
|
225
235
|
}
|
|
226
236
|
if ((0, util_1.isCodeInRange)("401", response.httpStatusCode)) {
|
|
227
|
-
|
|
237
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(await response.body.text(), contentType), "UnauthorizedErrorResponse", "");
|
|
238
|
+
throw new exception_1.ApiException(response.httpStatusCode, "Unauthorized", body, response.headers);
|
|
228
239
|
}
|
|
229
240
|
if ((0, util_1.isCodeInRange)("404", response.httpStatusCode)) {
|
|
230
|
-
|
|
241
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(await response.body.text(), contentType), "NotFoundErrorResponse", "");
|
|
242
|
+
throw new exception_1.ApiException(response.httpStatusCode, "Not Found", body, response.headers);
|
|
231
243
|
}
|
|
232
244
|
if ((0, util_1.isCodeInRange)("429", response.httpStatusCode)) {
|
|
233
|
-
|
|
245
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(await response.body.text(), contentType), "RateLimitErrorResponse", "");
|
|
246
|
+
throw new exception_1.ApiException(response.httpStatusCode, "Too Many Requests", body, response.headers);
|
|
234
247
|
}
|
|
235
248
|
if ((0, util_1.isCodeInRange)("500", response.httpStatusCode)) {
|
|
236
|
-
|
|
249
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(await response.body.text(), contentType), "InternalServerErrorResponse", "");
|
|
250
|
+
throw new exception_1.ApiException(response.httpStatusCode, "Internal Server Error", body, response.headers);
|
|
237
251
|
}
|
|
238
252
|
// Work around for missing responses in specification, e.g. for petstore.yaml
|
|
239
253
|
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
|
|
@@ -256,16 +270,20 @@ class MeasurementsApiResponseProcessor {
|
|
|
256
270
|
return new http_1.HttpInfo(response.httpStatusCode, response.headers, response.body, body);
|
|
257
271
|
}
|
|
258
272
|
if ((0, util_1.isCodeInRange)("400", response.httpStatusCode)) {
|
|
259
|
-
|
|
273
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(await response.body.text(), contentType), "ValidationErrorResponse", "");
|
|
274
|
+
throw new exception_1.ApiException(response.httpStatusCode, "Bad Request", body, response.headers);
|
|
260
275
|
}
|
|
261
276
|
if ((0, util_1.isCodeInRange)("401", response.httpStatusCode)) {
|
|
262
|
-
|
|
277
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(await response.body.text(), contentType), "UnauthorizedErrorResponse", "");
|
|
278
|
+
throw new exception_1.ApiException(response.httpStatusCode, "Unauthorized", body, response.headers);
|
|
263
279
|
}
|
|
264
280
|
if ((0, util_1.isCodeInRange)("429", response.httpStatusCode)) {
|
|
265
|
-
|
|
281
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(await response.body.text(), contentType), "RateLimitErrorResponse", "");
|
|
282
|
+
throw new exception_1.ApiException(response.httpStatusCode, "Too Many Requests", body, response.headers);
|
|
266
283
|
}
|
|
267
284
|
if ((0, util_1.isCodeInRange)("500", response.httpStatusCode)) {
|
|
268
|
-
|
|
285
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(await response.body.text(), contentType), "InternalServerErrorResponse", "");
|
|
286
|
+
throw new exception_1.ApiException(response.httpStatusCode, "Internal Server Error", body, response.headers);
|
|
269
287
|
}
|
|
270
288
|
// Work around for missing responses in specification, e.g. for petstore.yaml
|
|
271
289
|
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
|
|
@@ -160,19 +160,24 @@ class MetersApiResponseProcessor {
|
|
|
160
160
|
return new http_1.HttpInfo(response.httpStatusCode, response.headers, response.body, body);
|
|
161
161
|
}
|
|
162
162
|
if ((0, util_1.isCodeInRange)("400", response.httpStatusCode)) {
|
|
163
|
-
|
|
163
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(await response.body.text(), contentType), "ValidationErrorResponse", "");
|
|
164
|
+
throw new exception_1.ApiException(response.httpStatusCode, "Bad Request", body, response.headers);
|
|
164
165
|
}
|
|
165
166
|
if ((0, util_1.isCodeInRange)("401", response.httpStatusCode)) {
|
|
166
|
-
|
|
167
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(await response.body.text(), contentType), "UnauthorizedErrorResponse", "");
|
|
168
|
+
throw new exception_1.ApiException(response.httpStatusCode, "Unauthorized", body, response.headers);
|
|
167
169
|
}
|
|
168
170
|
if ((0, util_1.isCodeInRange)("404", response.httpStatusCode)) {
|
|
169
|
-
|
|
171
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(await response.body.text(), contentType), "NotFoundErrorResponse", "");
|
|
172
|
+
throw new exception_1.ApiException(response.httpStatusCode, "Not Found", body, response.headers);
|
|
170
173
|
}
|
|
171
174
|
if ((0, util_1.isCodeInRange)("429", response.httpStatusCode)) {
|
|
172
|
-
|
|
175
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(await response.body.text(), contentType), "RateLimitErrorResponse", "");
|
|
176
|
+
throw new exception_1.ApiException(response.httpStatusCode, "Too Many Requests", body, response.headers);
|
|
173
177
|
}
|
|
174
178
|
if ((0, util_1.isCodeInRange)("500", response.httpStatusCode)) {
|
|
175
|
-
|
|
179
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(await response.body.text(), contentType), "InternalServerErrorResponse", "");
|
|
180
|
+
throw new exception_1.ApiException(response.httpStatusCode, "Internal Server Error", body, response.headers);
|
|
176
181
|
}
|
|
177
182
|
// Work around for missing responses in specification, e.g. for petstore.yaml
|
|
178
183
|
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
|
|
@@ -195,19 +200,24 @@ class MetersApiResponseProcessor {
|
|
|
195
200
|
return new http_1.HttpInfo(response.httpStatusCode, response.headers, response.body, body);
|
|
196
201
|
}
|
|
197
202
|
if ((0, util_1.isCodeInRange)("400", response.httpStatusCode)) {
|
|
198
|
-
|
|
203
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(await response.body.text(), contentType), "ValidationErrorResponse", "");
|
|
204
|
+
throw new exception_1.ApiException(response.httpStatusCode, "Bad Request", body, response.headers);
|
|
199
205
|
}
|
|
200
206
|
if ((0, util_1.isCodeInRange)("401", response.httpStatusCode)) {
|
|
201
|
-
|
|
207
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(await response.body.text(), contentType), "UnauthorizedErrorResponse", "");
|
|
208
|
+
throw new exception_1.ApiException(response.httpStatusCode, "Unauthorized", body, response.headers);
|
|
202
209
|
}
|
|
203
210
|
if ((0, util_1.isCodeInRange)("404", response.httpStatusCode)) {
|
|
204
|
-
|
|
211
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(await response.body.text(), contentType), "NotFoundErrorResponse", "");
|
|
212
|
+
throw new exception_1.ApiException(response.httpStatusCode, "Not Found", body, response.headers);
|
|
205
213
|
}
|
|
206
214
|
if ((0, util_1.isCodeInRange)("429", response.httpStatusCode)) {
|
|
207
|
-
|
|
215
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(await response.body.text(), contentType), "RateLimitErrorResponse", "");
|
|
216
|
+
throw new exception_1.ApiException(response.httpStatusCode, "Too Many Requests", body, response.headers);
|
|
208
217
|
}
|
|
209
218
|
if ((0, util_1.isCodeInRange)("500", response.httpStatusCode)) {
|
|
210
|
-
|
|
219
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(await response.body.text(), contentType), "InternalServerErrorResponse", "");
|
|
220
|
+
throw new exception_1.ApiException(response.httpStatusCode, "Internal Server Error", body, response.headers);
|
|
211
221
|
}
|
|
212
222
|
// Work around for missing responses in specification, e.g. for petstore.yaml
|
|
213
223
|
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
|
|
@@ -230,16 +240,20 @@ class MetersApiResponseProcessor {
|
|
|
230
240
|
return new http_1.HttpInfo(response.httpStatusCode, response.headers, response.body, body);
|
|
231
241
|
}
|
|
232
242
|
if ((0, util_1.isCodeInRange)("400", response.httpStatusCode)) {
|
|
233
|
-
|
|
243
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(await response.body.text(), contentType), "ValidationErrorResponse", "");
|
|
244
|
+
throw new exception_1.ApiException(response.httpStatusCode, "Bad Request", body, response.headers);
|
|
234
245
|
}
|
|
235
246
|
if ((0, util_1.isCodeInRange)("401", response.httpStatusCode)) {
|
|
236
|
-
|
|
247
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(await response.body.text(), contentType), "UnauthorizedErrorResponse", "");
|
|
248
|
+
throw new exception_1.ApiException(response.httpStatusCode, "Unauthorized", body, response.headers);
|
|
237
249
|
}
|
|
238
250
|
if ((0, util_1.isCodeInRange)("429", response.httpStatusCode)) {
|
|
239
|
-
|
|
251
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(await response.body.text(), contentType), "RateLimitErrorResponse", "");
|
|
252
|
+
throw new exception_1.ApiException(response.httpStatusCode, "Too Many Requests", body, response.headers);
|
|
240
253
|
}
|
|
241
254
|
if ((0, util_1.isCodeInRange)("500", response.httpStatusCode)) {
|
|
242
|
-
|
|
255
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(await response.body.text(), contentType), "InternalServerErrorResponse", "");
|
|
256
|
+
throw new exception_1.ApiException(response.httpStatusCode, "Internal Server Error", body, response.headers);
|
|
243
257
|
}
|
|
244
258
|
// Work around for missing responses in specification, e.g. for petstore.yaml
|
|
245
259
|
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
|
|
@@ -262,19 +276,24 @@ class MetersApiResponseProcessor {
|
|
|
262
276
|
return new http_1.HttpInfo(response.httpStatusCode, response.headers, response.body, body);
|
|
263
277
|
}
|
|
264
278
|
if ((0, util_1.isCodeInRange)("400", response.httpStatusCode)) {
|
|
265
|
-
|
|
279
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(await response.body.text(), contentType), "ValidationErrorResponse", "");
|
|
280
|
+
throw new exception_1.ApiException(response.httpStatusCode, "Bad Request", body, response.headers);
|
|
266
281
|
}
|
|
267
282
|
if ((0, util_1.isCodeInRange)("401", response.httpStatusCode)) {
|
|
268
|
-
|
|
283
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(await response.body.text(), contentType), "UnauthorizedErrorResponse", "");
|
|
284
|
+
throw new exception_1.ApiException(response.httpStatusCode, "Unauthorized", body, response.headers);
|
|
269
285
|
}
|
|
270
286
|
if ((0, util_1.isCodeInRange)("404", response.httpStatusCode)) {
|
|
271
|
-
|
|
287
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(await response.body.text(), contentType), "NotFoundErrorResponse", "");
|
|
288
|
+
throw new exception_1.ApiException(response.httpStatusCode, "Not Found", body, response.headers);
|
|
272
289
|
}
|
|
273
290
|
if ((0, util_1.isCodeInRange)("429", response.httpStatusCode)) {
|
|
274
|
-
|
|
291
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(await response.body.text(), contentType), "RateLimitErrorResponse", "");
|
|
292
|
+
throw new exception_1.ApiException(response.httpStatusCode, "Too Many Requests", body, response.headers);
|
|
275
293
|
}
|
|
276
294
|
if ((0, util_1.isCodeInRange)("500", response.httpStatusCode)) {
|
|
277
|
-
|
|
295
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(await response.body.text(), contentType), "InternalServerErrorResponse", "");
|
|
296
|
+
throw new exception_1.ApiException(response.httpStatusCode, "Internal Server Error", body, response.headers);
|
|
278
297
|
}
|
|
279
298
|
// Work around for missing responses in specification, e.g. for petstore.yaml
|
|
280
299
|
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
import { BaseAPIRequestFactory } from './baseapi';
|
|
2
|
+
import { Configuration } from '../configuration';
|
|
3
|
+
import { RequestContext, ResponseContext, HttpInfo } from '../http/http';
|
|
4
|
+
import { DeletePlanResponse } from '../models/DeletePlanResponse';
|
|
5
|
+
import { GetPlanResponse } from '../models/GetPlanResponse';
|
|
6
|
+
import { ListPlansResponse } from '../models/ListPlansResponse';
|
|
7
|
+
/**
|
|
8
|
+
* no description
|
|
9
|
+
*/
|
|
10
|
+
export declare class PlansApiRequestFactory extends BaseAPIRequestFactory {
|
|
11
|
+
/**
|
|
12
|
+
* Delete a Plan by id.
|
|
13
|
+
* Delete Plan
|
|
14
|
+
* @param planId
|
|
15
|
+
*/
|
|
16
|
+
deletePlan(planId: string, _options?: Configuration): Promise<RequestContext>;
|
|
17
|
+
/**
|
|
18
|
+
* Get a Plan by id.
|
|
19
|
+
* Get Plan
|
|
20
|
+
* @param planId
|
|
21
|
+
*/
|
|
22
|
+
getPlan(planId: string, _options?: Configuration): Promise<RequestContext>;
|
|
23
|
+
/**
|
|
24
|
+
* Get a list of Plans.
|
|
25
|
+
* List Plans
|
|
26
|
+
* @param limit
|
|
27
|
+
* @param cursor
|
|
28
|
+
*/
|
|
29
|
+
listPlans(limit?: number, cursor?: string, _options?: Configuration): Promise<RequestContext>;
|
|
30
|
+
}
|
|
31
|
+
export declare class PlansApiResponseProcessor {
|
|
32
|
+
/**
|
|
33
|
+
* Unwraps the actual response sent by the server from the response context and deserializes the response content
|
|
34
|
+
* to the expected objects
|
|
35
|
+
*
|
|
36
|
+
* @params response Response returned by the server for a request to deletePlan
|
|
37
|
+
* @throws ApiException if the response code was not in [200, 299]
|
|
38
|
+
*/
|
|
39
|
+
deletePlanWithHttpInfo(response: ResponseContext): Promise<HttpInfo<DeletePlanResponse>>;
|
|
40
|
+
/**
|
|
41
|
+
* Unwraps the actual response sent by the server from the response context and deserializes the response content
|
|
42
|
+
* to the expected objects
|
|
43
|
+
*
|
|
44
|
+
* @params response Response returned by the server for a request to getPlan
|
|
45
|
+
* @throws ApiException if the response code was not in [200, 299]
|
|
46
|
+
*/
|
|
47
|
+
getPlanWithHttpInfo(response: ResponseContext): Promise<HttpInfo<GetPlanResponse>>;
|
|
48
|
+
/**
|
|
49
|
+
* Unwraps the actual response sent by the server from the response context and deserializes the response content
|
|
50
|
+
* to the expected objects
|
|
51
|
+
*
|
|
52
|
+
* @params response Response returned by the server for a request to listPlans
|
|
53
|
+
* @throws ApiException if the response code was not in [200, 299]
|
|
54
|
+
*/
|
|
55
|
+
listPlansWithHttpInfo(response: ResponseContext): Promise<HttpInfo<ListPlansResponse>>;
|
|
56
|
+
}
|