@paynow-gg/typescript-sdk 1.0.60 → 2.0.1

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 (140) hide show
  1. package/LICENSE +1 -1
  2. package/README.md +44 -5
  3. package/dist/cjs/generated/management/client.d.ts +895 -0
  4. package/dist/cjs/generated/management/client.d.ts.map +1 -0
  5. package/dist/cjs/generated/management/client.js +1568 -0
  6. package/dist/cjs/generated/management/client.js.map +1 -0
  7. package/dist/cjs/generated/management/types.d.ts +7566 -0
  8. package/dist/cjs/generated/management/types.d.ts.map +1 -0
  9. package/dist/cjs/generated/management/types.js +4 -0
  10. package/dist/cjs/generated/management/types.js.map +1 -0
  11. package/dist/cjs/generated/storefront/client.d.ts +229 -0
  12. package/dist/cjs/generated/storefront/client.d.ts.map +1 -0
  13. package/dist/cjs/generated/storefront/client.js +357 -0
  14. package/dist/cjs/generated/storefront/client.js.map +1 -0
  15. package/dist/cjs/generated/storefront/types.d.ts +3076 -0
  16. package/dist/cjs/generated/storefront/types.d.ts.map +1 -0
  17. package/dist/cjs/generated/storefront/types.js +4 -0
  18. package/dist/cjs/generated/storefront/types.js.map +1 -0
  19. package/dist/cjs/generated/webhooks/types.d.ts +3113 -0
  20. package/dist/cjs/generated/webhooks/types.d.ts.map +1 -0
  21. package/dist/cjs/generated/webhooks/types.js +4 -0
  22. package/dist/cjs/generated/webhooks/types.js.map +1 -0
  23. package/dist/cjs/index.d.ts +9 -0
  24. package/dist/cjs/index.d.ts.map +1 -0
  25. package/dist/cjs/index.js +16 -0
  26. package/dist/cjs/index.js.map +1 -0
  27. package/dist/cjs/management.d.ts +3 -0
  28. package/dist/cjs/management.d.ts.map +1 -0
  29. package/dist/cjs/management.js +22 -0
  30. package/dist/cjs/management.js.map +1 -0
  31. package/dist/cjs/package.json +3 -0
  32. package/dist/cjs/runtime/errors.d.ts +18 -0
  33. package/dist/cjs/runtime/errors.d.ts.map +1 -0
  34. package/dist/cjs/runtime/errors.js +41 -0
  35. package/dist/cjs/runtime/errors.js.map +1 -0
  36. package/dist/cjs/runtime/http.d.ts +20 -0
  37. package/dist/cjs/runtime/http.d.ts.map +1 -0
  38. package/dist/cjs/runtime/http.js +121 -0
  39. package/dist/cjs/runtime/http.js.map +1 -0
  40. package/dist/cjs/runtime/options.d.ts +12 -0
  41. package/dist/cjs/runtime/options.d.ts.map +1 -0
  42. package/dist/{types.js → cjs/runtime/options.js} +1 -1
  43. package/dist/cjs/runtime/options.js.map +1 -0
  44. package/dist/cjs/storefront.d.ts +3 -0
  45. package/dist/cjs/storefront.d.ts.map +1 -0
  46. package/dist/cjs/storefront.js +22 -0
  47. package/dist/cjs/storefront.js.map +1 -0
  48. package/dist/cjs/webhooks.d.ts +2 -0
  49. package/dist/cjs/webhooks.d.ts.map +1 -0
  50. package/dist/cjs/webhooks.js +18 -0
  51. package/dist/cjs/webhooks.js.map +1 -0
  52. package/dist/esm/generated/management/client.d.ts +895 -0
  53. package/dist/esm/generated/management/client.d.ts.map +1 -0
  54. package/dist/esm/generated/management/client.js +1531 -0
  55. package/dist/esm/generated/management/client.js.map +1 -0
  56. package/dist/esm/generated/management/types.d.ts +7566 -0
  57. package/dist/esm/generated/management/types.d.ts.map +1 -0
  58. package/dist/esm/generated/management/types.js +3 -0
  59. package/dist/esm/generated/management/types.js.map +1 -0
  60. package/dist/esm/generated/storefront/client.d.ts +229 -0
  61. package/dist/esm/generated/storefront/client.d.ts.map +1 -0
  62. package/dist/esm/generated/storefront/client.js +340 -0
  63. package/dist/esm/generated/storefront/client.js.map +1 -0
  64. package/dist/esm/generated/storefront/types.d.ts +3076 -0
  65. package/dist/esm/generated/storefront/types.d.ts.map +1 -0
  66. package/dist/esm/generated/storefront/types.js +3 -0
  67. package/dist/esm/generated/storefront/types.js.map +1 -0
  68. package/dist/esm/generated/webhooks/types.d.ts +3113 -0
  69. package/dist/esm/generated/webhooks/types.d.ts.map +1 -0
  70. package/dist/esm/generated/webhooks/types.js +3 -0
  71. package/dist/esm/generated/webhooks/types.js.map +1 -0
  72. package/dist/esm/index.d.ts +9 -0
  73. package/dist/esm/index.d.ts.map +1 -0
  74. package/dist/esm/index.js +5 -0
  75. package/dist/esm/index.js.map +1 -0
  76. package/dist/esm/management.d.ts +3 -0
  77. package/dist/esm/management.d.ts.map +1 -0
  78. package/dist/esm/management.js +3 -0
  79. package/dist/esm/management.js.map +1 -0
  80. package/dist/esm/package.json +3 -0
  81. package/dist/esm/runtime/errors.d.ts +18 -0
  82. package/dist/esm/runtime/errors.d.ts.map +1 -0
  83. package/dist/esm/runtime/errors.js +36 -0
  84. package/dist/esm/runtime/errors.js.map +1 -0
  85. package/dist/esm/runtime/http.d.ts +20 -0
  86. package/dist/esm/runtime/http.d.ts.map +1 -0
  87. package/dist/esm/runtime/http.js +117 -0
  88. package/dist/esm/runtime/http.js.map +1 -0
  89. package/dist/esm/runtime/options.d.ts +12 -0
  90. package/dist/esm/runtime/options.d.ts.map +1 -0
  91. package/dist/esm/runtime/options.js +2 -0
  92. package/dist/esm/runtime/options.js.map +1 -0
  93. package/dist/esm/storefront.d.ts +3 -0
  94. package/dist/esm/storefront.d.ts.map +1 -0
  95. package/dist/esm/storefront.js +3 -0
  96. package/dist/esm/storefront.js.map +1 -0
  97. package/dist/esm/webhooks.d.ts +2 -0
  98. package/dist/esm/webhooks.d.ts.map +1 -0
  99. package/dist/esm/webhooks.js +2 -0
  100. package/dist/esm/webhooks.js.map +1 -0
  101. package/package.json +74 -15
  102. package/dist/client.d.ts +0 -73
  103. package/dist/client.d.ts.map +0 -1
  104. package/dist/client.js +0 -55
  105. package/dist/client.js.map +0 -1
  106. package/dist/errors.d.ts +0 -7
  107. package/dist/errors.d.ts.map +0 -1
  108. package/dist/errors.js +0 -14
  109. package/dist/errors.js.map +0 -1
  110. package/dist/generate.d.ts +0 -2
  111. package/dist/generate.d.ts.map +0 -1
  112. package/dist/generate.js +0 -102
  113. package/dist/generate.js.map +0 -1
  114. package/dist/generated/management.d.ts +0 -12769
  115. package/dist/generated/management.d.ts.map +0 -1
  116. package/dist/generated/management.js +0 -638
  117. package/dist/generated/management.js.map +0 -1
  118. package/dist/generated/storefront.d.ts +0 -3462
  119. package/dist/generated/storefront.d.ts.map +0 -1
  120. package/dist/generated/storefront.js +0 -90
  121. package/dist/generated/storefront.js.map +0 -1
  122. package/dist/generated/webhooks.d.ts +0 -3659
  123. package/dist/generated/webhooks.d.ts.map +0 -1
  124. package/dist/generated/webhooks.js +0 -5
  125. package/dist/generated/webhooks.js.map +0 -1
  126. package/dist/index.d.ts +0 -12
  127. package/dist/index.d.ts.map +0 -1
  128. package/dist/index.js +0 -10
  129. package/dist/index.js.map +0 -1
  130. package/dist/management.d.ts +0 -7
  131. package/dist/management.d.ts.map +0 -1
  132. package/dist/management.js +0 -12
  133. package/dist/management.js.map +0 -1
  134. package/dist/storefront.d.ts +0 -7
  135. package/dist/storefront.d.ts.map +0 -1
  136. package/dist/storefront.js +0 -13
  137. package/dist/storefront.js.map +0 -1
  138. package/dist/types.d.ts +0 -12
  139. package/dist/types.d.ts.map +0 -1
  140. package/dist/types.js.map +0 -1
@@ -0,0 +1,895 @@
1
+ import { HttpClient } from "../../runtime/http.js";
2
+ import type { ClientOptions, RequestOptions } from "../../runtime/options.js";
3
+ import type { AbandonedCheckoutStoreConfigurationDto, AbandonedCheckoutStoreConfigurationUpdateDto, AffiliateLinkDto, BanDto, BansGetBansQuery, CancelSubscriptionRequestDto, CheckForBanIDByIdentitiesRequestDto, CheckForBanIDByIdentitiesResponseDto, CommandAttemptDto, CouponDto, CouponsGetCouponsForStoreQuery, CreateAffiliateLinkDto, CreateCheckoutSessionManagementDto, CreateCheckoutSessionResponseDto, CreateCouponDto, CreateCustomerPortalSessionRequestDto, CreateDownloadableFileDownloadUrlResponseDto, CreateEmailTemplateDto, CreateGameServerConsoleDto, CreateGameServerDto, CreateGiftCardDto, CreateNavLinkDto, CreateProductDependentMigrationRequestDto, CreateRefundRequestDto, CreateSaleDto, CreateTierGroupRequestDto, CreateTrialEligibilityOverrideDto, CreateWebhookDto, CustomerDto, CustomerPortalSessionDto, CustomersGetCustomersQuery, CustomersLookupCustomerQuery, CustomerTokenResponseDto, CustomVariableDto, DataMigrationsGetDataMigrationsQuery, DataMigrationTaskDto, DeactivateEmailTemplateRequestDto, DeliveryGetCommandAttemptsForCustomerQuery, DeliveryGetCustomerDeliveryItemsQuery, DeliveryGetGameServerDeliveryItemsQuery, DeliveryGetOrderDeliveryItemsQuery, DeliveryGetStoreDeliveryItemsQuery, DeliveryItemAssignmentBulkDto, DeliveryItemAssignmentDto, DeliveryItemDto, DiscordActionDto, DiscordProfileDto, DiscordServerChannelDto, DiscordServerLinkDto, DiscordServerRoleDto, DiscordSetUserToDeliveryItemLinkQuery, EmailBrandingDto, EmailDeliveryDto, EmailTemplateDefinitionDto, EmailTemplateDto, FinishEmailBrandingImageUploadRequestDto, FinishTagImageUploadUrlRequestDto, FlakeId, GameServerConsoleDto, GameServerConsoleMessageDto, GameServerDto, GetEmailBrandingImageUploadUrlResponseDto, GetTagImageUploadUrlResponseDto, GiftCardDto, GiftcardsGetGiftCardsQuery, GlobalCommandDto, InvoiceDownloadUrlResponseDto, InvoiceDto, InvoicesListInvoicesQuery, MarketingGetEmailBrandingImageUploadUrlQuery, MarketingGetEmailDeliveriesQuery, MarketingGetEmailTemplatesQuery, NavLinkDto, OrderDto, OrdersGetOrdersQuery, PaymentDto, PaymentMethodTypeDto, PaymentsGetPaymentsQuery, ProductDependentMigrationDto, ProductDependentMigrationEstimateVersionDto, ProductDependentMigrationsGetProductDependentMigrationsQuery, ProductDownloadableFileDto, ProductDto, ProductPricingRegionDto, ProductPricingRegionGroupDto, ProductPricingRegionOverrideDto, ProductsGetProductsQuery, PurchaseFollowUpStoreConfigurationDto, PurchaseFollowUpStoreConfigurationUpdateDto, QueuedDiscordActionDto, RefundDto, ResendCommandsForGameServerRequestDto, ResendCommandsForGameServerResponseDto, ResendWebhookDto, SaleDto, SetDiscordActionDto, StartDataMigrationFromTebexRequestDto, StartDownloadableFileUploadRequestDto, StoreDto, StoreMemberDto, StorePaymentSettingsDto, StorePricingRegionOverrideDto, StoreUpsellSettingsDto, SubscriptionDto, SubscriptionsGetSubscriptionsQuery, TagDto, TierGroupDto, ToggleStorePaymentMethodTypeRequestDto, TrialDto, TrialEligibilityOverrideDto, TrialsGetEligibilityOverridesForCustomerQuery, TrialsGetTrialsQuery, UnqueueCommandsRequestDto, UnqueueCommandsResponseDto, UpdateAffiliateLinkDto, UpdateCouponDto, UpdateEmailBrandingDto, UpdateEmailTemplateDto, UpdateGameServerConsoleDto, UpdateGameServerDto, UpdateGiftCardDto, UpdateNavLinkDto, UpdateNavLinkOrderChangeDto, UpdateProductSortOrderRequestDto, UpdateSaleDto, UpdateStoreDto, UpdateStoreMemberDto, UpdateStorePaymentSettingsDto, UpdateStoreUpsellSettingsDto, UpdateSubscriptionRequestDto, UpdateSubscriptionResponseDto, UpdateTierGroupRequestDto, UpdateWebhookDto, UpsertBanRequestDto, UpsertCustomerRequestDto, UpsertCustomVariableRequestDto, UpsertGlobalCommandDto, UpsertProductRequestDto, UpsertTagRequestDto, WebhookHistoryDto, WebhookSubscriptionDto, WebhooksGetHistoryQuery, WebhookVariablesDto } from "./types.js";
4
+ export declare class AffiliateLinksResource {
5
+ private readonly http;
6
+ constructor(http: HttpClient);
7
+ createAffiliateLink(body: CreateAffiliateLinkDto, opts?: RequestOptions): Promise<AffiliateLinkDto>;
8
+ deleteAffiliateLink(affiliateLinkId: FlakeId, opts?: RequestOptions): Promise<void>;
9
+ getAffiliateLink(affiliateLinkId: FlakeId, opts?: RequestOptions): Promise<AffiliateLinkDto>;
10
+ getAffiliateLinks(opts?: RequestOptions): Promise<Array<AffiliateLinkDto>>;
11
+ updateAffiliateLink(affiliateLinkId: FlakeId, body?: UpdateAffiliateLinkDto, opts?: RequestOptions): Promise<AffiliateLinkDto>;
12
+ }
13
+ export declare class BansResource {
14
+ private readonly http;
15
+ constructor(http: HttpClient);
16
+ checkForBanByIdentities(body: CheckForBanIDByIdentitiesRequestDto, opts?: RequestOptions): Promise<CheckForBanIDByIdentitiesResponseDto>;
17
+ createBan(body?: UpsertBanRequestDto, opts?: RequestOptions): Promise<BanDto>;
18
+ deleteBan(banId: FlakeId, opts?: RequestOptions): Promise<void>;
19
+ getBan(banId: FlakeId, opts?: RequestOptions): Promise<BanDto>;
20
+ getBans(query?: BansGetBansQuery, opts?: RequestOptions): Promise<Array<BanDto>>;
21
+ updateBan(banId: FlakeId, body?: UpsertBanRequestDto, opts?: RequestOptions): Promise<BanDto>;
22
+ }
23
+ export declare class CheckoutResource {
24
+ private readonly http;
25
+ constructor(http: HttpClient);
26
+ /**
27
+ * Create a checkout session
28
+ *
29
+ * Creates a checkout session from a secure server using an API Key.
30
+ * If you have a Customer token, see the Storefront API Create Checkout endpoint.
31
+ */
32
+ createCheckoutSession(body: CreateCheckoutSessionManagementDto, opts?: RequestOptions): Promise<CreateCheckoutSessionResponseDto>;
33
+ }
34
+ export declare class CouponsResource {
35
+ private readonly http;
36
+ constructor(http: HttpClient);
37
+ createCouponForStore(body: CreateCouponDto, opts?: RequestOptions): Promise<CouponDto>;
38
+ /**
39
+ * Deletes a coupon
40
+ */
41
+ deleteCouponForStore(couponId: FlakeId, opts?: RequestOptions): Promise<void>;
42
+ /**
43
+ * Retrieves a coupon by ID
44
+ */
45
+ getCouponByIdForStore(couponId: FlakeId, opts?: RequestOptions): Promise<CouponDto>;
46
+ /**
47
+ * Fetches all coupons for a store id
48
+ */
49
+ getCouponsForStore(query?: CouponsGetCouponsForStoreQuery, opts?: RequestOptions): Promise<Array<CouponDto>>;
50
+ /**
51
+ * Performs a Delta Update of a Coupon
52
+ */
53
+ updateCouponForStore(couponId: FlakeId, body?: UpdateCouponDto, opts?: RequestOptions): Promise<CouponDto>;
54
+ }
55
+ export declare class CustomerPortalSessionsResource {
56
+ private readonly http;
57
+ constructor(http: HttpClient);
58
+ /**
59
+ * Create a customer portal session
60
+ *
61
+ * Creates a customer portal session from a secure server using an API Key.
62
+ * The returned session contains the token and URL to hand to the customer.
63
+ * @param customerId The ID of the customer to create the portal session for.
64
+ */
65
+ createCustomerPortalSession(customerId: FlakeId, body: CreateCustomerPortalSessionRequestDto, opts?: RequestOptions): Promise<CustomerPortalSessionDto>;
66
+ }
67
+ export declare class CustomersResource {
68
+ private readonly http;
69
+ constructor(http: HttpClient);
70
+ /**
71
+ * Bulk create customers
72
+ *
73
+ * Creates up to 200 customers at once.
74
+ */
75
+ bulkCreateCustomers(body?: Array<UpsertCustomerRequestDto>, opts?: RequestOptions): Promise<Array<CustomerDto>>;
76
+ /**
77
+ * Create customer
78
+ *
79
+ * Creates a new customer based on the fields passed.
80
+ */
81
+ createCustomer(body?: UpsertCustomerRequestDto, opts?: RequestOptions): Promise<CustomerDto>;
82
+ /**
83
+ * Create customer token
84
+ *
85
+ * Generates a customer token that can be used by the Storefront (Headless) API.
86
+ * @param customerId The ID of the customer to generate the customer token for.
87
+ */
88
+ createCustomerToken(customerId: FlakeId, opts?: RequestOptions): Promise<CustomerTokenResponseDto>;
89
+ /**
90
+ * Get customer by ID
91
+ *
92
+ * Retrieves a customer by the ID for the specified store.
93
+ * @param customerId The ID of the customer.
94
+ */
95
+ getCustomerById(customerId: FlakeId, opts?: RequestOptions): Promise<CustomerDto>;
96
+ /**
97
+ * Get customers
98
+ *
99
+ * Retrieves all customers for the specified store.
100
+ */
101
+ getCustomers(query?: CustomersGetCustomersQuery, opts?: RequestOptions): Promise<Array<CustomerDto>>;
102
+ /**
103
+ * Invalidate customer tokens
104
+ *
105
+ * Invalidates all generated customer tokens.
106
+ * @param customerId The ID of the customer to invalidate the customer tokens for.
107
+ */
108
+ invalidateCustomerTokens(customerId: FlakeId, opts?: RequestOptions): Promise<void>;
109
+ /**
110
+ * Lookup customer
111
+ *
112
+ * Looks up a customer by an external platform ID.
113
+ */
114
+ lookupCustomer(query?: CustomersLookupCustomerQuery, opts?: RequestOptions): Promise<CustomerDto>;
115
+ /**
116
+ * Update customer
117
+ *
118
+ * Updates an existing customer based on the fields passed.
119
+ */
120
+ updateCustomer(customerId: FlakeId, body?: UpsertCustomerRequestDto, opts?: RequestOptions): Promise<CustomerDto>;
121
+ }
122
+ export declare class CustomVariablesResource {
123
+ private readonly http;
124
+ constructor(http: HttpClient);
125
+ /**
126
+ * Create custom variable
127
+ *
128
+ * Creates a new custom variable for the specified store.
129
+ * Custom variables allow customers to provide additional input when purchasing products.
130
+ */
131
+ createCustomVariableForStore(body: UpsertCustomVariableRequestDto, opts?: RequestOptions): Promise<CustomVariableDto>;
132
+ /**
133
+ * Delete custom variable
134
+ *
135
+ * Deletes a custom variable from the specified store.
136
+ * This will also delete all associated options and cannot be undone.
137
+ * @param customVariableId The ID of the custom variable to delete.
138
+ */
139
+ deleteCustomVariableForStore(customVariableId: FlakeId, opts?: RequestOptions): Promise<void>;
140
+ /**
141
+ * Get custom variable
142
+ *
143
+ * Retrieves a specific custom variable by ID from the specified store.
144
+ * @param customVariableId The ID of the custom variable to retrieve.
145
+ */
146
+ getCustomVariableByIdForStore(customVariableId: FlakeId, opts?: RequestOptions): Promise<CustomVariableDto>;
147
+ /**
148
+ * Get custom variables
149
+ *
150
+ * Retrieves all custom variables for the specified store.
151
+ */
152
+ getCustomVariablesForStore(opts?: RequestOptions): Promise<Array<CustomVariableDto>>;
153
+ /**
154
+ * Update custom variable
155
+ *
156
+ * Performs a partial update of a custom variable using field mask.
157
+ * Only the fields specified in the request will be updated.
158
+ * @param customVariableId The ID of the custom variable to update.
159
+ */
160
+ updateCustomVariableForStore(customVariableId: FlakeId, body: UpsertCustomVariableRequestDto, opts?: RequestOptions): Promise<CustomVariableDto>;
161
+ }
162
+ export declare class DataMigrationsResource {
163
+ private readonly http;
164
+ constructor(http: HttpClient);
165
+ getDataMigrations(query?: DataMigrationsGetDataMigrationsQuery, opts?: RequestOptions): Promise<Array<DataMigrationTaskDto>>;
166
+ startDataMigrationFromTebex(body: StartDataMigrationFromTebexRequestDto, opts?: RequestOptions): Promise<Array<DataMigrationTaskDto>>;
167
+ }
168
+ export declare class DeliveryResource {
169
+ private readonly http;
170
+ constructor(http: HttpClient);
171
+ /**
172
+ * Assign a delivery item to a customer
173
+ *
174
+ * Allows you to assign a delivery item to a customer
175
+ */
176
+ assignDeliveryItem(customerId: FlakeId, body?: DeliveryItemAssignmentDto, opts?: RequestOptions): Promise<Array<DeliveryItemDto>>;
177
+ /**
178
+ * Assign delivery items in bulk
179
+ *
180
+ * Allows you to assign multiple delivery items for multiple customers in bulk
181
+ */
182
+ assignDeliveryItemsBulk(body?: Array<DeliveryItemAssignmentBulkDto>, opts?: RequestOptions): Promise<Array<DeliveryItemDto>>;
183
+ /**
184
+ * Get command attempts associated with a customer
185
+ *
186
+ * Retrieves command attempts associated with a customer
187
+ */
188
+ getCommandAttemptsForCustomer(customerId: FlakeId, query?: DeliveryGetCommandAttemptsForCustomerQuery, opts?: RequestOptions): Promise<Array<CommandAttemptDto>>;
189
+ /**
190
+ * Get delivery items associated with a customer
191
+ *
192
+ * Retrieves delivery items associated with a customer
193
+ */
194
+ getCustomerDeliveryItems(customerId: FlakeId, query?: DeliveryGetCustomerDeliveryItemsQuery, opts?: RequestOptions): Promise<Array<DeliveryItemDto>>;
195
+ /**
196
+ * Returns delivery items in which an associated command attempt is for the gameserver
197
+ */
198
+ getGameServerDeliveryItems(gameServerId: FlakeId, query?: DeliveryGetGameServerDeliveryItemsQuery, opts?: RequestOptions): Promise<Array<DeliveryItemDto>>;
199
+ /**
200
+ * Get delivery items associated with an order
201
+ *
202
+ * Retrieves all delivery items associated with a specific order.
203
+ * @param orderId The ID of the order to retrieve delivery items from.
204
+ */
205
+ getOrderDeliveryItems(orderId: FlakeId, query?: DeliveryGetOrderDeliveryItemsQuery, opts?: RequestOptions): Promise<Array<DeliveryItemDto>>;
206
+ /**
207
+ * Get all delivery items
208
+ *
209
+ * Retrieves all delivery items associated with this store (paginated)
210
+ */
211
+ getStoreDeliveryItems(query?: DeliveryGetStoreDeliveryItemsQuery, opts?: RequestOptions): Promise<Array<DeliveryItemDto>>;
212
+ /**
213
+ * Resend commands for a given Gameserver
214
+ */
215
+ resendDeliveryCommandsForGameServer(gameServerId: FlakeId, body?: ResendCommandsForGameServerRequestDto, opts?: RequestOptions): Promise<ResendCommandsForGameServerResponseDto>;
216
+ /**
217
+ * Revoke a delivery item from a customer
218
+ *
219
+ * Allows you to revoke a delivery item associated with a customer
220
+ */
221
+ revokeDeliveryItem(customerId: FlakeId, deliveryItemId: FlakeId, opts?: RequestOptions): Promise<void>;
222
+ /**
223
+ * Unqueue commands by Attempt IDs
224
+ */
225
+ unqueueDeliveryCommandAttemptByAttemptIDs(body: UnqueueCommandsRequestDto, opts?: RequestOptions): Promise<UnqueueCommandsResponseDto>;
226
+ }
227
+ export declare class DiscordResource {
228
+ private readonly http;
229
+ constructor(http: HttpClient);
230
+ createAction(productVersionId: FlakeId, body?: Array<SetDiscordActionDto>, opts?: RequestOptions): Promise<DiscordActionDto>;
231
+ createDiscordServerLink(opts?: RequestOptions): Promise<DiscordServerLinkDto>;
232
+ deleteDiscordServerLinks(token: string, opts?: RequestOptions): Promise<Array<DiscordServerLinkDto>>;
233
+ deleteUserToDeliveryItemLink(inventoryItemId: FlakeId, opts?: RequestOptions): Promise<void>;
234
+ getActions(productVersionId: FlakeId, opts?: RequestOptions): Promise<Array<DiscordActionDto>>;
235
+ getDiscordActionExecutionHistory(orderId: FlakeId, opts?: RequestOptions): Promise<Array<QueuedDiscordActionDto>>;
236
+ getDiscordServerLinks(opts?: RequestOptions): Promise<Array<DiscordServerLinkDto>>;
237
+ getDiscordServerRoles(discordServerId: number, opts?: RequestOptions): Promise<Array<DiscordServerRoleDto>>;
238
+ getDiscordServerTextChannels(discordServerId: number, opts?: RequestOptions): Promise<Array<DiscordServerChannelDto>>;
239
+ getLinkedDiscordAccounts(orderId: FlakeId, opts?: RequestOptions): Promise<Record<string, DiscordProfileDto>>;
240
+ getQueuedDiscordActionForDeliveryItem(inventoryItemId: FlakeId, opts?: RequestOptions): Promise<Array<QueuedDiscordActionDto>>;
241
+ getUserToDeliveryItemLinks(inventoryItemId: FlakeId, opts?: RequestOptions): Promise<DiscordProfileDto>;
242
+ setUserToDeliveryItemLink(inventoryItemId: FlakeId, query?: DiscordSetUserToDeliveryItemLinkQuery, opts?: RequestOptions): Promise<void>;
243
+ }
244
+ export declare class DownloadableFilesResource {
245
+ private readonly http;
246
+ constructor(http: HttpClient);
247
+ createDownloadUrl(productId: FlakeId, downloadableFileId: FlakeId, opts?: RequestOptions): Promise<CreateDownloadableFileDownloadUrlResponseDto>;
248
+ deleteDownloadableFile(productId: FlakeId, downloadableFileId: FlakeId, opts?: RequestOptions): Promise<void>;
249
+ finishDownloadableFileUpload(productId: FlakeId, downloadableFileId: FlakeId, opts?: RequestOptions): Promise<void>;
250
+ getDownloadableFiles(productId: FlakeId, opts?: RequestOptions): Promise<Array<ProductDownloadableFileDto>>;
251
+ startDownloadableFileUpload(productId: FlakeId, body: StartDownloadableFileUploadRequestDto, opts?: RequestOptions): Promise<void>;
252
+ }
253
+ export declare class GameServersResource {
254
+ private readonly http;
255
+ constructor(http: HttpClient);
256
+ /**
257
+ * Create a new Game Server for a store
258
+ */
259
+ createGameServer(body: CreateGameServerDto, opts?: RequestOptions): Promise<GameServerDto>;
260
+ /**
261
+ * Create a console for a game server.
262
+ */
263
+ createGameServerConsole(gameServerId: FlakeId, body: CreateGameServerConsoleDto, opts?: RequestOptions): Promise<GameServerConsoleDto>;
264
+ /**
265
+ * Delete a Game Server by ID for a store
266
+ */
267
+ deleteGameServer(gameServerId: FlakeId, opts?: RequestOptions): Promise<void>;
268
+ /**
269
+ * Delete an associated game server console.
270
+ */
271
+ deleteGameServerConsole(gameServerId: FlakeId, opts?: RequestOptions): Promise<void>;
272
+ /**
273
+ * Get a Game Server by ID for a store
274
+ */
275
+ getGameServer(gameServerId: FlakeId, opts?: RequestOptions): Promise<Array<GameServerDto>>;
276
+ /**
277
+ * Get the associated console for a game server.
278
+ */
279
+ getGameServerConsole(gameServerId: FlakeId, opts?: RequestOptions): Promise<GameServerConsoleDto>;
280
+ /**
281
+ * Get console messages for a game server.
282
+ */
283
+ getGameServerConsoleMessages(gameServerId: FlakeId, opts?: RequestOptions): Promise<Array<GameServerConsoleMessageDto>>;
284
+ /**
285
+ * Get Game Servers for a store
286
+ */
287
+ getGameServers(opts?: RequestOptions): Promise<Array<GameServerDto>>;
288
+ /**
289
+ * Reset the API Key Token for a Game Server for a store
290
+ */
291
+ resetGameServerToken(gameServerId: FlakeId, opts?: RequestOptions): Promise<GameServerDto>;
292
+ /**
293
+ * Update a Game Server By ID for a store
294
+ */
295
+ updateGameServer(gameServerId: FlakeId, body?: UpdateGameServerDto, opts?: RequestOptions): Promise<GameServerDto>;
296
+ /**
297
+ * Update a console for a game server.
298
+ */
299
+ updateGameServerConsole(gameServerId: FlakeId, body?: UpdateGameServerConsoleDto, opts?: RequestOptions): Promise<GameServerConsoleDto>;
300
+ }
301
+ export declare class GiftcardsResource {
302
+ private readonly http;
303
+ constructor(http: HttpClient);
304
+ /**
305
+ * Create a Gift Card for a store
306
+ */
307
+ createGiftCard(body: CreateGiftCardDto, opts?: RequestOptions): Promise<GiftCardDto>;
308
+ /**
309
+ * Delete a Gift Card By ID for a store
310
+ */
311
+ deleteGiftCard(giftCardId: FlakeId, opts?: RequestOptions): Promise<GiftCardDto>;
312
+ /**
313
+ * Get a Gift Card By ID for a store
314
+ */
315
+ getGiftCard(giftCardId: FlakeId, opts?: RequestOptions): Promise<GiftCardDto>;
316
+ /**
317
+ * Get Gift Cards for a store
318
+ */
319
+ getGiftCards(query?: GiftcardsGetGiftCardsQuery, opts?: RequestOptions): Promise<Array<GiftCardDto>>;
320
+ /**
321
+ * Update a Gift Card By ID for a store
322
+ */
323
+ updateGiftCard(giftCardId: FlakeId, body?: UpdateGiftCardDto, opts?: RequestOptions): Promise<GiftCardDto>;
324
+ }
325
+ export declare class GlobalCommandsResource {
326
+ private readonly http;
327
+ constructor(http: HttpClient);
328
+ /**
329
+ * Create global command
330
+ *
331
+ * Creates a global command for a store.
332
+ */
333
+ createGlobalCommand(body: UpsertGlobalCommandDto, opts?: RequestOptions): Promise<GlobalCommandDto>;
334
+ /**
335
+ * Delete global command
336
+ *
337
+ * Deletes a global command for a store.
338
+ * @param globalCommandId The ID of the command to delete.
339
+ */
340
+ deleteGlobalCommand(globalCommandId: FlakeId, opts?: RequestOptions): Promise<void>;
341
+ /**
342
+ * Get global commands
343
+ *
344
+ * Retrieves all global commands for the specified store.
345
+ */
346
+ getGlobalCommands(opts?: RequestOptions): Promise<Array<GlobalCommandDto>>;
347
+ /**
348
+ * Update global command
349
+ *
350
+ * Updates a global command for a store.
351
+ */
352
+ updateGlobalCommand(globalCommandId: FlakeId, body: UpsertGlobalCommandDto, opts?: RequestOptions): Promise<GlobalCommandDto>;
353
+ }
354
+ export declare class InvoicesResource {
355
+ private readonly http;
356
+ constructor(http: HttpClient);
357
+ /**
358
+ * Download invoice
359
+ *
360
+ * Retrieves a temporary download URL for the invoice PDF.
361
+ * @param invoiceId The ID of the invoice to download.
362
+ */
363
+ downloadInvoice(invoiceId: FlakeId, opts?: RequestOptions): Promise<InvoiceDownloadUrlResponseDto>;
364
+ /**
365
+ * Get invoices
366
+ *
367
+ * Retrieves all invoices for the specified store.
368
+ */
369
+ listInvoices(query?: InvoicesListInvoicesQuery, opts?: RequestOptions): Promise<Array<InvoiceDto>>;
370
+ }
371
+ export declare class MarketingResource {
372
+ private readonly http;
373
+ constructor(http: HttpClient);
374
+ activateEmailTemplate(templateId: FlakeId, opts?: RequestOptions): Promise<void>;
375
+ createEmailTemplate(body: CreateEmailTemplateDto, opts?: RequestOptions): Promise<EmailTemplateDto>;
376
+ deactivateEmailTemplate(templateId: FlakeId, opts?: RequestOptions): Promise<void>;
377
+ deactivateEmailTemplateByType(body: DeactivateEmailTemplateRequestDto, opts?: RequestOptions): Promise<void>;
378
+ deleteEmailTemplate(templateId: FlakeId, opts?: RequestOptions): Promise<void>;
379
+ finishEmailBrandingImageUpload(body: FinishEmailBrandingImageUploadRequestDto, opts?: RequestOptions): Promise<void>;
380
+ getEmailBranding(opts?: RequestOptions): Promise<EmailBrandingDto>;
381
+ getEmailBrandingImageUploadUrl(query?: MarketingGetEmailBrandingImageUploadUrlQuery, opts?: RequestOptions): Promise<GetEmailBrandingImageUploadUrlResponseDto>;
382
+ getEmailDeliveries(query?: MarketingGetEmailDeliveriesQuery, opts?: RequestOptions): Promise<Array<EmailDeliveryDto>>;
383
+ getEmailDelivery(emailDeliveryId: FlakeId, opts?: RequestOptions): Promise<EmailDeliveryDto>;
384
+ getEmailTemplate(templateId: FlakeId, opts?: RequestOptions): Promise<EmailTemplateDto>;
385
+ getEmailTemplateDefinitions(opts?: RequestOptions): Promise<Array<EmailTemplateDefinitionDto> | undefined>;
386
+ getEmailTemplates(query?: MarketingGetEmailTemplatesQuery, opts?: RequestOptions): Promise<Array<EmailTemplateDto>>;
387
+ /**
388
+ * Gets the abandoned checkout behaviour for a store
389
+ */
390
+ getStoreAbandonedCheckoutConfigurationOptions(opts?: RequestOptions): Promise<AbandonedCheckoutStoreConfigurationDto>;
391
+ /**
392
+ * Gets the purchase follow up behaviour for a store
393
+ */
394
+ getStorePurchaseFollowUpConfigurationOptions(opts?: RequestOptions): Promise<PurchaseFollowUpStoreConfigurationDto>;
395
+ /**
396
+ * Sets the abandoned checkout behaviour for a store
397
+ */
398
+ setStoreAbandonedCheckoutConfigurationOptions(body: AbandonedCheckoutStoreConfigurationUpdateDto, opts?: RequestOptions): Promise<AbandonedCheckoutStoreConfigurationDto | undefined>;
399
+ /**
400
+ * Sets the purchase follow up behaviour for a store
401
+ */
402
+ setStorePurchaseFollowUpConfigurationOptions(body: PurchaseFollowUpStoreConfigurationUpdateDto, opts?: RequestOptions): Promise<PurchaseFollowUpStoreConfigurationDto | undefined>;
403
+ updateEmailBranding(body?: UpdateEmailBrandingDto, opts?: RequestOptions): Promise<EmailBrandingDto>;
404
+ updateEmailTemplate(templateId: FlakeId, body?: UpdateEmailTemplateDto, opts?: RequestOptions): Promise<EmailTemplateDto>;
405
+ }
406
+ export declare class NavlinksResource {
407
+ private readonly http;
408
+ constructor(http: HttpClient);
409
+ /**
410
+ * Create a new NavLink for a store
411
+ */
412
+ createNavLink(body: CreateNavLinkDto, opts?: RequestOptions): Promise<NavLinkDto>;
413
+ /**
414
+ * Delete a NavLink for a store
415
+ */
416
+ deleteNavLink(navLinkId: FlakeId, opts?: RequestOptions): Promise<void>;
417
+ /**
418
+ * Get a NavLink by ID for a store
419
+ */
420
+ getNavLink(navLinkId: FlakeId, opts?: RequestOptions): Promise<NavLinkDto>;
421
+ /**
422
+ * Get all NavLinks for a store
423
+ */
424
+ getNavLinks(opts?: RequestOptions): Promise<Array<NavLinkDto>>;
425
+ /**
426
+ * Update a NavLink By ID for a store
427
+ */
428
+ updateNavLink(navLinkId: FlakeId, body?: UpdateNavLinkDto, opts?: RequestOptions): Promise<NavLinkDto>;
429
+ /**
430
+ * Update the sort orders of NavLinks for a Store
431
+ */
432
+ updateNavLinkOrder(body?: Array<UpdateNavLinkOrderChangeDto>, opts?: RequestOptions): Promise<void>;
433
+ }
434
+ export declare class OrdersResource {
435
+ private readonly http;
436
+ constructor(http: HttpClient);
437
+ /**
438
+ * Get order by ID
439
+ *
440
+ * Retrieves an order by the ID for the specified store.
441
+ * @param orderId The ID of the order.
442
+ */
443
+ getOrderById(orderId: FlakeId, opts?: RequestOptions): Promise<OrderDto>;
444
+ /**
445
+ * Get orders
446
+ *
447
+ * Retrieves all orders for the specified store.
448
+ */
449
+ getOrders(query?: OrdersGetOrdersQuery, opts?: RequestOptions): Promise<Array<OrderDto>>;
450
+ /**
451
+ * Refund order by ID
452
+ *
453
+ * Creates a refund for an order by the ID for the specified store.
454
+ * @param orderId The ID of the order.
455
+ */
456
+ refundOrder(orderId: FlakeId, body?: CreateRefundRequestDto, opts?: RequestOptions): Promise<RefundDto>;
457
+ }
458
+ export declare class PaymentMethodTypesResource {
459
+ private readonly http;
460
+ constructor(http: HttpClient);
461
+ /**
462
+ * Get store payment method types
463
+ *
464
+ * Retrieves all payment method types associated with a store
465
+ */
466
+ getStorePaymentMethodTypes(opts?: RequestOptions): Promise<Array<PaymentMethodTypeDto>>;
467
+ /**
468
+ * Request approval for a store payment method type
469
+ *
470
+ * Requests approval to use a payment method type that requires manual review
471
+ */
472
+ requestStorePaymentMethodTypeApproval(paymentMethodTypeId: string, opts?: RequestOptions): Promise<void>;
473
+ /**
474
+ * Toggle a store payment method type
475
+ *
476
+ * Enables or disabled a payment method type for a store
477
+ */
478
+ toggleStorePaymentMethodType(paymentMethodTypeId: string, body: ToggleStorePaymentMethodTypeRequestDto, opts?: RequestOptions): Promise<void>;
479
+ }
480
+ export declare class PaymentsResource {
481
+ private readonly http;
482
+ constructor(http: HttpClient);
483
+ /**
484
+ * Get payment by ID
485
+ *
486
+ * Retrieves a payment by an ID.
487
+ */
488
+ getPaymentById(paymentId: FlakeId, opts?: RequestOptions): Promise<PaymentDto>;
489
+ /**
490
+ * Get payments
491
+ *
492
+ * Retrieves all payments for the specified store using the filter specified.
493
+ */
494
+ getPayments(query?: PaymentsGetPaymentsQuery, opts?: RequestOptions): Promise<Array<PaymentDto>>;
495
+ }
496
+ export declare class PaymentSettingsResource {
497
+ private readonly http;
498
+ constructor(http: HttpClient);
499
+ /**
500
+ * Get store payment settings
501
+ *
502
+ * Retrieves payment settings for a store.
503
+ */
504
+ getStorePaymentSettings(opts?: RequestOptions): Promise<StorePaymentSettingsDto>;
505
+ /**
506
+ * Updates store payment settings
507
+ *
508
+ * Updates payment settings for a store.
509
+ */
510
+ updateStorePaymentSettings(body?: UpdateStorePaymentSettingsDto, opts?: RequestOptions): Promise<void>;
511
+ }
512
+ export declare class ProductDependentMigrationsResource {
513
+ private readonly http;
514
+ constructor(http: HttpClient);
515
+ createProductDependentMigration(productId: FlakeId, body: CreateProductDependentMigrationRequestDto, opts?: RequestOptions): Promise<ProductDependentMigrationDto>;
516
+ getProductDependentMigrationById(productDependentMigrationId: FlakeId, opts?: RequestOptions): Promise<ProductDependentMigrationDto>;
517
+ getProductDependentMigrationEstimate(productId: FlakeId, opts?: RequestOptions): Promise<Array<ProductDependentMigrationEstimateVersionDto>>;
518
+ getProductDependentMigrations(productId: FlakeId, query?: ProductDependentMigrationsGetProductDependentMigrationsQuery, opts?: RequestOptions): Promise<Array<ProductDependentMigrationDto>>;
519
+ }
520
+ export declare class ProductsResource {
521
+ private readonly http;
522
+ constructor(http: HttpClient);
523
+ /**
524
+ * Create product
525
+ *
526
+ * Creates a new product in the specified store.
527
+ * Creating dynamic products while creating a checkout session via this endpoint without prior approval is prohibited and will result in store deactivation per our User Agreement.
528
+ */
529
+ createProduct(body?: UpsertProductRequestDto, opts?: RequestOptions): Promise<ProductDto>;
530
+ /**
531
+ * Delete product
532
+ *
533
+ * Deletes a product from the specified store.
534
+ * @param productId The ID of the product to delete.
535
+ */
536
+ deleteProduct(productId: FlakeId, opts?: RequestOptions): Promise<void>;
537
+ /**
538
+ * Get product
539
+ *
540
+ * Retrieves a specific product by ID from the specified store.
541
+ * DO NOT USE THIS ROUTE FOR DISPLAYING PRODUCTS ON YOUR STOREFRONT, use the storefront API instead.
542
+ * @param productId The ID of the product to retrieve.
543
+ */
544
+ getProduct(productId: FlakeId, opts?: RequestOptions): Promise<ProductDto>;
545
+ /**
546
+ * Get products
547
+ *
548
+ * Retrieves all products for the specified store.
549
+ * DO NOT USE THIS ROUTE FOR DISPLAYING PRODUCTS ON YOUR STOREFRONT, use the storefront API instead!
550
+ */
551
+ getProducts(query?: ProductsGetProductsQuery, opts?: RequestOptions): Promise<Array<ProductDto>>;
552
+ /**
553
+ * Update product
554
+ *
555
+ * Updates an existing product in the specified store.
556
+ * @param productId The ID of the product to update.
557
+ */
558
+ updateProduct(productId: FlakeId, body?: UpsertProductRequestDto, opts?: RequestOptions): Promise<ProductDto>;
559
+ /**
560
+ * Update product sort order
561
+ *
562
+ * Updates the sort order of products in the specified store.
563
+ */
564
+ updateProductSortOrder(body: UpdateProductSortOrderRequestDto, opts?: RequestOptions): Promise<ProductDto | undefined>;
565
+ }
566
+ export declare class RegionalPricingResource {
567
+ private readonly http;
568
+ constructor(http: HttpClient);
569
+ getProductPricingRegions(productId: FlakeId, opts?: RequestOptions): Promise<Array<ProductPricingRegionDto>>;
570
+ getStorePricingRegionGroups(opts?: RequestOptions): Promise<Array<ProductPricingRegionGroupDto>>;
571
+ getStorePricingRegions(opts?: RequestOptions): Promise<Array<ProductPricingRegionDto>>;
572
+ setProductPricingRegionOverride(productId: FlakeId, regionId: string, body?: ProductPricingRegionOverrideDto, opts?: RequestOptions): Promise<void>;
573
+ setStorePricingRegionOverride(regionId: string, body?: StorePricingRegionOverrideDto, opts?: RequestOptions): Promise<void>;
574
+ }
575
+ export declare class SalesResource {
576
+ private readonly http;
577
+ constructor(http: HttpClient);
578
+ /**
579
+ * Create a sale by ID for a store
580
+ */
581
+ createSale(body: CreateSaleDto, opts?: RequestOptions): Promise<SaleDto>;
582
+ /**
583
+ * Delete a sale by ID for a store
584
+ */
585
+ deleteSaleById(saleId: FlakeId, opts?: RequestOptions): Promise<void>;
586
+ /**
587
+ * Get a sale by ID for a store
588
+ */
589
+ getSale(saleId: FlakeId, opts?: RequestOptions): Promise<SaleDto>;
590
+ /**
591
+ * Get sales associated with a store.
592
+ */
593
+ getSales(opts?: RequestOptions): Promise<Array<SaleDto>>;
594
+ /**
595
+ * Update a sale by ID for a store
596
+ */
597
+ updateSale(saleId: FlakeId, body?: UpdateSaleDto, opts?: RequestOptions): Promise<SaleDto>;
598
+ }
599
+ export declare class StoreResource {
600
+ private readonly http;
601
+ constructor(http: HttpClient);
602
+ /**
603
+ * Get a store
604
+ *
605
+ * Retrieves a single store by its ID.
606
+ */
607
+ getStore(opts?: RequestOptions): Promise<StoreDto>;
608
+ /**
609
+ * Get store member permissions
610
+ *
611
+ * Retrieves the resolved permissions map for a specific member of a store.
612
+ */
613
+ getStoreMemberPermissions(memberId: FlakeId, opts?: RequestOptions): Promise<Record<string, boolean>>;
614
+ /**
615
+ * List store members
616
+ *
617
+ * Retrieves all members who have access to the specified store.
618
+ */
619
+ getStoreMembers(opts?: RequestOptions): Promise<Array<StoreMemberDto>>;
620
+ /**
621
+ * Get stores
622
+ *
623
+ * Retrieves all stores accessible to the authenticated user or API key.
624
+ */
625
+ getStores(opts?: RequestOptions): Promise<Array<StoreDto>>;
626
+ /**
627
+ * Remove a store member
628
+ *
629
+ * Removes the specified member from the store, revoking their access.
630
+ */
631
+ kickStoreMember(memberId: FlakeId, opts?: RequestOptions): Promise<void>;
632
+ /**
633
+ * Update a store
634
+ *
635
+ * Partially updates a store's configuration using the provided fields.
636
+ */
637
+ updateStore(body?: UpdateStoreDto, opts?: RequestOptions): Promise<StoreDto>;
638
+ /**
639
+ * Update a store member
640
+ *
641
+ * Updates the role assigned to a specific member of the store.
642
+ */
643
+ updateStoreMember(memberId: FlakeId, body: UpdateStoreMemberDto, opts?: RequestOptions): Promise<void>;
644
+ }
645
+ export declare class SubscriptionsResource {
646
+ private readonly http;
647
+ constructor(http: HttpClient);
648
+ /**
649
+ * Cancel subscription by ID
650
+ *
651
+ * Cancels a subscription for the specified store by the supplied ID.
652
+ * @param subscriptionId The ID of the subscription.
653
+ */
654
+ cancelSubscription(subscriptionId: FlakeId, body?: CancelSubscriptionRequestDto, opts?: RequestOptions): Promise<void>;
655
+ /**
656
+ * Get subscription by ID
657
+ *
658
+ * Retrieves a subscription for the specified store by the supplied ID.
659
+ * @param subscriptionId The ID of the subscription.
660
+ */
661
+ getSubscriptionById(subscriptionId: FlakeId, opts?: RequestOptions): Promise<SubscriptionDto>;
662
+ /**
663
+ * Get subscriptions
664
+ *
665
+ * Retrieves all subscriptions for the specified store.
666
+ */
667
+ getSubscriptions(query?: SubscriptionsGetSubscriptionsQuery, opts?: RequestOptions): Promise<Array<SubscriptionDto>>;
668
+ /**
669
+ * Preview a subscription change
670
+ *
671
+ * Simulates a subscription change and returns the pricing breakdown without creating any records or
672
+ * initiating a payment. Accepts the same request body as `POST change` — see that endpoint for
673
+ * full parameter documentation. Does not return the `pending_payment` field.
674
+ */
675
+ previewSubscriptionChange(subscriptionId: FlakeId, body: UpdateSubscriptionRequestDto, opts?: RequestOptions): Promise<UpdateSubscriptionResponseDto>;
676
+ /**
677
+ * Stop pending subscription cancellation
678
+ *
679
+ * Stops a pending subscription cancellation for the specified store by the supplied ID.
680
+ * @param subscriptionId The ID of the subscription.
681
+ */
682
+ stopPendingSubscriptionCancellation(subscriptionId: FlakeId, opts?: RequestOptions): Promise<void>;
683
+ /**
684
+ * Update items on a subscription
685
+ *
686
+ * Updates the subscription lines, including the pricing, on an active subscription. The subscription must not be within 1 hour of its
687
+ * next renewal, and only one change can be pending at a time.
688
+ *
689
+ * **Access**
690
+ *
691
+ * This endpoint requires the Subscription Updates API feature flag to be enabled on your store. Contact
692
+ * PayNow to request access.
693
+ *
694
+ * **Proration behavior**
695
+ *
696
+ * Controlled by the `proration_behavior` field on the request:
697
+ *
698
+ * - `immediate` - the change is applied as soon as possible.
699
+ * Proration is calculated for the remaining period. If the prorated amount is ≥ $0.50 (or equivalent in other currencies), an order is
700
+ * initiated against the subscription's payment method; the change is applied once the payment succeeds.
701
+ * If the prorated amount is below $0.50, no order is created and the change is
702
+ * applied instantly.
703
+ * Only one proration order is allowed per billing cycle - a second immediate change in the same
704
+ * period will be rejected if a proration was already charged.
705
+ * When a payment is triggered, the response will include a `pending_payment` object. The payment result
706
+ * is synchronous - check `pending_payment.declined` to determine whether the charge succeeded. If
707
+ * declined, `pending_payment.decline_code` contains the reason.
708
+ *
709
+ * - `next_billing_period` - no payment is created. The change is queued and will be applied automatically
710
+ * at the start of the next renewal cycle. Ideal for downgrades.
711
+ *
712
+ * - `none` - the change is applied instantly with no proration calculated or charged.
713
+ *
714
+ * **Reverting a pending change**
715
+ *
716
+ * If a `next_billing_period` change is pending and the new request specifies the same product versions
717
+ * that are already on the subscription (i.e. reverting back to the current state), the pending change
718
+ * is canceled rather than rejected. The canceled change record is returned in the response.
719
+ */
720
+ updateSubscription(subscriptionId: FlakeId, body: UpdateSubscriptionRequestDto, opts?: RequestOptions): Promise<UpdateSubscriptionResponseDto>;
721
+ }
722
+ export declare class TagsResource {
723
+ private readonly http;
724
+ constructor(http: HttpClient);
725
+ /**
726
+ * Create a new tag
727
+ */
728
+ createTag(body?: UpsertTagRequestDto, opts?: RequestOptions): Promise<TagDto>;
729
+ /**
730
+ * Delete a tag by ID
731
+ */
732
+ deleteTag(tagId: FlakeId, opts?: RequestOptions): Promise<void>;
733
+ /**
734
+ * Delete tag image
735
+ *
736
+ * Deletes an image for a tag
737
+ */
738
+ deleteTagImage(tagId: FlakeId, opts?: RequestOptions): Promise<void>;
739
+ /**
740
+ * Finish tag image upload
741
+ *
742
+ * Finishes an image upload for a tag
743
+ */
744
+ finishTagImageUpload(tagId: FlakeId, body: FinishTagImageUploadUrlRequestDto, opts?: RequestOptions): Promise<void>;
745
+ /**
746
+ * Get a tag by an ID
747
+ */
748
+ getTag(tagId: FlakeId, opts?: RequestOptions): Promise<TagDto>;
749
+ /**
750
+ * Get upload URL for tag image
751
+ *
752
+ * Gets a pre-signed upload URL for uploading an image to a tag
753
+ */
754
+ getTagImageUploadUrl(tagId: FlakeId, opts?: RequestOptions): Promise<GetTagImageUploadUrlResponseDto>;
755
+ /**
756
+ * Get all tags for a store
757
+ */
758
+ getTags(opts?: RequestOptions): Promise<Array<TagDto>>;
759
+ /**
760
+ * Update a tag by ID
761
+ */
762
+ updateTag(tagId: FlakeId, body?: UpsertTagRequestDto, opts?: RequestOptions): Promise<TagDto>;
763
+ }
764
+ export declare class TierGroupsResource {
765
+ private readonly http;
766
+ constructor(http: HttpClient);
767
+ /**
768
+ * Create a new tier group
769
+ */
770
+ createTierGroup(body: CreateTierGroupRequestDto, opts?: RequestOptions): Promise<TierGroupDto>;
771
+ /**
772
+ * Delete a tier group by ID
773
+ */
774
+ deleteTierGroup(tierGroupId: FlakeId, opts?: RequestOptions): Promise<void>;
775
+ /**
776
+ * Get a tier group by ID
777
+ */
778
+ getTierGroup(tierGroupId: FlakeId, opts?: RequestOptions): Promise<TierGroupDto>;
779
+ /**
780
+ * List all tier groups for a store
781
+ */
782
+ listTierGroups(opts?: RequestOptions): Promise<Array<TierGroupDto>>;
783
+ /**
784
+ * Update a tier group by ID
785
+ */
786
+ updateTierGroup(tierGroupId: FlakeId, body: UpdateTierGroupRequestDto, opts?: RequestOptions): Promise<TierGroupDto>;
787
+ }
788
+ export declare class TrialsResource {
789
+ private readonly http;
790
+ constructor(http: HttpClient);
791
+ /**
792
+ * Create trial eligibility override for a customer
793
+ *
794
+ * Creates a new trial eligibility override for the specified customer.
795
+ * @param customerId The ID of the customer to create the trial eligibility override for.
796
+ */
797
+ createEligibilityOverrideForCustomer(customerId: FlakeId, body: CreateTrialEligibilityOverrideDto, opts?: RequestOptions): Promise<TrialEligibilityOverrideDto>;
798
+ /**
799
+ * Delete trial eligibility override for a customer
800
+ *
801
+ * Deletes an existing trial eligibility override.
802
+ * @param trialEligibilityOverrideId The ID of the trial eligibility override to delete.
803
+ */
804
+ deleteEligibilityOverrideForCustomer(customerId: string, trialEligibilityOverrideId: FlakeId, opts?: RequestOptions): Promise<void>;
805
+ /**
806
+ * Get trial eligibility overrides for a specific customer
807
+ *
808
+ * Retrieves all trial eligibility overrides for the specified customer.
809
+ * @param customerId The ID of the customer to retrieve trial eligibility overrides for.
810
+ */
811
+ getEligibilityOverridesForCustomer(customerId: FlakeId, query?: TrialsGetEligibilityOverridesForCustomerQuery, opts?: RequestOptions): Promise<Array<TrialEligibilityOverrideDto>>;
812
+ /**
813
+ * Get a trial by ID for a store
814
+ */
815
+ getTrial(trialId: FlakeId, opts?: RequestOptions): Promise<TrialDto>;
816
+ /**
817
+ * Get trials for a store
818
+ */
819
+ getTrials(query?: TrialsGetTrialsQuery, opts?: RequestOptions): Promise<Array<TrialDto>>;
820
+ }
821
+ export declare class UpsellSettingsResource {
822
+ private readonly http;
823
+ constructor(http: HttpClient);
824
+ /**
825
+ * Get store upselling settings
826
+ *
827
+ * Retrieves upselling settings for the store.
828
+ */
829
+ getStoreUpsellSettings(opts?: RequestOptions): Promise<StoreUpsellSettingsDto>;
830
+ /**
831
+ * Updates store upselling settings
832
+ *
833
+ * Updates upselling settings for a store.
834
+ */
835
+ updateStoreUpsellSettings(body?: UpdateStoreUpsellSettingsDto, opts?: RequestOptions): Promise<void>;
836
+ }
837
+ export declare class WebhooksResource {
838
+ private readonly http;
839
+ constructor(http: HttpClient);
840
+ createSubscription(body: CreateWebhookDto, opts?: RequestOptions): Promise<WebhookSubscriptionDto>;
841
+ deleteSubscription(webhookId: FlakeId, opts?: RequestOptions): Promise<void>;
842
+ getHistory(webhookId: FlakeId, query?: WebhooksGetHistoryQuery, opts?: RequestOptions): Promise<WebhookHistoryDto>;
843
+ getSubscriptions(opts?: RequestOptions): Promise<Array<WebhookSubscriptionDto>>;
844
+ getVariables(opts?: RequestOptions): Promise<Array<WebhookVariablesDto>>;
845
+ resend(body: ResendWebhookDto, opts?: RequestOptions): Promise<void>;
846
+ updateSubscription(webhookId: FlakeId, body: UpdateWebhookDto, opts?: RequestOptions): Promise<WebhookSubscriptionDto>;
847
+ }
848
+ /** Typed client for the PayNow management API. */
849
+ export declare class ManagementClient {
850
+ /** Escape hatch for endpoints this SDK does not model. */
851
+ readonly $http: HttpClient;
852
+ readonly affiliateLinks: AffiliateLinksResource;
853
+ readonly bans: BansResource;
854
+ readonly checkout: CheckoutResource;
855
+ readonly coupons: CouponsResource;
856
+ readonly customer_portal_sessions: CustomerPortalSessionsResource;
857
+ readonly customers: CustomersResource;
858
+ readonly customVariables: CustomVariablesResource;
859
+ readonly dataMigrations: DataMigrationsResource;
860
+ readonly delivery: DeliveryResource;
861
+ readonly discord: DiscordResource;
862
+ readonly downloadableFiles: DownloadableFilesResource;
863
+ readonly gameServers: GameServersResource;
864
+ readonly giftcards: GiftcardsResource;
865
+ readonly globalCommands: GlobalCommandsResource;
866
+ readonly invoices: InvoicesResource;
867
+ readonly marketing: MarketingResource;
868
+ readonly navlinks: NavlinksResource;
869
+ readonly orders: OrdersResource;
870
+ readonly paymentMethodTypes: PaymentMethodTypesResource;
871
+ readonly payments: PaymentsResource;
872
+ readonly paymentSettings: PaymentSettingsResource;
873
+ readonly productDependentMigrations: ProductDependentMigrationsResource;
874
+ readonly products: ProductsResource;
875
+ readonly regionalPricing: RegionalPricingResource;
876
+ readonly sales: SalesResource;
877
+ readonly store: StoreResource;
878
+ readonly subscriptions: SubscriptionsResource;
879
+ readonly tags: TagsResource;
880
+ readonly tierGroups: TierGroupsResource;
881
+ readonly trials: TrialsResource;
882
+ readonly upsellSettings: UpsellSettingsResource;
883
+ readonly webhooks: WebhooksResource;
884
+ constructor(http: HttpClient);
885
+ }
886
+ /** Options accepted by {@link createManagementClient}. */
887
+ export interface ManagementClientOptions extends ClientOptions {
888
+ /** An API key generated in the PayNow dashboard. */
889
+ apiKey: string;
890
+ /** The Flake ID of the store every request is scoped to. */
891
+ storeId: string;
892
+ }
893
+ /** Creates a ManagementClient that authenticates and scopes every request. */
894
+ export declare function createManagementClient(options: ManagementClientOptions): ManagementClient;
895
+ //# sourceMappingURL=client.d.ts.map