@schematichq/schematic-typescript-node 1.0.19 → 1.0.20

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.
@@ -16525,6 +16525,142 @@ function AudienceRequestBodyToJSON(value) {
16525
16525
  };
16526
16526
  }
16527
16527
 
16528
+ // src/api/models/BillingCustomerResponseData.ts
16529
+ function instanceOfBillingCustomerResponseData(value) {
16530
+ if (!("email" in value) || value["email"] === void 0)
16531
+ return false;
16532
+ if (!("externalId" in value) || value["externalId"] === void 0)
16533
+ return false;
16534
+ if (!("failedToImport" in value) || value["failedToImport"] === void 0)
16535
+ return false;
16536
+ if (!("id" in value) || value["id"] === void 0)
16537
+ return false;
16538
+ if (!("name" in value) || value["name"] === void 0)
16539
+ return false;
16540
+ if (!("updatedAt" in value) || value["updatedAt"] === void 0)
16541
+ return false;
16542
+ return true;
16543
+ }
16544
+ function BillingCustomerResponseDataFromJSON(json) {
16545
+ return BillingCustomerResponseDataFromJSONTyped(json, false);
16546
+ }
16547
+ function BillingCustomerResponseDataFromJSONTyped(json, ignoreDiscriminator) {
16548
+ if (json == null) {
16549
+ return json;
16550
+ }
16551
+ return {
16552
+ companyId: json["company_id"] == null ? void 0 : json["company_id"],
16553
+ deletedAt: json["deleted_at"] == null ? void 0 : new Date(json["deleted_at"]),
16554
+ email: json["email"],
16555
+ externalId: json["external_id"],
16556
+ failedToImport: json["failed_to_import"],
16557
+ id: json["id"],
16558
+ name: json["name"],
16559
+ updatedAt: new Date(json["updated_at"])
16560
+ };
16561
+ }
16562
+ function BillingCustomerResponseDataToJSON(value) {
16563
+ if (value == null) {
16564
+ return value;
16565
+ }
16566
+ return {
16567
+ company_id: value["companyId"],
16568
+ deleted_at: value["deletedAt"] == null ? void 0 : value["deletedAt"].toISOString(),
16569
+ email: value["email"],
16570
+ external_id: value["externalId"],
16571
+ failed_to_import: value["failedToImport"],
16572
+ id: value["id"],
16573
+ name: value["name"],
16574
+ updated_at: value["updatedAt"].toISOString()
16575
+ };
16576
+ }
16577
+
16578
+ // src/api/models/BillingCustomerSubscription.ts
16579
+ function instanceOfBillingCustomerSubscription(value) {
16580
+ if (!("totalPrice" in value) || value["totalPrice"] === void 0)
16581
+ return false;
16582
+ return true;
16583
+ }
16584
+ function BillingCustomerSubscriptionFromJSON(json) {
16585
+ return BillingCustomerSubscriptionFromJSONTyped(json, false);
16586
+ }
16587
+ function BillingCustomerSubscriptionFromJSONTyped(json, ignoreDiscriminator) {
16588
+ if (json == null) {
16589
+ return json;
16590
+ }
16591
+ return {
16592
+ expiredAt: json["expired_at"] == null ? void 0 : new Date(json["expired_at"]),
16593
+ totalPrice: json["total_price"]
16594
+ };
16595
+ }
16596
+ function BillingCustomerSubscriptionToJSON(value) {
16597
+ if (value == null) {
16598
+ return value;
16599
+ }
16600
+ return {
16601
+ expired_at: value["expiredAt"] == null ? void 0 : value["expiredAt"].toISOString(),
16602
+ total_price: value["totalPrice"]
16603
+ };
16604
+ }
16605
+
16606
+ // src/api/models/BillingCustomerWithSubscriptionsResponseData.ts
16607
+ function instanceOfBillingCustomerWithSubscriptionsResponseData(value) {
16608
+ if (!("email" in value) || value["email"] === void 0)
16609
+ return false;
16610
+ if (!("externalId" in value) || value["externalId"] === void 0)
16611
+ return false;
16612
+ if (!("failedToImport" in value) || value["failedToImport"] === void 0)
16613
+ return false;
16614
+ if (!("id" in value) || value["id"] === void 0)
16615
+ return false;
16616
+ if (!("name" in value) || value["name"] === void 0)
16617
+ return false;
16618
+ if (!("subscriptions" in value) || value["subscriptions"] === void 0)
16619
+ return false;
16620
+ if (!("updatedAt" in value) || value["updatedAt"] === void 0)
16621
+ return false;
16622
+ return true;
16623
+ }
16624
+ function BillingCustomerWithSubscriptionsResponseDataFromJSON(json) {
16625
+ return BillingCustomerWithSubscriptionsResponseDataFromJSONTyped(json, false);
16626
+ }
16627
+ function BillingCustomerWithSubscriptionsResponseDataFromJSONTyped(json, ignoreDiscriminator) {
16628
+ if (json == null) {
16629
+ return json;
16630
+ }
16631
+ return {
16632
+ companyId: json["company_id"] == null ? void 0 : json["company_id"],
16633
+ deletedAt: json["deleted_at"] == null ? void 0 : new Date(json["deleted_at"]),
16634
+ email: json["email"],
16635
+ externalId: json["external_id"],
16636
+ failedToImport: json["failed_to_import"],
16637
+ id: json["id"],
16638
+ name: json["name"],
16639
+ subscriptions: json["subscriptions"].map(
16640
+ BillingCustomerSubscriptionFromJSON
16641
+ ),
16642
+ updatedAt: new Date(json["updated_at"])
16643
+ };
16644
+ }
16645
+ function BillingCustomerWithSubscriptionsResponseDataToJSON(value) {
16646
+ if (value == null) {
16647
+ return value;
16648
+ }
16649
+ return {
16650
+ company_id: value["companyId"],
16651
+ deleted_at: value["deletedAt"] == null ? void 0 : value["deletedAt"].toISOString(),
16652
+ email: value["email"],
16653
+ external_id: value["externalId"],
16654
+ failed_to_import: value["failedToImport"],
16655
+ id: value["id"],
16656
+ name: value["name"],
16657
+ subscriptions: value["subscriptions"].map(
16658
+ BillingCustomerSubscriptionToJSON
16659
+ ),
16660
+ updated_at: value["updatedAt"].toISOString()
16661
+ };
16662
+ }
16663
+
16528
16664
  // src/api/models/BillingProductPlanResponseData.ts
16529
16665
  function instanceOfBillingProductPlanResponseData(value) {
16530
16666
  if (!("accountId" in value) || value["accountId"] === void 0)
@@ -16563,6 +16699,36 @@ function BillingProductPlanResponseDataToJSON(value) {
16563
16699
  };
16564
16700
  }
16565
16701
 
16702
+ // src/api/models/BillingProductPricing.ts
16703
+ function instanceOfBillingProductPricing(value) {
16704
+ if (!("price" in value) || value["price"] === void 0)
16705
+ return false;
16706
+ if (!("productExternalId" in value) || value["productExternalId"] === void 0)
16707
+ return false;
16708
+ return true;
16709
+ }
16710
+ function BillingProductPricingFromJSON(json) {
16711
+ return BillingProductPricingFromJSONTyped(json, false);
16712
+ }
16713
+ function BillingProductPricingFromJSONTyped(json, ignoreDiscriminator) {
16714
+ if (json == null) {
16715
+ return json;
16716
+ }
16717
+ return {
16718
+ price: json["price"],
16719
+ productExternalId: json["product_external_id"]
16720
+ };
16721
+ }
16722
+ function BillingProductPricingToJSON(value) {
16723
+ if (value == null) {
16724
+ return value;
16725
+ }
16726
+ return {
16727
+ price: value["price"],
16728
+ product_external_id: value["productExternalId"]
16729
+ };
16730
+ }
16731
+
16566
16732
  // src/api/models/BillingProductResponseData.ts
16567
16733
  function instanceOfBillingProductResponseData(value) {
16568
16734
  if (!("accountId" in value) || value["accountId"] === void 0)
@@ -18699,6 +18865,68 @@ function CountComponentsResponseToJSON(value) {
18699
18865
  };
18700
18866
  }
18701
18867
 
18868
+ // src/api/models/CountCustomersParams.ts
18869
+ function instanceOfCountCustomersParams(value) {
18870
+ return true;
18871
+ }
18872
+ function CountCustomersParamsFromJSON(json) {
18873
+ return CountCustomersParamsFromJSONTyped(json, false);
18874
+ }
18875
+ function CountCustomersParamsFromJSONTyped(json, ignoreDiscriminator) {
18876
+ if (json == null) {
18877
+ return json;
18878
+ }
18879
+ return {
18880
+ failedToImport: json["failed_to_import"] == null ? void 0 : json["failed_to_import"],
18881
+ limit: json["limit"] == null ? void 0 : json["limit"],
18882
+ name: json["name"] == null ? void 0 : json["name"],
18883
+ offset: json["offset"] == null ? void 0 : json["offset"],
18884
+ q: json["q"] == null ? void 0 : json["q"]
18885
+ };
18886
+ }
18887
+ function CountCustomersParamsToJSON(value) {
18888
+ if (value == null) {
18889
+ return value;
18890
+ }
18891
+ return {
18892
+ failed_to_import: value["failedToImport"],
18893
+ limit: value["limit"],
18894
+ name: value["name"],
18895
+ offset: value["offset"],
18896
+ q: value["q"]
18897
+ };
18898
+ }
18899
+
18900
+ // src/api/models/CountCustomersResponse.ts
18901
+ function instanceOfCountCustomersResponse(value) {
18902
+ if (!("data" in value) || value["data"] === void 0)
18903
+ return false;
18904
+ if (!("params" in value) || value["params"] === void 0)
18905
+ return false;
18906
+ return true;
18907
+ }
18908
+ function CountCustomersResponseFromJSON(json) {
18909
+ return CountCustomersResponseFromJSONTyped(json, false);
18910
+ }
18911
+ function CountCustomersResponseFromJSONTyped(json, ignoreDiscriminator) {
18912
+ if (json == null) {
18913
+ return json;
18914
+ }
18915
+ return {
18916
+ data: CountResponseFromJSON(json["data"]),
18917
+ params: CountCustomersParamsFromJSON(json["params"])
18918
+ };
18919
+ }
18920
+ function CountCustomersResponseToJSON(value) {
18921
+ if (value == null) {
18922
+ return value;
18923
+ }
18924
+ return {
18925
+ data: CountResponseToJSON(value["data"]),
18926
+ params: CountCustomersParamsToJSON(value["params"])
18927
+ };
18928
+ }
18929
+
18702
18930
  // src/api/models/CountEntityKeyDefinitionsParams.ts
18703
18931
  var CountEntityKeyDefinitionsParamsEntityTypeEnum = {
18704
18932
  Company: "company",
@@ -19589,6 +19817,50 @@ function CreateApiKeyResponseToJSON(value) {
19589
19817
  };
19590
19818
  }
19591
19819
 
19820
+ // src/api/models/CreateBillingCustomerRequestBody.ts
19821
+ function instanceOfCreateBillingCustomerRequestBody(value) {
19822
+ if (!("email" in value) || value["email"] === void 0)
19823
+ return false;
19824
+ if (!("externalId" in value) || value["externalId"] === void 0)
19825
+ return false;
19826
+ if (!("failedToImport" in value) || value["failedToImport"] === void 0)
19827
+ return false;
19828
+ if (!("meta" in value) || value["meta"] === void 0)
19829
+ return false;
19830
+ if (!("name" in value) || value["name"] === void 0)
19831
+ return false;
19832
+ return true;
19833
+ }
19834
+ function CreateBillingCustomerRequestBodyFromJSON(json) {
19835
+ return CreateBillingCustomerRequestBodyFromJSONTyped(json, false);
19836
+ }
19837
+ function CreateBillingCustomerRequestBodyFromJSONTyped(json, ignoreDiscriminator) {
19838
+ if (json == null) {
19839
+ return json;
19840
+ }
19841
+ return {
19842
+ companyId: json["company_id"] == null ? void 0 : json["company_id"],
19843
+ email: json["email"],
19844
+ externalId: json["external_id"],
19845
+ failedToImport: json["failed_to_import"],
19846
+ meta: json["meta"],
19847
+ name: json["name"]
19848
+ };
19849
+ }
19850
+ function CreateBillingCustomerRequestBodyToJSON(value) {
19851
+ if (value == null) {
19852
+ return value;
19853
+ }
19854
+ return {
19855
+ company_id: value["companyId"],
19856
+ email: value["email"],
19857
+ external_id: value["externalId"],
19858
+ failed_to_import: value["failedToImport"],
19859
+ meta: value["meta"],
19860
+ name: value["name"]
19861
+ };
19862
+ }
19863
+
19592
19864
  // src/api/models/CreateBillingProductRequestBody.ts
19593
19865
  function instanceOfCreateBillingProductRequestBody(value) {
19594
19866
  if (!("currency" in value) || value["currency"] === void 0)
@@ -19641,6 +19913,8 @@ function instanceOfCreateBillingSubscriptionsRequestBody(value) {
19641
19913
  return false;
19642
19914
  if (!("subscriptionExternalId" in value) || value["subscriptionExternalId"] === void 0)
19643
19915
  return false;
19916
+ if (!("totalPrice" in value) || value["totalPrice"] === void 0)
19917
+ return false;
19644
19918
  return true;
19645
19919
  }
19646
19920
  function CreateBillingSubscriptionsRequestBodyFromJSON(json) {
@@ -19654,8 +19928,11 @@ function CreateBillingSubscriptionsRequestBodyFromJSONTyped(json, ignoreDiscrimi
19654
19928
  customerExternalId: json["customer_external_id"],
19655
19929
  expiredAt: new Date(json["expired_at"]),
19656
19930
  interval: json["interval"] == null ? void 0 : json["interval"],
19657
- productExternalIds: json["product_external_ids"],
19658
- subscriptionExternalId: json["subscription_external_id"]
19931
+ productExternalIds: json["product_external_ids"].map(
19932
+ BillingProductPricingFromJSON
19933
+ ),
19934
+ subscriptionExternalId: json["subscription_external_id"],
19935
+ totalPrice: json["total_price"]
19659
19936
  };
19660
19937
  }
19661
19938
  function CreateBillingSubscriptionsRequestBodyToJSON(value) {
@@ -19666,8 +19943,11 @@ function CreateBillingSubscriptionsRequestBodyToJSON(value) {
19666
19943
  customer_external_id: value["customerExternalId"],
19667
19944
  expired_at: value["expiredAt"].toISOString(),
19668
19945
  interval: value["interval"],
19669
- product_external_ids: value["productExternalIds"],
19670
- subscription_external_id: value["subscriptionExternalId"]
19946
+ product_external_ids: value["productExternalIds"].map(
19947
+ BillingProductPricingToJSON
19948
+ ),
19949
+ subscription_external_id: value["subscriptionExternalId"],
19950
+ total_price: value["totalPrice"]
19671
19951
  };
19672
19952
  }
19673
19953
 
@@ -24556,6 +24836,72 @@ function ListCrmProductsResponseToJSON(value) {
24556
24836
  };
24557
24837
  }
24558
24838
 
24839
+ // src/api/models/ListCustomersParams.ts
24840
+ function instanceOfListCustomersParams(value) {
24841
+ return true;
24842
+ }
24843
+ function ListCustomersParamsFromJSON(json) {
24844
+ return ListCustomersParamsFromJSONTyped(json, false);
24845
+ }
24846
+ function ListCustomersParamsFromJSONTyped(json, ignoreDiscriminator) {
24847
+ if (json == null) {
24848
+ return json;
24849
+ }
24850
+ return {
24851
+ failedToImport: json["failed_to_import"] == null ? void 0 : json["failed_to_import"],
24852
+ limit: json["limit"] == null ? void 0 : json["limit"],
24853
+ name: json["name"] == null ? void 0 : json["name"],
24854
+ offset: json["offset"] == null ? void 0 : json["offset"],
24855
+ q: json["q"] == null ? void 0 : json["q"]
24856
+ };
24857
+ }
24858
+ function ListCustomersParamsToJSON(value) {
24859
+ if (value == null) {
24860
+ return value;
24861
+ }
24862
+ return {
24863
+ failed_to_import: value["failedToImport"],
24864
+ limit: value["limit"],
24865
+ name: value["name"],
24866
+ offset: value["offset"],
24867
+ q: value["q"]
24868
+ };
24869
+ }
24870
+
24871
+ // src/api/models/ListCustomersResponse.ts
24872
+ function instanceOfListCustomersResponse(value) {
24873
+ if (!("data" in value) || value["data"] === void 0)
24874
+ return false;
24875
+ if (!("params" in value) || value["params"] === void 0)
24876
+ return false;
24877
+ return true;
24878
+ }
24879
+ function ListCustomersResponseFromJSON(json) {
24880
+ return ListCustomersResponseFromJSONTyped(json, false);
24881
+ }
24882
+ function ListCustomersResponseFromJSONTyped(json, ignoreDiscriminator) {
24883
+ if (json == null) {
24884
+ return json;
24885
+ }
24886
+ return {
24887
+ data: json["data"].map(
24888
+ BillingCustomerWithSubscriptionsResponseDataFromJSON
24889
+ ),
24890
+ params: ListCustomersParamsFromJSON(json["params"])
24891
+ };
24892
+ }
24893
+ function ListCustomersResponseToJSON(value) {
24894
+ if (value == null) {
24895
+ return value;
24896
+ }
24897
+ return {
24898
+ data: value["data"].map(
24899
+ BillingCustomerWithSubscriptionsResponseDataToJSON
24900
+ ),
24901
+ params: ListCustomersParamsToJSON(value["params"])
24902
+ };
24903
+ }
24904
+
24559
24905
  // src/api/models/ListEntityKeyDefinitionsParams.ts
24560
24906
  var ListEntityKeyDefinitionsParamsEntityTypeEnum = {
24561
24907
  Company: "company",
@@ -26988,6 +27334,36 @@ function UpdateWebhookResponseToJSON(value) {
26988
27334
  };
26989
27335
  }
26990
27336
 
27337
+ // src/api/models/UpsertBillingCustomerResponse.ts
27338
+ function instanceOfUpsertBillingCustomerResponse(value) {
27339
+ if (!("data" in value) || value["data"] === void 0)
27340
+ return false;
27341
+ if (!("params" in value) || value["params"] === void 0)
27342
+ return false;
27343
+ return true;
27344
+ }
27345
+ function UpsertBillingCustomerResponseFromJSON(json) {
27346
+ return UpsertBillingCustomerResponseFromJSONTyped(json, false);
27347
+ }
27348
+ function UpsertBillingCustomerResponseFromJSONTyped(json, ignoreDiscriminator) {
27349
+ if (json == null) {
27350
+ return json;
27351
+ }
27352
+ return {
27353
+ data: BillingCustomerResponseDataFromJSON(json["data"]),
27354
+ params: json["params"]
27355
+ };
27356
+ }
27357
+ function UpsertBillingCustomerResponseToJSON(value) {
27358
+ if (value == null) {
27359
+ return value;
27360
+ }
27361
+ return {
27362
+ data: BillingCustomerResponseDataToJSON(value["data"]),
27363
+ params: value["params"]
27364
+ };
27365
+ }
27366
+
26991
27367
  // src/api/models/UpsertBillingProductPlanResponse.ts
26992
27368
  function instanceOfUpsertBillingProductPlanResponse(value) {
26993
27369
  if (!("data" in value) || value["data"] === void 0)
@@ -28268,6 +28644,106 @@ var AccountsApi = class extends BaseAPI {
28268
28644
 
28269
28645
  // src/api/apis/BillingApi.ts
28270
28646
  var BillingApi = class extends BaseAPI {
28647
+ /**
28648
+ * Count customers
28649
+ */
28650
+ async countCustomersRaw(requestParameters, initOverrides) {
28651
+ const queryParameters = {};
28652
+ if (requestParameters["name"] != null) {
28653
+ queryParameters["name"] = requestParameters["name"];
28654
+ }
28655
+ if (requestParameters["failedToImport"] != null) {
28656
+ queryParameters["failed_to_import"] = requestParameters["failedToImport"];
28657
+ }
28658
+ if (requestParameters["q"] != null) {
28659
+ queryParameters["q"] = requestParameters["q"];
28660
+ }
28661
+ if (requestParameters["limit"] != null) {
28662
+ queryParameters["limit"] = requestParameters["limit"];
28663
+ }
28664
+ if (requestParameters["offset"] != null) {
28665
+ queryParameters["offset"] = requestParameters["offset"];
28666
+ }
28667
+ const headerParameters = {};
28668
+ if (this.configuration && this.configuration.apiKey) {
28669
+ headerParameters["X-Schematic-Api-Key"] = await this.configuration.apiKey(
28670
+ "X-Schematic-Api-Key"
28671
+ );
28672
+ }
28673
+ const response = await this.request(
28674
+ {
28675
+ path: `/billing/customers/count`,
28676
+ method: "GET",
28677
+ headers: headerParameters,
28678
+ query: queryParameters
28679
+ },
28680
+ initOverrides
28681
+ );
28682
+ return new JSONApiResponse(
28683
+ response,
28684
+ (jsonValue) => CountCustomersResponseFromJSON(jsonValue)
28685
+ );
28686
+ }
28687
+ /**
28688
+ * Count customers
28689
+ */
28690
+ async countCustomers(requestParameters = {}, initOverrides) {
28691
+ const response = await this.countCustomersRaw(
28692
+ requestParameters,
28693
+ initOverrides
28694
+ );
28695
+ return await response.value();
28696
+ }
28697
+ /**
28698
+ * List customers
28699
+ */
28700
+ async listCustomersRaw(requestParameters, initOverrides) {
28701
+ const queryParameters = {};
28702
+ if (requestParameters["name"] != null) {
28703
+ queryParameters["name"] = requestParameters["name"];
28704
+ }
28705
+ if (requestParameters["failedToImport"] != null) {
28706
+ queryParameters["failed_to_import"] = requestParameters["failedToImport"];
28707
+ }
28708
+ if (requestParameters["q"] != null) {
28709
+ queryParameters["q"] = requestParameters["q"];
28710
+ }
28711
+ if (requestParameters["limit"] != null) {
28712
+ queryParameters["limit"] = requestParameters["limit"];
28713
+ }
28714
+ if (requestParameters["offset"] != null) {
28715
+ queryParameters["offset"] = requestParameters["offset"];
28716
+ }
28717
+ const headerParameters = {};
28718
+ if (this.configuration && this.configuration.apiKey) {
28719
+ headerParameters["X-Schematic-Api-Key"] = await this.configuration.apiKey(
28720
+ "X-Schematic-Api-Key"
28721
+ );
28722
+ }
28723
+ const response = await this.request(
28724
+ {
28725
+ path: `/billing/customers`,
28726
+ method: "GET",
28727
+ headers: headerParameters,
28728
+ query: queryParameters
28729
+ },
28730
+ initOverrides
28731
+ );
28732
+ return new JSONApiResponse(
28733
+ response,
28734
+ (jsonValue) => ListCustomersResponseFromJSON(jsonValue)
28735
+ );
28736
+ }
28737
+ /**
28738
+ * List customers
28739
+ */
28740
+ async listCustomers(requestParameters = {}, initOverrides) {
28741
+ const response = await this.listCustomersRaw(
28742
+ requestParameters,
28743
+ initOverrides
28744
+ );
28745
+ return await response.value();
28746
+ }
28271
28747
  /**
28272
28748
  * List products
28273
28749
  */
@@ -28318,6 +28794,51 @@ var BillingApi = class extends BaseAPI {
28318
28794
  );
28319
28795
  return await response.value();
28320
28796
  }
28797
+ /**
28798
+ * Upsert billing customer
28799
+ */
28800
+ async upsertBillingCustomerRaw(requestParameters, initOverrides) {
28801
+ if (requestParameters["createBillingCustomerRequestBody"] == null) {
28802
+ throw new RequiredError(
28803
+ "createBillingCustomerRequestBody",
28804
+ 'Required parameter "createBillingCustomerRequestBody" was null or undefined when calling upsertBillingCustomer().'
28805
+ );
28806
+ }
28807
+ const queryParameters = {};
28808
+ const headerParameters = {};
28809
+ headerParameters["Content-Type"] = "application/json";
28810
+ if (this.configuration && this.configuration.apiKey) {
28811
+ headerParameters["X-Schematic-Api-Key"] = await this.configuration.apiKey(
28812
+ "X-Schematic-Api-Key"
28813
+ );
28814
+ }
28815
+ const response = await this.request(
28816
+ {
28817
+ path: `/billing/customer/upsert`,
28818
+ method: "POST",
28819
+ headers: headerParameters,
28820
+ query: queryParameters,
28821
+ body: CreateBillingCustomerRequestBodyToJSON(
28822
+ requestParameters["createBillingCustomerRequestBody"]
28823
+ )
28824
+ },
28825
+ initOverrides
28826
+ );
28827
+ return new JSONApiResponse(
28828
+ response,
28829
+ (jsonValue) => UpsertBillingCustomerResponseFromJSON(jsonValue)
28830
+ );
28831
+ }
28832
+ /**
28833
+ * Upsert billing customer
28834
+ */
28835
+ async upsertBillingCustomer(requestParameters, initOverrides) {
28836
+ const response = await this.upsertBillingCustomerRaw(
28837
+ requestParameters,
28838
+ initOverrides
28839
+ );
28840
+ return await response.value();
28841
+ }
28321
28842
  /**
28322
28843
  * Upsert billing product
28323
28844
  */
@@ -34020,7 +34541,7 @@ var Schematic = class {
34020
34541
  constructor(apiKey, opts) {
34021
34542
  const { offline = false } = opts ?? {};
34022
34543
  const { basePath, flagDefaults = {} } = opts ?? {};
34023
- const version = "1.0.19";
34544
+ const version = "1.0.20";
34024
34545
  const headers = {
34025
34546
  "User-Agent": `schematic-typescript-node@v${version}`
34026
34547
  };
@@ -34162,9 +34683,21 @@ export {
34162
34683
  BASE_PATH,
34163
34684
  BaseAPI,
34164
34685
  BillingApi,
34686
+ BillingCustomerResponseDataFromJSON,
34687
+ BillingCustomerResponseDataFromJSONTyped,
34688
+ BillingCustomerResponseDataToJSON,
34689
+ BillingCustomerSubscriptionFromJSON,
34690
+ BillingCustomerSubscriptionFromJSONTyped,
34691
+ BillingCustomerSubscriptionToJSON,
34692
+ BillingCustomerWithSubscriptionsResponseDataFromJSON,
34693
+ BillingCustomerWithSubscriptionsResponseDataFromJSONTyped,
34694
+ BillingCustomerWithSubscriptionsResponseDataToJSON,
34165
34695
  BillingProductPlanResponseDataFromJSON,
34166
34696
  BillingProductPlanResponseDataFromJSONTyped,
34167
34697
  BillingProductPlanResponseDataToJSON,
34698
+ BillingProductPricingFromJSON,
34699
+ BillingProductPricingFromJSONTyped,
34700
+ BillingProductPricingToJSON,
34168
34701
  BillingProductResponseDataFromJSON,
34169
34702
  BillingProductResponseDataFromJSONTyped,
34170
34703
  BillingProductResponseDataToJSON,
@@ -34260,6 +34793,12 @@ export {
34260
34793
  CountComponentsResponseFromJSON,
34261
34794
  CountComponentsResponseFromJSONTyped,
34262
34795
  CountComponentsResponseToJSON,
34796
+ CountCustomersParamsFromJSON,
34797
+ CountCustomersParamsFromJSONTyped,
34798
+ CountCustomersParamsToJSON,
34799
+ CountCustomersResponseFromJSON,
34800
+ CountCustomersResponseFromJSONTyped,
34801
+ CountCustomersResponseToJSON,
34263
34802
  CountEntityKeyDefinitionsEntityTypeEnum,
34264
34803
  CountEntityKeyDefinitionsParamsEntityTypeEnum,
34265
34804
  CountEntityKeyDefinitionsParamsFromJSON,
@@ -34353,6 +34892,9 @@ export {
34353
34892
  CreateApiKeyResponseFromJSON,
34354
34893
  CreateApiKeyResponseFromJSONTyped,
34355
34894
  CreateApiKeyResponseToJSON,
34895
+ CreateBillingCustomerRequestBodyFromJSON,
34896
+ CreateBillingCustomerRequestBodyFromJSONTyped,
34897
+ CreateBillingCustomerRequestBodyToJSON,
34356
34898
  CreateBillingProductRequestBodyFromJSON,
34357
34899
  CreateBillingProductRequestBodyFromJSONTyped,
34358
34900
  CreateBillingProductRequestBodyToJSON,
@@ -34792,6 +35334,12 @@ export {
34792
35334
  ListCrmProductsResponseFromJSON,
34793
35335
  ListCrmProductsResponseFromJSONTyped,
34794
35336
  ListCrmProductsResponseToJSON,
35337
+ ListCustomersParamsFromJSON,
35338
+ ListCustomersParamsFromJSONTyped,
35339
+ ListCustomersParamsToJSON,
35340
+ ListCustomersResponseFromJSON,
35341
+ ListCustomersResponseFromJSONTyped,
35342
+ ListCustomersResponseToJSON,
34795
35343
  ListEntityKeyDefinitionsEntityTypeEnum,
34796
35344
  ListEntityKeyDefinitionsParamsEntityTypeEnum,
34797
35345
  ListEntityKeyDefinitionsParamsFromJSON,
@@ -35067,6 +35615,9 @@ export {
35067
35615
  UpdateWebhookResponseFromJSON,
35068
35616
  UpdateWebhookResponseFromJSONTyped,
35069
35617
  UpdateWebhookResponseToJSON,
35618
+ UpsertBillingCustomerResponseFromJSON,
35619
+ UpsertBillingCustomerResponseFromJSONTyped,
35620
+ UpsertBillingCustomerResponseToJSON,
35070
35621
  UpsertBillingProductPlanResponseFromJSON,
35071
35622
  UpsertBillingProductPlanResponseFromJSONTyped,
35072
35623
  UpsertBillingProductPlanResponseToJSON,
@@ -35140,7 +35691,11 @@ export {
35140
35691
  instanceOfApiKeyRequestResponseData,
35141
35692
  instanceOfApiKeyResponseData,
35142
35693
  instanceOfAudienceRequestBody,
35694
+ instanceOfBillingCustomerResponseData,
35695
+ instanceOfBillingCustomerSubscription,
35696
+ instanceOfBillingCustomerWithSubscriptionsResponseData,
35143
35697
  instanceOfBillingProductPlanResponseData,
35698
+ instanceOfBillingProductPricing,
35144
35699
  instanceOfBillingProductResponseData,
35145
35700
  instanceOfBillingSubscriptionResponseData,
35146
35701
  instanceOfCheckFlagOutputWithFlagKey,
@@ -35171,6 +35726,8 @@ export {
35171
35726
  instanceOfCountCompanyOverridesResponse,
35172
35727
  instanceOfCountComponentsParams,
35173
35728
  instanceOfCountComponentsResponse,
35729
+ instanceOfCountCustomersParams,
35730
+ instanceOfCountCustomersResponse,
35174
35731
  instanceOfCountEntityKeyDefinitionsParams,
35175
35732
  instanceOfCountEntityKeyDefinitionsResponse,
35176
35733
  instanceOfCountEntityTraitDefinitionsParams,
@@ -35200,6 +35757,7 @@ export {
35200
35757
  instanceOfCountWebhooksResponse,
35201
35758
  instanceOfCreateApiKeyRequestBody,
35202
35759
  instanceOfCreateApiKeyResponse,
35760
+ instanceOfCreateBillingCustomerRequestBody,
35203
35761
  instanceOfCreateBillingProductRequestBody,
35204
35762
  instanceOfCreateBillingSubscriptionsRequestBody,
35205
35763
  instanceOfCreateCompanyOverrideRequestBody,
@@ -35336,6 +35894,8 @@ export {
35336
35894
  instanceOfListComponentsResponse,
35337
35895
  instanceOfListCrmProductsParams,
35338
35896
  instanceOfListCrmProductsResponse,
35897
+ instanceOfListCustomersParams,
35898
+ instanceOfListCustomersResponse,
35339
35899
  instanceOfListEntityKeyDefinitionsParams,
35340
35900
  instanceOfListEntityKeyDefinitionsResponse,
35341
35901
  instanceOfListEntityTraitDefinitionsParams,
@@ -35419,6 +35979,7 @@ export {
35419
35979
  instanceOfUpdateRuleRequestBody,
35420
35980
  instanceOfUpdateWebhookRequestBody,
35421
35981
  instanceOfUpdateWebhookResponse,
35982
+ instanceOfUpsertBillingCustomerResponse,
35422
35983
  instanceOfUpsertBillingProductPlanResponse,
35423
35984
  instanceOfUpsertBillingProductRequestBody,
35424
35985
  instanceOfUpsertBillingProductResponse,