@0xsequence/api 0.0.0-20220513134147 → 0.0.0-20220519151110
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.
|
@@ -27,7 +27,7 @@ function _extends() {
|
|
|
27
27
|
}
|
|
28
28
|
|
|
29
29
|
/* eslint-disable */
|
|
30
|
-
// sequence-api v0.4.0
|
|
30
|
+
// sequence-api v0.4.0 7d1e87422f71f687846c08c90864e40a73c4cb43
|
|
31
31
|
// --
|
|
32
32
|
// This file has been generated by https://github.com/webrpc/webrpc using gen/typescript
|
|
33
33
|
// Do not edit by hand. Update your webrpc schema and re-generate.
|
|
@@ -36,7 +36,7 @@ const WebRPCVersion = "v1"; // Schema version of your RIDL schema
|
|
|
36
36
|
|
|
37
37
|
const WebRPCSchemaVersion = "v0.4.0"; // Schema hash generated from your RIDL schema
|
|
38
38
|
|
|
39
|
-
const WebRPCSchemaHash = "
|
|
39
|
+
const WebRPCSchemaHash = "7d1e87422f71f687846c08c90864e40a73c4cb43"; //
|
|
40
40
|
// Types
|
|
41
41
|
//
|
|
42
42
|
|
|
@@ -273,8 +273,8 @@ class API {
|
|
|
273
273
|
});
|
|
274
274
|
};
|
|
275
275
|
|
|
276
|
-
this.
|
|
277
|
-
return this.fetch(this.url('
|
|
276
|
+
this.getCoinPrices = (args, headers) => {
|
|
277
|
+
return this.fetch(this.url('GetCoinPrices'), createHTTPRequest(args, headers)).then(res => {
|
|
278
278
|
return buildResponse(res).then(_data => {
|
|
279
279
|
return {
|
|
280
280
|
tokenPrices: _data.tokenPrices
|
|
@@ -293,6 +293,57 @@ class API {
|
|
|
293
293
|
});
|
|
294
294
|
};
|
|
295
295
|
|
|
296
|
+
this.getExchangeRate = (args, headers) => {
|
|
297
|
+
return this.fetch(this.url('GetExchangeRate'), createHTTPRequest(args, headers)).then(res => {
|
|
298
|
+
return buildResponse(res).then(_data => {
|
|
299
|
+
return {
|
|
300
|
+
exchangeRate: _data.exchangeRate
|
|
301
|
+
};
|
|
302
|
+
});
|
|
303
|
+
});
|
|
304
|
+
};
|
|
305
|
+
|
|
306
|
+
this.listPayCardsOnFile = headers => {
|
|
307
|
+
return this.fetch(this.url('ListPayCardsOnFile'), createHTTPRequest({}, headers)).then(res => {
|
|
308
|
+
return buildResponse(res).then(_data => {
|
|
309
|
+
return {
|
|
310
|
+
payCards: _data.payCards
|
|
311
|
+
};
|
|
312
|
+
});
|
|
313
|
+
});
|
|
314
|
+
};
|
|
315
|
+
|
|
316
|
+
this.savePayCard = (args, headers) => {
|
|
317
|
+
return this.fetch(this.url('SavePayCard'), createHTTPRequest(args, headers)).then(res => {
|
|
318
|
+
return buildResponse(res).then(_data => {
|
|
319
|
+
return {
|
|
320
|
+
ok: _data.ok,
|
|
321
|
+
payCard: _data.payCard
|
|
322
|
+
};
|
|
323
|
+
});
|
|
324
|
+
});
|
|
325
|
+
};
|
|
326
|
+
|
|
327
|
+
this.deletePayCard = (args, headers) => {
|
|
328
|
+
return this.fetch(this.url('DeletePayCard'), createHTTPRequest(args, headers)).then(res => {
|
|
329
|
+
return buildResponse(res).then(_data => {
|
|
330
|
+
return {
|
|
331
|
+
ok: _data.ok
|
|
332
|
+
};
|
|
333
|
+
});
|
|
334
|
+
});
|
|
335
|
+
};
|
|
336
|
+
|
|
337
|
+
this.smartRampPurchase = (args, headers) => {
|
|
338
|
+
return this.fetch(this.url('SmartRampPurchase'), createHTTPRequest(args, headers)).then(res => {
|
|
339
|
+
return buildResponse(res).then(_data => {
|
|
340
|
+
return {
|
|
341
|
+
status: _data.status
|
|
342
|
+
};
|
|
343
|
+
});
|
|
344
|
+
});
|
|
345
|
+
};
|
|
346
|
+
|
|
296
347
|
this.getInviteInfo = headers => {
|
|
297
348
|
return this.fetch(this.url('GetInviteInfo'), createHTTPRequest({}, headers)).then(res => {
|
|
298
349
|
return buildResponse(res).then(_data => {
|
|
@@ -27,7 +27,7 @@ function _extends() {
|
|
|
27
27
|
}
|
|
28
28
|
|
|
29
29
|
/* eslint-disable */
|
|
30
|
-
// sequence-api v0.4.0
|
|
30
|
+
// sequence-api v0.4.0 7d1e87422f71f687846c08c90864e40a73c4cb43
|
|
31
31
|
// --
|
|
32
32
|
// This file has been generated by https://github.com/webrpc/webrpc using gen/typescript
|
|
33
33
|
// Do not edit by hand. Update your webrpc schema and re-generate.
|
|
@@ -36,7 +36,7 @@ const WebRPCVersion = "v1"; // Schema version of your RIDL schema
|
|
|
36
36
|
|
|
37
37
|
const WebRPCSchemaVersion = "v0.4.0"; // Schema hash generated from your RIDL schema
|
|
38
38
|
|
|
39
|
-
const WebRPCSchemaHash = "
|
|
39
|
+
const WebRPCSchemaHash = "7d1e87422f71f687846c08c90864e40a73c4cb43"; //
|
|
40
40
|
// Types
|
|
41
41
|
//
|
|
42
42
|
|
|
@@ -273,8 +273,8 @@ class API {
|
|
|
273
273
|
});
|
|
274
274
|
};
|
|
275
275
|
|
|
276
|
-
this.
|
|
277
|
-
return this.fetch(this.url('
|
|
276
|
+
this.getCoinPrices = (args, headers) => {
|
|
277
|
+
return this.fetch(this.url('GetCoinPrices'), createHTTPRequest(args, headers)).then(res => {
|
|
278
278
|
return buildResponse(res).then(_data => {
|
|
279
279
|
return {
|
|
280
280
|
tokenPrices: _data.tokenPrices
|
|
@@ -293,6 +293,57 @@ class API {
|
|
|
293
293
|
});
|
|
294
294
|
};
|
|
295
295
|
|
|
296
|
+
this.getExchangeRate = (args, headers) => {
|
|
297
|
+
return this.fetch(this.url('GetExchangeRate'), createHTTPRequest(args, headers)).then(res => {
|
|
298
|
+
return buildResponse(res).then(_data => {
|
|
299
|
+
return {
|
|
300
|
+
exchangeRate: _data.exchangeRate
|
|
301
|
+
};
|
|
302
|
+
});
|
|
303
|
+
});
|
|
304
|
+
};
|
|
305
|
+
|
|
306
|
+
this.listPayCardsOnFile = headers => {
|
|
307
|
+
return this.fetch(this.url('ListPayCardsOnFile'), createHTTPRequest({}, headers)).then(res => {
|
|
308
|
+
return buildResponse(res).then(_data => {
|
|
309
|
+
return {
|
|
310
|
+
payCards: _data.payCards
|
|
311
|
+
};
|
|
312
|
+
});
|
|
313
|
+
});
|
|
314
|
+
};
|
|
315
|
+
|
|
316
|
+
this.savePayCard = (args, headers) => {
|
|
317
|
+
return this.fetch(this.url('SavePayCard'), createHTTPRequest(args, headers)).then(res => {
|
|
318
|
+
return buildResponse(res).then(_data => {
|
|
319
|
+
return {
|
|
320
|
+
ok: _data.ok,
|
|
321
|
+
payCard: _data.payCard
|
|
322
|
+
};
|
|
323
|
+
});
|
|
324
|
+
});
|
|
325
|
+
};
|
|
326
|
+
|
|
327
|
+
this.deletePayCard = (args, headers) => {
|
|
328
|
+
return this.fetch(this.url('DeletePayCard'), createHTTPRequest(args, headers)).then(res => {
|
|
329
|
+
return buildResponse(res).then(_data => {
|
|
330
|
+
return {
|
|
331
|
+
ok: _data.ok
|
|
332
|
+
};
|
|
333
|
+
});
|
|
334
|
+
});
|
|
335
|
+
};
|
|
336
|
+
|
|
337
|
+
this.smartRampPurchase = (args, headers) => {
|
|
338
|
+
return this.fetch(this.url('SmartRampPurchase'), createHTTPRequest(args, headers)).then(res => {
|
|
339
|
+
return buildResponse(res).then(_data => {
|
|
340
|
+
return {
|
|
341
|
+
status: _data.status
|
|
342
|
+
};
|
|
343
|
+
});
|
|
344
|
+
});
|
|
345
|
+
};
|
|
346
|
+
|
|
296
347
|
this.getInviteInfo = headers => {
|
|
297
348
|
return this.fetch(this.url('GetInviteInfo'), createHTTPRequest({}, headers)).then(res => {
|
|
298
349
|
return buildResponse(res).then(_data => {
|
|
@@ -19,7 +19,7 @@ function _extends() {
|
|
|
19
19
|
}
|
|
20
20
|
|
|
21
21
|
/* eslint-disable */
|
|
22
|
-
// sequence-api v0.4.0
|
|
22
|
+
// sequence-api v0.4.0 7d1e87422f71f687846c08c90864e40a73c4cb43
|
|
23
23
|
// --
|
|
24
24
|
// This file has been generated by https://github.com/webrpc/webrpc using gen/typescript
|
|
25
25
|
// Do not edit by hand. Update your webrpc schema and re-generate.
|
|
@@ -28,7 +28,7 @@ const WebRPCVersion = "v1"; // Schema version of your RIDL schema
|
|
|
28
28
|
|
|
29
29
|
const WebRPCSchemaVersion = "v0.4.0"; // Schema hash generated from your RIDL schema
|
|
30
30
|
|
|
31
|
-
const WebRPCSchemaHash = "
|
|
31
|
+
const WebRPCSchemaHash = "7d1e87422f71f687846c08c90864e40a73c4cb43"; //
|
|
32
32
|
// Types
|
|
33
33
|
//
|
|
34
34
|
|
|
@@ -265,8 +265,8 @@ class API {
|
|
|
265
265
|
});
|
|
266
266
|
};
|
|
267
267
|
|
|
268
|
-
this.
|
|
269
|
-
return this.fetch(this.url('
|
|
268
|
+
this.getCoinPrices = (args, headers) => {
|
|
269
|
+
return this.fetch(this.url('GetCoinPrices'), createHTTPRequest(args, headers)).then(res => {
|
|
270
270
|
return buildResponse(res).then(_data => {
|
|
271
271
|
return {
|
|
272
272
|
tokenPrices: _data.tokenPrices
|
|
@@ -285,6 +285,57 @@ class API {
|
|
|
285
285
|
});
|
|
286
286
|
};
|
|
287
287
|
|
|
288
|
+
this.getExchangeRate = (args, headers) => {
|
|
289
|
+
return this.fetch(this.url('GetExchangeRate'), createHTTPRequest(args, headers)).then(res => {
|
|
290
|
+
return buildResponse(res).then(_data => {
|
|
291
|
+
return {
|
|
292
|
+
exchangeRate: _data.exchangeRate
|
|
293
|
+
};
|
|
294
|
+
});
|
|
295
|
+
});
|
|
296
|
+
};
|
|
297
|
+
|
|
298
|
+
this.listPayCardsOnFile = headers => {
|
|
299
|
+
return this.fetch(this.url('ListPayCardsOnFile'), createHTTPRequest({}, headers)).then(res => {
|
|
300
|
+
return buildResponse(res).then(_data => {
|
|
301
|
+
return {
|
|
302
|
+
payCards: _data.payCards
|
|
303
|
+
};
|
|
304
|
+
});
|
|
305
|
+
});
|
|
306
|
+
};
|
|
307
|
+
|
|
308
|
+
this.savePayCard = (args, headers) => {
|
|
309
|
+
return this.fetch(this.url('SavePayCard'), createHTTPRequest(args, headers)).then(res => {
|
|
310
|
+
return buildResponse(res).then(_data => {
|
|
311
|
+
return {
|
|
312
|
+
ok: _data.ok,
|
|
313
|
+
payCard: _data.payCard
|
|
314
|
+
};
|
|
315
|
+
});
|
|
316
|
+
});
|
|
317
|
+
};
|
|
318
|
+
|
|
319
|
+
this.deletePayCard = (args, headers) => {
|
|
320
|
+
return this.fetch(this.url('DeletePayCard'), createHTTPRequest(args, headers)).then(res => {
|
|
321
|
+
return buildResponse(res).then(_data => {
|
|
322
|
+
return {
|
|
323
|
+
ok: _data.ok
|
|
324
|
+
};
|
|
325
|
+
});
|
|
326
|
+
});
|
|
327
|
+
};
|
|
328
|
+
|
|
329
|
+
this.smartRampPurchase = (args, headers) => {
|
|
330
|
+
return this.fetch(this.url('SmartRampPurchase'), createHTTPRequest(args, headers)).then(res => {
|
|
331
|
+
return buildResponse(res).then(_data => {
|
|
332
|
+
return {
|
|
333
|
+
status: _data.status
|
|
334
|
+
};
|
|
335
|
+
});
|
|
336
|
+
});
|
|
337
|
+
};
|
|
338
|
+
|
|
288
339
|
this.getInviteInfo = headers => {
|
|
289
340
|
return this.fetch(this.url('GetInviteInfo'), createHTTPRequest({}, headers)).then(res => {
|
|
290
341
|
return buildResponse(res).then(_data => {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
export declare const WebRPCVersion = "v1";
|
|
2
2
|
export declare const WebRPCSchemaVersion = "v0.4.0";
|
|
3
|
-
export declare const WebRPCSchemaHash = "
|
|
3
|
+
export declare const WebRPCSchemaHash = "7d1e87422f71f687846c08c90864e40a73c4cb43";
|
|
4
4
|
export declare enum SortOrder {
|
|
5
5
|
DESC = "DESC",
|
|
6
6
|
ASC = "ASC"
|
|
@@ -78,9 +78,9 @@ export interface InviteInfo {
|
|
|
78
78
|
export interface ContractCall {
|
|
79
79
|
signature: string;
|
|
80
80
|
function: string;
|
|
81
|
-
args: Array<
|
|
81
|
+
args: Array<TupleComponent>;
|
|
82
82
|
}
|
|
83
|
-
export interface
|
|
83
|
+
export interface TupleComponent {
|
|
84
84
|
name?: string;
|
|
85
85
|
type: string;
|
|
86
86
|
value: any;
|
|
@@ -117,12 +117,39 @@ export interface Token {
|
|
|
117
117
|
contractAddress: string;
|
|
118
118
|
tokenId?: string;
|
|
119
119
|
}
|
|
120
|
+
export interface Price {
|
|
121
|
+
value: number;
|
|
122
|
+
currency: string;
|
|
123
|
+
}
|
|
120
124
|
export interface TokenPrice {
|
|
121
125
|
token: Token;
|
|
122
|
-
|
|
123
|
-
|
|
126
|
+
price?: Price;
|
|
127
|
+
price24hChange?: Price;
|
|
128
|
+
floorPrice: Price;
|
|
129
|
+
buyPrice: Price;
|
|
130
|
+
sellPrice: Price;
|
|
124
131
|
updatedAt: string;
|
|
125
132
|
}
|
|
133
|
+
export interface ExchangeRate {
|
|
134
|
+
name: string;
|
|
135
|
+
symbol: string;
|
|
136
|
+
value: number;
|
|
137
|
+
vsCurrency: string;
|
|
138
|
+
currencyType: string;
|
|
139
|
+
}
|
|
140
|
+
export interface PayCard {
|
|
141
|
+
id: number;
|
|
142
|
+
userAddress: string;
|
|
143
|
+
cardType: string;
|
|
144
|
+
cardHolder: string;
|
|
145
|
+
cardNumberLastFourDigits: string;
|
|
146
|
+
cardNumberToken: string;
|
|
147
|
+
cardCVCToken: string;
|
|
148
|
+
cardExpMonth: number;
|
|
149
|
+
cardExpYear: number;
|
|
150
|
+
updatedAt?: string;
|
|
151
|
+
createdAt?: string;
|
|
152
|
+
}
|
|
126
153
|
export interface API {
|
|
127
154
|
ping(headers?: object): Promise<PingReturn>;
|
|
128
155
|
version(headers?: object): Promise<VersionReturn>;
|
|
@@ -145,8 +172,13 @@ export interface API {
|
|
|
145
172
|
userStorageFetchAll(args: UserStorageFetchAllArgs, headers?: object): Promise<UserStorageFetchAllReturn>;
|
|
146
173
|
getMoonpayLink(args: GetMoonpayLinkArgs, headers?: object): Promise<GetMoonpayLinkReturn>;
|
|
147
174
|
isUsingGoogleMail(args: IsUsingGoogleMailArgs, headers?: object): Promise<IsUsingGoogleMailReturn>;
|
|
148
|
-
|
|
175
|
+
getCoinPrices(args: GetCoinPricesArgs, headers?: object): Promise<GetCoinPricesReturn>;
|
|
149
176
|
getCollectiblePrices(args: GetCollectiblePricesArgs, headers?: object): Promise<GetCollectiblePricesReturn>;
|
|
177
|
+
getExchangeRate(args: GetExchangeRateArgs, headers?: object): Promise<GetExchangeRateReturn>;
|
|
178
|
+
listPayCardsOnFile(headers?: object): Promise<ListPayCardsOnFileReturn>;
|
|
179
|
+
savePayCard(args: SavePayCardArgs, headers?: object): Promise<SavePayCardReturn>;
|
|
180
|
+
deletePayCard(args: DeletePayCardArgs, headers?: object): Promise<DeletePayCardReturn>;
|
|
181
|
+
smartRampPurchase(args: SmartRampPurchaseArgs, headers?: object): Promise<SmartRampPurchaseReturn>;
|
|
150
182
|
getInviteInfo(headers?: object): Promise<GetInviteInfoReturn>;
|
|
151
183
|
isValidAccessCode(args: IsValidAccessCodeArgs, headers?: object): Promise<IsValidAccessCodeReturn>;
|
|
152
184
|
internalClaimAccessCode(args: InternalClaimAccessCodeArgs, headers?: object): Promise<InternalClaimAccessCodeReturn>;
|
|
@@ -293,10 +325,10 @@ export interface IsUsingGoogleMailArgs {
|
|
|
293
325
|
export interface IsUsingGoogleMailReturn {
|
|
294
326
|
yes: boolean;
|
|
295
327
|
}
|
|
296
|
-
export interface
|
|
328
|
+
export interface GetCoinPricesArgs {
|
|
297
329
|
tokens: Array<Token>;
|
|
298
330
|
}
|
|
299
|
-
export interface
|
|
331
|
+
export interface GetCoinPricesReturn {
|
|
300
332
|
tokenPrices: Array<TokenPrice>;
|
|
301
333
|
}
|
|
302
334
|
export interface GetCollectiblePricesArgs {
|
|
@@ -305,6 +337,37 @@ export interface GetCollectiblePricesArgs {
|
|
|
305
337
|
export interface GetCollectiblePricesReturn {
|
|
306
338
|
tokenPrices: Array<TokenPrice>;
|
|
307
339
|
}
|
|
340
|
+
export interface GetExchangeRateArgs {
|
|
341
|
+
toCurrency: string;
|
|
342
|
+
}
|
|
343
|
+
export interface GetExchangeRateReturn {
|
|
344
|
+
exchangeRate: ExchangeRate;
|
|
345
|
+
}
|
|
346
|
+
export interface ListPayCardsOnFileArgs {
|
|
347
|
+
}
|
|
348
|
+
export interface ListPayCardsOnFileReturn {
|
|
349
|
+
payCards: Array<PayCard>;
|
|
350
|
+
}
|
|
351
|
+
export interface SavePayCardArgs {
|
|
352
|
+
payCard: PayCard;
|
|
353
|
+
}
|
|
354
|
+
export interface SavePayCardReturn {
|
|
355
|
+
ok: boolean;
|
|
356
|
+
payCard: PayCard;
|
|
357
|
+
}
|
|
358
|
+
export interface DeletePayCardArgs {
|
|
359
|
+
payCardId: number;
|
|
360
|
+
}
|
|
361
|
+
export interface DeletePayCardReturn {
|
|
362
|
+
ok: boolean;
|
|
363
|
+
}
|
|
364
|
+
export interface SmartRampPurchaseArgs {
|
|
365
|
+
payCardId: number;
|
|
366
|
+
payload: any;
|
|
367
|
+
}
|
|
368
|
+
export interface SmartRampPurchaseReturn {
|
|
369
|
+
status: boolean;
|
|
370
|
+
}
|
|
308
371
|
export interface GetInviteInfoArgs {
|
|
309
372
|
}
|
|
310
373
|
export interface GetInviteInfoReturn {
|
|
@@ -357,8 +420,13 @@ export declare class API implements API {
|
|
|
357
420
|
userStorageFetchAll: (args: UserStorageFetchAllArgs, headers?: object | undefined) => Promise<UserStorageFetchAllReturn>;
|
|
358
421
|
getMoonpayLink: (args: GetMoonpayLinkArgs, headers?: object | undefined) => Promise<GetMoonpayLinkReturn>;
|
|
359
422
|
isUsingGoogleMail: (args: IsUsingGoogleMailArgs, headers?: object | undefined) => Promise<IsUsingGoogleMailReturn>;
|
|
360
|
-
|
|
423
|
+
getCoinPrices: (args: GetCoinPricesArgs, headers?: object | undefined) => Promise<GetCoinPricesReturn>;
|
|
361
424
|
getCollectiblePrices: (args: GetCollectiblePricesArgs, headers?: object | undefined) => Promise<GetCollectiblePricesReturn>;
|
|
425
|
+
getExchangeRate: (args: GetExchangeRateArgs, headers?: object | undefined) => Promise<GetExchangeRateReturn>;
|
|
426
|
+
listPayCardsOnFile: (headers?: object | undefined) => Promise<ListPayCardsOnFileReturn>;
|
|
427
|
+
savePayCard: (args: SavePayCardArgs, headers?: object | undefined) => Promise<SavePayCardReturn>;
|
|
428
|
+
deletePayCard: (args: DeletePayCardArgs, headers?: object | undefined) => Promise<DeletePayCardReturn>;
|
|
429
|
+
smartRampPurchase: (args: SmartRampPurchaseArgs, headers?: object | undefined) => Promise<SmartRampPurchaseReturn>;
|
|
362
430
|
getInviteInfo: (headers?: object | undefined) => Promise<GetInviteInfoReturn>;
|
|
363
431
|
isValidAccessCode: (args: IsValidAccessCodeArgs, headers?: object | undefined) => Promise<IsValidAccessCodeReturn>;
|
|
364
432
|
internalClaimAccessCode: (args: InternalClaimAccessCodeArgs, headers?: object | undefined) => Promise<InternalClaimAccessCodeReturn>;
|
package/package.json
CHANGED
package/src/api.gen.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/* eslint-disable */
|
|
2
|
-
// sequence-api v0.4.0
|
|
2
|
+
// sequence-api v0.4.0 7d1e87422f71f687846c08c90864e40a73c4cb43
|
|
3
3
|
// --
|
|
4
4
|
// This file has been generated by https://github.com/webrpc/webrpc using gen/typescript
|
|
5
5
|
// Do not edit by hand. Update your webrpc schema and re-generate.
|
|
@@ -11,7 +11,7 @@ export const WebRPCVersion = "v1"
|
|
|
11
11
|
export const WebRPCSchemaVersion = "v0.4.0"
|
|
12
12
|
|
|
13
13
|
// Schema hash generated from your RIDL schema
|
|
14
|
-
export const WebRPCSchemaHash = "
|
|
14
|
+
export const WebRPCSchemaHash = "7d1e87422f71f687846c08c90864e40a73c4cb43"
|
|
15
15
|
|
|
16
16
|
|
|
17
17
|
//
|
|
@@ -110,10 +110,10 @@ export interface InviteInfo {
|
|
|
110
110
|
export interface ContractCall {
|
|
111
111
|
signature: string
|
|
112
112
|
function: string
|
|
113
|
-
args: Array<
|
|
113
|
+
args: Array<TupleComponent>
|
|
114
114
|
}
|
|
115
115
|
|
|
116
|
-
export interface
|
|
116
|
+
export interface TupleComponent {
|
|
117
117
|
name?: string
|
|
118
118
|
type: string
|
|
119
119
|
value: any
|
|
@@ -156,13 +156,43 @@ export interface Token {
|
|
|
156
156
|
tokenId?: string
|
|
157
157
|
}
|
|
158
158
|
|
|
159
|
+
export interface Price {
|
|
160
|
+
value: number
|
|
161
|
+
currency: string
|
|
162
|
+
}
|
|
163
|
+
|
|
159
164
|
export interface TokenPrice {
|
|
160
165
|
token: Token
|
|
161
|
-
|
|
162
|
-
|
|
166
|
+
price?: Price
|
|
167
|
+
price24hChange?: Price
|
|
168
|
+
floorPrice: Price
|
|
169
|
+
buyPrice: Price
|
|
170
|
+
sellPrice: Price
|
|
163
171
|
updatedAt: string
|
|
164
172
|
}
|
|
165
173
|
|
|
174
|
+
export interface ExchangeRate {
|
|
175
|
+
name: string
|
|
176
|
+
symbol: string
|
|
177
|
+
value: number
|
|
178
|
+
vsCurrency: string
|
|
179
|
+
currencyType: string
|
|
180
|
+
}
|
|
181
|
+
|
|
182
|
+
export interface PayCard {
|
|
183
|
+
id: number
|
|
184
|
+
userAddress: string
|
|
185
|
+
cardType: string
|
|
186
|
+
cardHolder: string
|
|
187
|
+
cardNumberLastFourDigits: string
|
|
188
|
+
cardNumberToken: string
|
|
189
|
+
cardCVCToken: string
|
|
190
|
+
cardExpMonth: number
|
|
191
|
+
cardExpYear: number
|
|
192
|
+
updatedAt?: string
|
|
193
|
+
createdAt?: string
|
|
194
|
+
}
|
|
195
|
+
|
|
166
196
|
export interface API {
|
|
167
197
|
ping(headers?: object): Promise<PingReturn>
|
|
168
198
|
version(headers?: object): Promise<VersionReturn>
|
|
@@ -185,8 +215,13 @@ export interface API {
|
|
|
185
215
|
userStorageFetchAll(args: UserStorageFetchAllArgs, headers?: object): Promise<UserStorageFetchAllReturn>
|
|
186
216
|
getMoonpayLink(args: GetMoonpayLinkArgs, headers?: object): Promise<GetMoonpayLinkReturn>
|
|
187
217
|
isUsingGoogleMail(args: IsUsingGoogleMailArgs, headers?: object): Promise<IsUsingGoogleMailReturn>
|
|
188
|
-
|
|
218
|
+
getCoinPrices(args: GetCoinPricesArgs, headers?: object): Promise<GetCoinPricesReturn>
|
|
189
219
|
getCollectiblePrices(args: GetCollectiblePricesArgs, headers?: object): Promise<GetCollectiblePricesReturn>
|
|
220
|
+
getExchangeRate(args: GetExchangeRateArgs, headers?: object): Promise<GetExchangeRateReturn>
|
|
221
|
+
listPayCardsOnFile(headers?: object): Promise<ListPayCardsOnFileReturn>
|
|
222
|
+
savePayCard(args: SavePayCardArgs, headers?: object): Promise<SavePayCardReturn>
|
|
223
|
+
deletePayCard(args: DeletePayCardArgs, headers?: object): Promise<DeletePayCardReturn>
|
|
224
|
+
smartRampPurchase(args: SmartRampPurchaseArgs, headers?: object): Promise<SmartRampPurchaseReturn>
|
|
190
225
|
getInviteInfo(headers?: object): Promise<GetInviteInfoReturn>
|
|
191
226
|
isValidAccessCode(args: IsValidAccessCodeArgs, headers?: object): Promise<IsValidAccessCodeReturn>
|
|
192
227
|
internalClaimAccessCode(args: InternalClaimAccessCodeArgs, headers?: object): Promise<InternalClaimAccessCodeReturn>
|
|
@@ -353,11 +388,11 @@ export interface IsUsingGoogleMailArgs {
|
|
|
353
388
|
export interface IsUsingGoogleMailReturn {
|
|
354
389
|
yes: boolean
|
|
355
390
|
}
|
|
356
|
-
export interface
|
|
391
|
+
export interface GetCoinPricesArgs {
|
|
357
392
|
tokens: Array<Token>
|
|
358
393
|
}
|
|
359
394
|
|
|
360
|
-
export interface
|
|
395
|
+
export interface GetCoinPricesReturn {
|
|
361
396
|
tokenPrices: Array<TokenPrice>
|
|
362
397
|
}
|
|
363
398
|
export interface GetCollectiblePricesArgs {
|
|
@@ -367,6 +402,42 @@ export interface GetCollectiblePricesArgs {
|
|
|
367
402
|
export interface GetCollectiblePricesReturn {
|
|
368
403
|
tokenPrices: Array<TokenPrice>
|
|
369
404
|
}
|
|
405
|
+
export interface GetExchangeRateArgs {
|
|
406
|
+
toCurrency: string
|
|
407
|
+
}
|
|
408
|
+
|
|
409
|
+
export interface GetExchangeRateReturn {
|
|
410
|
+
exchangeRate: ExchangeRate
|
|
411
|
+
}
|
|
412
|
+
export interface ListPayCardsOnFileArgs {
|
|
413
|
+
}
|
|
414
|
+
|
|
415
|
+
export interface ListPayCardsOnFileReturn {
|
|
416
|
+
payCards: Array<PayCard>
|
|
417
|
+
}
|
|
418
|
+
export interface SavePayCardArgs {
|
|
419
|
+
payCard: PayCard
|
|
420
|
+
}
|
|
421
|
+
|
|
422
|
+
export interface SavePayCardReturn {
|
|
423
|
+
ok: boolean
|
|
424
|
+
payCard: PayCard
|
|
425
|
+
}
|
|
426
|
+
export interface DeletePayCardArgs {
|
|
427
|
+
payCardId: number
|
|
428
|
+
}
|
|
429
|
+
|
|
430
|
+
export interface DeletePayCardReturn {
|
|
431
|
+
ok: boolean
|
|
432
|
+
}
|
|
433
|
+
export interface SmartRampPurchaseArgs {
|
|
434
|
+
payCardId: number
|
|
435
|
+
payload: any
|
|
436
|
+
}
|
|
437
|
+
|
|
438
|
+
export interface SmartRampPurchaseReturn {
|
|
439
|
+
status: boolean
|
|
440
|
+
}
|
|
370
441
|
export interface GetInviteInfoArgs {
|
|
371
442
|
}
|
|
372
443
|
|
|
@@ -679,9 +750,9 @@ export class API implements API {
|
|
|
679
750
|
})
|
|
680
751
|
}
|
|
681
752
|
|
|
682
|
-
|
|
753
|
+
getCoinPrices = (args: GetCoinPricesArgs, headers?: object): Promise<GetCoinPricesReturn> => {
|
|
683
754
|
return this.fetch(
|
|
684
|
-
this.url('
|
|
755
|
+
this.url('GetCoinPrices'),
|
|
685
756
|
createHTTPRequest(args, headers)).then((res) => {
|
|
686
757
|
return buildResponse(res).then(_data => {
|
|
687
758
|
return {
|
|
@@ -703,6 +774,68 @@ export class API implements API {
|
|
|
703
774
|
})
|
|
704
775
|
}
|
|
705
776
|
|
|
777
|
+
getExchangeRate = (args: GetExchangeRateArgs, headers?: object): Promise<GetExchangeRateReturn> => {
|
|
778
|
+
return this.fetch(
|
|
779
|
+
this.url('GetExchangeRate'),
|
|
780
|
+
createHTTPRequest(args, headers)).then((res) => {
|
|
781
|
+
return buildResponse(res).then(_data => {
|
|
782
|
+
return {
|
|
783
|
+
exchangeRate: <ExchangeRate>(_data.exchangeRate)
|
|
784
|
+
}
|
|
785
|
+
})
|
|
786
|
+
})
|
|
787
|
+
}
|
|
788
|
+
|
|
789
|
+
listPayCardsOnFile = (headers?: object): Promise<ListPayCardsOnFileReturn> => {
|
|
790
|
+
return this.fetch(
|
|
791
|
+
this.url('ListPayCardsOnFile'),
|
|
792
|
+
createHTTPRequest({}, headers)
|
|
793
|
+
).then((res) => {
|
|
794
|
+
return buildResponse(res).then(_data => {
|
|
795
|
+
return {
|
|
796
|
+
payCards: <Array<PayCard>>(_data.payCards)
|
|
797
|
+
}
|
|
798
|
+
})
|
|
799
|
+
})
|
|
800
|
+
}
|
|
801
|
+
|
|
802
|
+
savePayCard = (args: SavePayCardArgs, headers?: object): Promise<SavePayCardReturn> => {
|
|
803
|
+
return this.fetch(
|
|
804
|
+
this.url('SavePayCard'),
|
|
805
|
+
createHTTPRequest(args, headers)).then((res) => {
|
|
806
|
+
return buildResponse(res).then(_data => {
|
|
807
|
+
return {
|
|
808
|
+
ok: <boolean>(_data.ok),
|
|
809
|
+
payCard: <PayCard>(_data.payCard)
|
|
810
|
+
}
|
|
811
|
+
})
|
|
812
|
+
})
|
|
813
|
+
}
|
|
814
|
+
|
|
815
|
+
deletePayCard = (args: DeletePayCardArgs, headers?: object): Promise<DeletePayCardReturn> => {
|
|
816
|
+
return this.fetch(
|
|
817
|
+
this.url('DeletePayCard'),
|
|
818
|
+
createHTTPRequest(args, headers)).then((res) => {
|
|
819
|
+
return buildResponse(res).then(_data => {
|
|
820
|
+
return {
|
|
821
|
+
ok: <boolean>(_data.ok)
|
|
822
|
+
}
|
|
823
|
+
})
|
|
824
|
+
})
|
|
825
|
+
}
|
|
826
|
+
|
|
827
|
+
smartRampPurchase = (args: SmartRampPurchaseArgs, headers?: object): Promise<SmartRampPurchaseReturn> => {
|
|
828
|
+
return this.fetch(
|
|
829
|
+
this.url('SmartRampPurchase'),
|
|
830
|
+
createHTTPRequest(args, headers)).then((res) => {
|
|
831
|
+
return buildResponse(res).then(_data => {
|
|
832
|
+
return {
|
|
833
|
+
status: <boolean>(_data.status)
|
|
834
|
+
}
|
|
835
|
+
})
|
|
836
|
+
})
|
|
837
|
+
}
|
|
838
|
+
|
|
706
839
|
getInviteInfo = (headers?: object): Promise<GetInviteInfoReturn> => {
|
|
707
840
|
return this.fetch(
|
|
708
841
|
this.url('GetInviteInfo'),
|