snaptrade-typescript-sdk 9.0.172 → 9.0.174
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 +19 -18
- package/dist/api/options-api-generated.d.ts +12 -5
- package/dist/api/options-api-generated.js +12 -8
- package/dist/api/trading-api-generated.d.ts +4 -4
- package/dist/api/trading-api-generated.js +4 -4
- package/dist/browser.js +1 -1
- package/dist/configuration.js +1 -1
- package/dist/models/crypto-order-form.d.ts +4 -4
- package/dist/models/mleg-price-effect-strict.d.ts +1 -1
- package/dist/models/mleg-trade-form.d.ts +2 -2
- package/dist/models/option-impact.d.ts +13 -5
- package/dist/models/simple-order-form.d.ts +4 -4
- package/dist/operationParameterMap.js +4 -1
- package/package.json +1 -1
package/dist/configuration.js
CHANGED
|
@@ -32,7 +32,7 @@ class Configuration {
|
|
|
32
32
|
this.accessToken = param.accessToken;
|
|
33
33
|
this.basePath = param.basePath;
|
|
34
34
|
this.baseOptions = (_a = param.baseOptions) !== null && _a !== void 0 ? _a : {};
|
|
35
|
-
this.userAgent = param.userAgent === undefined ? "Konfig/9.0.
|
|
35
|
+
this.userAgent = param.userAgent === undefined ? "Konfig/9.0.174/typescript" : param.userAgent;
|
|
36
36
|
this.formDataCtor = param.formDataCtor;
|
|
37
37
|
}
|
|
38
38
|
/**
|
|
@@ -37,25 +37,25 @@ export interface CryptoOrderForm {
|
|
|
37
37
|
*/
|
|
38
38
|
'amount': string;
|
|
39
39
|
/**
|
|
40
|
-
* The limit price. Required if the order type is LIMIT
|
|
40
|
+
* The limit price. Required if the order type is `LIMIT`, `STOP_LOSS_LIMIT` or `TAKE_PROFIT_LIMIT`.
|
|
41
41
|
* @type {string}
|
|
42
42
|
* @memberof CryptoOrderForm
|
|
43
43
|
*/
|
|
44
44
|
'limit_price'?: string;
|
|
45
45
|
/**
|
|
46
|
-
* The stop price. Required if the order type is STOP_LOSS_MARKET
|
|
46
|
+
* The stop price. Required if the order type is `STOP_LOSS_MARKET`, `STOP_LOSS_LIMIT`, `TAKE_PROFIT_MARKET` or `TAKE_PROFIT_LIMIT`.
|
|
47
47
|
* @type {string}
|
|
48
48
|
* @memberof CryptoOrderForm
|
|
49
49
|
*/
|
|
50
50
|
'stop_price'?: string;
|
|
51
51
|
/**
|
|
52
|
-
* Valid and required only for order type LIMIT
|
|
52
|
+
* Valid and required only for order type `LIMIT`. If true orders that would be filled immediately are rejected to avoid incurring TAKER fees.
|
|
53
53
|
* @type {boolean}
|
|
54
54
|
* @memberof CryptoOrderForm
|
|
55
55
|
*/
|
|
56
56
|
'post_only'?: boolean;
|
|
57
57
|
/**
|
|
58
|
-
* The expiration date of the order. Required if the time_in_force is GTD
|
|
58
|
+
* The expiration date of the order. Required if the time_in_force is `GTD`.
|
|
59
59
|
* @type {string}
|
|
60
60
|
* @memberof CryptoOrderForm
|
|
61
61
|
*/
|
|
@@ -21,13 +21,13 @@ export interface MlegTradeForm {
|
|
|
21
21
|
*/
|
|
22
22
|
'time_in_force': TimeInForceStrict;
|
|
23
23
|
/**
|
|
24
|
-
* The limit price. Required if the order type is LIMIT
|
|
24
|
+
* The limit price. Required if the order type is `LIMIT`, `STOP_LOSS_LIMIT`.
|
|
25
25
|
* @type {string}
|
|
26
26
|
* @memberof MlegTradeForm
|
|
27
27
|
*/
|
|
28
28
|
'limit_price'?: string | null;
|
|
29
29
|
/**
|
|
30
|
-
* The stop price. Required if the order type is STOP_LOSS_MARKET
|
|
30
|
+
* The stop price. Required if the order type is `STOP_LOSS_MARKET`, `STOP_LOSS_LIMIT`.
|
|
31
31
|
* @type {string}
|
|
32
32
|
* @memberof MlegTradeForm
|
|
33
33
|
*/
|
|
@@ -1,20 +1,28 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Estimated
|
|
2
|
+
* Estimated cash change and fees for an option order before it is placed.
|
|
3
3
|
* @export
|
|
4
4
|
* @interface OptionImpact
|
|
5
5
|
*/
|
|
6
6
|
export interface OptionImpact {
|
|
7
7
|
[key: string]: any;
|
|
8
8
|
/**
|
|
9
|
-
* Estimated
|
|
9
|
+
* Estimated cash change for the order, before fees.
|
|
10
10
|
* @type {string}
|
|
11
11
|
* @memberof OptionImpact
|
|
12
12
|
*/
|
|
13
|
-
'
|
|
13
|
+
'estimated_cash_change'?: string;
|
|
14
14
|
/**
|
|
15
|
-
*
|
|
15
|
+
* Direction of the cash change. CREDIT means cash is received, DEBIT means cash is paid out, EVEN means no cash changes hands. UNKNOWN if the direction cannot be determined from the request.
|
|
16
16
|
* @type {string}
|
|
17
17
|
* @memberof OptionImpact
|
|
18
18
|
*/
|
|
19
|
-
'
|
|
19
|
+
'cash_change_direction'?: OptionImpactCashChangeDirectionEnum;
|
|
20
|
+
/**
|
|
21
|
+
* Estimated total transaction fees and commissions for the order.
|
|
22
|
+
* @type {string}
|
|
23
|
+
* @memberof OptionImpact
|
|
24
|
+
*/
|
|
25
|
+
'estimated_fee_total'?: string;
|
|
20
26
|
}
|
|
27
|
+
type OptionImpactCashChangeDirectionEnum = 'CREDIT' | 'DEBIT' | 'EVEN' | 'UNKNOWN';
|
|
28
|
+
export {};
|
|
@@ -38,25 +38,25 @@ export interface SimpleOrderForm {
|
|
|
38
38
|
*/
|
|
39
39
|
'amount': string;
|
|
40
40
|
/**
|
|
41
|
-
* The limit price. Required if the order type is LIMIT
|
|
41
|
+
* The limit price. Required if the order type is `LIMIT`, `STOP_LOSS_LIMIT` or `TAKE_PROFIT_LIMIT`.
|
|
42
42
|
* @type {string}
|
|
43
43
|
* @memberof SimpleOrderForm
|
|
44
44
|
*/
|
|
45
45
|
'limit_price'?: string;
|
|
46
46
|
/**
|
|
47
|
-
* The stop price. Required if the order type is STOP_LOSS_MARKET
|
|
47
|
+
* The stop price. Required if the order type is `STOP_LOSS_MARKET`, `STOP_LOSS_LIMIT`, `TAKE_PROFIT_MARKET` or `TAKE_PROFIT_LIMIT`.
|
|
48
48
|
* @type {string}
|
|
49
49
|
* @memberof SimpleOrderForm
|
|
50
50
|
*/
|
|
51
51
|
'stop_price'?: string;
|
|
52
52
|
/**
|
|
53
|
-
* Valid and required only for order type LIMIT
|
|
53
|
+
* Valid and required only for order type `LIMIT`. If true orders that would be filled immediately are rejected to avoid incurring TAKER fees.
|
|
54
54
|
* @type {boolean}
|
|
55
55
|
* @memberof SimpleOrderForm
|
|
56
56
|
*/
|
|
57
57
|
'post_only'?: boolean;
|
|
58
58
|
/**
|
|
59
|
-
* The expiration date of the order. Required if the time_in_force is GTD
|
|
59
|
+
* The expiration date of the order. Required if the time_in_force is `GTD`.
|
|
60
60
|
* @type {string}
|
|
61
61
|
* @memberof SimpleOrderForm
|
|
62
62
|
*/
|
|
@@ -411,7 +411,7 @@ exports.operationParameterMap = {
|
|
|
411
411
|
},
|
|
412
412
|
]
|
|
413
413
|
},
|
|
414
|
-
'/
|
|
414
|
+
'/accounts/{accountId}/quotes/options-GET': {
|
|
415
415
|
parameters: [
|
|
416
416
|
{
|
|
417
417
|
name: 'userId'
|
|
@@ -419,6 +419,9 @@ exports.operationParameterMap = {
|
|
|
419
419
|
{
|
|
420
420
|
name: 'userSecret'
|
|
421
421
|
},
|
|
422
|
+
{
|
|
423
|
+
name: 'accountId'
|
|
424
|
+
},
|
|
422
425
|
{
|
|
423
426
|
name: 'symbol'
|
|
424
427
|
},
|