@schematichq/schematic-typescript-node 1.6.2 → 1.6.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (38) hide show
  1. package/dist/api/resources/billing/client/requests/CreateInvoiceRequestBody.d.ts +1 -0
  2. package/dist/api/resources/entitlements/client/requests/CreateBillingLinkedPlanEntitlementRequestBody.d.ts +1 -1
  3. package/dist/api/resources/entitlements/client/requests/CreatePlanEntitlementRequestBody.d.ts +1 -1
  4. package/dist/api/resources/entitlements/client/requests/UpdatePlanEntitlementRequestBody.d.ts +1 -1
  5. package/dist/api/types/ChangeSubscriptionInternalRequestBody.d.ts +2 -0
  6. package/dist/api/types/ChangeSubscriptionRequestBody.d.ts +2 -0
  7. package/dist/api/types/CompanyFeatureUsageExportMetadataVisibleColumnsItem.d.ts +1 -0
  8. package/dist/api/types/CreateEntitlementInBundleRequestBody.d.ts +1 -1
  9. package/dist/api/types/CreditEventLedgerResponseData.d.ts +1 -0
  10. package/dist/api/types/InvoiceRequestBody.d.ts +1 -0
  11. package/dist/api/types/InvoiceResponseData.d.ts +2 -0
  12. package/dist/api/types/ManagePlanRequest.d.ts +2 -0
  13. package/dist/api/types/PlanEntitlementResponseData.d.ts +1 -1
  14. package/dist/api/types/PreviewSubscriptionFinanceResponseData.d.ts +2 -0
  15. package/dist/api/types/RulesengineComparableOperator.d.ts +11 -0
  16. package/dist/api/types/RulesengineCondition.d.ts +1 -1
  17. package/dist/api/types/UpcomingInvoiceResponseData.d.ts +2 -0
  18. package/dist/api/types/UsageBasedEntitlementRequestBody.d.ts +1 -1
  19. package/dist/api/types/UsageBasedEntitlementResponseData.d.ts +1 -1
  20. package/dist/api/types/index.d.ts +1 -0
  21. package/dist/index.js +9 -9
  22. package/dist/serialization/resources/billing/client/requests/CreateInvoiceRequestBody.d.ts +1 -0
  23. package/dist/serialization/types/ChangeSubscriptionInternalRequestBody.d.ts +1 -0
  24. package/dist/serialization/types/ChangeSubscriptionRequestBody.d.ts +1 -0
  25. package/dist/serialization/types/CompanyFeatureUsageExportMetadataVisibleColumnsItem.d.ts +1 -1
  26. package/dist/serialization/types/CreditEventLedgerResponseData.d.ts +1 -0
  27. package/dist/serialization/types/InvoiceRequestBody.d.ts +1 -0
  28. package/dist/serialization/types/InvoiceResponseData.d.ts +1 -0
  29. package/dist/serialization/types/ManagePlanRequest.d.ts +1 -0
  30. package/dist/serialization/types/PreviewSubscriptionFinanceResponseData.d.ts +1 -0
  31. package/dist/serialization/types/RulesengineComparableOperator.d.ts +7 -0
  32. package/dist/serialization/types/RulesengineCondition.d.ts +2 -2
  33. package/dist/serialization/types/UpcomingInvoiceResponseData.d.ts +1 -0
  34. package/dist/serialization/types/index.d.ts +1 -0
  35. package/dist/wasm/rulesengine.d.ts +1 -0
  36. package/dist/wasm/rulesengine.js +34 -4
  37. package/dist/wasm/rulesengine_bg.wasm.d.ts +2 -0
  38. package/package.json +3 -3
@@ -26,5 +26,6 @@ export interface CreateInvoiceRequestBody {
26
26
  status?: Schematic.InvoiceStatus;
27
27
  subscriptionExternalId?: string;
28
28
  subtotal: number;
29
+ total?: number;
29
30
  url?: string;
30
31
  }
@@ -40,7 +40,7 @@ export interface CreateBillingLinkedPlanEntitlementRequestBody {
40
40
  quarterlyUnitPriceDecimal?: string;
41
41
  softLimit?: number;
42
42
  tierMode?: Schematic.BillingTiersMode;
43
- /** The committed unit quantity for this entitlement. For custom plans this is the quantity the company is contractually committed to; for standard plans it is the quantity pre-filled when subscribing. Only applies to pay-in-advance entitlements. Note: this is not yet enforced/auto-provisioned as a true default — it is currently stored for downstream billing use. */
43
+ /** The committed unit quantity for this entitlement. For custom plans this is the minimum the company is contractually committed to: the company can buy more, and finalizing a new plan version sets the subscription quantity to the larger of this value and what the subscription already holds. For standard plans it is the quantity pre-filled when subscribing. Only applies to pay-in-advance entitlements. */
44
44
  usageQuantity?: number;
45
45
  valueBool?: boolean;
46
46
  valueCreditId?: string;
@@ -36,7 +36,7 @@ export interface CreatePlanEntitlementRequestBody {
36
36
  quarterlyUnitPriceDecimal?: string;
37
37
  softLimit?: number;
38
38
  tierMode?: Schematic.BillingTiersMode;
39
- /** The committed unit quantity for this entitlement. For custom plans this is the quantity the company is contractually committed to; for standard plans it is the quantity pre-filled when subscribing. Only applies to pay-in-advance entitlements. Note: this is not yet enforced/auto-provisioned as a true default — it is currently stored for downstream billing use. */
39
+ /** The committed unit quantity for this entitlement. For custom plans this is the minimum the company is contractually committed to: the company can buy more, and finalizing a new plan version sets the subscription quantity to the larger of this value and what the subscription already holds. For standard plans it is the quantity pre-filled when subscribing. Only applies to pay-in-advance entitlements. */
40
40
  usageQuantity?: number;
41
41
  valueBool?: boolean;
42
42
  valueCreditId?: string;
@@ -31,7 +31,7 @@ export interface UpdatePlanEntitlementRequestBody {
31
31
  quarterlyUnitPriceDecimal?: string;
32
32
  softLimit?: number;
33
33
  tierMode?: Schematic.BillingTiersMode;
34
- /** The committed unit quantity for this entitlement. For custom plans this is the quantity the company is contractually committed to; for standard plans it is the quantity pre-filled when subscribing. Only applies to pay-in-advance entitlements. Note: this is not yet enforced/auto-provisioned as a true default — it is currently stored for downstream billing use. */
34
+ /** The committed unit quantity for this entitlement. For custom plans this is the minimum the company is contractually committed to: the company can buy more, and finalizing a new plan version sets the subscription quantity to the larger of this value and what the subscription already holds. For standard plans it is the quantity pre-filled when subscribing. Only applies to pay-in-advance entitlements. */
35
35
  usageQuantity?: number;
36
36
  valueBool?: boolean;
37
37
  valueCreditId?: string;
@@ -6,6 +6,8 @@ export interface ChangeSubscriptionInternalRequestBody {
6
6
  companyId: string;
7
7
  couponExternalId?: string;
8
8
  creditBundles: Schematic.UpdateCreditBundleRequestBody[];
9
+ /** ISO 4217 currency this cart is being built in. Prices are still selected by id; this records the intent, and a cart that prices in another currency is reported as a problem. */
10
+ currency?: string;
9
11
  customFieldValues: Schematic.CheckoutFieldValue[];
10
12
  newPlanId: string;
11
13
  newPriceId: string;
@@ -5,6 +5,8 @@ export interface ChangeSubscriptionRequestBody {
5
5
  billingEntityId?: string;
6
6
  couponExternalId?: string;
7
7
  creditBundles: Schematic.UpdateCreditBundleRequestBody[];
8
+ /** ISO 4217 currency this cart is being built in. Prices are still selected by id; this records the intent, and a cart that prices in another currency is reported as a problem. */
9
+ currency?: string;
8
10
  customFieldValues: Schematic.CheckoutFieldValue[];
9
11
  newPlanId: string;
10
12
  newPriceId: string;
@@ -3,5 +3,6 @@ export declare const CompanyFeatureUsageExportMetadataVisibleColumnsItem: {
3
3
  readonly Subscription: "subscription";
4
4
  readonly Users: "users";
5
5
  readonly LastSeenAt: "last_seen_at";
6
+ readonly CreatedAt: "created_at";
6
7
  };
7
8
  export type CompanyFeatureUsageExportMetadataVisibleColumnsItem = (typeof CompanyFeatureUsageExportMetadataVisibleColumnsItem)[keyof typeof CompanyFeatureUsageExportMetadataVisibleColumnsItem];
@@ -28,7 +28,7 @@ export interface CreateEntitlementInBundleRequestBody {
28
28
  quarterlyUnitPriceDecimal?: string;
29
29
  softLimit?: number;
30
30
  tierMode?: Schematic.BillingTiersMode;
31
- /** The committed unit quantity for this entitlement. For custom plans this is the quantity the company is contractually committed to; for standard plans it is the quantity pre-filled when subscribing. Only applies to pay-in-advance entitlements. Note: this is not yet enforced/auto-provisioned as a true default — it is currently stored for downstream billing use. */
31
+ /** The committed unit quantity for this entitlement. For custom plans this is the minimum the company is contractually committed to: the company can buy more, and finalizing a new plan version sets the subscription quantity to the larger of this value and what the subscription already holds. For standard plans it is the quantity pre-filled when subscribing. Only applies to pay-in-advance entitlements. */
32
32
  usageQuantity?: number;
33
33
  valueBool?: boolean;
34
34
  valueCreditId?: string;
@@ -32,5 +32,6 @@ export interface CreditEventLedgerResponseData {
32
32
  transferReason?: Schematic.CreditTransferReason;
33
33
  usageEventId?: string;
34
34
  usageReason?: Schematic.CreditUsageReason;
35
+ userId?: string;
35
36
  zeroedOutReason?: Schematic.BillingCreditGrantZeroedOutReason;
36
37
  }
@@ -13,5 +13,6 @@ export interface InvoiceRequestBody {
13
13
  status?: Schematic.InvoiceStatus;
14
14
  subscriptionExternalId?: string;
15
15
  subtotal: number;
16
+ total?: number;
16
17
  url?: string;
17
18
  }
@@ -19,6 +19,8 @@ export interface InvoiceResponseData {
19
19
  status?: Schematic.InvoiceStatus;
20
20
  subscriptionExternalId?: string;
21
21
  subtotal: number;
22
+ /** Amount after discounts and tax, before applying the customer balance. Null when the provider has not reported it: rows synced before the column existed, or pushed without one. */
23
+ total?: number;
22
24
  updatedAt: Date;
23
25
  url?: string;
24
26
  }
@@ -19,6 +19,8 @@ export interface ManagePlanRequest {
19
19
  companyId: string;
20
20
  couponExternalId?: string;
21
21
  creditBundles: Schematic.UpdateCreditBundleRequestBody[];
22
+ /** ISO 4217 currency this change is being built in. Prices are still selected by id; this records the intent. */
23
+ currency?: string;
22
24
  customFieldValues: Schematic.CheckoutFieldValue[];
23
25
  /** Payment terms in days for an invoiced subscription. Defaults to 30. */
24
26
  daysUntilDue?: number;
@@ -26,7 +26,7 @@ export interface PlanEntitlementResponseData {
26
26
  softLimit?: number;
27
27
  updatedAt: Date;
28
28
  usageBasedProduct?: Schematic.BillingProductResponseData;
29
- /** The committed unit quantity for this entitlement. For custom plans this is the quantity the company is contractually committed to; for standard plans it is the quantity pre-filled when subscribing. Only applies to pay-in-advance entitlements. Note: this is not yet enforced/auto-provisioned as a true default — it is currently stored for downstream billing use. */
29
+ /** The committed unit quantity for this entitlement. For custom plans this is the minimum the company is contractually committed to: the company can buy more, and finalizing a new plan version sets the subscription quantity to the larger of this value and what the subscription already holds. For standard plans it is the quantity pre-filled when subscribing. Only applies to pay-in-advance entitlements. */
30
30
  usageQuantity?: number;
31
31
  valueBool?: boolean;
32
32
  valueCredit?: Schematic.BillingCreditResponseData;
@@ -1,6 +1,8 @@
1
1
  import type * as Schematic from "../index";
2
2
  export interface PreviewSubscriptionFinanceResponseData {
3
3
  amountOff: number;
4
+ /** ISO 4217 currency every amount in this block is denominated in. */
5
+ currency: string;
4
6
  discountAmount: number;
5
7
  discounts: Schematic.PreviewSubscriptionDiscountResponseData[];
6
8
  dueNow: number;
@@ -0,0 +1,11 @@
1
+ export declare const RulesengineComparableOperator: {
2
+ readonly Eq: "eq";
3
+ readonly Gt: "gt";
4
+ readonly Gte: "gte";
5
+ readonly IsEmpty: "is_empty";
6
+ readonly Lt: "lt";
7
+ readonly Lte: "lte";
8
+ readonly NotEmpty: "not_empty";
9
+ readonly Ne: "ne";
10
+ };
11
+ export type RulesengineComparableOperator = (typeof RulesengineComparableOperator)[keyof typeof RulesengineComparableOperator];
@@ -11,7 +11,7 @@ export interface RulesengineCondition {
11
11
  metricPeriod?: Schematic.RulesengineMetricPeriod;
12
12
  metricPeriodMonthReset?: Schematic.RulesengineMetricPeriodMonthReset;
13
13
  metricValue?: number;
14
- operator: Schematic.ComparableOperator;
14
+ operator: Schematic.RulesengineComparableOperator;
15
15
  resourceIds: string[];
16
16
  traitDefinition?: Schematic.RulesengineTraitDefinition;
17
17
  traitValue: string;
@@ -18,6 +18,8 @@ export interface UpcomingInvoiceResponseData {
18
18
  status?: Schematic.InvoiceStatus;
19
19
  subscriptionExternalId?: string;
20
20
  subtotal: number;
21
+ /** Amount after discounts and tax, before applying the customer balance. Null when the provider has not reported it. */
22
+ total?: number;
21
23
  updatedAt: Date;
22
24
  url?: string;
23
25
  }
@@ -22,7 +22,7 @@ export interface UsageBasedEntitlementRequestBody {
22
22
  quarterlyUnitPriceDecimal?: string;
23
23
  softLimit?: number;
24
24
  tierMode?: Schematic.BillingTiersMode;
25
- /** The committed unit quantity for this entitlement. For custom plans this is the quantity the company is contractually committed to; for standard plans it is the quantity pre-filled when subscribing. Only applies to pay-in-advance entitlements. Note: this is not yet enforced/auto-provisioned as a true default — it is currently stored for downstream billing use. */
25
+ /** The committed unit quantity for this entitlement. For custom plans this is the minimum the company is contractually committed to: the company can buy more, and finalizing a new plan version sets the subscription quantity to the larger of this value and what the subscription already holds. For standard plans it is the quantity pre-filled when subscribing. Only applies to pay-in-advance entitlements. */
26
26
  usageQuantity?: number;
27
27
  yearlyMeteredPriceId?: string;
28
28
  yearlyPriceTiers?: Schematic.CreatePriceTierRequestBody[];
@@ -9,7 +9,7 @@ export interface UsageBasedEntitlementResponseData {
9
9
  monthlyUsageBasedPrice?: Schematic.BillingPriceView;
10
10
  priceBehavior?: Schematic.EntitlementPriceBehavior;
11
11
  quarterlyUsageBasedPrice?: Schematic.BillingPriceView;
12
- /** The committed unit quantity for this entitlement. For custom plans this is the quantity the company is contractually committed to; for standard plans it is the quantity pre-filled when subscribing. Only applies to pay-in-advance entitlements. Note: this is not yet enforced/auto-provisioned as a true default — it is currently stored for downstream billing use. */
12
+ /** The committed unit quantity for this entitlement. For custom plans this is the minimum the company is contractually committed to: the company can buy more, and finalizing a new plan version sets the subscription quantity to the larger of this value and what the subscription already holds. For standard plans it is the quantity pre-filled when subscribing. Only applies to pay-in-advance entitlements. */
13
13
  usageQuantity?: number;
14
14
  valueBool?: boolean;
15
15
  valueNumeric?: number;
@@ -380,6 +380,7 @@ export * from "./RulesEngineSchemaVersion";
380
380
  export * from "./RulesengineCheckFlagResult";
381
381
  export * from "./RulesengineCompany";
382
382
  export * from "./RulesengineCompanyMetric";
383
+ export * from "./RulesengineComparableOperator";
383
384
  export * from "./RulesengineCondition";
384
385
  export * from "./RulesengineConditionGroup";
385
386
  export * from "./RulesengineConditionType";