@dynamic-labs/sdk-api 0.50.0 → 0.51.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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@dynamic-labs/sdk-api",
3
- "version": "0.50.0",
3
+ "version": "0.51.0",
4
4
  "author": "Dynamic Labs",
5
5
  "license": "Apache-2.0",
6
6
  "publishConfig": {
@@ -22,7 +22,7 @@ export interface FlowGasEstimate {
22
22
  */
23
23
  usdValue?: string;
24
24
  /**
25
- * Estimated gas cost in the source chain's native token
25
+ * Estimated gas cost in native-token base units (wei, lamports, etc.)
26
26
  * @type {string}
27
27
  * @memberof FlowGasEstimate
28
28
  */
@@ -3,6 +3,7 @@
3
3
  Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
5
  var runtime = require('../runtime.cjs');
6
+ var ChainEnum = require('./ChainEnum.cjs');
6
7
  var FlowFeeBreakdown = require('./FlowFeeBreakdown.cjs');
7
8
  var FlowTokenInfo = require('./FlowTokenInfo.cjs');
8
9
  var SwapSigningPayload = require('./SwapSigningPayload.cjs');
@@ -24,6 +25,12 @@ function FlowQuoteFromJSONTyped(json, ignoreDiscriminator) {
24
25
  'signingPayload': !runtime.exists(json, 'signingPayload') ? undefined : SwapSigningPayload.SwapSigningPayloadFromJSON(json['signingPayload']),
25
26
  'createdAt': (new Date(json['createdAt'])),
26
27
  'expiresAt': (new Date(json['expiresAt'])),
28
+ 'fromChainName': !runtime.exists(json, 'fromChainName') ? undefined : ChainEnum.ChainEnumFromJSON(json['fromChainName']),
29
+ 'fromChainId': !runtime.exists(json, 'fromChainId') ? undefined : json['fromChainId'],
30
+ 'fromToken': !runtime.exists(json, 'fromToken') ? undefined : json['fromToken'],
31
+ 'toChainName': !runtime.exists(json, 'toChainName') ? undefined : ChainEnum.ChainEnumFromJSON(json['toChainName']),
32
+ 'toChainId': !runtime.exists(json, 'toChainId') ? undefined : json['toChainId'],
33
+ 'toToken': !runtime.exists(json, 'toToken') ? undefined : json['toToken'],
27
34
  'fromTokenInfo': !runtime.exists(json, 'fromTokenInfo') ? undefined : FlowTokenInfo.FlowTokenInfoFromJSON(json['fromTokenInfo']),
28
35
  'toTokenInfo': !runtime.exists(json, 'toTokenInfo') ? undefined : FlowTokenInfo.FlowTokenInfoFromJSON(json['toTokenInfo']),
29
36
  };
@@ -44,6 +51,12 @@ function FlowQuoteToJSON(value) {
44
51
  'signingPayload': SwapSigningPayload.SwapSigningPayloadToJSON(value.signingPayload),
45
52
  'createdAt': (value.createdAt.toISOString()),
46
53
  'expiresAt': (value.expiresAt.toISOString()),
54
+ 'fromChainName': ChainEnum.ChainEnumToJSON(value.fromChainName),
55
+ 'fromChainId': value.fromChainId,
56
+ 'fromToken': value.fromToken,
57
+ 'toChainName': ChainEnum.ChainEnumToJSON(value.toChainName),
58
+ 'toChainId': value.toChainId,
59
+ 'toToken': value.toToken,
47
60
  'fromTokenInfo': FlowTokenInfo.FlowTokenInfoToJSON(value.fromTokenInfo),
48
61
  'toTokenInfo': FlowTokenInfo.FlowTokenInfoToJSON(value.toTokenInfo),
49
62
  };
@@ -9,6 +9,7 @@
9
9
  * https://openapi-generator.tech
10
10
  * Do not edit the class manually.
11
11
  */
12
+ import { ChainEnum } from './ChainEnum';
12
13
  import { FlowFeeBreakdown } from './FlowFeeBreakdown';
13
14
  import { FlowTokenInfo } from './FlowTokenInfo';
14
15
  import { SwapSigningPayload } from './SwapSigningPayload';
@@ -25,13 +26,13 @@ export interface FlowQuote {
25
26
  */
26
27
  version: number;
27
28
  /**
28
- * Amount being sent in the source token
29
+ * Amount being sent in source-token base units
29
30
  * @type {string}
30
31
  * @memberof FlowQuote
31
32
  */
32
33
  fromAmount: string;
33
34
  /**
34
- * Amount to be received in the destination token
35
+ * Amount to be received in destination-token base units
35
36
  * @type {string}
36
37
  * @memberof FlowQuote
37
38
  */
@@ -66,6 +67,42 @@ export interface FlowQuote {
66
67
  * @memberof FlowQuote
67
68
  */
68
69
  expiresAt: Date;
70
+ /**
71
+ *
72
+ * @type {ChainEnum}
73
+ * @memberof FlowQuote
74
+ */
75
+ fromChainName?: ChainEnum;
76
+ /**
77
+ *
78
+ * @type {string}
79
+ * @memberof FlowQuote
80
+ */
81
+ fromChainId?: string;
82
+ /**
83
+ *
84
+ * @type {string}
85
+ * @memberof FlowQuote
86
+ */
87
+ fromToken?: string;
88
+ /**
89
+ *
90
+ * @type {ChainEnum}
91
+ * @memberof FlowQuote
92
+ */
93
+ toChainName?: ChainEnum;
94
+ /**
95
+ *
96
+ * @type {string}
97
+ * @memberof FlowQuote
98
+ */
99
+ toChainId?: string;
100
+ /**
101
+ *
102
+ * @type {string}
103
+ * @memberof FlowQuote
104
+ */
105
+ toToken?: string;
69
106
  /**
70
107
  *
71
108
  * @type {FlowTokenInfo}
@@ -1,4 +1,5 @@
1
1
  import { exists } from '../runtime.js';
2
+ import { ChainEnumFromJSON, ChainEnumToJSON } from './ChainEnum.js';
2
3
  import { FlowFeeBreakdownFromJSON, FlowFeeBreakdownToJSON } from './FlowFeeBreakdown.js';
3
4
  import { FlowTokenInfoFromJSON, FlowTokenInfoToJSON } from './FlowTokenInfo.js';
4
5
  import { SwapSigningPayloadFromJSON, SwapSigningPayloadToJSON } from './SwapSigningPayload.js';
@@ -20,6 +21,12 @@ function FlowQuoteFromJSONTyped(json, ignoreDiscriminator) {
20
21
  'signingPayload': !exists(json, 'signingPayload') ? undefined : SwapSigningPayloadFromJSON(json['signingPayload']),
21
22
  'createdAt': (new Date(json['createdAt'])),
22
23
  'expiresAt': (new Date(json['expiresAt'])),
24
+ 'fromChainName': !exists(json, 'fromChainName') ? undefined : ChainEnumFromJSON(json['fromChainName']),
25
+ 'fromChainId': !exists(json, 'fromChainId') ? undefined : json['fromChainId'],
26
+ 'fromToken': !exists(json, 'fromToken') ? undefined : json['fromToken'],
27
+ 'toChainName': !exists(json, 'toChainName') ? undefined : ChainEnumFromJSON(json['toChainName']),
28
+ 'toChainId': !exists(json, 'toChainId') ? undefined : json['toChainId'],
29
+ 'toToken': !exists(json, 'toToken') ? undefined : json['toToken'],
23
30
  'fromTokenInfo': !exists(json, 'fromTokenInfo') ? undefined : FlowTokenInfoFromJSON(json['fromTokenInfo']),
24
31
  'toTokenInfo': !exists(json, 'toTokenInfo') ? undefined : FlowTokenInfoFromJSON(json['toTokenInfo']),
25
32
  };
@@ -40,6 +47,12 @@ function FlowQuoteToJSON(value) {
40
47
  'signingPayload': SwapSigningPayloadToJSON(value.signingPayload),
41
48
  'createdAt': (value.createdAt.toISOString()),
42
49
  'expiresAt': (value.expiresAt.toISOString()),
50
+ 'fromChainName': ChainEnumToJSON(value.fromChainName),
51
+ 'fromChainId': value.fromChainId,
52
+ 'fromToken': value.fromToken,
53
+ 'toChainName': ChainEnumToJSON(value.toChainName),
54
+ 'toChainId': value.toChainId,
55
+ 'toToken': value.toToken,
43
56
  'fromTokenInfo': FlowTokenInfoToJSON(value.fromTokenInfo),
44
57
  'toTokenInfo': FlowTokenInfoToJSON(value.toTokenInfo),
45
58
  };