@seal-protocol/backendjs 0.0.29 → 0.0.41

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.
@@ -108,10 +108,11 @@ export declare const SealClientAxiosParamCreator: (configuration?: Configuration
108
108
  * @param {string} [maxPriceMargin] not supported yet
109
109
  * @param {string} [maxReservationDepositPerStable] not supported yet
110
110
  * @param {string} [minRemainingAmountStableTerms] not supported yet
111
+ * @param {boolean} [onChainValue]
111
112
  * @param {*} [options] Override http request option.
112
113
  * @throws {RequiredError}
113
114
  */
114
- getOrders: (chainId?: string, tokenIn?: string, tokenOut?: string, owner?: string, fromPriceDecimal?: string, toPriceDecimal?: string, orderByProperty?: GetOrdersOrderByPropertyEnum, orderByDescending?: boolean, paginationKey?: string, paginationLimit?: number, paginationCountTotal?: boolean, reservationAllowedValue?: boolean, liveValue?: boolean, cancelledValue?: boolean, depositToken?: string, minReservationPeriodSeconds?: number, minRemainingAmount?: string, minPriceMargin?: string, maxPriceMargin?: string, maxReservationDepositPerStable?: string, minRemainingAmountStableTerms?: string, options?: RawAxiosRequestConfig) => Promise<RequestArgs>;
115
+ getOrders: (chainId?: string, tokenIn?: string, tokenOut?: string, owner?: string, fromPriceDecimal?: string, toPriceDecimal?: string, orderByProperty?: GetOrdersOrderByPropertyEnum, orderByDescending?: boolean, paginationKey?: string, paginationLimit?: number, paginationCountTotal?: boolean, reservationAllowedValue?: boolean, liveValue?: boolean, cancelledValue?: boolean, depositToken?: string, minReservationPeriodSeconds?: number, minRemainingAmount?: string, minPriceMargin?: string, maxPriceMargin?: string, maxReservationDepositPerStable?: string, minRemainingAmountStableTerms?: string, onChainValue?: boolean, options?: RawAxiosRequestConfig) => Promise<RequestArgs>;
115
116
  /**
116
117
  *
117
118
  * @param {string} [tokenInCoingeckoId]
@@ -244,10 +245,11 @@ export declare const SealClientFp: (configuration?: Configuration) => {
244
245
  * @param {string} [maxPriceMargin] not supported yet
245
246
  * @param {string} [maxReservationDepositPerStable] not supported yet
246
247
  * @param {string} [minRemainingAmountStableTerms] not supported yet
248
+ * @param {boolean} [onChainValue]
247
249
  * @param {*} [options] Override http request option.
248
250
  * @throws {RequiredError}
249
251
  */
250
- getOrders(chainId?: string, tokenIn?: string, tokenOut?: string, owner?: string, fromPriceDecimal?: string, toPriceDecimal?: string, orderByProperty?: GetOrdersOrderByPropertyEnum, orderByDescending?: boolean, paginationKey?: string, paginationLimit?: number, paginationCountTotal?: boolean, reservationAllowedValue?: boolean, liveValue?: boolean, cancelledValue?: boolean, depositToken?: string, minReservationPeriodSeconds?: number, minRemainingAmount?: string, minPriceMargin?: string, maxPriceMargin?: string, maxReservationDepositPerStable?: string, minRemainingAmountStableTerms?: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<SealGetOrdersResponse>>;
252
+ getOrders(chainId?: string, tokenIn?: string, tokenOut?: string, owner?: string, fromPriceDecimal?: string, toPriceDecimal?: string, orderByProperty?: GetOrdersOrderByPropertyEnum, orderByDescending?: boolean, paginationKey?: string, paginationLimit?: number, paginationCountTotal?: boolean, reservationAllowedValue?: boolean, liveValue?: boolean, cancelledValue?: boolean, depositToken?: string, minReservationPeriodSeconds?: number, minRemainingAmount?: string, minPriceMargin?: string, maxPriceMargin?: string, maxReservationDepositPerStable?: string, minRemainingAmountStableTerms?: string, onChainValue?: boolean, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<SealGetOrdersResponse>>;
251
253
  /**
252
254
  *
253
255
  * @param {string} [tokenInCoingeckoId]
@@ -665,6 +667,12 @@ export interface SealClientGetOrdersRequest {
665
667
  * @memberof SealClientGetOrders
666
668
  */
667
669
  readonly minRemainingAmountStableTerms?: string;
670
+ /**
671
+ *
672
+ * @type {boolean}
673
+ * @memberof SealClientGetOrders
674
+ */
675
+ readonly onChainValue?: boolean;
668
676
  }
669
677
  /**
670
678
  * Request parameters for getPairPrice operation in SealClient.
@@ -278,10 +278,11 @@ const SealClientAxiosParamCreator = function (configuration) {
278
278
  * @param {string} [maxPriceMargin] not supported yet
279
279
  * @param {string} [maxReservationDepositPerStable] not supported yet
280
280
  * @param {string} [minRemainingAmountStableTerms] not supported yet
281
+ * @param {boolean} [onChainValue]
281
282
  * @param {*} [options] Override http request option.
282
283
  * @throws {RequiredError}
283
284
  */
284
- getOrders: async (chainId, tokenIn, tokenOut, owner, fromPriceDecimal, toPriceDecimal, orderByProperty, orderByDescending, paginationKey, paginationLimit, paginationCountTotal, reservationAllowedValue, liveValue, cancelledValue, depositToken, minReservationPeriodSeconds, minRemainingAmount, minPriceMargin, maxPriceMargin, maxReservationDepositPerStable, minRemainingAmountStableTerms, options = {}) => {
285
+ getOrders: async (chainId, tokenIn, tokenOut, owner, fromPriceDecimal, toPriceDecimal, orderByProperty, orderByDescending, paginationKey, paginationLimit, paginationCountTotal, reservationAllowedValue, liveValue, cancelledValue, depositToken, minReservationPeriodSeconds, minRemainingAmount, minPriceMargin, maxPriceMargin, maxReservationDepositPerStable, minRemainingAmountStableTerms, onChainValue, options = {}) => {
285
286
  const localVarPath = `/seal/orders`;
286
287
  // use dummy base URL string because the URL constructor only accepts absolute URLs.
287
288
  const localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
@@ -355,6 +356,9 @@ const SealClientAxiosParamCreator = function (configuration) {
355
356
  if (minRemainingAmountStableTerms !== undefined) {
356
357
  localVarQueryParameter['minRemainingAmountStableTerms'] = minRemainingAmountStableTerms;
357
358
  }
359
+ if (onChainValue !== undefined) {
360
+ localVarQueryParameter['onChain.value'] = onChainValue;
361
+ }
358
362
  (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
359
363
  let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
360
364
  localVarRequestOptions.headers = { ...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers };
@@ -673,11 +677,12 @@ const SealClientFp = function (configuration) {
673
677
  * @param {string} [maxPriceMargin] not supported yet
674
678
  * @param {string} [maxReservationDepositPerStable] not supported yet
675
679
  * @param {string} [minRemainingAmountStableTerms] not supported yet
680
+ * @param {boolean} [onChainValue]
676
681
  * @param {*} [options] Override http request option.
677
682
  * @throws {RequiredError}
678
683
  */
679
- async getOrders(chainId, tokenIn, tokenOut, owner, fromPriceDecimal, toPriceDecimal, orderByProperty, orderByDescending, paginationKey, paginationLimit, paginationCountTotal, reservationAllowedValue, liveValue, cancelledValue, depositToken, minReservationPeriodSeconds, minRemainingAmount, minPriceMargin, maxPriceMargin, maxReservationDepositPerStable, minRemainingAmountStableTerms, options) {
680
- const localVarAxiosArgs = await localVarAxiosParamCreator.getOrders(chainId, tokenIn, tokenOut, owner, fromPriceDecimal, toPriceDecimal, orderByProperty, orderByDescending, paginationKey, paginationLimit, paginationCountTotal, reservationAllowedValue, liveValue, cancelledValue, depositToken, minReservationPeriodSeconds, minRemainingAmount, minPriceMargin, maxPriceMargin, maxReservationDepositPerStable, minRemainingAmountStableTerms, options);
684
+ async getOrders(chainId, tokenIn, tokenOut, owner, fromPriceDecimal, toPriceDecimal, orderByProperty, orderByDescending, paginationKey, paginationLimit, paginationCountTotal, reservationAllowedValue, liveValue, cancelledValue, depositToken, minReservationPeriodSeconds, minRemainingAmount, minPriceMargin, maxPriceMargin, maxReservationDepositPerStable, minRemainingAmountStableTerms, onChainValue, options) {
685
+ const localVarAxiosArgs = await localVarAxiosParamCreator.getOrders(chainId, tokenIn, tokenOut, owner, fromPriceDecimal, toPriceDecimal, orderByProperty, orderByDescending, paginationKey, paginationLimit, paginationCountTotal, reservationAllowedValue, liveValue, cancelledValue, depositToken, minReservationPeriodSeconds, minRemainingAmount, minPriceMargin, maxPriceMargin, maxReservationDepositPerStable, minRemainingAmountStableTerms, onChainValue, options);
681
686
  const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
682
687
  const localVarOperationServerBasePath = base_1.operationServerMap['SealClient.getOrders']?.[localVarOperationServerIndex]?.url;
683
688
  return (axios, basePath) => (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
@@ -825,7 +830,7 @@ const SealClientFactory = function (configuration, basePath, axios) {
825
830
  * @throws {RequiredError}
826
831
  */
827
832
  getOrders(requestParameters = {}, options) {
828
- return localVarFp.getOrders(requestParameters.chainId, requestParameters.tokenIn, requestParameters.tokenOut, requestParameters.owner, requestParameters.fromPriceDecimal, requestParameters.toPriceDecimal, requestParameters.orderByProperty, requestParameters.orderByDescending, requestParameters.paginationKey, requestParameters.paginationLimit, requestParameters.paginationCountTotal, requestParameters.reservationAllowedValue, requestParameters.liveValue, requestParameters.cancelledValue, requestParameters.depositToken, requestParameters.minReservationPeriodSeconds, requestParameters.minRemainingAmount, requestParameters.minPriceMargin, requestParameters.maxPriceMargin, requestParameters.maxReservationDepositPerStable, requestParameters.minRemainingAmountStableTerms, options).then((request) => request(axios, basePath));
833
+ return localVarFp.getOrders(requestParameters.chainId, requestParameters.tokenIn, requestParameters.tokenOut, requestParameters.owner, requestParameters.fromPriceDecimal, requestParameters.toPriceDecimal, requestParameters.orderByProperty, requestParameters.orderByDescending, requestParameters.paginationKey, requestParameters.paginationLimit, requestParameters.paginationCountTotal, requestParameters.reservationAllowedValue, requestParameters.liveValue, requestParameters.cancelledValue, requestParameters.depositToken, requestParameters.minReservationPeriodSeconds, requestParameters.minRemainingAmount, requestParameters.minPriceMargin, requestParameters.maxPriceMargin, requestParameters.maxReservationDepositPerStable, requestParameters.minRemainingAmountStableTerms, requestParameters.onChainValue, options).then((request) => request(axios, basePath));
829
834
  },
830
835
  /**
831
836
  *
@@ -947,7 +952,7 @@ class SealClient extends base_1.BaseAPI {
947
952
  * @memberof SealClient
948
953
  */
949
954
  getOrders(requestParameters = {}, options) {
950
- return (0, exports.SealClientFp)(this.configuration).getOrders(requestParameters.chainId, requestParameters.tokenIn, requestParameters.tokenOut, requestParameters.owner, requestParameters.fromPriceDecimal, requestParameters.toPriceDecimal, requestParameters.orderByProperty, requestParameters.orderByDescending, requestParameters.paginationKey, requestParameters.paginationLimit, requestParameters.paginationCountTotal, requestParameters.reservationAllowedValue, requestParameters.liveValue, requestParameters.cancelledValue, requestParameters.depositToken, requestParameters.minReservationPeriodSeconds, requestParameters.minRemainingAmount, requestParameters.minPriceMargin, requestParameters.maxPriceMargin, requestParameters.maxReservationDepositPerStable, requestParameters.minRemainingAmountStableTerms, options).then((request) => request(this.axios, this.basePath));
955
+ return (0, exports.SealClientFp)(this.configuration).getOrders(requestParameters.chainId, requestParameters.tokenIn, requestParameters.tokenOut, requestParameters.owner, requestParameters.fromPriceDecimal, requestParameters.toPriceDecimal, requestParameters.orderByProperty, requestParameters.orderByDescending, requestParameters.paginationKey, requestParameters.paginationLimit, requestParameters.paginationCountTotal, requestParameters.reservationAllowedValue, requestParameters.liveValue, requestParameters.cancelledValue, requestParameters.depositToken, requestParameters.minReservationPeriodSeconds, requestParameters.minRemainingAmount, requestParameters.minPriceMargin, requestParameters.maxPriceMargin, requestParameters.maxReservationDepositPerStable, requestParameters.minRemainingAmountStableTerms, requestParameters.onChainValue, options).then((request) => request(this.axios, this.basePath));
951
956
  }
952
957
  /**
953
958
  *
@@ -2,6 +2,7 @@ export * from './protobuf-any';
2
2
  export * from './rpc-status';
3
3
  export * from './seal-cancel-order-request';
4
4
  export * from './seal-chain';
5
+ export * from './seal-chain-health';
5
6
  export * from './seal-chain-sync-state';
6
7
  export * from './seal-chains-order-by';
7
8
  export * from './seal-chains-order-by-property';
@@ -18,6 +18,7 @@ __exportStar(require("./protobuf-any"), exports);
18
18
  __exportStar(require("./rpc-status"), exports);
19
19
  __exportStar(require("./seal-cancel-order-request"), exports);
20
20
  __exportStar(require("./seal-chain"), exports);
21
+ __exportStar(require("./seal-chain-health"), exports);
21
22
  __exportStar(require("./seal-chain-sync-state"), exports);
22
23
  __exportStar(require("./seal-chains-order-by"), exports);
23
24
  __exportStar(require("./seal-chains-order-by-property"), exports);
@@ -0,0 +1,42 @@
1
+ /**
2
+ * seal/seal.proto
3
+ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
4
+ *
5
+ * The version of the OpenAPI document: version not set
6
+ *
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ */
12
+ /**
13
+ *
14
+ * @export
15
+ * @interface SealChainHealth
16
+ */
17
+ export interface SealChainHealth {
18
+ /**
19
+ *
20
+ * @type {string}
21
+ * @memberof SealChainHealth
22
+ */
23
+ 'indexerBlockDifference'?: string;
24
+ /**
25
+ *
26
+ * @type {string}
27
+ * @memberof SealChainHealth
28
+ */
29
+ 'backendBlockDifference'?: string;
30
+ /**
31
+ *
32
+ * @type {string}
33
+ * @memberof SealChainHealth
34
+ */
35
+ 'estimatedSyncDurationSeconds'?: string;
36
+ /**
37
+ *
38
+ * @type {string}
39
+ * @memberof SealChainHealth
40
+ */
41
+ 'estimatedSyncDurationDuration'?: string;
42
+ }
@@ -0,0 +1,15 @@
1
+ "use strict";
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+ /**
5
+ * seal/seal.proto
6
+ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
7
+ *
8
+ * The version of the OpenAPI document: version not set
9
+ *
10
+ *
11
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
12
+ * https://openapi-generator.tech
13
+ * Do not edit the class manually.
14
+ */
15
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -9,12 +9,19 @@
9
9
  * https://openapi-generator.tech
10
10
  * Do not edit the class manually.
11
11
  */
12
+ import type { SealChainHealth } from './seal-chain-health';
12
13
  /**
13
14
  *
14
15
  * @export
15
16
  * @interface SealGetHealthCheckResponse
16
17
  */
17
18
  export interface SealGetHealthCheckResponse {
19
+ /**
20
+ *
21
+ * @type {Array<SealChainHealth>}
22
+ * @memberof SealGetHealthCheckResponse
23
+ */
24
+ 'chainHealth'?: Array<SealChainHealth>;
18
25
  /**
19
26
  *
20
27
  * @type {string}
@@ -179,4 +179,10 @@ export interface SealOrder {
179
179
  * @memberof SealOrder
180
180
  */
181
181
  'orderIntent'?: SealOrderIntent;
182
+ /**
183
+ *
184
+ * @type {boolean}
185
+ * @memberof SealOrder
186
+ */
187
+ 'onChain'?: boolean;
182
188
  }
@@ -27,4 +27,10 @@ export interface TypesTimestamp {
27
27
  * @memberof TypesTimestamp
28
28
  */
29
29
  'nanos'?: number;
30
+ /**
31
+ *
32
+ * @type {string}
33
+ * @memberof TypesTimestamp
34
+ */
35
+ 'str'?: string;
30
36
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@seal-protocol/backendjs",
3
- "version": "0.0.29",
3
+ "version": "0.0.41",
4
4
  "description": "Javascript SDK for Seal Backend",
5
5
  "author": "amin <amin@refractedlabs.com>",
6
6
  "homepage": "https://github.com/seal-protocol/backend/tree/main/ts-client#readme",