@ophelio/sdk 0.5.0 → 0.6.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +59 -40
- package/dist/index.cjs +166 -42
- package/dist/index.d.cts +252 -30
- package/dist/index.d.mts +252 -30
- package/dist/index.mjs +166 -42
- package/package.json +2 -2
package/dist/index.d.cts
CHANGED
|
@@ -1219,6 +1219,16 @@ interface components {
|
|
|
1219
1219
|
update_time: string;
|
|
1220
1220
|
};
|
|
1221
1221
|
ListPlansResponse: {
|
|
1222
|
+
/**
|
|
1223
|
+
* @description Opaque token for the next page; empty string on the last page.
|
|
1224
|
+
* @example
|
|
1225
|
+
*/
|
|
1226
|
+
next_page_token: string;
|
|
1227
|
+
/**
|
|
1228
|
+
* @description Total number of results across all pages.
|
|
1229
|
+
* @example 42
|
|
1230
|
+
*/
|
|
1231
|
+
total_size: number;
|
|
1222
1232
|
plans: components["schemas"]["Plan"][];
|
|
1223
1233
|
};
|
|
1224
1234
|
ErrorDetail: {
|
|
@@ -1267,7 +1277,17 @@ interface components {
|
|
|
1267
1277
|
create_time: string; /** Format: date-time */
|
|
1268
1278
|
update_time: string;
|
|
1269
1279
|
};
|
|
1270
|
-
|
|
1280
|
+
ListPlanBillingOptionsResponse: {
|
|
1281
|
+
/**
|
|
1282
|
+
* @description Opaque token for the next page; empty string on the last page.
|
|
1283
|
+
* @example
|
|
1284
|
+
*/
|
|
1285
|
+
next_page_token: string;
|
|
1286
|
+
/**
|
|
1287
|
+
* @description Total number of results across all pages.
|
|
1288
|
+
* @example 42
|
|
1289
|
+
*/
|
|
1290
|
+
total_size: number;
|
|
1271
1291
|
billing_options: components["schemas"]["BillingOption"][];
|
|
1272
1292
|
};
|
|
1273
1293
|
CreateBillingOptionForPlanDto: {
|
|
@@ -1297,6 +1317,16 @@ interface components {
|
|
|
1297
1317
|
update_time: string;
|
|
1298
1318
|
};
|
|
1299
1319
|
ListPlanLinksResponse: {
|
|
1320
|
+
/**
|
|
1321
|
+
* @description Opaque token for the next page; empty string on the last page.
|
|
1322
|
+
* @example
|
|
1323
|
+
*/
|
|
1324
|
+
next_page_token: string;
|
|
1325
|
+
/**
|
|
1326
|
+
* @description Total number of results across all pages.
|
|
1327
|
+
* @example 42
|
|
1328
|
+
*/
|
|
1329
|
+
total_size: number;
|
|
1300
1330
|
plan_links: components["schemas"]["PlanLinkView"][];
|
|
1301
1331
|
};
|
|
1302
1332
|
CreatePlanLinkDto: {
|
|
@@ -1347,6 +1377,16 @@ interface components {
|
|
|
1347
1377
|
entitlement: components["schemas"]["PlanEntitlementDefinition"] | null;
|
|
1348
1378
|
};
|
|
1349
1379
|
ListPlanEntitlementsResponse: {
|
|
1380
|
+
/**
|
|
1381
|
+
* @description Opaque token for the next page; empty string on the last page.
|
|
1382
|
+
* @example
|
|
1383
|
+
*/
|
|
1384
|
+
next_page_token: string;
|
|
1385
|
+
/**
|
|
1386
|
+
* @description Total number of results across all pages.
|
|
1387
|
+
* @example 42
|
|
1388
|
+
*/
|
|
1389
|
+
total_size: number;
|
|
1350
1390
|
entitlements: components["schemas"]["PlanEntitlement"][];
|
|
1351
1391
|
};
|
|
1352
1392
|
CreatePlanEntitlementDto: {
|
|
@@ -1376,12 +1416,35 @@ interface components {
|
|
|
1376
1416
|
pricing_group: components["schemas"]["MappingPricingGroup"] | null;
|
|
1377
1417
|
};
|
|
1378
1418
|
ListPlanPricingGroupMappingsResponse: {
|
|
1419
|
+
/**
|
|
1420
|
+
* @description Opaque token for the next page; empty string on the last page.
|
|
1421
|
+
* @example
|
|
1422
|
+
*/
|
|
1423
|
+
next_page_token: string;
|
|
1424
|
+
/**
|
|
1425
|
+
* @description Total number of results across all pages.
|
|
1426
|
+
* @example 42
|
|
1427
|
+
*/
|
|
1428
|
+
total_size: number;
|
|
1379
1429
|
pricing_group_mappings: components["schemas"]["PlanPricingGroupMapping"][];
|
|
1380
1430
|
};
|
|
1381
1431
|
CreatePlanPricingGroupMappingDto: {
|
|
1382
1432
|
/** Format: uuid */member_role_id: string; /** Format: uuid */
|
|
1383
1433
|
pricing_group_id: string;
|
|
1384
1434
|
};
|
|
1435
|
+
ListBillingOptionsResponse: {
|
|
1436
|
+
/**
|
|
1437
|
+
* @description Opaque token for the next page; empty string on the last page.
|
|
1438
|
+
* @example
|
|
1439
|
+
*/
|
|
1440
|
+
next_page_token: string;
|
|
1441
|
+
/**
|
|
1442
|
+
* @description Total number of results across all pages.
|
|
1443
|
+
* @example 42
|
|
1444
|
+
*/
|
|
1445
|
+
total_size: number;
|
|
1446
|
+
billing_options: components["schemas"]["BillingOption"][];
|
|
1447
|
+
};
|
|
1385
1448
|
UpdateBillingOptionDto: {
|
|
1386
1449
|
display_name?: string;
|
|
1387
1450
|
description?: string | null; /** @enum {string} */
|
|
@@ -1399,6 +1462,16 @@ interface components {
|
|
|
1399
1462
|
sales_channel: components["schemas"]["SalesChannelSummary"] | null;
|
|
1400
1463
|
};
|
|
1401
1464
|
ListBillingOptionSalesChannelsResponse: {
|
|
1465
|
+
/**
|
|
1466
|
+
* @description Opaque token for the next page; empty string on the last page.
|
|
1467
|
+
* @example
|
|
1468
|
+
*/
|
|
1469
|
+
next_page_token: string;
|
|
1470
|
+
/**
|
|
1471
|
+
* @description Total number of results across all pages.
|
|
1472
|
+
* @example 42
|
|
1473
|
+
*/
|
|
1474
|
+
total_size: number;
|
|
1402
1475
|
sales_channels: components["schemas"]["BillingOptionSalesChannel"][];
|
|
1403
1476
|
};
|
|
1404
1477
|
CreateBillingOptionSalesChannelDto: {
|
|
@@ -1414,6 +1487,16 @@ interface components {
|
|
|
1414
1487
|
update_time: string;
|
|
1415
1488
|
};
|
|
1416
1489
|
ListSalesChannelsResponse: {
|
|
1490
|
+
/**
|
|
1491
|
+
* @description Opaque token for the next page; empty string on the last page.
|
|
1492
|
+
* @example
|
|
1493
|
+
*/
|
|
1494
|
+
next_page_token: string;
|
|
1495
|
+
/**
|
|
1496
|
+
* @description Total number of results across all pages.
|
|
1497
|
+
* @example 42
|
|
1498
|
+
*/
|
|
1499
|
+
total_size: number;
|
|
1417
1500
|
sales_channels: components["schemas"]["SalesChannel"][];
|
|
1418
1501
|
};
|
|
1419
1502
|
CreateSalesChannelDto: {
|
|
@@ -1493,6 +1576,16 @@ interface components {
|
|
|
1493
1576
|
update_time: string;
|
|
1494
1577
|
};
|
|
1495
1578
|
ListEntitlementsResponse: {
|
|
1579
|
+
/**
|
|
1580
|
+
* @description Opaque token for the next page; empty string on the last page.
|
|
1581
|
+
* @example
|
|
1582
|
+
*/
|
|
1583
|
+
next_page_token: string;
|
|
1584
|
+
/**
|
|
1585
|
+
* @description Total number of results across all pages.
|
|
1586
|
+
* @example 42
|
|
1587
|
+
*/
|
|
1588
|
+
total_size: number;
|
|
1496
1589
|
entitlements: components["schemas"]["Entitlement"][];
|
|
1497
1590
|
};
|
|
1498
1591
|
RedeemEntitlementDto: {
|
|
@@ -1625,6 +1718,16 @@ interface components {
|
|
|
1625
1718
|
membership: components["schemas"]["MemberMembershipSummary"] | null;
|
|
1626
1719
|
};
|
|
1627
1720
|
ListMemberEntitlementsResponse: {
|
|
1721
|
+
/**
|
|
1722
|
+
* @description Opaque token for the next page; empty string on the last page.
|
|
1723
|
+
* @example
|
|
1724
|
+
*/
|
|
1725
|
+
next_page_token: string;
|
|
1726
|
+
/**
|
|
1727
|
+
* @description Total number of results across all pages.
|
|
1728
|
+
* @example 42
|
|
1729
|
+
*/
|
|
1730
|
+
total_size: number;
|
|
1628
1731
|
entitlements: components["schemas"]["MemberEntitlement"][];
|
|
1629
1732
|
};
|
|
1630
1733
|
UpdateMemberDto: {
|
|
@@ -1710,6 +1813,16 @@ interface components {
|
|
|
1710
1813
|
update_time: string;
|
|
1711
1814
|
};
|
|
1712
1815
|
ListMemberRolesResponse: {
|
|
1816
|
+
/**
|
|
1817
|
+
* @description Opaque token for the next page; empty string on the last page.
|
|
1818
|
+
* @example
|
|
1819
|
+
*/
|
|
1820
|
+
next_page_token: string;
|
|
1821
|
+
/**
|
|
1822
|
+
* @description Total number of results across all pages.
|
|
1823
|
+
* @example 42
|
|
1824
|
+
*/
|
|
1825
|
+
total_size: number;
|
|
1713
1826
|
member_roles: components["schemas"]["MemberRole"][];
|
|
1714
1827
|
};
|
|
1715
1828
|
CreateMemberRoleDto: {
|
|
@@ -1736,6 +1849,16 @@ interface components {
|
|
|
1736
1849
|
update_time: string;
|
|
1737
1850
|
};
|
|
1738
1851
|
ListWebhookSubscriptionsResponse: {
|
|
1852
|
+
/**
|
|
1853
|
+
* @description Opaque token for the next page; empty string on the last page.
|
|
1854
|
+
* @example
|
|
1855
|
+
*/
|
|
1856
|
+
next_page_token: string;
|
|
1857
|
+
/**
|
|
1858
|
+
* @description Total number of results across all pages.
|
|
1859
|
+
* @example 42
|
|
1860
|
+
*/
|
|
1861
|
+
total_size: number;
|
|
1739
1862
|
webhook_subscriptions: components["schemas"]["WebhookSubscription"][];
|
|
1740
1863
|
};
|
|
1741
1864
|
WebhookDelivery: {
|
|
@@ -1784,6 +1907,16 @@ interface components {
|
|
|
1784
1907
|
update_time: string;
|
|
1785
1908
|
};
|
|
1786
1909
|
ListPricingGroupsResponse: {
|
|
1910
|
+
/**
|
|
1911
|
+
* @description Opaque token for the next page; empty string on the last page.
|
|
1912
|
+
* @example
|
|
1913
|
+
*/
|
|
1914
|
+
next_page_token: string;
|
|
1915
|
+
/**
|
|
1916
|
+
* @description Total number of results across all pages.
|
|
1917
|
+
* @example 42
|
|
1918
|
+
*/
|
|
1919
|
+
total_size: number;
|
|
1787
1920
|
pricing_groups: components["schemas"]["PricingGroup"][];
|
|
1788
1921
|
};
|
|
1789
1922
|
CreatePricingGroupDto: {
|
|
@@ -1974,6 +2107,16 @@ interface components {
|
|
|
1974
2107
|
memberships: components["schemas"]["Membership"][];
|
|
1975
2108
|
};
|
|
1976
2109
|
ListMembershipMembersResponse: {
|
|
2110
|
+
/**
|
|
2111
|
+
* @description Opaque token for the next page; empty string on the last page.
|
|
2112
|
+
* @example
|
|
2113
|
+
*/
|
|
2114
|
+
next_page_token: string;
|
|
2115
|
+
/**
|
|
2116
|
+
* @description Total number of results across all pages.
|
|
2117
|
+
* @example 42
|
|
2118
|
+
*/
|
|
2119
|
+
total_size: number;
|
|
1977
2120
|
members: components["schemas"]["Member"][];
|
|
1978
2121
|
};
|
|
1979
2122
|
AddMemberDto: {
|
|
@@ -2477,7 +2620,10 @@ interface operations {
|
|
|
2477
2620
|
};
|
|
2478
2621
|
PlansController_list: {
|
|
2479
2622
|
parameters: {
|
|
2480
|
-
query?:
|
|
2623
|
+
query?: {
|
|
2624
|
+
page_size?: number;
|
|
2625
|
+
page_token?: string;
|
|
2626
|
+
};
|
|
2481
2627
|
header?: never;
|
|
2482
2628
|
path?: never;
|
|
2483
2629
|
cookie?: never;
|
|
@@ -2604,7 +2750,10 @@ interface operations {
|
|
|
2604
2750
|
};
|
|
2605
2751
|
PlansController_listBillingOptions: {
|
|
2606
2752
|
parameters: {
|
|
2607
|
-
query?:
|
|
2753
|
+
query?: {
|
|
2754
|
+
page_size?: number;
|
|
2755
|
+
page_token?: string;
|
|
2756
|
+
};
|
|
2608
2757
|
header?: never;
|
|
2609
2758
|
path?: never;
|
|
2610
2759
|
cookie?: never;
|
|
@@ -2616,7 +2765,7 @@ interface operations {
|
|
|
2616
2765
|
[name: string]: unknown;
|
|
2617
2766
|
};
|
|
2618
2767
|
content: {
|
|
2619
|
-
"application/json": components["schemas"]["
|
|
2768
|
+
"application/json": components["schemas"]["ListPlanBillingOptionsResponse"];
|
|
2620
2769
|
};
|
|
2621
2770
|
};
|
|
2622
2771
|
404: {
|
|
@@ -2662,7 +2811,10 @@ interface operations {
|
|
|
2662
2811
|
};
|
|
2663
2812
|
PlansController_listPlanLinks: {
|
|
2664
2813
|
parameters: {
|
|
2665
|
-
query?:
|
|
2814
|
+
query?: {
|
|
2815
|
+
page_size?: number;
|
|
2816
|
+
page_token?: string;
|
|
2817
|
+
};
|
|
2666
2818
|
header?: never;
|
|
2667
2819
|
path?: never;
|
|
2668
2820
|
cookie?: never;
|
|
@@ -2720,7 +2872,10 @@ interface operations {
|
|
|
2720
2872
|
};
|
|
2721
2873
|
PlansController_listEntitlements: {
|
|
2722
2874
|
parameters: {
|
|
2723
|
-
query?:
|
|
2875
|
+
query?: {
|
|
2876
|
+
page_size?: number;
|
|
2877
|
+
page_token?: string;
|
|
2878
|
+
};
|
|
2724
2879
|
header?: never;
|
|
2725
2880
|
path?: never;
|
|
2726
2881
|
cookie?: never;
|
|
@@ -2778,7 +2933,10 @@ interface operations {
|
|
|
2778
2933
|
};
|
|
2779
2934
|
PlansController_listPricingGroupMappings: {
|
|
2780
2935
|
parameters: {
|
|
2781
|
-
query?:
|
|
2936
|
+
query?: {
|
|
2937
|
+
page_size?: number;
|
|
2938
|
+
page_token?: string;
|
|
2939
|
+
};
|
|
2782
2940
|
header?: never;
|
|
2783
2941
|
path?: never;
|
|
2784
2942
|
cookie?: never;
|
|
@@ -2836,7 +2994,10 @@ interface operations {
|
|
|
2836
2994
|
};
|
|
2837
2995
|
BillingOptionsController_list: {
|
|
2838
2996
|
parameters: {
|
|
2839
|
-
query?:
|
|
2997
|
+
query?: {
|
|
2998
|
+
page_size?: number;
|
|
2999
|
+
page_token?: string;
|
|
3000
|
+
};
|
|
2840
3001
|
header?: never;
|
|
2841
3002
|
path?: never;
|
|
2842
3003
|
cookie?: never;
|
|
@@ -2940,7 +3101,10 @@ interface operations {
|
|
|
2940
3101
|
};
|
|
2941
3102
|
BillingOptionsController_listSalesChannels: {
|
|
2942
3103
|
parameters: {
|
|
2943
|
-
query?:
|
|
3104
|
+
query?: {
|
|
3105
|
+
page_size?: number;
|
|
3106
|
+
page_token?: string;
|
|
3107
|
+
};
|
|
2944
3108
|
header?: never;
|
|
2945
3109
|
path?: never;
|
|
2946
3110
|
cookie?: never;
|
|
@@ -3025,7 +3189,10 @@ interface operations {
|
|
|
3025
3189
|
};
|
|
3026
3190
|
SalesChannelsController_list: {
|
|
3027
3191
|
parameters: {
|
|
3028
|
-
query?:
|
|
3192
|
+
query?: {
|
|
3193
|
+
page_size?: number;
|
|
3194
|
+
page_token?: string;
|
|
3195
|
+
};
|
|
3029
3196
|
header?: never;
|
|
3030
3197
|
path?: never;
|
|
3031
3198
|
cookie?: never;
|
|
@@ -3469,7 +3636,10 @@ interface operations {
|
|
|
3469
3636
|
};
|
|
3470
3637
|
EntitlementsController_list: {
|
|
3471
3638
|
parameters: {
|
|
3472
|
-
query?:
|
|
3639
|
+
query?: {
|
|
3640
|
+
page_size?: number;
|
|
3641
|
+
page_token?: string;
|
|
3642
|
+
};
|
|
3473
3643
|
header?: never;
|
|
3474
3644
|
path?: never;
|
|
3475
3645
|
cookie?: never;
|
|
@@ -3801,6 +3971,8 @@ interface operations {
|
|
|
3801
3971
|
parameters: {
|
|
3802
3972
|
query?: {
|
|
3803
3973
|
/** @description Registered target codes the request is being made at, sent comma-separated (`?targets=venue_a,coffee_shop`). Codes are matched exactly; an unregistered code is refused. Omit for no target context; send it empty to name no targets. */targets?: string[];
|
|
3974
|
+
page_size?: number;
|
|
3975
|
+
page_token?: string;
|
|
3804
3976
|
type?: "discount" | "early_access" | "free_entry" | "guest_pass";
|
|
3805
3977
|
};
|
|
3806
3978
|
header?: never;
|
|
@@ -4106,7 +4278,10 @@ interface operations {
|
|
|
4106
4278
|
};
|
|
4107
4279
|
MemberRolesController_list: {
|
|
4108
4280
|
parameters: {
|
|
4109
|
-
query?:
|
|
4281
|
+
query?: {
|
|
4282
|
+
page_size?: number;
|
|
4283
|
+
page_token?: string;
|
|
4284
|
+
};
|
|
4110
4285
|
header?: never;
|
|
4111
4286
|
path?: never;
|
|
4112
4287
|
cookie?: never;
|
|
@@ -4233,7 +4408,10 @@ interface operations {
|
|
|
4233
4408
|
};
|
|
4234
4409
|
WebhookSubscriptionsController_list: {
|
|
4235
4410
|
parameters: {
|
|
4236
|
-
query?:
|
|
4411
|
+
query?: {
|
|
4412
|
+
page_size?: number;
|
|
4413
|
+
page_token?: string;
|
|
4414
|
+
};
|
|
4237
4415
|
header?: never;
|
|
4238
4416
|
path?: never;
|
|
4239
4417
|
cookie?: never;
|
|
@@ -4390,7 +4568,10 @@ interface operations {
|
|
|
4390
4568
|
};
|
|
4391
4569
|
PricingGroupsController_list: {
|
|
4392
4570
|
parameters: {
|
|
4393
|
-
query?:
|
|
4571
|
+
query?: {
|
|
4572
|
+
page_size?: number;
|
|
4573
|
+
page_token?: string;
|
|
4574
|
+
};
|
|
4394
4575
|
header?: never;
|
|
4395
4576
|
path?: never;
|
|
4396
4577
|
cookie?: never;
|
|
@@ -4965,7 +5146,10 @@ interface operations {
|
|
|
4965
5146
|
};
|
|
4966
5147
|
MembershipsController_listMembers: {
|
|
4967
5148
|
parameters: {
|
|
4968
|
-
query?:
|
|
5149
|
+
query?: {
|
|
5150
|
+
page_size?: number;
|
|
5151
|
+
page_token?: string;
|
|
5152
|
+
};
|
|
4969
5153
|
header?: never;
|
|
4970
5154
|
path?: never;
|
|
4971
5155
|
cookie?: never;
|
|
@@ -5774,11 +5958,22 @@ declare class BillingOptionSalesChannelsResource extends APIResource {
|
|
|
5774
5958
|
//#endregion
|
|
5775
5959
|
//#region src/resources/billing-options.d.ts
|
|
5776
5960
|
declare class BillingOptionsResource extends APIResource {
|
|
5777
|
-
|
|
5961
|
+
/**
|
|
5962
|
+
* Every billing option in the project, across all plans — plans multiplied
|
|
5963
|
+
* by their options, so this is the largest of the configuration lists.
|
|
5964
|
+
* Ordered by plan, then display name. Use `collect` or `paginate` to walk it,
|
|
5965
|
+
* or read `total_size` off the first page for a count without loading rows.
|
|
5966
|
+
*/
|
|
5967
|
+
list(params?: PageParams, options?: RequestOptions): Promise<Page<BillingOption>>;
|
|
5778
5968
|
get(id: string, options?: RequestOptions): Promise<BillingOption>;
|
|
5779
5969
|
update(id: string, params: UpdateBillingOptionParams, options?: RequestOptions): Promise<BillingOption>;
|
|
5780
5970
|
delete(id: string, options?: RequestOptions): Promise<void>;
|
|
5781
|
-
|
|
5971
|
+
/**
|
|
5972
|
+
* The sales channels a billing option is restricted to, in the order they
|
|
5973
|
+
* were linked. No links at all means the billing option is available
|
|
5974
|
+
* everywhere.
|
|
5975
|
+
*/
|
|
5976
|
+
listSalesChannels(id: string, params?: PageParams, options?: RequestOptions): Promise<Page<BillingOptionSalesChannel>>;
|
|
5782
5977
|
createSalesChannelLink(id: string, params: CreateBillingOptionSalesChannelParams, options?: RequestOptions): Promise<BillingOptionSalesChannel>;
|
|
5783
5978
|
}
|
|
5784
5979
|
//#endregion
|
|
@@ -5867,7 +6062,7 @@ declare class EntitlementsResource extends APIResource {
|
|
|
5867
6062
|
* is refused rather than silently returning the original row.
|
|
5868
6063
|
*/
|
|
5869
6064
|
recordUsage(params: RecordUsageParams, options?: IdempotentRequestOptions): Promise<EntitlementUsage[]>;
|
|
5870
|
-
list(options?: RequestOptions): Promise<Entitlement
|
|
6065
|
+
list(params?: PageParams, options?: RequestOptions): Promise<Page<Entitlement>>;
|
|
5871
6066
|
get(id: string, options?: RequestOptions): Promise<Entitlement>;
|
|
5872
6067
|
create(params: CreateEntitlementParams, options?: RequestOptions): Promise<Entitlement>;
|
|
5873
6068
|
update(id: string, params: UpdateEntitlementParams, options?: RequestOptions): Promise<Entitlement>;
|
|
@@ -5876,7 +6071,7 @@ declare class EntitlementsResource extends APIResource {
|
|
|
5876
6071
|
//#endregion
|
|
5877
6072
|
//#region src/resources/member-roles.d.ts
|
|
5878
6073
|
declare class MemberRolesResource extends APIResource {
|
|
5879
|
-
list(options?: RequestOptions): Promise<MemberRole
|
|
6074
|
+
list(params?: PageParams, options?: RequestOptions): Promise<Page<MemberRole>>;
|
|
5880
6075
|
get(id: string, options?: RequestOptions): Promise<MemberRole>;
|
|
5881
6076
|
create(params: CreateMemberRoleParams, options?: RequestOptions): Promise<MemberRole>;
|
|
5882
6077
|
update(id: string, params: UpdateMemberRoleParams, options?: RequestOptions): Promise<MemberRole>;
|
|
@@ -5888,9 +6083,26 @@ declare class MembersResource extends APIResource {
|
|
|
5888
6083
|
/**
|
|
5889
6084
|
* Active-member list for offline gate caching. Pass the previous
|
|
5890
6085
|
* response's `generated_at` as `since` to fetch incrementally.
|
|
6086
|
+
*
|
|
6087
|
+
* `targets` names the venue, zone, shop or gate this roster is for, and
|
|
6088
|
+
* settles what the gate can grant while it is offline: each member's
|
|
6089
|
+
* entitlements are stored as they stand at the moment of the sync and are
|
|
6090
|
+
* read back during an outage without being checked again. Omit it for the
|
|
6091
|
+
* whole roster. Codes are matched exactly, so send them back verbatim from
|
|
6092
|
+
* `targetCodes.list()` — an unregistered one is refused with a 400.
|
|
6093
|
+
*
|
|
6094
|
+
* Two things work differently here than on `admit.check` and
|
|
6095
|
+
* `members.listEntitlements`, both on purpose. An empty `targets` is
|
|
6096
|
+
* refused with a 400. It is not read as naming no targets, so it never
|
|
6097
|
+
* returns only the benefits valid everywhere. And a project that requires
|
|
6098
|
+
* every read to say where it is still answers a sync that omits `targets`.
|
|
6099
|
+
* The roster is what a gate falls back on when it cannot reach us, so a
|
|
6100
|
+
* quietly shortened or unfetchable copy would only show up during the
|
|
6101
|
+
* outage it was kept for.
|
|
5891
6102
|
*/
|
|
5892
6103
|
sync(params?: {
|
|
5893
6104
|
since?: string;
|
|
6105
|
+
targets?: string[];
|
|
5894
6106
|
}, options?: RequestOptions): Promise<MemberSyncResponse>;
|
|
5895
6107
|
get(id: string, options?: RequestOptions): Promise<Member>;
|
|
5896
6108
|
/**
|
|
@@ -5907,11 +6119,16 @@ declare class MembersResource extends APIResource {
|
|
|
5907
6119
|
* Each entitlement carries `valid_on` and `valid_at` when something
|
|
5908
6120
|
* restricts it by date or by target; both list only what it matched, never
|
|
5909
6121
|
* what it failed.
|
|
6122
|
+
*
|
|
6123
|
+
* `page_size` / `page_token` window the already-filtered result, so they
|
|
6124
|
+
* compose with `type` and `targets` rather than replacing them. A page token
|
|
6125
|
+
* is bound to the filters it was issued under: change `type` or `targets`
|
|
6126
|
+
* and the token is refused rather than returning misaligned rows.
|
|
5910
6127
|
*/
|
|
5911
|
-
listEntitlements(id: string, params?: {
|
|
6128
|
+
listEntitlements(id: string, params?: PageParams & {
|
|
5912
6129
|
type?: EntitlementType;
|
|
5913
6130
|
targets?: string[];
|
|
5914
|
-
}, options?: RequestOptions): Promise<MemberEntitlement
|
|
6131
|
+
}, options?: RequestOptions): Promise<Page<MemberEntitlement>>;
|
|
5915
6132
|
/**
|
|
5916
6133
|
* Updates a member's details. Accepts `name`, `date_of_birth` and `role`
|
|
5917
6134
|
* (a member-role code). To reassign the primary member use `setPrimary`;
|
|
@@ -5957,7 +6174,12 @@ declare class MembershipsResource extends APIResource {
|
|
|
5957
6174
|
* transaction once and does not advance dunning twice.
|
|
5958
6175
|
*/
|
|
5959
6176
|
createTransaction(id: string, params: CreateTransactionParams, options?: IdempotentRequestOptions): Promise<Transaction>;
|
|
5960
|
-
|
|
6177
|
+
/**
|
|
6178
|
+
* The cardholders on a membership, primary first, then in the order they
|
|
6179
|
+
* were added. Bounded by the plan's `max_party_size`, so the default page
|
|
6180
|
+
* size covers a membership in one request.
|
|
6181
|
+
*/
|
|
6182
|
+
listMembers(id: string, params?: PageParams, options?: RequestOptions): Promise<Page<Member>>;
|
|
5961
6183
|
/**
|
|
5962
6184
|
* Add a member to an existing membership, up to the plan's max party size.
|
|
5963
6185
|
* `role` is a member-role code; an optional `email` links the member to a
|
|
@@ -6026,24 +6248,24 @@ declare class PlanPricingGroupMappingsResource extends APIResource {
|
|
|
6026
6248
|
//#endregion
|
|
6027
6249
|
//#region src/resources/plans.d.ts
|
|
6028
6250
|
declare class PlansResource extends APIResource {
|
|
6029
|
-
list(options?: RequestOptions): Promise<Plan
|
|
6251
|
+
list(params?: PageParams, options?: RequestOptions): Promise<Page<Plan>>;
|
|
6030
6252
|
get(id: string, options?: RequestOptions): Promise<Plan>;
|
|
6031
|
-
listBillingOptions(id: string, options?: RequestOptions): Promise<BillingOption
|
|
6032
|
-
listEntitlements(id: string, options?: RequestOptions): Promise<PlanEntitlement
|
|
6253
|
+
listBillingOptions(id: string, params?: PageParams, options?: RequestOptions): Promise<Page<BillingOption>>;
|
|
6254
|
+
listEntitlements(id: string, params?: PageParams, options?: RequestOptions): Promise<Page<PlanEntitlement>>;
|
|
6033
6255
|
create(params: CreatePlanParams, options?: RequestOptions): Promise<Plan>;
|
|
6034
6256
|
update(id: string, params: UpdatePlanParams, options?: RequestOptions): Promise<Plan>;
|
|
6035
6257
|
delete(id: string, options?: RequestOptions): Promise<void>;
|
|
6036
6258
|
createBillingOption(id: string, params: CreateBillingOptionParams, options?: RequestOptions): Promise<BillingOption>;
|
|
6037
|
-
listPlanLinks(id: string, options?: RequestOptions): Promise<PlanLinkView
|
|
6259
|
+
listPlanLinks(id: string, params?: PageParams, options?: RequestOptions): Promise<Page<PlanLinkView>>;
|
|
6038
6260
|
createPlanLink(id: string, params: CreatePlanLinkParams, options?: RequestOptions): Promise<PlanLink>;
|
|
6039
6261
|
createEntitlement(id: string, params: CreatePlanEntitlementParams, options?: RequestOptions): Promise<PlanEntitlement>;
|
|
6040
|
-
listPricingGroupMappings(id: string, options?: RequestOptions): Promise<PlanPricingGroupMapping
|
|
6262
|
+
listPricingGroupMappings(id: string, params?: PageParams, options?: RequestOptions): Promise<Page<PlanPricingGroupMapping>>;
|
|
6041
6263
|
createPricingGroupMapping(id: string, params: CreatePlanPricingGroupMappingParams, options?: RequestOptions): Promise<PlanPricingGroupMapping>;
|
|
6042
6264
|
}
|
|
6043
6265
|
//#endregion
|
|
6044
6266
|
//#region src/resources/pricing-groups.d.ts
|
|
6045
6267
|
declare class PricingGroupsResource extends APIResource {
|
|
6046
|
-
list(options?: RequestOptions): Promise<PricingGroup
|
|
6268
|
+
list(params?: PageParams, options?: RequestOptions): Promise<Page<PricingGroup>>;
|
|
6047
6269
|
get(id: string, options?: RequestOptions): Promise<PricingGroup>;
|
|
6048
6270
|
create(params: CreatePricingGroupParams, options?: RequestOptions): Promise<PricingGroup>;
|
|
6049
6271
|
update(id: string, params: UpdatePricingGroupParams, options?: RequestOptions): Promise<PricingGroup>;
|
|
@@ -6052,7 +6274,7 @@ declare class PricingGroupsResource extends APIResource {
|
|
|
6052
6274
|
//#endregion
|
|
6053
6275
|
//#region src/resources/sales-channels.d.ts
|
|
6054
6276
|
declare class SalesChannelsResource extends APIResource {
|
|
6055
|
-
list(options?: RequestOptions): Promise<SalesChannel
|
|
6277
|
+
list(params?: PageParams, options?: RequestOptions): Promise<Page<SalesChannel>>;
|
|
6056
6278
|
get(id: string, options?: RequestOptions): Promise<SalesChannel>;
|
|
6057
6279
|
create(params: CreateSalesChannelParams, options?: RequestOptions): Promise<SalesChannel>;
|
|
6058
6280
|
update(id: string, params: UpdateSalesChannelParams, options?: RequestOptions): Promise<SalesChannel>;
|
|
@@ -6097,7 +6319,7 @@ declare class TargetCodesResource extends APIResource {
|
|
|
6097
6319
|
//#endregion
|
|
6098
6320
|
//#region src/resources/webhook-subscriptions.d.ts
|
|
6099
6321
|
declare class WebhookSubscriptionsResource extends APIResource {
|
|
6100
|
-
list(options?: RequestOptions): Promise<WebhookSubscription
|
|
6322
|
+
list(params?: PageParams, options?: RequestOptions): Promise<Page<WebhookSubscription>>;
|
|
6101
6323
|
get(id: string, options?: RequestOptions): Promise<WebhookSubscription>;
|
|
6102
6324
|
listDeliveries(id: string, params?: PageParams, options?: RequestOptions): Promise<Page<WebhookDelivery>>;
|
|
6103
6325
|
/** The HMAC signing secret is only returned on creation — store it then. */
|