diff --git a/packages/internal/guardian/src/client/api.ts b/packages/internal/guardian/src/client/api.ts index 50723da672..09de3aa670 100644 --- a/packages/internal/guardian/src/client/api.ts +++ b/packages/internal/guardian/src/client/api.ts @@ -15,6 +15,5 @@ export * from './domain/messages-api'; -export * from './domain/starkex-transactions-api'; export * from './domain/transactions-api'; diff --git a/packages/internal/guardian/src/client/domain/starkex-transactions-api.ts b/packages/internal/guardian/src/client/domain/starkex-transactions-api.ts deleted file mode 100644 index 7800d5a3f5..0000000000 --- a/packages/internal/guardian/src/client/domain/starkex-transactions-api.ts +++ /dev/null @@ -1,157 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Guardian - * Guardian API - * - * The version of the OpenAPI document: 1.0.0 - * Contact: support@immutable.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -import type { Configuration } from '../configuration'; -import type { AxiosPromise, AxiosInstance, RawAxiosRequestConfig } from 'axios'; -import globalAxios from 'axios'; -// Some imports not used depending on template conditions -// @ts-ignore -import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObject, setBearerAuthToObject, setOAuthToObject, setSearchParams, serializeDataIfNeeded, toPathString, createRequestFunction } from '../common'; -// @ts-ignore -import { BASE_PATH, COLLECTION_FORMATS, type RequestArgs, BaseAPI, RequiredError, operationServerMap } from '../base'; -// @ts-ignore -import type { APIError404 } from '../models'; -// @ts-ignore -import type { APIError500 } from '../models'; -// @ts-ignore -import type { TransactionEvaluationResponse } from '../models'; -/** - * StarkexTransactionsApi - axios parameter creator - * @export - */ -export const StarkexTransactionsApiAxiosParamCreator = function (configuration?: Configuration) { - return { - /** - * Check if it is a valid transaction by payload hash - * @summary Evaluate if it is an valid transaction - * @param {string} payloadHash Hash for the payload - * @param {*} [options] Override http request option. - * @deprecated - * @throws {RequiredError} - */ - evaluateStarkexTransaction: async (payloadHash: string, options: RawAxiosRequestConfig = {}): Promise => { - // verify required parameter 'payloadHash' is not null or undefined - assertParamExists('evaluateStarkexTransaction', 'payloadHash', payloadHash) - const localVarPath = `/guardian/v1/starkex/evaluate/{payloadHash}` - .replace(`{${"payloadHash"}}`, encodeURIComponent(String(payloadHash))); - // use dummy base URL string because the URL constructor only accepts absolute URLs. - const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); - let baseOptions; - if (configuration) { - baseOptions = configuration.baseOptions; - } - - const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options}; - const localVarHeaderParameter = {} as any; - const localVarQueryParameter = {} as any; - - // authentication BearerAuth required - // http bearer authentication required - await setBearerAuthToObject(localVarHeaderParameter, configuration) - - - - setSearchParams(localVarUrlObj, localVarQueryParameter); - let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; - localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; - - return { - url: toPathString(localVarUrlObj), - options: localVarRequestOptions, - }; - }, - } -}; - -/** - * StarkexTransactionsApi - functional programming interface - * @export - */ -export const StarkexTransactionsApiFp = function(configuration?: Configuration) { - const localVarAxiosParamCreator = StarkexTransactionsApiAxiosParamCreator(configuration) - return { - /** - * Check if it is a valid transaction by payload hash - * @summary Evaluate if it is an valid transaction - * @param {string} payloadHash Hash for the payload - * @param {*} [options] Override http request option. - * @deprecated - * @throws {RequiredError} - */ - async evaluateStarkexTransaction(payloadHash: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { - const localVarAxiosArgs = await localVarAxiosParamCreator.evaluateStarkexTransaction(payloadHash, options); - const localVarOperationServerIndex = configuration?.serverIndex ?? 0; - const localVarOperationServerBasePath = operationServerMap['StarkexTransactionsApi.evaluateStarkexTransaction']?.[localVarOperationServerIndex]?.url; - return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); - }, - } -}; - -/** - * StarkexTransactionsApi - factory interface - * @export - */ -export const StarkexTransactionsApiFactory = function (configuration?: Configuration, basePath?: string, axios?: AxiosInstance) { - const localVarFp = StarkexTransactionsApiFp(configuration) - return { - /** - * Check if it is a valid transaction by payload hash - * @summary Evaluate if it is an valid transaction - * @param {StarkexTransactionsApiEvaluateStarkexTransactionRequest} requestParameters Request parameters. - * @param {*} [options] Override http request option. - * @deprecated - * @throws {RequiredError} - */ - evaluateStarkexTransaction(requestParameters: StarkexTransactionsApiEvaluateStarkexTransactionRequest, options?: RawAxiosRequestConfig): AxiosPromise { - return localVarFp.evaluateStarkexTransaction(requestParameters.payloadHash, options).then((request) => request(axios, basePath)); - }, - }; -}; - -/** - * Request parameters for evaluateStarkexTransaction operation in StarkexTransactionsApi. - * @export - * @interface StarkexTransactionsApiEvaluateStarkexTransactionRequest - */ -export interface StarkexTransactionsApiEvaluateStarkexTransactionRequest { - /** - * Hash for the payload - * @type {string} - * @memberof StarkexTransactionsApiEvaluateStarkexTransaction - */ - readonly payloadHash: string -} - -/** - * StarkexTransactionsApi - object-oriented interface - * @export - * @class StarkexTransactionsApi - * @extends {BaseAPI} - */ -export class StarkexTransactionsApi extends BaseAPI { - /** - * Check if it is a valid transaction by payload hash - * @summary Evaluate if it is an valid transaction - * @param {StarkexTransactionsApiEvaluateStarkexTransactionRequest} requestParameters Request parameters. - * @param {*} [options] Override http request option. - * @deprecated - * @throws {RequiredError} - * @memberof StarkexTransactionsApi - */ - public evaluateStarkexTransaction(requestParameters: StarkexTransactionsApiEvaluateStarkexTransactionRequest, options?: RawAxiosRequestConfig) { - return StarkexTransactionsApiFp(this.configuration).evaluateStarkexTransaction(requestParameters.payloadHash, options).then((request) => request(this.axios, this.basePath)); - } -} -