Merge pull request #167 from GMGNAI/feat-quote-exist-auth

docs(order-quote): order quote now uses normal auth, no private key needed
This commit is contained in:
GMGN.AI
2026-06-24 16:21:20 +08:00
committed by GitHub
5 changed files with 14 additions and 14 deletions
+1 -1
View File
@@ -475,7 +475,7 @@ export class OpenApiClient {
slippage: number
): Promise<unknown> {
const query = { chain, from_address, input_token, output_token, input_amount, slippage };
return this.authSignedRequest("GET", "/v1/trade/quote", query, null);
return this.authExistRequest("GET", "/v1/trade/quote", query);
}
// ---- Swap endpoints (signed auth) ----
+3 -3
View File
@@ -149,9 +149,9 @@ export function registerSwapCommands(program: Command): void {
order
.command("quote")
.description("Get a swap quote without submitting a transaction (signed auth — requires GMGN_PRIVATE_KEY)")
.requiredOption("--chain <chain>", "Chain: sol / bsc / base / eth (requires GMGN_PRIVATE_KEY)")
.requiredOption("--from <address>", "Wallet address (must match API Key binding)")
.description("Get a swap quote without submitting a transaction (exist auth — GMGN_API_KEY only, no private key needed)")
.requiredOption("--chain <chain>", "Chain: sol / bsc / base / eth")
.requiredOption("--from <address>", "Wallet address")
.requiredOption("--input-token <address>", "Input token contract address")
.requiredOption("--output-token <address>", "Output token contract address")
.requiredOption("--amount <amount>", "Input amount (smallest unit)")