@openmeter/sdk 1.0.0-beta-d15df9dfbcc2 → 1.0.0-beta-1b87dc115a7b
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/dist/cjs/src/client/customers.cjs +17 -0
- package/dist/cjs/src/client/customers.d.cts +11 -0
- package/dist/cjs/src/client/customers.js.map +1 -1
- package/dist/cjs/src/client/events.cjs +19 -7
- package/dist/cjs/src/client/events.d.cts +15 -4
- package/dist/cjs/src/client/events.js.map +1 -1
- package/dist/cjs/src/client/plans.cjs +127 -50
- package/dist/cjs/src/client/plans.d.cts +114 -24
- package/dist/cjs/src/client/plans.js.map +1 -1
- package/dist/cjs/src/client/subscriptions.cjs +16 -0
- package/dist/cjs/src/client/subscriptions.d.cts +8 -0
- package/dist/cjs/src/client/subscriptions.js.map +1 -1
- package/dist/cjs/{tsconfig.6896524f.tsbuildinfo → tsconfig.1591d310.tsbuildinfo} +1 -1
- package/dist/cjs/{tsconfig.f950eb1f.tsbuildinfo → tsconfig.65d74ee9.tsbuildinfo} +1 -1
- package/dist/src/client/customers.d.ts +11 -0
- package/dist/src/client/customers.js +17 -0
- package/dist/src/client/customers.js.map +1 -1
- package/dist/src/client/events.d.ts +15 -4
- package/dist/src/client/events.js +19 -7
- package/dist/src/client/events.js.map +1 -1
- package/dist/src/client/plans.d.ts +114 -24
- package/dist/src/client/plans.js +124 -48
- package/dist/src/client/plans.js.map +1 -1
- package/dist/src/client/subscriptions.d.ts +8 -0
- package/dist/src/client/subscriptions.js +16 -0
- package/dist/src/client/subscriptions.js.map +1 -1
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/package.json +1 -1
|
@@ -1,13 +1,18 @@
|
|
|
1
1
|
import type { RequestOptions } from './common.js';
|
|
2
2
|
import type { operations, paths, PlanCreate, PlanReplaceUpdate } from './schemas.js';
|
|
3
3
|
import type { Client } from 'openapi-fetch';
|
|
4
|
+
/**
|
|
5
|
+
* Plans
|
|
6
|
+
* Manage customer subscription plans and addon assignments.
|
|
7
|
+
*/
|
|
4
8
|
export declare class Plans {
|
|
5
9
|
private client;
|
|
10
|
+
addons: PlanAddons;
|
|
6
11
|
constructor(client: Client<paths, `${string}/${string}`>);
|
|
7
12
|
/**
|
|
8
13
|
* Create a plan
|
|
9
14
|
* @param plan - The plan to create
|
|
10
|
-
* @param
|
|
15
|
+
* @param options - Optional request options
|
|
11
16
|
* @returns The created plan
|
|
12
17
|
*/
|
|
13
18
|
create(plan: PlanCreate, options?: RequestOptions): Promise<{
|
|
@@ -31,12 +36,13 @@ export declare class Plans {
|
|
|
31
36
|
readonly validationErrors: import("./schemas.js").components["schemas"]["ValidationError"][] | null;
|
|
32
37
|
}>;
|
|
33
38
|
/**
|
|
34
|
-
* Get a plan by ID
|
|
35
|
-
* @param
|
|
36
|
-
* @param
|
|
39
|
+
* Get a plan by ID
|
|
40
|
+
* @param planId - The ID of the plan to retrieve
|
|
41
|
+
* @param params - Optional query parameters
|
|
42
|
+
* @param options - Optional request options
|
|
37
43
|
* @returns The plan
|
|
38
44
|
*/
|
|
39
|
-
get(
|
|
45
|
+
get(planId: operations['getPlan']['parameters']['path']['planId'], params?: operations['getPlan']['parameters']['query'], options?: RequestOptions): Promise<{
|
|
40
46
|
readonly id: string;
|
|
41
47
|
name: string;
|
|
42
48
|
description?: string;
|
|
@@ -58,11 +64,11 @@ export declare class Plans {
|
|
|
58
64
|
}>;
|
|
59
65
|
/**
|
|
60
66
|
* List plans
|
|
61
|
-
* @param
|
|
62
|
-
* @param
|
|
63
|
-
* @returns
|
|
67
|
+
* @param params - Optional parameters for listing plans
|
|
68
|
+
* @param options - Optional request options
|
|
69
|
+
* @returns A list of plans
|
|
64
70
|
*/
|
|
65
|
-
list(
|
|
71
|
+
list(params?: operations['listPlans']['parameters']['query'], options?: RequestOptions): Promise<{
|
|
66
72
|
totalCount: number;
|
|
67
73
|
page: number;
|
|
68
74
|
pageSize: number;
|
|
@@ -70,12 +76,12 @@ export declare class Plans {
|
|
|
70
76
|
}>;
|
|
71
77
|
/**
|
|
72
78
|
* Update a plan
|
|
73
|
-
* @param
|
|
74
|
-
* @param plan - The plan to update
|
|
75
|
-
* @param
|
|
79
|
+
* @param planId - The ID of the plan to update
|
|
80
|
+
* @param plan - The plan data to update
|
|
81
|
+
* @param options - Optional request options
|
|
76
82
|
* @returns The updated plan
|
|
77
83
|
*/
|
|
78
|
-
update(
|
|
84
|
+
update(planId: operations['updatePlan']['parameters']['path']['planId'], plan: PlanReplaceUpdate, options?: RequestOptions): Promise<{
|
|
79
85
|
readonly id: string;
|
|
80
86
|
name: string;
|
|
81
87
|
description?: string;
|
|
@@ -96,19 +102,19 @@ export declare class Plans {
|
|
|
96
102
|
readonly validationErrors: import("./schemas.js").components["schemas"]["ValidationError"][] | null;
|
|
97
103
|
}>;
|
|
98
104
|
/**
|
|
99
|
-
* Delete a plan
|
|
100
|
-
* @param
|
|
101
|
-
* @param
|
|
102
|
-
* @returns
|
|
105
|
+
* Delete a plan by ID
|
|
106
|
+
* @param planId - The ID of the plan to delete
|
|
107
|
+
* @param options - Optional request options
|
|
108
|
+
* @returns void or standard error response structure
|
|
103
109
|
*/
|
|
104
|
-
delete(
|
|
110
|
+
delete(planId: operations['deletePlan']['parameters']['path']['planId'], options?: RequestOptions): Promise<undefined>;
|
|
105
111
|
/**
|
|
106
112
|
* Archive a plan
|
|
107
|
-
* @param
|
|
108
|
-
* @param
|
|
113
|
+
* @param planId - The ID of the plan to archive
|
|
114
|
+
* @param options - Optional request options
|
|
109
115
|
* @returns The archived plan
|
|
110
116
|
*/
|
|
111
|
-
archive(
|
|
117
|
+
archive(planId: operations['archivePlan']['parameters']['path']['planId'], options?: RequestOptions): Promise<{
|
|
112
118
|
readonly id: string;
|
|
113
119
|
name: string;
|
|
114
120
|
description?: string;
|
|
@@ -130,11 +136,11 @@ export declare class Plans {
|
|
|
130
136
|
}>;
|
|
131
137
|
/**
|
|
132
138
|
* Publish a plan
|
|
133
|
-
* @param
|
|
134
|
-
* @param
|
|
139
|
+
* @param planId - The ID of the plan to publish
|
|
140
|
+
* @param options - Optional request options
|
|
135
141
|
* @returns The published plan
|
|
136
142
|
*/
|
|
137
|
-
publish(
|
|
143
|
+
publish(planId: operations['publishPlan']['parameters']['path']['planId'], options?: RequestOptions): Promise<{
|
|
138
144
|
readonly id: string;
|
|
139
145
|
name: string;
|
|
140
146
|
description?: string;
|
|
@@ -155,3 +161,87 @@ export declare class Plans {
|
|
|
155
161
|
readonly validationErrors: import("./schemas.js").components["schemas"]["ValidationError"][] | null;
|
|
156
162
|
}>;
|
|
157
163
|
}
|
|
164
|
+
/**
|
|
165
|
+
* Plan Addons
|
|
166
|
+
* Manage addon assignments for plans.
|
|
167
|
+
*/
|
|
168
|
+
export declare class PlanAddons {
|
|
169
|
+
private client;
|
|
170
|
+
constructor(client: Client<paths, `${string}/${string}`>);
|
|
171
|
+
/**
|
|
172
|
+
* List plan addons
|
|
173
|
+
* @param planId - The ID of the plan
|
|
174
|
+
* @param params - Optional query parameters
|
|
175
|
+
* @param options - Optional request options
|
|
176
|
+
* @returns A list of plan addons
|
|
177
|
+
*/
|
|
178
|
+
list(planId: operations['listPlanAddons']['parameters']['path']['planId'], params?: operations['listPlanAddons']['parameters']['query'], options?: RequestOptions): Promise<{
|
|
179
|
+
totalCount: number;
|
|
180
|
+
page: number;
|
|
181
|
+
pageSize: number;
|
|
182
|
+
items: import("./schemas.js").components["schemas"]["PlanAddon"][];
|
|
183
|
+
}>;
|
|
184
|
+
/**
|
|
185
|
+
* Create a plan addon
|
|
186
|
+
* @param planId - The ID of the plan
|
|
187
|
+
* @param planAddon - The plan addon to create
|
|
188
|
+
* @param options - Optional request options
|
|
189
|
+
* @returns The created plan addon
|
|
190
|
+
*/
|
|
191
|
+
create(planId: operations['createPlanAddon']['parameters']['path']['planId'], planAddon: operations['createPlanAddon']['requestBody']['content']['application/json'], options?: RequestOptions): Promise<{
|
|
192
|
+
readonly createdAt: Date;
|
|
193
|
+
readonly updatedAt: Date;
|
|
194
|
+
readonly deletedAt?: Date;
|
|
195
|
+
readonly annotations?: import("./schemas.js").components["schemas"]["Annotations"];
|
|
196
|
+
metadata?: import("./schemas.js").components["schemas"]["Metadata"];
|
|
197
|
+
readonly addon: import("./schemas.js").components["schemas"]["Addon"];
|
|
198
|
+
fromPlanPhase: string;
|
|
199
|
+
maxQuantity?: number;
|
|
200
|
+
readonly validationErrors: import("./schemas.js").components["schemas"]["ValidationError"][] | null;
|
|
201
|
+
}>;
|
|
202
|
+
/**
|
|
203
|
+
* Get a plan addon by ID
|
|
204
|
+
* @param planId - The ID of the plan
|
|
205
|
+
* @param planAddonId - The ID of the plan addon
|
|
206
|
+
* @param options - Optional request options
|
|
207
|
+
* @returns The plan addon
|
|
208
|
+
*/
|
|
209
|
+
get(planId: operations['getPlanAddon']['parameters']['path']['planId'], planAddonId: operations['getPlanAddon']['parameters']['path']['planAddonId'], options?: RequestOptions): Promise<{
|
|
210
|
+
readonly createdAt: Date;
|
|
211
|
+
readonly updatedAt: Date;
|
|
212
|
+
readonly deletedAt?: Date;
|
|
213
|
+
readonly annotations?: import("./schemas.js").components["schemas"]["Annotations"];
|
|
214
|
+
metadata?: import("./schemas.js").components["schemas"]["Metadata"];
|
|
215
|
+
readonly addon: import("./schemas.js").components["schemas"]["Addon"];
|
|
216
|
+
fromPlanPhase: string;
|
|
217
|
+
maxQuantity?: number;
|
|
218
|
+
readonly validationErrors: import("./schemas.js").components["schemas"]["ValidationError"][] | null;
|
|
219
|
+
}>;
|
|
220
|
+
/**
|
|
221
|
+
* Update a plan addon
|
|
222
|
+
* @param planId - The ID of the plan
|
|
223
|
+
* @param planAddonId - The ID of the plan addon to update
|
|
224
|
+
* @param planAddon - The plan addon data to update
|
|
225
|
+
* @param options - Optional request options
|
|
226
|
+
* @returns The updated plan addon
|
|
227
|
+
*/
|
|
228
|
+
update(planId: operations['updatePlanAddon']['parameters']['path']['planId'], planAddonId: operations['updatePlanAddon']['parameters']['path']['planAddonId'], planAddon: operations['updatePlanAddon']['requestBody']['content']['application/json'], options?: RequestOptions): Promise<{
|
|
229
|
+
readonly createdAt: Date;
|
|
230
|
+
readonly updatedAt: Date;
|
|
231
|
+
readonly deletedAt?: Date;
|
|
232
|
+
readonly annotations?: import("./schemas.js").components["schemas"]["Annotations"];
|
|
233
|
+
metadata?: import("./schemas.js").components["schemas"]["Metadata"];
|
|
234
|
+
readonly addon: import("./schemas.js").components["schemas"]["Addon"];
|
|
235
|
+
fromPlanPhase: string;
|
|
236
|
+
maxQuantity?: number;
|
|
237
|
+
readonly validationErrors: import("./schemas.js").components["schemas"]["ValidationError"][] | null;
|
|
238
|
+
}>;
|
|
239
|
+
/**
|
|
240
|
+
* Delete a plan addon by ID
|
|
241
|
+
* @param planId - The ID of the plan
|
|
242
|
+
* @param planAddonId - The ID of the plan addon to delete
|
|
243
|
+
* @param options - Optional request options
|
|
244
|
+
* @returns void or standard error response structure
|
|
245
|
+
*/
|
|
246
|
+
delete(planId: operations['deletePlanAddon']['parameters']['path']['planId'], planAddonId: operations['deletePlanAddon']['parameters']['path']['planAddonId'], options?: RequestOptions): Promise<undefined>;
|
|
247
|
+
}
|
package/dist/src/client/plans.js
CHANGED
|
@@ -1,13 +1,19 @@
|
|
|
1
1
|
import { transformResponse } from './utils.js';
|
|
2
|
+
/**
|
|
3
|
+
* Plans
|
|
4
|
+
* Manage customer subscription plans and addon assignments.
|
|
5
|
+
*/
|
|
2
6
|
export class Plans {
|
|
3
7
|
client;
|
|
8
|
+
addons;
|
|
4
9
|
constructor(client) {
|
|
5
10
|
this.client = client;
|
|
11
|
+
this.addons = new PlanAddons(this.client);
|
|
6
12
|
}
|
|
7
13
|
/**
|
|
8
14
|
* Create a plan
|
|
9
15
|
* @param plan - The plan to create
|
|
10
|
-
* @param
|
|
16
|
+
* @param options - Optional request options
|
|
11
17
|
* @returns The created plan
|
|
12
18
|
*/
|
|
13
19
|
async create(plan, options) {
|
|
@@ -18,17 +24,17 @@ export class Plans {
|
|
|
18
24
|
return transformResponse(resp);
|
|
19
25
|
}
|
|
20
26
|
/**
|
|
21
|
-
* Get a plan by ID
|
|
22
|
-
* @param
|
|
23
|
-
* @param
|
|
27
|
+
* Get a plan by ID
|
|
28
|
+
* @param planId - The ID of the plan to retrieve
|
|
29
|
+
* @param params - Optional query parameters
|
|
30
|
+
* @param options - Optional request options
|
|
24
31
|
* @returns The plan
|
|
25
32
|
*/
|
|
26
|
-
async get(
|
|
33
|
+
async get(planId, params, options) {
|
|
27
34
|
const resp = await this.client.GET('/api/v1/plans/{planId}', {
|
|
28
35
|
params: {
|
|
29
|
-
path: {
|
|
30
|
-
|
|
31
|
-
},
|
|
36
|
+
path: { planId },
|
|
37
|
+
query: params,
|
|
32
38
|
},
|
|
33
39
|
...options,
|
|
34
40
|
});
|
|
@@ -36,88 +42,158 @@ export class Plans {
|
|
|
36
42
|
}
|
|
37
43
|
/**
|
|
38
44
|
* List plans
|
|
39
|
-
* @param
|
|
40
|
-
* @param
|
|
41
|
-
* @returns
|
|
45
|
+
* @param params - Optional parameters for listing plans
|
|
46
|
+
* @param options - Optional request options
|
|
47
|
+
* @returns A list of plans
|
|
42
48
|
*/
|
|
43
|
-
async list(
|
|
49
|
+
async list(params, options) {
|
|
44
50
|
const resp = await this.client.GET('/api/v1/plans', {
|
|
45
|
-
params: {
|
|
46
|
-
query,
|
|
47
|
-
},
|
|
51
|
+
params: { query: params },
|
|
48
52
|
...options,
|
|
49
53
|
});
|
|
50
54
|
return transformResponse(resp);
|
|
51
55
|
}
|
|
52
56
|
/**
|
|
53
57
|
* Update a plan
|
|
54
|
-
* @param
|
|
55
|
-
* @param plan - The plan to update
|
|
56
|
-
* @param
|
|
58
|
+
* @param planId - The ID of the plan to update
|
|
59
|
+
* @param plan - The plan data to update
|
|
60
|
+
* @param options - Optional request options
|
|
57
61
|
* @returns The updated plan
|
|
58
62
|
*/
|
|
59
|
-
async update(
|
|
63
|
+
async update(planId, plan, options) {
|
|
60
64
|
const resp = await this.client.PUT('/api/v1/plans/{planId}', {
|
|
61
65
|
body: plan,
|
|
62
|
-
params: {
|
|
63
|
-
path: {
|
|
64
|
-
planId: id,
|
|
65
|
-
},
|
|
66
|
-
},
|
|
66
|
+
params: { path: { planId } },
|
|
67
67
|
...options,
|
|
68
68
|
});
|
|
69
69
|
return transformResponse(resp);
|
|
70
70
|
}
|
|
71
71
|
/**
|
|
72
|
-
* Delete a plan
|
|
73
|
-
* @param
|
|
74
|
-
* @param
|
|
75
|
-
* @returns
|
|
72
|
+
* Delete a plan by ID
|
|
73
|
+
* @param planId - The ID of the plan to delete
|
|
74
|
+
* @param options - Optional request options
|
|
75
|
+
* @returns void or standard error response structure
|
|
76
76
|
*/
|
|
77
|
-
async delete(
|
|
77
|
+
async delete(planId, options) {
|
|
78
78
|
const resp = await this.client.DELETE('/api/v1/plans/{planId}', {
|
|
79
|
-
params: {
|
|
80
|
-
path: {
|
|
81
|
-
planId: id,
|
|
82
|
-
},
|
|
83
|
-
},
|
|
79
|
+
params: { path: { planId } },
|
|
84
80
|
...options,
|
|
85
81
|
});
|
|
86
82
|
return transformResponse(resp);
|
|
87
83
|
}
|
|
88
84
|
/**
|
|
89
85
|
* Archive a plan
|
|
90
|
-
* @param
|
|
91
|
-
* @param
|
|
86
|
+
* @param planId - The ID of the plan to archive
|
|
87
|
+
* @param options - Optional request options
|
|
92
88
|
* @returns The archived plan
|
|
93
89
|
*/
|
|
94
|
-
async archive(
|
|
90
|
+
async archive(planId, options) {
|
|
95
91
|
const resp = await this.client.POST('/api/v1/plans/{planId}/archive', {
|
|
96
|
-
params: {
|
|
97
|
-
path: {
|
|
98
|
-
planId: id,
|
|
99
|
-
},
|
|
100
|
-
},
|
|
92
|
+
params: { path: { planId } },
|
|
101
93
|
...options,
|
|
102
94
|
});
|
|
103
95
|
return transformResponse(resp);
|
|
104
96
|
}
|
|
105
97
|
/**
|
|
106
98
|
* Publish a plan
|
|
107
|
-
* @param
|
|
108
|
-
* @param
|
|
99
|
+
* @param planId - The ID of the plan to publish
|
|
100
|
+
* @param options - Optional request options
|
|
109
101
|
* @returns The published plan
|
|
110
102
|
*/
|
|
111
|
-
async publish(
|
|
103
|
+
async publish(planId, options) {
|
|
112
104
|
const resp = await this.client.POST('/api/v1/plans/{planId}/publish', {
|
|
105
|
+
params: { path: { planId } },
|
|
106
|
+
...options,
|
|
107
|
+
});
|
|
108
|
+
return transformResponse(resp);
|
|
109
|
+
}
|
|
110
|
+
}
|
|
111
|
+
/**
|
|
112
|
+
* Plan Addons
|
|
113
|
+
* Manage addon assignments for plans.
|
|
114
|
+
*/
|
|
115
|
+
export class PlanAddons {
|
|
116
|
+
client;
|
|
117
|
+
constructor(client) {
|
|
118
|
+
this.client = client;
|
|
119
|
+
}
|
|
120
|
+
/**
|
|
121
|
+
* List plan addons
|
|
122
|
+
* @param planId - The ID of the plan
|
|
123
|
+
* @param params - Optional query parameters
|
|
124
|
+
* @param options - Optional request options
|
|
125
|
+
* @returns A list of plan addons
|
|
126
|
+
*/
|
|
127
|
+
async list(planId, params, options) {
|
|
128
|
+
const resp = await this.client.GET('/api/v1/plans/{planId}/addons', {
|
|
113
129
|
params: {
|
|
114
|
-
path: {
|
|
115
|
-
|
|
116
|
-
},
|
|
130
|
+
path: { planId },
|
|
131
|
+
query: params,
|
|
117
132
|
},
|
|
118
133
|
...options,
|
|
119
134
|
});
|
|
120
135
|
return transformResponse(resp);
|
|
121
136
|
}
|
|
137
|
+
/**
|
|
138
|
+
* Create a plan addon
|
|
139
|
+
* @param planId - The ID of the plan
|
|
140
|
+
* @param planAddon - The plan addon to create
|
|
141
|
+
* @param options - Optional request options
|
|
142
|
+
* @returns The created plan addon
|
|
143
|
+
*/
|
|
144
|
+
async create(planId, planAddon, options) {
|
|
145
|
+
const resp = await this.client.POST('/api/v1/plans/{planId}/addons', {
|
|
146
|
+
body: planAddon,
|
|
147
|
+
params: { path: { planId } },
|
|
148
|
+
...options,
|
|
149
|
+
});
|
|
150
|
+
return transformResponse(resp);
|
|
151
|
+
}
|
|
152
|
+
/**
|
|
153
|
+
* Get a plan addon by ID
|
|
154
|
+
* @param planId - The ID of the plan
|
|
155
|
+
* @param planAddonId - The ID of the plan addon
|
|
156
|
+
* @param options - Optional request options
|
|
157
|
+
* @returns The plan addon
|
|
158
|
+
*/
|
|
159
|
+
async get(planId, planAddonId, options) {
|
|
160
|
+
const resp = await this.client.GET('/api/v1/plans/{planId}/addons/{planAddonId}', {
|
|
161
|
+
params: {
|
|
162
|
+
path: { planAddonId, planId },
|
|
163
|
+
},
|
|
164
|
+
...options,
|
|
165
|
+
});
|
|
166
|
+
return transformResponse(resp);
|
|
167
|
+
}
|
|
168
|
+
/**
|
|
169
|
+
* Update a plan addon
|
|
170
|
+
* @param planId - The ID of the plan
|
|
171
|
+
* @param planAddonId - The ID of the plan addon to update
|
|
172
|
+
* @param planAddon - The plan addon data to update
|
|
173
|
+
* @param options - Optional request options
|
|
174
|
+
* @returns The updated plan addon
|
|
175
|
+
*/
|
|
176
|
+
async update(planId, planAddonId, planAddon, options) {
|
|
177
|
+
const resp = await this.client.PUT('/api/v1/plans/{planId}/addons/{planAddonId}', {
|
|
178
|
+
body: planAddon,
|
|
179
|
+
params: { path: { planAddonId, planId } },
|
|
180
|
+
...options,
|
|
181
|
+
});
|
|
182
|
+
return transformResponse(resp);
|
|
183
|
+
}
|
|
184
|
+
/**
|
|
185
|
+
* Delete a plan addon by ID
|
|
186
|
+
* @param planId - The ID of the plan
|
|
187
|
+
* @param planAddonId - The ID of the plan addon to delete
|
|
188
|
+
* @param options - Optional request options
|
|
189
|
+
* @returns void or standard error response structure
|
|
190
|
+
*/
|
|
191
|
+
async delete(planId, planAddonId, options) {
|
|
192
|
+
const resp = await this.client.DELETE('/api/v1/plans/{planId}/addons/{planAddonId}', {
|
|
193
|
+
params: { path: { planAddonId, planId } },
|
|
194
|
+
...options,
|
|
195
|
+
});
|
|
196
|
+
return transformResponse(resp);
|
|
197
|
+
}
|
|
122
198
|
}
|
|
123
199
|
//# sourceMappingURL=plans.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"plans.js","sourceRoot":"","sources":["../../../src/client/plans.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,iBAAiB,EAAE,MAAM,YAAY,CAAA;AAU9C,MAAM,OAAO,KAAK;
|
|
1
|
+
{"version":3,"file":"plans.js","sourceRoot":"","sources":["../../../src/client/plans.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,iBAAiB,EAAE,MAAM,YAAY,CAAA;AAU9C;;;GAGG;AACH,MAAM,OAAO,KAAK;IAGI;IAFb,MAAM,CAAY;IAEzB,YAAoB,MAA4C;QAA5C,WAAM,GAAN,MAAM,CAAsC;QAC9D,IAAI,CAAC,MAAM,GAAG,IAAI,UAAU,CAAC,IAAI,CAAC,MAAM,CAAC,CAAA;IAC3C,CAAC;IAED;;;;;OAKG;IACI,KAAK,CAAC,MAAM,CAAC,IAAgB,EAAE,OAAwB;QAC5D,MAAM,IAAI,GAAG,MAAM,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,eAAe,EAAE;YACnD,IAAI,EAAE,IAAI;YACV,GAAG,OAAO;SACX,CAAC,CAAA;QAEF,OAAO,iBAAiB,CAAC,IAAI,CAAC,CAAA;IAChC,CAAC;IAED;;;;;;OAMG;IACI,KAAK,CAAC,GAAG,CACd,MAA6D,EAC7D,MAAqD,EACrD,OAAwB;QAExB,MAAM,IAAI,GAAG,MAAM,IAAI,CAAC,MAAM,CAAC,GAAG,CAAC,wBAAwB,EAAE;YAC3D,MAAM,EAAE;gBACN,IAAI,EAAE,EAAE,MAAM,EAAE;gBAChB,KAAK,EAAE,MAAM;aACd;YACD,GAAG,OAAO;SACX,CAAC,CAAA;QAEF,OAAO,iBAAiB,CAAC,IAAI,CAAC,CAAA;IAChC,CAAC;IAED;;;;;OAKG;IACI,KAAK,CAAC,IAAI,CACf,MAAuD,EACvD,OAAwB;QAExB,MAAM,IAAI,GAAG,MAAM,IAA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A;QAED,OAAO,iBAAiB,CAAC,IAAI,CAAC,CAAA;IAChC,CAAC;IAED;;;;;;;OAOG;IACI,KAAK,CAAC,MAAM,CACjB,MAAqE,EACrE,WAA+E,EAC/E,SAAsF,EACtF,OAAwB;QAExB,MAAM,IAAI,GAAG,MAAM,IAAI,CAAC,MAAM,CAAC,GAAG,CAChC,6CAA6C,EAC7C;YACE,IAAI,EAAE,SAAS;YACf,MAAM,EAAE,EAAE,IAAI,EAAE,EAAE,WAAW,EAAE,MAAM,EAAE,EAAE;YACzC,GAAG,OAAO;SACX,CACF,CAAA;QAED,OAAO,iBAAiB,CAAC,IAAI,CAAC,CAAA;IAChC,CAAC;IAED;;;;;;OAMG;IACI,KAAK,CAAC,MAAM,CACjB,MAAqE,EACrE,WAA+E,EAC/E,OAAwB;QAExB,MAAM,IAAI,GAAG,MAAM,IAAI,CAAC,MAAM,CAAC,MAAM,CACnC,6CAA6C,EAC7C;YACE,MAAM,EAAE,EAAE,IAAI,EAAE,EAAE,WAAW,EAAE,MAAM,EAAE,EAAE;YACzC,GAAG,OAAO;SACX,CACF,CAAA;QAED,OAAO,iBAAiB,CAAC,IAAI,CAAC,CAAA;IAChC,CAAC;CACF"}
|
|
@@ -154,4 +154,12 @@ export declare class Subscriptions {
|
|
|
154
154
|
readonly billingCadence: string;
|
|
155
155
|
readonly proRatingConfig?: import("./schemas.js").components["schemas"]["ProRatingConfig"];
|
|
156
156
|
}>;
|
|
157
|
+
/**
|
|
158
|
+
* Delete subscription
|
|
159
|
+
* @description Deletes a subscription. Only scheduled subscriptions can be deleted.
|
|
160
|
+
* @param subscriptionId - The ID of the subscription to delete
|
|
161
|
+
* @param options - Optional request options
|
|
162
|
+
* @returns void or standard error response structure
|
|
163
|
+
*/
|
|
164
|
+
delete(subscriptionId: operations['deleteSubscription']['parameters']['path']['subscriptionId'], options?: RequestOptions): Promise<undefined>;
|
|
157
165
|
}
|
|
@@ -108,5 +108,21 @@ export class Subscriptions {
|
|
|
108
108
|
});
|
|
109
109
|
return transformResponse(resp);
|
|
110
110
|
}
|
|
111
|
+
/**
|
|
112
|
+
* Delete subscription
|
|
113
|
+
* @description Deletes a subscription. Only scheduled subscriptions can be deleted.
|
|
114
|
+
* @param subscriptionId - The ID of the subscription to delete
|
|
115
|
+
* @param options - Optional request options
|
|
116
|
+
* @returns void or standard error response structure
|
|
117
|
+
*/
|
|
118
|
+
async delete(subscriptionId, options) {
|
|
119
|
+
const resp = await this.client.DELETE('/api/v1/subscriptions/{subscriptionId}', {
|
|
120
|
+
params: {
|
|
121
|
+
path: { subscriptionId },
|
|
122
|
+
},
|
|
123
|
+
...options,
|
|
124
|
+
});
|
|
125
|
+
return transformResponse(resp);
|
|
126
|
+
}
|
|
111
127
|
}
|
|
112
128
|
//# sourceMappingURL=subscriptions.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"subscriptions.js","sourceRoot":"","sources":["../../../src/client/subscriptions.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,iBAAiB,EAAE,MAAM,YAAY,CAAA;AAW9C;;GAEG;AACH,MAAM,OAAO,aAAa;IACK;IAA7B,YAA6B,MAA4C;QAA5C,WAAM,GAAN,MAAM,CAAsC;IAAG,CAAC;IAE7E;;;;;OAKG;IACI,KAAK,CAAC,MAAM,CAAC,IAAwB,EAAE,OAAwB;QACpE,MAAM,IAAI,GAAG,MAAM,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,uBAAuB,EAAE;YAC3D,IAAI;YACJ,GAAG,OAAO;SACX,CAAC,CAAA;QAEF,OAAO,iBAAiB,CAAC,IAAI,CAAC,CAAA;IAChC,CAAC;IAED;;;;;OAKG;IACI,KAAK,CAAC,GAAG,CACd,EAAyE,EACzE,OAAwB;QAExB,MAAM,IAAI,GAAG,MAAM,IAAI,CAAC,MAAM,CAAC,GAAG,CAChC,wCAAwC,EACxC;YACE,MAAM,EAAE,EAAE,IAAI,EAAE,EAAE,cAAc,EAAE,EAAE,EAAE,EAAE;Y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CACjC,gDAAgD,EAChD;YACE,IAAI;YACJ,MAAM,EAAE,EAAE,IAAI,EAAE,EAAE,cAAc,EAAE,EAAE,EAAE,EAAE;YACxC,GAAG,OAAO;SACX,CACF,CAAA;QAED,OAAO,iBAAiB,CAAC,IAAI,CAAC,CAAA;IAChC,CAAC;IAED;;;;;OAKG;IACI,KAAK,CAAC,qBAAqB,CAChC,EAA+E,EAC/E,OAAwB;QAExB,MAAM,IAAI,GAAG,MAAM,IAAI,CAAC,MAAM,CAAC,IAAI,CACjC,+DAA+D,EAC/D;YACE,MAAM,EAAE,EAAE,IAAI,EAAE,EAAE,cAAc,EAAE,EAAE,EAAE,EAAE;YACxC,GAAG,OAAO;SACX,CACF,CAAA;QAED,OAAO,iBAAiB,CAAC,IAAI,CAAC,CAAA;IAChC,CAAC;CACF"}
|
|
1
|
+
{"version":3,"file":"subscriptions.js","sourceRoot":"","sources":["../../../src/client/subscriptions.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,iBAAiB,EAAE,MAAM,YAAY,CAAA;AAW9C;;GAEG;AACH,MAAM,OAAO,aAAa;IACK;IAA7B,YAA6B,MAA4C;QAA5C,WAAM,GAAN,MAAM,CAAsC;IAAG,CAAC;IAE7E;;;;;OAKG;IACI,KAAK,CAAC,MAAM,CAAC,IAAwB,EAAE,OAAwB;QACpE,MAAM,IAAI,GAAG,MAAM,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,uBAAuB,EAAE;YAC3D,IAAI;YACJ,GAAG,OAAO;SACX,CAAC,CAAA;QAEF,OAAO,iBAAiB,CAAC,IAAI,CAAC,CAAA;IAChC,CAAC;IAED;;;;;OAKG;IACI,KAAK,CAAC,GAAG,CACd,EAAyE,EACzE,OAAwB;QAExB,MAAM,IAAI,GAAG,MAAM,IAAI,CAAC,MAAM,CAAC,GAAG,CAChC,wCAAwC,EACxC;YACE,MAAM,EAAE,EAAE,IAAI,EAAE,EAAE,cAAc,EAAE,EAAE,EAAE,EAAE;YACxC,GAAG,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