@schematichq/schematic-typescript-node 1.1.9 → 1.1.11
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/Client.d.ts +20 -13
- package/Client.js +13 -8
- package/README.md +199 -0
- package/api/errors/BadRequestError.d.ts +2 -1
- package/api/errors/BadRequestError.js +19 -8
- package/api/errors/ForbiddenError.d.ts +2 -1
- package/api/errors/ForbiddenError.js +19 -8
- package/api/errors/InternalServerError.d.ts +2 -1
- package/api/errors/InternalServerError.js +19 -8
- package/api/errors/NotFoundError.d.ts +2 -1
- package/api/errors/NotFoundError.js +19 -8
- package/api/errors/UnauthorizedError.d.ts +2 -1
- package/api/errors/UnauthorizedError.js +19 -8
- package/api/errors/index.d.ts +1 -1
- package/api/errors/index.js +1 -1
- package/api/resources/accesstokens/client/Client.d.ts +7 -1
- package/api/resources/accesstokens/client/Client.js +50 -22
- package/api/resources/accounts/client/Client.d.ts +55 -14
- package/api/resources/accounts/client/Client.js +548 -224
- package/api/resources/accounts/types/CreateEnvironmentRequestBodyEnvironmentType.d.ts +1 -1
- package/api/resources/accounts/types/QuickstartResponse.d.ts +9 -0
- package/api/resources/accounts/types/UpdateEnvironmentRequestBodyEnvironmentType.d.ts +1 -1
- package/api/resources/accounts/types/index.d.ts +1 -0
- package/api/resources/accounts/types/index.js +1 -0
- package/api/resources/billing/client/Client.d.ts +99 -25
- package/api/resources/billing/client/Client.js +912 -307
- package/api/resources/billing/client/requests/CountBillingProductsRequest.d.ts +10 -1
- package/api/resources/billing/client/requests/CountCustomersRequest.d.ts +1 -0
- package/api/resources/billing/client/requests/CreateBillingCustomerRequestBody.d.ts +1 -0
- package/api/resources/billing/client/requests/CreateBillingPriceRequestBody.d.ts +14 -2
- package/api/resources/billing/client/requests/CreateBillingProductRequestBody.d.ts +2 -5
- package/api/resources/billing/client/requests/CreateBillingSubscriptionsRequestBody.d.ts +6 -2
- package/api/resources/billing/client/requests/CreatePaymentMethodRequestBody.d.ts +0 -1
- package/api/resources/billing/client/requests/ListBillingProductsRequest.d.ts +10 -1
- package/api/resources/billing/client/requests/ListCouponsRequest.d.ts +19 -0
- package/api/resources/billing/client/requests/{ListCustomersRequest.d.ts → ListCustomersWithSubscriptionsRequest.d.ts} +2 -1
- package/api/resources/billing/client/requests/ListPaymentMethodsRequest.d.ts +0 -1
- package/api/resources/billing/client/requests/ListProductPricesRequest.d.ts +10 -1
- package/api/resources/billing/client/requests/SearchBillingPricesRequest.d.ts +3 -1
- package/api/resources/billing/client/requests/index.d.ts +2 -1
- package/api/resources/billing/types/CountBillingProductsParams.d.ts +6 -1
- package/api/resources/billing/types/CountBillingProductsRequestPriceUsageType.d.ts +8 -0
- package/api/resources/billing/types/CountBillingProductsRequestPriceUsageType.js +10 -0
- package/api/resources/billing/types/CountBillingProductsResponseParamsPriceUsageType.d.ts +8 -0
- package/api/resources/billing/types/CountBillingProductsResponseParamsPriceUsageType.js +10 -0
- package/api/resources/billing/types/CountCustomersParams.d.ts +1 -0
- package/api/resources/billing/types/CreateBillingPriceRequestBodyBillingScheme.d.ts +8 -0
- package/api/resources/billing/types/CreateBillingPriceRequestBodyBillingScheme.js +10 -0
- package/api/resources/billing/types/CreateBillingPriceRequestBodyTierMode.d.ts +8 -0
- package/api/resources/billing/types/CreateBillingPriceRequestBodyTierMode.js +10 -0
- package/api/resources/billing/types/CreateBillingPriceRequestBodyUsageType.d.ts +8 -0
- package/api/resources/billing/types/CreateBillingPriceRequestBodyUsageType.js +10 -0
- package/api/resources/billing/types/CreateBillingSubscriptionsRequestBodyTrialEndSetting.d.ts +8 -0
- package/api/resources/billing/types/CreateBillingSubscriptionsRequestBodyTrialEndSetting.js +10 -0
- package/api/resources/billing/types/DeleteBillingProductResponse.d.ts +9 -0
- package/api/resources/billing/types/ListBillingProductsParams.d.ts +6 -1
- package/api/resources/billing/types/ListBillingProductsRequestPriceUsageType.d.ts +8 -0
- package/api/resources/billing/types/ListBillingProductsRequestPriceUsageType.js +10 -0
- package/api/resources/billing/types/ListBillingProductsResponseParamsPriceUsageType.d.ts +8 -0
- package/api/resources/billing/types/ListBillingProductsResponseParamsPriceUsageType.js +10 -0
- package/api/resources/billing/types/ListCouponsParams.d.ts +14 -0
- package/api/resources/billing/types/ListCouponsResponse.d.ts +10 -0
- package/{dist/api/resources/billing/types/ListCustomersParams.d.ts → api/resources/billing/types/ListCustomersWithSubscriptionsParams.d.ts} +2 -1
- package/api/resources/billing/types/ListCustomersWithSubscriptionsParams.js +5 -0
- package/{dist/api/resources/billing/types/ListCustomersResponse.d.ts → api/resources/billing/types/ListCustomersWithSubscriptionsResponse.d.ts} +2 -2
- package/api/resources/billing/types/ListCustomersWithSubscriptionsResponse.js +5 -0
- package/api/resources/billing/types/ListPaymentMethodsParams.d.ts +0 -1
- package/api/resources/billing/types/ListProductPricesParams.d.ts +6 -1
- package/api/resources/billing/types/ListProductPricesRequestPriceUsageType.d.ts +8 -0
- package/api/resources/billing/types/ListProductPricesRequestPriceUsageType.js +10 -0
- package/api/resources/billing/types/ListProductPricesResponseParamsPriceUsageType.d.ts +8 -0
- package/api/resources/billing/types/ListProductPricesResponseParamsPriceUsageType.js +10 -0
- package/api/resources/billing/types/SearchBillingPricesParams.d.ts +3 -1
- package/api/resources/billing/types/SearchBillingPricesRequestUsageType.d.ts +8 -0
- package/api/resources/billing/types/SearchBillingPricesRequestUsageType.js +10 -0
- package/api/resources/billing/types/SearchBillingPricesResponseParamsUsageType.d.ts +8 -0
- package/api/resources/billing/types/SearchBillingPricesResponseParamsUsageType.js +10 -0
- package/api/resources/billing/types/index.d.ts +17 -2
- package/api/resources/billing/types/index.js +17 -2
- package/api/resources/checkout/client/Client.d.ts +19 -6
- package/api/resources/checkout/client/Client.js +149 -73
- package/api/resources/checkout/client/requests/CheckoutDataRequestBody.d.ts +13 -0
- package/api/resources/checkout/client/requests/CheckoutDataRequestBody.js +5 -0
- package/api/resources/checkout/client/requests/index.d.ts +1 -0
- package/api/resources/companies/client/Client.d.ts +99 -37
- package/api/resources/companies/client/Client.js +1024 -499
- package/api/resources/companies/client/requests/CountCompaniesRequest.d.ts +4 -0
- package/api/resources/companies/client/requests/ListCompaniesRequest.d.ts +4 -0
- package/api/resources/companies/client/requests/LookupCompanyRequest.d.ts +2 -4
- package/api/resources/companies/client/requests/LookupUserRequest.d.ts +2 -4
- package/api/resources/companies/types/CountCompaniesParams.d.ts +2 -0
- package/api/resources/companies/types/CountEntityKeyDefinitionsRequestEntityType.d.ts +1 -1
- package/api/resources/companies/types/CountEntityKeyDefinitionsResponseParamsEntityType.d.ts +1 -1
- package/api/resources/companies/types/CountEntityTraitDefinitionsRequestEntityType.d.ts +1 -1
- package/api/resources/companies/types/CountEntityTraitDefinitionsRequestTraitType.d.ts +1 -1
- package/api/resources/companies/types/CountEntityTraitDefinitionsResponseParamsEntityType.d.ts +1 -1
- package/api/resources/companies/types/CountEntityTraitDefinitionsResponseParamsTraitType.d.ts +1 -1
- package/api/resources/companies/types/CreateEntityTraitDefinitionRequestBodyEntityType.d.ts +1 -1
- package/api/resources/companies/types/CreateEntityTraitDefinitionRequestBodyTraitType.d.ts +1 -1
- package/api/resources/companies/types/ListCompaniesParams.d.ts +2 -0
- package/api/resources/companies/types/ListEntityKeyDefinitionsRequestEntityType.d.ts +1 -1
- package/api/resources/companies/types/ListEntityKeyDefinitionsResponseParamsEntityType.d.ts +1 -1
- package/api/resources/companies/types/ListEntityTraitDefinitionsRequestEntityType.d.ts +1 -1
- package/api/resources/companies/types/ListEntityTraitDefinitionsRequestTraitType.d.ts +1 -1
- package/api/resources/companies/types/ListEntityTraitDefinitionsResponseParamsEntityType.d.ts +1 -1
- package/api/resources/companies/types/ListEntityTraitDefinitionsResponseParamsTraitType.d.ts +1 -1
- package/api/resources/companies/types/LookupCompanyParams.d.ts +1 -1
- package/api/resources/companies/types/LookupUserParams.d.ts +1 -1
- package/api/resources/companies/types/UpdateEntityTraitDefinitionRequestBodyTraitType.d.ts +1 -1
- package/api/resources/components/client/Client.d.ts +22 -7
- package/api/resources/components/client/Client.js +226 -117
- package/api/resources/components/types/CreateComponentRequestBodyEntityType.d.ts +1 -1
- package/api/resources/components/types/UpdateComponentRequestBodyEntityType.d.ts +1 -1
- package/api/resources/components/types/UpdateComponentRequestBodyState.d.ts +1 -1
- package/api/resources/crm/client/Client.d.ts +19 -5
- package/api/resources/crm/client/Client.js +183 -83
- package/api/resources/dataexports/client/Client.d.ts +58 -0
- package/api/resources/dataexports/client/Client.js +265 -0
- package/api/resources/dataexports/client/index.d.ts +1 -0
- package/api/resources/dataexports/client/index.js +17 -0
- package/api/resources/dataexports/client/requests/CreateDataExportRequestBody.d.ts +12 -0
- package/api/resources/dataexports/client/requests/CreateDataExportRequestBody.js +5 -0
- package/api/resources/dataexports/client/requests/index.d.ts +1 -0
- package/api/resources/dataexports/client/requests/index.js +2 -0
- package/api/resources/dataexports/index.d.ts +2 -0
- package/api/resources/dataexports/index.js +18 -0
- package/api/resources/dataexports/types/CreateDataExportResponse.d.ts +9 -0
- package/api/resources/dataexports/types/CreateDataExportResponse.js +5 -0
- package/api/resources/dataexports/types/index.d.ts +1 -0
- package/api/resources/dataexports/types/index.js +17 -0
- package/api/resources/entitlements/client/Client.d.ts +57 -22
- package/api/resources/entitlements/client/Client.js +612 -306
- package/api/resources/entitlements/client/requests/CreatePlanEntitlementRequestBody.d.ts +7 -0
- package/api/resources/entitlements/client/requests/GetFeatureUsageByCompanyRequest.d.ts +2 -4
- package/api/resources/entitlements/client/requests/UpdatePlanEntitlementRequestBody.d.ts +7 -0
- package/api/resources/entitlements/types/CreateCompanyOverrideRequestBodyMetricPeriod.d.ts +1 -1
- package/api/resources/entitlements/types/CreateCompanyOverrideRequestBodyMetricPeriodMonthReset.d.ts +1 -1
- package/api/resources/entitlements/types/CreateCompanyOverrideRequestBodyValueType.d.ts +1 -1
- package/api/resources/entitlements/types/CreatePlanEntitlementRequestBodyMetricPeriod.d.ts +1 -1
- package/api/resources/entitlements/types/CreatePlanEntitlementRequestBodyMetricPeriodMonthReset.d.ts +1 -1
- package/api/resources/entitlements/types/CreatePlanEntitlementRequestBodyValueType.d.ts +1 -1
- package/api/resources/entitlements/types/GetFeatureUsageByCompanyParams.d.ts +1 -1
- package/api/resources/entitlements/types/UpdateCompanyOverrideRequestBodyMetricPeriod.d.ts +1 -1
- package/api/resources/entitlements/types/UpdateCompanyOverrideRequestBodyMetricPeriodMonthReset.d.ts +1 -1
- package/api/resources/entitlements/types/UpdateCompanyOverrideRequestBodyValueType.d.ts +1 -1
- package/api/resources/entitlements/types/UpdatePlanEntitlementRequestBodyMetricPeriod.d.ts +1 -1
- package/api/resources/entitlements/types/UpdatePlanEntitlementRequestBodyMetricPeriodMonthReset.d.ts +1 -1
- package/api/resources/entitlements/types/UpdatePlanEntitlementRequestBodyValueType.d.ts +1 -1
- package/api/resources/events/client/Client.d.ts +20 -6
- package/api/resources/events/client/Client.js +199 -99
- package/api/resources/features/client/Client.d.ts +56 -19
- package/api/resources/features/client/Client.js +607 -300
- package/api/resources/features/client/requests/CreateFeatureRequestBody.d.ts +2 -0
- package/api/resources/features/client/requests/UpdateFeatureRequestBody.d.ts +2 -0
- package/api/resources/features/types/CreateFeatureRequestBodyFeatureType.d.ts +1 -1
- package/api/resources/features/types/UpdateFeatureRequestBodyFeatureType.d.ts +1 -1
- package/api/resources/index.d.ts +3 -0
- package/api/resources/index.js +21 -8
- package/api/resources/plangroups/client/Client.d.ts +17 -5
- package/api/resources/plangroups/client/Client.js +105 -55
- package/api/resources/plangroups/client/requests/CreatePlanGroupRequestBody.d.ts +7 -2
- package/api/resources/plangroups/client/requests/UpdatePlanGroupRequestBody.d.ts +7 -2
- package/api/resources/plans/client/Client.d.ts +128 -11
- package/api/resources/plans/client/Client.js +1063 -210
- package/api/resources/plans/client/requests/CountPlanTraitsRequest.d.ts +20 -0
- package/api/resources/plans/client/requests/CountPlanTraitsRequest.js +5 -0
- package/api/resources/plans/client/requests/CreatePlanTraitRequestBody.d.ts +16 -0
- package/api/resources/plans/client/requests/CreatePlanTraitRequestBody.js +5 -0
- package/api/resources/plans/client/requests/ListPlanTraitsRequest.d.ts +20 -0
- package/api/resources/plans/client/requests/ListPlanTraitsRequest.js +5 -0
- package/api/resources/plans/client/requests/UpdatePlanTraitRequestBody.d.ts +14 -0
- package/api/resources/plans/client/requests/UpdatePlanTraitRequestBody.js +5 -0
- package/api/resources/plans/client/requests/UpsertBillingProductRequestBody.d.ts +2 -0
- package/api/resources/plans/client/requests/index.d.ts +4 -0
- package/api/resources/plans/types/CountPlanTraitsParams.d.ts +15 -0
- package/api/resources/plans/types/CountPlanTraitsParams.js +5 -0
- package/api/resources/plans/types/CountPlanTraitsResponse.d.ts +9 -0
- package/api/resources/plans/types/CountPlanTraitsResponse.js +5 -0
- package/api/resources/plans/types/CountPlansRequestPlanType.d.ts +1 -1
- package/api/resources/plans/types/CountPlansResponseParamsPlanType.d.ts +1 -1
- package/api/resources/plans/types/CreatePlanRequestBodyPlanType.d.ts +1 -1
- package/api/resources/plans/types/CreatePlanTraitResponse.d.ts +9 -0
- package/api/resources/plans/types/CreatePlanTraitResponse.js +5 -0
- package/api/resources/plans/types/DeletePlanTraitResponse.d.ts +9 -0
- package/api/resources/plans/types/DeletePlanTraitResponse.js +5 -0
- package/api/resources/plans/types/GetPlanTraitResponse.d.ts +9 -0
- package/api/resources/plans/types/GetPlanTraitResponse.js +5 -0
- package/api/resources/plans/types/ListPlanTraitsParams.d.ts +15 -0
- package/api/resources/plans/types/ListPlanTraitsParams.js +5 -0
- package/api/resources/plans/types/ListPlanTraitsResponse.d.ts +10 -0
- package/api/resources/plans/types/ListPlanTraitsResponse.js +5 -0
- package/api/resources/plans/types/ListPlansRequestPlanType.d.ts +1 -1
- package/api/resources/plans/types/ListPlansResponseParamsPlanType.d.ts +1 -1
- package/api/resources/plans/types/UpdatePlanTraitResponse.d.ts +9 -0
- package/api/resources/plans/types/UpdatePlanTraitResponse.js +5 -0
- package/api/resources/plans/types/index.d.ts +8 -0
- package/api/resources/plans/types/index.js +8 -0
- package/api/resources/webhooks/client/Client.d.ts +28 -9
- package/api/resources/webhooks/client/Client.js +293 -148
- package/api/resources/webhooks/client/requests/CreateWebhookRequestBody.d.ts +1 -0
- package/api/resources/webhooks/client/requests/UpdateWebhookRequestBody.d.ts +1 -0
- package/api/resources/webhooks/types/CreateWebhookRequestBodyRequestTypesItem.d.ts +5 -1
- package/api/resources/webhooks/types/CreateWebhookRequestBodyRequestTypesItem.js +4 -0
- package/api/resources/webhooks/types/UpdateWebhookRequestBodyRequestTypesItem.d.ts +5 -1
- package/api/resources/webhooks/types/UpdateWebhookRequestBodyRequestTypesItem.js +4 -0
- package/api/resources/webhooks/types/UpdateWebhookRequestBodyStatus.d.ts +1 -1
- package/api/types/BillingCouponResponseData.d.ts +0 -3
- package/api/types/BillingPriceResponseData.d.ts +2 -0
- package/api/types/BillingPriceView.d.ts +7 -0
- package/api/types/BillingProductDetailResponseData.d.ts +3 -0
- package/api/types/BillingProductForSubscriptionResponseData.d.ts +5 -0
- package/api/types/BillingProductPlanResponseData.d.ts +2 -0
- package/api/types/BillingProductPriceResponseData.d.ts +3 -0
- package/api/types/BillingProductPriceTierResponseData.d.ts +9 -0
- package/api/types/BillingProductPriceTierResponseData.js +5 -0
- package/api/types/BillingProductPricing.d.ts +4 -1
- package/api/types/BillingProductPricingUsageType.d.ts +8 -0
- package/api/types/BillingProductPricingUsageType.js +10 -0
- package/api/types/BillingProductResponseData.d.ts +2 -0
- package/api/types/BillingSubscriptionResponseData.d.ts +3 -0
- package/api/types/BillingSubscriptionView.d.ts +3 -0
- package/api/types/ChangeSubscriptionInternalRequestBody.d.ts +1 -0
- package/api/types/ChangeSubscriptionRequestBody.d.ts +1 -0
- package/api/types/CheckFlagResponseData.d.ts +2 -0
- package/api/types/CheckoutDataResponseData.d.ts +3 -1
- package/api/types/CompanyDetailResponseData.d.ts +2 -0
- package/api/types/CompanyPlanDetailResponseData.d.ts +5 -0
- package/api/types/CompanyPlanWithBillingSubView.d.ts +2 -0
- package/api/types/CompanySubscriptionResponseData.d.ts +2 -0
- package/api/types/ComponentCapabilities.d.ts +1 -0
- package/api/types/CreateBillingPriceTierRequestBody.d.ts +10 -0
- package/api/types/CreateBillingPriceTierRequestBody.js +5 -0
- package/api/types/CreateEntitlementReqCommonMetricPeriod.d.ts +1 -1
- package/api/types/CreateEntitlementReqCommonMetricPeriodMonthReset.d.ts +1 -1
- package/api/types/CreateEntitlementReqCommonValueType.d.ts +1 -1
- package/api/types/CreateEventRequestBodyEventType.d.ts +1 -1
- package/api/types/CreateOrUpdateConditionRequestBodyConditionType.d.ts +1 -1
- package/api/types/CreateOrUpdateConditionRequestBodyMetricPeriod.d.ts +1 -1
- package/api/types/CreateOrUpdateConditionRequestBodyMetricPeriodMonthReset.d.ts +1 -1
- package/api/types/CreateOrUpdateConditionRequestBodyOperator.d.ts +1 -1
- package/api/types/CreateOrUpdateRuleRequestBodyRuleType.d.ts +1 -1
- package/api/types/CustomPlanConfig.d.ts +8 -0
- package/api/types/CustomPlanConfig.js +5 -0
- package/api/types/CustomPlanViewConfigResponseData.d.ts +8 -0
- package/api/types/CustomPlanViewConfigResponseData.js +5 -0
- package/api/types/DataExportResponseData.d.ts +17 -0
- package/api/types/DataExportResponseData.js +5 -0
- package/api/types/Decimal.d.ts +1 -1
- package/api/types/EntitlementTriggerConfig.d.ts +6 -0
- package/api/types/EntitlementTriggerConfig.js +5 -0
- package/api/types/EntitlementsInPlan.d.ts +7 -0
- package/api/types/EntitlementsInPlan.js +5 -0
- package/api/types/EventBody.d.ts +1 -1
- package/api/types/EventSummaryResponseData.d.ts +2 -2
- package/api/types/FeatureCompanyResponseDataAllocationType.d.ts +1 -1
- package/api/types/FeatureCompanyUserResponseDataAllocationType.d.ts +1 -1
- package/api/types/FeatureDetailResponseData.d.ts +2 -0
- package/api/types/FeatureResponseData.d.ts +2 -0
- package/api/types/FeatureUsageResponseData.d.ts +2 -0
- package/api/types/FeatureUsageResponseDataAllocationType.d.ts +1 -1
- package/api/types/OrderedPlansInGroup.d.ts +8 -0
- package/api/types/OrderedPlansInGroup.js +5 -0
- package/api/types/PaymentMethodRequestBody.d.ts +0 -1
- package/api/types/PaymentMethodResponseData.d.ts +0 -1
- package/api/types/PlanDetailResponseData.d.ts +2 -0
- package/api/types/PlanEntitlementResponseData.d.ts +2 -0
- package/api/types/PlanEntitlementsOrder.d.ts +7 -0
- package/api/types/PlanEntitlementsOrder.js +5 -0
- package/api/types/PlanGroupDetailResponseData.d.ts +3 -0
- package/api/types/PlanGroupPlanDetailResponseData.d.ts +4 -0
- package/api/types/PlanGroupPlanEntitlementsOrder.d.ts +8 -0
- package/api/types/PlanGroupPlanEntitlementsOrder.js +5 -0
- package/api/types/PlanGroupResponseData.d.ts +2 -1
- package/api/types/PlanTraitResponseData.d.ts +16 -0
- package/api/types/PlanTraitResponseData.js +5 -0
- package/api/types/PreviewSubscriptionChangeResponseData.d.ts +3 -0
- package/api/types/PreviewSubscriptionFinanceResponseData.d.ts +15 -0
- package/api/types/PreviewSubscriptionFinanceResponseData.js +5 -0
- package/api/types/PreviewSubscriptionUpcomingInvoiceLineItems.d.ts +10 -0
- package/api/types/PreviewSubscriptionUpcomingInvoiceLineItems.js +5 -0
- package/api/types/QuickstartResp.d.ts +6 -0
- package/api/types/QuickstartResp.js +5 -0
- package/api/types/UpdateEntitlementReqCommonMetricPeriod.d.ts +1 -1
- package/api/types/UpdateEntitlementReqCommonMetricPeriodMonthReset.d.ts +1 -1
- package/api/types/UpdateEntitlementReqCommonValueType.d.ts +1 -1
- package/api/types/UpsertCompanyRequestBody.d.ts +1 -0
- package/api/types/UpsertTraitRequestBody.d.ts +1 -1
- package/api/types/UpsertUserRequestBody.d.ts +7 -2
- package/api/types/UpsertUserSubRequestBody.d.ts +4 -1
- package/api/types/UsageBasedEntitlementRequestBody.d.ts +7 -0
- package/api/types/WebhookResponseData.d.ts +3 -0
- package/api/types/index.d.ts +15 -0
- package/api/types/index.js +15 -0
- package/core/fetcher/APIResponse.d.ts +11 -1
- package/core/fetcher/Fetcher.d.ts +2 -2
- package/core/fetcher/Fetcher.js +13 -5
- package/core/fetcher/Headers.d.ts +2 -0
- package/core/fetcher/Headers.js +84 -0
- package/core/fetcher/HttpResponsePromise.d.ts +58 -0
- package/core/fetcher/HttpResponsePromise.js +103 -0
- package/core/fetcher/RawResponse.d.ts +29 -0
- package/core/fetcher/RawResponse.js +44 -0
- package/core/fetcher/Supplier.d.ts +1 -1
- package/core/fetcher/createRequestUrl.d.ts +1 -1
- package/core/fetcher/createRequestUrl.js +1 -2
- package/core/fetcher/custom.js +19 -2
- package/core/fetcher/getFetchFn.js +18 -9
- package/core/fetcher/getHeader.js +1 -2
- package/core/fetcher/getRequestBody.js +5 -5
- package/core/fetcher/getResponseBody.js +1 -2
- package/core/fetcher/index.d.ts +3 -0
- package/core/fetcher/index.js +7 -1
- package/core/fetcher/makeRequest.d.ts +1 -1
- package/core/fetcher/requestWithRetries.js +4 -5
- package/core/fetcher/signals.d.ts +0 -1
- package/core/fetcher/signals.js +2 -3
- package/core/fetcher/stream-wrappers/NodePre18StreamWrapper.d.ts +0 -1
- package/core/fetcher/stream-wrappers/NodePre18StreamWrapper.js +6 -4
- package/core/fetcher/stream-wrappers/UndiciStreamWrapper.d.ts +1 -1
- package/core/fetcher/stream-wrappers/chooseStreamWrapper.d.ts +1 -1
- package/core/fetcher/stream-wrappers/chooseStreamWrapper.js +18 -9
- package/core/index.js +17 -7
- package/core/json.d.ts +15 -0
- package/core/json.js +24 -0
- package/core/runtime/runtime.d.ts +1 -1
- package/core/runtime/runtime.js +51 -41
- package/core/schemas/Schema.d.ts +7 -5
- package/core/schemas/Schema.js +2 -0
- package/core/schemas/builders/bigint/bigint.d.ts +1 -1
- package/core/schemas/builders/bigint/bigint.js +22 -19
- package/core/schemas/builders/date/date.js +1 -2
- package/core/schemas/builders/enum/enum.js +1 -2
- package/core/schemas/builders/lazy/lazy.d.ts +1 -1
- package/core/schemas/builders/lazy/lazy.js +3 -4
- package/core/schemas/builders/lazy/lazyObject.js +1 -2
- package/core/schemas/builders/list/list.js +1 -2
- package/core/schemas/builders/literals/booleanLiteral.js +1 -2
- package/core/schemas/builders/literals/stringLiteral.js +1 -2
- package/core/schemas/builders/object/object.d.ts +1 -1
- package/core/schemas/builders/object/object.js +31 -3
- package/core/schemas/builders/object/objectWithoutOptionalProperties.d.ts +3 -3
- package/core/schemas/builders/object/objectWithoutOptionalProperties.js +1 -2
- package/core/schemas/builders/object/property.js +2 -3
- package/core/schemas/builders/object/types.d.ts +16 -11
- package/core/schemas/builders/object-like/getObjectLikeUtils.js +2 -3
- package/core/schemas/builders/object-like/types.d.ts +1 -1
- package/core/schemas/builders/record/record.js +2 -4
- package/core/schemas/builders/record/types.d.ts +2 -2
- package/core/schemas/builders/schema-utils/getSchemaUtils.d.ts +4 -0
- package/core/schemas/builders/schema-utils/getSchemaUtils.js +67 -4
- package/core/schemas/builders/schema-utils/stringifyValidationErrors.js +1 -2
- package/core/schemas/builders/set/set.js +1 -2
- package/core/schemas/builders/undiscriminated-union/types.d.ts +4 -4
- package/core/schemas/builders/undiscriminated-union/undiscriminatedUnion.js +1 -2
- package/core/schemas/builders/union/discriminant.js +1 -2
- package/core/schemas/builders/union/types.d.ts +6 -6
- package/core/schemas/builders/union/union.d.ts +1 -1
- package/core/schemas/builders/union/union.js +1 -2
- package/core/schemas/utils/MaybePromise.d.ts +1 -1
- package/core/schemas/utils/addQuestionMarksToNullableProperties.d.ts +4 -4
- package/core/schemas/utils/createIdentitySchemaCreator.js +1 -2
- package/core/schemas/utils/entries.d.ts +1 -1
- package/core/schemas/utils/entries.js +1 -2
- package/core/schemas/utils/filterObject.d.ts +1 -1
- package/core/schemas/utils/filterObject.js +1 -2
- package/core/schemas/utils/getErrorMessageForIncorrectType.js +1 -2
- package/core/schemas/utils/isPlainObject.js +1 -2
- package/core/schemas/utils/keys.d.ts +1 -1
- package/core/schemas/utils/keys.js +1 -2
- package/core/schemas/utils/maybeSkipValidation.js +1 -2
- package/core/schemas/utils/partition.js +1 -2
- package/dist/Client.d.ts +20 -13
- package/dist/Client.js +13 -8
- package/dist/api/errors/BadRequestError.d.ts +2 -1
- package/dist/api/errors/BadRequestError.js +19 -8
- package/dist/api/errors/ForbiddenError.d.ts +2 -1
- package/dist/api/errors/ForbiddenError.js +19 -8
- package/dist/api/errors/InternalServerError.d.ts +2 -1
- package/dist/api/errors/InternalServerError.js +19 -8
- package/dist/api/errors/NotFoundError.d.ts +2 -1
- package/dist/api/errors/NotFoundError.js +19 -8
- package/dist/api/errors/UnauthorizedError.d.ts +2 -1
- package/dist/api/errors/UnauthorizedError.js +19 -8
- package/dist/api/errors/index.d.ts +1 -1
- package/dist/api/errors/index.js +1 -1
- package/dist/api/resources/accesstokens/client/Client.d.ts +7 -1
- package/dist/api/resources/accesstokens/client/Client.js +50 -22
- package/dist/api/resources/accounts/client/Client.d.ts +55 -14
- package/dist/api/resources/accounts/client/Client.js +548 -224
- package/dist/api/resources/accounts/types/CreateEnvironmentRequestBodyEnvironmentType.d.ts +1 -1
- package/dist/api/resources/accounts/types/QuickstartResponse.d.ts +9 -0
- package/dist/api/resources/accounts/types/QuickstartResponse.js +5 -0
- package/dist/api/resources/accounts/types/UpdateEnvironmentRequestBodyEnvironmentType.d.ts +1 -1
- package/dist/api/resources/accounts/types/index.d.ts +1 -0
- package/dist/api/resources/accounts/types/index.js +1 -0
- package/dist/api/resources/billing/client/Client.d.ts +99 -25
- package/dist/api/resources/billing/client/Client.js +912 -307
- package/dist/api/resources/billing/client/requests/CountBillingProductsRequest.d.ts +10 -1
- package/dist/api/resources/billing/client/requests/CountCustomersRequest.d.ts +1 -0
- package/dist/api/resources/billing/client/requests/CreateBillingCustomerRequestBody.d.ts +1 -0
- package/dist/api/resources/billing/client/requests/CreateBillingPriceRequestBody.d.ts +14 -2
- package/dist/api/resources/billing/client/requests/CreateBillingProductRequestBody.d.ts +2 -5
- package/dist/api/resources/billing/client/requests/CreateBillingSubscriptionsRequestBody.d.ts +6 -2
- package/dist/api/resources/billing/client/requests/CreatePaymentMethodRequestBody.d.ts +0 -1
- package/dist/api/resources/billing/client/requests/ListBillingProductsRequest.d.ts +10 -1
- package/dist/api/resources/billing/client/requests/ListCouponsRequest.d.ts +19 -0
- package/dist/api/resources/billing/client/requests/ListCouponsRequest.js +5 -0
- package/dist/api/resources/billing/client/requests/{ListCustomersRequest.d.ts → ListCustomersWithSubscriptionsRequest.d.ts} +2 -1
- package/dist/api/resources/billing/client/requests/ListCustomersWithSubscriptionsRequest.js +5 -0
- package/dist/api/resources/billing/client/requests/ListPaymentMethodsRequest.d.ts +0 -1
- package/dist/api/resources/billing/client/requests/ListProductPricesRequest.d.ts +10 -1
- package/dist/api/resources/billing/client/requests/SearchBillingPricesRequest.d.ts +3 -1
- package/dist/api/resources/billing/client/requests/index.d.ts +2 -1
- package/dist/api/resources/billing/types/CountBillingProductsParams.d.ts +6 -1
- package/dist/api/resources/billing/types/CountBillingProductsRequestPriceUsageType.d.ts +8 -0
- package/dist/api/resources/billing/types/CountBillingProductsRequestPriceUsageType.js +10 -0
- package/dist/api/resources/billing/types/CountBillingProductsResponseParamsPriceUsageType.d.ts +8 -0
- package/dist/api/resources/billing/types/CountBillingProductsResponseParamsPriceUsageType.js +10 -0
- package/dist/api/resources/billing/types/CountCustomersParams.d.ts +1 -0
- package/dist/api/resources/billing/types/CreateBillingPriceRequestBodyBillingScheme.d.ts +8 -0
- package/dist/api/resources/billing/types/CreateBillingPriceRequestBodyBillingScheme.js +10 -0
- package/dist/api/resources/billing/types/CreateBillingPriceRequestBodyTierMode.d.ts +8 -0
- package/dist/api/resources/billing/types/CreateBillingPriceRequestBodyTierMode.js +10 -0
- package/dist/api/resources/billing/types/CreateBillingPriceRequestBodyUsageType.d.ts +8 -0
- package/dist/api/resources/billing/types/CreateBillingPriceRequestBodyUsageType.js +10 -0
- package/dist/api/resources/billing/types/CreateBillingSubscriptionsRequestBodyTrialEndSetting.d.ts +8 -0
- package/dist/api/resources/billing/types/CreateBillingSubscriptionsRequestBodyTrialEndSetting.js +10 -0
- package/dist/api/resources/billing/types/DeleteBillingProductResponse.d.ts +9 -0
- package/dist/api/resources/billing/types/DeleteBillingProductResponse.js +5 -0
- package/dist/api/resources/billing/types/ListBillingProductsParams.d.ts +6 -1
- package/dist/api/resources/billing/types/ListBillingProductsRequestPriceUsageType.d.ts +8 -0
- package/dist/api/resources/billing/types/ListBillingProductsRequestPriceUsageType.js +10 -0
- package/dist/api/resources/billing/types/ListBillingProductsResponseParamsPriceUsageType.d.ts +8 -0
- package/dist/api/resources/billing/types/ListBillingProductsResponseParamsPriceUsageType.js +10 -0
- package/dist/api/resources/billing/types/ListCouponsParams.d.ts +14 -0
- package/dist/api/resources/billing/types/ListCouponsParams.js +5 -0
- package/dist/api/resources/billing/types/ListCouponsResponse.d.ts +10 -0
- package/dist/api/resources/billing/types/ListCouponsResponse.js +5 -0
- package/{api/resources/billing/types/ListCustomersParams.d.ts → dist/api/resources/billing/types/ListCustomersWithSubscriptionsParams.d.ts} +2 -1
- package/dist/api/resources/billing/types/ListCustomersWithSubscriptionsParams.js +5 -0
- package/{api/resources/billing/types/ListCustomersResponse.d.ts → dist/api/resources/billing/types/ListCustomersWithSubscriptionsResponse.d.ts} +2 -2
- package/dist/api/resources/billing/types/ListCustomersWithSubscriptionsResponse.js +5 -0
- package/dist/api/resources/billing/types/ListPaymentMethodsParams.d.ts +0 -1
- package/dist/api/resources/billing/types/ListProductPricesParams.d.ts +6 -1
- package/dist/api/resources/billing/types/ListProductPricesRequestPriceUsageType.d.ts +8 -0
- package/dist/api/resources/billing/types/ListProductPricesRequestPriceUsageType.js +10 -0
- package/dist/api/resources/billing/types/ListProductPricesResponseParamsPriceUsageType.d.ts +8 -0
- package/dist/api/resources/billing/types/ListProductPricesResponseParamsPriceUsageType.js +10 -0
- package/dist/api/resources/billing/types/SearchBillingPricesParams.d.ts +3 -1
- package/dist/api/resources/billing/types/SearchBillingPricesRequestUsageType.d.ts +8 -0
- package/dist/api/resources/billing/types/SearchBillingPricesRequestUsageType.js +10 -0
- package/dist/api/resources/billing/types/SearchBillingPricesResponseParamsUsageType.d.ts +8 -0
- package/dist/api/resources/billing/types/SearchBillingPricesResponseParamsUsageType.js +10 -0
- package/dist/api/resources/billing/types/index.d.ts +17 -2
- package/dist/api/resources/billing/types/index.js +17 -2
- package/dist/api/resources/checkout/client/Client.d.ts +19 -6
- package/dist/api/resources/checkout/client/Client.js +149 -73
- package/dist/api/resources/checkout/client/requests/CheckoutDataRequestBody.d.ts +13 -0
- package/dist/api/resources/checkout/client/requests/CheckoutDataRequestBody.js +5 -0
- package/dist/api/resources/checkout/client/requests/index.d.ts +1 -0
- package/dist/api/resources/companies/client/Client.d.ts +99 -37
- package/dist/api/resources/companies/client/Client.js +1024 -499
- package/dist/api/resources/companies/client/requests/CountCompaniesRequest.d.ts +4 -0
- package/dist/api/resources/companies/client/requests/ListCompaniesRequest.d.ts +4 -0
- package/dist/api/resources/companies/client/requests/LookupCompanyRequest.d.ts +2 -4
- package/dist/api/resources/companies/client/requests/LookupUserRequest.d.ts +2 -4
- package/dist/api/resources/companies/types/CountCompaniesParams.d.ts +2 -0
- package/dist/api/resources/companies/types/CountEntityKeyDefinitionsRequestEntityType.d.ts +1 -1
- package/dist/api/resources/companies/types/CountEntityKeyDefinitionsResponseParamsEntityType.d.ts +1 -1
- package/dist/api/resources/companies/types/CountEntityTraitDefinitionsRequestEntityType.d.ts +1 -1
- package/dist/api/resources/companies/types/CountEntityTraitDefinitionsRequestTraitType.d.ts +1 -1
- package/dist/api/resources/companies/types/CountEntityTraitDefinitionsResponseParamsEntityType.d.ts +1 -1
- package/dist/api/resources/companies/types/CountEntityTraitDefinitionsResponseParamsTraitType.d.ts +1 -1
- package/dist/api/resources/companies/types/CreateEntityTraitDefinitionRequestBodyEntityType.d.ts +1 -1
- package/dist/api/resources/companies/types/CreateEntityTraitDefinitionRequestBodyTraitType.d.ts +1 -1
- package/dist/api/resources/companies/types/ListCompaniesParams.d.ts +2 -0
- package/dist/api/resources/companies/types/ListEntityKeyDefinitionsRequestEntityType.d.ts +1 -1
- package/dist/api/resources/companies/types/ListEntityKeyDefinitionsResponseParamsEntityType.d.ts +1 -1
- package/dist/api/resources/companies/types/ListEntityTraitDefinitionsRequestEntityType.d.ts +1 -1
- package/dist/api/resources/companies/types/ListEntityTraitDefinitionsRequestTraitType.d.ts +1 -1
- package/dist/api/resources/companies/types/ListEntityTraitDefinitionsResponseParamsEntityType.d.ts +1 -1
- package/dist/api/resources/companies/types/ListEntityTraitDefinitionsResponseParamsTraitType.d.ts +1 -1
- package/dist/api/resources/companies/types/LookupCompanyParams.d.ts +1 -1
- package/dist/api/resources/companies/types/LookupUserParams.d.ts +1 -1
- package/dist/api/resources/companies/types/UpdateEntityTraitDefinitionRequestBodyTraitType.d.ts +1 -1
- package/dist/api/resources/components/client/Client.d.ts +22 -7
- package/dist/api/resources/components/client/Client.js +226 -117
- package/dist/api/resources/components/types/CreateComponentRequestBodyEntityType.d.ts +1 -1
- package/dist/api/resources/components/types/UpdateComponentRequestBodyEntityType.d.ts +1 -1
- package/dist/api/resources/components/types/UpdateComponentRequestBodyState.d.ts +1 -1
- package/dist/api/resources/crm/client/Client.d.ts +19 -5
- package/dist/api/resources/crm/client/Client.js +183 -83
- package/dist/api/resources/dataexports/client/Client.d.ts +58 -0
- package/dist/api/resources/dataexports/client/Client.js +265 -0
- package/dist/api/resources/dataexports/client/index.d.ts +1 -0
- package/dist/api/resources/dataexports/client/index.js +17 -0
- package/dist/api/resources/dataexports/client/requests/CreateDataExportRequestBody.d.ts +12 -0
- package/dist/api/resources/dataexports/client/requests/CreateDataExportRequestBody.js +5 -0
- package/dist/api/resources/dataexports/client/requests/index.d.ts +1 -0
- package/dist/api/resources/dataexports/client/requests/index.js +2 -0
- package/dist/api/resources/dataexports/index.d.ts +2 -0
- package/dist/api/resources/dataexports/index.js +18 -0
- package/dist/api/resources/dataexports/types/CreateDataExportResponse.d.ts +9 -0
- package/dist/api/resources/dataexports/types/CreateDataExportResponse.js +5 -0
- package/dist/api/resources/dataexports/types/index.d.ts +1 -0
- package/dist/api/resources/dataexports/types/index.js +17 -0
- package/dist/api/resources/entitlements/client/Client.d.ts +57 -22
- package/dist/api/resources/entitlements/client/Client.js +612 -306
- package/dist/api/resources/entitlements/client/requests/CreatePlanEntitlementRequestBody.d.ts +7 -0
- package/dist/api/resources/entitlements/client/requests/GetFeatureUsageByCompanyRequest.d.ts +2 -4
- package/dist/api/resources/entitlements/client/requests/UpdatePlanEntitlementRequestBody.d.ts +7 -0
- package/dist/api/resources/entitlements/types/CreateCompanyOverrideRequestBodyMetricPeriod.d.ts +1 -1
- package/dist/api/resources/entitlements/types/CreateCompanyOverrideRequestBodyMetricPeriodMonthReset.d.ts +1 -1
- package/dist/api/resources/entitlements/types/CreateCompanyOverrideRequestBodyValueType.d.ts +1 -1
- package/dist/api/resources/entitlements/types/CreatePlanEntitlementRequestBodyMetricPeriod.d.ts +1 -1
- package/dist/api/resources/entitlements/types/CreatePlanEntitlementRequestBodyMetricPeriodMonthReset.d.ts +1 -1
- package/dist/api/resources/entitlements/types/CreatePlanEntitlementRequestBodyValueType.d.ts +1 -1
- package/dist/api/resources/entitlements/types/GetFeatureUsageByCompanyParams.d.ts +1 -1
- package/dist/api/resources/entitlements/types/UpdateCompanyOverrideRequestBodyMetricPeriod.d.ts +1 -1
- package/dist/api/resources/entitlements/types/UpdateCompanyOverrideRequestBodyMetricPeriodMonthReset.d.ts +1 -1
- package/dist/api/resources/entitlements/types/UpdateCompanyOverrideRequestBodyValueType.d.ts +1 -1
- package/dist/api/resources/entitlements/types/UpdatePlanEntitlementRequestBodyMetricPeriod.d.ts +1 -1
- package/dist/api/resources/entitlements/types/UpdatePlanEntitlementRequestBodyMetricPeriodMonthReset.d.ts +1 -1
- package/dist/api/resources/entitlements/types/UpdatePlanEntitlementRequestBodyValueType.d.ts +1 -1
- package/dist/api/resources/events/client/Client.d.ts +20 -6
- package/dist/api/resources/events/client/Client.js +199 -99
- package/dist/api/resources/features/client/Client.d.ts +56 -19
- package/dist/api/resources/features/client/Client.js +607 -300
- package/dist/api/resources/features/client/requests/CreateFeatureRequestBody.d.ts +2 -0
- package/dist/api/resources/features/client/requests/UpdateFeatureRequestBody.d.ts +2 -0
- package/dist/api/resources/features/types/CreateFeatureRequestBodyFeatureType.d.ts +1 -1
- package/dist/api/resources/features/types/UpdateFeatureRequestBodyFeatureType.d.ts +1 -1
- package/dist/api/resources/index.d.ts +3 -0
- package/dist/api/resources/index.js +21 -8
- package/dist/api/resources/plangroups/client/Client.d.ts +17 -5
- package/dist/api/resources/plangroups/client/Client.js +105 -55
- package/dist/api/resources/plangroups/client/requests/CreatePlanGroupRequestBody.d.ts +7 -2
- package/dist/api/resources/plangroups/client/requests/UpdatePlanGroupRequestBody.d.ts +7 -2
- package/dist/api/resources/plans/client/Client.d.ts +128 -11
- package/dist/api/resources/plans/client/Client.js +1063 -210
- package/dist/api/resources/plans/client/requests/CountPlanTraitsRequest.d.ts +20 -0
- package/dist/api/resources/plans/client/requests/CountPlanTraitsRequest.js +5 -0
- package/dist/api/resources/plans/client/requests/CreatePlanTraitRequestBody.d.ts +16 -0
- package/dist/api/resources/plans/client/requests/CreatePlanTraitRequestBody.js +5 -0
- package/dist/api/resources/plans/client/requests/ListPlanTraitsRequest.d.ts +20 -0
- package/dist/api/resources/plans/client/requests/ListPlanTraitsRequest.js +5 -0
- package/dist/api/resources/plans/client/requests/UpdatePlanTraitRequestBody.d.ts +14 -0
- package/dist/api/resources/plans/client/requests/UpdatePlanTraitRequestBody.js +5 -0
- package/dist/api/resources/plans/client/requests/UpsertBillingProductRequestBody.d.ts +2 -0
- package/dist/api/resources/plans/client/requests/index.d.ts +4 -0
- package/dist/api/resources/plans/types/CountPlanTraitsParams.d.ts +15 -0
- package/dist/api/resources/plans/types/CountPlanTraitsParams.js +5 -0
- package/dist/api/resources/plans/types/CountPlanTraitsResponse.d.ts +9 -0
- package/dist/api/resources/plans/types/CountPlanTraitsResponse.js +5 -0
- package/dist/api/resources/plans/types/CountPlansRequestPlanType.d.ts +1 -1
- package/dist/api/resources/plans/types/CountPlansResponseParamsPlanType.d.ts +1 -1
- package/dist/api/resources/plans/types/CreatePlanRequestBodyPlanType.d.ts +1 -1
- package/dist/api/resources/plans/types/CreatePlanTraitResponse.d.ts +9 -0
- package/dist/api/resources/plans/types/CreatePlanTraitResponse.js +5 -0
- package/dist/api/resources/plans/types/DeletePlanTraitResponse.d.ts +9 -0
- package/dist/api/resources/plans/types/DeletePlanTraitResponse.js +5 -0
- package/dist/api/resources/plans/types/GetPlanTraitResponse.d.ts +9 -0
- package/dist/api/resources/plans/types/GetPlanTraitResponse.js +5 -0
- package/dist/api/resources/plans/types/ListPlanTraitsParams.d.ts +15 -0
- package/dist/api/resources/plans/types/ListPlanTraitsParams.js +5 -0
- package/dist/api/resources/plans/types/ListPlanTraitsResponse.d.ts +10 -0
- package/dist/api/resources/plans/types/ListPlanTraitsResponse.js +5 -0
- package/dist/api/resources/plans/types/ListPlansRequestPlanType.d.ts +1 -1
- package/dist/api/resources/plans/types/ListPlansResponseParamsPlanType.d.ts +1 -1
- package/dist/api/resources/plans/types/UpdatePlanTraitResponse.d.ts +9 -0
- package/dist/api/resources/plans/types/UpdatePlanTraitResponse.js +5 -0
- package/dist/api/resources/plans/types/index.d.ts +8 -0
- package/dist/api/resources/plans/types/index.js +8 -0
- package/dist/api/resources/webhooks/client/Client.d.ts +28 -9
- package/dist/api/resources/webhooks/client/Client.js +293 -148
- package/dist/api/resources/webhooks/client/requests/CreateWebhookRequestBody.d.ts +1 -0
- package/dist/api/resources/webhooks/client/requests/UpdateWebhookRequestBody.d.ts +1 -0
- package/dist/api/resources/webhooks/types/CreateWebhookRequestBodyRequestTypesItem.d.ts +5 -1
- package/dist/api/resources/webhooks/types/CreateWebhookRequestBodyRequestTypesItem.js +4 -0
- package/dist/api/resources/webhooks/types/UpdateWebhookRequestBodyRequestTypesItem.d.ts +5 -1
- package/dist/api/resources/webhooks/types/UpdateWebhookRequestBodyRequestTypesItem.js +4 -0
- package/dist/api/resources/webhooks/types/UpdateWebhookRequestBodyStatus.d.ts +1 -1
- package/dist/api/types/BillingCouponResponseData.d.ts +0 -3
- package/dist/api/types/BillingPriceResponseData.d.ts +2 -0
- package/dist/api/types/BillingPriceView.d.ts +7 -0
- package/dist/api/types/BillingProductDetailResponseData.d.ts +3 -0
- package/dist/api/types/BillingProductForSubscriptionResponseData.d.ts +5 -0
- package/dist/api/types/BillingProductPlanResponseData.d.ts +2 -0
- package/dist/api/types/BillingProductPriceResponseData.d.ts +3 -0
- package/dist/api/types/BillingProductPriceTierResponseData.d.ts +9 -0
- package/dist/api/types/BillingProductPriceTierResponseData.js +5 -0
- package/dist/api/types/BillingProductPricing.d.ts +4 -1
- package/dist/api/types/BillingProductPricingUsageType.d.ts +8 -0
- package/dist/api/types/BillingProductPricingUsageType.js +10 -0
- package/dist/api/types/BillingProductResponseData.d.ts +2 -0
- package/dist/api/types/BillingSubscriptionResponseData.d.ts +3 -0
- package/dist/api/types/BillingSubscriptionView.d.ts +3 -0
- package/dist/api/types/ChangeSubscriptionInternalRequestBody.d.ts +1 -0
- package/dist/api/types/ChangeSubscriptionRequestBody.d.ts +1 -0
- package/dist/api/types/CheckFlagResponseData.d.ts +2 -0
- package/dist/api/types/CheckoutDataResponseData.d.ts +3 -1
- package/dist/api/types/CompanyDetailResponseData.d.ts +2 -0
- package/dist/api/types/CompanyPlanDetailResponseData.d.ts +5 -0
- package/dist/api/types/CompanyPlanWithBillingSubView.d.ts +2 -0
- package/dist/api/types/CompanySubscriptionResponseData.d.ts +2 -0
- package/dist/api/types/ComponentCapabilities.d.ts +1 -0
- package/dist/api/types/CreateBillingPriceTierRequestBody.d.ts +10 -0
- package/dist/api/types/CreateBillingPriceTierRequestBody.js +5 -0
- package/dist/api/types/CreateEntitlementReqCommonMetricPeriod.d.ts +1 -1
- package/dist/api/types/CreateEntitlementReqCommonMetricPeriodMonthReset.d.ts +1 -1
- package/dist/api/types/CreateEntitlementReqCommonValueType.d.ts +1 -1
- package/dist/api/types/CreateEventRequestBodyEventType.d.ts +1 -1
- package/dist/api/types/CreateOrUpdateConditionRequestBodyConditionType.d.ts +1 -1
- package/dist/api/types/CreateOrUpdateConditionRequestBodyMetricPeriod.d.ts +1 -1
- package/dist/api/types/CreateOrUpdateConditionRequestBodyMetricPeriodMonthReset.d.ts +1 -1
- package/dist/api/types/CreateOrUpdateConditionRequestBodyOperator.d.ts +1 -1
- package/dist/api/types/CreateOrUpdateRuleRequestBodyRuleType.d.ts +1 -1
- package/dist/api/types/CustomPlanConfig.d.ts +8 -0
- package/dist/api/types/CustomPlanConfig.js +5 -0
- package/dist/api/types/CustomPlanViewConfigResponseData.d.ts +8 -0
- package/dist/api/types/CustomPlanViewConfigResponseData.js +5 -0
- package/dist/api/types/DataExportResponseData.d.ts +17 -0
- package/dist/api/types/DataExportResponseData.js +5 -0
- package/dist/api/types/Decimal.d.ts +1 -1
- package/dist/api/types/EntitlementTriggerConfig.d.ts +6 -0
- package/dist/api/types/EntitlementTriggerConfig.js +5 -0
- package/dist/api/types/EntitlementsInPlan.d.ts +7 -0
- package/dist/api/types/EntitlementsInPlan.js +5 -0
- package/dist/api/types/EventBody.d.ts +1 -1
- package/dist/api/types/EventSummaryResponseData.d.ts +2 -2
- package/dist/api/types/FeatureCompanyResponseDataAllocationType.d.ts +1 -1
- package/dist/api/types/FeatureCompanyUserResponseDataAllocationType.d.ts +1 -1
- package/dist/api/types/FeatureDetailResponseData.d.ts +2 -0
- package/dist/api/types/FeatureResponseData.d.ts +2 -0
- package/dist/api/types/FeatureUsageResponseData.d.ts +2 -0
- package/dist/api/types/FeatureUsageResponseDataAllocationType.d.ts +1 -1
- package/dist/api/types/OrderedPlansInGroup.d.ts +8 -0
- package/dist/api/types/OrderedPlansInGroup.js +5 -0
- package/dist/api/types/PaymentMethodRequestBody.d.ts +0 -1
- package/dist/api/types/PaymentMethodResponseData.d.ts +0 -1
- package/dist/api/types/PlanDetailResponseData.d.ts +2 -0
- package/dist/api/types/PlanEntitlementResponseData.d.ts +2 -0
- package/dist/api/types/PlanEntitlementsOrder.d.ts +7 -0
- package/dist/api/types/PlanEntitlementsOrder.js +5 -0
- package/dist/api/types/PlanGroupDetailResponseData.d.ts +3 -0
- package/dist/api/types/PlanGroupPlanDetailResponseData.d.ts +4 -0
- package/dist/api/types/PlanGroupPlanEntitlementsOrder.d.ts +8 -0
- package/dist/api/types/PlanGroupPlanEntitlementsOrder.js +5 -0
- package/dist/api/types/PlanGroupResponseData.d.ts +2 -1
- package/dist/api/types/PlanTraitResponseData.d.ts +16 -0
- package/dist/api/types/PlanTraitResponseData.js +5 -0
- package/dist/api/types/PreviewSubscriptionChangeResponseData.d.ts +3 -0
- package/dist/api/types/PreviewSubscriptionFinanceResponseData.d.ts +15 -0
- package/dist/api/types/PreviewSubscriptionFinanceResponseData.js +5 -0
- package/dist/api/types/PreviewSubscriptionUpcomingInvoiceLineItems.d.ts +10 -0
- package/dist/api/types/PreviewSubscriptionUpcomingInvoiceLineItems.js +5 -0
- package/dist/api/types/QuickstartResp.d.ts +6 -0
- package/dist/api/types/QuickstartResp.js +5 -0
- package/dist/api/types/UpdateEntitlementReqCommonMetricPeriod.d.ts +1 -1
- package/dist/api/types/UpdateEntitlementReqCommonMetricPeriodMonthReset.d.ts +1 -1
- package/dist/api/types/UpdateEntitlementReqCommonValueType.d.ts +1 -1
- package/dist/api/types/UpsertCompanyRequestBody.d.ts +1 -0
- package/dist/api/types/UpsertTraitRequestBody.d.ts +1 -1
- package/dist/api/types/UpsertUserRequestBody.d.ts +7 -2
- package/dist/api/types/UpsertUserSubRequestBody.d.ts +4 -1
- package/dist/api/types/UsageBasedEntitlementRequestBody.d.ts +7 -0
- package/dist/api/types/WebhookResponseData.d.ts +3 -0
- package/dist/api/types/index.d.ts +15 -0
- package/dist/api/types/index.js +15 -0
- package/dist/core/fetcher/APIResponse.d.ts +11 -1
- package/dist/core/fetcher/Fetcher.d.ts +2 -2
- package/dist/core/fetcher/Fetcher.js +13 -5
- package/dist/core/fetcher/Headers.d.ts +2 -0
- package/dist/core/fetcher/Headers.js +84 -0
- package/dist/core/fetcher/HttpResponsePromise.d.ts +58 -0
- package/dist/core/fetcher/HttpResponsePromise.js +103 -0
- package/dist/core/fetcher/RawResponse.d.ts +29 -0
- package/dist/core/fetcher/RawResponse.js +44 -0
- package/dist/core/fetcher/Supplier.d.ts +1 -1
- package/dist/core/fetcher/createRequestUrl.d.ts +1 -1
- package/dist/core/fetcher/createRequestUrl.js +1 -2
- package/dist/core/fetcher/custom.js +19 -2
- package/dist/core/fetcher/getFetchFn.js +18 -9
- package/dist/core/fetcher/getHeader.js +1 -2
- package/dist/core/fetcher/getRequestBody.js +5 -5
- package/dist/core/fetcher/getResponseBody.js +1 -2
- package/dist/core/fetcher/index.d.ts +3 -0
- package/dist/core/fetcher/index.js +7 -1
- package/dist/core/fetcher/makeRequest.d.ts +1 -1
- package/dist/core/fetcher/requestWithRetries.js +4 -5
- package/dist/core/fetcher/signals.d.ts +0 -1
- package/dist/core/fetcher/signals.js +2 -3
- package/dist/core/fetcher/stream-wrappers/NodePre18StreamWrapper.d.ts +0 -1
- package/dist/core/fetcher/stream-wrappers/NodePre18StreamWrapper.js +6 -4
- package/dist/core/fetcher/stream-wrappers/UndiciStreamWrapper.d.ts +1 -1
- package/dist/core/fetcher/stream-wrappers/chooseStreamWrapper.d.ts +1 -1
- package/dist/core/fetcher/stream-wrappers/chooseStreamWrapper.js +18 -9
- package/dist/core/index.js +17 -7
- package/dist/core/json.d.ts +15 -0
- package/dist/core/json.js +24 -0
- package/dist/core/runtime/runtime.d.ts +1 -1
- package/dist/core/runtime/runtime.js +51 -41
- package/dist/core/schemas/Schema.d.ts +7 -5
- package/dist/core/schemas/Schema.js +2 -0
- package/dist/core/schemas/builders/bigint/bigint.d.ts +1 -1
- package/dist/core/schemas/builders/bigint/bigint.js +22 -19
- package/dist/core/schemas/builders/date/date.js +1 -2
- package/dist/core/schemas/builders/enum/enum.js +1 -2
- package/dist/core/schemas/builders/lazy/lazy.d.ts +1 -1
- package/dist/core/schemas/builders/lazy/lazy.js +3 -4
- package/dist/core/schemas/builders/lazy/lazyObject.js +1 -2
- package/dist/core/schemas/builders/list/list.js +1 -2
- package/dist/core/schemas/builders/literals/booleanLiteral.js +1 -2
- package/dist/core/schemas/builders/literals/stringLiteral.js +1 -2
- package/dist/core/schemas/builders/object/object.d.ts +1 -1
- package/dist/core/schemas/builders/object/object.js +31 -3
- package/dist/core/schemas/builders/object/objectWithoutOptionalProperties.d.ts +3 -3
- package/dist/core/schemas/builders/object/objectWithoutOptionalProperties.js +1 -2
- package/dist/core/schemas/builders/object/property.js +2 -3
- package/dist/core/schemas/builders/object/types.d.ts +16 -11
- package/dist/core/schemas/builders/object-like/getObjectLikeUtils.js +2 -3
- package/dist/core/schemas/builders/object-like/types.d.ts +1 -1
- package/dist/core/schemas/builders/record/record.js +2 -4
- package/dist/core/schemas/builders/record/types.d.ts +2 -2
- package/dist/core/schemas/builders/schema-utils/getSchemaUtils.d.ts +4 -0
- package/dist/core/schemas/builders/schema-utils/getSchemaUtils.js +67 -4
- package/dist/core/schemas/builders/schema-utils/stringifyValidationErrors.js +1 -2
- package/dist/core/schemas/builders/set/set.js +1 -2
- package/dist/core/schemas/builders/undiscriminated-union/types.d.ts +4 -4
- package/dist/core/schemas/builders/undiscriminated-union/undiscriminatedUnion.js +1 -2
- package/dist/core/schemas/builders/union/discriminant.js +1 -2
- package/dist/core/schemas/builders/union/types.d.ts +6 -6
- package/dist/core/schemas/builders/union/union.d.ts +1 -1
- package/dist/core/schemas/builders/union/union.js +1 -2
- package/dist/core/schemas/utils/MaybePromise.d.ts +1 -1
- package/dist/core/schemas/utils/addQuestionMarksToNullableProperties.d.ts +4 -4
- package/dist/core/schemas/utils/createIdentitySchemaCreator.js +1 -2
- package/dist/core/schemas/utils/entries.d.ts +1 -1
- package/dist/core/schemas/utils/entries.js +1 -2
- package/dist/core/schemas/utils/filterObject.d.ts +1 -1
- package/dist/core/schemas/utils/filterObject.js +1 -2
- package/dist/core/schemas/utils/getErrorMessageForIncorrectType.js +1 -2
- package/dist/core/schemas/utils/isPlainObject.js +1 -2
- package/dist/core/schemas/utils/keys.d.ts +1 -1
- package/dist/core/schemas/utils/keys.js +1 -2
- package/dist/core/schemas/utils/maybeSkipValidation.js +1 -2
- package/dist/core/schemas/utils/partition.js +1 -2
- package/dist/environments.d.ts +1 -1
- package/dist/errors/SchematicError.d.ts +4 -1
- package/dist/errors/SchematicError.js +6 -8
- package/dist/errors/SchematicTimeoutError.d.ts +1 -1
- package/dist/errors/SchematicTimeoutError.js +2 -2
- package/dist/events.d.ts +4 -0
- package/dist/events.js +41 -5
- package/dist/events.test.js +51 -4
- package/dist/index.d.ts +1 -0
- package/dist/index.js +26 -8
- package/dist/serialization/resources/accesstokens/client/requests/IssueTemporaryAccessTokenRequestBody.js +17 -7
- package/dist/serialization/resources/accesstokens/types/IssueTemporaryAccessTokenResponse.js +17 -7
- package/dist/serialization/resources/accounts/client/requests/CreateApiKeyRequestBody.js +17 -7
- package/dist/serialization/resources/accounts/client/requests/CreateEnvironmentRequestBody.js +17 -7
- package/dist/serialization/resources/accounts/client/requests/UpdateApiKeyRequestBody.js +17 -7
- package/dist/serialization/resources/accounts/client/requests/UpdateEnvironmentRequestBody.js +17 -7
- package/dist/serialization/resources/accounts/types/CountApiKeysParams.js +17 -7
- package/dist/serialization/resources/accounts/types/CountApiKeysResponse.js +17 -7
- package/dist/serialization/resources/accounts/types/CountApiRequestsParams.js +17 -7
- package/dist/serialization/resources/accounts/types/CountApiRequestsResponse.js +17 -7
- package/dist/serialization/resources/accounts/types/CreateApiKeyResponse.js +17 -7
- package/dist/serialization/resources/accounts/types/CreateEnvironmentRequestBodyEnvironmentType.js +17 -7
- package/dist/serialization/resources/accounts/types/CreateEnvironmentResponse.js +17 -7
- package/dist/serialization/resources/accounts/types/DeleteApiKeyResponse.js +17 -7
- package/dist/serialization/resources/accounts/types/DeleteEnvironmentResponse.js +17 -7
- package/dist/serialization/resources/accounts/types/GetApiKeyResponse.js +17 -7
- package/dist/serialization/resources/accounts/types/GetApiRequestResponse.js +17 -7
- package/dist/serialization/resources/accounts/types/GetEnvironmentResponse.js +17 -7
- package/dist/serialization/resources/accounts/types/ListApiKeysParams.js +17 -7
- package/dist/serialization/resources/accounts/types/ListApiKeysResponse.js +17 -7
- package/dist/serialization/resources/accounts/types/ListApiRequestsParams.js +17 -7
- package/dist/serialization/resources/accounts/types/ListApiRequestsResponse.js +17 -7
- package/dist/serialization/resources/accounts/types/ListEnvironmentsParams.js +17 -7
- package/dist/serialization/resources/accounts/types/ListEnvironmentsResponse.js +17 -7
- package/dist/serialization/resources/accounts/types/QuickstartResponse.d.ts +14 -0
- package/dist/serialization/resources/accounts/types/QuickstartResponse.js +45 -0
- package/dist/serialization/resources/accounts/types/UpdateApiKeyResponse.js +17 -7
- package/dist/serialization/resources/accounts/types/UpdateEnvironmentRequestBodyEnvironmentType.js +17 -7
- package/dist/serialization/resources/accounts/types/UpdateEnvironmentResponse.js +17 -7
- package/dist/serialization/resources/accounts/types/index.d.ts +1 -0
- package/dist/serialization/resources/accounts/types/index.js +1 -0
- package/dist/serialization/resources/billing/client/requests/CreateBillingCustomerRequestBody.d.ts +1 -0
- package/dist/serialization/resources/billing/client/requests/CreateBillingCustomerRequestBody.js +18 -7
- package/dist/serialization/resources/billing/client/requests/CreateBillingPriceRequestBody.d.ts +11 -1
- package/dist/serialization/resources/billing/client/requests/CreateBillingPriceRequestBody.js +28 -8
- package/dist/serialization/resources/billing/client/requests/CreateBillingProductRequestBody.d.ts +1 -2
- package/dist/serialization/resources/billing/client/requests/CreateBillingProductRequestBody.js +18 -9
- package/dist/serialization/resources/billing/client/requests/CreateBillingSubscriptionsRequestBody.d.ts +5 -1
- package/dist/serialization/resources/billing/client/requests/CreateBillingSubscriptionsRequestBody.js +22 -8
- package/dist/serialization/resources/billing/client/requests/CreateCouponRequestBody.js +17 -7
- package/dist/serialization/resources/billing/client/requests/CreateInvoiceRequestBody.js +17 -7
- package/dist/serialization/resources/billing/client/requests/CreateMeterRequestBody.js +17 -7
- package/dist/serialization/resources/billing/client/requests/CreatePaymentMethodRequestBody.d.ts +0 -1
- package/dist/serialization/resources/billing/client/requests/CreatePaymentMethodRequestBody.js +17 -8
- package/dist/serialization/resources/billing/types/CountBillingProductsParams.d.ts +4 -1
- package/dist/serialization/resources/billing/types/CountBillingProductsParams.js +21 -8
- package/dist/serialization/resources/billing/types/CountBillingProductsRequestPriceUsageType.d.ts +10 -0
- package/dist/serialization/resources/billing/types/CountBillingProductsRequestPriceUsageType.js +41 -0
- package/dist/serialization/resources/billing/types/CountBillingProductsResponse.js +17 -7
- package/dist/serialization/resources/billing/types/CountBillingProductsResponseParamsPriceUsageType.d.ts +10 -0
- package/dist/serialization/resources/billing/types/CountBillingProductsResponseParamsPriceUsageType.js +41 -0
- package/dist/serialization/resources/billing/types/CountCustomersParams.d.ts +1 -0
- package/dist/serialization/resources/billing/types/CountCustomersParams.js +18 -7
- package/dist/serialization/resources/billing/types/CountCustomersResponse.js +17 -7
- package/dist/serialization/resources/billing/types/CreateBillingPriceRequestBodyBillingScheme.d.ts +10 -0
- package/dist/serialization/resources/billing/types/CreateBillingPriceRequestBodyBillingScheme.js +41 -0
- package/dist/serialization/resources/billing/types/CreateBillingPriceRequestBodyTierMode.d.ts +10 -0
- package/dist/serialization/resources/billing/types/CreateBillingPriceRequestBodyTierMode.js +41 -0
- package/dist/serialization/resources/billing/types/CreateBillingPriceRequestBodyUsageType.d.ts +10 -0
- package/dist/serialization/resources/billing/types/CreateBillingPriceRequestBodyUsageType.js +41 -0
- package/dist/serialization/resources/billing/types/CreateBillingSubscriptionsRequestBodyTrialEndSetting.d.ts +10 -0
- package/dist/serialization/resources/billing/types/CreateBillingSubscriptionsRequestBodyTrialEndSetting.js +41 -0
- package/dist/serialization/resources/billing/types/DeleteBillingProductResponse.d.ts +14 -0
- package/dist/serialization/resources/billing/types/DeleteBillingProductResponse.js +45 -0
- package/dist/serialization/resources/billing/types/DeleteProductPriceResponse.js +17 -7
- package/dist/serialization/resources/billing/types/ListBillingProductsParams.d.ts +4 -1
- package/dist/serialization/resources/billing/types/ListBillingProductsParams.js +21 -8
- package/dist/serialization/resources/billing/types/ListBillingProductsRequestPriceUsageType.d.ts +10 -0
- package/dist/serialization/resources/billing/types/ListBillingProductsRequestPriceUsageType.js +41 -0
- package/dist/serialization/resources/billing/types/ListBillingProductsResponse.js +17 -7
- package/dist/serialization/resources/billing/types/ListBillingProductsResponseParamsPriceUsageType.d.ts +10 -0
- package/dist/serialization/resources/billing/types/ListBillingProductsResponseParamsPriceUsageType.js +41 -0
- package/dist/serialization/resources/billing/types/ListCouponsParams.d.ts +15 -0
- package/dist/serialization/resources/billing/types/ListCouponsParams.js +46 -0
- package/dist/serialization/resources/billing/types/ListCouponsResponse.d.ts +15 -0
- package/dist/serialization/resources/billing/types/ListCouponsResponse.js +46 -0
- package/dist/serialization/resources/billing/types/{ListCustomersParams.d.ts → ListCustomersWithSubscriptionsParams.d.ts} +3 -2
- package/dist/serialization/resources/billing/types/{ListCustomersParams.js → ListCustomersWithSubscriptionsParams.js} +20 -9
- package/{serialization/resources/billing/types/ListCustomersResponse.d.ts → dist/serialization/resources/billing/types/ListCustomersWithSubscriptionsResponse.d.ts} +4 -4
- package/dist/serialization/resources/billing/types/{ListCustomersResponse.js → ListCustomersWithSubscriptionsResponse.js} +21 -11
- package/dist/serialization/resources/billing/types/ListInvoicesParams.js +17 -7
- package/dist/serialization/resources/billing/types/ListInvoicesResponse.js +17 -7
- package/dist/serialization/resources/billing/types/ListMetersParams.js +17 -7
- package/dist/serialization/resources/billing/types/ListMetersResponse.js +17 -7
- package/dist/serialization/resources/billing/types/ListPaymentMethodsParams.d.ts +0 -1
- package/dist/serialization/resources/billing/types/ListPaymentMethodsParams.js +17 -8
- package/dist/serialization/resources/billing/types/ListPaymentMethodsResponse.js +17 -7
- package/dist/serialization/resources/billing/types/ListProductPricesParams.d.ts +4 -1
- package/dist/serialization/resources/billing/types/ListProductPricesParams.js +21 -8
- package/dist/serialization/resources/billing/types/ListProductPricesRequestPriceUsageType.d.ts +10 -0
- package/dist/serialization/resources/billing/types/ListProductPricesRequestPriceUsageType.js +41 -0
- package/dist/serialization/resources/billing/types/ListProductPricesResponse.js +17 -7
- package/dist/serialization/resources/billing/types/ListProductPricesResponseParamsPriceUsageType.d.ts +10 -0
- package/dist/serialization/resources/billing/types/ListProductPricesResponseParamsPriceUsageType.js +41 -0
- package/dist/serialization/resources/billing/types/SearchBillingPricesParams.d.ts +3 -1
- package/dist/serialization/resources/billing/types/SearchBillingPricesParams.js +20 -8
- package/dist/serialization/resources/billing/types/SearchBillingPricesRequestUsageType.d.ts +10 -0
- package/dist/serialization/resources/billing/types/SearchBillingPricesRequestUsageType.js +41 -0
- package/dist/serialization/resources/billing/types/SearchBillingPricesResponse.js +17 -7
- package/dist/serialization/resources/billing/types/SearchBillingPricesResponseParamsUsageType.d.ts +10 -0
- package/dist/serialization/resources/billing/types/SearchBillingPricesResponseParamsUsageType.js +41 -0
- package/dist/serialization/resources/billing/types/UpsertBillingCouponResponse.js +17 -7
- package/dist/serialization/resources/billing/types/UpsertBillingCustomerResponse.js +17 -7
- package/dist/serialization/resources/billing/types/UpsertBillingMeterResponse.js +17 -7
- package/dist/serialization/resources/billing/types/UpsertBillingPriceResponse.js +17 -7
- package/dist/serialization/resources/billing/types/UpsertBillingProductResponse.js +17 -7
- package/dist/serialization/resources/billing/types/UpsertBillingSubscriptionResponse.js +17 -7
- package/dist/serialization/resources/billing/types/UpsertInvoiceResponse.js +17 -7
- package/dist/serialization/resources/billing/types/UpsertPaymentMethodResponse.js +17 -7
- package/dist/serialization/resources/billing/types/index.d.ts +17 -2
- package/dist/serialization/resources/billing/types/index.js +17 -2
- package/dist/serialization/resources/checkout/client/requests/CheckoutDataRequestBody.d.ts +13 -0
- package/dist/serialization/resources/checkout/client/requests/CheckoutDataRequestBody.js +44 -0
- package/dist/serialization/resources/checkout/client/requests/UpdateTrialEndRequestBody.js +17 -7
- package/dist/serialization/resources/checkout/client/requests/index.d.ts +1 -0
- package/dist/serialization/resources/checkout/client/requests/index.js +3 -1
- package/dist/serialization/resources/checkout/types/CheckoutInternalResponse.js +17 -7
- package/dist/serialization/resources/checkout/types/GetCheckoutDataResponse.js +17 -7
- package/dist/serialization/resources/checkout/types/PreviewCheckoutInternalResponse.js +17 -7
- package/dist/serialization/resources/checkout/types/UpdateCustomerSubscriptionTrialEndResponse.js +17 -7
- package/dist/serialization/resources/companies/client/requests/CreateEntityTraitDefinitionRequestBody.js +17 -7
- package/dist/serialization/resources/companies/client/requests/GetOrCreateCompanyMembershipRequestBody.js +17 -7
- package/dist/serialization/resources/companies/client/requests/UpdateEntityTraitDefinitionRequestBody.js +17 -7
- package/dist/serialization/resources/companies/types/CountCompaniesParams.d.ts +1 -0
- package/dist/serialization/resources/companies/types/CountCompaniesParams.js +18 -7
- package/dist/serialization/resources/companies/types/CountCompaniesResponse.js +17 -7
- package/dist/serialization/resources/companies/types/CountEntityKeyDefinitionsParams.js +17 -7
- package/dist/serialization/resources/companies/types/CountEntityKeyDefinitionsRequestEntityType.js +17 -7
- package/dist/serialization/resources/companies/types/CountEntityKeyDefinitionsResponse.js +17 -7
- package/dist/serialization/resources/companies/types/CountEntityKeyDefinitionsResponseParamsEntityType.js +17 -7
- package/dist/serialization/resources/companies/types/CountEntityTraitDefinitionsParams.js +17 -7
- package/dist/serialization/resources/companies/types/CountEntityTraitDefinitionsRequestEntityType.js +17 -7
- package/dist/serialization/resources/companies/types/CountEntityTraitDefinitionsRequestTraitType.js +17 -7
- package/dist/serialization/resources/companies/types/CountEntityTraitDefinitionsResponse.js +17 -7
- package/dist/serialization/resources/companies/types/CountEntityTraitDefinitionsResponseParamsEntityType.js +17 -7
- package/dist/serialization/resources/companies/types/CountEntityTraitDefinitionsResponseParamsTraitType.js +17 -7
- package/dist/serialization/resources/companies/types/CountUsersParams.js +17 -7
- package/dist/serialization/resources/companies/types/CountUsersResponse.js +17 -7
- package/dist/serialization/resources/companies/types/CreateCompanyResponse.js +17 -7
- package/dist/serialization/resources/companies/types/CreateEntityTraitDefinitionRequestBodyEntityType.js +17 -7
- package/dist/serialization/resources/companies/types/CreateEntityTraitDefinitionRequestBodyTraitType.js +17 -7
- package/dist/serialization/resources/companies/types/CreateUserResponse.js +17 -7
- package/dist/serialization/resources/companies/types/DeleteCompanyByKeysResponse.js +17 -7
- package/dist/serialization/resources/companies/types/DeleteCompanyMembershipResponse.js +17 -7
- package/dist/serialization/resources/companies/types/DeleteCompanyResponse.js +17 -7
- package/dist/serialization/resources/companies/types/DeleteUserByKeysResponse.js +17 -7
- package/dist/serialization/resources/companies/types/DeleteUserResponse.js +17 -7
- package/dist/serialization/resources/companies/types/GetActiveCompanySubscriptionParams.js +17 -7
- package/dist/serialization/resources/companies/types/GetActiveCompanySubscriptionResponse.js +17 -7
- package/dist/serialization/resources/companies/types/GetActiveDealsParams.js +17 -7
- package/dist/serialization/resources/companies/types/GetActiveDealsResponse.js +17 -7
- package/dist/serialization/resources/companies/types/GetCompanyResponse.js +17 -7
- package/dist/serialization/resources/companies/types/GetEntityTraitDefinitionResponse.js +17 -7
- package/dist/serialization/resources/companies/types/GetEntityTraitValuesParams.js +17 -7
- package/dist/serialization/resources/companies/types/GetEntityTraitValuesResponse.js +17 -7
- package/dist/serialization/resources/companies/types/GetOrCreateCompanyMembershipResponse.js +17 -7
- package/dist/serialization/resources/companies/types/GetOrCreateEntityTraitDefinitionResponse.js +17 -7
- package/dist/serialization/resources/companies/types/GetUserResponse.js +17 -7
- package/dist/serialization/resources/companies/types/ListCompaniesParams.d.ts +1 -0
- package/dist/serialization/resources/companies/types/ListCompaniesParams.js +18 -7
- package/dist/serialization/resources/companies/types/ListCompaniesResponse.js +17 -7
- package/dist/serialization/resources/companies/types/ListCompanyMembershipsParams.js +17 -7
- package/dist/serialization/resources/companies/types/ListCompanyMembershipsResponse.js +17 -7
- package/dist/serialization/resources/companies/types/ListEntityKeyDefinitionsParams.js +17 -7
- package/dist/serialization/resources/companies/types/ListEntityKeyDefinitionsRequestEntityType.js +17 -7
- package/dist/serialization/resources/companies/types/ListEntityKeyDefinitionsResponse.js +17 -7
- package/dist/serialization/resources/companies/types/ListEntityKeyDefinitionsResponseParamsEntityType.js +17 -7
- package/dist/serialization/resources/companies/types/ListEntityTraitDefinitionsParams.js +17 -7
- package/dist/serialization/resources/companies/types/ListEntityTraitDefinitionsRequestEntityType.js +17 -7
- package/dist/serialization/resources/companies/types/ListEntityTraitDefinitionsRequestTraitType.js +17 -7
- package/dist/serialization/resources/companies/types/ListEntityTraitDefinitionsResponse.js +17 -7
- package/dist/serialization/resources/companies/types/ListEntityTraitDefinitionsResponseParamsEntityType.js +17 -7
- package/dist/serialization/resources/companies/types/ListEntityTraitDefinitionsResponseParamsTraitType.js +17 -7
- package/dist/serialization/resources/companies/types/ListUsersParams.js +17 -7
- package/dist/serialization/resources/companies/types/ListUsersResponse.js +17 -7
- package/dist/serialization/resources/companies/types/LookupCompanyParams.d.ts +1 -1
- package/dist/serialization/resources/companies/types/LookupCompanyParams.js +18 -8
- package/dist/serialization/resources/companies/types/LookupCompanyResponse.js +17 -7
- package/dist/serialization/resources/companies/types/LookupUserParams.d.ts +1 -1
- package/dist/serialization/resources/companies/types/LookupUserParams.js +18 -8
- package/dist/serialization/resources/companies/types/LookupUserResponse.js +17 -7
- package/dist/serialization/resources/companies/types/UpdateEntityTraitDefinitionRequestBodyTraitType.js +17 -7
- package/dist/serialization/resources/companies/types/UpdateEntityTraitDefinitionResponse.js +17 -7
- package/dist/serialization/resources/companies/types/UpsertCompanyResponse.js +17 -7
- package/dist/serialization/resources/companies/types/UpsertCompanyTraitResponse.js +17 -7
- package/dist/serialization/resources/companies/types/UpsertUserResponse.js +17 -7
- package/dist/serialization/resources/companies/types/UpsertUserTraitResponse.js +17 -7
- package/dist/serialization/resources/components/client/requests/CreateComponentRequestBody.js +17 -7
- package/dist/serialization/resources/components/client/requests/UpdateComponentRequestBody.js +17 -7
- package/dist/serialization/resources/components/types/CountComponentsParams.js +17 -7
- package/dist/serialization/resources/components/types/CountComponentsResponse.js +17 -7
- package/dist/serialization/resources/components/types/CreateComponentRequestBodyEntityType.js +17 -7
- package/dist/serialization/resources/components/types/CreateComponentResponse.js +17 -7
- package/dist/serialization/resources/components/types/DeleteComponentResponse.js +17 -7
- package/dist/serialization/resources/components/types/GetComponentResponse.js +17 -7
- package/dist/serialization/resources/components/types/ListComponentsParams.js +17 -7
- package/dist/serialization/resources/components/types/ListComponentsResponse.js +17 -7
- package/dist/serialization/resources/components/types/PreviewComponentDataParams.js +17 -7
- package/dist/serialization/resources/components/types/PreviewComponentDataResponse.js +17 -7
- package/dist/serialization/resources/components/types/UpdateComponentRequestBodyEntityType.js +17 -7
- package/dist/serialization/resources/components/types/UpdateComponentRequestBodyState.js +17 -7
- package/dist/serialization/resources/components/types/UpdateComponentResponse.js +17 -7
- package/dist/serialization/resources/crm/client/requests/CreateCrmDealLineItemAssociationRequestBody.js +17 -7
- package/dist/serialization/resources/crm/client/requests/CreateCrmDealRequestBody.js +17 -7
- package/dist/serialization/resources/crm/client/requests/CreateCrmLineItemRequestBody.js +17 -7
- package/dist/serialization/resources/crm/client/requests/CreateCrmProductRequestBody.js +17 -7
- package/dist/serialization/resources/crm/types/ListCrmProductsParams.js +17 -7
- package/dist/serialization/resources/crm/types/ListCrmProductsResponse.js +17 -7
- package/dist/serialization/resources/crm/types/UpsertCrmDealResponse.js +17 -7
- package/dist/serialization/resources/crm/types/UpsertCrmProductResponse.js +17 -7
- package/dist/serialization/resources/crm/types/UpsertDealLineItemAssociationResponse.js +17 -7
- package/dist/serialization/resources/crm/types/UpsertLineItemResponse.js +17 -7
- package/dist/serialization/resources/dataexports/client/index.d.ts +1 -0
- package/dist/serialization/resources/dataexports/client/index.js +17 -0
- package/dist/serialization/resources/dataexports/client/requests/CreateDataExportRequestBody.d.ts +12 -0
- package/dist/serialization/resources/dataexports/client/requests/CreateDataExportRequestBody.js +43 -0
- package/dist/serialization/resources/dataexports/client/requests/index.d.ts +1 -0
- package/dist/serialization/resources/dataexports/client/requests/index.js +5 -0
- package/dist/serialization/resources/dataexports/index.d.ts +2 -0
- package/dist/serialization/resources/dataexports/index.js +18 -0
- package/dist/serialization/resources/dataexports/types/CreateDataExportResponse.d.ts +14 -0
- package/dist/serialization/resources/dataexports/types/CreateDataExportResponse.js +45 -0
- package/dist/serialization/resources/dataexports/types/index.d.ts +1 -0
- package/dist/serialization/resources/dataexports/types/index.js +17 -0
- package/dist/serialization/resources/entitlements/client/requests/CreateCompanyOverrideRequestBody.js +17 -7
- package/dist/serialization/resources/entitlements/client/requests/CreatePlanEntitlementRequestBody.d.ts +7 -0
- package/dist/serialization/resources/entitlements/client/requests/CreatePlanEntitlementRequestBody.js +24 -7
- package/dist/serialization/resources/entitlements/client/requests/UpdateCompanyOverrideRequestBody.js +17 -7
- package/dist/serialization/resources/entitlements/client/requests/UpdatePlanEntitlementRequestBody.d.ts +7 -0
- package/dist/serialization/resources/entitlements/client/requests/UpdatePlanEntitlementRequestBody.js +24 -7
- package/dist/serialization/resources/entitlements/types/CountCompanyOverridesParams.js +17 -7
- package/dist/serialization/resources/entitlements/types/CountCompanyOverridesResponse.js +17 -7
- package/dist/serialization/resources/entitlements/types/CountFeatureCompaniesParams.js +17 -7
- package/dist/serialization/resources/entitlements/types/CountFeatureCompaniesResponse.js +17 -7
- package/dist/serialization/resources/entitlements/types/CountFeatureUsageParams.js +17 -7
- package/dist/serialization/resources/entitlements/types/CountFeatureUsageResponse.js +17 -7
- package/dist/serialization/resources/entitlements/types/CountFeatureUsersParams.js +17 -7
- package/dist/serialization/resources/entitlements/types/CountFeatureUsersResponse.js +17 -7
- package/dist/serialization/resources/entitlements/types/CountPlanEntitlementsParams.js +17 -7
- package/dist/serialization/resources/entitlements/types/CountPlanEntitlementsResponse.js +17 -7
- package/dist/serialization/resources/entitlements/types/CreateCompanyOverrideRequestBodyMetricPeriod.js +17 -7
- package/dist/serialization/resources/entitlements/types/CreateCompanyOverrideRequestBodyMetricPeriodMonthReset.js +17 -7
- package/dist/serialization/resources/entitlements/types/CreateCompanyOverrideRequestBodyValueType.js +17 -7
- package/dist/serialization/resources/entitlements/types/CreateCompanyOverrideResponse.js +17 -7
- package/dist/serialization/resources/entitlements/types/CreatePlanEntitlementRequestBodyMetricPeriod.js +17 -7
- package/dist/serialization/resources/entitlements/types/CreatePlanEntitlementRequestBodyMetricPeriodMonthReset.js +17 -7
- package/dist/serialization/resources/entitlements/types/CreatePlanEntitlementRequestBodyValueType.js +17 -7
- package/dist/serialization/resources/entitlements/types/CreatePlanEntitlementResponse.js +17 -7
- package/dist/serialization/resources/entitlements/types/DeleteCompanyOverrideResponse.js +17 -7
- package/dist/serialization/resources/entitlements/types/DeletePlanEntitlementResponse.js +17 -7
- package/dist/serialization/resources/entitlements/types/GetCompanyOverrideResponse.js +17 -7
- package/dist/serialization/resources/entitlements/types/GetFeatureUsageByCompanyParams.d.ts +1 -1
- package/dist/serialization/resources/entitlements/types/GetFeatureUsageByCompanyParams.js +18 -8
- package/dist/serialization/resources/entitlements/types/GetFeatureUsageByCompanyResponse.js +17 -7
- package/dist/serialization/resources/entitlements/types/GetPlanEntitlementResponse.js +17 -7
- package/dist/serialization/resources/entitlements/types/ListCompanyOverridesParams.js +17 -7
- package/dist/serialization/resources/entitlements/types/ListCompanyOverridesResponse.js +17 -7
- package/dist/serialization/resources/entitlements/types/ListFeatureCompaniesParams.js +17 -7
- package/dist/serialization/resources/entitlements/types/ListFeatureCompaniesResponse.js +17 -7
- package/dist/serialization/resources/entitlements/types/ListFeatureUsageParams.js +17 -7
- package/dist/serialization/resources/entitlements/types/ListFeatureUsageResponse.js +17 -7
- package/dist/serialization/resources/entitlements/types/ListFeatureUsersParams.js +17 -7
- package/dist/serialization/resources/entitlements/types/ListFeatureUsersResponse.js +17 -7
- package/dist/serialization/resources/entitlements/types/ListPlanEntitlementsParams.js +17 -7
- package/dist/serialization/resources/entitlements/types/ListPlanEntitlementsResponse.js +17 -7
- package/dist/serialization/resources/entitlements/types/UpdateCompanyOverrideRequestBodyMetricPeriod.js +17 -7
- package/dist/serialization/resources/entitlements/types/UpdateCompanyOverrideRequestBodyMetricPeriodMonthReset.js +17 -7
- package/dist/serialization/resources/entitlements/types/UpdateCompanyOverrideRequestBodyValueType.js +17 -7
- package/dist/serialization/resources/entitlements/types/UpdateCompanyOverrideResponse.js +17 -7
- package/dist/serialization/resources/entitlements/types/UpdatePlanEntitlementRequestBodyMetricPeriod.js +17 -7
- package/dist/serialization/resources/entitlements/types/UpdatePlanEntitlementRequestBodyMetricPeriodMonthReset.js +17 -7
- package/dist/serialization/resources/entitlements/types/UpdatePlanEntitlementRequestBodyValueType.js +17 -7
- package/dist/serialization/resources/entitlements/types/UpdatePlanEntitlementResponse.js +17 -7
- package/dist/serialization/resources/events/client/requests/CreateEventBatchRequestBody.js +17 -7
- package/dist/serialization/resources/events/types/CreateEventBatchResponse.js +17 -7
- package/dist/serialization/resources/events/types/CreateEventResponse.js +17 -7
- package/dist/serialization/resources/events/types/GetEventResponse.js +17 -7
- package/dist/serialization/resources/events/types/GetEventSummariesParams.js +17 -7
- package/dist/serialization/resources/events/types/GetEventSummariesResponse.js +17 -7
- package/dist/serialization/resources/events/types/GetSegmentIntegrationStatusResponse.js +17 -7
- package/dist/serialization/resources/events/types/ListEventsParams.js +17 -7
- package/dist/serialization/resources/events/types/ListEventsResponse.js +17 -7
- package/dist/serialization/resources/features/client/requests/CreateFeatureRequestBody.d.ts +2 -0
- package/dist/serialization/resources/features/client/requests/CreateFeatureRequestBody.js +19 -7
- package/dist/serialization/resources/features/client/requests/UpdateFeatureRequestBody.d.ts +2 -0
- package/dist/serialization/resources/features/client/requests/UpdateFeatureRequestBody.js +19 -7
- package/dist/serialization/resources/features/client/requests/UpdateFlagRulesRequestBody.js +17 -7
- package/dist/serialization/resources/features/types/CheckFlagResponse.js +17 -7
- package/dist/serialization/resources/features/types/CheckFlagsResponse.js +17 -7
- package/dist/serialization/resources/features/types/CountAudienceCompaniesResponse.js +17 -7
- package/dist/serialization/resources/features/types/CountAudienceUsersResponse.js +17 -7
- package/dist/serialization/resources/features/types/CountFeaturesParams.js +17 -7
- package/dist/serialization/resources/features/types/CountFeaturesResponse.js +17 -7
- package/dist/serialization/resources/features/types/CountFlagsParams.js +17 -7
- package/dist/serialization/resources/features/types/CountFlagsResponse.js +17 -7
- package/dist/serialization/resources/features/types/CreateFeatureRequestBodyFeatureType.js +17 -7
- package/dist/serialization/resources/features/types/CreateFeatureResponse.js +17 -7
- package/dist/serialization/resources/features/types/CreateFlagResponse.js +17 -7
- package/dist/serialization/resources/features/types/DeleteFeatureResponse.js +17 -7
- package/dist/serialization/resources/features/types/DeleteFlagResponse.js +17 -7
- package/dist/serialization/resources/features/types/GetFeatureResponse.js +17 -7
- package/dist/serialization/resources/features/types/GetFlagResponse.js +17 -7
- package/dist/serialization/resources/features/types/ListAudienceCompaniesResponse.js +17 -7
- package/dist/serialization/resources/features/types/ListAudienceUsersResponse.js +17 -7
- package/dist/serialization/resources/features/types/ListFeaturesParams.js +17 -7
- package/dist/serialization/resources/features/types/ListFeaturesResponse.js +17 -7
- package/dist/serialization/resources/features/types/ListFlagsParams.js +17 -7
- package/dist/serialization/resources/features/types/ListFlagsResponse.js +17 -7
- package/dist/serialization/resources/features/types/UpdateFeatureRequestBodyFeatureType.js +17 -7
- package/dist/serialization/resources/features/types/UpdateFeatureResponse.js +17 -7
- package/dist/serialization/resources/features/types/UpdateFlagResponse.js +17 -7
- package/dist/serialization/resources/features/types/UpdateFlagRulesResponse.js +17 -7
- package/dist/serialization/resources/index.d.ts +3 -0
- package/dist/serialization/resources/index.js +21 -8
- package/dist/serialization/resources/plangroups/client/requests/CreatePlanGroupRequestBody.d.ts +5 -1
- package/dist/serialization/resources/plangroups/client/requests/CreatePlanGroupRequestBody.js +22 -8
- package/dist/serialization/resources/plangroups/client/requests/UpdatePlanGroupRequestBody.d.ts +5 -1
- package/dist/serialization/resources/plangroups/client/requests/UpdatePlanGroupRequestBody.js +22 -8
- package/dist/serialization/resources/plangroups/types/CreatePlanGroupResponse.js +17 -7
- package/dist/serialization/resources/plangroups/types/GetPlanGroupResponse.js +17 -7
- package/dist/serialization/resources/plangroups/types/UpdatePlanGroupResponse.js +17 -7
- package/dist/serialization/resources/plans/client/requests/CreatePlanRequestBody.js +17 -7
- package/dist/serialization/resources/plans/client/requests/CreatePlanTraitRequestBody.d.ts +14 -0
- package/dist/serialization/resources/plans/client/requests/CreatePlanTraitRequestBody.js +45 -0
- package/dist/serialization/resources/plans/client/requests/UpdateAudienceRequestBody.js +17 -7
- package/dist/serialization/resources/plans/client/requests/UpdateCompanyPlansRequestBody.js +17 -7
- package/dist/serialization/resources/plans/client/requests/UpdatePlanRequestBody.js +17 -7
- package/dist/serialization/resources/plans/client/requests/UpdatePlanTraitRequestBody.d.ts +13 -0
- package/dist/serialization/resources/plans/client/requests/UpdatePlanTraitRequestBody.js +44 -0
- package/dist/serialization/resources/plans/client/requests/UpsertBillingProductRequestBody.d.ts +2 -0
- package/dist/serialization/resources/plans/client/requests/UpsertBillingProductRequestBody.js +19 -7
- package/dist/serialization/resources/plans/client/requests/index.d.ts +2 -0
- package/dist/serialization/resources/plans/client/requests/index.js +5 -1
- package/dist/serialization/resources/plans/types/CountPlanTraitsParams.d.ts +16 -0
- package/dist/serialization/resources/plans/types/CountPlanTraitsParams.js +47 -0
- package/dist/serialization/resources/plans/types/CountPlanTraitsResponse.d.ts +15 -0
- package/dist/serialization/resources/plans/types/CountPlanTraitsResponse.js +46 -0
- package/dist/serialization/resources/plans/types/CountPlansParams.js +17 -7
- package/dist/serialization/resources/plans/types/CountPlansRequestPlanType.js +17 -7
- package/dist/serialization/resources/plans/types/CountPlansResponse.js +17 -7
- package/dist/serialization/resources/plans/types/CountPlansResponseParamsPlanType.js +17 -7
- package/dist/serialization/resources/plans/types/CreatePlanRequestBodyPlanType.js +17 -7
- package/dist/serialization/resources/plans/types/CreatePlanResponse.js +17 -7
- package/dist/serialization/resources/plans/types/CreatePlanTraitResponse.d.ts +14 -0
- package/dist/serialization/resources/plans/types/CreatePlanTraitResponse.js +45 -0
- package/dist/serialization/resources/plans/types/DeleteAudienceResponse.js +17 -7
- package/dist/serialization/resources/plans/types/DeletePlanResponse.js +17 -7
- package/dist/serialization/resources/plans/types/DeletePlanTraitResponse.d.ts +14 -0
- package/dist/serialization/resources/plans/types/DeletePlanTraitResponse.js +45 -0
- package/dist/serialization/resources/plans/types/GetAudienceResponse.js +17 -7
- package/dist/serialization/resources/plans/types/GetPlanResponse.js +17 -7
- package/dist/serialization/resources/plans/types/GetPlanTraitResponse.d.ts +14 -0
- package/dist/serialization/resources/plans/types/GetPlanTraitResponse.js +45 -0
- package/dist/serialization/resources/plans/types/ListPlanTraitsParams.d.ts +16 -0
- package/dist/serialization/resources/plans/types/ListPlanTraitsParams.js +47 -0
- package/dist/serialization/resources/plans/types/ListPlanTraitsResponse.d.ts +15 -0
- package/dist/serialization/resources/plans/types/ListPlanTraitsResponse.js +46 -0
- package/dist/serialization/resources/plans/types/ListPlansParams.js +17 -7
- package/dist/serialization/resources/plans/types/ListPlansRequestPlanType.js +17 -7
- package/dist/serialization/resources/plans/types/ListPlansResponse.js +17 -7
- package/dist/serialization/resources/plans/types/ListPlansResponseParamsPlanType.js +17 -7
- package/dist/serialization/resources/plans/types/UpdateAudienceResponse.js +17 -7
- package/dist/serialization/resources/plans/types/UpdateCompanyPlansResponse.js +17 -7
- package/dist/serialization/resources/plans/types/UpdatePlanResponse.js +17 -7
- package/dist/serialization/resources/plans/types/UpdatePlanTraitResponse.d.ts +14 -0
- package/dist/serialization/resources/plans/types/UpdatePlanTraitResponse.js +45 -0
- package/dist/serialization/resources/plans/types/UpsertBillingProductPlanResponse.js +17 -7
- package/dist/serialization/resources/plans/types/index.d.ts +8 -0
- package/dist/serialization/resources/plans/types/index.js +8 -0
- package/dist/serialization/resources/webhooks/client/requests/CreateWebhookRequestBody.d.ts +2 -0
- package/dist/serialization/resources/webhooks/client/requests/CreateWebhookRequestBody.js +19 -7
- package/dist/serialization/resources/webhooks/client/requests/UpdateWebhookRequestBody.d.ts +2 -0
- package/dist/serialization/resources/webhooks/client/requests/UpdateWebhookRequestBody.js +19 -7
- package/dist/serialization/resources/webhooks/types/CountWebhookEventsParams.js +17 -7
- package/dist/serialization/resources/webhooks/types/CountWebhookEventsResponse.js +17 -7
- package/dist/serialization/resources/webhooks/types/CountWebhooksParams.js +17 -7
- package/dist/serialization/resources/webhooks/types/CountWebhooksResponse.js +17 -7
- package/dist/serialization/resources/webhooks/types/CreateWebhookRequestBodyRequestTypesItem.d.ts +1 -1
- package/dist/serialization/resources/webhooks/types/CreateWebhookRequestBodyRequestTypesItem.js +21 -7
- package/dist/serialization/resources/webhooks/types/CreateWebhookResponse.js +17 -7
- package/dist/serialization/resources/webhooks/types/DeleteWebhookResponse.js +17 -7
- package/dist/serialization/resources/webhooks/types/GetWebhookEventResponse.js +17 -7
- package/dist/serialization/resources/webhooks/types/GetWebhookResponse.js +17 -7
- package/dist/serialization/resources/webhooks/types/ListWebhookEventsParams.js +17 -7
- package/dist/serialization/resources/webhooks/types/ListWebhookEventsResponse.js +17 -7
- package/dist/serialization/resources/webhooks/types/ListWebhooksParams.js +17 -7
- package/dist/serialization/resources/webhooks/types/ListWebhooksResponse.js +17 -7
- package/dist/serialization/resources/webhooks/types/UpdateWebhookRequestBodyRequestTypesItem.d.ts +1 -1
- package/dist/serialization/resources/webhooks/types/UpdateWebhookRequestBodyRequestTypesItem.js +21 -7
- package/dist/serialization/resources/webhooks/types/UpdateWebhookRequestBodyStatus.js +17 -7
- package/dist/serialization/resources/webhooks/types/UpdateWebhookResponse.js +17 -7
- package/dist/serialization/types/ApiError.js +17 -7
- package/dist/serialization/types/ApiKeyCreateResponseData.js +17 -7
- package/dist/serialization/types/ApiKeyRequestListResponseData.js +17 -7
- package/dist/serialization/types/ApiKeyRequestResponseData.js +17 -7
- package/dist/serialization/types/ApiKeyResponseData.js +17 -7
- package/dist/serialization/types/AudienceRequestBody.js +17 -7
- package/dist/serialization/types/BillingCouponResponseData.js +17 -7
- package/dist/serialization/types/BillingCustomerResponseData.js +17 -7
- package/dist/serialization/types/BillingCustomerSubscription.js +17 -7
- package/dist/serialization/types/BillingCustomerWithSubscriptionsResponseData.js +17 -7
- package/dist/serialization/types/BillingMeterResponseData.js +17 -7
- package/dist/serialization/types/BillingPriceResponseData.d.ts +2 -0
- package/dist/serialization/types/BillingPriceResponseData.js +19 -7
- package/dist/serialization/types/BillingPriceView.d.ts +7 -0
- package/dist/serialization/types/BillingPriceView.js +24 -7
- package/dist/serialization/types/BillingProductDetailResponseData.d.ts +3 -0
- package/dist/serialization/types/BillingProductDetailResponseData.js +20 -7
- package/dist/serialization/types/BillingProductForSubscriptionResponseData.d.ts +5 -0
- package/dist/serialization/types/BillingProductForSubscriptionResponseData.js +22 -7
- package/dist/serialization/types/BillingProductPlanResponseData.d.ts +2 -0
- package/dist/serialization/types/BillingProductPlanResponseData.js +19 -7
- package/dist/serialization/types/BillingProductPriceResponseData.d.ts +3 -0
- package/dist/serialization/types/BillingProductPriceResponseData.js +20 -7
- package/dist/serialization/types/BillingProductPriceTierResponseData.d.ts +15 -0
- package/dist/serialization/types/BillingProductPriceTierResponseData.js +46 -0
- package/dist/serialization/types/BillingProductPricing.d.ts +4 -1
- package/dist/serialization/types/BillingProductPricing.js +21 -8
- package/dist/serialization/types/BillingProductPricingUsageType.d.ts +10 -0
- package/dist/serialization/types/BillingProductPricingUsageType.js +41 -0
- package/dist/serialization/types/BillingProductResponseData.d.ts +2 -0
- package/dist/serialization/types/BillingProductResponseData.js +19 -7
- package/dist/serialization/types/BillingSubscriptionDiscount.js +17 -7
- package/dist/serialization/types/BillingSubscriptionDiscountView.js +17 -7
- package/dist/serialization/types/BillingSubscriptionResponseData.d.ts +3 -0
- package/dist/serialization/types/BillingSubscriptionResponseData.js +20 -7
- package/dist/serialization/types/BillingSubscriptionView.d.ts +3 -0
- package/dist/serialization/types/BillingSubscriptionView.js +20 -7
- package/dist/serialization/types/ChangeSubscriptionInternalRequestBody.d.ts +1 -0
- package/dist/serialization/types/ChangeSubscriptionInternalRequestBody.js +18 -7
- package/dist/serialization/types/ChangeSubscriptionRequestBody.d.ts +1 -0
- package/dist/serialization/types/ChangeSubscriptionRequestBody.js +18 -7
- package/dist/serialization/types/CheckFlagRequestBody.js +17 -7
- package/dist/serialization/types/CheckFlagResponseData.d.ts +1 -0
- package/dist/serialization/types/CheckFlagResponseData.js +18 -7
- package/dist/serialization/types/CheckFlagsResponseData.js +17 -7
- package/dist/serialization/types/CheckoutDataResponseData.d.ts +2 -0
- package/dist/serialization/types/CheckoutDataResponseData.js +19 -7
- package/dist/serialization/types/CompanyCrmDealsResponseData.js +17 -7
- package/dist/serialization/types/CompanyDetailResponseData.d.ts +3 -0
- package/dist/serialization/types/CompanyDetailResponseData.js +20 -7
- package/dist/serialization/types/CompanyEventPeriodMetricsResponseData.js +17 -7
- package/dist/serialization/types/CompanyMembershipDetailResponseData.js +17 -7
- package/dist/serialization/types/CompanyMembershipResponseData.js +17 -7
- package/dist/serialization/types/CompanyOverrideResponseData.js +17 -7
- package/dist/serialization/types/CompanyPlanDetailResponseData.d.ts +6 -0
- package/dist/serialization/types/CompanyPlanDetailResponseData.js +23 -7
- package/dist/serialization/types/CompanyPlanWithBillingSubView.d.ts +2 -0
- package/dist/serialization/types/CompanyPlanWithBillingSubView.js +19 -7
- package/dist/serialization/types/CompanyResponseData.js +17 -7
- package/dist/serialization/types/CompanySubscriptionResponseData.d.ts +2 -0
- package/dist/serialization/types/CompanySubscriptionResponseData.js +19 -7
- package/dist/serialization/types/ComponentCapabilities.d.ts +1 -0
- package/dist/serialization/types/ComponentCapabilities.js +18 -7
- package/dist/serialization/types/ComponentHydrateResponseData.js +17 -7
- package/dist/serialization/types/ComponentPreviewResponseData.js +17 -7
- package/dist/serialization/types/ComponentResponseData.js +17 -7
- package/dist/serialization/types/CountResponse.js +17 -7
- package/dist/serialization/types/CouponRequestBody.js +17 -7
- package/dist/serialization/types/CreateBillingPriceTierRequestBody.d.ts +16 -0
- package/dist/serialization/types/CreateBillingPriceTierRequestBody.js +47 -0
- package/dist/serialization/types/CreateEntitlementReqCommon.js +17 -7
- package/dist/serialization/types/CreateEntitlementReqCommonMetricPeriod.js +17 -7
- package/dist/serialization/types/CreateEntitlementReqCommonMetricPeriodMonthReset.js +17 -7
- package/dist/serialization/types/CreateEntitlementReqCommonValueType.js +17 -7
- package/dist/serialization/types/CreateEventRequestBody.js +17 -7
- package/dist/serialization/types/CreateEventRequestBodyEventType.js +17 -7
- package/dist/serialization/types/CreateFlagRequestBody.js +17 -7
- package/dist/serialization/types/CreateOrUpdateConditionGroupRequestBody.js +17 -7
- package/dist/serialization/types/CreateOrUpdateConditionRequestBody.js +17 -7
- package/dist/serialization/types/CreateOrUpdateConditionRequestBodyConditionType.js +17 -7
- package/dist/serialization/types/CreateOrUpdateConditionRequestBodyMetricPeriod.js +17 -7
- package/dist/serialization/types/CreateOrUpdateConditionRequestBodyMetricPeriodMonthReset.js +17 -7
- package/dist/serialization/types/CreateOrUpdateConditionRequestBodyOperator.js +17 -7
- package/dist/serialization/types/CreateOrUpdateFlagRequestBody.js +17 -7
- package/dist/serialization/types/CreateOrUpdateRuleRequestBody.js +17 -7
- package/dist/serialization/types/CreateOrUpdateRuleRequestBodyRuleType.js +17 -7
- package/dist/serialization/types/CrmDealLineItem.js +17 -7
- package/dist/serialization/types/CrmDealResponseData.js +17 -7
- package/dist/serialization/types/CrmLineItemResponseData.js +17 -7
- package/dist/serialization/types/CrmProductResponseData.js +17 -7
- package/dist/serialization/types/CustomPlanConfig.d.ts +14 -0
- package/dist/serialization/types/CustomPlanConfig.js +45 -0
- package/dist/serialization/types/CustomPlanViewConfigResponseData.d.ts +14 -0
- package/dist/serialization/types/CustomPlanViewConfigResponseData.js +45 -0
- package/dist/serialization/types/DataExportResponseData.d.ts +20 -0
- package/dist/serialization/types/DataExportResponseData.js +51 -0
- package/dist/serialization/types/Decimal.js +17 -7
- package/dist/serialization/types/DeleteResponse.js +17 -7
- package/dist/serialization/types/EntitlementTriggerConfig.d.ts +12 -0
- package/dist/serialization/types/EntitlementTriggerConfig.js +43 -0
- package/dist/serialization/types/EntitlementsInPlan.d.ts +13 -0
- package/dist/serialization/types/EntitlementsInPlan.js +44 -0
- package/dist/serialization/types/EntityKeyDefinitionResponseData.js +17 -7
- package/dist/serialization/types/EntityKeyDetailResponseData.js +17 -7
- package/dist/serialization/types/EntityKeyResponseData.js +17 -7
- package/dist/serialization/types/EntityTraitDefinitionResponseData.js +17 -7
- package/dist/serialization/types/EntityTraitDetailResponseData.js +17 -7
- package/dist/serialization/types/EntityTraitResponseData.js +17 -7
- package/dist/serialization/types/EntityTraitValue.js +17 -7
- package/dist/serialization/types/EnvironmentDetailResponseData.js +17 -7
- package/dist/serialization/types/EnvironmentResponseData.js +17 -7
- package/dist/serialization/types/EventBody.js +17 -7
- package/dist/serialization/types/EventBodyFlagCheck.js +17 -7
- package/dist/serialization/types/EventBodyIdentify.js +17 -7
- package/dist/serialization/types/EventBodyIdentifyCompany.js +17 -7
- package/dist/serialization/types/EventBodyTrack.js +17 -7
- package/dist/serialization/types/EventDetailResponseData.js +17 -7
- package/dist/serialization/types/EventResponseData.js +17 -7
- package/dist/serialization/types/EventSummaryResponseData.d.ts +2 -2
- package/dist/serialization/types/EventSummaryResponseData.js +19 -9
- package/dist/serialization/types/FeatureCompanyResponseData.js +17 -7
- package/dist/serialization/types/FeatureCompanyResponseDataAllocationType.js +17 -7
- package/dist/serialization/types/FeatureCompanyUserResponseData.js +17 -7
- package/dist/serialization/types/FeatureCompanyUserResponseDataAllocationType.js +17 -7
- package/dist/serialization/types/FeatureDetailResponseData.d.ts +2 -0
- package/dist/serialization/types/FeatureDetailResponseData.js +19 -7
- package/dist/serialization/types/FeatureResponseData.d.ts +2 -0
- package/dist/serialization/types/FeatureResponseData.js +19 -7
- package/dist/serialization/types/FeatureUsageDetailResponseData.js +17 -7
- package/dist/serialization/types/FeatureUsageResponseData.d.ts +1 -0
- package/dist/serialization/types/FeatureUsageResponseData.js +18 -7
- package/dist/serialization/types/FeatureUsageResponseDataAllocationType.js +17 -7
- package/dist/serialization/types/FlagDetailResponseData.js +17 -7
- package/dist/serialization/types/FlagResponseData.js +17 -7
- package/dist/serialization/types/GenericPreviewObject.js +17 -7
- package/dist/serialization/types/InvoiceRequestBody.js +17 -7
- package/dist/serialization/types/InvoiceResponseData.js +17 -7
- package/dist/serialization/types/IssueTemporaryAccessTokenResponseData.js +17 -7
- package/dist/serialization/types/KeysRequestBody.js +17 -7
- package/dist/serialization/types/MeterRequestBody.js +17 -7
- package/dist/serialization/types/OrderedPlansInGroup.d.ts +14 -0
- package/dist/serialization/types/OrderedPlansInGroup.js +45 -0
- package/dist/serialization/types/PaginationFilter.js +17 -7
- package/dist/serialization/types/PaymentMethodRequestBody.d.ts +0 -1
- package/dist/serialization/types/PaymentMethodRequestBody.js +17 -8
- package/dist/serialization/types/PaymentMethodResponseData.d.ts +0 -1
- package/dist/serialization/types/PaymentMethodResponseData.js +17 -8
- package/dist/serialization/types/PlanAudienceDetailResponseData.js +17 -7
- package/dist/serialization/types/PlanAudienceResponseData.js +17 -7
- package/dist/serialization/types/PlanDetailResponseData.d.ts +2 -0
- package/dist/serialization/types/PlanDetailResponseData.js +19 -7
- package/dist/serialization/types/PlanEntitlementResponseData.d.ts +3 -0
- package/dist/serialization/types/PlanEntitlementResponseData.js +20 -7
- package/dist/serialization/types/PlanEntitlementsOrder.d.ts +13 -0
- package/dist/serialization/types/PlanEntitlementsOrder.js +44 -0
- package/dist/serialization/types/PlanGroupDetailResponseData.d.ts +5 -0
- package/dist/serialization/types/PlanGroupDetailResponseData.js +22 -7
- package/dist/serialization/types/PlanGroupPlanDetailResponseData.d.ts +5 -0
- package/dist/serialization/types/PlanGroupPlanDetailResponseData.js +22 -7
- package/dist/serialization/types/PlanGroupPlanEntitlementsOrder.d.ts +14 -0
- package/dist/serialization/types/PlanGroupPlanEntitlementsOrder.js +45 -0
- package/dist/serialization/types/PlanGroupResponseData.d.ts +2 -1
- package/dist/serialization/types/PlanGroupResponseData.js +19 -8
- package/dist/serialization/types/PlanResponseData.js +17 -7
- package/dist/serialization/types/PlanTraitResponseData.d.ts +19 -0
- package/dist/serialization/types/PlanTraitResponseData.js +50 -0
- package/dist/serialization/types/PreviewObject.js +17 -7
- package/dist/serialization/types/PreviewObjectResponseData.js +17 -7
- package/dist/serialization/types/PreviewSubscriptionChangeResponseData.d.ts +4 -0
- package/dist/serialization/types/PreviewSubscriptionChangeResponseData.js +21 -7
- package/dist/serialization/types/PreviewSubscriptionFinanceResponseData.d.ts +21 -0
- package/dist/serialization/types/PreviewSubscriptionFinanceResponseData.js +52 -0
- package/dist/serialization/types/PreviewSubscriptionUpcomingInvoiceLineItems.d.ts +16 -0
- package/dist/serialization/types/PreviewSubscriptionUpcomingInvoiceLineItems.js +47 -0
- package/dist/serialization/types/QuickstartResp.d.ts +12 -0
- package/dist/serialization/types/QuickstartResp.js +43 -0
- package/dist/serialization/types/RawEventBatchResponseData.js +17 -7
- package/dist/serialization/types/RawEventResponseData.js +17 -7
- package/dist/serialization/types/RuleConditionDetailResponseData.js +17 -7
- package/dist/serialization/types/RuleConditionGroupDetailResponseData.js +17 -7
- package/dist/serialization/types/RuleConditionGroupResponseData.js +17 -7
- package/dist/serialization/types/RuleConditionResponseData.js +17 -7
- package/dist/serialization/types/RuleDetailResponseData.js +17 -7
- package/dist/serialization/types/RuleResponseData.js +17 -7
- package/dist/serialization/types/RulesDetailResponseData.js +17 -7
- package/dist/serialization/types/SegmentStatusResp.js +17 -7
- package/dist/serialization/types/StripeEmbedInfo.js +17 -7
- package/dist/serialization/types/TemporaryAccessTokenResponseData.js +17 -7
- package/dist/serialization/types/UpdateAddOnRequestBody.js +17 -7
- package/dist/serialization/types/UpdateEntitlementReqCommon.js +17 -7
- package/dist/serialization/types/UpdateEntitlementReqCommonMetricPeriod.js +17 -7
- package/dist/serialization/types/UpdateEntitlementReqCommonMetricPeriodMonthReset.js +17 -7
- package/dist/serialization/types/UpdateEntitlementReqCommonValueType.js +17 -7
- package/dist/serialization/types/UpdatePayInAdvanceRequestBody.js +17 -7
- package/dist/serialization/types/UpdateRuleRequestBody.js +17 -7
- package/dist/serialization/types/UpsertCompanyRequestBody.js +17 -7
- package/dist/serialization/types/UpsertTraitRequestBody.js +17 -7
- package/dist/serialization/types/UpsertUserRequestBody.d.ts +2 -0
- package/dist/serialization/types/UpsertUserRequestBody.js +19 -7
- package/dist/serialization/types/UpsertUserSubRequestBody.d.ts +1 -0
- package/dist/serialization/types/UpsertUserSubRequestBody.js +18 -7
- package/dist/serialization/types/UsageBasedEntitlementRequestBody.d.ts +7 -0
- package/dist/serialization/types/UsageBasedEntitlementRequestBody.js +24 -7
- package/dist/serialization/types/UsageBasedEntitlementResponseData.js +17 -7
- package/dist/serialization/types/UserDetailResponseData.js +17 -7
- package/dist/serialization/types/UserResponseData.js +17 -7
- package/dist/serialization/types/WebhookEventDetailResponseData.js +17 -7
- package/dist/serialization/types/WebhookEventResponseData.js +17 -7
- package/dist/serialization/types/WebhookResponseData.d.ts +3 -0
- package/dist/serialization/types/WebhookResponseData.js +20 -7
- package/dist/serialization/types/index.d.ts +15 -0
- package/dist/serialization/types/index.js +15 -0
- package/dist/webhooks.d.ts +76 -0
- package/dist/webhooks.js +170 -0
- package/environments.d.ts +1 -1
- package/errors/SchematicError.d.ts +4 -1
- package/errors/SchematicError.js +6 -8
- package/errors/SchematicTimeoutError.d.ts +1 -1
- package/errors/SchematicTimeoutError.js +2 -2
- package/events.d.ts +4 -0
- package/events.js +41 -5
- package/events.test.js +51 -4
- package/index.d.ts +1 -0
- package/index.js +26 -8
- package/{jest.config.js → jest.config.mjs} +4 -1
- package/package.json +18 -16
- package/reference.md +532 -21
- package/scripts/rename-to-esm-files.js +115 -0
- package/scripts/webhook-test-server/README.md +24 -0
- package/scripts/webhook-test-server/package-lock.json +196 -0
- package/scripts/webhook-test-server/package.json +13 -0
- package/scripts/webhook-test-server/webhook-test-server.ts +100 -0
- package/serialization/resources/accesstokens/client/requests/IssueTemporaryAccessTokenRequestBody.js +17 -7
- package/serialization/resources/accesstokens/types/IssueTemporaryAccessTokenResponse.js +17 -7
- package/serialization/resources/accounts/client/requests/CreateApiKeyRequestBody.js +17 -7
- package/serialization/resources/accounts/client/requests/CreateEnvironmentRequestBody.js +17 -7
- package/serialization/resources/accounts/client/requests/UpdateApiKeyRequestBody.js +17 -7
- package/serialization/resources/accounts/client/requests/UpdateEnvironmentRequestBody.js +17 -7
- package/serialization/resources/accounts/types/CountApiKeysParams.js +17 -7
- package/serialization/resources/accounts/types/CountApiKeysResponse.js +17 -7
- package/serialization/resources/accounts/types/CountApiRequestsParams.js +17 -7
- package/serialization/resources/accounts/types/CountApiRequestsResponse.js +17 -7
- package/serialization/resources/accounts/types/CreateApiKeyResponse.js +17 -7
- package/serialization/resources/accounts/types/CreateEnvironmentRequestBodyEnvironmentType.js +17 -7
- package/serialization/resources/accounts/types/CreateEnvironmentResponse.js +17 -7
- package/serialization/resources/accounts/types/DeleteApiKeyResponse.js +17 -7
- package/serialization/resources/accounts/types/DeleteEnvironmentResponse.js +17 -7
- package/serialization/resources/accounts/types/GetApiKeyResponse.js +17 -7
- package/serialization/resources/accounts/types/GetApiRequestResponse.js +17 -7
- package/serialization/resources/accounts/types/GetEnvironmentResponse.js +17 -7
- package/serialization/resources/accounts/types/ListApiKeysParams.js +17 -7
- package/serialization/resources/accounts/types/ListApiKeysResponse.js +17 -7
- package/serialization/resources/accounts/types/ListApiRequestsParams.js +17 -7
- package/serialization/resources/accounts/types/ListApiRequestsResponse.js +17 -7
- package/serialization/resources/accounts/types/ListEnvironmentsParams.js +17 -7
- package/serialization/resources/accounts/types/ListEnvironmentsResponse.js +17 -7
- package/serialization/resources/accounts/types/QuickstartResponse.d.ts +14 -0
- package/serialization/resources/accounts/types/QuickstartResponse.js +45 -0
- package/serialization/resources/accounts/types/UpdateApiKeyResponse.js +17 -7
- package/serialization/resources/accounts/types/UpdateEnvironmentRequestBodyEnvironmentType.js +17 -7
- package/serialization/resources/accounts/types/UpdateEnvironmentResponse.js +17 -7
- package/serialization/resources/accounts/types/index.d.ts +1 -0
- package/serialization/resources/accounts/types/index.js +1 -0
- package/serialization/resources/billing/client/requests/CreateBillingCustomerRequestBody.d.ts +1 -0
- package/serialization/resources/billing/client/requests/CreateBillingCustomerRequestBody.js +18 -7
- package/serialization/resources/billing/client/requests/CreateBillingPriceRequestBody.d.ts +11 -1
- package/serialization/resources/billing/client/requests/CreateBillingPriceRequestBody.js +28 -8
- package/serialization/resources/billing/client/requests/CreateBillingProductRequestBody.d.ts +1 -2
- package/serialization/resources/billing/client/requests/CreateBillingProductRequestBody.js +18 -9
- package/serialization/resources/billing/client/requests/CreateBillingSubscriptionsRequestBody.d.ts +5 -1
- package/serialization/resources/billing/client/requests/CreateBillingSubscriptionsRequestBody.js +22 -8
- package/serialization/resources/billing/client/requests/CreateCouponRequestBody.js +17 -7
- package/serialization/resources/billing/client/requests/CreateInvoiceRequestBody.js +17 -7
- package/serialization/resources/billing/client/requests/CreateMeterRequestBody.js +17 -7
- package/serialization/resources/billing/client/requests/CreatePaymentMethodRequestBody.d.ts +0 -1
- package/serialization/resources/billing/client/requests/CreatePaymentMethodRequestBody.js +17 -8
- package/serialization/resources/billing/types/CountBillingProductsParams.d.ts +4 -1
- package/serialization/resources/billing/types/CountBillingProductsParams.js +21 -8
- package/serialization/resources/billing/types/CountBillingProductsRequestPriceUsageType.d.ts +10 -0
- package/serialization/resources/billing/types/CountBillingProductsRequestPriceUsageType.js +41 -0
- package/serialization/resources/billing/types/CountBillingProductsResponse.js +17 -7
- package/serialization/resources/billing/types/CountBillingProductsResponseParamsPriceUsageType.d.ts +10 -0
- package/serialization/resources/billing/types/CountBillingProductsResponseParamsPriceUsageType.js +41 -0
- package/serialization/resources/billing/types/CountCustomersParams.d.ts +1 -0
- package/serialization/resources/billing/types/CountCustomersParams.js +18 -7
- package/serialization/resources/billing/types/CountCustomersResponse.js +17 -7
- package/serialization/resources/billing/types/CreateBillingPriceRequestBodyBillingScheme.d.ts +10 -0
- package/serialization/resources/billing/types/CreateBillingPriceRequestBodyBillingScheme.js +41 -0
- package/serialization/resources/billing/types/CreateBillingPriceRequestBodyTierMode.d.ts +10 -0
- package/serialization/resources/billing/types/CreateBillingPriceRequestBodyTierMode.js +41 -0
- package/serialization/resources/billing/types/CreateBillingPriceRequestBodyUsageType.d.ts +10 -0
- package/serialization/resources/billing/types/CreateBillingPriceRequestBodyUsageType.js +41 -0
- package/serialization/resources/billing/types/CreateBillingSubscriptionsRequestBodyTrialEndSetting.d.ts +10 -0
- package/serialization/resources/billing/types/CreateBillingSubscriptionsRequestBodyTrialEndSetting.js +41 -0
- package/serialization/resources/billing/types/DeleteBillingProductResponse.d.ts +14 -0
- package/serialization/resources/billing/types/DeleteBillingProductResponse.js +45 -0
- package/serialization/resources/billing/types/DeleteProductPriceResponse.js +17 -7
- package/serialization/resources/billing/types/ListBillingProductsParams.d.ts +4 -1
- package/serialization/resources/billing/types/ListBillingProductsParams.js +21 -8
- package/serialization/resources/billing/types/ListBillingProductsRequestPriceUsageType.d.ts +10 -0
- package/serialization/resources/billing/types/ListBillingProductsRequestPriceUsageType.js +41 -0
- package/serialization/resources/billing/types/ListBillingProductsResponse.js +17 -7
- package/serialization/resources/billing/types/ListBillingProductsResponseParamsPriceUsageType.d.ts +10 -0
- package/serialization/resources/billing/types/ListBillingProductsResponseParamsPriceUsageType.js +41 -0
- package/serialization/resources/billing/types/ListCouponsParams.d.ts +15 -0
- package/serialization/resources/billing/types/ListCouponsParams.js +46 -0
- package/serialization/resources/billing/types/ListCouponsResponse.d.ts +15 -0
- package/serialization/resources/billing/types/ListCouponsResponse.js +46 -0
- package/serialization/resources/billing/types/{ListCustomersParams.d.ts → ListCustomersWithSubscriptionsParams.d.ts} +3 -2
- package/serialization/resources/billing/types/{ListCustomersParams.js → ListCustomersWithSubscriptionsParams.js} +20 -9
- package/{dist/serialization/resources/billing/types/ListCustomersResponse.d.ts → serialization/resources/billing/types/ListCustomersWithSubscriptionsResponse.d.ts} +4 -4
- package/serialization/resources/billing/types/{ListCustomersResponse.js → ListCustomersWithSubscriptionsResponse.js} +21 -11
- package/serialization/resources/billing/types/ListInvoicesParams.js +17 -7
- package/serialization/resources/billing/types/ListInvoicesResponse.js +17 -7
- package/serialization/resources/billing/types/ListMetersParams.js +17 -7
- package/serialization/resources/billing/types/ListMetersResponse.js +17 -7
- package/serialization/resources/billing/types/ListPaymentMethodsParams.d.ts +0 -1
- package/serialization/resources/billing/types/ListPaymentMethodsParams.js +17 -8
- package/serialization/resources/billing/types/ListPaymentMethodsResponse.js +17 -7
- package/serialization/resources/billing/types/ListProductPricesParams.d.ts +4 -1
- package/serialization/resources/billing/types/ListProductPricesParams.js +21 -8
- package/serialization/resources/billing/types/ListProductPricesRequestPriceUsageType.d.ts +10 -0
- package/serialization/resources/billing/types/ListProductPricesRequestPriceUsageType.js +41 -0
- package/serialization/resources/billing/types/ListProductPricesResponse.js +17 -7
- package/serialization/resources/billing/types/ListProductPricesResponseParamsPriceUsageType.d.ts +10 -0
- package/serialization/resources/billing/types/ListProductPricesResponseParamsPriceUsageType.js +41 -0
- package/serialization/resources/billing/types/SearchBillingPricesParams.d.ts +3 -1
- package/serialization/resources/billing/types/SearchBillingPricesParams.js +20 -8
- package/serialization/resources/billing/types/SearchBillingPricesRequestUsageType.d.ts +10 -0
- package/serialization/resources/billing/types/SearchBillingPricesRequestUsageType.js +41 -0
- package/serialization/resources/billing/types/SearchBillingPricesResponse.js +17 -7
- package/serialization/resources/billing/types/SearchBillingPricesResponseParamsUsageType.d.ts +10 -0
- package/serialization/resources/billing/types/SearchBillingPricesResponseParamsUsageType.js +41 -0
- package/serialization/resources/billing/types/UpsertBillingCouponResponse.js +17 -7
- package/serialization/resources/billing/types/UpsertBillingCustomerResponse.js +17 -7
- package/serialization/resources/billing/types/UpsertBillingMeterResponse.js +17 -7
- package/serialization/resources/billing/types/UpsertBillingPriceResponse.js +17 -7
- package/serialization/resources/billing/types/UpsertBillingProductResponse.js +17 -7
- package/serialization/resources/billing/types/UpsertBillingSubscriptionResponse.js +17 -7
- package/serialization/resources/billing/types/UpsertInvoiceResponse.js +17 -7
- package/serialization/resources/billing/types/UpsertPaymentMethodResponse.js +17 -7
- package/serialization/resources/billing/types/index.d.ts +17 -2
- package/serialization/resources/billing/types/index.js +17 -2
- package/serialization/resources/checkout/client/requests/CheckoutDataRequestBody.d.ts +13 -0
- package/serialization/resources/checkout/client/requests/CheckoutDataRequestBody.js +44 -0
- package/serialization/resources/checkout/client/requests/UpdateTrialEndRequestBody.js +17 -7
- package/serialization/resources/checkout/client/requests/index.d.ts +1 -0
- package/serialization/resources/checkout/client/requests/index.js +3 -1
- package/serialization/resources/checkout/types/CheckoutInternalResponse.js +17 -7
- package/serialization/resources/checkout/types/GetCheckoutDataResponse.js +17 -7
- package/serialization/resources/checkout/types/PreviewCheckoutInternalResponse.js +17 -7
- package/serialization/resources/checkout/types/UpdateCustomerSubscriptionTrialEndResponse.js +17 -7
- package/serialization/resources/companies/client/requests/CreateEntityTraitDefinitionRequestBody.js +17 -7
- package/serialization/resources/companies/client/requests/GetOrCreateCompanyMembershipRequestBody.js +17 -7
- package/serialization/resources/companies/client/requests/UpdateEntityTraitDefinitionRequestBody.js +17 -7
- package/serialization/resources/companies/types/CountCompaniesParams.d.ts +1 -0
- package/serialization/resources/companies/types/CountCompaniesParams.js +18 -7
- package/serialization/resources/companies/types/CountCompaniesResponse.js +17 -7
- package/serialization/resources/companies/types/CountEntityKeyDefinitionsParams.js +17 -7
- package/serialization/resources/companies/types/CountEntityKeyDefinitionsRequestEntityType.js +17 -7
- package/serialization/resources/companies/types/CountEntityKeyDefinitionsResponse.js +17 -7
- package/serialization/resources/companies/types/CountEntityKeyDefinitionsResponseParamsEntityType.js +17 -7
- package/serialization/resources/companies/types/CountEntityTraitDefinitionsParams.js +17 -7
- package/serialization/resources/companies/types/CountEntityTraitDefinitionsRequestEntityType.js +17 -7
- package/serialization/resources/companies/types/CountEntityTraitDefinitionsRequestTraitType.js +17 -7
- package/serialization/resources/companies/types/CountEntityTraitDefinitionsResponse.js +17 -7
- package/serialization/resources/companies/types/CountEntityTraitDefinitionsResponseParamsEntityType.js +17 -7
- package/serialization/resources/companies/types/CountEntityTraitDefinitionsResponseParamsTraitType.js +17 -7
- package/serialization/resources/companies/types/CountUsersParams.js +17 -7
- package/serialization/resources/companies/types/CountUsersResponse.js +17 -7
- package/serialization/resources/companies/types/CreateCompanyResponse.js +17 -7
- package/serialization/resources/companies/types/CreateEntityTraitDefinitionRequestBodyEntityType.js +17 -7
- package/serialization/resources/companies/types/CreateEntityTraitDefinitionRequestBodyTraitType.js +17 -7
- package/serialization/resources/companies/types/CreateUserResponse.js +17 -7
- package/serialization/resources/companies/types/DeleteCompanyByKeysResponse.js +17 -7
- package/serialization/resources/companies/types/DeleteCompanyMembershipResponse.js +17 -7
- package/serialization/resources/companies/types/DeleteCompanyResponse.js +17 -7
- package/serialization/resources/companies/types/DeleteUserByKeysResponse.js +17 -7
- package/serialization/resources/companies/types/DeleteUserResponse.js +17 -7
- package/serialization/resources/companies/types/GetActiveCompanySubscriptionParams.js +17 -7
- package/serialization/resources/companies/types/GetActiveCompanySubscriptionResponse.js +17 -7
- package/serialization/resources/companies/types/GetActiveDealsParams.js +17 -7
- package/serialization/resources/companies/types/GetActiveDealsResponse.js +17 -7
- package/serialization/resources/companies/types/GetCompanyResponse.js +17 -7
- package/serialization/resources/companies/types/GetEntityTraitDefinitionResponse.js +17 -7
- package/serialization/resources/companies/types/GetEntityTraitValuesParams.js +17 -7
- package/serialization/resources/companies/types/GetEntityTraitValuesResponse.js +17 -7
- package/serialization/resources/companies/types/GetOrCreateCompanyMembershipResponse.js +17 -7
- package/serialization/resources/companies/types/GetOrCreateEntityTraitDefinitionResponse.js +17 -7
- package/serialization/resources/companies/types/GetUserResponse.js +17 -7
- package/serialization/resources/companies/types/ListCompaniesParams.d.ts +1 -0
- package/serialization/resources/companies/types/ListCompaniesParams.js +18 -7
- package/serialization/resources/companies/types/ListCompaniesResponse.js +17 -7
- package/serialization/resources/companies/types/ListCompanyMembershipsParams.js +17 -7
- package/serialization/resources/companies/types/ListCompanyMembershipsResponse.js +17 -7
- package/serialization/resources/companies/types/ListEntityKeyDefinitionsParams.js +17 -7
- package/serialization/resources/companies/types/ListEntityKeyDefinitionsRequestEntityType.js +17 -7
- package/serialization/resources/companies/types/ListEntityKeyDefinitionsResponse.js +17 -7
- package/serialization/resources/companies/types/ListEntityKeyDefinitionsResponseParamsEntityType.js +17 -7
- package/serialization/resources/companies/types/ListEntityTraitDefinitionsParams.js +17 -7
- package/serialization/resources/companies/types/ListEntityTraitDefinitionsRequestEntityType.js +17 -7
- package/serialization/resources/companies/types/ListEntityTraitDefinitionsRequestTraitType.js +17 -7
- package/serialization/resources/companies/types/ListEntityTraitDefinitionsResponse.js +17 -7
- package/serialization/resources/companies/types/ListEntityTraitDefinitionsResponseParamsEntityType.js +17 -7
- package/serialization/resources/companies/types/ListEntityTraitDefinitionsResponseParamsTraitType.js +17 -7
- package/serialization/resources/companies/types/ListUsersParams.js +17 -7
- package/serialization/resources/companies/types/ListUsersResponse.js +17 -7
- package/serialization/resources/companies/types/LookupCompanyParams.d.ts +1 -1
- package/serialization/resources/companies/types/LookupCompanyParams.js +18 -8
- package/serialization/resources/companies/types/LookupCompanyResponse.js +17 -7
- package/serialization/resources/companies/types/LookupUserParams.d.ts +1 -1
- package/serialization/resources/companies/types/LookupUserParams.js +18 -8
- package/serialization/resources/companies/types/LookupUserResponse.js +17 -7
- package/serialization/resources/companies/types/UpdateEntityTraitDefinitionRequestBodyTraitType.js +17 -7
- package/serialization/resources/companies/types/UpdateEntityTraitDefinitionResponse.js +17 -7
- package/serialization/resources/companies/types/UpsertCompanyResponse.js +17 -7
- package/serialization/resources/companies/types/UpsertCompanyTraitResponse.js +17 -7
- package/serialization/resources/companies/types/UpsertUserResponse.js +17 -7
- package/serialization/resources/companies/types/UpsertUserTraitResponse.js +17 -7
- package/serialization/resources/components/client/requests/CreateComponentRequestBody.js +17 -7
- package/serialization/resources/components/client/requests/UpdateComponentRequestBody.js +17 -7
- package/serialization/resources/components/types/CountComponentsParams.js +17 -7
- package/serialization/resources/components/types/CountComponentsResponse.js +17 -7
- package/serialization/resources/components/types/CreateComponentRequestBodyEntityType.js +17 -7
- package/serialization/resources/components/types/CreateComponentResponse.js +17 -7
- package/serialization/resources/components/types/DeleteComponentResponse.js +17 -7
- package/serialization/resources/components/types/GetComponentResponse.js +17 -7
- package/serialization/resources/components/types/ListComponentsParams.js +17 -7
- package/serialization/resources/components/types/ListComponentsResponse.js +17 -7
- package/serialization/resources/components/types/PreviewComponentDataParams.js +17 -7
- package/serialization/resources/components/types/PreviewComponentDataResponse.js +17 -7
- package/serialization/resources/components/types/UpdateComponentRequestBodyEntityType.js +17 -7
- package/serialization/resources/components/types/UpdateComponentRequestBodyState.js +17 -7
- package/serialization/resources/components/types/UpdateComponentResponse.js +17 -7
- package/serialization/resources/crm/client/requests/CreateCrmDealLineItemAssociationRequestBody.js +17 -7
- package/serialization/resources/crm/client/requests/CreateCrmDealRequestBody.js +17 -7
- package/serialization/resources/crm/client/requests/CreateCrmLineItemRequestBody.js +17 -7
- package/serialization/resources/crm/client/requests/CreateCrmProductRequestBody.js +17 -7
- package/serialization/resources/crm/types/ListCrmProductsParams.js +17 -7
- package/serialization/resources/crm/types/ListCrmProductsResponse.js +17 -7
- package/serialization/resources/crm/types/UpsertCrmDealResponse.js +17 -7
- package/serialization/resources/crm/types/UpsertCrmProductResponse.js +17 -7
- package/serialization/resources/crm/types/UpsertDealLineItemAssociationResponse.js +17 -7
- package/serialization/resources/crm/types/UpsertLineItemResponse.js +17 -7
- package/serialization/resources/dataexports/client/index.d.ts +1 -0
- package/serialization/resources/dataexports/client/index.js +17 -0
- package/serialization/resources/dataexports/client/requests/CreateDataExportRequestBody.d.ts +12 -0
- package/serialization/resources/dataexports/client/requests/CreateDataExportRequestBody.js +43 -0
- package/serialization/resources/dataexports/client/requests/index.d.ts +1 -0
- package/serialization/resources/dataexports/client/requests/index.js +5 -0
- package/serialization/resources/dataexports/index.d.ts +2 -0
- package/serialization/resources/dataexports/index.js +18 -0
- package/serialization/resources/dataexports/types/CreateDataExportResponse.d.ts +14 -0
- package/serialization/resources/dataexports/types/CreateDataExportResponse.js +45 -0
- package/serialization/resources/dataexports/types/index.d.ts +1 -0
- package/serialization/resources/dataexports/types/index.js +17 -0
- package/serialization/resources/entitlements/client/requests/CreateCompanyOverrideRequestBody.js +17 -7
- package/serialization/resources/entitlements/client/requests/CreatePlanEntitlementRequestBody.d.ts +7 -0
- package/serialization/resources/entitlements/client/requests/CreatePlanEntitlementRequestBody.js +24 -7
- package/serialization/resources/entitlements/client/requests/UpdateCompanyOverrideRequestBody.js +17 -7
- package/serialization/resources/entitlements/client/requests/UpdatePlanEntitlementRequestBody.d.ts +7 -0
- package/serialization/resources/entitlements/client/requests/UpdatePlanEntitlementRequestBody.js +24 -7
- package/serialization/resources/entitlements/types/CountCompanyOverridesParams.js +17 -7
- package/serialization/resources/entitlements/types/CountCompanyOverridesResponse.js +17 -7
- package/serialization/resources/entitlements/types/CountFeatureCompaniesParams.js +17 -7
- package/serialization/resources/entitlements/types/CountFeatureCompaniesResponse.js +17 -7
- package/serialization/resources/entitlements/types/CountFeatureUsageParams.js +17 -7
- package/serialization/resources/entitlements/types/CountFeatureUsageResponse.js +17 -7
- package/serialization/resources/entitlements/types/CountFeatureUsersParams.js +17 -7
- package/serialization/resources/entitlements/types/CountFeatureUsersResponse.js +17 -7
- package/serialization/resources/entitlements/types/CountPlanEntitlementsParams.js +17 -7
- package/serialization/resources/entitlements/types/CountPlanEntitlementsResponse.js +17 -7
- package/serialization/resources/entitlements/types/CreateCompanyOverrideRequestBodyMetricPeriod.js +17 -7
- package/serialization/resources/entitlements/types/CreateCompanyOverrideRequestBodyMetricPeriodMonthReset.js +17 -7
- package/serialization/resources/entitlements/types/CreateCompanyOverrideRequestBodyValueType.js +17 -7
- package/serialization/resources/entitlements/types/CreateCompanyOverrideResponse.js +17 -7
- package/serialization/resources/entitlements/types/CreatePlanEntitlementRequestBodyMetricPeriod.js +17 -7
- package/serialization/resources/entitlements/types/CreatePlanEntitlementRequestBodyMetricPeriodMonthReset.js +17 -7
- package/serialization/resources/entitlements/types/CreatePlanEntitlementRequestBodyValueType.js +17 -7
- package/serialization/resources/entitlements/types/CreatePlanEntitlementResponse.js +17 -7
- package/serialization/resources/entitlements/types/DeleteCompanyOverrideResponse.js +17 -7
- package/serialization/resources/entitlements/types/DeletePlanEntitlementResponse.js +17 -7
- package/serialization/resources/entitlements/types/GetCompanyOverrideResponse.js +17 -7
- package/serialization/resources/entitlements/types/GetFeatureUsageByCompanyParams.d.ts +1 -1
- package/serialization/resources/entitlements/types/GetFeatureUsageByCompanyParams.js +18 -8
- package/serialization/resources/entitlements/types/GetFeatureUsageByCompanyResponse.js +17 -7
- package/serialization/resources/entitlements/types/GetPlanEntitlementResponse.js +17 -7
- package/serialization/resources/entitlements/types/ListCompanyOverridesParams.js +17 -7
- package/serialization/resources/entitlements/types/ListCompanyOverridesResponse.js +17 -7
- package/serialization/resources/entitlements/types/ListFeatureCompaniesParams.js +17 -7
- package/serialization/resources/entitlements/types/ListFeatureCompaniesResponse.js +17 -7
- package/serialization/resources/entitlements/types/ListFeatureUsageParams.js +17 -7
- package/serialization/resources/entitlements/types/ListFeatureUsageResponse.js +17 -7
- package/serialization/resources/entitlements/types/ListFeatureUsersParams.js +17 -7
- package/serialization/resources/entitlements/types/ListFeatureUsersResponse.js +17 -7
- package/serialization/resources/entitlements/types/ListPlanEntitlementsParams.js +17 -7
- package/serialization/resources/entitlements/types/ListPlanEntitlementsResponse.js +17 -7
- package/serialization/resources/entitlements/types/UpdateCompanyOverrideRequestBodyMetricPeriod.js +17 -7
- package/serialization/resources/entitlements/types/UpdateCompanyOverrideRequestBodyMetricPeriodMonthReset.js +17 -7
- package/serialization/resources/entitlements/types/UpdateCompanyOverrideRequestBodyValueType.js +17 -7
- package/serialization/resources/entitlements/types/UpdateCompanyOverrideResponse.js +17 -7
- package/serialization/resources/entitlements/types/UpdatePlanEntitlementRequestBodyMetricPeriod.js +17 -7
- package/serialization/resources/entitlements/types/UpdatePlanEntitlementRequestBodyMetricPeriodMonthReset.js +17 -7
- package/serialization/resources/entitlements/types/UpdatePlanEntitlementRequestBodyValueType.js +17 -7
- package/serialization/resources/entitlements/types/UpdatePlanEntitlementResponse.js +17 -7
- package/serialization/resources/events/client/requests/CreateEventBatchRequestBody.js +17 -7
- package/serialization/resources/events/types/CreateEventBatchResponse.js +17 -7
- package/serialization/resources/events/types/CreateEventResponse.js +17 -7
- package/serialization/resources/events/types/GetEventResponse.js +17 -7
- package/serialization/resources/events/types/GetEventSummariesParams.js +17 -7
- package/serialization/resources/events/types/GetEventSummariesResponse.js +17 -7
- package/serialization/resources/events/types/GetSegmentIntegrationStatusResponse.js +17 -7
- package/serialization/resources/events/types/ListEventsParams.js +17 -7
- package/serialization/resources/events/types/ListEventsResponse.js +17 -7
- package/serialization/resources/features/client/requests/CreateFeatureRequestBody.d.ts +2 -0
- package/serialization/resources/features/client/requests/CreateFeatureRequestBody.js +19 -7
- package/serialization/resources/features/client/requests/UpdateFeatureRequestBody.d.ts +2 -0
- package/serialization/resources/features/client/requests/UpdateFeatureRequestBody.js +19 -7
- package/serialization/resources/features/client/requests/UpdateFlagRulesRequestBody.js +17 -7
- package/serialization/resources/features/types/CheckFlagResponse.js +17 -7
- package/serialization/resources/features/types/CheckFlagsResponse.js +17 -7
- package/serialization/resources/features/types/CountAudienceCompaniesResponse.js +17 -7
- package/serialization/resources/features/types/CountAudienceUsersResponse.js +17 -7
- package/serialization/resources/features/types/CountFeaturesParams.js +17 -7
- package/serialization/resources/features/types/CountFeaturesResponse.js +17 -7
- package/serialization/resources/features/types/CountFlagsParams.js +17 -7
- package/serialization/resources/features/types/CountFlagsResponse.js +17 -7
- package/serialization/resources/features/types/CreateFeatureRequestBodyFeatureType.js +17 -7
- package/serialization/resources/features/types/CreateFeatureResponse.js +17 -7
- package/serialization/resources/features/types/CreateFlagResponse.js +17 -7
- package/serialization/resources/features/types/DeleteFeatureResponse.js +17 -7
- package/serialization/resources/features/types/DeleteFlagResponse.js +17 -7
- package/serialization/resources/features/types/GetFeatureResponse.js +17 -7
- package/serialization/resources/features/types/GetFlagResponse.js +17 -7
- package/serialization/resources/features/types/ListAudienceCompaniesResponse.js +17 -7
- package/serialization/resources/features/types/ListAudienceUsersResponse.js +17 -7
- package/serialization/resources/features/types/ListFeaturesParams.js +17 -7
- package/serialization/resources/features/types/ListFeaturesResponse.js +17 -7
- package/serialization/resources/features/types/ListFlagsParams.js +17 -7
- package/serialization/resources/features/types/ListFlagsResponse.js +17 -7
- package/serialization/resources/features/types/UpdateFeatureRequestBodyFeatureType.js +17 -7
- package/serialization/resources/features/types/UpdateFeatureResponse.js +17 -7
- package/serialization/resources/features/types/UpdateFlagResponse.js +17 -7
- package/serialization/resources/features/types/UpdateFlagRulesResponse.js +17 -7
- package/serialization/resources/index.d.ts +3 -0
- package/serialization/resources/index.js +21 -8
- package/serialization/resources/plangroups/client/requests/CreatePlanGroupRequestBody.d.ts +5 -1
- package/serialization/resources/plangroups/client/requests/CreatePlanGroupRequestBody.js +22 -8
- package/serialization/resources/plangroups/client/requests/UpdatePlanGroupRequestBody.d.ts +5 -1
- package/serialization/resources/plangroups/client/requests/UpdatePlanGroupRequestBody.js +22 -8
- package/serialization/resources/plangroups/types/CreatePlanGroupResponse.js +17 -7
- package/serialization/resources/plangroups/types/GetPlanGroupResponse.js +17 -7
- package/serialization/resources/plangroups/types/UpdatePlanGroupResponse.js +17 -7
- package/serialization/resources/plans/client/requests/CreatePlanRequestBody.js +17 -7
- package/serialization/resources/plans/client/requests/CreatePlanTraitRequestBody.d.ts +14 -0
- package/serialization/resources/plans/client/requests/CreatePlanTraitRequestBody.js +45 -0
- package/serialization/resources/plans/client/requests/UpdateAudienceRequestBody.js +17 -7
- package/serialization/resources/plans/client/requests/UpdateCompanyPlansRequestBody.js +17 -7
- package/serialization/resources/plans/client/requests/UpdatePlanRequestBody.js +17 -7
- package/serialization/resources/plans/client/requests/UpdatePlanTraitRequestBody.d.ts +13 -0
- package/serialization/resources/plans/client/requests/UpdatePlanTraitRequestBody.js +44 -0
- package/serialization/resources/plans/client/requests/UpsertBillingProductRequestBody.d.ts +2 -0
- package/serialization/resources/plans/client/requests/UpsertBillingProductRequestBody.js +19 -7
- package/serialization/resources/plans/client/requests/index.d.ts +2 -0
- package/serialization/resources/plans/client/requests/index.js +5 -1
- package/serialization/resources/plans/types/CountPlanTraitsParams.d.ts +16 -0
- package/serialization/resources/plans/types/CountPlanTraitsParams.js +47 -0
- package/serialization/resources/plans/types/CountPlanTraitsResponse.d.ts +15 -0
- package/serialization/resources/plans/types/CountPlanTraitsResponse.js +46 -0
- package/serialization/resources/plans/types/CountPlansParams.js +17 -7
- package/serialization/resources/plans/types/CountPlansRequestPlanType.js +17 -7
- package/serialization/resources/plans/types/CountPlansResponse.js +17 -7
- package/serialization/resources/plans/types/CountPlansResponseParamsPlanType.js +17 -7
- package/serialization/resources/plans/types/CreatePlanRequestBodyPlanType.js +17 -7
- package/serialization/resources/plans/types/CreatePlanResponse.js +17 -7
- package/serialization/resources/plans/types/CreatePlanTraitResponse.d.ts +14 -0
- package/serialization/resources/plans/types/CreatePlanTraitResponse.js +45 -0
- package/serialization/resources/plans/types/DeleteAudienceResponse.js +17 -7
- package/serialization/resources/plans/types/DeletePlanResponse.js +17 -7
- package/serialization/resources/plans/types/DeletePlanTraitResponse.d.ts +14 -0
- package/serialization/resources/plans/types/DeletePlanTraitResponse.js +45 -0
- package/serialization/resources/plans/types/GetAudienceResponse.js +17 -7
- package/serialization/resources/plans/types/GetPlanResponse.js +17 -7
- package/serialization/resources/plans/types/GetPlanTraitResponse.d.ts +14 -0
- package/serialization/resources/plans/types/GetPlanTraitResponse.js +45 -0
- package/serialization/resources/plans/types/ListPlanTraitsParams.d.ts +16 -0
- package/serialization/resources/plans/types/ListPlanTraitsParams.js +47 -0
- package/serialization/resources/plans/types/ListPlanTraitsResponse.d.ts +15 -0
- package/serialization/resources/plans/types/ListPlanTraitsResponse.js +46 -0
- package/serialization/resources/plans/types/ListPlansParams.js +17 -7
- package/serialization/resources/plans/types/ListPlansRequestPlanType.js +17 -7
- package/serialization/resources/plans/types/ListPlansResponse.js +17 -7
- package/serialization/resources/plans/types/ListPlansResponseParamsPlanType.js +17 -7
- package/serialization/resources/plans/types/UpdateAudienceResponse.js +17 -7
- package/serialization/resources/plans/types/UpdateCompanyPlansResponse.js +17 -7
- package/serialization/resources/plans/types/UpdatePlanResponse.js +17 -7
- package/serialization/resources/plans/types/UpdatePlanTraitResponse.d.ts +14 -0
- package/serialization/resources/plans/types/UpdatePlanTraitResponse.js +45 -0
- package/serialization/resources/plans/types/UpsertBillingProductPlanResponse.js +17 -7
- package/serialization/resources/plans/types/index.d.ts +8 -0
- package/serialization/resources/plans/types/index.js +8 -0
- package/serialization/resources/webhooks/client/requests/CreateWebhookRequestBody.d.ts +2 -0
- package/serialization/resources/webhooks/client/requests/CreateWebhookRequestBody.js +19 -7
- package/serialization/resources/webhooks/client/requests/UpdateWebhookRequestBody.d.ts +2 -0
- package/serialization/resources/webhooks/client/requests/UpdateWebhookRequestBody.js +19 -7
- package/serialization/resources/webhooks/types/CountWebhookEventsParams.js +17 -7
- package/serialization/resources/webhooks/types/CountWebhookEventsResponse.js +17 -7
- package/serialization/resources/webhooks/types/CountWebhooksParams.js +17 -7
- package/serialization/resources/webhooks/types/CountWebhooksResponse.js +17 -7
- package/serialization/resources/webhooks/types/CreateWebhookRequestBodyRequestTypesItem.d.ts +1 -1
- package/serialization/resources/webhooks/types/CreateWebhookRequestBodyRequestTypesItem.js +21 -7
- package/serialization/resources/webhooks/types/CreateWebhookResponse.js +17 -7
- package/serialization/resources/webhooks/types/DeleteWebhookResponse.js +17 -7
- package/serialization/resources/webhooks/types/GetWebhookEventResponse.js +17 -7
- package/serialization/resources/webhooks/types/GetWebhookResponse.js +17 -7
- package/serialization/resources/webhooks/types/ListWebhookEventsParams.js +17 -7
- package/serialization/resources/webhooks/types/ListWebhookEventsResponse.js +17 -7
- package/serialization/resources/webhooks/types/ListWebhooksParams.js +17 -7
- package/serialization/resources/webhooks/types/ListWebhooksResponse.js +17 -7
- package/serialization/resources/webhooks/types/UpdateWebhookRequestBodyRequestTypesItem.d.ts +1 -1
- package/serialization/resources/webhooks/types/UpdateWebhookRequestBodyRequestTypesItem.js +21 -7
- package/serialization/resources/webhooks/types/UpdateWebhookRequestBodyStatus.js +17 -7
- package/serialization/resources/webhooks/types/UpdateWebhookResponse.js +17 -7
- package/serialization/types/ApiError.js +17 -7
- package/serialization/types/ApiKeyCreateResponseData.js +17 -7
- package/serialization/types/ApiKeyRequestListResponseData.js +17 -7
- package/serialization/types/ApiKeyRequestResponseData.js +17 -7
- package/serialization/types/ApiKeyResponseData.js +17 -7
- package/serialization/types/AudienceRequestBody.js +17 -7
- package/serialization/types/BillingCouponResponseData.js +17 -7
- package/serialization/types/BillingCustomerResponseData.js +17 -7
- package/serialization/types/BillingCustomerSubscription.js +17 -7
- package/serialization/types/BillingCustomerWithSubscriptionsResponseData.js +17 -7
- package/serialization/types/BillingMeterResponseData.js +17 -7
- package/serialization/types/BillingPriceResponseData.d.ts +2 -0
- package/serialization/types/BillingPriceResponseData.js +19 -7
- package/serialization/types/BillingPriceView.d.ts +7 -0
- package/serialization/types/BillingPriceView.js +24 -7
- package/serialization/types/BillingProductDetailResponseData.d.ts +3 -0
- package/serialization/types/BillingProductDetailResponseData.js +20 -7
- package/serialization/types/BillingProductForSubscriptionResponseData.d.ts +5 -0
- package/serialization/types/BillingProductForSubscriptionResponseData.js +22 -7
- package/serialization/types/BillingProductPlanResponseData.d.ts +2 -0
- package/serialization/types/BillingProductPlanResponseData.js +19 -7
- package/serialization/types/BillingProductPriceResponseData.d.ts +3 -0
- package/serialization/types/BillingProductPriceResponseData.js +20 -7
- package/serialization/types/BillingProductPriceTierResponseData.d.ts +15 -0
- package/serialization/types/BillingProductPriceTierResponseData.js +46 -0
- package/serialization/types/BillingProductPricing.d.ts +4 -1
- package/serialization/types/BillingProductPricing.js +21 -8
- package/serialization/types/BillingProductPricingUsageType.d.ts +10 -0
- package/serialization/types/BillingProductPricingUsageType.js +41 -0
- package/serialization/types/BillingProductResponseData.d.ts +2 -0
- package/serialization/types/BillingProductResponseData.js +19 -7
- package/serialization/types/BillingSubscriptionDiscount.js +17 -7
- package/serialization/types/BillingSubscriptionDiscountView.js +17 -7
- package/serialization/types/BillingSubscriptionResponseData.d.ts +3 -0
- package/serialization/types/BillingSubscriptionResponseData.js +20 -7
- package/serialization/types/BillingSubscriptionView.d.ts +3 -0
- package/serialization/types/BillingSubscriptionView.js +20 -7
- package/serialization/types/ChangeSubscriptionInternalRequestBody.d.ts +1 -0
- package/serialization/types/ChangeSubscriptionInternalRequestBody.js +18 -7
- package/serialization/types/ChangeSubscriptionRequestBody.d.ts +1 -0
- package/serialization/types/ChangeSubscriptionRequestBody.js +18 -7
- package/serialization/types/CheckFlagRequestBody.js +17 -7
- package/serialization/types/CheckFlagResponseData.d.ts +1 -0
- package/serialization/types/CheckFlagResponseData.js +18 -7
- package/serialization/types/CheckFlagsResponseData.js +17 -7
- package/serialization/types/CheckoutDataResponseData.d.ts +2 -0
- package/serialization/types/CheckoutDataResponseData.js +19 -7
- package/serialization/types/CompanyCrmDealsResponseData.js +17 -7
- package/serialization/types/CompanyDetailResponseData.d.ts +3 -0
- package/serialization/types/CompanyDetailResponseData.js +20 -7
- package/serialization/types/CompanyEventPeriodMetricsResponseData.js +17 -7
- package/serialization/types/CompanyMembershipDetailResponseData.js +17 -7
- package/serialization/types/CompanyMembershipResponseData.js +17 -7
- package/serialization/types/CompanyOverrideResponseData.js +17 -7
- package/serialization/types/CompanyPlanDetailResponseData.d.ts +6 -0
- package/serialization/types/CompanyPlanDetailResponseData.js +23 -7
- package/serialization/types/CompanyPlanWithBillingSubView.d.ts +2 -0
- package/serialization/types/CompanyPlanWithBillingSubView.js +19 -7
- package/serialization/types/CompanyResponseData.js +17 -7
- package/serialization/types/CompanySubscriptionResponseData.d.ts +2 -0
- package/serialization/types/CompanySubscriptionResponseData.js +19 -7
- package/serialization/types/ComponentCapabilities.d.ts +1 -0
- package/serialization/types/ComponentCapabilities.js +18 -7
- package/serialization/types/ComponentHydrateResponseData.js +17 -7
- package/serialization/types/ComponentPreviewResponseData.js +17 -7
- package/serialization/types/ComponentResponseData.js +17 -7
- package/serialization/types/CountResponse.js +17 -7
- package/serialization/types/CouponRequestBody.js +17 -7
- package/serialization/types/CreateBillingPriceTierRequestBody.d.ts +16 -0
- package/serialization/types/CreateBillingPriceTierRequestBody.js +47 -0
- package/serialization/types/CreateEntitlementReqCommon.js +17 -7
- package/serialization/types/CreateEntitlementReqCommonMetricPeriod.js +17 -7
- package/serialization/types/CreateEntitlementReqCommonMetricPeriodMonthReset.js +17 -7
- package/serialization/types/CreateEntitlementReqCommonValueType.js +17 -7
- package/serialization/types/CreateEventRequestBody.js +17 -7
- package/serialization/types/CreateEventRequestBodyEventType.js +17 -7
- package/serialization/types/CreateFlagRequestBody.js +17 -7
- package/serialization/types/CreateOrUpdateConditionGroupRequestBody.js +17 -7
- package/serialization/types/CreateOrUpdateConditionRequestBody.js +17 -7
- package/serialization/types/CreateOrUpdateConditionRequestBodyConditionType.js +17 -7
- package/serialization/types/CreateOrUpdateConditionRequestBodyMetricPeriod.js +17 -7
- package/serialization/types/CreateOrUpdateConditionRequestBodyMetricPeriodMonthReset.js +17 -7
- package/serialization/types/CreateOrUpdateConditionRequestBodyOperator.js +17 -7
- package/serialization/types/CreateOrUpdateFlagRequestBody.js +17 -7
- package/serialization/types/CreateOrUpdateRuleRequestBody.js +17 -7
- package/serialization/types/CreateOrUpdateRuleRequestBodyRuleType.js +17 -7
- package/serialization/types/CrmDealLineItem.js +17 -7
- package/serialization/types/CrmDealResponseData.js +17 -7
- package/serialization/types/CrmLineItemResponseData.js +17 -7
- package/serialization/types/CrmProductResponseData.js +17 -7
- package/serialization/types/CustomPlanConfig.d.ts +14 -0
- package/serialization/types/CustomPlanConfig.js +45 -0
- package/serialization/types/CustomPlanViewConfigResponseData.d.ts +14 -0
- package/serialization/types/CustomPlanViewConfigResponseData.js +45 -0
- package/serialization/types/DataExportResponseData.d.ts +20 -0
- package/serialization/types/DataExportResponseData.js +51 -0
- package/serialization/types/Decimal.js +17 -7
- package/serialization/types/DeleteResponse.js +17 -7
- package/serialization/types/EntitlementTriggerConfig.d.ts +12 -0
- package/serialization/types/EntitlementTriggerConfig.js +43 -0
- package/serialization/types/EntitlementsInPlan.d.ts +13 -0
- package/serialization/types/EntitlementsInPlan.js +44 -0
- package/serialization/types/EntityKeyDefinitionResponseData.js +17 -7
- package/serialization/types/EntityKeyDetailResponseData.js +17 -7
- package/serialization/types/EntityKeyResponseData.js +17 -7
- package/serialization/types/EntityTraitDefinitionResponseData.js +17 -7
- package/serialization/types/EntityTraitDetailResponseData.js +17 -7
- package/serialization/types/EntityTraitResponseData.js +17 -7
- package/serialization/types/EntityTraitValue.js +17 -7
- package/serialization/types/EnvironmentDetailResponseData.js +17 -7
- package/serialization/types/EnvironmentResponseData.js +17 -7
- package/serialization/types/EventBody.js +17 -7
- package/serialization/types/EventBodyFlagCheck.js +17 -7
- package/serialization/types/EventBodyIdentify.js +17 -7
- package/serialization/types/EventBodyIdentifyCompany.js +17 -7
- package/serialization/types/EventBodyTrack.js +17 -7
- package/serialization/types/EventDetailResponseData.js +17 -7
- package/serialization/types/EventResponseData.js +17 -7
- package/serialization/types/EventSummaryResponseData.d.ts +2 -2
- package/serialization/types/EventSummaryResponseData.js +19 -9
- package/serialization/types/FeatureCompanyResponseData.js +17 -7
- package/serialization/types/FeatureCompanyResponseDataAllocationType.js +17 -7
- package/serialization/types/FeatureCompanyUserResponseData.js +17 -7
- package/serialization/types/FeatureCompanyUserResponseDataAllocationType.js +17 -7
- package/serialization/types/FeatureDetailResponseData.d.ts +2 -0
- package/serialization/types/FeatureDetailResponseData.js +19 -7
- package/serialization/types/FeatureResponseData.d.ts +2 -0
- package/serialization/types/FeatureResponseData.js +19 -7
- package/serialization/types/FeatureUsageDetailResponseData.js +17 -7
- package/serialization/types/FeatureUsageResponseData.d.ts +1 -0
- package/serialization/types/FeatureUsageResponseData.js +18 -7
- package/serialization/types/FeatureUsageResponseDataAllocationType.js +17 -7
- package/serialization/types/FlagDetailResponseData.js +17 -7
- package/serialization/types/FlagResponseData.js +17 -7
- package/serialization/types/GenericPreviewObject.js +17 -7
- package/serialization/types/InvoiceRequestBody.js +17 -7
- package/serialization/types/InvoiceResponseData.js +17 -7
- package/serialization/types/IssueTemporaryAccessTokenResponseData.js +17 -7
- package/serialization/types/KeysRequestBody.js +17 -7
- package/serialization/types/MeterRequestBody.js +17 -7
- package/serialization/types/OrderedPlansInGroup.d.ts +14 -0
- package/serialization/types/OrderedPlansInGroup.js +45 -0
- package/serialization/types/PaginationFilter.js +17 -7
- package/serialization/types/PaymentMethodRequestBody.d.ts +0 -1
- package/serialization/types/PaymentMethodRequestBody.js +17 -8
- package/serialization/types/PaymentMethodResponseData.d.ts +0 -1
- package/serialization/types/PaymentMethodResponseData.js +17 -8
- package/serialization/types/PlanAudienceDetailResponseData.js +17 -7
- package/serialization/types/PlanAudienceResponseData.js +17 -7
- package/serialization/types/PlanDetailResponseData.d.ts +2 -0
- package/serialization/types/PlanDetailResponseData.js +19 -7
- package/serialization/types/PlanEntitlementResponseData.d.ts +3 -0
- package/serialization/types/PlanEntitlementResponseData.js +20 -7
- package/serialization/types/PlanEntitlementsOrder.d.ts +13 -0
- package/serialization/types/PlanEntitlementsOrder.js +44 -0
- package/serialization/types/PlanGroupDetailResponseData.d.ts +5 -0
- package/serialization/types/PlanGroupDetailResponseData.js +22 -7
- package/serialization/types/PlanGroupPlanDetailResponseData.d.ts +5 -0
- package/serialization/types/PlanGroupPlanDetailResponseData.js +22 -7
- package/serialization/types/PlanGroupPlanEntitlementsOrder.d.ts +14 -0
- package/serialization/types/PlanGroupPlanEntitlementsOrder.js +45 -0
- package/serialization/types/PlanGroupResponseData.d.ts +2 -1
- package/serialization/types/PlanGroupResponseData.js +19 -8
- package/serialization/types/PlanResponseData.js +17 -7
- package/serialization/types/PlanTraitResponseData.d.ts +19 -0
- package/serialization/types/PlanTraitResponseData.js +50 -0
- package/serialization/types/PreviewObject.js +17 -7
- package/serialization/types/PreviewObjectResponseData.js +17 -7
- package/serialization/types/PreviewSubscriptionChangeResponseData.d.ts +4 -0
- package/serialization/types/PreviewSubscriptionChangeResponseData.js +21 -7
- package/serialization/types/PreviewSubscriptionFinanceResponseData.d.ts +21 -0
- package/serialization/types/PreviewSubscriptionFinanceResponseData.js +52 -0
- package/serialization/types/PreviewSubscriptionUpcomingInvoiceLineItems.d.ts +16 -0
- package/serialization/types/PreviewSubscriptionUpcomingInvoiceLineItems.js +47 -0
- package/serialization/types/QuickstartResp.d.ts +12 -0
- package/serialization/types/QuickstartResp.js +43 -0
- package/serialization/types/RawEventBatchResponseData.js +17 -7
- package/serialization/types/RawEventResponseData.js +17 -7
- package/serialization/types/RuleConditionDetailResponseData.js +17 -7
- package/serialization/types/RuleConditionGroupDetailResponseData.js +17 -7
- package/serialization/types/RuleConditionGroupResponseData.js +17 -7
- package/serialization/types/RuleConditionResponseData.js +17 -7
- package/serialization/types/RuleDetailResponseData.js +17 -7
- package/serialization/types/RuleResponseData.js +17 -7
- package/serialization/types/RulesDetailResponseData.js +17 -7
- package/serialization/types/SegmentStatusResp.js +17 -7
- package/serialization/types/StripeEmbedInfo.js +17 -7
- package/serialization/types/TemporaryAccessTokenResponseData.js +17 -7
- package/serialization/types/UpdateAddOnRequestBody.js +17 -7
- package/serialization/types/UpdateEntitlementReqCommon.js +17 -7
- package/serialization/types/UpdateEntitlementReqCommonMetricPeriod.js +17 -7
- package/serialization/types/UpdateEntitlementReqCommonMetricPeriodMonthReset.js +17 -7
- package/serialization/types/UpdateEntitlementReqCommonValueType.js +17 -7
- package/serialization/types/UpdatePayInAdvanceRequestBody.js +17 -7
- package/serialization/types/UpdateRuleRequestBody.js +17 -7
- package/serialization/types/UpsertCompanyRequestBody.js +17 -7
- package/serialization/types/UpsertTraitRequestBody.js +17 -7
- package/serialization/types/UpsertUserRequestBody.d.ts +2 -0
- package/serialization/types/UpsertUserRequestBody.js +19 -7
- package/serialization/types/UpsertUserSubRequestBody.d.ts +1 -0
- package/serialization/types/UpsertUserSubRequestBody.js +18 -7
- package/serialization/types/UsageBasedEntitlementRequestBody.d.ts +7 -0
- package/serialization/types/UsageBasedEntitlementRequestBody.js +24 -7
- package/serialization/types/UsageBasedEntitlementResponseData.js +17 -7
- package/serialization/types/UserDetailResponseData.js +17 -7
- package/serialization/types/UserResponseData.js +17 -7
- package/serialization/types/WebhookEventDetailResponseData.js +17 -7
- package/serialization/types/WebhookEventResponseData.js +17 -7
- package/serialization/types/WebhookResponseData.d.ts +3 -0
- package/serialization/types/WebhookResponseData.js +20 -7
- package/serialization/types/index.d.ts +15 -0
- package/serialization/types/index.js +15 -0
- package/webhooks.d.ts +76 -0
- package/webhooks.js +170 -0
- /package/api/resources/{billing/client/requests/ListCustomersRequest.js → accounts/types/QuickstartResponse.js} +0 -0
- /package/api/resources/billing/{types/ListCustomersParams.js → client/requests/ListCouponsRequest.js} +0 -0
- /package/api/resources/billing/{types/ListCustomersResponse.js → client/requests/ListCustomersWithSubscriptionsRequest.js} +0 -0
- /package/{dist/api/resources/billing/client/requests/ListCustomersRequest.js → api/resources/billing/types/DeleteBillingProductResponse.js} +0 -0
- /package/{dist/api/resources/billing/types/ListCustomersParams.js → api/resources/billing/types/ListCouponsParams.js} +0 -0
- /package/{dist/api/resources/billing/types/ListCustomersResponse.js → api/resources/billing/types/ListCouponsResponse.js} +0 -0
|
@@ -18,13 +18,23 @@ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (
|
|
|
18
18
|
}) : function(o, v) {
|
|
19
19
|
o["default"] = v;
|
|
20
20
|
});
|
|
21
|
-
var __importStar = (this && this.__importStar) || function (
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
};
|
|
21
|
+
var __importStar = (this && this.__importStar) || (function () {
|
|
22
|
+
var ownKeys = function(o) {
|
|
23
|
+
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
24
|
+
var ar = [];
|
|
25
|
+
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
26
|
+
return ar;
|
|
27
|
+
};
|
|
28
|
+
return ownKeys(o);
|
|
29
|
+
};
|
|
30
|
+
return function (mod) {
|
|
31
|
+
if (mod && mod.__esModule) return mod;
|
|
32
|
+
var result = {};
|
|
33
|
+
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
34
|
+
__setModuleDefault(result, mod);
|
|
35
|
+
return result;
|
|
36
|
+
};
|
|
37
|
+
})();
|
|
28
38
|
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
29
39
|
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
30
40
|
return new (P || (P = Promise))(function (resolve, reject) {
|
|
@@ -56,6 +66,7 @@ class Features {
|
|
|
56
66
|
* @throws {@link Schematic.BadRequestError}
|
|
57
67
|
* @throws {@link Schematic.UnauthorizedError}
|
|
58
68
|
* @throws {@link Schematic.ForbiddenError}
|
|
69
|
+
* @throws {@link Schematic.NotFoundError}
|
|
59
70
|
* @throws {@link Schematic.InternalServerError}
|
|
60
71
|
*
|
|
61
72
|
* @example
|
|
@@ -75,12 +86,15 @@ class Features {
|
|
|
75
86
|
* })
|
|
76
87
|
*/
|
|
77
88
|
countAudienceCompanies(request, requestOptions) {
|
|
78
|
-
|
|
89
|
+
return core.HttpResponsePromise.fromPromise(this.__countAudienceCompanies(request, requestOptions));
|
|
90
|
+
}
|
|
91
|
+
__countAudienceCompanies(request, requestOptions) {
|
|
79
92
|
return __awaiter(this, void 0, void 0, function* () {
|
|
93
|
+
var _a, _b, _c;
|
|
80
94
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
81
|
-
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.
|
|
95
|
+
url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.SchematicEnvironment.Default, "audience/count-companies"),
|
|
82
96
|
method: "POST",
|
|
83
|
-
headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@schematichq/schematic-typescript-node", "X-Fern-SDK-Version": "1.1.
|
|
97
|
+
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@schematichq/schematic-typescript-node", "X-Fern-SDK-Version": "1.1.11", "User-Agent": "@schematichq/schematic-typescript-node/1.1.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
84
98
|
contentType: "application/json",
|
|
85
99
|
requestType: "json",
|
|
86
100
|
body: serializers.AudienceRequestBody.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
|
@@ -89,13 +103,16 @@ class Features {
|
|
|
89
103
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
90
104
|
});
|
|
91
105
|
if (_response.ok) {
|
|
92
|
-
return
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
106
|
+
return {
|
|
107
|
+
data: serializers.CountAudienceCompaniesResponse.parseOrThrow(_response.body, {
|
|
108
|
+
unrecognizedObjectKeys: "passthrough",
|
|
109
|
+
allowUnrecognizedUnionMembers: true,
|
|
110
|
+
allowUnrecognizedEnumValues: true,
|
|
111
|
+
skipValidation: true,
|
|
112
|
+
breadcrumbsPrefix: ["response"],
|
|
113
|
+
}),
|
|
114
|
+
rawResponse: _response.rawResponse,
|
|
115
|
+
};
|
|
99
116
|
}
|
|
100
117
|
if (_response.error.reason === "status-code") {
|
|
101
118
|
switch (_response.error.statusCode) {
|
|
@@ -106,7 +123,7 @@ class Features {
|
|
|
106
123
|
allowUnrecognizedEnumValues: true,
|
|
107
124
|
skipValidation: true,
|
|
108
125
|
breadcrumbsPrefix: ["response"],
|
|
109
|
-
}));
|
|
126
|
+
}), _response.rawResponse);
|
|
110
127
|
case 401:
|
|
111
128
|
throw new Schematic.UnauthorizedError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
112
129
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -114,7 +131,7 @@ class Features {
|
|
|
114
131
|
allowUnrecognizedEnumValues: true,
|
|
115
132
|
skipValidation: true,
|
|
116
133
|
breadcrumbsPrefix: ["response"],
|
|
117
|
-
}));
|
|
134
|
+
}), _response.rawResponse);
|
|
118
135
|
case 403:
|
|
119
136
|
throw new Schematic.ForbiddenError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
120
137
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -122,7 +139,15 @@ class Features {
|
|
|
122
139
|
allowUnrecognizedEnumValues: true,
|
|
123
140
|
skipValidation: true,
|
|
124
141
|
breadcrumbsPrefix: ["response"],
|
|
125
|
-
}));
|
|
142
|
+
}), _response.rawResponse);
|
|
143
|
+
case 404:
|
|
144
|
+
throw new Schematic.NotFoundError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
145
|
+
unrecognizedObjectKeys: "passthrough",
|
|
146
|
+
allowUnrecognizedUnionMembers: true,
|
|
147
|
+
allowUnrecognizedEnumValues: true,
|
|
148
|
+
skipValidation: true,
|
|
149
|
+
breadcrumbsPrefix: ["response"],
|
|
150
|
+
}), _response.rawResponse);
|
|
126
151
|
case 500:
|
|
127
152
|
throw new Schematic.InternalServerError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
128
153
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -130,11 +155,12 @@ class Features {
|
|
|
130
155
|
allowUnrecognizedEnumValues: true,
|
|
131
156
|
skipValidation: true,
|
|
132
157
|
breadcrumbsPrefix: ["response"],
|
|
133
|
-
}));
|
|
158
|
+
}), _response.rawResponse);
|
|
134
159
|
default:
|
|
135
160
|
throw new errors.SchematicError({
|
|
136
161
|
statusCode: _response.error.statusCode,
|
|
137
162
|
body: _response.error.body,
|
|
163
|
+
rawResponse: _response.rawResponse,
|
|
138
164
|
});
|
|
139
165
|
}
|
|
140
166
|
}
|
|
@@ -143,12 +169,14 @@ class Features {
|
|
|
143
169
|
throw new errors.SchematicError({
|
|
144
170
|
statusCode: _response.error.statusCode,
|
|
145
171
|
body: _response.error.rawBody,
|
|
172
|
+
rawResponse: _response.rawResponse,
|
|
146
173
|
});
|
|
147
174
|
case "timeout":
|
|
148
|
-
throw new errors.SchematicTimeoutError();
|
|
175
|
+
throw new errors.SchematicTimeoutError("Timeout exceeded when calling POST /audience/count-companies.");
|
|
149
176
|
case "unknown":
|
|
150
177
|
throw new errors.SchematicError({
|
|
151
178
|
message: _response.error.errorMessage,
|
|
179
|
+
rawResponse: _response.rawResponse,
|
|
152
180
|
});
|
|
153
181
|
}
|
|
154
182
|
});
|
|
@@ -160,6 +188,7 @@ class Features {
|
|
|
160
188
|
* @throws {@link Schematic.BadRequestError}
|
|
161
189
|
* @throws {@link Schematic.UnauthorizedError}
|
|
162
190
|
* @throws {@link Schematic.ForbiddenError}
|
|
191
|
+
* @throws {@link Schematic.NotFoundError}
|
|
163
192
|
* @throws {@link Schematic.InternalServerError}
|
|
164
193
|
*
|
|
165
194
|
* @example
|
|
@@ -179,12 +208,15 @@ class Features {
|
|
|
179
208
|
* })
|
|
180
209
|
*/
|
|
181
210
|
countAudienceUsers(request, requestOptions) {
|
|
182
|
-
|
|
211
|
+
return core.HttpResponsePromise.fromPromise(this.__countAudienceUsers(request, requestOptions));
|
|
212
|
+
}
|
|
213
|
+
__countAudienceUsers(request, requestOptions) {
|
|
183
214
|
return __awaiter(this, void 0, void 0, function* () {
|
|
215
|
+
var _a, _b, _c;
|
|
184
216
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
185
|
-
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.
|
|
217
|
+
url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.SchematicEnvironment.Default, "audience/count-users"),
|
|
186
218
|
method: "POST",
|
|
187
|
-
headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@schematichq/schematic-typescript-node", "X-Fern-SDK-Version": "1.1.
|
|
219
|
+
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@schematichq/schematic-typescript-node", "X-Fern-SDK-Version": "1.1.11", "User-Agent": "@schematichq/schematic-typescript-node/1.1.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
188
220
|
contentType: "application/json",
|
|
189
221
|
requestType: "json",
|
|
190
222
|
body: serializers.AudienceRequestBody.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
|
@@ -193,13 +225,16 @@ class Features {
|
|
|
193
225
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
194
226
|
});
|
|
195
227
|
if (_response.ok) {
|
|
196
|
-
return
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
228
|
+
return {
|
|
229
|
+
data: serializers.CountAudienceUsersResponse.parseOrThrow(_response.body, {
|
|
230
|
+
unrecognizedObjectKeys: "passthrough",
|
|
231
|
+
allowUnrecognizedUnionMembers: true,
|
|
232
|
+
allowUnrecognizedEnumValues: true,
|
|
233
|
+
skipValidation: true,
|
|
234
|
+
breadcrumbsPrefix: ["response"],
|
|
235
|
+
}),
|
|
236
|
+
rawResponse: _response.rawResponse,
|
|
237
|
+
};
|
|
203
238
|
}
|
|
204
239
|
if (_response.error.reason === "status-code") {
|
|
205
240
|
switch (_response.error.statusCode) {
|
|
@@ -210,7 +245,7 @@ class Features {
|
|
|
210
245
|
allowUnrecognizedEnumValues: true,
|
|
211
246
|
skipValidation: true,
|
|
212
247
|
breadcrumbsPrefix: ["response"],
|
|
213
|
-
}));
|
|
248
|
+
}), _response.rawResponse);
|
|
214
249
|
case 401:
|
|
215
250
|
throw new Schematic.UnauthorizedError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
216
251
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -218,7 +253,7 @@ class Features {
|
|
|
218
253
|
allowUnrecognizedEnumValues: true,
|
|
219
254
|
skipValidation: true,
|
|
220
255
|
breadcrumbsPrefix: ["response"],
|
|
221
|
-
}));
|
|
256
|
+
}), _response.rawResponse);
|
|
222
257
|
case 403:
|
|
223
258
|
throw new Schematic.ForbiddenError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
224
259
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -226,7 +261,15 @@ class Features {
|
|
|
226
261
|
allowUnrecognizedEnumValues: true,
|
|
227
262
|
skipValidation: true,
|
|
228
263
|
breadcrumbsPrefix: ["response"],
|
|
229
|
-
}));
|
|
264
|
+
}), _response.rawResponse);
|
|
265
|
+
case 404:
|
|
266
|
+
throw new Schematic.NotFoundError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
267
|
+
unrecognizedObjectKeys: "passthrough",
|
|
268
|
+
allowUnrecognizedUnionMembers: true,
|
|
269
|
+
allowUnrecognizedEnumValues: true,
|
|
270
|
+
skipValidation: true,
|
|
271
|
+
breadcrumbsPrefix: ["response"],
|
|
272
|
+
}), _response.rawResponse);
|
|
230
273
|
case 500:
|
|
231
274
|
throw new Schematic.InternalServerError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
232
275
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -234,11 +277,12 @@ class Features {
|
|
|
234
277
|
allowUnrecognizedEnumValues: true,
|
|
235
278
|
skipValidation: true,
|
|
236
279
|
breadcrumbsPrefix: ["response"],
|
|
237
|
-
}));
|
|
280
|
+
}), _response.rawResponse);
|
|
238
281
|
default:
|
|
239
282
|
throw new errors.SchematicError({
|
|
240
283
|
statusCode: _response.error.statusCode,
|
|
241
284
|
body: _response.error.body,
|
|
285
|
+
rawResponse: _response.rawResponse,
|
|
242
286
|
});
|
|
243
287
|
}
|
|
244
288
|
}
|
|
@@ -247,12 +291,14 @@ class Features {
|
|
|
247
291
|
throw new errors.SchematicError({
|
|
248
292
|
statusCode: _response.error.statusCode,
|
|
249
293
|
body: _response.error.rawBody,
|
|
294
|
+
rawResponse: _response.rawResponse,
|
|
250
295
|
});
|
|
251
296
|
case "timeout":
|
|
252
|
-
throw new errors.SchematicTimeoutError();
|
|
297
|
+
throw new errors.SchematicTimeoutError("Timeout exceeded when calling POST /audience/count-users.");
|
|
253
298
|
case "unknown":
|
|
254
299
|
throw new errors.SchematicError({
|
|
255
300
|
message: _response.error.errorMessage,
|
|
301
|
+
rawResponse: _response.rawResponse,
|
|
256
302
|
});
|
|
257
303
|
}
|
|
258
304
|
});
|
|
@@ -264,6 +310,7 @@ class Features {
|
|
|
264
310
|
* @throws {@link Schematic.BadRequestError}
|
|
265
311
|
* @throws {@link Schematic.UnauthorizedError}
|
|
266
312
|
* @throws {@link Schematic.ForbiddenError}
|
|
313
|
+
* @throws {@link Schematic.NotFoundError}
|
|
267
314
|
* @throws {@link Schematic.InternalServerError}
|
|
268
315
|
*
|
|
269
316
|
* @example
|
|
@@ -283,12 +330,15 @@ class Features {
|
|
|
283
330
|
* })
|
|
284
331
|
*/
|
|
285
332
|
listAudienceCompanies(request, requestOptions) {
|
|
286
|
-
|
|
333
|
+
return core.HttpResponsePromise.fromPromise(this.__listAudienceCompanies(request, requestOptions));
|
|
334
|
+
}
|
|
335
|
+
__listAudienceCompanies(request, requestOptions) {
|
|
287
336
|
return __awaiter(this, void 0, void 0, function* () {
|
|
337
|
+
var _a, _b, _c;
|
|
288
338
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
289
|
-
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.
|
|
339
|
+
url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.SchematicEnvironment.Default, "audience/get-companies"),
|
|
290
340
|
method: "POST",
|
|
291
|
-
headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@schematichq/schematic-typescript-node", "X-Fern-SDK-Version": "1.1.
|
|
341
|
+
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@schematichq/schematic-typescript-node", "X-Fern-SDK-Version": "1.1.11", "User-Agent": "@schematichq/schematic-typescript-node/1.1.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
292
342
|
contentType: "application/json",
|
|
293
343
|
requestType: "json",
|
|
294
344
|
body: serializers.AudienceRequestBody.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
|
@@ -297,13 +347,16 @@ class Features {
|
|
|
297
347
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
298
348
|
});
|
|
299
349
|
if (_response.ok) {
|
|
300
|
-
return
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
350
|
+
return {
|
|
351
|
+
data: serializers.ListAudienceCompaniesResponse.parseOrThrow(_response.body, {
|
|
352
|
+
unrecognizedObjectKeys: "passthrough",
|
|
353
|
+
allowUnrecognizedUnionMembers: true,
|
|
354
|
+
allowUnrecognizedEnumValues: true,
|
|
355
|
+
skipValidation: true,
|
|
356
|
+
breadcrumbsPrefix: ["response"],
|
|
357
|
+
}),
|
|
358
|
+
rawResponse: _response.rawResponse,
|
|
359
|
+
};
|
|
307
360
|
}
|
|
308
361
|
if (_response.error.reason === "status-code") {
|
|
309
362
|
switch (_response.error.statusCode) {
|
|
@@ -314,7 +367,7 @@ class Features {
|
|
|
314
367
|
allowUnrecognizedEnumValues: true,
|
|
315
368
|
skipValidation: true,
|
|
316
369
|
breadcrumbsPrefix: ["response"],
|
|
317
|
-
}));
|
|
370
|
+
}), _response.rawResponse);
|
|
318
371
|
case 401:
|
|
319
372
|
throw new Schematic.UnauthorizedError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
320
373
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -322,7 +375,7 @@ class Features {
|
|
|
322
375
|
allowUnrecognizedEnumValues: true,
|
|
323
376
|
skipValidation: true,
|
|
324
377
|
breadcrumbsPrefix: ["response"],
|
|
325
|
-
}));
|
|
378
|
+
}), _response.rawResponse);
|
|
326
379
|
case 403:
|
|
327
380
|
throw new Schematic.ForbiddenError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
328
381
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -330,7 +383,15 @@ class Features {
|
|
|
330
383
|
allowUnrecognizedEnumValues: true,
|
|
331
384
|
skipValidation: true,
|
|
332
385
|
breadcrumbsPrefix: ["response"],
|
|
333
|
-
}));
|
|
386
|
+
}), _response.rawResponse);
|
|
387
|
+
case 404:
|
|
388
|
+
throw new Schematic.NotFoundError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
389
|
+
unrecognizedObjectKeys: "passthrough",
|
|
390
|
+
allowUnrecognizedUnionMembers: true,
|
|
391
|
+
allowUnrecognizedEnumValues: true,
|
|
392
|
+
skipValidation: true,
|
|
393
|
+
breadcrumbsPrefix: ["response"],
|
|
394
|
+
}), _response.rawResponse);
|
|
334
395
|
case 500:
|
|
335
396
|
throw new Schematic.InternalServerError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
336
397
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -338,11 +399,12 @@ class Features {
|
|
|
338
399
|
allowUnrecognizedEnumValues: true,
|
|
339
400
|
skipValidation: true,
|
|
340
401
|
breadcrumbsPrefix: ["response"],
|
|
341
|
-
}));
|
|
402
|
+
}), _response.rawResponse);
|
|
342
403
|
default:
|
|
343
404
|
throw new errors.SchematicError({
|
|
344
405
|
statusCode: _response.error.statusCode,
|
|
345
406
|
body: _response.error.body,
|
|
407
|
+
rawResponse: _response.rawResponse,
|
|
346
408
|
});
|
|
347
409
|
}
|
|
348
410
|
}
|
|
@@ -351,12 +413,14 @@ class Features {
|
|
|
351
413
|
throw new errors.SchematicError({
|
|
352
414
|
statusCode: _response.error.statusCode,
|
|
353
415
|
body: _response.error.rawBody,
|
|
416
|
+
rawResponse: _response.rawResponse,
|
|
354
417
|
});
|
|
355
418
|
case "timeout":
|
|
356
|
-
throw new errors.SchematicTimeoutError();
|
|
419
|
+
throw new errors.SchematicTimeoutError("Timeout exceeded when calling POST /audience/get-companies.");
|
|
357
420
|
case "unknown":
|
|
358
421
|
throw new errors.SchematicError({
|
|
359
422
|
message: _response.error.errorMessage,
|
|
423
|
+
rawResponse: _response.rawResponse,
|
|
360
424
|
});
|
|
361
425
|
}
|
|
362
426
|
});
|
|
@@ -368,6 +432,7 @@ class Features {
|
|
|
368
432
|
* @throws {@link Schematic.BadRequestError}
|
|
369
433
|
* @throws {@link Schematic.UnauthorizedError}
|
|
370
434
|
* @throws {@link Schematic.ForbiddenError}
|
|
435
|
+
* @throws {@link Schematic.NotFoundError}
|
|
371
436
|
* @throws {@link Schematic.InternalServerError}
|
|
372
437
|
*
|
|
373
438
|
* @example
|
|
@@ -387,12 +452,15 @@ class Features {
|
|
|
387
452
|
* })
|
|
388
453
|
*/
|
|
389
454
|
listAudienceUsers(request, requestOptions) {
|
|
390
|
-
|
|
455
|
+
return core.HttpResponsePromise.fromPromise(this.__listAudienceUsers(request, requestOptions));
|
|
456
|
+
}
|
|
457
|
+
__listAudienceUsers(request, requestOptions) {
|
|
391
458
|
return __awaiter(this, void 0, void 0, function* () {
|
|
459
|
+
var _a, _b, _c;
|
|
392
460
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
393
|
-
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.
|
|
461
|
+
url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.SchematicEnvironment.Default, "audience/get-users"),
|
|
394
462
|
method: "POST",
|
|
395
|
-
headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@schematichq/schematic-typescript-node", "X-Fern-SDK-Version": "1.1.
|
|
463
|
+
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@schematichq/schematic-typescript-node", "X-Fern-SDK-Version": "1.1.11", "User-Agent": "@schematichq/schematic-typescript-node/1.1.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
396
464
|
contentType: "application/json",
|
|
397
465
|
requestType: "json",
|
|
398
466
|
body: serializers.AudienceRequestBody.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
|
@@ -401,13 +469,16 @@ class Features {
|
|
|
401
469
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
402
470
|
});
|
|
403
471
|
if (_response.ok) {
|
|
404
|
-
return
|
|
405
|
-
|
|
406
|
-
|
|
407
|
-
|
|
408
|
-
|
|
409
|
-
|
|
410
|
-
|
|
472
|
+
return {
|
|
473
|
+
data: serializers.ListAudienceUsersResponse.parseOrThrow(_response.body, {
|
|
474
|
+
unrecognizedObjectKeys: "passthrough",
|
|
475
|
+
allowUnrecognizedUnionMembers: true,
|
|
476
|
+
allowUnrecognizedEnumValues: true,
|
|
477
|
+
skipValidation: true,
|
|
478
|
+
breadcrumbsPrefix: ["response"],
|
|
479
|
+
}),
|
|
480
|
+
rawResponse: _response.rawResponse,
|
|
481
|
+
};
|
|
411
482
|
}
|
|
412
483
|
if (_response.error.reason === "status-code") {
|
|
413
484
|
switch (_response.error.statusCode) {
|
|
@@ -418,7 +489,7 @@ class Features {
|
|
|
418
489
|
allowUnrecognizedEnumValues: true,
|
|
419
490
|
skipValidation: true,
|
|
420
491
|
breadcrumbsPrefix: ["response"],
|
|
421
|
-
}));
|
|
492
|
+
}), _response.rawResponse);
|
|
422
493
|
case 401:
|
|
423
494
|
throw new Schematic.UnauthorizedError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
424
495
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -426,7 +497,7 @@ class Features {
|
|
|
426
497
|
allowUnrecognizedEnumValues: true,
|
|
427
498
|
skipValidation: true,
|
|
428
499
|
breadcrumbsPrefix: ["response"],
|
|
429
|
-
}));
|
|
500
|
+
}), _response.rawResponse);
|
|
430
501
|
case 403:
|
|
431
502
|
throw new Schematic.ForbiddenError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
432
503
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -434,7 +505,15 @@ class Features {
|
|
|
434
505
|
allowUnrecognizedEnumValues: true,
|
|
435
506
|
skipValidation: true,
|
|
436
507
|
breadcrumbsPrefix: ["response"],
|
|
437
|
-
}));
|
|
508
|
+
}), _response.rawResponse);
|
|
509
|
+
case 404:
|
|
510
|
+
throw new Schematic.NotFoundError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
511
|
+
unrecognizedObjectKeys: "passthrough",
|
|
512
|
+
allowUnrecognizedUnionMembers: true,
|
|
513
|
+
allowUnrecognizedEnumValues: true,
|
|
514
|
+
skipValidation: true,
|
|
515
|
+
breadcrumbsPrefix: ["response"],
|
|
516
|
+
}), _response.rawResponse);
|
|
438
517
|
case 500:
|
|
439
518
|
throw new Schematic.InternalServerError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
440
519
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -442,11 +521,12 @@ class Features {
|
|
|
442
521
|
allowUnrecognizedEnumValues: true,
|
|
443
522
|
skipValidation: true,
|
|
444
523
|
breadcrumbsPrefix: ["response"],
|
|
445
|
-
}));
|
|
524
|
+
}), _response.rawResponse);
|
|
446
525
|
default:
|
|
447
526
|
throw new errors.SchematicError({
|
|
448
527
|
statusCode: _response.error.statusCode,
|
|
449
528
|
body: _response.error.body,
|
|
529
|
+
rawResponse: _response.rawResponse,
|
|
450
530
|
});
|
|
451
531
|
}
|
|
452
532
|
}
|
|
@@ -455,12 +535,14 @@ class Features {
|
|
|
455
535
|
throw new errors.SchematicError({
|
|
456
536
|
statusCode: _response.error.statusCode,
|
|
457
537
|
body: _response.error.rawBody,
|
|
538
|
+
rawResponse: _response.rawResponse,
|
|
458
539
|
});
|
|
459
540
|
case "timeout":
|
|
460
|
-
throw new errors.SchematicTimeoutError();
|
|
541
|
+
throw new errors.SchematicTimeoutError("Timeout exceeded when calling POST /audience/get-users.");
|
|
461
542
|
case "unknown":
|
|
462
543
|
throw new errors.SchematicError({
|
|
463
544
|
message: _response.error.errorMessage,
|
|
545
|
+
rawResponse: _response.rawResponse,
|
|
464
546
|
});
|
|
465
547
|
}
|
|
466
548
|
});
|
|
@@ -472,14 +554,18 @@ class Features {
|
|
|
472
554
|
* @throws {@link Schematic.BadRequestError}
|
|
473
555
|
* @throws {@link Schematic.UnauthorizedError}
|
|
474
556
|
* @throws {@link Schematic.ForbiddenError}
|
|
557
|
+
* @throws {@link Schematic.NotFoundError}
|
|
475
558
|
* @throws {@link Schematic.InternalServerError}
|
|
476
559
|
*
|
|
477
560
|
* @example
|
|
478
561
|
* await client.features.listFeatures()
|
|
479
562
|
*/
|
|
480
563
|
listFeatures(request = {}, requestOptions) {
|
|
481
|
-
|
|
482
|
-
|
|
564
|
+
return core.HttpResponsePromise.fromPromise(this.__listFeatures(request, requestOptions));
|
|
565
|
+
}
|
|
566
|
+
__listFeatures() {
|
|
567
|
+
return __awaiter(this, arguments, void 0, function* (request = {}, requestOptions) {
|
|
568
|
+
var _a, _b, _c;
|
|
483
569
|
const { ids, q, withoutCompanyOverrideFor, withoutPlanEntitlementFor, limit, offset } = request;
|
|
484
570
|
const _queryParams = {};
|
|
485
571
|
if (ids != null) {
|
|
@@ -506,9 +592,9 @@ class Features {
|
|
|
506
592
|
_queryParams["offset"] = offset.toString();
|
|
507
593
|
}
|
|
508
594
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
509
|
-
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.
|
|
595
|
+
url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.SchematicEnvironment.Default, "features"),
|
|
510
596
|
method: "GET",
|
|
511
|
-
headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@schematichq/schematic-typescript-node", "X-Fern-SDK-Version": "1.1.
|
|
597
|
+
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@schematichq/schematic-typescript-node", "X-Fern-SDK-Version": "1.1.11", "User-Agent": "@schematichq/schematic-typescript-node/1.1.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
512
598
|
contentType: "application/json",
|
|
513
599
|
queryParameters: _queryParams,
|
|
514
600
|
requestType: "json",
|
|
@@ -517,13 +603,16 @@ class Features {
|
|
|
517
603
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
518
604
|
});
|
|
519
605
|
if (_response.ok) {
|
|
520
|
-
return
|
|
521
|
-
|
|
522
|
-
|
|
523
|
-
|
|
524
|
-
|
|
525
|
-
|
|
526
|
-
|
|
606
|
+
return {
|
|
607
|
+
data: serializers.ListFeaturesResponse.parseOrThrow(_response.body, {
|
|
608
|
+
unrecognizedObjectKeys: "passthrough",
|
|
609
|
+
allowUnrecognizedUnionMembers: true,
|
|
610
|
+
allowUnrecognizedEnumValues: true,
|
|
611
|
+
skipValidation: true,
|
|
612
|
+
breadcrumbsPrefix: ["response"],
|
|
613
|
+
}),
|
|
614
|
+
rawResponse: _response.rawResponse,
|
|
615
|
+
};
|
|
527
616
|
}
|
|
528
617
|
if (_response.error.reason === "status-code") {
|
|
529
618
|
switch (_response.error.statusCode) {
|
|
@@ -534,7 +623,7 @@ class Features {
|
|
|
534
623
|
allowUnrecognizedEnumValues: true,
|
|
535
624
|
skipValidation: true,
|
|
536
625
|
breadcrumbsPrefix: ["response"],
|
|
537
|
-
}));
|
|
626
|
+
}), _response.rawResponse);
|
|
538
627
|
case 401:
|
|
539
628
|
throw new Schematic.UnauthorizedError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
540
629
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -542,7 +631,7 @@ class Features {
|
|
|
542
631
|
allowUnrecognizedEnumValues: true,
|
|
543
632
|
skipValidation: true,
|
|
544
633
|
breadcrumbsPrefix: ["response"],
|
|
545
|
-
}));
|
|
634
|
+
}), _response.rawResponse);
|
|
546
635
|
case 403:
|
|
547
636
|
throw new Schematic.ForbiddenError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
548
637
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -550,7 +639,15 @@ class Features {
|
|
|
550
639
|
allowUnrecognizedEnumValues: true,
|
|
551
640
|
skipValidation: true,
|
|
552
641
|
breadcrumbsPrefix: ["response"],
|
|
553
|
-
}));
|
|
642
|
+
}), _response.rawResponse);
|
|
643
|
+
case 404:
|
|
644
|
+
throw new Schematic.NotFoundError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
645
|
+
unrecognizedObjectKeys: "passthrough",
|
|
646
|
+
allowUnrecognizedUnionMembers: true,
|
|
647
|
+
allowUnrecognizedEnumValues: true,
|
|
648
|
+
skipValidation: true,
|
|
649
|
+
breadcrumbsPrefix: ["response"],
|
|
650
|
+
}), _response.rawResponse);
|
|
554
651
|
case 500:
|
|
555
652
|
throw new Schematic.InternalServerError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
556
653
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -558,11 +655,12 @@ class Features {
|
|
|
558
655
|
allowUnrecognizedEnumValues: true,
|
|
559
656
|
skipValidation: true,
|
|
560
657
|
breadcrumbsPrefix: ["response"],
|
|
561
|
-
}));
|
|
658
|
+
}), _response.rawResponse);
|
|
562
659
|
default:
|
|
563
660
|
throw new errors.SchematicError({
|
|
564
661
|
statusCode: _response.error.statusCode,
|
|
565
662
|
body: _response.error.body,
|
|
663
|
+
rawResponse: _response.rawResponse,
|
|
566
664
|
});
|
|
567
665
|
}
|
|
568
666
|
}
|
|
@@ -571,12 +669,14 @@ class Features {
|
|
|
571
669
|
throw new errors.SchematicError({
|
|
572
670
|
statusCode: _response.error.statusCode,
|
|
573
671
|
body: _response.error.rawBody,
|
|
672
|
+
rawResponse: _response.rawResponse,
|
|
574
673
|
});
|
|
575
674
|
case "timeout":
|
|
576
|
-
throw new errors.SchematicTimeoutError();
|
|
675
|
+
throw new errors.SchematicTimeoutError("Timeout exceeded when calling GET /features.");
|
|
577
676
|
case "unknown":
|
|
578
677
|
throw new errors.SchematicError({
|
|
579
678
|
message: _response.error.errorMessage,
|
|
679
|
+
rawResponse: _response.rawResponse,
|
|
580
680
|
});
|
|
581
681
|
}
|
|
582
682
|
});
|
|
@@ -588,6 +688,7 @@ class Features {
|
|
|
588
688
|
* @throws {@link Schematic.BadRequestError}
|
|
589
689
|
* @throws {@link Schematic.UnauthorizedError}
|
|
590
690
|
* @throws {@link Schematic.ForbiddenError}
|
|
691
|
+
* @throws {@link Schematic.NotFoundError}
|
|
591
692
|
* @throws {@link Schematic.InternalServerError}
|
|
592
693
|
*
|
|
593
694
|
* @example
|
|
@@ -598,12 +699,15 @@ class Features {
|
|
|
598
699
|
* })
|
|
599
700
|
*/
|
|
600
701
|
createFeature(request, requestOptions) {
|
|
601
|
-
|
|
702
|
+
return core.HttpResponsePromise.fromPromise(this.__createFeature(request, requestOptions));
|
|
703
|
+
}
|
|
704
|
+
__createFeature(request, requestOptions) {
|
|
602
705
|
return __awaiter(this, void 0, void 0, function* () {
|
|
706
|
+
var _a, _b, _c;
|
|
603
707
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
604
|
-
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.
|
|
708
|
+
url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.SchematicEnvironment.Default, "features"),
|
|
605
709
|
method: "POST",
|
|
606
|
-
headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@schematichq/schematic-typescript-node", "X-Fern-SDK-Version": "1.1.
|
|
710
|
+
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@schematichq/schematic-typescript-node", "X-Fern-SDK-Version": "1.1.11", "User-Agent": "@schematichq/schematic-typescript-node/1.1.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
607
711
|
contentType: "application/json",
|
|
608
712
|
requestType: "json",
|
|
609
713
|
body: serializers.CreateFeatureRequestBody.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
|
@@ -612,13 +716,16 @@ class Features {
|
|
|
612
716
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
613
717
|
});
|
|
614
718
|
if (_response.ok) {
|
|
615
|
-
return
|
|
616
|
-
|
|
617
|
-
|
|
618
|
-
|
|
619
|
-
|
|
620
|
-
|
|
621
|
-
|
|
719
|
+
return {
|
|
720
|
+
data: serializers.CreateFeatureResponse.parseOrThrow(_response.body, {
|
|
721
|
+
unrecognizedObjectKeys: "passthrough",
|
|
722
|
+
allowUnrecognizedUnionMembers: true,
|
|
723
|
+
allowUnrecognizedEnumValues: true,
|
|
724
|
+
skipValidation: true,
|
|
725
|
+
breadcrumbsPrefix: ["response"],
|
|
726
|
+
}),
|
|
727
|
+
rawResponse: _response.rawResponse,
|
|
728
|
+
};
|
|
622
729
|
}
|
|
623
730
|
if (_response.error.reason === "status-code") {
|
|
624
731
|
switch (_response.error.statusCode) {
|
|
@@ -629,7 +736,7 @@ class Features {
|
|
|
629
736
|
allowUnrecognizedEnumValues: true,
|
|
630
737
|
skipValidation: true,
|
|
631
738
|
breadcrumbsPrefix: ["response"],
|
|
632
|
-
}));
|
|
739
|
+
}), _response.rawResponse);
|
|
633
740
|
case 401:
|
|
634
741
|
throw new Schematic.UnauthorizedError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
635
742
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -637,7 +744,7 @@ class Features {
|
|
|
637
744
|
allowUnrecognizedEnumValues: true,
|
|
638
745
|
skipValidation: true,
|
|
639
746
|
breadcrumbsPrefix: ["response"],
|
|
640
|
-
}));
|
|
747
|
+
}), _response.rawResponse);
|
|
641
748
|
case 403:
|
|
642
749
|
throw new Schematic.ForbiddenError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
643
750
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -645,7 +752,15 @@ class Features {
|
|
|
645
752
|
allowUnrecognizedEnumValues: true,
|
|
646
753
|
skipValidation: true,
|
|
647
754
|
breadcrumbsPrefix: ["response"],
|
|
648
|
-
}));
|
|
755
|
+
}), _response.rawResponse);
|
|
756
|
+
case 404:
|
|
757
|
+
throw new Schematic.NotFoundError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
758
|
+
unrecognizedObjectKeys: "passthrough",
|
|
759
|
+
allowUnrecognizedUnionMembers: true,
|
|
760
|
+
allowUnrecognizedEnumValues: true,
|
|
761
|
+
skipValidation: true,
|
|
762
|
+
breadcrumbsPrefix: ["response"],
|
|
763
|
+
}), _response.rawResponse);
|
|
649
764
|
case 500:
|
|
650
765
|
throw new Schematic.InternalServerError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
651
766
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -653,11 +768,12 @@ class Features {
|
|
|
653
768
|
allowUnrecognizedEnumValues: true,
|
|
654
769
|
skipValidation: true,
|
|
655
770
|
breadcrumbsPrefix: ["response"],
|
|
656
|
-
}));
|
|
771
|
+
}), _response.rawResponse);
|
|
657
772
|
default:
|
|
658
773
|
throw new errors.SchematicError({
|
|
659
774
|
statusCode: _response.error.statusCode,
|
|
660
775
|
body: _response.error.body,
|
|
776
|
+
rawResponse: _response.rawResponse,
|
|
661
777
|
});
|
|
662
778
|
}
|
|
663
779
|
}
|
|
@@ -666,12 +782,14 @@ class Features {
|
|
|
666
782
|
throw new errors.SchematicError({
|
|
667
783
|
statusCode: _response.error.statusCode,
|
|
668
784
|
body: _response.error.rawBody,
|
|
785
|
+
rawResponse: _response.rawResponse,
|
|
669
786
|
});
|
|
670
787
|
case "timeout":
|
|
671
|
-
throw new errors.SchematicTimeoutError();
|
|
788
|
+
throw new errors.SchematicTimeoutError("Timeout exceeded when calling POST /features.");
|
|
672
789
|
case "unknown":
|
|
673
790
|
throw new errors.SchematicError({
|
|
674
791
|
message: _response.error.errorMessage,
|
|
792
|
+
rawResponse: _response.rawResponse,
|
|
675
793
|
});
|
|
676
794
|
}
|
|
677
795
|
});
|
|
@@ -689,12 +807,15 @@ class Features {
|
|
|
689
807
|
* await client.features.getFeature("feature_id")
|
|
690
808
|
*/
|
|
691
809
|
getFeature(featureId, requestOptions) {
|
|
692
|
-
|
|
810
|
+
return core.HttpResponsePromise.fromPromise(this.__getFeature(featureId, requestOptions));
|
|
811
|
+
}
|
|
812
|
+
__getFeature(featureId, requestOptions) {
|
|
693
813
|
return __awaiter(this, void 0, void 0, function* () {
|
|
814
|
+
var _a, _b, _c;
|
|
694
815
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
695
|
-
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.
|
|
816
|
+
url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.SchematicEnvironment.Default, `features/${encodeURIComponent(featureId)}`),
|
|
696
817
|
method: "GET",
|
|
697
|
-
headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@schematichq/schematic-typescript-node", "X-Fern-SDK-Version": "1.1.
|
|
818
|
+
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@schematichq/schematic-typescript-node", "X-Fern-SDK-Version": "1.1.11", "User-Agent": "@schematichq/schematic-typescript-node/1.1.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
698
819
|
contentType: "application/json",
|
|
699
820
|
requestType: "json",
|
|
700
821
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
@@ -702,13 +823,16 @@ class Features {
|
|
|
702
823
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
703
824
|
});
|
|
704
825
|
if (_response.ok) {
|
|
705
|
-
return
|
|
706
|
-
|
|
707
|
-
|
|
708
|
-
|
|
709
|
-
|
|
710
|
-
|
|
711
|
-
|
|
826
|
+
return {
|
|
827
|
+
data: serializers.GetFeatureResponse.parseOrThrow(_response.body, {
|
|
828
|
+
unrecognizedObjectKeys: "passthrough",
|
|
829
|
+
allowUnrecognizedUnionMembers: true,
|
|
830
|
+
allowUnrecognizedEnumValues: true,
|
|
831
|
+
skipValidation: true,
|
|
832
|
+
breadcrumbsPrefix: ["response"],
|
|
833
|
+
}),
|
|
834
|
+
rawResponse: _response.rawResponse,
|
|
835
|
+
};
|
|
712
836
|
}
|
|
713
837
|
if (_response.error.reason === "status-code") {
|
|
714
838
|
switch (_response.error.statusCode) {
|
|
@@ -719,7 +843,7 @@ class Features {
|
|
|
719
843
|
allowUnrecognizedEnumValues: true,
|
|
720
844
|
skipValidation: true,
|
|
721
845
|
breadcrumbsPrefix: ["response"],
|
|
722
|
-
}));
|
|
846
|
+
}), _response.rawResponse);
|
|
723
847
|
case 403:
|
|
724
848
|
throw new Schematic.ForbiddenError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
725
849
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -727,7 +851,7 @@ class Features {
|
|
|
727
851
|
allowUnrecognizedEnumValues: true,
|
|
728
852
|
skipValidation: true,
|
|
729
853
|
breadcrumbsPrefix: ["response"],
|
|
730
|
-
}));
|
|
854
|
+
}), _response.rawResponse);
|
|
731
855
|
case 404:
|
|
732
856
|
throw new Schematic.NotFoundError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
733
857
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -735,7 +859,7 @@ class Features {
|
|
|
735
859
|
allowUnrecognizedEnumValues: true,
|
|
736
860
|
skipValidation: true,
|
|
737
861
|
breadcrumbsPrefix: ["response"],
|
|
738
|
-
}));
|
|
862
|
+
}), _response.rawResponse);
|
|
739
863
|
case 500:
|
|
740
864
|
throw new Schematic.InternalServerError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
741
865
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -743,11 +867,12 @@ class Features {
|
|
|
743
867
|
allowUnrecognizedEnumValues: true,
|
|
744
868
|
skipValidation: true,
|
|
745
869
|
breadcrumbsPrefix: ["response"],
|
|
746
|
-
}));
|
|
870
|
+
}), _response.rawResponse);
|
|
747
871
|
default:
|
|
748
872
|
throw new errors.SchematicError({
|
|
749
873
|
statusCode: _response.error.statusCode,
|
|
750
874
|
body: _response.error.body,
|
|
875
|
+
rawResponse: _response.rawResponse,
|
|
751
876
|
});
|
|
752
877
|
}
|
|
753
878
|
}
|
|
@@ -756,12 +881,14 @@ class Features {
|
|
|
756
881
|
throw new errors.SchematicError({
|
|
757
882
|
statusCode: _response.error.statusCode,
|
|
758
883
|
body: _response.error.rawBody,
|
|
884
|
+
rawResponse: _response.rawResponse,
|
|
759
885
|
});
|
|
760
886
|
case "timeout":
|
|
761
|
-
throw new errors.SchematicTimeoutError();
|
|
887
|
+
throw new errors.SchematicTimeoutError("Timeout exceeded when calling GET /features/{feature_id}.");
|
|
762
888
|
case "unknown":
|
|
763
889
|
throw new errors.SchematicError({
|
|
764
890
|
message: _response.error.errorMessage,
|
|
891
|
+
rawResponse: _response.rawResponse,
|
|
765
892
|
});
|
|
766
893
|
}
|
|
767
894
|
});
|
|
@@ -781,12 +908,15 @@ class Features {
|
|
|
781
908
|
* await client.features.updateFeature("feature_id")
|
|
782
909
|
*/
|
|
783
910
|
updateFeature(featureId, request = {}, requestOptions) {
|
|
784
|
-
|
|
785
|
-
|
|
911
|
+
return core.HttpResponsePromise.fromPromise(this.__updateFeature(featureId, request, requestOptions));
|
|
912
|
+
}
|
|
913
|
+
__updateFeature(featureId_1) {
|
|
914
|
+
return __awaiter(this, arguments, void 0, function* (featureId, request = {}, requestOptions) {
|
|
915
|
+
var _a, _b, _c;
|
|
786
916
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
787
|
-
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.
|
|
917
|
+
url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.SchematicEnvironment.Default, `features/${encodeURIComponent(featureId)}`),
|
|
788
918
|
method: "PUT",
|
|
789
|
-
headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@schematichq/schematic-typescript-node", "X-Fern-SDK-Version": "1.1.
|
|
919
|
+
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@schematichq/schematic-typescript-node", "X-Fern-SDK-Version": "1.1.11", "User-Agent": "@schematichq/schematic-typescript-node/1.1.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
790
920
|
contentType: "application/json",
|
|
791
921
|
requestType: "json",
|
|
792
922
|
body: serializers.UpdateFeatureRequestBody.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
|
@@ -795,13 +925,16 @@ class Features {
|
|
|
795
925
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
796
926
|
});
|
|
797
927
|
if (_response.ok) {
|
|
798
|
-
return
|
|
799
|
-
|
|
800
|
-
|
|
801
|
-
|
|
802
|
-
|
|
803
|
-
|
|
804
|
-
|
|
928
|
+
return {
|
|
929
|
+
data: serializers.UpdateFeatureResponse.parseOrThrow(_response.body, {
|
|
930
|
+
unrecognizedObjectKeys: "passthrough",
|
|
931
|
+
allowUnrecognizedUnionMembers: true,
|
|
932
|
+
allowUnrecognizedEnumValues: true,
|
|
933
|
+
skipValidation: true,
|
|
934
|
+
breadcrumbsPrefix: ["response"],
|
|
935
|
+
}),
|
|
936
|
+
rawResponse: _response.rawResponse,
|
|
937
|
+
};
|
|
805
938
|
}
|
|
806
939
|
if (_response.error.reason === "status-code") {
|
|
807
940
|
switch (_response.error.statusCode) {
|
|
@@ -812,7 +945,7 @@ class Features {
|
|
|
812
945
|
allowUnrecognizedEnumValues: true,
|
|
813
946
|
skipValidation: true,
|
|
814
947
|
breadcrumbsPrefix: ["response"],
|
|
815
|
-
}));
|
|
948
|
+
}), _response.rawResponse);
|
|
816
949
|
case 401:
|
|
817
950
|
throw new Schematic.UnauthorizedError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
818
951
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -820,7 +953,7 @@ class Features {
|
|
|
820
953
|
allowUnrecognizedEnumValues: true,
|
|
821
954
|
skipValidation: true,
|
|
822
955
|
breadcrumbsPrefix: ["response"],
|
|
823
|
-
}));
|
|
956
|
+
}), _response.rawResponse);
|
|
824
957
|
case 403:
|
|
825
958
|
throw new Schematic.ForbiddenError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
826
959
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -828,7 +961,7 @@ class Features {
|
|
|
828
961
|
allowUnrecognizedEnumValues: true,
|
|
829
962
|
skipValidation: true,
|
|
830
963
|
breadcrumbsPrefix: ["response"],
|
|
831
|
-
}));
|
|
964
|
+
}), _response.rawResponse);
|
|
832
965
|
case 404:
|
|
833
966
|
throw new Schematic.NotFoundError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
834
967
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -836,7 +969,7 @@ class Features {
|
|
|
836
969
|
allowUnrecognizedEnumValues: true,
|
|
837
970
|
skipValidation: true,
|
|
838
971
|
breadcrumbsPrefix: ["response"],
|
|
839
|
-
}));
|
|
972
|
+
}), _response.rawResponse);
|
|
840
973
|
case 500:
|
|
841
974
|
throw new Schematic.InternalServerError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
842
975
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -844,11 +977,12 @@ class Features {
|
|
|
844
977
|
allowUnrecognizedEnumValues: true,
|
|
845
978
|
skipValidation: true,
|
|
846
979
|
breadcrumbsPrefix: ["response"],
|
|
847
|
-
}));
|
|
980
|
+
}), _response.rawResponse);
|
|
848
981
|
default:
|
|
849
982
|
throw new errors.SchematicError({
|
|
850
983
|
statusCode: _response.error.statusCode,
|
|
851
984
|
body: _response.error.body,
|
|
985
|
+
rawResponse: _response.rawResponse,
|
|
852
986
|
});
|
|
853
987
|
}
|
|
854
988
|
}
|
|
@@ -857,12 +991,14 @@ class Features {
|
|
|
857
991
|
throw new errors.SchematicError({
|
|
858
992
|
statusCode: _response.error.statusCode,
|
|
859
993
|
body: _response.error.rawBody,
|
|
994
|
+
rawResponse: _response.rawResponse,
|
|
860
995
|
});
|
|
861
996
|
case "timeout":
|
|
862
|
-
throw new errors.SchematicTimeoutError();
|
|
997
|
+
throw new errors.SchematicTimeoutError("Timeout exceeded when calling PUT /features/{feature_id}.");
|
|
863
998
|
case "unknown":
|
|
864
999
|
throw new errors.SchematicError({
|
|
865
1000
|
message: _response.error.errorMessage,
|
|
1001
|
+
rawResponse: _response.rawResponse,
|
|
866
1002
|
});
|
|
867
1003
|
}
|
|
868
1004
|
});
|
|
@@ -874,18 +1010,22 @@ class Features {
|
|
|
874
1010
|
* @throws {@link Schematic.BadRequestError}
|
|
875
1011
|
* @throws {@link Schematic.UnauthorizedError}
|
|
876
1012
|
* @throws {@link Schematic.ForbiddenError}
|
|
1013
|
+
* @throws {@link Schematic.NotFoundError}
|
|
877
1014
|
* @throws {@link Schematic.InternalServerError}
|
|
878
1015
|
*
|
|
879
1016
|
* @example
|
|
880
1017
|
* await client.features.deleteFeature("feature_id")
|
|
881
1018
|
*/
|
|
882
1019
|
deleteFeature(featureId, requestOptions) {
|
|
883
|
-
|
|
1020
|
+
return core.HttpResponsePromise.fromPromise(this.__deleteFeature(featureId, requestOptions));
|
|
1021
|
+
}
|
|
1022
|
+
__deleteFeature(featureId, requestOptions) {
|
|
884
1023
|
return __awaiter(this, void 0, void 0, function* () {
|
|
1024
|
+
var _a, _b, _c;
|
|
885
1025
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
886
|
-
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.
|
|
1026
|
+
url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.SchematicEnvironment.Default, `features/${encodeURIComponent(featureId)}`),
|
|
887
1027
|
method: "DELETE",
|
|
888
|
-
headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@schematichq/schematic-typescript-node", "X-Fern-SDK-Version": "1.1.
|
|
1028
|
+
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@schematichq/schematic-typescript-node", "X-Fern-SDK-Version": "1.1.11", "User-Agent": "@schematichq/schematic-typescript-node/1.1.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
889
1029
|
contentType: "application/json",
|
|
890
1030
|
requestType: "json",
|
|
891
1031
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
@@ -893,13 +1033,16 @@ class Features {
|
|
|
893
1033
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
894
1034
|
});
|
|
895
1035
|
if (_response.ok) {
|
|
896
|
-
return
|
|
897
|
-
|
|
898
|
-
|
|
899
|
-
|
|
900
|
-
|
|
901
|
-
|
|
902
|
-
|
|
1036
|
+
return {
|
|
1037
|
+
data: serializers.DeleteFeatureResponse.parseOrThrow(_response.body, {
|
|
1038
|
+
unrecognizedObjectKeys: "passthrough",
|
|
1039
|
+
allowUnrecognizedUnionMembers: true,
|
|
1040
|
+
allowUnrecognizedEnumValues: true,
|
|
1041
|
+
skipValidation: true,
|
|
1042
|
+
breadcrumbsPrefix: ["response"],
|
|
1043
|
+
}),
|
|
1044
|
+
rawResponse: _response.rawResponse,
|
|
1045
|
+
};
|
|
903
1046
|
}
|
|
904
1047
|
if (_response.error.reason === "status-code") {
|
|
905
1048
|
switch (_response.error.statusCode) {
|
|
@@ -910,7 +1053,7 @@ class Features {
|
|
|
910
1053
|
allowUnrecognizedEnumValues: true,
|
|
911
1054
|
skipValidation: true,
|
|
912
1055
|
breadcrumbsPrefix: ["response"],
|
|
913
|
-
}));
|
|
1056
|
+
}), _response.rawResponse);
|
|
914
1057
|
case 401:
|
|
915
1058
|
throw new Schematic.UnauthorizedError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
916
1059
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -918,7 +1061,7 @@ class Features {
|
|
|
918
1061
|
allowUnrecognizedEnumValues: true,
|
|
919
1062
|
skipValidation: true,
|
|
920
1063
|
breadcrumbsPrefix: ["response"],
|
|
921
|
-
}));
|
|
1064
|
+
}), _response.rawResponse);
|
|
922
1065
|
case 403:
|
|
923
1066
|
throw new Schematic.ForbiddenError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
924
1067
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -926,7 +1069,15 @@ class Features {
|
|
|
926
1069
|
allowUnrecognizedEnumValues: true,
|
|
927
1070
|
skipValidation: true,
|
|
928
1071
|
breadcrumbsPrefix: ["response"],
|
|
929
|
-
}));
|
|
1072
|
+
}), _response.rawResponse);
|
|
1073
|
+
case 404:
|
|
1074
|
+
throw new Schematic.NotFoundError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
1075
|
+
unrecognizedObjectKeys: "passthrough",
|
|
1076
|
+
allowUnrecognizedUnionMembers: true,
|
|
1077
|
+
allowUnrecognizedEnumValues: true,
|
|
1078
|
+
skipValidation: true,
|
|
1079
|
+
breadcrumbsPrefix: ["response"],
|
|
1080
|
+
}), _response.rawResponse);
|
|
930
1081
|
case 500:
|
|
931
1082
|
throw new Schematic.InternalServerError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
932
1083
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -934,11 +1085,12 @@ class Features {
|
|
|
934
1085
|
allowUnrecognizedEnumValues: true,
|
|
935
1086
|
skipValidation: true,
|
|
936
1087
|
breadcrumbsPrefix: ["response"],
|
|
937
|
-
}));
|
|
1088
|
+
}), _response.rawResponse);
|
|
938
1089
|
default:
|
|
939
1090
|
throw new errors.SchematicError({
|
|
940
1091
|
statusCode: _response.error.statusCode,
|
|
941
1092
|
body: _response.error.body,
|
|
1093
|
+
rawResponse: _response.rawResponse,
|
|
942
1094
|
});
|
|
943
1095
|
}
|
|
944
1096
|
}
|
|
@@ -947,12 +1099,14 @@ class Features {
|
|
|
947
1099
|
throw new errors.SchematicError({
|
|
948
1100
|
statusCode: _response.error.statusCode,
|
|
949
1101
|
body: _response.error.rawBody,
|
|
1102
|
+
rawResponse: _response.rawResponse,
|
|
950
1103
|
});
|
|
951
1104
|
case "timeout":
|
|
952
|
-
throw new errors.SchematicTimeoutError();
|
|
1105
|
+
throw new errors.SchematicTimeoutError("Timeout exceeded when calling DELETE /features/{feature_id}.");
|
|
953
1106
|
case "unknown":
|
|
954
1107
|
throw new errors.SchematicError({
|
|
955
1108
|
message: _response.error.errorMessage,
|
|
1109
|
+
rawResponse: _response.rawResponse,
|
|
956
1110
|
});
|
|
957
1111
|
}
|
|
958
1112
|
});
|
|
@@ -964,14 +1118,18 @@ class Features {
|
|
|
964
1118
|
* @throws {@link Schematic.BadRequestError}
|
|
965
1119
|
* @throws {@link Schematic.UnauthorizedError}
|
|
966
1120
|
* @throws {@link Schematic.ForbiddenError}
|
|
1121
|
+
* @throws {@link Schematic.NotFoundError}
|
|
967
1122
|
* @throws {@link Schematic.InternalServerError}
|
|
968
1123
|
*
|
|
969
1124
|
* @example
|
|
970
1125
|
* await client.features.countFeatures()
|
|
971
1126
|
*/
|
|
972
1127
|
countFeatures(request = {}, requestOptions) {
|
|
973
|
-
|
|
974
|
-
|
|
1128
|
+
return core.HttpResponsePromise.fromPromise(this.__countFeatures(request, requestOptions));
|
|
1129
|
+
}
|
|
1130
|
+
__countFeatures() {
|
|
1131
|
+
return __awaiter(this, arguments, void 0, function* (request = {}, requestOptions) {
|
|
1132
|
+
var _a, _b, _c;
|
|
975
1133
|
const { ids, q, withoutCompanyOverrideFor, withoutPlanEntitlementFor, limit, offset } = request;
|
|
976
1134
|
const _queryParams = {};
|
|
977
1135
|
if (ids != null) {
|
|
@@ -998,9 +1156,9 @@ class Features {
|
|
|
998
1156
|
_queryParams["offset"] = offset.toString();
|
|
999
1157
|
}
|
|
1000
1158
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
1001
|
-
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.
|
|
1159
|
+
url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.SchematicEnvironment.Default, "features/count"),
|
|
1002
1160
|
method: "GET",
|
|
1003
|
-
headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@schematichq/schematic-typescript-node", "X-Fern-SDK-Version": "1.1.
|
|
1161
|
+
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@schematichq/schematic-typescript-node", "X-Fern-SDK-Version": "1.1.11", "User-Agent": "@schematichq/schematic-typescript-node/1.1.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
1004
1162
|
contentType: "application/json",
|
|
1005
1163
|
queryParameters: _queryParams,
|
|
1006
1164
|
requestType: "json",
|
|
@@ -1009,13 +1167,16 @@ class Features {
|
|
|
1009
1167
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
1010
1168
|
});
|
|
1011
1169
|
if (_response.ok) {
|
|
1012
|
-
return
|
|
1013
|
-
|
|
1014
|
-
|
|
1015
|
-
|
|
1016
|
-
|
|
1017
|
-
|
|
1018
|
-
|
|
1170
|
+
return {
|
|
1171
|
+
data: serializers.CountFeaturesResponse.parseOrThrow(_response.body, {
|
|
1172
|
+
unrecognizedObjectKeys: "passthrough",
|
|
1173
|
+
allowUnrecognizedUnionMembers: true,
|
|
1174
|
+
allowUnrecognizedEnumValues: true,
|
|
1175
|
+
skipValidation: true,
|
|
1176
|
+
breadcrumbsPrefix: ["response"],
|
|
1177
|
+
}),
|
|
1178
|
+
rawResponse: _response.rawResponse,
|
|
1179
|
+
};
|
|
1019
1180
|
}
|
|
1020
1181
|
if (_response.error.reason === "status-code") {
|
|
1021
1182
|
switch (_response.error.statusCode) {
|
|
@@ -1026,7 +1187,7 @@ class Features {
|
|
|
1026
1187
|
allowUnrecognizedEnumValues: true,
|
|
1027
1188
|
skipValidation: true,
|
|
1028
1189
|
breadcrumbsPrefix: ["response"],
|
|
1029
|
-
}));
|
|
1190
|
+
}), _response.rawResponse);
|
|
1030
1191
|
case 401:
|
|
1031
1192
|
throw new Schematic.UnauthorizedError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
1032
1193
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -1034,7 +1195,7 @@ class Features {
|
|
|
1034
1195
|
allowUnrecognizedEnumValues: true,
|
|
1035
1196
|
skipValidation: true,
|
|
1036
1197
|
breadcrumbsPrefix: ["response"],
|
|
1037
|
-
}));
|
|
1198
|
+
}), _response.rawResponse);
|
|
1038
1199
|
case 403:
|
|
1039
1200
|
throw new Schematic.ForbiddenError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
1040
1201
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -1042,7 +1203,15 @@ class Features {
|
|
|
1042
1203
|
allowUnrecognizedEnumValues: true,
|
|
1043
1204
|
skipValidation: true,
|
|
1044
1205
|
breadcrumbsPrefix: ["response"],
|
|
1045
|
-
}));
|
|
1206
|
+
}), _response.rawResponse);
|
|
1207
|
+
case 404:
|
|
1208
|
+
throw new Schematic.NotFoundError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
1209
|
+
unrecognizedObjectKeys: "passthrough",
|
|
1210
|
+
allowUnrecognizedUnionMembers: true,
|
|
1211
|
+
allowUnrecognizedEnumValues: true,
|
|
1212
|
+
skipValidation: true,
|
|
1213
|
+
breadcrumbsPrefix: ["response"],
|
|
1214
|
+
}), _response.rawResponse);
|
|
1046
1215
|
case 500:
|
|
1047
1216
|
throw new Schematic.InternalServerError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
1048
1217
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -1050,11 +1219,12 @@ class Features {
|
|
|
1050
1219
|
allowUnrecognizedEnumValues: true,
|
|
1051
1220
|
skipValidation: true,
|
|
1052
1221
|
breadcrumbsPrefix: ["response"],
|
|
1053
|
-
}));
|
|
1222
|
+
}), _response.rawResponse);
|
|
1054
1223
|
default:
|
|
1055
1224
|
throw new errors.SchematicError({
|
|
1056
1225
|
statusCode: _response.error.statusCode,
|
|
1057
1226
|
body: _response.error.body,
|
|
1227
|
+
rawResponse: _response.rawResponse,
|
|
1058
1228
|
});
|
|
1059
1229
|
}
|
|
1060
1230
|
}
|
|
@@ -1063,12 +1233,14 @@ class Features {
|
|
|
1063
1233
|
throw new errors.SchematicError({
|
|
1064
1234
|
statusCode: _response.error.statusCode,
|
|
1065
1235
|
body: _response.error.rawBody,
|
|
1236
|
+
rawResponse: _response.rawResponse,
|
|
1066
1237
|
});
|
|
1067
1238
|
case "timeout":
|
|
1068
|
-
throw new errors.SchematicTimeoutError();
|
|
1239
|
+
throw new errors.SchematicTimeoutError("Timeout exceeded when calling GET /features/count.");
|
|
1069
1240
|
case "unknown":
|
|
1070
1241
|
throw new errors.SchematicError({
|
|
1071
1242
|
message: _response.error.errorMessage,
|
|
1243
|
+
rawResponse: _response.rawResponse,
|
|
1072
1244
|
});
|
|
1073
1245
|
}
|
|
1074
1246
|
});
|
|
@@ -1080,14 +1252,18 @@ class Features {
|
|
|
1080
1252
|
* @throws {@link Schematic.BadRequestError}
|
|
1081
1253
|
* @throws {@link Schematic.UnauthorizedError}
|
|
1082
1254
|
* @throws {@link Schematic.ForbiddenError}
|
|
1255
|
+
* @throws {@link Schematic.NotFoundError}
|
|
1083
1256
|
* @throws {@link Schematic.InternalServerError}
|
|
1084
1257
|
*
|
|
1085
1258
|
* @example
|
|
1086
1259
|
* await client.features.listFlags()
|
|
1087
1260
|
*/
|
|
1088
1261
|
listFlags(request = {}, requestOptions) {
|
|
1089
|
-
|
|
1090
|
-
|
|
1262
|
+
return core.HttpResponsePromise.fromPromise(this.__listFlags(request, requestOptions));
|
|
1263
|
+
}
|
|
1264
|
+
__listFlags() {
|
|
1265
|
+
return __awaiter(this, arguments, void 0, function* (request = {}, requestOptions) {
|
|
1266
|
+
var _a, _b, _c;
|
|
1091
1267
|
const { featureId, ids, q, limit, offset } = request;
|
|
1092
1268
|
const _queryParams = {};
|
|
1093
1269
|
if (featureId != null) {
|
|
@@ -1111,9 +1287,9 @@ class Features {
|
|
|
1111
1287
|
_queryParams["offset"] = offset.toString();
|
|
1112
1288
|
}
|
|
1113
1289
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
1114
|
-
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.
|
|
1290
|
+
url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.SchematicEnvironment.Default, "flags"),
|
|
1115
1291
|
method: "GET",
|
|
1116
|
-
headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@schematichq/schematic-typescript-node", "X-Fern-SDK-Version": "1.1.
|
|
1292
|
+
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@schematichq/schematic-typescript-node", "X-Fern-SDK-Version": "1.1.11", "User-Agent": "@schematichq/schematic-typescript-node/1.1.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
1117
1293
|
contentType: "application/json",
|
|
1118
1294
|
queryParameters: _queryParams,
|
|
1119
1295
|
requestType: "json",
|
|
@@ -1122,13 +1298,16 @@ class Features {
|
|
|
1122
1298
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
1123
1299
|
});
|
|
1124
1300
|
if (_response.ok) {
|
|
1125
|
-
return
|
|
1126
|
-
|
|
1127
|
-
|
|
1128
|
-
|
|
1129
|
-
|
|
1130
|
-
|
|
1131
|
-
|
|
1301
|
+
return {
|
|
1302
|
+
data: serializers.ListFlagsResponse.parseOrThrow(_response.body, {
|
|
1303
|
+
unrecognizedObjectKeys: "passthrough",
|
|
1304
|
+
allowUnrecognizedUnionMembers: true,
|
|
1305
|
+
allowUnrecognizedEnumValues: true,
|
|
1306
|
+
skipValidation: true,
|
|
1307
|
+
breadcrumbsPrefix: ["response"],
|
|
1308
|
+
}),
|
|
1309
|
+
rawResponse: _response.rawResponse,
|
|
1310
|
+
};
|
|
1132
1311
|
}
|
|
1133
1312
|
if (_response.error.reason === "status-code") {
|
|
1134
1313
|
switch (_response.error.statusCode) {
|
|
@@ -1139,7 +1318,7 @@ class Features {
|
|
|
1139
1318
|
allowUnrecognizedEnumValues: true,
|
|
1140
1319
|
skipValidation: true,
|
|
1141
1320
|
breadcrumbsPrefix: ["response"],
|
|
1142
|
-
}));
|
|
1321
|
+
}), _response.rawResponse);
|
|
1143
1322
|
case 401:
|
|
1144
1323
|
throw new Schematic.UnauthorizedError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
1145
1324
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -1147,7 +1326,7 @@ class Features {
|
|
|
1147
1326
|
allowUnrecognizedEnumValues: true,
|
|
1148
1327
|
skipValidation: true,
|
|
1149
1328
|
breadcrumbsPrefix: ["response"],
|
|
1150
|
-
}));
|
|
1329
|
+
}), _response.rawResponse);
|
|
1151
1330
|
case 403:
|
|
1152
1331
|
throw new Schematic.ForbiddenError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
1153
1332
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -1155,7 +1334,15 @@ class Features {
|
|
|
1155
1334
|
allowUnrecognizedEnumValues: true,
|
|
1156
1335
|
skipValidation: true,
|
|
1157
1336
|
breadcrumbsPrefix: ["response"],
|
|
1158
|
-
}));
|
|
1337
|
+
}), _response.rawResponse);
|
|
1338
|
+
case 404:
|
|
1339
|
+
throw new Schematic.NotFoundError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
1340
|
+
unrecognizedObjectKeys: "passthrough",
|
|
1341
|
+
allowUnrecognizedUnionMembers: true,
|
|
1342
|
+
allowUnrecognizedEnumValues: true,
|
|
1343
|
+
skipValidation: true,
|
|
1344
|
+
breadcrumbsPrefix: ["response"],
|
|
1345
|
+
}), _response.rawResponse);
|
|
1159
1346
|
case 500:
|
|
1160
1347
|
throw new Schematic.InternalServerError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
1161
1348
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -1163,11 +1350,12 @@ class Features {
|
|
|
1163
1350
|
allowUnrecognizedEnumValues: true,
|
|
1164
1351
|
skipValidation: true,
|
|
1165
1352
|
breadcrumbsPrefix: ["response"],
|
|
1166
|
-
}));
|
|
1353
|
+
}), _response.rawResponse);
|
|
1167
1354
|
default:
|
|
1168
1355
|
throw new errors.SchematicError({
|
|
1169
1356
|
statusCode: _response.error.statusCode,
|
|
1170
1357
|
body: _response.error.body,
|
|
1358
|
+
rawResponse: _response.rawResponse,
|
|
1171
1359
|
});
|
|
1172
1360
|
}
|
|
1173
1361
|
}
|
|
@@ -1176,12 +1364,14 @@ class Features {
|
|
|
1176
1364
|
throw new errors.SchematicError({
|
|
1177
1365
|
statusCode: _response.error.statusCode,
|
|
1178
1366
|
body: _response.error.rawBody,
|
|
1367
|
+
rawResponse: _response.rawResponse,
|
|
1179
1368
|
});
|
|
1180
1369
|
case "timeout":
|
|
1181
|
-
throw new errors.SchematicTimeoutError();
|
|
1370
|
+
throw new errors.SchematicTimeoutError("Timeout exceeded when calling GET /flags.");
|
|
1182
1371
|
case "unknown":
|
|
1183
1372
|
throw new errors.SchematicError({
|
|
1184
1373
|
message: _response.error.errorMessage,
|
|
1374
|
+
rawResponse: _response.rawResponse,
|
|
1185
1375
|
});
|
|
1186
1376
|
}
|
|
1187
1377
|
});
|
|
@@ -1193,6 +1383,7 @@ class Features {
|
|
|
1193
1383
|
* @throws {@link Schematic.BadRequestError}
|
|
1194
1384
|
* @throws {@link Schematic.UnauthorizedError}
|
|
1195
1385
|
* @throws {@link Schematic.ForbiddenError}
|
|
1386
|
+
* @throws {@link Schematic.NotFoundError}
|
|
1196
1387
|
* @throws {@link Schematic.InternalServerError}
|
|
1197
1388
|
*
|
|
1198
1389
|
* @example
|
|
@@ -1205,12 +1396,15 @@ class Features {
|
|
|
1205
1396
|
* })
|
|
1206
1397
|
*/
|
|
1207
1398
|
createFlag(request, requestOptions) {
|
|
1208
|
-
|
|
1399
|
+
return core.HttpResponsePromise.fromPromise(this.__createFlag(request, requestOptions));
|
|
1400
|
+
}
|
|
1401
|
+
__createFlag(request, requestOptions) {
|
|
1209
1402
|
return __awaiter(this, void 0, void 0, function* () {
|
|
1403
|
+
var _a, _b, _c;
|
|
1210
1404
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
1211
|
-
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.
|
|
1405
|
+
url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.SchematicEnvironment.Default, "flags"),
|
|
1212
1406
|
method: "POST",
|
|
1213
|
-
headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@schematichq/schematic-typescript-node", "X-Fern-SDK-Version": "1.1.
|
|
1407
|
+
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@schematichq/schematic-typescript-node", "X-Fern-SDK-Version": "1.1.11", "User-Agent": "@schematichq/schematic-typescript-node/1.1.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
1214
1408
|
contentType: "application/json",
|
|
1215
1409
|
requestType: "json",
|
|
1216
1410
|
body: serializers.CreateFlagRequestBody.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
|
@@ -1219,13 +1413,16 @@ class Features {
|
|
|
1219
1413
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
1220
1414
|
});
|
|
1221
1415
|
if (_response.ok) {
|
|
1222
|
-
return
|
|
1223
|
-
|
|
1224
|
-
|
|
1225
|
-
|
|
1226
|
-
|
|
1227
|
-
|
|
1228
|
-
|
|
1416
|
+
return {
|
|
1417
|
+
data: serializers.CreateFlagResponse.parseOrThrow(_response.body, {
|
|
1418
|
+
unrecognizedObjectKeys: "passthrough",
|
|
1419
|
+
allowUnrecognizedUnionMembers: true,
|
|
1420
|
+
allowUnrecognizedEnumValues: true,
|
|
1421
|
+
skipValidation: true,
|
|
1422
|
+
breadcrumbsPrefix: ["response"],
|
|
1423
|
+
}),
|
|
1424
|
+
rawResponse: _response.rawResponse,
|
|
1425
|
+
};
|
|
1229
1426
|
}
|
|
1230
1427
|
if (_response.error.reason === "status-code") {
|
|
1231
1428
|
switch (_response.error.statusCode) {
|
|
@@ -1236,7 +1433,7 @@ class Features {
|
|
|
1236
1433
|
allowUnrecognizedEnumValues: true,
|
|
1237
1434
|
skipValidation: true,
|
|
1238
1435
|
breadcrumbsPrefix: ["response"],
|
|
1239
|
-
}));
|
|
1436
|
+
}), _response.rawResponse);
|
|
1240
1437
|
case 401:
|
|
1241
1438
|
throw new Schematic.UnauthorizedError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
1242
1439
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -1244,7 +1441,7 @@ class Features {
|
|
|
1244
1441
|
allowUnrecognizedEnumValues: true,
|
|
1245
1442
|
skipValidation: true,
|
|
1246
1443
|
breadcrumbsPrefix: ["response"],
|
|
1247
|
-
}));
|
|
1444
|
+
}), _response.rawResponse);
|
|
1248
1445
|
case 403:
|
|
1249
1446
|
throw new Schematic.ForbiddenError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
1250
1447
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -1252,7 +1449,15 @@ class Features {
|
|
|
1252
1449
|
allowUnrecognizedEnumValues: true,
|
|
1253
1450
|
skipValidation: true,
|
|
1254
1451
|
breadcrumbsPrefix: ["response"],
|
|
1255
|
-
}));
|
|
1452
|
+
}), _response.rawResponse);
|
|
1453
|
+
case 404:
|
|
1454
|
+
throw new Schematic.NotFoundError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
1455
|
+
unrecognizedObjectKeys: "passthrough",
|
|
1456
|
+
allowUnrecognizedUnionMembers: true,
|
|
1457
|
+
allowUnrecognizedEnumValues: true,
|
|
1458
|
+
skipValidation: true,
|
|
1459
|
+
breadcrumbsPrefix: ["response"],
|
|
1460
|
+
}), _response.rawResponse);
|
|
1256
1461
|
case 500:
|
|
1257
1462
|
throw new Schematic.InternalServerError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
1258
1463
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -1260,11 +1465,12 @@ class Features {
|
|
|
1260
1465
|
allowUnrecognizedEnumValues: true,
|
|
1261
1466
|
skipValidation: true,
|
|
1262
1467
|
breadcrumbsPrefix: ["response"],
|
|
1263
|
-
}));
|
|
1468
|
+
}), _response.rawResponse);
|
|
1264
1469
|
default:
|
|
1265
1470
|
throw new errors.SchematicError({
|
|
1266
1471
|
statusCode: _response.error.statusCode,
|
|
1267
1472
|
body: _response.error.body,
|
|
1473
|
+
rawResponse: _response.rawResponse,
|
|
1268
1474
|
});
|
|
1269
1475
|
}
|
|
1270
1476
|
}
|
|
@@ -1273,12 +1479,14 @@ class Features {
|
|
|
1273
1479
|
throw new errors.SchematicError({
|
|
1274
1480
|
statusCode: _response.error.statusCode,
|
|
1275
1481
|
body: _response.error.rawBody,
|
|
1482
|
+
rawResponse: _response.rawResponse,
|
|
1276
1483
|
});
|
|
1277
1484
|
case "timeout":
|
|
1278
|
-
throw new errors.SchematicTimeoutError();
|
|
1485
|
+
throw new errors.SchematicTimeoutError("Timeout exceeded when calling POST /flags.");
|
|
1279
1486
|
case "unknown":
|
|
1280
1487
|
throw new errors.SchematicError({
|
|
1281
1488
|
message: _response.error.errorMessage,
|
|
1489
|
+
rawResponse: _response.rawResponse,
|
|
1282
1490
|
});
|
|
1283
1491
|
}
|
|
1284
1492
|
});
|
|
@@ -1296,12 +1504,15 @@ class Features {
|
|
|
1296
1504
|
* await client.features.getFlag("flag_id")
|
|
1297
1505
|
*/
|
|
1298
1506
|
getFlag(flagId, requestOptions) {
|
|
1299
|
-
|
|
1507
|
+
return core.HttpResponsePromise.fromPromise(this.__getFlag(flagId, requestOptions));
|
|
1508
|
+
}
|
|
1509
|
+
__getFlag(flagId, requestOptions) {
|
|
1300
1510
|
return __awaiter(this, void 0, void 0, function* () {
|
|
1511
|
+
var _a, _b, _c;
|
|
1301
1512
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
1302
|
-
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.
|
|
1513
|
+
url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.SchematicEnvironment.Default, `flags/${encodeURIComponent(flagId)}`),
|
|
1303
1514
|
method: "GET",
|
|
1304
|
-
headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@schematichq/schematic-typescript-node", "X-Fern-SDK-Version": "1.1.
|
|
1515
|
+
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@schematichq/schematic-typescript-node", "X-Fern-SDK-Version": "1.1.11", "User-Agent": "@schematichq/schematic-typescript-node/1.1.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
1305
1516
|
contentType: "application/json",
|
|
1306
1517
|
requestType: "json",
|
|
1307
1518
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
@@ -1309,13 +1520,16 @@ class Features {
|
|
|
1309
1520
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
1310
1521
|
});
|
|
1311
1522
|
if (_response.ok) {
|
|
1312
|
-
return
|
|
1313
|
-
|
|
1314
|
-
|
|
1315
|
-
|
|
1316
|
-
|
|
1317
|
-
|
|
1318
|
-
|
|
1523
|
+
return {
|
|
1524
|
+
data: serializers.GetFlagResponse.parseOrThrow(_response.body, {
|
|
1525
|
+
unrecognizedObjectKeys: "passthrough",
|
|
1526
|
+
allowUnrecognizedUnionMembers: true,
|
|
1527
|
+
allowUnrecognizedEnumValues: true,
|
|
1528
|
+
skipValidation: true,
|
|
1529
|
+
breadcrumbsPrefix: ["response"],
|
|
1530
|
+
}),
|
|
1531
|
+
rawResponse: _response.rawResponse,
|
|
1532
|
+
};
|
|
1319
1533
|
}
|
|
1320
1534
|
if (_response.error.reason === "status-code") {
|
|
1321
1535
|
switch (_response.error.statusCode) {
|
|
@@ -1326,7 +1540,7 @@ class Features {
|
|
|
1326
1540
|
allowUnrecognizedEnumValues: true,
|
|
1327
1541
|
skipValidation: true,
|
|
1328
1542
|
breadcrumbsPrefix: ["response"],
|
|
1329
|
-
}));
|
|
1543
|
+
}), _response.rawResponse);
|
|
1330
1544
|
case 403:
|
|
1331
1545
|
throw new Schematic.ForbiddenError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
1332
1546
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -1334,7 +1548,7 @@ class Features {
|
|
|
1334
1548
|
allowUnrecognizedEnumValues: true,
|
|
1335
1549
|
skipValidation: true,
|
|
1336
1550
|
breadcrumbsPrefix: ["response"],
|
|
1337
|
-
}));
|
|
1551
|
+
}), _response.rawResponse);
|
|
1338
1552
|
case 404:
|
|
1339
1553
|
throw new Schematic.NotFoundError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
1340
1554
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -1342,7 +1556,7 @@ class Features {
|
|
|
1342
1556
|
allowUnrecognizedEnumValues: true,
|
|
1343
1557
|
skipValidation: true,
|
|
1344
1558
|
breadcrumbsPrefix: ["response"],
|
|
1345
|
-
}));
|
|
1559
|
+
}), _response.rawResponse);
|
|
1346
1560
|
case 500:
|
|
1347
1561
|
throw new Schematic.InternalServerError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
1348
1562
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -1350,11 +1564,12 @@ class Features {
|
|
|
1350
1564
|
allowUnrecognizedEnumValues: true,
|
|
1351
1565
|
skipValidation: true,
|
|
1352
1566
|
breadcrumbsPrefix: ["response"],
|
|
1353
|
-
}));
|
|
1567
|
+
}), _response.rawResponse);
|
|
1354
1568
|
default:
|
|
1355
1569
|
throw new errors.SchematicError({
|
|
1356
1570
|
statusCode: _response.error.statusCode,
|
|
1357
1571
|
body: _response.error.body,
|
|
1572
|
+
rawResponse: _response.rawResponse,
|
|
1358
1573
|
});
|
|
1359
1574
|
}
|
|
1360
1575
|
}
|
|
@@ -1363,12 +1578,14 @@ class Features {
|
|
|
1363
1578
|
throw new errors.SchematicError({
|
|
1364
1579
|
statusCode: _response.error.statusCode,
|
|
1365
1580
|
body: _response.error.rawBody,
|
|
1581
|
+
rawResponse: _response.rawResponse,
|
|
1366
1582
|
});
|
|
1367
1583
|
case "timeout":
|
|
1368
|
-
throw new errors.SchematicTimeoutError();
|
|
1584
|
+
throw new errors.SchematicTimeoutError("Timeout exceeded when calling GET /flags/{flag_id}.");
|
|
1369
1585
|
case "unknown":
|
|
1370
1586
|
throw new errors.SchematicError({
|
|
1371
1587
|
message: _response.error.errorMessage,
|
|
1588
|
+
rawResponse: _response.rawResponse,
|
|
1372
1589
|
});
|
|
1373
1590
|
}
|
|
1374
1591
|
});
|
|
@@ -1394,12 +1611,15 @@ class Features {
|
|
|
1394
1611
|
* })
|
|
1395
1612
|
*/
|
|
1396
1613
|
updateFlag(flagId, request, requestOptions) {
|
|
1397
|
-
|
|
1614
|
+
return core.HttpResponsePromise.fromPromise(this.__updateFlag(flagId, request, requestOptions));
|
|
1615
|
+
}
|
|
1616
|
+
__updateFlag(flagId, request, requestOptions) {
|
|
1398
1617
|
return __awaiter(this, void 0, void 0, function* () {
|
|
1618
|
+
var _a, _b, _c;
|
|
1399
1619
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
1400
|
-
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.
|
|
1620
|
+
url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.SchematicEnvironment.Default, `flags/${encodeURIComponent(flagId)}`),
|
|
1401
1621
|
method: "PUT",
|
|
1402
|
-
headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@schematichq/schematic-typescript-node", "X-Fern-SDK-Version": "1.1.
|
|
1622
|
+
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@schematichq/schematic-typescript-node", "X-Fern-SDK-Version": "1.1.11", "User-Agent": "@schematichq/schematic-typescript-node/1.1.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
1403
1623
|
contentType: "application/json",
|
|
1404
1624
|
requestType: "json",
|
|
1405
1625
|
body: serializers.CreateFlagRequestBody.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
|
@@ -1408,13 +1628,16 @@ class Features {
|
|
|
1408
1628
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
1409
1629
|
});
|
|
1410
1630
|
if (_response.ok) {
|
|
1411
|
-
return
|
|
1412
|
-
|
|
1413
|
-
|
|
1414
|
-
|
|
1415
|
-
|
|
1416
|
-
|
|
1417
|
-
|
|
1631
|
+
return {
|
|
1632
|
+
data: serializers.UpdateFlagResponse.parseOrThrow(_response.body, {
|
|
1633
|
+
unrecognizedObjectKeys: "passthrough",
|
|
1634
|
+
allowUnrecognizedUnionMembers: true,
|
|
1635
|
+
allowUnrecognizedEnumValues: true,
|
|
1636
|
+
skipValidation: true,
|
|
1637
|
+
breadcrumbsPrefix: ["response"],
|
|
1638
|
+
}),
|
|
1639
|
+
rawResponse: _response.rawResponse,
|
|
1640
|
+
};
|
|
1418
1641
|
}
|
|
1419
1642
|
if (_response.error.reason === "status-code") {
|
|
1420
1643
|
switch (_response.error.statusCode) {
|
|
@@ -1425,7 +1648,7 @@ class Features {
|
|
|
1425
1648
|
allowUnrecognizedEnumValues: true,
|
|
1426
1649
|
skipValidation: true,
|
|
1427
1650
|
breadcrumbsPrefix: ["response"],
|
|
1428
|
-
}));
|
|
1651
|
+
}), _response.rawResponse);
|
|
1429
1652
|
case 401:
|
|
1430
1653
|
throw new Schematic.UnauthorizedError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
1431
1654
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -1433,7 +1656,7 @@ class Features {
|
|
|
1433
1656
|
allowUnrecognizedEnumValues: true,
|
|
1434
1657
|
skipValidation: true,
|
|
1435
1658
|
breadcrumbsPrefix: ["response"],
|
|
1436
|
-
}));
|
|
1659
|
+
}), _response.rawResponse);
|
|
1437
1660
|
case 403:
|
|
1438
1661
|
throw new Schematic.ForbiddenError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
1439
1662
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -1441,7 +1664,7 @@ class Features {
|
|
|
1441
1664
|
allowUnrecognizedEnumValues: true,
|
|
1442
1665
|
skipValidation: true,
|
|
1443
1666
|
breadcrumbsPrefix: ["response"],
|
|
1444
|
-
}));
|
|
1667
|
+
}), _response.rawResponse);
|
|
1445
1668
|
case 404:
|
|
1446
1669
|
throw new Schematic.NotFoundError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
1447
1670
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -1449,7 +1672,7 @@ class Features {
|
|
|
1449
1672
|
allowUnrecognizedEnumValues: true,
|
|
1450
1673
|
skipValidation: true,
|
|
1451
1674
|
breadcrumbsPrefix: ["response"],
|
|
1452
|
-
}));
|
|
1675
|
+
}), _response.rawResponse);
|
|
1453
1676
|
case 500:
|
|
1454
1677
|
throw new Schematic.InternalServerError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
1455
1678
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -1457,11 +1680,12 @@ class Features {
|
|
|
1457
1680
|
allowUnrecognizedEnumValues: true,
|
|
1458
1681
|
skipValidation: true,
|
|
1459
1682
|
breadcrumbsPrefix: ["response"],
|
|
1460
|
-
}));
|
|
1683
|
+
}), _response.rawResponse);
|
|
1461
1684
|
default:
|
|
1462
1685
|
throw new errors.SchematicError({
|
|
1463
1686
|
statusCode: _response.error.statusCode,
|
|
1464
1687
|
body: _response.error.body,
|
|
1688
|
+
rawResponse: _response.rawResponse,
|
|
1465
1689
|
});
|
|
1466
1690
|
}
|
|
1467
1691
|
}
|
|
@@ -1470,12 +1694,14 @@ class Features {
|
|
|
1470
1694
|
throw new errors.SchematicError({
|
|
1471
1695
|
statusCode: _response.error.statusCode,
|
|
1472
1696
|
body: _response.error.rawBody,
|
|
1697
|
+
rawResponse: _response.rawResponse,
|
|
1473
1698
|
});
|
|
1474
1699
|
case "timeout":
|
|
1475
|
-
throw new errors.SchematicTimeoutError();
|
|
1700
|
+
throw new errors.SchematicTimeoutError("Timeout exceeded when calling PUT /flags/{flag_id}.");
|
|
1476
1701
|
case "unknown":
|
|
1477
1702
|
throw new errors.SchematicError({
|
|
1478
1703
|
message: _response.error.errorMessage,
|
|
1704
|
+
rawResponse: _response.rawResponse,
|
|
1479
1705
|
});
|
|
1480
1706
|
}
|
|
1481
1707
|
});
|
|
@@ -1487,18 +1713,22 @@ class Features {
|
|
|
1487
1713
|
* @throws {@link Schematic.BadRequestError}
|
|
1488
1714
|
* @throws {@link Schematic.UnauthorizedError}
|
|
1489
1715
|
* @throws {@link Schematic.ForbiddenError}
|
|
1716
|
+
* @throws {@link Schematic.NotFoundError}
|
|
1490
1717
|
* @throws {@link Schematic.InternalServerError}
|
|
1491
1718
|
*
|
|
1492
1719
|
* @example
|
|
1493
1720
|
* await client.features.deleteFlag("flag_id")
|
|
1494
1721
|
*/
|
|
1495
1722
|
deleteFlag(flagId, requestOptions) {
|
|
1496
|
-
|
|
1723
|
+
return core.HttpResponsePromise.fromPromise(this.__deleteFlag(flagId, requestOptions));
|
|
1724
|
+
}
|
|
1725
|
+
__deleteFlag(flagId, requestOptions) {
|
|
1497
1726
|
return __awaiter(this, void 0, void 0, function* () {
|
|
1727
|
+
var _a, _b, _c;
|
|
1498
1728
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
1499
|
-
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.
|
|
1729
|
+
url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.SchematicEnvironment.Default, `flags/${encodeURIComponent(flagId)}`),
|
|
1500
1730
|
method: "DELETE",
|
|
1501
|
-
headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@schematichq/schematic-typescript-node", "X-Fern-SDK-Version": "1.1.
|
|
1731
|
+
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@schematichq/schematic-typescript-node", "X-Fern-SDK-Version": "1.1.11", "User-Agent": "@schematichq/schematic-typescript-node/1.1.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
1502
1732
|
contentType: "application/json",
|
|
1503
1733
|
requestType: "json",
|
|
1504
1734
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
@@ -1506,13 +1736,16 @@ class Features {
|
|
|
1506
1736
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
1507
1737
|
});
|
|
1508
1738
|
if (_response.ok) {
|
|
1509
|
-
return
|
|
1510
|
-
|
|
1511
|
-
|
|
1512
|
-
|
|
1513
|
-
|
|
1514
|
-
|
|
1515
|
-
|
|
1739
|
+
return {
|
|
1740
|
+
data: serializers.DeleteFlagResponse.parseOrThrow(_response.body, {
|
|
1741
|
+
unrecognizedObjectKeys: "passthrough",
|
|
1742
|
+
allowUnrecognizedUnionMembers: true,
|
|
1743
|
+
allowUnrecognizedEnumValues: true,
|
|
1744
|
+
skipValidation: true,
|
|
1745
|
+
breadcrumbsPrefix: ["response"],
|
|
1746
|
+
}),
|
|
1747
|
+
rawResponse: _response.rawResponse,
|
|
1748
|
+
};
|
|
1516
1749
|
}
|
|
1517
1750
|
if (_response.error.reason === "status-code") {
|
|
1518
1751
|
switch (_response.error.statusCode) {
|
|
@@ -1523,7 +1756,7 @@ class Features {
|
|
|
1523
1756
|
allowUnrecognizedEnumValues: true,
|
|
1524
1757
|
skipValidation: true,
|
|
1525
1758
|
breadcrumbsPrefix: ["response"],
|
|
1526
|
-
}));
|
|
1759
|
+
}), _response.rawResponse);
|
|
1527
1760
|
case 401:
|
|
1528
1761
|
throw new Schematic.UnauthorizedError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
1529
1762
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -1531,7 +1764,7 @@ class Features {
|
|
|
1531
1764
|
allowUnrecognizedEnumValues: true,
|
|
1532
1765
|
skipValidation: true,
|
|
1533
1766
|
breadcrumbsPrefix: ["response"],
|
|
1534
|
-
}));
|
|
1767
|
+
}), _response.rawResponse);
|
|
1535
1768
|
case 403:
|
|
1536
1769
|
throw new Schematic.ForbiddenError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
1537
1770
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -1539,7 +1772,15 @@ class Features {
|
|
|
1539
1772
|
allowUnrecognizedEnumValues: true,
|
|
1540
1773
|
skipValidation: true,
|
|
1541
1774
|
breadcrumbsPrefix: ["response"],
|
|
1542
|
-
}));
|
|
1775
|
+
}), _response.rawResponse);
|
|
1776
|
+
case 404:
|
|
1777
|
+
throw new Schematic.NotFoundError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
1778
|
+
unrecognizedObjectKeys: "passthrough",
|
|
1779
|
+
allowUnrecognizedUnionMembers: true,
|
|
1780
|
+
allowUnrecognizedEnumValues: true,
|
|
1781
|
+
skipValidation: true,
|
|
1782
|
+
breadcrumbsPrefix: ["response"],
|
|
1783
|
+
}), _response.rawResponse);
|
|
1543
1784
|
case 500:
|
|
1544
1785
|
throw new Schematic.InternalServerError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
1545
1786
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -1547,11 +1788,12 @@ class Features {
|
|
|
1547
1788
|
allowUnrecognizedEnumValues: true,
|
|
1548
1789
|
skipValidation: true,
|
|
1549
1790
|
breadcrumbsPrefix: ["response"],
|
|
1550
|
-
}));
|
|
1791
|
+
}), _response.rawResponse);
|
|
1551
1792
|
default:
|
|
1552
1793
|
throw new errors.SchematicError({
|
|
1553
1794
|
statusCode: _response.error.statusCode,
|
|
1554
1795
|
body: _response.error.body,
|
|
1796
|
+
rawResponse: _response.rawResponse,
|
|
1555
1797
|
});
|
|
1556
1798
|
}
|
|
1557
1799
|
}
|
|
@@ -1560,12 +1802,14 @@ class Features {
|
|
|
1560
1802
|
throw new errors.SchematicError({
|
|
1561
1803
|
statusCode: _response.error.statusCode,
|
|
1562
1804
|
body: _response.error.rawBody,
|
|
1805
|
+
rawResponse: _response.rawResponse,
|
|
1563
1806
|
});
|
|
1564
1807
|
case "timeout":
|
|
1565
|
-
throw new errors.SchematicTimeoutError();
|
|
1808
|
+
throw new errors.SchematicTimeoutError("Timeout exceeded when calling DELETE /flags/{flag_id}.");
|
|
1566
1809
|
case "unknown":
|
|
1567
1810
|
throw new errors.SchematicError({
|
|
1568
1811
|
message: _response.error.errorMessage,
|
|
1812
|
+
rawResponse: _response.rawResponse,
|
|
1569
1813
|
});
|
|
1570
1814
|
}
|
|
1571
1815
|
});
|
|
@@ -1603,12 +1847,15 @@ class Features {
|
|
|
1603
1847
|
* })
|
|
1604
1848
|
*/
|
|
1605
1849
|
updateFlagRules(flagId, request, requestOptions) {
|
|
1606
|
-
|
|
1850
|
+
return core.HttpResponsePromise.fromPromise(this.__updateFlagRules(flagId, request, requestOptions));
|
|
1851
|
+
}
|
|
1852
|
+
__updateFlagRules(flagId, request, requestOptions) {
|
|
1607
1853
|
return __awaiter(this, void 0, void 0, function* () {
|
|
1854
|
+
var _a, _b, _c;
|
|
1608
1855
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
1609
|
-
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.
|
|
1856
|
+
url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.SchematicEnvironment.Default, `flags/${encodeURIComponent(flagId)}/rules`),
|
|
1610
1857
|
method: "PUT",
|
|
1611
|
-
headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@schematichq/schematic-typescript-node", "X-Fern-SDK-Version": "1.1.
|
|
1858
|
+
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@schematichq/schematic-typescript-node", "X-Fern-SDK-Version": "1.1.11", "User-Agent": "@schematichq/schematic-typescript-node/1.1.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
1612
1859
|
contentType: "application/json",
|
|
1613
1860
|
requestType: "json",
|
|
1614
1861
|
body: serializers.UpdateFlagRulesRequestBody.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
|
@@ -1617,13 +1864,16 @@ class Features {
|
|
|
1617
1864
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
1618
1865
|
});
|
|
1619
1866
|
if (_response.ok) {
|
|
1620
|
-
return
|
|
1621
|
-
|
|
1622
|
-
|
|
1623
|
-
|
|
1624
|
-
|
|
1625
|
-
|
|
1626
|
-
|
|
1867
|
+
return {
|
|
1868
|
+
data: serializers.UpdateFlagRulesResponse.parseOrThrow(_response.body, {
|
|
1869
|
+
unrecognizedObjectKeys: "passthrough",
|
|
1870
|
+
allowUnrecognizedUnionMembers: true,
|
|
1871
|
+
allowUnrecognizedEnumValues: true,
|
|
1872
|
+
skipValidation: true,
|
|
1873
|
+
breadcrumbsPrefix: ["response"],
|
|
1874
|
+
}),
|
|
1875
|
+
rawResponse: _response.rawResponse,
|
|
1876
|
+
};
|
|
1627
1877
|
}
|
|
1628
1878
|
if (_response.error.reason === "status-code") {
|
|
1629
1879
|
switch (_response.error.statusCode) {
|
|
@@ -1634,7 +1884,7 @@ class Features {
|
|
|
1634
1884
|
allowUnrecognizedEnumValues: true,
|
|
1635
1885
|
skipValidation: true,
|
|
1636
1886
|
breadcrumbsPrefix: ["response"],
|
|
1637
|
-
}));
|
|
1887
|
+
}), _response.rawResponse);
|
|
1638
1888
|
case 401:
|
|
1639
1889
|
throw new Schematic.UnauthorizedError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
1640
1890
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -1642,7 +1892,7 @@ class Features {
|
|
|
1642
1892
|
allowUnrecognizedEnumValues: true,
|
|
1643
1893
|
skipValidation: true,
|
|
1644
1894
|
breadcrumbsPrefix: ["response"],
|
|
1645
|
-
}));
|
|
1895
|
+
}), _response.rawResponse);
|
|
1646
1896
|
case 403:
|
|
1647
1897
|
throw new Schematic.ForbiddenError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
1648
1898
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -1650,7 +1900,7 @@ class Features {
|
|
|
1650
1900
|
allowUnrecognizedEnumValues: true,
|
|
1651
1901
|
skipValidation: true,
|
|
1652
1902
|
breadcrumbsPrefix: ["response"],
|
|
1653
|
-
}));
|
|
1903
|
+
}), _response.rawResponse);
|
|
1654
1904
|
case 404:
|
|
1655
1905
|
throw new Schematic.NotFoundError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
1656
1906
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -1658,7 +1908,7 @@ class Features {
|
|
|
1658
1908
|
allowUnrecognizedEnumValues: true,
|
|
1659
1909
|
skipValidation: true,
|
|
1660
1910
|
breadcrumbsPrefix: ["response"],
|
|
1661
|
-
}));
|
|
1911
|
+
}), _response.rawResponse);
|
|
1662
1912
|
case 500:
|
|
1663
1913
|
throw new Schematic.InternalServerError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
1664
1914
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -1666,11 +1916,12 @@ class Features {
|
|
|
1666
1916
|
allowUnrecognizedEnumValues: true,
|
|
1667
1917
|
skipValidation: true,
|
|
1668
1918
|
breadcrumbsPrefix: ["response"],
|
|
1669
|
-
}));
|
|
1919
|
+
}), _response.rawResponse);
|
|
1670
1920
|
default:
|
|
1671
1921
|
throw new errors.SchematicError({
|
|
1672
1922
|
statusCode: _response.error.statusCode,
|
|
1673
1923
|
body: _response.error.body,
|
|
1924
|
+
rawResponse: _response.rawResponse,
|
|
1674
1925
|
});
|
|
1675
1926
|
}
|
|
1676
1927
|
}
|
|
@@ -1679,12 +1930,14 @@ class Features {
|
|
|
1679
1930
|
throw new errors.SchematicError({
|
|
1680
1931
|
statusCode: _response.error.statusCode,
|
|
1681
1932
|
body: _response.error.rawBody,
|
|
1933
|
+
rawResponse: _response.rawResponse,
|
|
1682
1934
|
});
|
|
1683
1935
|
case "timeout":
|
|
1684
|
-
throw new errors.SchematicTimeoutError();
|
|
1936
|
+
throw new errors.SchematicTimeoutError("Timeout exceeded when calling PUT /flags/{flag_id}/rules.");
|
|
1685
1937
|
case "unknown":
|
|
1686
1938
|
throw new errors.SchematicError({
|
|
1687
1939
|
message: _response.error.errorMessage,
|
|
1940
|
+
rawResponse: _response.rawResponse,
|
|
1688
1941
|
});
|
|
1689
1942
|
}
|
|
1690
1943
|
});
|
|
@@ -1697,18 +1950,22 @@ class Features {
|
|
|
1697
1950
|
* @throws {@link Schematic.BadRequestError}
|
|
1698
1951
|
* @throws {@link Schematic.UnauthorizedError}
|
|
1699
1952
|
* @throws {@link Schematic.ForbiddenError}
|
|
1953
|
+
* @throws {@link Schematic.NotFoundError}
|
|
1700
1954
|
* @throws {@link Schematic.InternalServerError}
|
|
1701
1955
|
*
|
|
1702
1956
|
* @example
|
|
1703
1957
|
* await client.features.checkFlag("key", {})
|
|
1704
1958
|
*/
|
|
1705
1959
|
checkFlag(key, request, requestOptions) {
|
|
1706
|
-
|
|
1960
|
+
return core.HttpResponsePromise.fromPromise(this.__checkFlag(key, request, requestOptions));
|
|
1961
|
+
}
|
|
1962
|
+
__checkFlag(key, request, requestOptions) {
|
|
1707
1963
|
return __awaiter(this, void 0, void 0, function* () {
|
|
1964
|
+
var _a, _b, _c;
|
|
1708
1965
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
1709
|
-
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.
|
|
1966
|
+
url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.SchematicEnvironment.Default, `flags/${encodeURIComponent(key)}/check`),
|
|
1710
1967
|
method: "POST",
|
|
1711
|
-
headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@schematichq/schematic-typescript-node", "X-Fern-SDK-Version": "1.1.
|
|
1968
|
+
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@schematichq/schematic-typescript-node", "X-Fern-SDK-Version": "1.1.11", "User-Agent": "@schematichq/schematic-typescript-node/1.1.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
1712
1969
|
contentType: "application/json",
|
|
1713
1970
|
requestType: "json",
|
|
1714
1971
|
body: serializers.CheckFlagRequestBody.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
|
@@ -1717,13 +1974,16 @@ class Features {
|
|
|
1717
1974
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
1718
1975
|
});
|
|
1719
1976
|
if (_response.ok) {
|
|
1720
|
-
return
|
|
1721
|
-
|
|
1722
|
-
|
|
1723
|
-
|
|
1724
|
-
|
|
1725
|
-
|
|
1726
|
-
|
|
1977
|
+
return {
|
|
1978
|
+
data: serializers.CheckFlagResponse.parseOrThrow(_response.body, {
|
|
1979
|
+
unrecognizedObjectKeys: "passthrough",
|
|
1980
|
+
allowUnrecognizedUnionMembers: true,
|
|
1981
|
+
allowUnrecognizedEnumValues: true,
|
|
1982
|
+
skipValidation: true,
|
|
1983
|
+
breadcrumbsPrefix: ["response"],
|
|
1984
|
+
}),
|
|
1985
|
+
rawResponse: _response.rawResponse,
|
|
1986
|
+
};
|
|
1727
1987
|
}
|
|
1728
1988
|
if (_response.error.reason === "status-code") {
|
|
1729
1989
|
switch (_response.error.statusCode) {
|
|
@@ -1734,7 +1994,7 @@ class Features {
|
|
|
1734
1994
|
allowUnrecognizedEnumValues: true,
|
|
1735
1995
|
skipValidation: true,
|
|
1736
1996
|
breadcrumbsPrefix: ["response"],
|
|
1737
|
-
}));
|
|
1997
|
+
}), _response.rawResponse);
|
|
1738
1998
|
case 401:
|
|
1739
1999
|
throw new Schematic.UnauthorizedError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
1740
2000
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -1742,7 +2002,7 @@ class Features {
|
|
|
1742
2002
|
allowUnrecognizedEnumValues: true,
|
|
1743
2003
|
skipValidation: true,
|
|
1744
2004
|
breadcrumbsPrefix: ["response"],
|
|
1745
|
-
}));
|
|
2005
|
+
}), _response.rawResponse);
|
|
1746
2006
|
case 403:
|
|
1747
2007
|
throw new Schematic.ForbiddenError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
1748
2008
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -1750,7 +2010,15 @@ class Features {
|
|
|
1750
2010
|
allowUnrecognizedEnumValues: true,
|
|
1751
2011
|
skipValidation: true,
|
|
1752
2012
|
breadcrumbsPrefix: ["response"],
|
|
1753
|
-
}));
|
|
2013
|
+
}), _response.rawResponse);
|
|
2014
|
+
case 404:
|
|
2015
|
+
throw new Schematic.NotFoundError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
2016
|
+
unrecognizedObjectKeys: "passthrough",
|
|
2017
|
+
allowUnrecognizedUnionMembers: true,
|
|
2018
|
+
allowUnrecognizedEnumValues: true,
|
|
2019
|
+
skipValidation: true,
|
|
2020
|
+
breadcrumbsPrefix: ["response"],
|
|
2021
|
+
}), _response.rawResponse);
|
|
1754
2022
|
case 500:
|
|
1755
2023
|
throw new Schematic.InternalServerError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
1756
2024
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -1758,11 +2026,12 @@ class Features {
|
|
|
1758
2026
|
allowUnrecognizedEnumValues: true,
|
|
1759
2027
|
skipValidation: true,
|
|
1760
2028
|
breadcrumbsPrefix: ["response"],
|
|
1761
|
-
}));
|
|
2029
|
+
}), _response.rawResponse);
|
|
1762
2030
|
default:
|
|
1763
2031
|
throw new errors.SchematicError({
|
|
1764
2032
|
statusCode: _response.error.statusCode,
|
|
1765
2033
|
body: _response.error.body,
|
|
2034
|
+
rawResponse: _response.rawResponse,
|
|
1766
2035
|
});
|
|
1767
2036
|
}
|
|
1768
2037
|
}
|
|
@@ -1771,12 +2040,14 @@ class Features {
|
|
|
1771
2040
|
throw new errors.SchematicError({
|
|
1772
2041
|
statusCode: _response.error.statusCode,
|
|
1773
2042
|
body: _response.error.rawBody,
|
|
2043
|
+
rawResponse: _response.rawResponse,
|
|
1774
2044
|
});
|
|
1775
2045
|
case "timeout":
|
|
1776
|
-
throw new errors.SchematicTimeoutError();
|
|
2046
|
+
throw new errors.SchematicTimeoutError("Timeout exceeded when calling POST /flags/{key}/check.");
|
|
1777
2047
|
case "unknown":
|
|
1778
2048
|
throw new errors.SchematicError({
|
|
1779
2049
|
message: _response.error.errorMessage,
|
|
2050
|
+
rawResponse: _response.rawResponse,
|
|
1780
2051
|
});
|
|
1781
2052
|
}
|
|
1782
2053
|
});
|
|
@@ -1788,18 +2059,22 @@ class Features {
|
|
|
1788
2059
|
* @throws {@link Schematic.BadRequestError}
|
|
1789
2060
|
* @throws {@link Schematic.UnauthorizedError}
|
|
1790
2061
|
* @throws {@link Schematic.ForbiddenError}
|
|
2062
|
+
* @throws {@link Schematic.NotFoundError}
|
|
1791
2063
|
* @throws {@link Schematic.InternalServerError}
|
|
1792
2064
|
*
|
|
1793
2065
|
* @example
|
|
1794
2066
|
* await client.features.checkFlags({})
|
|
1795
2067
|
*/
|
|
1796
2068
|
checkFlags(request, requestOptions) {
|
|
1797
|
-
|
|
2069
|
+
return core.HttpResponsePromise.fromPromise(this.__checkFlags(request, requestOptions));
|
|
2070
|
+
}
|
|
2071
|
+
__checkFlags(request, requestOptions) {
|
|
1798
2072
|
return __awaiter(this, void 0, void 0, function* () {
|
|
2073
|
+
var _a, _b, _c;
|
|
1799
2074
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
1800
|
-
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.
|
|
2075
|
+
url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.SchematicEnvironment.Default, "flags/check"),
|
|
1801
2076
|
method: "POST",
|
|
1802
|
-
headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@schematichq/schematic-typescript-node", "X-Fern-SDK-Version": "1.1.
|
|
2077
|
+
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@schematichq/schematic-typescript-node", "X-Fern-SDK-Version": "1.1.11", "User-Agent": "@schematichq/schematic-typescript-node/1.1.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
1803
2078
|
contentType: "application/json",
|
|
1804
2079
|
requestType: "json",
|
|
1805
2080
|
body: serializers.CheckFlagRequestBody.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
|
@@ -1808,13 +2083,16 @@ class Features {
|
|
|
1808
2083
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
1809
2084
|
});
|
|
1810
2085
|
if (_response.ok) {
|
|
1811
|
-
return
|
|
1812
|
-
|
|
1813
|
-
|
|
1814
|
-
|
|
1815
|
-
|
|
1816
|
-
|
|
1817
|
-
|
|
2086
|
+
return {
|
|
2087
|
+
data: serializers.CheckFlagsResponse.parseOrThrow(_response.body, {
|
|
2088
|
+
unrecognizedObjectKeys: "passthrough",
|
|
2089
|
+
allowUnrecognizedUnionMembers: true,
|
|
2090
|
+
allowUnrecognizedEnumValues: true,
|
|
2091
|
+
skipValidation: true,
|
|
2092
|
+
breadcrumbsPrefix: ["response"],
|
|
2093
|
+
}),
|
|
2094
|
+
rawResponse: _response.rawResponse,
|
|
2095
|
+
};
|
|
1818
2096
|
}
|
|
1819
2097
|
if (_response.error.reason === "status-code") {
|
|
1820
2098
|
switch (_response.error.statusCode) {
|
|
@@ -1825,7 +2103,7 @@ class Features {
|
|
|
1825
2103
|
allowUnrecognizedEnumValues: true,
|
|
1826
2104
|
skipValidation: true,
|
|
1827
2105
|
breadcrumbsPrefix: ["response"],
|
|
1828
|
-
}));
|
|
2106
|
+
}), _response.rawResponse);
|
|
1829
2107
|
case 401:
|
|
1830
2108
|
throw new Schematic.UnauthorizedError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
1831
2109
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -1833,7 +2111,7 @@ class Features {
|
|
|
1833
2111
|
allowUnrecognizedEnumValues: true,
|
|
1834
2112
|
skipValidation: true,
|
|
1835
2113
|
breadcrumbsPrefix: ["response"],
|
|
1836
|
-
}));
|
|
2114
|
+
}), _response.rawResponse);
|
|
1837
2115
|
case 403:
|
|
1838
2116
|
throw new Schematic.ForbiddenError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
1839
2117
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -1841,7 +2119,15 @@ class Features {
|
|
|
1841
2119
|
allowUnrecognizedEnumValues: true,
|
|
1842
2120
|
skipValidation: true,
|
|
1843
2121
|
breadcrumbsPrefix: ["response"],
|
|
1844
|
-
}));
|
|
2122
|
+
}), _response.rawResponse);
|
|
2123
|
+
case 404:
|
|
2124
|
+
throw new Schematic.NotFoundError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
2125
|
+
unrecognizedObjectKeys: "passthrough",
|
|
2126
|
+
allowUnrecognizedUnionMembers: true,
|
|
2127
|
+
allowUnrecognizedEnumValues: true,
|
|
2128
|
+
skipValidation: true,
|
|
2129
|
+
breadcrumbsPrefix: ["response"],
|
|
2130
|
+
}), _response.rawResponse);
|
|
1845
2131
|
case 500:
|
|
1846
2132
|
throw new Schematic.InternalServerError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
1847
2133
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -1849,11 +2135,12 @@ class Features {
|
|
|
1849
2135
|
allowUnrecognizedEnumValues: true,
|
|
1850
2136
|
skipValidation: true,
|
|
1851
2137
|
breadcrumbsPrefix: ["response"],
|
|
1852
|
-
}));
|
|
2138
|
+
}), _response.rawResponse);
|
|
1853
2139
|
default:
|
|
1854
2140
|
throw new errors.SchematicError({
|
|
1855
2141
|
statusCode: _response.error.statusCode,
|
|
1856
2142
|
body: _response.error.body,
|
|
2143
|
+
rawResponse: _response.rawResponse,
|
|
1857
2144
|
});
|
|
1858
2145
|
}
|
|
1859
2146
|
}
|
|
@@ -1862,12 +2149,14 @@ class Features {
|
|
|
1862
2149
|
throw new errors.SchematicError({
|
|
1863
2150
|
statusCode: _response.error.statusCode,
|
|
1864
2151
|
body: _response.error.rawBody,
|
|
2152
|
+
rawResponse: _response.rawResponse,
|
|
1865
2153
|
});
|
|
1866
2154
|
case "timeout":
|
|
1867
|
-
throw new errors.SchematicTimeoutError();
|
|
2155
|
+
throw new errors.SchematicTimeoutError("Timeout exceeded when calling POST /flags/check.");
|
|
1868
2156
|
case "unknown":
|
|
1869
2157
|
throw new errors.SchematicError({
|
|
1870
2158
|
message: _response.error.errorMessage,
|
|
2159
|
+
rawResponse: _response.rawResponse,
|
|
1871
2160
|
});
|
|
1872
2161
|
}
|
|
1873
2162
|
});
|
|
@@ -1879,14 +2168,18 @@ class Features {
|
|
|
1879
2168
|
* @throws {@link Schematic.BadRequestError}
|
|
1880
2169
|
* @throws {@link Schematic.UnauthorizedError}
|
|
1881
2170
|
* @throws {@link Schematic.ForbiddenError}
|
|
2171
|
+
* @throws {@link Schematic.NotFoundError}
|
|
1882
2172
|
* @throws {@link Schematic.InternalServerError}
|
|
1883
2173
|
*
|
|
1884
2174
|
* @example
|
|
1885
2175
|
* await client.features.countFlags()
|
|
1886
2176
|
*/
|
|
1887
2177
|
countFlags(request = {}, requestOptions) {
|
|
1888
|
-
|
|
1889
|
-
|
|
2178
|
+
return core.HttpResponsePromise.fromPromise(this.__countFlags(request, requestOptions));
|
|
2179
|
+
}
|
|
2180
|
+
__countFlags() {
|
|
2181
|
+
return __awaiter(this, arguments, void 0, function* (request = {}, requestOptions) {
|
|
2182
|
+
var _a, _b, _c;
|
|
1890
2183
|
const { featureId, ids, q, limit, offset } = request;
|
|
1891
2184
|
const _queryParams = {};
|
|
1892
2185
|
if (featureId != null) {
|
|
@@ -1910,9 +2203,9 @@ class Features {
|
|
|
1910
2203
|
_queryParams["offset"] = offset.toString();
|
|
1911
2204
|
}
|
|
1912
2205
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
1913
|
-
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.
|
|
2206
|
+
url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.SchematicEnvironment.Default, "flags/count"),
|
|
1914
2207
|
method: "GET",
|
|
1915
|
-
headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@schematichq/schematic-typescript-node", "X-Fern-SDK-Version": "1.1.
|
|
2208
|
+
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@schematichq/schematic-typescript-node", "X-Fern-SDK-Version": "1.1.11", "User-Agent": "@schematichq/schematic-typescript-node/1.1.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
1916
2209
|
contentType: "application/json",
|
|
1917
2210
|
queryParameters: _queryParams,
|
|
1918
2211
|
requestType: "json",
|
|
@@ -1921,13 +2214,16 @@ class Features {
|
|
|
1921
2214
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
1922
2215
|
});
|
|
1923
2216
|
if (_response.ok) {
|
|
1924
|
-
return
|
|
1925
|
-
|
|
1926
|
-
|
|
1927
|
-
|
|
1928
|
-
|
|
1929
|
-
|
|
1930
|
-
|
|
2217
|
+
return {
|
|
2218
|
+
data: serializers.CountFlagsResponse.parseOrThrow(_response.body, {
|
|
2219
|
+
unrecognizedObjectKeys: "passthrough",
|
|
2220
|
+
allowUnrecognizedUnionMembers: true,
|
|
2221
|
+
allowUnrecognizedEnumValues: true,
|
|
2222
|
+
skipValidation: true,
|
|
2223
|
+
breadcrumbsPrefix: ["response"],
|
|
2224
|
+
}),
|
|
2225
|
+
rawResponse: _response.rawResponse,
|
|
2226
|
+
};
|
|
1931
2227
|
}
|
|
1932
2228
|
if (_response.error.reason === "status-code") {
|
|
1933
2229
|
switch (_response.error.statusCode) {
|
|
@@ -1938,7 +2234,7 @@ class Features {
|
|
|
1938
2234
|
allowUnrecognizedEnumValues: true,
|
|
1939
2235
|
skipValidation: true,
|
|
1940
2236
|
breadcrumbsPrefix: ["response"],
|
|
1941
|
-
}));
|
|
2237
|
+
}), _response.rawResponse);
|
|
1942
2238
|
case 401:
|
|
1943
2239
|
throw new Schematic.UnauthorizedError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
1944
2240
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -1946,7 +2242,7 @@ class Features {
|
|
|
1946
2242
|
allowUnrecognizedEnumValues: true,
|
|
1947
2243
|
skipValidation: true,
|
|
1948
2244
|
breadcrumbsPrefix: ["response"],
|
|
1949
|
-
}));
|
|
2245
|
+
}), _response.rawResponse);
|
|
1950
2246
|
case 403:
|
|
1951
2247
|
throw new Schematic.ForbiddenError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
1952
2248
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -1954,7 +2250,15 @@ class Features {
|
|
|
1954
2250
|
allowUnrecognizedEnumValues: true,
|
|
1955
2251
|
skipValidation: true,
|
|
1956
2252
|
breadcrumbsPrefix: ["response"],
|
|
1957
|
-
}));
|
|
2253
|
+
}), _response.rawResponse);
|
|
2254
|
+
case 404:
|
|
2255
|
+
throw new Schematic.NotFoundError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
2256
|
+
unrecognizedObjectKeys: "passthrough",
|
|
2257
|
+
allowUnrecognizedUnionMembers: true,
|
|
2258
|
+
allowUnrecognizedEnumValues: true,
|
|
2259
|
+
skipValidation: true,
|
|
2260
|
+
breadcrumbsPrefix: ["response"],
|
|
2261
|
+
}), _response.rawResponse);
|
|
1958
2262
|
case 500:
|
|
1959
2263
|
throw new Schematic.InternalServerError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
1960
2264
|
unrecognizedObjectKeys: "passthrough",
|
|
@@ -1962,11 +2266,12 @@ class Features {
|
|
|
1962
2266
|
allowUnrecognizedEnumValues: true,
|
|
1963
2267
|
skipValidation: true,
|
|
1964
2268
|
breadcrumbsPrefix: ["response"],
|
|
1965
|
-
}));
|
|
2269
|
+
}), _response.rawResponse);
|
|
1966
2270
|
default:
|
|
1967
2271
|
throw new errors.SchematicError({
|
|
1968
2272
|
statusCode: _response.error.statusCode,
|
|
1969
2273
|
body: _response.error.body,
|
|
2274
|
+
rawResponse: _response.rawResponse,
|
|
1970
2275
|
});
|
|
1971
2276
|
}
|
|
1972
2277
|
}
|
|
@@ -1975,12 +2280,14 @@ class Features {
|
|
|
1975
2280
|
throw new errors.SchematicError({
|
|
1976
2281
|
statusCode: _response.error.statusCode,
|
|
1977
2282
|
body: _response.error.rawBody,
|
|
2283
|
+
rawResponse: _response.rawResponse,
|
|
1978
2284
|
});
|
|
1979
2285
|
case "timeout":
|
|
1980
|
-
throw new errors.SchematicTimeoutError();
|
|
2286
|
+
throw new errors.SchematicTimeoutError("Timeout exceeded when calling GET /flags/count.");
|
|
1981
2287
|
case "unknown":
|
|
1982
2288
|
throw new errors.SchematicError({
|
|
1983
2289
|
message: _response.error.errorMessage,
|
|
2290
|
+
rawResponse: _response.rawResponse,
|
|
1984
2291
|
});
|
|
1985
2292
|
}
|
|
1986
2293
|
});
|