@mintmoney/react 0.1.0-alpha.11 → 0.1.0-alpha.12
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/esm/api/checkouts.js +9 -9
- package/dist/esm/api/generated.js +544 -592
- package/dist/esm/api/index.js +10 -10
- package/dist/esm/api/payments.js +17 -21
- package/dist/esm/api/types.js +8 -2
- package/dist/esm/api/types.js.map +1 -1
- package/dist/esm/checkout/container.js +2 -2
- package/dist/esm/checkout/index.js +18 -38
- package/dist/esm/checkout/modal.js +52 -63
- package/dist/esm/checkout/views/back.js +3 -7
- package/dist/esm/checkout/views/card-intent/details.js +4 -21
- package/dist/esm/checkout/views/crypto-intent/curreny.js +18 -43
- package/dist/esm/checkout/views/crypto-intent/curreny.js.map +1 -1
- package/dist/esm/checkout/views/crypto-intent/direct-details.js +16 -60
- package/dist/esm/checkout/views/crypto-intent/methods.js +19 -27
- package/dist/esm/checkout/views/crypto-intent/processing.js +31 -39
- package/dist/esm/checkout/views/crypto-intent/processing.js.map +1 -1
- package/dist/esm/checkout/views/crypto-intent/success.js +14 -32
- package/dist/esm/checkout/views/initial.js +24 -29
- package/dist/esm/checkout/views/method-select.js +10 -24
- package/dist/esm/components/buttons/index.js +11 -20
- package/dist/esm/components/icons/checkMark.js +4 -16
- package/dist/esm/components/icons/close.js +4 -19
- package/dist/esm/components/icons/index.js +1 -1
- package/dist/esm/components/index.js +1 -1
- package/dist/esm/components/lists/empty.js +2 -5
- package/dist/esm/components/lists/index.js +8 -47
- package/dist/esm/components/loading/index.js +6 -47
- package/dist/esm/components/modals/index.js +1 -1
- package/dist/esm/components/modals/modal-with-views.js +23 -62
- package/dist/esm/components/modals/modal.js +11 -67
- package/dist/esm/components/modals/use-modal-with-views.js +22 -25
- package/dist/esm/components/text/index.js +21 -21
- package/dist/esm/config.js +14 -5
- package/dist/esm/config.js.map +1 -1
- package/dist/esm/context.js +10 -18
- package/dist/esm/index.js +1 -1
- package/dist/esm/state/checkout/store.js +144 -144
- package/dist/esm/state/checkout/store.js.map +1 -1
- package/dist/esm/themes/default.js +55 -55
- package/dist/esm/themes/index.js +1 -1
- package/dist/esm/themes/types.js +1 -1
- package/dist/esm/utils/cn.js +1 -1
- package/dist/types/api/checkouts.d.ts +5 -5
- package/dist/types/api/generated.d.ts +835 -924
- package/dist/types/api/index.d.ts +1 -1
- package/dist/types/api/payments.d.ts +3 -10
- package/dist/types/api/types.d.ts +16 -14
- package/dist/types/api/types.d.ts.map +1 -1
- package/dist/types/checkout/container.d.ts +2 -12
- package/dist/types/checkout/index.d.ts +6 -10
- package/dist/types/checkout/modal.d.ts +5 -7
- package/dist/types/checkout/views/back.d.ts +3 -5
- package/dist/types/checkout/views/card-intent/details.d.ts +1 -1
- package/dist/types/checkout/views/crypto-intent/curreny.d.ts +1 -1
- package/dist/types/checkout/views/crypto-intent/curreny.d.ts.map +1 -1
- package/dist/types/checkout/views/crypto-intent/direct-details.d.ts +2 -4
- package/dist/types/checkout/views/crypto-intent/methods.d.ts +1 -1
- package/dist/types/checkout/views/crypto-intent/processing.d.ts +1 -1
- package/dist/types/checkout/views/crypto-intent/processing.d.ts.map +1 -1
- package/dist/types/checkout/views/crypto-intent/success.d.ts +3 -5
- package/dist/types/checkout/views/initial.d.ts +3 -5
- package/dist/types/checkout/views/method-select.d.ts +1 -1
- package/dist/types/components/buttons/index.d.ts +6 -16
- package/dist/types/components/icons/checkMark.d.ts +3 -5
- package/dist/types/components/icons/close.d.ts +3 -5
- package/dist/types/components/icons/index.d.ts +1 -1
- package/dist/types/components/index.d.ts +1 -1
- package/dist/types/components/lists/empty.d.ts +3 -5
- package/dist/types/components/lists/index.d.ts +9 -17
- package/dist/types/components/loading/index.d.ts +4 -4
- package/dist/types/components/modals/index.d.ts +1 -1
- package/dist/types/components/modals/modal-with-views.d.ts +18 -23
- package/dist/types/components/modals/modal.d.ts +9 -17
- package/dist/types/components/modals/use-modal-with-views.d.ts +6 -9
- package/dist/types/components/text/index.d.ts +7 -17
- package/dist/types/config.d.ts +16 -12
- package/dist/types/config.d.ts.map +1 -1
- package/dist/types/context.d.ts +4 -7
- package/dist/types/index.d.ts +1 -1
- package/dist/types/state/checkout/store.d.ts +51 -74
- package/dist/types/state/checkout/store.d.ts.map +1 -1
- package/dist/types/themes/default.d.ts +1 -1
- package/dist/types/themes/index.d.ts +1 -1
- package/dist/types/themes/types.d.ts +26 -25
- package/dist/types/utils/cn.d.ts +1 -1
- package/package.json +1 -1
|
@@ -10,234 +10,208 @@
|
|
|
10
10
|
*/
|
|
11
11
|
export var ContentType;
|
|
12
12
|
(function (ContentType) {
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
13
|
+
ContentType["Json"] = "application/json";
|
|
14
|
+
ContentType["FormData"] = "multipart/form-data";
|
|
15
|
+
ContentType["UrlEncoded"] = "application/x-www-form-urlencoded";
|
|
16
|
+
ContentType["Text"] = "text/plain";
|
|
17
17
|
})(ContentType || (ContentType = {}));
|
|
18
18
|
export class HttpClient {
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
r.data = null;
|
|
175
|
-
r.error = null;
|
|
176
|
-
const data = !responseFormat
|
|
177
|
-
? r
|
|
178
|
-
: await response[responseFormat]()
|
|
179
|
-
.then((data) => {
|
|
180
|
-
if (r.ok) {
|
|
181
|
-
r.data = data;
|
|
182
|
-
} else {
|
|
183
|
-
r.error = data;
|
|
184
|
-
}
|
|
185
|
-
return r;
|
|
186
|
-
})
|
|
187
|
-
.catch((e) => {
|
|
188
|
-
r.error = e;
|
|
189
|
-
return r;
|
|
19
|
+
constructor(apiConfig = {}) {
|
|
20
|
+
Object.defineProperty(this, "baseUrl", {
|
|
21
|
+
enumerable: true,
|
|
22
|
+
configurable: true,
|
|
23
|
+
writable: true,
|
|
24
|
+
value: "https://api.local.getmint.money"
|
|
25
|
+
});
|
|
26
|
+
Object.defineProperty(this, "securityData", {
|
|
27
|
+
enumerable: true,
|
|
28
|
+
configurable: true,
|
|
29
|
+
writable: true,
|
|
30
|
+
value: null
|
|
31
|
+
});
|
|
32
|
+
Object.defineProperty(this, "securityWorker", {
|
|
33
|
+
enumerable: true,
|
|
34
|
+
configurable: true,
|
|
35
|
+
writable: true,
|
|
36
|
+
value: void 0
|
|
37
|
+
});
|
|
38
|
+
Object.defineProperty(this, "abortControllers", {
|
|
39
|
+
enumerable: true,
|
|
40
|
+
configurable: true,
|
|
41
|
+
writable: true,
|
|
42
|
+
value: new Map()
|
|
43
|
+
});
|
|
44
|
+
Object.defineProperty(this, "customFetch", {
|
|
45
|
+
enumerable: true,
|
|
46
|
+
configurable: true,
|
|
47
|
+
writable: true,
|
|
48
|
+
value: (...fetchParams) => fetch(...fetchParams)
|
|
49
|
+
});
|
|
50
|
+
Object.defineProperty(this, "baseApiParams", {
|
|
51
|
+
enumerable: true,
|
|
52
|
+
configurable: true,
|
|
53
|
+
writable: true,
|
|
54
|
+
value: {
|
|
55
|
+
credentials: "same-origin",
|
|
56
|
+
headers: {},
|
|
57
|
+
redirect: "follow",
|
|
58
|
+
referrerPolicy: "no-referrer",
|
|
59
|
+
}
|
|
60
|
+
});
|
|
61
|
+
Object.defineProperty(this, "setSecurityData", {
|
|
62
|
+
enumerable: true,
|
|
63
|
+
configurable: true,
|
|
64
|
+
writable: true,
|
|
65
|
+
value: (data) => {
|
|
66
|
+
this.securityData = data;
|
|
67
|
+
}
|
|
68
|
+
});
|
|
69
|
+
Object.defineProperty(this, "contentFormatters", {
|
|
70
|
+
enumerable: true,
|
|
71
|
+
configurable: true,
|
|
72
|
+
writable: true,
|
|
73
|
+
value: {
|
|
74
|
+
[ContentType.Json]: (input) => input !== null && (typeof input === "object" || typeof input === "string")
|
|
75
|
+
? JSON.stringify(input)
|
|
76
|
+
: input,
|
|
77
|
+
[ContentType.Text]: (input) => input !== null && typeof input !== "string"
|
|
78
|
+
? JSON.stringify(input)
|
|
79
|
+
: input,
|
|
80
|
+
[ContentType.FormData]: (input) => Object.keys(input || {}).reduce((formData, key) => {
|
|
81
|
+
const property = input[key];
|
|
82
|
+
formData.append(key, property instanceof Blob
|
|
83
|
+
? property
|
|
84
|
+
: typeof property === "object" && property !== null
|
|
85
|
+
? JSON.stringify(property)
|
|
86
|
+
: `${property}`);
|
|
87
|
+
return formData;
|
|
88
|
+
}, new FormData()),
|
|
89
|
+
[ContentType.UrlEncoded]: (input) => this.toQueryString(input),
|
|
90
|
+
}
|
|
91
|
+
});
|
|
92
|
+
Object.defineProperty(this, "createAbortSignal", {
|
|
93
|
+
enumerable: true,
|
|
94
|
+
configurable: true,
|
|
95
|
+
writable: true,
|
|
96
|
+
value: (cancelToken) => {
|
|
97
|
+
if (this.abortControllers.has(cancelToken)) {
|
|
98
|
+
const abortController = this.abortControllers.get(cancelToken);
|
|
99
|
+
if (abortController) {
|
|
100
|
+
return abortController.signal;
|
|
101
|
+
}
|
|
102
|
+
return void 0;
|
|
103
|
+
}
|
|
104
|
+
const abortController = new AbortController();
|
|
105
|
+
this.abortControllers.set(cancelToken, abortController);
|
|
106
|
+
return abortController.signal;
|
|
107
|
+
}
|
|
108
|
+
});
|
|
109
|
+
Object.defineProperty(this, "abortRequest", {
|
|
110
|
+
enumerable: true,
|
|
111
|
+
configurable: true,
|
|
112
|
+
writable: true,
|
|
113
|
+
value: (cancelToken) => {
|
|
114
|
+
const abortController = this.abortControllers.get(cancelToken);
|
|
115
|
+
if (abortController) {
|
|
116
|
+
abortController.abort();
|
|
117
|
+
this.abortControllers.delete(cancelToken);
|
|
118
|
+
}
|
|
119
|
+
}
|
|
120
|
+
});
|
|
121
|
+
Object.defineProperty(this, "request", {
|
|
122
|
+
enumerable: true,
|
|
123
|
+
configurable: true,
|
|
124
|
+
writable: true,
|
|
125
|
+
value: async ({ body, secure, path, type, query, format, baseUrl, cancelToken, ...params }) => {
|
|
126
|
+
const secureParams = ((typeof secure === "boolean" ? secure : this.baseApiParams.secure) &&
|
|
127
|
+
this.securityWorker &&
|
|
128
|
+
(await this.securityWorker(this.securityData))) ||
|
|
129
|
+
{};
|
|
130
|
+
const requestParams = this.mergeRequestParams(params, secureParams);
|
|
131
|
+
const queryString = query && this.toQueryString(query);
|
|
132
|
+
const payloadFormatter = this.contentFormatters[type || ContentType.Json];
|
|
133
|
+
const responseFormat = format || requestParams.format;
|
|
134
|
+
return this.customFetch(`${baseUrl || this.baseUrl || ""}${path}${queryString ? `?${queryString}` : ""}`, {
|
|
135
|
+
...requestParams,
|
|
136
|
+
headers: {
|
|
137
|
+
...(requestParams.headers || {}),
|
|
138
|
+
...(type && type !== ContentType.FormData
|
|
139
|
+
? { "Content-Type": type }
|
|
140
|
+
: {}),
|
|
141
|
+
},
|
|
142
|
+
signal: (cancelToken
|
|
143
|
+
? this.createAbortSignal(cancelToken)
|
|
144
|
+
: requestParams.signal) || null,
|
|
145
|
+
body: typeof body === "undefined" || body === null
|
|
146
|
+
? null
|
|
147
|
+
: payloadFormatter(body),
|
|
148
|
+
}).then(async (response) => {
|
|
149
|
+
const r = response.clone();
|
|
150
|
+
r.data = null;
|
|
151
|
+
r.error = null;
|
|
152
|
+
const data = !responseFormat
|
|
153
|
+
? r
|
|
154
|
+
: await response[responseFormat]()
|
|
155
|
+
.then((data) => {
|
|
156
|
+
if (r.ok) {
|
|
157
|
+
r.data = data;
|
|
158
|
+
}
|
|
159
|
+
else {
|
|
160
|
+
r.error = data;
|
|
161
|
+
}
|
|
162
|
+
return r;
|
|
163
|
+
})
|
|
164
|
+
.catch((e) => {
|
|
165
|
+
r.error = e;
|
|
166
|
+
return r;
|
|
167
|
+
});
|
|
168
|
+
if (cancelToken) {
|
|
169
|
+
this.abortControllers.delete(cancelToken);
|
|
170
|
+
}
|
|
171
|
+
if (!response.ok)
|
|
172
|
+
throw data;
|
|
173
|
+
return data;
|
|
190
174
|
});
|
|
191
|
-
|
|
192
|
-
this.abortControllers.delete(cancelToken);
|
|
193
|
-
}
|
|
194
|
-
if (!response.ok) throw data;
|
|
195
|
-
return data;
|
|
175
|
+
}
|
|
196
176
|
});
|
|
197
|
-
|
|
198
|
-
}
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
...(this.baseApiParams.headers || {}),
|
|
236
|
-
...(params1.headers || {}),
|
|
237
|
-
...((params2 && params2.headers) || {}),
|
|
238
|
-
},
|
|
239
|
-
};
|
|
240
|
-
}
|
|
177
|
+
Object.assign(this, apiConfig);
|
|
178
|
+
}
|
|
179
|
+
encodeQueryParam(key, value) {
|
|
180
|
+
const encodedKey = encodeURIComponent(key);
|
|
181
|
+
return `${encodedKey}=${encodeURIComponent(typeof value === "number" ? value : `${value}`)}`;
|
|
182
|
+
}
|
|
183
|
+
addQueryParam(query, key) {
|
|
184
|
+
return this.encodeQueryParam(key, query[key]);
|
|
185
|
+
}
|
|
186
|
+
addArrayQueryParam(query, key) {
|
|
187
|
+
const value = query[key];
|
|
188
|
+
return value.map((v) => this.encodeQueryParam(key, v)).join("&");
|
|
189
|
+
}
|
|
190
|
+
toQueryString(rawQuery) {
|
|
191
|
+
const query = rawQuery || {};
|
|
192
|
+
const keys = Object.keys(query).filter((key) => "undefined" !== typeof query[key]);
|
|
193
|
+
return keys
|
|
194
|
+
.map((key) => Array.isArray(query[key])
|
|
195
|
+
? this.addArrayQueryParam(query, key)
|
|
196
|
+
: this.addQueryParam(query, key))
|
|
197
|
+
.join("&");
|
|
198
|
+
}
|
|
199
|
+
addQueryParams(rawQuery) {
|
|
200
|
+
const queryString = this.toQueryString(rawQuery);
|
|
201
|
+
return queryString ? `?${queryString}` : "";
|
|
202
|
+
}
|
|
203
|
+
mergeRequestParams(params1, params2) {
|
|
204
|
+
return {
|
|
205
|
+
...this.baseApiParams,
|
|
206
|
+
...params1,
|
|
207
|
+
...(params2 || {}),
|
|
208
|
+
headers: {
|
|
209
|
+
...(this.baseApiParams.headers || {}),
|
|
210
|
+
...(params1.headers || {}),
|
|
211
|
+
...((params2 && params2.headers) || {}),
|
|
212
|
+
},
|
|
213
|
+
};
|
|
214
|
+
}
|
|
241
215
|
}
|
|
242
216
|
/**
|
|
243
217
|
* @title Mint Money API
|
|
@@ -247,372 +221,350 @@ export class HttpClient {
|
|
|
247
221
|
* API for the getmint.money platform
|
|
248
222
|
*/
|
|
249
223
|
export class Api extends HttpClient {
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
|
|
327
|
-
|
|
328
|
-
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
|
|
370
|
-
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
|
|
383
|
-
|
|
384
|
-
|
|
385
|
-
|
|
386
|
-
|
|
387
|
-
|
|
388
|
-
|
|
389
|
-
|
|
390
|
-
|
|
391
|
-
|
|
392
|
-
|
|
393
|
-
|
|
394
|
-
|
|
395
|
-
|
|
396
|
-
|
|
397
|
-
|
|
398
|
-
|
|
399
|
-
|
|
400
|
-
|
|
401
|
-
|
|
402
|
-
|
|
403
|
-
|
|
404
|
-
|
|
405
|
-
|
|
406
|
-
|
|
407
|
-
|
|
408
|
-
|
|
409
|
-
|
|
410
|
-
|
|
411
|
-
|
|
412
|
-
|
|
413
|
-
|
|
414
|
-
|
|
415
|
-
|
|
416
|
-
|
|
417
|
-
|
|
418
|
-
|
|
419
|
-
|
|
420
|
-
|
|
421
|
-
|
|
422
|
-
|
|
423
|
-
|
|
424
|
-
|
|
425
|
-
|
|
426
|
-
|
|
427
|
-
|
|
428
|
-
|
|
429
|
-
|
|
430
|
-
|
|
431
|
-
|
|
432
|
-
|
|
433
|
-
|
|
434
|
-
|
|
435
|
-
|
|
436
|
-
|
|
437
|
-
|
|
438
|
-
|
|
439
|
-
|
|
440
|
-
|
|
441
|
-
|
|
442
|
-
|
|
443
|
-
|
|
444
|
-
|
|
445
|
-
|
|
446
|
-
|
|
447
|
-
|
|
448
|
-
|
|
449
|
-
|
|
450
|
-
|
|
451
|
-
|
|
452
|
-
|
|
453
|
-
|
|
454
|
-
|
|
455
|
-
|
|
456
|
-
|
|
457
|
-
|
|
458
|
-
|
|
459
|
-
|
|
460
|
-
|
|
461
|
-
|
|
462
|
-
|
|
463
|
-
|
|
464
|
-
|
|
465
|
-
|
|
466
|
-
|
|
467
|
-
|
|
468
|
-
|
|
469
|
-
|
|
470
|
-
|
|
471
|
-
|
|
472
|
-
|
|
473
|
-
|
|
474
|
-
|
|
475
|
-
|
|
476
|
-
|
|
477
|
-
|
|
478
|
-
|
|
479
|
-
|
|
480
|
-
|
|
481
|
-
|
|
482
|
-
|
|
483
|
-
|
|
484
|
-
|
|
485
|
-
|
|
486
|
-
|
|
487
|
-
|
|
488
|
-
|
|
489
|
-
|
|
490
|
-
|
|
491
|
-
|
|
492
|
-
|
|
493
|
-
|
|
494
|
-
|
|
495
|
-
|
|
496
|
-
|
|
497
|
-
|
|
498
|
-
|
|
499
|
-
|
|
500
|
-
|
|
501
|
-
|
|
502
|
-
|
|
503
|
-
|
|
504
|
-
|
|
505
|
-
|
|
506
|
-
|
|
507
|
-
|
|
508
|
-
|
|
509
|
-
|
|
510
|
-
|
|
511
|
-
|
|
512
|
-
|
|
513
|
-
|
|
514
|
-
|
|
515
|
-
|
|
516
|
-
|
|
517
|
-
|
|
518
|
-
|
|
519
|
-
|
|
520
|
-
|
|
521
|
-
|
|
522
|
-
|
|
523
|
-
|
|
524
|
-
|
|
525
|
-
|
|
526
|
-
|
|
527
|
-
|
|
528
|
-
|
|
529
|
-
|
|
530
|
-
|
|
531
|
-
|
|
532
|
-
|
|
533
|
-
|
|
534
|
-
|
|
535
|
-
|
|
536
|
-
|
|
537
|
-
|
|
538
|
-
|
|
539
|
-
|
|
540
|
-
|
|
541
|
-
|
|
542
|
-
|
|
543
|
-
|
|
544
|
-
|
|
545
|
-
|
|
546
|
-
|
|
547
|
-
|
|
548
|
-
|
|
549
|
-
|
|
550
|
-
|
|
551
|
-
|
|
552
|
-
|
|
553
|
-
|
|
554
|
-
|
|
555
|
-
|
|
556
|
-
|
|
557
|
-
|
|
558
|
-
|
|
559
|
-
|
|
560
|
-
|
|
561
|
-
|
|
562
|
-
|
|
563
|
-
|
|
564
|
-
|
|
565
|
-
|
|
566
|
-
|
|
567
|
-
|
|
568
|
-
|
|
569
|
-
|
|
570
|
-
|
|
571
|
-
|
|
572
|
-
|
|
573
|
-
|
|
574
|
-
|
|
575
|
-
|
|
576
|
-
|
|
577
|
-
|
|
578
|
-
|
|
579
|
-
|
|
580
|
-
|
|
581
|
-
|
|
582
|
-
|
|
583
|
-
|
|
584
|
-
|
|
585
|
-
|
|
586
|
-
|
|
587
|
-
|
|
588
|
-
|
|
589
|
-
|
|
590
|
-
|
|
591
|
-
|
|
592
|
-
|
|
593
|
-
|
|
594
|
-
|
|
595
|
-
...params,
|
|
596
|
-
}),
|
|
597
|
-
/**
|
|
598
|
-
* @description Create a new merchant account
|
|
599
|
-
*
|
|
600
|
-
* @tags Merchant Accounts
|
|
601
|
-
* @name MerchantAccountsCreate
|
|
602
|
-
* @request POST:/v1/merchant-accounts/
|
|
603
|
-
* @response `201` `MerchantAccountsCreateData` Default Response
|
|
604
|
-
*/
|
|
605
|
-
merchantAccountsCreate: (data, params = {}) =>
|
|
606
|
-
this.request({
|
|
607
|
-
path: `/v1/merchant-accounts/`,
|
|
608
|
-
method: "POST",
|
|
609
|
-
body: data,
|
|
610
|
-
type: ContentType.Json,
|
|
611
|
-
format: "json",
|
|
612
|
-
...params,
|
|
613
|
-
}),
|
|
614
|
-
},
|
|
615
|
-
});
|
|
616
|
-
}
|
|
224
|
+
constructor() {
|
|
225
|
+
super(...arguments);
|
|
226
|
+
Object.defineProperty(this, "v1", {
|
|
227
|
+
enumerable: true,
|
|
228
|
+
configurable: true,
|
|
229
|
+
writable: true,
|
|
230
|
+
value: {
|
|
231
|
+
/**
|
|
232
|
+
* No description
|
|
233
|
+
*
|
|
234
|
+
* @tags Health
|
|
235
|
+
* @name HealthzList
|
|
236
|
+
* @request GET:/v1/healthz
|
|
237
|
+
* @response `200` `HealthzListData` Default Response
|
|
238
|
+
*/
|
|
239
|
+
healthzList: (params = {}) => this.request({
|
|
240
|
+
path: `/v1/healthz`,
|
|
241
|
+
method: "GET",
|
|
242
|
+
format: "json",
|
|
243
|
+
...params,
|
|
244
|
+
}),
|
|
245
|
+
/**
|
|
246
|
+
* @description Create a new organisation
|
|
247
|
+
*
|
|
248
|
+
* @tags Organisations
|
|
249
|
+
* @name OrganizationsCreate
|
|
250
|
+
* @request POST:/v1/organizations/
|
|
251
|
+
* @response `201` `OrganizationsCreateData` Default Response
|
|
252
|
+
*/
|
|
253
|
+
organizationsCreate: (data, params = {}) => this.request({
|
|
254
|
+
path: `/v1/organizations/`,
|
|
255
|
+
method: "POST",
|
|
256
|
+
body: data,
|
|
257
|
+
type: ContentType.Json,
|
|
258
|
+
format: "json",
|
|
259
|
+
...params,
|
|
260
|
+
}),
|
|
261
|
+
/**
|
|
262
|
+
* @description Get account details for the current user
|
|
263
|
+
*
|
|
264
|
+
* @tags Account
|
|
265
|
+
* @name AccountsMeList
|
|
266
|
+
* @request GET:/v1/accounts/me
|
|
267
|
+
* @response `200` `AccountsMeListData` Default Response
|
|
268
|
+
*/
|
|
269
|
+
accountsMeList: (params = {}) => this.request({
|
|
270
|
+
path: `/v1/accounts/me`,
|
|
271
|
+
method: "GET",
|
|
272
|
+
format: "json",
|
|
273
|
+
...params,
|
|
274
|
+
}),
|
|
275
|
+
/**
|
|
276
|
+
* @description Create a new on-chain payment
|
|
277
|
+
*
|
|
278
|
+
* @tags Payments
|
|
279
|
+
* @name PaymentsCreate
|
|
280
|
+
* @request POST:/v1/payments/
|
|
281
|
+
* @response `201` `PaymentsCreateData` Default Response
|
|
282
|
+
*/
|
|
283
|
+
paymentsCreate: (data, params = {}) => this.request({
|
|
284
|
+
path: `/v1/payments/`,
|
|
285
|
+
method: "POST",
|
|
286
|
+
body: data,
|
|
287
|
+
type: ContentType.Json,
|
|
288
|
+
format: "json",
|
|
289
|
+
...params,
|
|
290
|
+
}),
|
|
291
|
+
/**
|
|
292
|
+
* @description Fetch all payment by id
|
|
293
|
+
*
|
|
294
|
+
* @tags Payments
|
|
295
|
+
* @name PaymentsList
|
|
296
|
+
* @request GET:/v1/payments/
|
|
297
|
+
* @response `200` `PaymentsListData` Default Response
|
|
298
|
+
*/
|
|
299
|
+
paymentsList: (query, params = {}) => this.request({
|
|
300
|
+
path: `/v1/payments/`,
|
|
301
|
+
method: "GET",
|
|
302
|
+
query: query,
|
|
303
|
+
format: "json",
|
|
304
|
+
...params,
|
|
305
|
+
}),
|
|
306
|
+
/**
|
|
307
|
+
* @description Fetch a payment by id
|
|
308
|
+
*
|
|
309
|
+
* @tags Payments
|
|
310
|
+
* @name PaymentsDetail
|
|
311
|
+
* @request GET:/v1/payments/{paymentId}
|
|
312
|
+
* @response `201` `PaymentsDetailData` Default Response
|
|
313
|
+
*/
|
|
314
|
+
paymentsDetail: (paymentId, params = {}) => this.request({
|
|
315
|
+
path: `/v1/payments/${paymentId}`,
|
|
316
|
+
method: "GET",
|
|
317
|
+
format: "json",
|
|
318
|
+
...params,
|
|
319
|
+
}),
|
|
320
|
+
/**
|
|
321
|
+
* @description Add attempt to pay for a payment using cryptocurrency
|
|
322
|
+
*
|
|
323
|
+
* @tags Payments
|
|
324
|
+
* @name PaymentsCryptoPayCreate
|
|
325
|
+
* @request POST:/v1/payments/crypto-pay/{paymentId}
|
|
326
|
+
* @response `201` `PaymentsCryptoPayCreateData` Default Response
|
|
327
|
+
*/
|
|
328
|
+
paymentsCryptoPayCreate: (paymentId, data, params = {}) => this.request({
|
|
329
|
+
path: `/v1/payments/crypto-pay/${paymentId}`,
|
|
330
|
+
method: "POST",
|
|
331
|
+
body: data,
|
|
332
|
+
type: ContentType.Json,
|
|
333
|
+
format: "json",
|
|
334
|
+
...params,
|
|
335
|
+
}),
|
|
336
|
+
/**
|
|
337
|
+
* @description Fetch the supported chains
|
|
338
|
+
*
|
|
339
|
+
* @tags Chain
|
|
340
|
+
* @name ChainsList
|
|
341
|
+
* @request GET:/v1/chains
|
|
342
|
+
* @response `200` `ChainsListData` Default Response
|
|
343
|
+
*/
|
|
344
|
+
chainsList: (query, params = {}) => this.request({
|
|
345
|
+
path: `/v1/chains`,
|
|
346
|
+
method: "GET",
|
|
347
|
+
query: query,
|
|
348
|
+
format: "json",
|
|
349
|
+
...params,
|
|
350
|
+
}),
|
|
351
|
+
/**
|
|
352
|
+
* @description Fetch the supported tokens
|
|
353
|
+
*
|
|
354
|
+
* @tags Chain
|
|
355
|
+
* @name TokensList
|
|
356
|
+
* @request GET:/v1/tokens
|
|
357
|
+
* @response `200` `TokensListData` Default Response
|
|
358
|
+
*/
|
|
359
|
+
tokensList: (query, params = {}) => this.request({
|
|
360
|
+
path: `/v1/tokens`,
|
|
361
|
+
method: "GET",
|
|
362
|
+
query: query,
|
|
363
|
+
format: "json",
|
|
364
|
+
...params,
|
|
365
|
+
}),
|
|
366
|
+
/**
|
|
367
|
+
* @description Create a new endpoint for the organization
|
|
368
|
+
*
|
|
369
|
+
* @tags Webhooks
|
|
370
|
+
* @name WebhooksCreate
|
|
371
|
+
* @request POST:/v1/webhooks/
|
|
372
|
+
* @response `201` `WebhooksCreateData` Default Response
|
|
373
|
+
*/
|
|
374
|
+
webhooksCreate: (data, params = {}) => this.request({
|
|
375
|
+
path: `/v1/webhooks/`,
|
|
376
|
+
method: "POST",
|
|
377
|
+
body: data,
|
|
378
|
+
type: ContentType.Json,
|
|
379
|
+
format: "json",
|
|
380
|
+
...params,
|
|
381
|
+
}),
|
|
382
|
+
/**
|
|
383
|
+
* @description Fetch all WebhookUrls
|
|
384
|
+
*
|
|
385
|
+
* @tags Webhooks
|
|
386
|
+
* @name WebhooksList
|
|
387
|
+
* @request GET:/v1/webhooks/
|
|
388
|
+
* @response `200` `WebhooksListData` Default Response
|
|
389
|
+
*/
|
|
390
|
+
webhooksList: (query, params = {}) => this.request({
|
|
391
|
+
path: `/v1/webhooks/`,
|
|
392
|
+
method: "GET",
|
|
393
|
+
query: query,
|
|
394
|
+
format: "json",
|
|
395
|
+
...params,
|
|
396
|
+
}),
|
|
397
|
+
/**
|
|
398
|
+
* @description Create a new API key for the organization
|
|
399
|
+
*
|
|
400
|
+
* @tags ApiKeys
|
|
401
|
+
* @name ApiKeysCreate
|
|
402
|
+
* @request POST:/v1/api-keys/
|
|
403
|
+
* @response `201` `ApiKeysCreateData` Default Response
|
|
404
|
+
*/
|
|
405
|
+
apiKeysCreate: (data, params = {}) => this.request({
|
|
406
|
+
path: `/v1/api-keys/`,
|
|
407
|
+
method: "POST",
|
|
408
|
+
body: data,
|
|
409
|
+
type: ContentType.Json,
|
|
410
|
+
format: "json",
|
|
411
|
+
...params,
|
|
412
|
+
}),
|
|
413
|
+
/**
|
|
414
|
+
* @description Fetch all ApiKeys
|
|
415
|
+
*
|
|
416
|
+
* @tags ApiKeys
|
|
417
|
+
* @name ApiKeysList
|
|
418
|
+
* @request GET:/v1/api-keys/
|
|
419
|
+
* @response `200` `ApiKeysListData` Default Response
|
|
420
|
+
*/
|
|
421
|
+
apiKeysList: (query, params = {}) => this.request({
|
|
422
|
+
path: `/v1/api-keys/`,
|
|
423
|
+
method: "GET",
|
|
424
|
+
query: query,
|
|
425
|
+
format: "json",
|
|
426
|
+
...params,
|
|
427
|
+
}),
|
|
428
|
+
/**
|
|
429
|
+
* @description Delete an ApiKey
|
|
430
|
+
*
|
|
431
|
+
* @tags ApiKeys
|
|
432
|
+
* @name ApiKeysDelete
|
|
433
|
+
* @request DELETE:/v1/api-keys/{apiKeyId}
|
|
434
|
+
* @response `200` `ApiKeysDeleteData` Default Response
|
|
435
|
+
*/
|
|
436
|
+
apiKeysDelete: (apiKeyId, params = {}) => this.request({
|
|
437
|
+
path: `/v1/api-keys/${apiKeyId}`,
|
|
438
|
+
method: "DELETE",
|
|
439
|
+
format: "json",
|
|
440
|
+
...params,
|
|
441
|
+
}),
|
|
442
|
+
/**
|
|
443
|
+
* @description Patch an ApiKey
|
|
444
|
+
*
|
|
445
|
+
* @tags ApiKeys
|
|
446
|
+
* @name ApiKeysPartialUpdate
|
|
447
|
+
* @request PATCH:/v1/api-keys/{apiKeyId}
|
|
448
|
+
* @response `201` `ApiKeysPartialUpdateData` Default Response
|
|
449
|
+
*/
|
|
450
|
+
apiKeysPartialUpdate: (apiKeyId, data, params = {}) => this.request({
|
|
451
|
+
path: `/v1/api-keys/${apiKeyId}`,
|
|
452
|
+
method: "PATCH",
|
|
453
|
+
body: data,
|
|
454
|
+
type: ContentType.Json,
|
|
455
|
+
format: "json",
|
|
456
|
+
...params,
|
|
457
|
+
}),
|
|
458
|
+
/**
|
|
459
|
+
* @description Sync a specific block
|
|
460
|
+
*
|
|
461
|
+
* @tags Blocks
|
|
462
|
+
* @name BlocksCreate
|
|
463
|
+
* @request POST:/v1/blocks
|
|
464
|
+
* @response `200` `BlocksCreateData` Default Response
|
|
465
|
+
*/
|
|
466
|
+
blocksCreate: (data, params = {}) => this.request({
|
|
467
|
+
path: `/v1/blocks`,
|
|
468
|
+
method: "POST",
|
|
469
|
+
body: data,
|
|
470
|
+
type: ContentType.Json,
|
|
471
|
+
format: "json",
|
|
472
|
+
...params,
|
|
473
|
+
}),
|
|
474
|
+
/**
|
|
475
|
+
* @description Begin identity verification
|
|
476
|
+
*
|
|
477
|
+
* @tags Auth
|
|
478
|
+
* @name AuthIdentifyStartCreate
|
|
479
|
+
* @request POST:/v1/auth/identify/start
|
|
480
|
+
* @response `200` `AuthIdentifyStartCreateData` Default Response
|
|
481
|
+
*/
|
|
482
|
+
authIdentifyStartCreate: (data, params = {}) => this.request({
|
|
483
|
+
path: `/v1/auth/identify/start`,
|
|
484
|
+
method: "POST",
|
|
485
|
+
body: data,
|
|
486
|
+
type: ContentType.Json,
|
|
487
|
+
format: "json",
|
|
488
|
+
...params,
|
|
489
|
+
}),
|
|
490
|
+
/**
|
|
491
|
+
* @description Send identity verification
|
|
492
|
+
*
|
|
493
|
+
* @tags Auth
|
|
494
|
+
* @name AuthIdentifyVerifyCreate
|
|
495
|
+
* @request POST:/v1/auth/identify/verify
|
|
496
|
+
* @response `200` `AuthIdentifyVerifyCreateData` Default Response
|
|
497
|
+
*/
|
|
498
|
+
authIdentifyVerifyCreate: (data, params = {}) => this.request({
|
|
499
|
+
path: `/v1/auth/identify/verify`,
|
|
500
|
+
method: "POST",
|
|
501
|
+
body: data,
|
|
502
|
+
type: ContentType.Json,
|
|
503
|
+
format: "json",
|
|
504
|
+
...params,
|
|
505
|
+
}),
|
|
506
|
+
/**
|
|
507
|
+
* @description Create a new checkout
|
|
508
|
+
*
|
|
509
|
+
* @tags Checkouts
|
|
510
|
+
* @name CheckoutsCreate
|
|
511
|
+
* @request POST:/v1/checkouts/
|
|
512
|
+
* @response `201` `CheckoutsCreateData` Default Response
|
|
513
|
+
*/
|
|
514
|
+
checkoutsCreate: (data, params = {}) => this.request({
|
|
515
|
+
path: `/v1/checkouts/`,
|
|
516
|
+
method: "POST",
|
|
517
|
+
body: data,
|
|
518
|
+
type: ContentType.Json,
|
|
519
|
+
format: "json",
|
|
520
|
+
...params,
|
|
521
|
+
}),
|
|
522
|
+
/**
|
|
523
|
+
* @description Get a checkout by id
|
|
524
|
+
*
|
|
525
|
+
* @tags Checkouts
|
|
526
|
+
* @name CheckoutsDetail
|
|
527
|
+
* @request GET:/v1/checkouts/{id}
|
|
528
|
+
* @response `200` `CheckoutsDetailData` Default Response
|
|
529
|
+
*/
|
|
530
|
+
checkoutsDetail: (id, params = {}) => this.request({
|
|
531
|
+
path: `/v1/checkouts/${id}`,
|
|
532
|
+
method: "GET",
|
|
533
|
+
format: "json",
|
|
534
|
+
...params,
|
|
535
|
+
}),
|
|
536
|
+
/**
|
|
537
|
+
* @description Publish a checkout by id
|
|
538
|
+
*
|
|
539
|
+
* @tags Checkouts
|
|
540
|
+
* @name CheckoutsPublishCreate
|
|
541
|
+
* @request POST:/v1/checkouts/{id}/publish
|
|
542
|
+
* @response `200` `CheckoutsPublishCreateData` Default Response
|
|
543
|
+
*/
|
|
544
|
+
checkoutsPublishCreate: (id, params = {}) => this.request({
|
|
545
|
+
path: `/v1/checkouts/${id}/publish`,
|
|
546
|
+
method: "POST",
|
|
547
|
+
format: "json",
|
|
548
|
+
...params,
|
|
549
|
+
}),
|
|
550
|
+
/**
|
|
551
|
+
* @description Create a new merchant account
|
|
552
|
+
*
|
|
553
|
+
* @tags Merchant Accounts
|
|
554
|
+
* @name MerchantAccountsCreate
|
|
555
|
+
* @request POST:/v1/merchant-accounts/
|
|
556
|
+
* @response `201` `MerchantAccountsCreateData` Default Response
|
|
557
|
+
*/
|
|
558
|
+
merchantAccountsCreate: (data, params = {}) => this.request({
|
|
559
|
+
path: `/v1/merchant-accounts/`,
|
|
560
|
+
method: "POST",
|
|
561
|
+
body: data,
|
|
562
|
+
type: ContentType.Json,
|
|
563
|
+
format: "json",
|
|
564
|
+
...params,
|
|
565
|
+
}),
|
|
566
|
+
}
|
|
567
|
+
});
|
|
568
|
+
}
|
|
617
569
|
}
|
|
618
|
-
//# sourceMappingURL=generated.js.map
|
|
570
|
+
//# sourceMappingURL=generated.js.map
|