New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@jup-ag/api

Package Overview
Dependencies
Maintainers
7
Versions
56
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@jup-ag/api - npm Package Compare versions

Comparing version 6.0.26 to 6.0.27-alpha

196

dist/index.d.ts

@@ -694,2 +694,94 @@ /**

/**
*
* @export
* @interface SwapRequestDynamicSlippage
*/
interface SwapRequestDynamicSlippage {
/**
*
* @type {number}
* @memberof SwapRequestDynamicSlippage
*/
minBps?: number;
/**
*
* @type {number}
* @memberof SwapRequestDynamicSlippage
*/
maxBps?: number;
}
/**
* Check if a given object implements the SwapRequestDynamicSlippage interface.
*/
declare function instanceOfSwapRequestDynamicSlippage(value: object): boolean;
declare function SwapRequestDynamicSlippageFromJSON(json: any): SwapRequestDynamicSlippage;
declare function SwapRequestDynamicSlippageFromJSONTyped(json: any, ignoreDiscriminator: boolean): SwapRequestDynamicSlippage;
declare function SwapRequestDynamicSlippageToJSON(value?: SwapRequestDynamicSlippage | null): any;
/**
* Jupiter API v6
* The core of [jup.ag](https://jup.ag). Easily get a quote and swap through Jupiter API. ### Rate Limit We update our rate limit from time to time depending on the load of our servers. We recommend running your own instance of the API if you want to have high rate limit, here to learn how to run the [self-hosted API](https://station.jup.ag/docs/apis/self-hosted). ### API Wrapper - Typescript [@jup-ag/api](https://github.com/jup-ag/jupiter-quote-api-node) ### Data types - Public keys are base58 encoded strings - raw data such as Vec<u8\\> are base64 encoded strings
*
* The version of the OpenAPI document: 6.0.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/
/**
*
* @export
* @interface SwapRequestPrioritizationFeeLamportsAnyOfPriorityLevelWithMaxLamports
*/
interface SwapRequestPrioritizationFeeLamportsAnyOfPriorityLevelWithMaxLamports {
/**
*
* @type {boolean}
* @memberof SwapRequestPrioritizationFeeLamportsAnyOfPriorityLevelWithMaxLamports
*/
global?: boolean;
/**
*
* @type {number}
* @memberof SwapRequestPrioritizationFeeLamportsAnyOfPriorityLevelWithMaxLamports
*/
maxLamports?: number;
/**
*
* @type {string}
* @memberof SwapRequestPrioritizationFeeLamportsAnyOfPriorityLevelWithMaxLamports
*/
priorityLevel?: SwapRequestPrioritizationFeeLamportsAnyOfPriorityLevelWithMaxLamportsPriorityLevelEnum;
}
/**
* @export
*/
declare const SwapRequestPrioritizationFeeLamportsAnyOfPriorityLevelWithMaxLamportsPriorityLevelEnum: {
readonly Medium: "medium";
readonly High: "high";
readonly VeryHigh: "veryHigh";
};
type SwapRequestPrioritizationFeeLamportsAnyOfPriorityLevelWithMaxLamportsPriorityLevelEnum = typeof SwapRequestPrioritizationFeeLamportsAnyOfPriorityLevelWithMaxLamportsPriorityLevelEnum[keyof typeof SwapRequestPrioritizationFeeLamportsAnyOfPriorityLevelWithMaxLamportsPriorityLevelEnum];
/**
* Check if a given object implements the SwapRequestPrioritizationFeeLamportsAnyOfPriorityLevelWithMaxLamports interface.
*/
declare function instanceOfSwapRequestPrioritizationFeeLamportsAnyOfPriorityLevelWithMaxLamports(value: object): boolean;
declare function SwapRequestPrioritizationFeeLamportsAnyOfPriorityLevelWithMaxLamportsFromJSON(json: any): SwapRequestPrioritizationFeeLamportsAnyOfPriorityLevelWithMaxLamports;
declare function SwapRequestPrioritizationFeeLamportsAnyOfPriorityLevelWithMaxLamportsFromJSONTyped(json: any, ignoreDiscriminator: boolean): SwapRequestPrioritizationFeeLamportsAnyOfPriorityLevelWithMaxLamports;
declare function SwapRequestPrioritizationFeeLamportsAnyOfPriorityLevelWithMaxLamportsToJSON(value?: SwapRequestPrioritizationFeeLamportsAnyOfPriorityLevelWithMaxLamports | null): any;
/**
* Jupiter API v6
* The core of [jup.ag](https://jup.ag). Easily get a quote and swap through Jupiter API. ### Rate Limit We update our rate limit from time to time depending on the load of our servers. We recommend running your own instance of the API if you want to have high rate limit, here to learn how to run the [self-hosted API](https://station.jup.ag/docs/apis/self-hosted). ### API Wrapper - Typescript [@jup-ag/api](https://github.com/jup-ag/jupiter-quote-api-node) ### Data types - Public keys are base58 encoded strings - raw data such as Vec<u8\\> are base64 encoded strings
*
* The version of the OpenAPI document: 6.0.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/
/**
* Prioritization fee lamports paid for the transaction in addition to the signatures fee. Mutually exclusive with compute_unit_price_micro_lamports. If `auto` is used, Jupiter will automatically set a priority fee and it will be capped at 5,000,000 lamports / 0.005 SOL.

@@ -700,2 +792,8 @@ * @export

interface SwapRequestPrioritizationFeeLamports {
/**
*
* @type {SwapRequestPrioritizationFeeLamportsAnyOfPriorityLevelWithMaxLamports}
* @memberof SwapRequestPrioritizationFeeLamports
*/
priorityLevelWithMaxLamports?: SwapRequestPrioritizationFeeLamportsAnyOfPriorityLevelWithMaxLamports;
}

@@ -812,2 +910,8 @@ /**

quoteResponse: QuoteResponse;
/**
*
* @type {SwapRequestDynamicSlippage}
* @memberof SwapRequest
*/
dynamicSlippage?: SwapRequestDynamicSlippage;
}

@@ -833,5 +937,89 @@ /**

*/
/**
*
* @export
* @interface SwapRequestPrioritizationFeeLamportsAnyOf
*/
interface SwapRequestPrioritizationFeeLamportsAnyOf {
/**
*
* @type {SwapRequestPrioritizationFeeLamportsAnyOfPriorityLevelWithMaxLamports}
* @memberof SwapRequestPrioritizationFeeLamportsAnyOf
*/
priorityLevelWithMaxLamports?: SwapRequestPrioritizationFeeLamportsAnyOfPriorityLevelWithMaxLamports;
}
/**
* Check if a given object implements the SwapRequestPrioritizationFeeLamportsAnyOf interface.
*/
declare function instanceOfSwapRequestPrioritizationFeeLamportsAnyOf(value: object): boolean;
declare function SwapRequestPrioritizationFeeLamportsAnyOfFromJSON(json: any): SwapRequestPrioritizationFeeLamportsAnyOf;
declare function SwapRequestPrioritizationFeeLamportsAnyOfFromJSONTyped(json: any, ignoreDiscriminator: boolean): SwapRequestPrioritizationFeeLamportsAnyOf;
declare function SwapRequestPrioritizationFeeLamportsAnyOfToJSON(value?: SwapRequestPrioritizationFeeLamportsAnyOf | null): any;
/**
* Jupiter API v6
* The core of [jup.ag](https://jup.ag). Easily get a quote and swap through Jupiter API. ### Rate Limit We update our rate limit from time to time depending on the load of our servers. We recommend running your own instance of the API if you want to have high rate limit, here to learn how to run the [self-hosted API](https://station.jup.ag/docs/apis/self-hosted). ### API Wrapper - Typescript [@jup-ag/api](https://github.com/jup-ag/jupiter-quote-api-node) ### Data types - Public keys are base58 encoded strings - raw data such as Vec<u8\\> are base64 encoded strings
*
* The version of the OpenAPI document: 6.0.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/
/**
*
* @export
* @interface SwapResponseDynamicSlippageReport
*/
interface SwapResponseDynamicSlippageReport {
/**
*
* @type {string}
* @memberof SwapResponseDynamicSlippageReport
*/
amplificationRatio?: string;
/**
*
* @type {number}
* @memberof SwapResponseDynamicSlippageReport
*/
otherAmount?: number;
/**
*
* @type {number}
* @memberof SwapResponseDynamicSlippageReport
*/
simulatedIncurredSlippageBps?: number;
/**
*
* @type {number}
* @memberof SwapResponseDynamicSlippageReport
*/
slippageBps?: number;
}
/**
* Check if a given object implements the SwapResponseDynamicSlippageReport interface.
*/
declare function instanceOfSwapResponseDynamicSlippageReport(value: object): boolean;
declare function SwapResponseDynamicSlippageReportFromJSON(json: any): SwapResponseDynamicSlippageReport;
declare function SwapResponseDynamicSlippageReportFromJSONTyped(json: any, ignoreDiscriminator: boolean): SwapResponseDynamicSlippageReport;
declare function SwapResponseDynamicSlippageReportToJSON(value?: SwapResponseDynamicSlippageReport | null): any;
/**
* Jupiter API v6
* The core of [jup.ag](https://jup.ag). Easily get a quote and swap through Jupiter API. ### Rate Limit We update our rate limit from time to time depending on the load of our servers. We recommend running your own instance of the API if you want to have high rate limit, here to learn how to run the [self-hosted API](https://station.jup.ag/docs/apis/self-hosted). ### API Wrapper - Typescript [@jup-ag/api](https://github.com/jup-ag/jupiter-quote-api-node) ### Data types - Public keys are base58 encoded strings - raw data such as Vec<u8\\> are base64 encoded strings
*
* The version of the OpenAPI document: 6.0.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/
/**
*
* @export
* @interface SwapResponse

@@ -858,2 +1046,8 @@ */

prioritizationFeeLamports?: number;
/**
*
* @type {SwapResponseDynamicSlippageReport}
* @memberof SwapResponse
*/
dynamicSlippageReport?: SwapResponseDynamicSlippageReport;
}

@@ -991,2 +1185,2 @@ /**

export { AccountMeta, AccountMetaFromJSON, AccountMetaFromJSONTyped, AccountMetaToJSON, ApiResponse, BASE_PATH, BaseAPI, BlobApiResponse, COLLECTION_FORMATS, Configuration, ConfigurationParameters, Consume, DefaultApi, DefaultConfig, ErrorContext, FetchAPI, FetchError, FetchParams, HTTPBody, HTTPHeaders, HTTPMethod, HTTPQuery, HTTPRequestInit, IndexedRouteMapGetRequest, IndexedRouteMapResponse, IndexedRouteMapResponseFromJSON, IndexedRouteMapResponseFromJSONTyped, IndexedRouteMapResponseToJSON, InitOverrideFunction, Instruction, InstructionFromJSON, InstructionFromJSONTyped, InstructionToJSON, JSONApiResponse, Json, Middleware, ModelPropertyNaming, PlatformFee, PlatformFeeFromJSON, PlatformFeeFromJSONTyped, PlatformFeeToJSON, QuoteGetRequest, QuoteGetSwapModeEnum, QuoteResponse, QuoteResponseFromJSON, QuoteResponseFromJSONTyped, QuoteResponseToJSON, RequestContext, RequestOpts, RequiredError, ResponseContext, ResponseError, ResponseTransformer, RoutePlanStep, RoutePlanStepFromJSON, RoutePlanStepFromJSONTyped, RoutePlanStepToJSON, SwapInfo, SwapInfoFromJSON, SwapInfoFromJSONTyped, SwapInfoToJSON, SwapInstructionsPostRequest, SwapInstructionsResponse, SwapInstructionsResponseFromJSON, SwapInstructionsResponseFromJSONTyped, SwapInstructionsResponseToJSON, SwapMode, SwapModeFromJSON, SwapModeFromJSONTyped, SwapModeToJSON, SwapPostRequest, SwapRequest, SwapRequestComputeUnitPriceMicroLamports, SwapRequestComputeUnitPriceMicroLamportsFromJSON, SwapRequestComputeUnitPriceMicroLamportsFromJSONTyped, SwapRequestComputeUnitPriceMicroLamportsToJSON, SwapRequestFromJSON, SwapRequestFromJSONTyped, SwapRequestPrioritizationFeeLamports, SwapRequestPrioritizationFeeLamportsFromJSON, SwapRequestPrioritizationFeeLamportsFromJSONTyped, SwapRequestPrioritizationFeeLamportsToJSON, SwapRequestToJSON, SwapResponse, SwapResponseFromJSON, SwapResponseFromJSONTyped, SwapResponseToJSON, TextApiResponse, VoidApiResponse, canConsumeForm, createJupiterApiClient, exists, instanceOfAccountMeta, instanceOfIndexedRouteMapResponse, instanceOfInstruction, instanceOfPlatformFee, instanceOfQuoteResponse, instanceOfRoutePlanStep, instanceOfSwapInfo, instanceOfSwapInstructionsResponse, instanceOfSwapRequest, instanceOfSwapRequestComputeUnitPriceMicroLamports, instanceOfSwapRequestPrioritizationFeeLamports, instanceOfSwapResponse, mapValues, querystring };
export { AccountMeta, AccountMetaFromJSON, AccountMetaFromJSONTyped, AccountMetaToJSON, ApiResponse, BASE_PATH, BaseAPI, BlobApiResponse, COLLECTION_FORMATS, Configuration, ConfigurationParameters, Consume, DefaultApi, DefaultConfig, ErrorContext, FetchAPI, FetchError, FetchParams, HTTPBody, HTTPHeaders, HTTPMethod, HTTPQuery, HTTPRequestInit, IndexedRouteMapGetRequest, IndexedRouteMapResponse, IndexedRouteMapResponseFromJSON, IndexedRouteMapResponseFromJSONTyped, IndexedRouteMapResponseToJSON, InitOverrideFunction, Instruction, InstructionFromJSON, InstructionFromJSONTyped, InstructionToJSON, JSONApiResponse, Json, Middleware, ModelPropertyNaming, PlatformFee, PlatformFeeFromJSON, PlatformFeeFromJSONTyped, PlatformFeeToJSON, QuoteGetRequest, QuoteGetSwapModeEnum, QuoteResponse, QuoteResponseFromJSON, QuoteResponseFromJSONTyped, QuoteResponseToJSON, RequestContext, RequestOpts, RequiredError, ResponseContext, ResponseError, ResponseTransformer, RoutePlanStep, RoutePlanStepFromJSON, RoutePlanStepFromJSONTyped, RoutePlanStepToJSON, SwapInfo, SwapInfoFromJSON, SwapInfoFromJSONTyped, SwapInfoToJSON, SwapInstructionsPostRequest, SwapInstructionsResponse, SwapInstructionsResponseFromJSON, SwapInstructionsResponseFromJSONTyped, SwapInstructionsResponseToJSON, SwapMode, SwapModeFromJSON, SwapModeFromJSONTyped, SwapModeToJSON, SwapPostRequest, SwapRequest, SwapRequestComputeUnitPriceMicroLamports, SwapRequestComputeUnitPriceMicroLamportsFromJSON, SwapRequestComputeUnitPriceMicroLamportsFromJSONTyped, SwapRequestComputeUnitPriceMicroLamportsToJSON, SwapRequestDynamicSlippage, SwapRequestDynamicSlippageFromJSON, SwapRequestDynamicSlippageFromJSONTyped, SwapRequestDynamicSlippageToJSON, SwapRequestFromJSON, SwapRequestFromJSONTyped, SwapRequestPrioritizationFeeLamports, SwapRequestPrioritizationFeeLamportsAnyOf, SwapRequestPrioritizationFeeLamportsAnyOfFromJSON, SwapRequestPrioritizationFeeLamportsAnyOfFromJSONTyped, SwapRequestPrioritizationFeeLamportsAnyOfPriorityLevelWithMaxLamports, SwapRequestPrioritizationFeeLamportsAnyOfPriorityLevelWithMaxLamportsFromJSON, SwapRequestPrioritizationFeeLamportsAnyOfPriorityLevelWithMaxLamportsFromJSONTyped, SwapRequestPrioritizationFeeLamportsAnyOfPriorityLevelWithMaxLamportsPriorityLevelEnum, SwapRequestPrioritizationFeeLamportsAnyOfPriorityLevelWithMaxLamportsToJSON, SwapRequestPrioritizationFeeLamportsAnyOfToJSON, SwapRequestPrioritizationFeeLamportsFromJSON, SwapRequestPrioritizationFeeLamportsFromJSONTyped, SwapRequestPrioritizationFeeLamportsToJSON, SwapRequestToJSON, SwapResponse, SwapResponseDynamicSlippageReport, SwapResponseDynamicSlippageReportFromJSON, SwapResponseDynamicSlippageReportFromJSONTyped, SwapResponseDynamicSlippageReportToJSON, SwapResponseFromJSON, SwapResponseFromJSONTyped, SwapResponseToJSON, TextApiResponse, VoidApiResponse, canConsumeForm, createJupiterApiClient, exists, instanceOfAccountMeta, instanceOfIndexedRouteMapResponse, instanceOfInstruction, instanceOfPlatformFee, instanceOfQuoteResponse, instanceOfRoutePlanStep, instanceOfSwapInfo, instanceOfSwapInstructionsResponse, instanceOfSwapRequest, instanceOfSwapRequestComputeUnitPriceMicroLamports, instanceOfSwapRequestDynamicSlippage, instanceOfSwapRequestPrioritizationFeeLamports, instanceOfSwapRequestPrioritizationFeeLamportsAnyOf, instanceOfSwapRequestPrioritizationFeeLamportsAnyOfPriorityLevelWithMaxLamports, instanceOfSwapResponse, instanceOfSwapResponseDynamicSlippageReport, mapValues, querystring };

@@ -103,4 +103,14 @@ "use strict";

SwapRequestComputeUnitPriceMicroLamportsToJSON: () => SwapRequestComputeUnitPriceMicroLamportsToJSON,
SwapRequestDynamicSlippageFromJSON: () => SwapRequestDynamicSlippageFromJSON,
SwapRequestDynamicSlippageFromJSONTyped: () => SwapRequestDynamicSlippageFromJSONTyped,
SwapRequestDynamicSlippageToJSON: () => SwapRequestDynamicSlippageToJSON,
SwapRequestFromJSON: () => SwapRequestFromJSON,
SwapRequestFromJSONTyped: () => SwapRequestFromJSONTyped,
SwapRequestPrioritizationFeeLamportsAnyOfFromJSON: () => SwapRequestPrioritizationFeeLamportsAnyOfFromJSON,
SwapRequestPrioritizationFeeLamportsAnyOfFromJSONTyped: () => SwapRequestPrioritizationFeeLamportsAnyOfFromJSONTyped,
SwapRequestPrioritizationFeeLamportsAnyOfPriorityLevelWithMaxLamportsFromJSON: () => SwapRequestPrioritizationFeeLamportsAnyOfPriorityLevelWithMaxLamportsFromJSON,
SwapRequestPrioritizationFeeLamportsAnyOfPriorityLevelWithMaxLamportsFromJSONTyped: () => SwapRequestPrioritizationFeeLamportsAnyOfPriorityLevelWithMaxLamportsFromJSONTyped,
SwapRequestPrioritizationFeeLamportsAnyOfPriorityLevelWithMaxLamportsPriorityLevelEnum: () => SwapRequestPrioritizationFeeLamportsAnyOfPriorityLevelWithMaxLamportsPriorityLevelEnum,
SwapRequestPrioritizationFeeLamportsAnyOfPriorityLevelWithMaxLamportsToJSON: () => SwapRequestPrioritizationFeeLamportsAnyOfPriorityLevelWithMaxLamportsToJSON,
SwapRequestPrioritizationFeeLamportsAnyOfToJSON: () => SwapRequestPrioritizationFeeLamportsAnyOfToJSON,
SwapRequestPrioritizationFeeLamportsFromJSON: () => SwapRequestPrioritizationFeeLamportsFromJSON,

@@ -110,2 +120,5 @@ SwapRequestPrioritizationFeeLamportsFromJSONTyped: () => SwapRequestPrioritizationFeeLamportsFromJSONTyped,

SwapRequestToJSON: () => SwapRequestToJSON,
SwapResponseDynamicSlippageReportFromJSON: () => SwapResponseDynamicSlippageReportFromJSON,
SwapResponseDynamicSlippageReportFromJSONTyped: () => SwapResponseDynamicSlippageReportFromJSONTyped,
SwapResponseDynamicSlippageReportToJSON: () => SwapResponseDynamicSlippageReportToJSON,
SwapResponseFromJSON: () => SwapResponseFromJSON,

@@ -129,4 +142,8 @@ SwapResponseFromJSONTyped: () => SwapResponseFromJSONTyped,

instanceOfSwapRequestComputeUnitPriceMicroLamports: () => instanceOfSwapRequestComputeUnitPriceMicroLamports,
instanceOfSwapRequestDynamicSlippage: () => instanceOfSwapRequestDynamicSlippage,
instanceOfSwapRequestPrioritizationFeeLamports: () => instanceOfSwapRequestPrioritizationFeeLamports,
instanceOfSwapRequestPrioritizationFeeLamportsAnyOf: () => instanceOfSwapRequestPrioritizationFeeLamportsAnyOf,
instanceOfSwapRequestPrioritizationFeeLamportsAnyOfPriorityLevelWithMaxLamports: () => instanceOfSwapRequestPrioritizationFeeLamportsAnyOfPriorityLevelWithMaxLamports,
instanceOfSwapResponse: () => instanceOfSwapResponse,
instanceOfSwapResponseDynamicSlippageReport: () => instanceOfSwapResponseDynamicSlippageReport,
mapValues: () => mapValues,

@@ -784,2 +801,69 @@ querystring: () => querystring

// generated/models/SwapRequestDynamicSlippage.ts
function instanceOfSwapRequestDynamicSlippage(value) {
let isInstance = true;
return isInstance;
}
function SwapRequestDynamicSlippageFromJSON(json) {
return SwapRequestDynamicSlippageFromJSONTyped(json, false);
}
function SwapRequestDynamicSlippageFromJSONTyped(json, ignoreDiscriminator) {
if (json === void 0 || json === null) {
return json;
}
return {
"minBps": !exists(json, "minBps") ? void 0 : json["minBps"],
"maxBps": !exists(json, "maxBps") ? void 0 : json["maxBps"]
};
}
function SwapRequestDynamicSlippageToJSON(value) {
if (value === void 0) {
return void 0;
}
if (value === null) {
return null;
}
return {
"minBps": value.minBps,
"maxBps": value.maxBps
};
}
// generated/models/SwapRequestPrioritizationFeeLamportsAnyOfPriorityLevelWithMaxLamports.ts
var SwapRequestPrioritizationFeeLamportsAnyOfPriorityLevelWithMaxLamportsPriorityLevelEnum = {
Medium: "medium",
High: "high",
VeryHigh: "veryHigh"
};
function instanceOfSwapRequestPrioritizationFeeLamportsAnyOfPriorityLevelWithMaxLamports(value) {
let isInstance = true;
return isInstance;
}
function SwapRequestPrioritizationFeeLamportsAnyOfPriorityLevelWithMaxLamportsFromJSON(json) {
return SwapRequestPrioritizationFeeLamportsAnyOfPriorityLevelWithMaxLamportsFromJSONTyped(json, false);
}
function SwapRequestPrioritizationFeeLamportsAnyOfPriorityLevelWithMaxLamportsFromJSONTyped(json, ignoreDiscriminator) {
if (json === void 0 || json === null) {
return json;
}
return {
"global": !exists(json, "global") ? void 0 : json["global"],
"maxLamports": !exists(json, "maxLamports") ? void 0 : json["maxLamports"],
"priorityLevel": !exists(json, "priorityLevel") ? void 0 : json["priorityLevel"]
};
}
function SwapRequestPrioritizationFeeLamportsAnyOfPriorityLevelWithMaxLamportsToJSON(value) {
if (value === void 0) {
return void 0;
}
if (value === null) {
return null;
}
return {
"global": value.global,
"maxLamports": value.maxLamports,
"priorityLevel": value.priorityLevel
};
}
// generated/models/SwapRequestPrioritizationFeeLamports.ts

@@ -794,6 +878,19 @@ function instanceOfSwapRequestPrioritizationFeeLamports(value) {

function SwapRequestPrioritizationFeeLamportsFromJSONTyped(json, ignoreDiscriminator) {
return json;
if (json === void 0 || json === null) {
return json;
}
return {
"priorityLevelWithMaxLamports": !exists(json, "priorityLevelWithMaxLamports") ? void 0 : SwapRequestPrioritizationFeeLamportsAnyOfPriorityLevelWithMaxLamportsFromJSON(json["priorityLevelWithMaxLamports"])
};
}
function SwapRequestPrioritizationFeeLamportsToJSON(value) {
return value;
if (value === void 0) {
return void 0;
}
if (value === null) {
return null;
}
return {
"priorityLevelWithMaxLamports": SwapRequestPrioritizationFeeLamportsAnyOfPriorityLevelWithMaxLamportsToJSON(value.priorityLevelWithMaxLamports)
};
}

@@ -829,3 +926,4 @@

"allowOptimizedWrappedSolTokenAccount": !exists(json, "allowOptimizedWrappedSolTokenAccount") ? void 0 : json["allowOptimizedWrappedSolTokenAccount"],
"quoteResponse": QuoteResponseFromJSON(json["quoteResponse"])
"quoteResponse": QuoteResponseFromJSON(json["quoteResponse"]),
"dynamicSlippage": !exists(json, "dynamicSlippage") ? void 0 : SwapRequestDynamicSlippageFromJSON(json["dynamicSlippage"])
};

@@ -854,6 +952,69 @@ }

"allowOptimizedWrappedSolTokenAccount": value.allowOptimizedWrappedSolTokenAccount,
"quoteResponse": QuoteResponseToJSON(value.quoteResponse)
"quoteResponse": QuoteResponseToJSON(value.quoteResponse),
"dynamicSlippage": SwapRequestDynamicSlippageToJSON(value.dynamicSlippage)
};
}
// generated/models/SwapRequestPrioritizationFeeLamportsAnyOf.ts
function instanceOfSwapRequestPrioritizationFeeLamportsAnyOf(value) {
let isInstance = true;
return isInstance;
}
function SwapRequestPrioritizationFeeLamportsAnyOfFromJSON(json) {
return SwapRequestPrioritizationFeeLamportsAnyOfFromJSONTyped(json, false);
}
function SwapRequestPrioritizationFeeLamportsAnyOfFromJSONTyped(json, ignoreDiscriminator) {
if (json === void 0 || json === null) {
return json;
}
return {
"priorityLevelWithMaxLamports": !exists(json, "priorityLevelWithMaxLamports") ? void 0 : SwapRequestPrioritizationFeeLamportsAnyOfPriorityLevelWithMaxLamportsFromJSON(json["priorityLevelWithMaxLamports"])
};
}
function SwapRequestPrioritizationFeeLamportsAnyOfToJSON(value) {
if (value === void 0) {
return void 0;
}
if (value === null) {
return null;
}
return {
"priorityLevelWithMaxLamports": SwapRequestPrioritizationFeeLamportsAnyOfPriorityLevelWithMaxLamportsToJSON(value.priorityLevelWithMaxLamports)
};
}
// generated/models/SwapResponseDynamicSlippageReport.ts
function instanceOfSwapResponseDynamicSlippageReport(value) {
let isInstance = true;
return isInstance;
}
function SwapResponseDynamicSlippageReportFromJSON(json) {
return SwapResponseDynamicSlippageReportFromJSONTyped(json, false);
}
function SwapResponseDynamicSlippageReportFromJSONTyped(json, ignoreDiscriminator) {
if (json === void 0 || json === null) {
return json;
}
return {
"amplificationRatio": !exists(json, "amplificationRatio") ? void 0 : json["amplificationRatio"],
"otherAmount": !exists(json, "otherAmount") ? void 0 : json["otherAmount"],
"simulatedIncurredSlippageBps": !exists(json, "simulatedIncurredSlippageBps") ? void 0 : json["simulatedIncurredSlippageBps"],
"slippageBps": !exists(json, "slippageBps") ? void 0 : json["slippageBps"]
};
}
function SwapResponseDynamicSlippageReportToJSON(value) {
if (value === void 0) {
return void 0;
}
if (value === null) {
return null;
}
return {
"amplificationRatio": value.amplificationRatio,
"otherAmount": value.otherAmount,
"simulatedIncurredSlippageBps": value.simulatedIncurredSlippageBps,
"slippageBps": value.slippageBps
};
}
// generated/models/SwapResponse.ts

@@ -876,3 +1037,4 @@ function instanceOfSwapResponse(value) {

"lastValidBlockHeight": json["lastValidBlockHeight"],
"prioritizationFeeLamports": !exists(json, "prioritizationFeeLamports") ? void 0 : json["prioritizationFeeLamports"]
"prioritizationFeeLamports": !exists(json, "prioritizationFeeLamports") ? void 0 : json["prioritizationFeeLamports"],
"dynamicSlippageReport": !exists(json, "dynamicSlippageReport") ? void 0 : SwapResponseDynamicSlippageReportFromJSON(json["dynamicSlippageReport"])
};

@@ -890,3 +1052,4 @@ }

"lastValidBlockHeight": value.lastValidBlockHeight,
"prioritizationFeeLamports": value.prioritizationFeeLamports
"prioritizationFeeLamports": value.prioritizationFeeLamports,
"dynamicSlippageReport": SwapResponseDynamicSlippageReportToJSON(value.dynamicSlippageReport)
};

@@ -1192,4 +1355,14 @@ }

SwapRequestComputeUnitPriceMicroLamportsToJSON,
SwapRequestDynamicSlippageFromJSON,
SwapRequestDynamicSlippageFromJSONTyped,
SwapRequestDynamicSlippageToJSON,
SwapRequestFromJSON,
SwapRequestFromJSONTyped,
SwapRequestPrioritizationFeeLamportsAnyOfFromJSON,
SwapRequestPrioritizationFeeLamportsAnyOfFromJSONTyped,
SwapRequestPrioritizationFeeLamportsAnyOfPriorityLevelWithMaxLamportsFromJSON,
SwapRequestPrioritizationFeeLamportsAnyOfPriorityLevelWithMaxLamportsFromJSONTyped,
SwapRequestPrioritizationFeeLamportsAnyOfPriorityLevelWithMaxLamportsPriorityLevelEnum,
SwapRequestPrioritizationFeeLamportsAnyOfPriorityLevelWithMaxLamportsToJSON,
SwapRequestPrioritizationFeeLamportsAnyOfToJSON,
SwapRequestPrioritizationFeeLamportsFromJSON,

@@ -1199,2 +1372,5 @@ SwapRequestPrioritizationFeeLamportsFromJSONTyped,

SwapRequestToJSON,
SwapResponseDynamicSlippageReportFromJSON,
SwapResponseDynamicSlippageReportFromJSONTyped,
SwapResponseDynamicSlippageReportToJSON,
SwapResponseFromJSON,

@@ -1218,6 +1394,10 @@ SwapResponseFromJSONTyped,

instanceOfSwapRequestComputeUnitPriceMicroLamports,
instanceOfSwapRequestDynamicSlippage,
instanceOfSwapRequestPrioritizationFeeLamports,
instanceOfSwapRequestPrioritizationFeeLamportsAnyOf,
instanceOfSwapRequestPrioritizationFeeLamportsAnyOfPriorityLevelWithMaxLamports,
instanceOfSwapResponse,
instanceOfSwapResponseDynamicSlippageReport,
mapValues,
querystring
});

22

package.json
{
"name": "@jup-ag/api",
"version": "6.0.26",
"version": "6.0.27-alpha",
"description": "## Generate typescript types from swagger schema",

@@ -9,2 +9,10 @@ "main": "dist/index.js",

"sideEffects": false,
"scripts": {
"dev-swap": "FLOW=swap ts-node ./example/index.ts",
"dev-quote": "FLOW=quote ts-node ./example/index.ts",
"test": "vitest",
"build": "npm run openapi-gen && tsup src/index.ts --dts --format esm,cjs",
"openapi-gen": "openapi-generator-cli generate -i swagger.yaml -o generated -g typescript-fetch --skip-validate-spec --additional-properties=supportsES6=true,typescriptThreePlus=true",
"openapi-gen-rust": "openapi-generator-cli generate -i swagger.yaml -o generated -g rust"
},
"author": "",

@@ -28,11 +36,3 @@ "license": "MIT",

"dist"
],
"scripts": {
"dev-swap": "FLOW=swap ts-node ./example/index.ts",
"dev-quote": "FLOW=quote ts-node ./example/index.ts",
"test": "vitest",
"build": "npm run openapi-gen && tsup src/index.ts --dts --format esm,cjs",
"openapi-gen": "openapi-generator-cli generate -i swagger.yaml -o generated -g typescript-fetch --skip-validate-spec --additional-properties=supportsES6=true,typescriptThreePlus=true",
"openapi-gen-rust": "openapi-generator-cli generate -i swagger.yaml -o generated -g rust"
}
}
]
}

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc