@flexprice/sdk 2.1.2 → 2.1.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 (144) hide show
  1. package/docs/sdk/models/changed-invoice-action.md +19 -0
  2. package/docs/sdk/models/changed-invoice-status.md +19 -0
  3. package/docs/sdk/models/changed-invoice.md +19 -6
  4. package/docs/sdk/models/changed-line-item-action.md +19 -0
  5. package/docs/sdk/models/changed-line-item.md +1 -1
  6. package/docs/sdk/models/changed-resources.md +16 -1
  7. package/docs/sdk/models/changed-subscription-action.md +19 -0
  8. package/docs/sdk/models/changed-subscription.md +5 -5
  9. package/docs/sdk/models/clone-environment-request-request.md +19 -0
  10. package/docs/sdk/models/clone-environment-request.md +17 -0
  11. package/docs/sdk/models/clone-feature-request-request.md +19 -0
  12. package/docs/sdk/models/clone-feature-request.md +18 -0
  13. package/docs/sdk/models/{post-plans-id-clone-request.md → clone-plan-request-request.md} +3 -3
  14. package/docs/sdk/models/create-subscription-request.md +38 -37
  15. package/docs/sdk/models/environment-type.md +15 -0
  16. package/docs/sdk/models/subscription-modify-response.md +16 -0
  17. package/docs/sdk/models/window-size.md +2 -2
  18. package/docs/sdks/environments/README.md +79 -0
  19. package/docs/sdks/features/README.md +73 -0
  20. package/docs/sdks/plans/README.md +7 -7
  21. package/esm/funcs/environments-clone-environment.d.ts +17 -0
  22. package/esm/funcs/environments-clone-environment.d.ts.map +1 -0
  23. package/esm/funcs/environments-clone-environment.js +92 -0
  24. package/esm/funcs/environments-clone-environment.js.map +1 -0
  25. package/esm/funcs/features-clone-feature.d.ts +17 -0
  26. package/esm/funcs/features-clone-feature.d.ts.map +1 -0
  27. package/esm/funcs/features-clone-feature.js +92 -0
  28. package/esm/funcs/features-clone-feature.js.map +1 -0
  29. package/esm/funcs/{plans-post-plans-id-clone.d.ts → plans-clone-plan.d.ts} +2 -2
  30. package/esm/funcs/plans-clone-plan.d.ts.map +1 -0
  31. package/esm/funcs/{plans-post-plans-id-clone.js → plans-clone-plan.js} +4 -4
  32. package/esm/funcs/plans-clone-plan.js.map +1 -0
  33. package/esm/lib/config.d.ts +3 -3
  34. package/esm/lib/config.js +3 -3
  35. package/esm/sdk/environments.d.ts +12 -0
  36. package/esm/sdk/environments.d.ts.map +1 -0
  37. package/esm/sdk/environments.js +18 -0
  38. package/esm/sdk/environments.js.map +1 -0
  39. package/esm/sdk/features.d.ts +7 -0
  40. package/esm/sdk/features.d.ts.map +1 -1
  41. package/esm/sdk/features.js +10 -0
  42. package/esm/sdk/features.js.map +1 -1
  43. package/esm/sdk/models/changed-invoice-action.d.ts +16 -0
  44. package/esm/sdk/models/changed-invoice-action.d.ts.map +1 -0
  45. package/esm/sdk/models/changed-invoice-action.js +14 -0
  46. package/esm/sdk/models/changed-invoice-action.js.map +1 -0
  47. package/esm/sdk/models/changed-invoice-status.d.ts +16 -0
  48. package/esm/sdk/models/changed-invoice-status.d.ts.map +1 -0
  49. package/esm/sdk/models/changed-invoice-status.js +14 -0
  50. package/esm/sdk/models/changed-invoice-status.js.map +1 -0
  51. package/esm/sdk/models/changed-invoice.d.ts +12 -3
  52. package/esm/sdk/models/changed-invoice.d.ts.map +1 -1
  53. package/esm/sdk/models/changed-invoice.js +15 -4
  54. package/esm/sdk/models/changed-invoice.js.map +1 -1
  55. package/esm/sdk/models/changed-line-item-action.d.ts +17 -0
  56. package/esm/sdk/models/changed-line-item-action.d.ts.map +1 -0
  57. package/esm/sdk/models/changed-line-item-action.js +15 -0
  58. package/esm/sdk/models/changed-line-item-action.js.map +1 -0
  59. package/esm/sdk/models/changed-line-item.d.ts +3 -2
  60. package/esm/sdk/models/changed-line-item.d.ts.map +1 -1
  61. package/esm/sdk/models/changed-line-item.js +2 -1
  62. package/esm/sdk/models/changed-line-item.js.map +1 -1
  63. package/esm/sdk/models/changed-subscription-action.d.ts +16 -0
  64. package/esm/sdk/models/changed-subscription-action.d.ts.map +1 -0
  65. package/esm/sdk/models/changed-subscription-action.js +14 -0
  66. package/esm/sdk/models/changed-subscription-action.js.map +1 -0
  67. package/esm/sdk/models/changed-subscription.d.ts +3 -2
  68. package/esm/sdk/models/changed-subscription.d.ts.map +1 -1
  69. package/esm/sdk/models/changed-subscription.js +2 -1
  70. package/esm/sdk/models/changed-subscription.js.map +1 -1
  71. package/esm/sdk/models/clone-environment-op.d.ts +21 -0
  72. package/esm/sdk/models/clone-environment-op.d.ts.map +1 -0
  73. package/esm/sdk/models/clone-environment-op.js +14 -0
  74. package/esm/sdk/models/clone-environment-op.js.map +1 -0
  75. package/esm/sdk/models/clone-environment-request.d.ts +26 -0
  76. package/esm/sdk/models/clone-environment-request.d.ts.map +1 -0
  77. package/esm/sdk/models/clone-environment-request.js +20 -0
  78. package/esm/sdk/models/clone-environment-request.js.map +1 -0
  79. package/esm/sdk/models/clone-feature-op.d.ts +21 -0
  80. package/esm/sdk/models/clone-feature-op.d.ts.map +1 -0
  81. package/esm/sdk/models/clone-feature-op.js +14 -0
  82. package/esm/sdk/models/clone-feature-op.js.map +1 -0
  83. package/esm/sdk/models/clone-feature-request.d.ts +31 -0
  84. package/esm/sdk/models/clone-feature-request.d.ts.map +1 -0
  85. package/esm/sdk/models/clone-feature-request.js +20 -0
  86. package/esm/sdk/models/clone-feature-request.js.map +1 -0
  87. package/esm/sdk/models/clone-plan-op.d.ts +21 -0
  88. package/esm/sdk/models/clone-plan-op.d.ts.map +1 -0
  89. package/esm/sdk/models/{post-plans-id-clone-op.js → clone-plan-op.js} +4 -4
  90. package/esm/sdk/models/clone-plan-op.js.map +1 -0
  91. package/esm/sdk/models/create-subscription-request.d.ts +10 -0
  92. package/esm/sdk/models/create-subscription-request.d.ts.map +1 -1
  93. package/esm/sdk/models/create-subscription-request.js +2 -0
  94. package/esm/sdk/models/create-subscription-request.js.map +1 -1
  95. package/esm/sdk/models/environment-type.d.ts +10 -0
  96. package/esm/sdk/models/environment-type.d.ts.map +1 -0
  97. package/esm/sdk/models/environment-type.js +11 -0
  98. package/esm/sdk/models/environment-type.js.map +1 -0
  99. package/esm/sdk/models/index.d.ts +10 -1
  100. package/esm/sdk/models/index.d.ts.map +1 -1
  101. package/esm/sdk/models/index.js +10 -1
  102. package/esm/sdk/models/index.js.map +1 -1
  103. package/esm/sdk/models/window-size.d.ts +1 -1
  104. package/esm/sdk/models/window-size.js +1 -1
  105. package/esm/sdk/models/window-size.js.map +1 -1
  106. package/esm/sdk/plans.d.ts +1 -1
  107. package/esm/sdk/plans.d.ts.map +1 -1
  108. package/esm/sdk/plans.js +3 -3
  109. package/esm/sdk/plans.js.map +1 -1
  110. package/esm/sdk/sdk.d.ts +3 -0
  111. package/esm/sdk/sdk.d.ts.map +1 -1
  112. package/esm/sdk/sdk.js +5 -0
  113. package/esm/sdk/sdk.js.map +1 -1
  114. package/jsr.json +1 -1
  115. package/package.json +3 -3
  116. package/src/funcs/environments-clone-environment.ts +185 -0
  117. package/src/funcs/features-clone-feature.ts +184 -0
  118. package/src/funcs/{plans-post-plans-id-clone.ts → plans-clone-plan.ts} +4 -4
  119. package/src/lib/config.ts +3 -3
  120. package/src/sdk/environments.ts +29 -0
  121. package/src/sdk/features.ts +20 -0
  122. package/src/sdk/models/changed-invoice-action.ts +25 -0
  123. package/src/sdk/models/changed-invoice-status.ts +25 -0
  124. package/src/sdk/models/changed-invoice.ts +39 -8
  125. package/src/sdk/models/changed-line-item-action.ts +26 -0
  126. package/src/sdk/models/changed-line-item.ts +7 -3
  127. package/src/sdk/models/changed-subscription-action.ts +27 -0
  128. package/src/sdk/models/changed-subscription.ts +7 -3
  129. package/src/sdk/models/clone-environment-op.ts +46 -0
  130. package/src/sdk/models/clone-environment-request.ts +57 -0
  131. package/src/sdk/models/clone-feature-op.ts +44 -0
  132. package/src/sdk/models/clone-feature-request.ts +56 -0
  133. package/src/sdk/models/{post-plans-id-clone-op.ts → clone-plan-op.ts} +8 -8
  134. package/src/sdk/models/create-subscription-request.ts +14 -0
  135. package/src/sdk/models/environment-type.ts +17 -0
  136. package/src/sdk/models/index.ts +10 -1
  137. package/src/sdk/models/window-size.ts +1 -1
  138. package/src/sdk/plans.ts +3 -3
  139. package/src/sdk/sdk.ts +6 -0
  140. package/esm/funcs/plans-post-plans-id-clone.d.ts.map +0 -1
  141. package/esm/funcs/plans-post-plans-id-clone.js.map +0 -1
  142. package/esm/sdk/models/post-plans-id-clone-op.d.ts +0 -21
  143. package/esm/sdk/models/post-plans-id-clone-op.d.ts.map +0 -1
  144. package/esm/sdk/models/post-plans-id-clone-op.js.map +0 -1
@@ -0,0 +1,19 @@
1
+ # ChangedInvoiceAction
2
+
3
+ created (proration invoice) | wallet_credit (downgrade credit)
4
+
5
+ ## Example Usage
6
+
7
+ ```typescript
8
+ import { ChangedInvoiceAction } from "@flexprice/sdk/sdk/models";
9
+
10
+ let value: ChangedInvoiceAction = "created";
11
+
12
+ // Open enum: unrecognized values are captured as Unrecognized<string>
13
+ ```
14
+
15
+ ## Values
16
+
17
+ ```typescript
18
+ "created" | "wallet_credit" | Unrecognized<string>
19
+ ```
@@ -0,0 +1,19 @@
1
+ # ChangedInvoiceStatus
2
+
3
+ preview | issued | INITIATED | PENDING | PROCESSING | SUCCEEDED | OVERPAID | FAILED | REFUNDED | PARTIALLY_REFUNDED
4
+
5
+ ## Example Usage
6
+
7
+ ```typescript
8
+ import { ChangedInvoiceStatus } from "@flexprice/sdk/sdk/models";
9
+
10
+ let value: ChangedInvoiceStatus = "preview";
11
+
12
+ // Open enum: unrecognized values are captured as Unrecognized<string>
13
+ ```
14
+
15
+ ## Values
16
+
17
+ ```typescript
18
+ "preview" | "issued" | Unrecognized<string>
19
+ ```
@@ -5,13 +5,26 @@
5
5
  ```typescript
6
6
  import { ChangedInvoice } from "@flexprice/sdk/sdk/models";
7
7
 
8
- let value: ChangedInvoice = {};
8
+ let value: ChangedInvoice = {
9
+ invoice: {
10
+ subscription: {
11
+ latestInvoice: {
12
+ subscription: {
13
+ plan: {},
14
+ },
15
+ },
16
+ plan: {},
17
+ },
18
+ },
19
+ };
9
20
  ```
10
21
 
11
22
  ## Fields
12
23
 
13
- | Field | Type | Required | Description |
14
- | --------------------------- | --------------------------- | --------------------------- | --------------------------- |
15
- | `action` | *string* | :heavy_minus_sign: | "created" \| "wallet_credit" |
16
- | `id` | *string* | :heavy_minus_sign: | N/A |
17
- | `status` | *string* | :heavy_minus_sign: | N/A |
24
+ | Field | Type | Required | Description |
25
+ | ------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------- |
26
+ | `action` | [models.ChangedInvoiceAction](../../sdk/models/changed-invoice-action.md) | :heavy_minus_sign: | created (proration invoice) \| wallet_credit (downgrade credit) |
27
+ | `id` | *string* | :heavy_minus_sign: | N/A |
28
+ | `invoice` | [models.InvoiceResponse](../../sdk/models/invoice-response.md) | :heavy_minus_sign: | N/A |
29
+ | `status` | [models.ChangedInvoiceStatus](../../sdk/models/changed-invoice-status.md) | :heavy_minus_sign: | preview \| issued \| INITIATED \| PENDING \| PROCESSING \| SUCCEEDED \| OVERPAID \| FAILED \| REFUNDED \| PARTIALLY_REFUNDED |
30
+ | `walletTransaction` | [models.WalletTransactionResponse](../../sdk/models/wallet-transaction-response.md) | :heavy_minus_sign: | N/A |
@@ -0,0 +1,19 @@
1
+ # ChangedLineItemAction
2
+
3
+ created | updated | ended
4
+
5
+ ## Example Usage
6
+
7
+ ```typescript
8
+ import { ChangedLineItemAction } from "@flexprice/sdk/sdk/models";
9
+
10
+ let value: ChangedLineItemAction = "created";
11
+
12
+ // Open enum: unrecognized values are captured as Unrecognized<string>
13
+ ```
14
+
15
+ ## Values
16
+
17
+ ```typescript
18
+ "created" | "updated" | "ended" | Unrecognized<string>
19
+ ```
@@ -12,7 +12,7 @@ let value: ChangedLineItem = {};
12
12
 
13
13
  | Field | Type | Required | Description |
14
14
  | --------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------- |
15
- | `changeAction` | *string* | :heavy_minus_sign: | "created" \| "updated" \| "ended" |
15
+ | `changeAction` | [models.ChangedLineItemAction](../../sdk/models/changed-line-item-action.md) | :heavy_minus_sign: | created \| updated \| ended |
16
16
  | `endDate` | [Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date) | :heavy_minus_sign: | N/A |
17
17
  | `id` | *string* | :heavy_minus_sign: | N/A |
18
18
  | `priceId` | *string* | :heavy_minus_sign: | N/A |
@@ -5,7 +5,22 @@
5
5
  ```typescript
6
6
  import { ChangedResources } from "@flexprice/sdk/sdk/models";
7
7
 
8
- let value: ChangedResources = {};
8
+ let value: ChangedResources = {
9
+ invoices: [
10
+ {
11
+ invoice: {
12
+ subscription: {
13
+ latestInvoice: {
14
+ subscription: {
15
+ plan: {},
16
+ },
17
+ },
18
+ plan: {},
19
+ },
20
+ },
21
+ },
22
+ ],
23
+ };
9
24
  ```
10
25
 
11
26
  ## Fields
@@ -0,0 +1,19 @@
1
+ # ChangedSubscriptionAction
2
+
3
+ created | updated
4
+
5
+ ## Example Usage
6
+
7
+ ```typescript
8
+ import { ChangedSubscriptionAction } from "@flexprice/sdk/sdk/models";
9
+
10
+ let value: ChangedSubscriptionAction = "updated";
11
+
12
+ // Open enum: unrecognized values are captured as Unrecognized<string>
13
+ ```
14
+
15
+ ## Values
16
+
17
+ ```typescript
18
+ "created" | "updated" | Unrecognized<string>
19
+ ```
@@ -10,8 +10,8 @@ let value: ChangedSubscription = {};
10
10
 
11
11
  ## Fields
12
12
 
13
- | Field | Type | Required | Description |
14
- | -------------------------------------------------------------------- | -------------------------------------------------------------------- | -------------------------------------------------------------------- | -------------------------------------------------------------------- |
15
- | `action` | *string* | :heavy_minus_sign: | "created" \| "updated" |
16
- | `id` | *string* | :heavy_minus_sign: | N/A |
17
- | `status` | [models.SubscriptionStatus](../../sdk/models/subscription-status.md) | :heavy_minus_sign: | N/A |
13
+ | Field | Type | Required | Description |
14
+ | ----------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------- |
15
+ | `action` | [models.ChangedSubscriptionAction](../../sdk/models/changed-subscription-action.md) | :heavy_minus_sign: | created \| updated |
16
+ | `id` | *string* | :heavy_minus_sign: | N/A |
17
+ | `status` | [models.SubscriptionStatus](../../sdk/models/subscription-status.md) | :heavy_minus_sign: | N/A |
@@ -0,0 +1,19 @@
1
+ # CloneEnvironmentRequestRequest
2
+
3
+ ## Example Usage
4
+
5
+ ```typescript
6
+ import { CloneEnvironmentRequestRequest } from "@flexprice/sdk/sdk/models";
7
+
8
+ let value: CloneEnvironmentRequestRequest = {
9
+ id: "<id>",
10
+ body: {},
11
+ };
12
+ ```
13
+
14
+ ## Fields
15
+
16
+ | Field | Type | Required | Description |
17
+ | ------------------------------------------------------------------------------- | ------------------------------------------------------------------------------- | ------------------------------------------------------------------------------- | ------------------------------------------------------------------------------- |
18
+ | `id` | *string* | :heavy_check_mark: | Source Environment ID |
19
+ | `body` | [models.CloneEnvironmentRequest](../../sdk/models/clone-environment-request.md) | :heavy_check_mark: | Clone configuration |
@@ -0,0 +1,17 @@
1
+ # CloneEnvironmentRequest
2
+
3
+ ## Example Usage
4
+
5
+ ```typescript
6
+ import { CloneEnvironmentRequest } from "@flexprice/sdk/sdk/models";
7
+
8
+ let value: CloneEnvironmentRequest = {};
9
+ ```
10
+
11
+ ## Fields
12
+
13
+ | Field | Type | Required | Description |
14
+ | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
15
+ | `name` | *string* | :heavy_minus_sign: | Name of the new environment (required when target_environment_id is not provided) |
16
+ | `targetEnvironmentId` | *string* | :heavy_minus_sign: | TargetEnvironmentID is the ID of an existing environment to clone into (optional).<br/>When provided, Name and Type are ignored. When omitted, Name and Type are required. |
17
+ | `type` | [models.EnvironmentType](../../sdk/models/environment-type.md) | :heavy_minus_sign: | N/A |
@@ -0,0 +1,19 @@
1
+ # CloneFeatureRequestRequest
2
+
3
+ ## Example Usage
4
+
5
+ ```typescript
6
+ import { CloneFeatureRequestRequest } from "@flexprice/sdk/sdk/models";
7
+
8
+ let value: CloneFeatureRequestRequest = {
9
+ id: "<id>",
10
+ body: {},
11
+ };
12
+ ```
13
+
14
+ ## Fields
15
+
16
+ | Field | Type | Required | Description |
17
+ | ----------------------------------------------------------------------- | ----------------------------------------------------------------------- | ----------------------------------------------------------------------- | ----------------------------------------------------------------------- |
18
+ | `id` | *string* | :heavy_check_mark: | Source Feature ID |
19
+ | `body` | [models.CloneFeatureRequest](../../sdk/models/clone-feature-request.md) | :heavy_check_mark: | Clone configuration |
@@ -0,0 +1,18 @@
1
+ # CloneFeatureRequest
2
+
3
+ ## Example Usage
4
+
5
+ ```typescript
6
+ import { CloneFeatureRequest } from "@flexprice/sdk/sdk/models";
7
+
8
+ let value: CloneFeatureRequest = {};
9
+ ```
10
+
11
+ ## Fields
12
+
13
+ | Field | Type | Required | Description |
14
+ | --------------------------------------------------------------------- | --------------------------------------------------------------------- | --------------------------------------------------------------------- | --------------------------------------------------------------------- |
15
+ | `description` | *string* | :heavy_minus_sign: | Description overrides the source feature's description when provided |
16
+ | `lookupKey` | *string* | :heavy_minus_sign: | LookupKey is required and must be unique across published features |
17
+ | `metadata` | Record<string, *string*> | :heavy_minus_sign: | N/A |
18
+ | `name` | *string* | :heavy_minus_sign: | Name is required and must be different from the source feature's name |
@@ -1,11 +1,11 @@
1
- # PostPlansIdCloneRequest
1
+ # ClonePlanRequestRequest
2
2
 
3
3
  ## Example Usage
4
4
 
5
5
  ```typescript
6
- import { PostPlansIdCloneRequest } from "@flexprice/sdk/sdk/models";
6
+ import { ClonePlanRequestRequest } from "@flexprice/sdk/sdk/models";
7
7
 
8
- let value: PostPlansIdCloneRequest = {
8
+ let value: ClonePlanRequestRequest = {
9
9
  id: "<id>",
10
10
  body: {},
11
11
  };
@@ -14,40 +14,41 @@ let value: CreateSubscriptionRequest = {
14
14
 
15
15
  ## Fields
16
16
 
17
- | Field | Type | Required | Description |
18
- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
19
- | `addons` | [models.AddAddonToSubscriptionRequest](../../sdk/models/add-addon-to-subscription-request.md)[] | :heavy_minus_sign: | Addons represents addons to be added to the subscription during creation |
20
- | `billingCycle` | [models.BillingCycle](../../sdk/models/billing-cycle.md) | :heavy_minus_sign: | N/A |
21
- | `billingPeriod` | [models.BillingPeriod](../../sdk/models/billing-period.md) | :heavy_check_mark: | N/A |
22
- | `billingPeriodCount` | *number* | :heavy_minus_sign: | N/A |
23
- | `collectionMethod` | [models.CollectionMethod](../../sdk/models/collection-method.md) | :heavy_minus_sign: | N/A |
24
- | `commitmentAmount` | *string* | :heavy_minus_sign: | CommitmentAmount is the minimum amount a customer commits to paying for a billing period |
25
- | `commitmentDuration` | [models.BillingPeriod](../../sdk/models/billing-period.md) | :heavy_minus_sign: | N/A |
26
- | `coupons` | *string*[] | :heavy_minus_sign: | N/A |
27
- | `creditGrants` | [models.CreateCreditGrantRequest](../../sdk/models/create-credit-grant-request.md)[] | :heavy_minus_sign: | Credit grants to be applied when subscription is created |
28
- | `currency` | *string* | :heavy_check_mark: | N/A |
29
- | `customerId` | *string* | :heavy_minus_sign: | customer_id is the flexprice customer id<br/>and it is prioritized over external_customer_id in case both are provided. |
30
- | `customerTimezone` | *string* | :heavy_minus_sign: | Timezone of the customer.<br/>If not set, the default value is UTC. |
31
- | `enableTrueUp` | *boolean* | :heavy_minus_sign: | Enable Commitment True Up Fee |
32
- | `endDate` | [Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date) | :heavy_minus_sign: | N/A |
33
- | `externalCustomerId` | *string* | :heavy_minus_sign: | external_customer_id is the customer id in your DB<br/>and must be same as what you provided as external_id while creating the customer in flexprice. |
34
- | `gatewayPaymentMethodId` | *string* | :heavy_minus_sign: | N/A |
35
- | `inheritance` | [models.SubscriptionInheritanceConfig](../../sdk/models/subscription-inheritance-config.md) | :heavy_minus_sign: | N/A |
36
- | `lineItemCommitments` | Record<string, [models.LineItemCommitmentConfig](../../sdk/models/line-item-commitment-config.md)> | :heavy_minus_sign: | LineItemCommitments allows setting commitment configuration per line item (keyed by price_id) |
37
- | `lineItemCoupons` | Record<string, *string*[]> | :heavy_minus_sign: | N/A |
38
- | `lineItems` | [models.CreateSubscriptionLineItemRequest](../../sdk/models/create-subscription-line-item-request.md)[] | :heavy_minus_sign: | LineItems are extra line items to add at creation (each with price_id or price), in addition to plan prices |
39
- | `lookupKey` | *string* | :heavy_minus_sign: | N/A |
40
- | `metadata` | Record<string, *string*> | :heavy_minus_sign: | N/A |
41
- | `overageFactor` | *string* | :heavy_minus_sign: | OverageFactor is a multiplier applied to usage beyond the commitment amount |
42
- | `overrideEntitlements` | [models.OverrideEntitlementRequest](../../sdk/models/override-entitlement-request.md)[] | :heavy_minus_sign: | OverrideEntitlements allows customizing specific entitlements for this subscription |
43
- | `overrideLineItems` | [models.OverrideLineItemRequest](../../sdk/models/override-line-item-request.md)[] | :heavy_minus_sign: | OverrideLineItems allows customizing specific prices for this subscription |
44
- | `paymentBehavior` | [models.PaymentBehavior](../../sdk/models/payment-behavior.md) | :heavy_minus_sign: | N/A |
45
- | `paymentTerms` | [models.PaymentTerms](../../sdk/models/payment-terms.md) | :heavy_minus_sign: | N/A |
46
- | `phases` | [models.SubscriptionPhaseCreateRequest](../../sdk/models/subscription-phase-create-request.md)[] | :heavy_minus_sign: | Phases represents subscription phases to be created with the subscription |
47
- | `planId` | *string* | :heavy_check_mark: | N/A |
48
- | `prorationBehavior` | [models.ProrationBehavior](../../sdk/models/proration-behavior.md) | :heavy_minus_sign: | N/A |
49
- | `startDate` | [Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date) | :heavy_minus_sign: | N/A |
50
- | `subscriptionStatus` | [models.SubscriptionStatus](../../sdk/models/subscription-status.md) | :heavy_minus_sign: | N/A |
51
- | `taxRateOverrides` | [models.TaxRateOverride](../../sdk/models/tax-rate-override.md)[] | :heavy_minus_sign: | tax_rate_overrides is the tax rate overrides to be applied to the subscription |
52
- | `trialEnd` | [Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date) | :heavy_minus_sign: | N/A |
53
- | `trialStart` | [Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date) | :heavy_minus_sign: | N/A |
17
+ | Field | Type | Required | Description |
18
+ | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
19
+ | `addons` | [models.AddAddonToSubscriptionRequest](../../sdk/models/add-addon-to-subscription-request.md)[] | :heavy_minus_sign: | Addons represents addons to be added to the subscription during creation |
20
+ | `billingAnchor` | [Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date) | :heavy_minus_sign: | BillingAnchor overrides the derived billing anchor when billing_cycle is anniversary.<br/>For monthly billing, the day-of-month (and time-of-day) define cycle boundaries: if start_date<br/>is before that day in the month, the first billing period ends on the next occurrence of that<br/>day in the same month (a shorter first period); subsequent periods follow the usual interval. |
21
+ | `billingCycle` | [models.BillingCycle](../../sdk/models/billing-cycle.md) | :heavy_minus_sign: | N/A |
22
+ | `billingPeriod` | [models.BillingPeriod](../../sdk/models/billing-period.md) | :heavy_check_mark: | N/A |
23
+ | `billingPeriodCount` | *number* | :heavy_minus_sign: | N/A |
24
+ | `collectionMethod` | [models.CollectionMethod](../../sdk/models/collection-method.md) | :heavy_minus_sign: | N/A |
25
+ | `commitmentAmount` | *string* | :heavy_minus_sign: | CommitmentAmount is the minimum amount a customer commits to paying for a billing period |
26
+ | `commitmentDuration` | [models.BillingPeriod](../../sdk/models/billing-period.md) | :heavy_minus_sign: | N/A |
27
+ | `coupons` | *string*[] | :heavy_minus_sign: | N/A |
28
+ | `creditGrants` | [models.CreateCreditGrantRequest](../../sdk/models/create-credit-grant-request.md)[] | :heavy_minus_sign: | Credit grants to be applied when subscription is created |
29
+ | `currency` | *string* | :heavy_check_mark: | N/A |
30
+ | `customerId` | *string* | :heavy_minus_sign: | customer_id is the flexprice customer id<br/>and it is prioritized over external_customer_id in case both are provided. |
31
+ | `customerTimezone` | *string* | :heavy_minus_sign: | Timezone of the customer.<br/>If not set, the default value is UTC. |
32
+ | `enableTrueUp` | *boolean* | :heavy_minus_sign: | Enable Commitment True Up Fee |
33
+ | `endDate` | [Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date) | :heavy_minus_sign: | N/A |
34
+ | `externalCustomerId` | *string* | :heavy_minus_sign: | external_customer_id is the customer id in your DB<br/>and must be same as what you provided as external_id while creating the customer in flexprice. |
35
+ | `gatewayPaymentMethodId` | *string* | :heavy_minus_sign: | N/A |
36
+ | `inheritance` | [models.SubscriptionInheritanceConfig](../../sdk/models/subscription-inheritance-config.md) | :heavy_minus_sign: | N/A |
37
+ | `lineItemCommitments` | Record<string, [models.LineItemCommitmentConfig](../../sdk/models/line-item-commitment-config.md)> | :heavy_minus_sign: | LineItemCommitments allows setting commitment configuration per line item (keyed by price_id) |
38
+ | `lineItemCoupons` | Record<string, *string*[]> | :heavy_minus_sign: | N/A |
39
+ | `lineItems` | [models.CreateSubscriptionLineItemRequest](../../sdk/models/create-subscription-line-item-request.md)[] | :heavy_minus_sign: | LineItems are extra line items to add at creation (each with price_id or price), in addition to plan prices |
40
+ | `lookupKey` | *string* | :heavy_minus_sign: | N/A |
41
+ | `metadata` | Record<string, *string*> | :heavy_minus_sign: | N/A |
42
+ | `overageFactor` | *string* | :heavy_minus_sign: | OverageFactor is a multiplier applied to usage beyond the commitment amount |
43
+ | `overrideEntitlements` | [models.OverrideEntitlementRequest](../../sdk/models/override-entitlement-request.md)[] | :heavy_minus_sign: | OverrideEntitlements allows customizing specific entitlements for this subscription |
44
+ | `overrideLineItems` | [models.OverrideLineItemRequest](../../sdk/models/override-line-item-request.md)[] | :heavy_minus_sign: | OverrideLineItems allows customizing specific prices for this subscription |
45
+ | `paymentBehavior` | [models.PaymentBehavior](../../sdk/models/payment-behavior.md) | :heavy_minus_sign: | N/A |
46
+ | `paymentTerms` | [models.PaymentTerms](../../sdk/models/payment-terms.md) | :heavy_minus_sign: | N/A |
47
+ | `phases` | [models.SubscriptionPhaseCreateRequest](../../sdk/models/subscription-phase-create-request.md)[] | :heavy_minus_sign: | Phases represents subscription phases to be created with the subscription |
48
+ | `planId` | *string* | :heavy_check_mark: | N/A |
49
+ | `prorationBehavior` | [models.ProrationBehavior](../../sdk/models/proration-behavior.md) | :heavy_minus_sign: | N/A |
50
+ | `startDate` | [Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date) | :heavy_minus_sign: | N/A |
51
+ | `subscriptionStatus` | [models.SubscriptionStatus](../../sdk/models/subscription-status.md) | :heavy_minus_sign: | N/A |
52
+ | `taxRateOverrides` | [models.TaxRateOverride](../../sdk/models/tax-rate-override.md)[] | :heavy_minus_sign: | tax_rate_overrides is the tax rate overrides to be applied to the subscription |
53
+ | `trialEnd` | [Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date) | :heavy_minus_sign: | N/A |
54
+ | `trialStart` | [Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date) | :heavy_minus_sign: | N/A |
@@ -0,0 +1,15 @@
1
+ # EnvironmentType
2
+
3
+ ## Example Usage
4
+
5
+ ```typescript
6
+ import { EnvironmentType } from "@flexprice/sdk/sdk/models";
7
+
8
+ let value: EnvironmentType = "production";
9
+ ```
10
+
11
+ ## Values
12
+
13
+ ```typescript
14
+ "development" | "production"
15
+ ```
@@ -6,6 +6,22 @@
6
6
  import { SubscriptionModifyResponse } from "@flexprice/sdk/sdk/models";
7
7
 
8
8
  let value: SubscriptionModifyResponse = {
9
+ changedResources: {
10
+ invoices: [
11
+ {
12
+ invoice: {
13
+ subscription: {
14
+ latestInvoice: {
15
+ subscription: {
16
+ plan: {},
17
+ },
18
+ },
19
+ plan: {},
20
+ },
21
+ },
22
+ },
23
+ ],
24
+ },
9
25
  subscription: {
10
26
  latestInvoice: {
11
27
  subscription: {
@@ -5,7 +5,7 @@
5
5
  ```typescript
6
6
  import { WindowSize } from "@flexprice/sdk/sdk/models";
7
7
 
8
- let value: WindowSize = "12HOUR";
8
+ let value: WindowSize = "6HOUR";
9
9
 
10
10
  // Open enum: unrecognized values are captured as Unrecognized<string>
11
11
  ```
@@ -13,5 +13,5 @@ let value: WindowSize = "12HOUR";
13
13
  ## Values
14
14
 
15
15
  ```typescript
16
- "MINUTE" | "15MIN" | "30MIN" | "HOUR" | "3HOUR" | "6HOUR" | "12HOUR" | "DAY" | "WEEK" | "MONTH" | Unrecognized<string>
16
+ "MONTH" | "MINUTE" | "15MIN" | "30MIN" | "HOUR" | "3HOUR" | "6HOUR" | "12HOUR" | "DAY" | "WEEK" | Unrecognized<string>
17
17
  ```