snaptrade-typescript-sdk 8.8.0 → 8.9.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/README.md +1 -2
- package/dist/api.d.ts +0 -1
- package/dist/api.js +0 -1
- package/dist/client.d.ts +1 -2
- package/dist/client.js +0 -1
- package/dist/configuration.js +1 -1
- package/dist/models/index.d.ts +0 -1
- package/dist/models/index.js +0 -1
- package/package.json +1 -1
- package/dist/api/api-disclaimer-api-custom.d.ts +0 -3
- package/dist/api/api-disclaimer-api-custom.js +0 -27
- package/dist/api/api-disclaimer-api.d.ts +0 -97
- package/dist/api/api-disclaimer-api.js +0 -247
- package/dist/models/apidisclaimer-accept-request.d.ts +0 -24
- package/dist/models/apidisclaimer-accept-request.js +0 -15
package/README.md
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# snaptrade-typescript-sdk@8.
|
|
1
|
+
# snaptrade-typescript-sdk@8.9.0
|
|
2
2
|
|
|
3
3
|
Connect brokerage accounts to your app for live positions and trading
|
|
4
4
|
## Installing
|
|
@@ -109,7 +109,6 @@ Class | Method | HTTP request | Description
|
|
|
109
109
|
*AccountInformationApi* | [**getUserHoldings**](docs/AccountInformationApi.md#getUserHoldings) | **GET** /accounts/{accountId}/holdings | List balances, positions and orders for the specified account.
|
|
110
110
|
*AccountInformationApi* | [**listUserAccounts**](docs/AccountInformationApi.md#listUserAccounts) | **GET** /accounts | List all investment accounts for the user
|
|
111
111
|
*AccountInformationApi* | [**updateUserAccount**](docs/AccountInformationApi.md#updateUserAccount) | **PUT** /accounts/{accountId} | Update details of an investment account
|
|
112
|
-
*ApiDisclaimerApi* | [**accept**](docs/ApiDisclaimerApi.md#accept) | **POST** /snapTrade/acceptDisclaimer | Accept or Reject SnapTrade disclaimer agreement
|
|
113
112
|
*ApiStatusApi* | [**check**](docs/ApiStatusApi.md#check) | **GET** / | Get API Status
|
|
114
113
|
*AuthenticationApi* | [**deleteSnapTradeUser**](docs/AuthenticationApi.md#deleteSnapTradeUser) | **DELETE** /snapTrade/deleteUser | Delete user from SnapTrade, disabling all brokerage authorizations and permanently deleting all data associated with the user
|
|
115
114
|
*AuthenticationApi* | [**getUserJWT**](docs/AuthenticationApi.md#getUserJWT) | **GET** /snapTrade/encryptedJWT | Obtains an encrypted JWT tokens that should be decrypted on a user\'s local device
|
package/dist/api.d.ts
CHANGED
|
@@ -10,7 +10,6 @@
|
|
|
10
10
|
* Do not edit the class manually.
|
|
11
11
|
*/
|
|
12
12
|
export * from './api/account-information-api';
|
|
13
|
-
export * from './api/api-disclaimer-api';
|
|
14
13
|
export * from './api/api-status-api';
|
|
15
14
|
export * from './api/authentication-api';
|
|
16
15
|
export * from './api/connections-api';
|
package/dist/api.js
CHANGED
|
@@ -28,7 +28,6 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
28
28
|
};
|
|
29
29
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
30
30
|
__exportStar(require("./api/account-information-api"), exports);
|
|
31
|
-
__exportStar(require("./api/api-disclaimer-api"), exports);
|
|
32
31
|
__exportStar(require("./api/api-status-api"), exports);
|
|
33
32
|
__exportStar(require("./api/authentication-api"), exports);
|
|
34
33
|
__exportStar(require("./api/connections-api"), exports);
|
package/dist/client.d.ts
CHANGED
|
@@ -9,12 +9,11 @@
|
|
|
9
9
|
* https://konfigthis.com
|
|
10
10
|
* Do not edit the class manually.
|
|
11
11
|
*/
|
|
12
|
-
import { AccountInformationApi,
|
|
12
|
+
import { AccountInformationApi, ApiStatusApi, AuthenticationApi, ConnectionsApi, ErrorLogsApi, OptionsApi, PortfolioManagementApi, ReferenceDataApi, TradingApi, TransactionsAndReportingApi } from "./api";
|
|
13
13
|
import { ConfigurationParameters } from "./configuration";
|
|
14
14
|
import { SnaptradeCustom } from "./client-custom";
|
|
15
15
|
export declare class Snaptrade extends SnaptradeCustom {
|
|
16
16
|
readonly accountInformation: AccountInformationApi;
|
|
17
|
-
readonly apiDisclaimer: ApiDisclaimerApi;
|
|
18
17
|
readonly apiStatus: ApiStatusApi;
|
|
19
18
|
readonly authentication: AuthenticationApi;
|
|
20
19
|
readonly connections: ConnectionsApi;
|
package/dist/client.js
CHANGED
|
@@ -36,7 +36,6 @@ var Snaptrade = /** @class */ (function (_super) {
|
|
|
36
36
|
var _this = _super.call(this, configurationParameters) || this;
|
|
37
37
|
var configuration = new configuration_1.Configuration(configurationParameters);
|
|
38
38
|
_this.accountInformation = new api_1.AccountInformationApi(configuration);
|
|
39
|
-
_this.apiDisclaimer = new api_1.ApiDisclaimerApi(configuration);
|
|
40
39
|
_this.apiStatus = new api_1.ApiStatusApi(configuration);
|
|
41
40
|
_this.authentication = new api_1.AuthenticationApi(configuration);
|
|
42
41
|
_this.connections = new api_1.ConnectionsApi(configuration);
|
package/dist/configuration.js
CHANGED
|
@@ -34,7 +34,7 @@ var Configuration = /** @class */ (function () {
|
|
|
34
34
|
this.accessToken = param.accessToken;
|
|
35
35
|
this.basePath = param.basePath;
|
|
36
36
|
this.baseOptions = (_a = param.baseOptions) !== null && _a !== void 0 ? _a : {};
|
|
37
|
-
this.userAgent = param.userAgent === undefined ? "Konfig/8.
|
|
37
|
+
this.userAgent = param.userAgent === undefined ? "Konfig/8.9.0/typescript" : param.userAgent;
|
|
38
38
|
this.formDataCtor = param.formDataCtor;
|
|
39
39
|
}
|
|
40
40
|
/**
|
package/dist/models/index.d.ts
CHANGED
package/dist/models/index.js
CHANGED
|
@@ -14,7 +14,6 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
14
14
|
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
15
|
};
|
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
-
__exportStar(require("./apidisclaimer-accept-request"), exports);
|
|
18
17
|
__exportStar(require("./account"), exports);
|
|
19
18
|
__exportStar(require("./account-holdings"), exports);
|
|
20
19
|
__exportStar(require("./account-holdings-account"), exports);
|
package/package.json
CHANGED
|
@@ -1,27 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __extends = (this && this.__extends) || (function () {
|
|
3
|
-
var extendStatics = function (d, b) {
|
|
4
|
-
extendStatics = Object.setPrototypeOf ||
|
|
5
|
-
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
6
|
-
function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
|
|
7
|
-
return extendStatics(d, b);
|
|
8
|
-
};
|
|
9
|
-
return function (d, b) {
|
|
10
|
-
if (typeof b !== "function" && b !== null)
|
|
11
|
-
throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
|
|
12
|
-
extendStatics(d, b);
|
|
13
|
-
function __() { this.constructor = d; }
|
|
14
|
-
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
|
15
|
-
};
|
|
16
|
-
})();
|
|
17
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18
|
-
exports.ApiDisclaimerApiCustom = void 0;
|
|
19
|
-
var base_1 = require("../base");
|
|
20
|
-
var ApiDisclaimerApiCustom = /** @class */ (function (_super) {
|
|
21
|
-
__extends(ApiDisclaimerApiCustom, _super);
|
|
22
|
-
function ApiDisclaimerApiCustom() {
|
|
23
|
-
return _super !== null && _super.apply(this, arguments) || this;
|
|
24
|
-
}
|
|
25
|
-
return ApiDisclaimerApiCustom;
|
|
26
|
-
}(base_1.BaseAPI));
|
|
27
|
-
exports.ApiDisclaimerApiCustom = ApiDisclaimerApiCustom;
|
|
@@ -1,97 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* SnapTrade
|
|
3
|
-
* Connect brokerage accounts to your app for live positions and trading
|
|
4
|
-
*
|
|
5
|
-
* The version of the OpenAPI document: 1.0.0
|
|
6
|
-
* Contact: api@snaptrade.com
|
|
7
|
-
*
|
|
8
|
-
* NOTE: This file is auto generated by Konfig (https://konfigthis.com).
|
|
9
|
-
* https://konfigthis.com
|
|
10
|
-
* Do not edit the class manually.
|
|
11
|
-
*/
|
|
12
|
-
import { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
|
|
13
|
-
import { Configuration } from '../configuration';
|
|
14
|
-
import { RequestArgs } from '../base';
|
|
15
|
-
import { APIDisclaimerAcceptRequest } from '../models';
|
|
16
|
-
import { SnapTradeAPIDisclaimerAcceptStatus } from '../models';
|
|
17
|
-
import { ApiDisclaimerApiCustom } from "./api-disclaimer-api-custom";
|
|
18
|
-
/**
|
|
19
|
-
* ApiDisclaimerApi - axios parameter creator
|
|
20
|
-
* @export
|
|
21
|
-
*/
|
|
22
|
-
export declare const ApiDisclaimerApiAxiosParamCreator: (configuration?: Configuration) => {
|
|
23
|
-
/**
|
|
24
|
-
*
|
|
25
|
-
* @summary Accept or Reject SnapTrade disclaimer agreement
|
|
26
|
-
* @param {string} userId
|
|
27
|
-
* @param {string} userSecret
|
|
28
|
-
* @param {APIDisclaimerAcceptRequest} aPIDisclaimerAcceptRequest
|
|
29
|
-
* @param {*} [options] Override http request option.
|
|
30
|
-
* @throws {RequiredError}
|
|
31
|
-
*/
|
|
32
|
-
accept: (userId: string, userSecret: string, aPIDisclaimerAcceptRequest: APIDisclaimerAcceptRequest, options?: AxiosRequestConfig) => Promise<RequestArgs>;
|
|
33
|
-
};
|
|
34
|
-
/**
|
|
35
|
-
* ApiDisclaimerApi - functional programming interface
|
|
36
|
-
* @export
|
|
37
|
-
*/
|
|
38
|
-
export declare const ApiDisclaimerApiFp: (configuration?: Configuration) => {
|
|
39
|
-
/**
|
|
40
|
-
*
|
|
41
|
-
* @summary Accept or Reject SnapTrade disclaimer agreement
|
|
42
|
-
* @param {ApiDisclaimerApiAcceptRequest} requestParameters Request parameters.
|
|
43
|
-
* @param {*} [options] Override http request option.
|
|
44
|
-
* @throws {RequiredError}
|
|
45
|
-
*/
|
|
46
|
-
accept(requestParameters: ApiDisclaimerApiAcceptRequest, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<SnapTradeAPIDisclaimerAcceptStatus>>;
|
|
47
|
-
};
|
|
48
|
-
/**
|
|
49
|
-
* ApiDisclaimerApi - factory interface
|
|
50
|
-
* @export
|
|
51
|
-
*/
|
|
52
|
-
export declare const ApiDisclaimerApiFactory: (configuration?: Configuration, basePath?: string, axios?: AxiosInstance) => {
|
|
53
|
-
/**
|
|
54
|
-
*
|
|
55
|
-
* @summary Accept or Reject SnapTrade disclaimer agreement
|
|
56
|
-
* @param {ApiDisclaimerApiAcceptRequest} requestParameters Request parameters.
|
|
57
|
-
* @param {*} [options] Override http request option.
|
|
58
|
-
* @throws {RequiredError}
|
|
59
|
-
*/
|
|
60
|
-
accept(requestParameters: ApiDisclaimerApiAcceptRequest, options?: AxiosRequestConfig): AxiosPromise<SnapTradeAPIDisclaimerAcceptStatus>;
|
|
61
|
-
};
|
|
62
|
-
/**
|
|
63
|
-
* Request parameters for accept operation in ApiDisclaimerApi.
|
|
64
|
-
* @export
|
|
65
|
-
* @interface ApiDisclaimerApiAcceptRequest
|
|
66
|
-
*/
|
|
67
|
-
export type ApiDisclaimerApiAcceptRequest = {
|
|
68
|
-
/**
|
|
69
|
-
*
|
|
70
|
-
* @type {string}
|
|
71
|
-
* @memberof ApiDisclaimerApiAccept
|
|
72
|
-
*/
|
|
73
|
-
readonly userId: string;
|
|
74
|
-
/**
|
|
75
|
-
*
|
|
76
|
-
* @type {string}
|
|
77
|
-
* @memberof ApiDisclaimerApiAccept
|
|
78
|
-
*/
|
|
79
|
-
readonly userSecret: string;
|
|
80
|
-
} & APIDisclaimerAcceptRequest;
|
|
81
|
-
/**
|
|
82
|
-
* ApiDisclaimerApi - object-oriented interface
|
|
83
|
-
* @export
|
|
84
|
-
* @class ApiDisclaimerApi
|
|
85
|
-
* @extends {BaseAPI}
|
|
86
|
-
*/
|
|
87
|
-
export declare class ApiDisclaimerApi extends ApiDisclaimerApiCustom {
|
|
88
|
-
/**
|
|
89
|
-
*
|
|
90
|
-
* @summary Accept or Reject SnapTrade disclaimer agreement
|
|
91
|
-
* @param {ApiDisclaimerApiAcceptRequest} requestParameters Request parameters.
|
|
92
|
-
* @param {*} [options] Override http request option.
|
|
93
|
-
* @throws {RequiredError}
|
|
94
|
-
* @memberof ApiDisclaimerApi
|
|
95
|
-
*/
|
|
96
|
-
accept(requestParameters: ApiDisclaimerApiAcceptRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<SnapTradeAPIDisclaimerAcceptStatus, any>>;
|
|
97
|
-
}
|
|
@@ -1,247 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
/* tslint:disable */
|
|
3
|
-
/* eslint-disable */
|
|
4
|
-
/**
|
|
5
|
-
* SnapTrade
|
|
6
|
-
* Connect brokerage accounts to your app for live positions and trading
|
|
7
|
-
*
|
|
8
|
-
* The version of the OpenAPI document: 1.0.0
|
|
9
|
-
* Contact: api@snaptrade.com
|
|
10
|
-
*
|
|
11
|
-
* NOTE: This file is auto generated by Konfig (https://konfigthis.com).
|
|
12
|
-
* https://konfigthis.com
|
|
13
|
-
* Do not edit the class manually.
|
|
14
|
-
*/
|
|
15
|
-
var __extends = (this && this.__extends) || (function () {
|
|
16
|
-
var extendStatics = function (d, b) {
|
|
17
|
-
extendStatics = Object.setPrototypeOf ||
|
|
18
|
-
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
19
|
-
function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
|
|
20
|
-
return extendStatics(d, b);
|
|
21
|
-
};
|
|
22
|
-
return function (d, b) {
|
|
23
|
-
if (typeof b !== "function" && b !== null)
|
|
24
|
-
throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
|
|
25
|
-
extendStatics(d, b);
|
|
26
|
-
function __() { this.constructor = d; }
|
|
27
|
-
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
|
28
|
-
};
|
|
29
|
-
})();
|
|
30
|
-
var __assign = (this && this.__assign) || function () {
|
|
31
|
-
__assign = Object.assign || function(t) {
|
|
32
|
-
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
33
|
-
s = arguments[i];
|
|
34
|
-
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
|
35
|
-
t[p] = s[p];
|
|
36
|
-
}
|
|
37
|
-
return t;
|
|
38
|
-
};
|
|
39
|
-
return __assign.apply(this, arguments);
|
|
40
|
-
};
|
|
41
|
-
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
42
|
-
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
43
|
-
return new (P || (P = Promise))(function (resolve, reject) {
|
|
44
|
-
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
45
|
-
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
46
|
-
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
47
|
-
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
48
|
-
});
|
|
49
|
-
};
|
|
50
|
-
var __generator = (this && this.__generator) || function (thisArg, body) {
|
|
51
|
-
var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;
|
|
52
|
-
return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
|
|
53
|
-
function verb(n) { return function (v) { return step([n, v]); }; }
|
|
54
|
-
function step(op) {
|
|
55
|
-
if (f) throw new TypeError("Generator is already executing.");
|
|
56
|
-
while (g && (g = 0, op[0] && (_ = 0)), _) try {
|
|
57
|
-
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
|
|
58
|
-
if (y = 0, t) op = [op[0] & 2, t.value];
|
|
59
|
-
switch (op[0]) {
|
|
60
|
-
case 0: case 1: t = op; break;
|
|
61
|
-
case 4: _.label++; return { value: op[1], done: false };
|
|
62
|
-
case 5: _.label++; y = op[1]; op = [0]; continue;
|
|
63
|
-
case 7: op = _.ops.pop(); _.trys.pop(); continue;
|
|
64
|
-
default:
|
|
65
|
-
if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }
|
|
66
|
-
if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }
|
|
67
|
-
if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }
|
|
68
|
-
if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }
|
|
69
|
-
if (t[2]) _.ops.pop();
|
|
70
|
-
_.trys.pop(); continue;
|
|
71
|
-
}
|
|
72
|
-
op = body.call(thisArg, _);
|
|
73
|
-
} catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }
|
|
74
|
-
if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
|
|
75
|
-
}
|
|
76
|
-
};
|
|
77
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
78
|
-
exports.ApiDisclaimerApi = exports.ApiDisclaimerApiFactory = exports.ApiDisclaimerApiFp = exports.ApiDisclaimerApiAxiosParamCreator = void 0;
|
|
79
|
-
var axios_1 = require("axios");
|
|
80
|
-
// Some imports not used depending on template conditions
|
|
81
|
-
// @ts-ignore
|
|
82
|
-
var common_1 = require("../common");
|
|
83
|
-
// @ts-ignore
|
|
84
|
-
var base_1 = require("../base");
|
|
85
|
-
var requestBeforeHook_1 = require("../requestBeforeHook");
|
|
86
|
-
var api_disclaimer_api_custom_1 = require("./api-disclaimer-api-custom");
|
|
87
|
-
/**
|
|
88
|
-
* ApiDisclaimerApi - axios parameter creator
|
|
89
|
-
* @export
|
|
90
|
-
*/
|
|
91
|
-
var ApiDisclaimerApiAxiosParamCreator = function (configuration) {
|
|
92
|
-
var _this = this;
|
|
93
|
-
return {
|
|
94
|
-
/**
|
|
95
|
-
*
|
|
96
|
-
* @summary Accept or Reject SnapTrade disclaimer agreement
|
|
97
|
-
* @param {string} userId
|
|
98
|
-
* @param {string} userSecret
|
|
99
|
-
* @param {APIDisclaimerAcceptRequest} aPIDisclaimerAcceptRequest
|
|
100
|
-
* @param {*} [options] Override http request option.
|
|
101
|
-
* @throws {RequiredError}
|
|
102
|
-
*/
|
|
103
|
-
accept: function (userId, userSecret, aPIDisclaimerAcceptRequest, options) {
|
|
104
|
-
if (options === void 0) { options = {}; }
|
|
105
|
-
return __awaiter(_this, void 0, void 0, function () {
|
|
106
|
-
var localVarPath, localVarUrlObj, baseOptions, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
|
|
107
|
-
return __generator(this, function (_a) {
|
|
108
|
-
switch (_a.label) {
|
|
109
|
-
case 0:
|
|
110
|
-
// verify required parameter 'userId' is not null or undefined
|
|
111
|
-
(0, common_1.assertParamExists)('accept', 'userId', userId);
|
|
112
|
-
// verify required parameter 'userSecret' is not null or undefined
|
|
113
|
-
(0, common_1.assertParamExists)('accept', 'userSecret', userSecret);
|
|
114
|
-
// verify required parameter 'aPIDisclaimerAcceptRequest' is not null or undefined
|
|
115
|
-
(0, common_1.assertParamExists)('accept', 'aPIDisclaimerAcceptRequest', aPIDisclaimerAcceptRequest);
|
|
116
|
-
localVarPath = "/snapTrade/acceptDisclaimer";
|
|
117
|
-
localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
|
|
118
|
-
if (configuration) {
|
|
119
|
-
baseOptions = configuration.baseOptions;
|
|
120
|
-
}
|
|
121
|
-
localVarRequestOptions = __assign(__assign({ method: 'POST' }, baseOptions), options);
|
|
122
|
-
localVarHeaderParameter = configuration ? { "User-Agent": configuration.userAgent } : {};
|
|
123
|
-
localVarQueryParameter = {};
|
|
124
|
-
// authentication PartnerClientId required
|
|
125
|
-
return [4 /*yield*/, (0, common_1.setApiKeyToObject)({ object: localVarQueryParameter, keyParamName: "clientId", configuration: configuration })
|
|
126
|
-
// authentication PartnerSignature required
|
|
127
|
-
];
|
|
128
|
-
case 1:
|
|
129
|
-
// authentication PartnerClientId required
|
|
130
|
-
_a.sent();
|
|
131
|
-
// authentication PartnerSignature required
|
|
132
|
-
return [4 /*yield*/, (0, common_1.setApiKeyToObject)({ object: localVarHeaderParameter, keyParamName: "Signature", configuration: configuration })
|
|
133
|
-
// authentication PartnerTimestamp required
|
|
134
|
-
];
|
|
135
|
-
case 2:
|
|
136
|
-
// authentication PartnerSignature required
|
|
137
|
-
_a.sent();
|
|
138
|
-
// authentication PartnerTimestamp required
|
|
139
|
-
return [4 /*yield*/, (0, common_1.setApiKeyToObject)({ object: localVarQueryParameter, keyParamName: "timestamp", configuration: configuration })];
|
|
140
|
-
case 3:
|
|
141
|
-
// authentication PartnerTimestamp required
|
|
142
|
-
_a.sent();
|
|
143
|
-
if (userId !== undefined) {
|
|
144
|
-
localVarQueryParameter['userId'] = userId;
|
|
145
|
-
}
|
|
146
|
-
if (userSecret !== undefined) {
|
|
147
|
-
localVarQueryParameter['userSecret'] = userSecret;
|
|
148
|
-
}
|
|
149
|
-
localVarHeaderParameter['Content-Type'] = 'application/json';
|
|
150
|
-
headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
151
|
-
localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
152
|
-
(0, requestBeforeHook_1.requestBeforeHook)({
|
|
153
|
-
requestBody: aPIDisclaimerAcceptRequest,
|
|
154
|
-
queryParameters: localVarQueryParameter,
|
|
155
|
-
requestConfig: localVarRequestOptions,
|
|
156
|
-
path: localVarPath,
|
|
157
|
-
configuration: configuration
|
|
158
|
-
});
|
|
159
|
-
localVarRequestOptions.data = (0, common_1.serializeDataIfNeeded)(aPIDisclaimerAcceptRequest, localVarRequestOptions, configuration);
|
|
160
|
-
(0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
|
|
161
|
-
return [2 /*return*/, {
|
|
162
|
-
url: (0, common_1.toPathString)(localVarUrlObj),
|
|
163
|
-
options: localVarRequestOptions,
|
|
164
|
-
}];
|
|
165
|
-
}
|
|
166
|
-
});
|
|
167
|
-
});
|
|
168
|
-
},
|
|
169
|
-
};
|
|
170
|
-
};
|
|
171
|
-
exports.ApiDisclaimerApiAxiosParamCreator = ApiDisclaimerApiAxiosParamCreator;
|
|
172
|
-
/**
|
|
173
|
-
* ApiDisclaimerApi - functional programming interface
|
|
174
|
-
* @export
|
|
175
|
-
*/
|
|
176
|
-
var ApiDisclaimerApiFp = function (configuration) {
|
|
177
|
-
var localVarAxiosParamCreator = (0, exports.ApiDisclaimerApiAxiosParamCreator)(configuration);
|
|
178
|
-
return {
|
|
179
|
-
/**
|
|
180
|
-
*
|
|
181
|
-
* @summary Accept or Reject SnapTrade disclaimer agreement
|
|
182
|
-
* @param {ApiDisclaimerApiAcceptRequest} requestParameters Request parameters.
|
|
183
|
-
* @param {*} [options] Override http request option.
|
|
184
|
-
* @throws {RequiredError}
|
|
185
|
-
*/
|
|
186
|
-
accept: function (requestParameters, options) {
|
|
187
|
-
return __awaiter(this, void 0, void 0, function () {
|
|
188
|
-
var localVarAxiosArgs;
|
|
189
|
-
return __generator(this, function (_a) {
|
|
190
|
-
switch (_a.label) {
|
|
191
|
-
case 0: return [4 /*yield*/, localVarAxiosParamCreator.accept(requestParameters.userId, requestParameters.userSecret, requestParameters, options)];
|
|
192
|
-
case 1:
|
|
193
|
-
localVarAxiosArgs = _a.sent();
|
|
194
|
-
return [2 /*return*/, (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
|
|
195
|
-
}
|
|
196
|
-
});
|
|
197
|
-
});
|
|
198
|
-
},
|
|
199
|
-
};
|
|
200
|
-
};
|
|
201
|
-
exports.ApiDisclaimerApiFp = ApiDisclaimerApiFp;
|
|
202
|
-
/**
|
|
203
|
-
* ApiDisclaimerApi - factory interface
|
|
204
|
-
* @export
|
|
205
|
-
*/
|
|
206
|
-
var ApiDisclaimerApiFactory = function (configuration, basePath, axios) {
|
|
207
|
-
var localVarFp = (0, exports.ApiDisclaimerApiFp)(configuration);
|
|
208
|
-
return {
|
|
209
|
-
/**
|
|
210
|
-
*
|
|
211
|
-
* @summary Accept or Reject SnapTrade disclaimer agreement
|
|
212
|
-
* @param {ApiDisclaimerApiAcceptRequest} requestParameters Request parameters.
|
|
213
|
-
* @param {*} [options] Override http request option.
|
|
214
|
-
* @throws {RequiredError}
|
|
215
|
-
*/
|
|
216
|
-
accept: function (requestParameters, options) {
|
|
217
|
-
return localVarFp.accept(requestParameters, options).then(function (request) { return request(axios, basePath); });
|
|
218
|
-
},
|
|
219
|
-
};
|
|
220
|
-
};
|
|
221
|
-
exports.ApiDisclaimerApiFactory = ApiDisclaimerApiFactory;
|
|
222
|
-
/**
|
|
223
|
-
* ApiDisclaimerApi - object-oriented interface
|
|
224
|
-
* @export
|
|
225
|
-
* @class ApiDisclaimerApi
|
|
226
|
-
* @extends {BaseAPI}
|
|
227
|
-
*/
|
|
228
|
-
var ApiDisclaimerApi = /** @class */ (function (_super) {
|
|
229
|
-
__extends(ApiDisclaimerApi, _super);
|
|
230
|
-
function ApiDisclaimerApi() {
|
|
231
|
-
return _super !== null && _super.apply(this, arguments) || this;
|
|
232
|
-
}
|
|
233
|
-
/**
|
|
234
|
-
*
|
|
235
|
-
* @summary Accept or Reject SnapTrade disclaimer agreement
|
|
236
|
-
* @param {ApiDisclaimerApiAcceptRequest} requestParameters Request parameters.
|
|
237
|
-
* @param {*} [options] Override http request option.
|
|
238
|
-
* @throws {RequiredError}
|
|
239
|
-
* @memberof ApiDisclaimerApi
|
|
240
|
-
*/
|
|
241
|
-
ApiDisclaimerApi.prototype.accept = function (requestParameters, options) {
|
|
242
|
-
var _this = this;
|
|
243
|
-
return (0, exports.ApiDisclaimerApiFp)(this.configuration).accept(requestParameters, options).then(function (request) { return request(_this.axios, _this.basePath); });
|
|
244
|
-
};
|
|
245
|
-
return ApiDisclaimerApi;
|
|
246
|
-
}(api_disclaimer_api_custom_1.ApiDisclaimerApiCustom));
|
|
247
|
-
exports.ApiDisclaimerApi = ApiDisclaimerApi;
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* SnapTrade
|
|
3
|
-
* Connect brokerage accounts to your app for live positions and trading
|
|
4
|
-
*
|
|
5
|
-
* The version of the OpenAPI document: 1.0.0
|
|
6
|
-
* Contact: api@snaptrade.com
|
|
7
|
-
*
|
|
8
|
-
* NOTE: This file is auto generated by Konfig (https://konfigthis.com).
|
|
9
|
-
* https://konfigthis.com
|
|
10
|
-
* Do not edit the class manually.
|
|
11
|
-
*/
|
|
12
|
-
/**
|
|
13
|
-
*
|
|
14
|
-
* @export
|
|
15
|
-
* @interface APIDisclaimerAcceptRequest
|
|
16
|
-
*/
|
|
17
|
-
export interface APIDisclaimerAcceptRequest {
|
|
18
|
-
/**
|
|
19
|
-
* A boolean that indicates whether this user has accepted the disclaimer or not.
|
|
20
|
-
* @type {boolean}
|
|
21
|
-
* @memberof APIDisclaimerAcceptRequest
|
|
22
|
-
*/
|
|
23
|
-
'accepted'?: boolean;
|
|
24
|
-
}
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
/* tslint:disable */
|
|
3
|
-
/* eslint-disable */
|
|
4
|
-
/**
|
|
5
|
-
* SnapTrade
|
|
6
|
-
* Connect brokerage accounts to your app for live positions and trading
|
|
7
|
-
*
|
|
8
|
-
* The version of the OpenAPI document: 1.0.0
|
|
9
|
-
* Contact: api@snaptrade.com
|
|
10
|
-
*
|
|
11
|
-
* NOTE: This file is auto generated by Konfig (https://konfigthis.com).
|
|
12
|
-
* https://konfigthis.com
|
|
13
|
-
* Do not edit the class manually.
|
|
14
|
-
*/
|
|
15
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|