CtrlK
BlogDocsLog inGet started
Tessl Logo

tessl-skill-index-evals/jup-ag__agent-skills__integrating-jupiter

Comprehensive guidance for integrating Jupiter APIs (Ultra Swap, Lend, Perps, Trigger, Recurring, Tokens, Price, Portfolio, Prediction Markets, Send, Studio, Lock, Routing).

86

1.85x

Quality

84%

Does it follow best practices?

Impact

91%

1.85x

Average score across 5 eval scenarios

Overview
Skills
Evals
Files

task.mdevals/scenario-1/

Ultra Swap Integration Module

Problem/Feature Description

You are building a backend service for a Solana trading bot that needs to execute token swaps. The service should provide a clean TypeScript module that handles the complete lifecycle of a swap: getting a quote/order, signing the transaction, and executing it.

The module needs to be production-grade, meaning it must handle authentication, enforce sensible timeouts, validate inputs before making API calls, handle various error scenarios gracefully, and provide structured logging for debugging and monitoring. The trading bot will be used by multiple users concurrently, so rate limit handling is important.

The swap execution should be resilient: if a network error occurs during execution, the system should be able to safely retry without risking duplicate swaps. The module should also enforce configurable safety limits on slippage and maximum trade amounts.

Output Specification

Produce a single TypeScript file called ultra-swap.ts that exports:

  1. A configured HTTP client/fetch wrapper for Jupiter API calls with proper authentication and timeout handling
  2. A getSwapOrder(params: { inputMint: string, outputMint: string, amount: string, walletAddress: string }) function that fetches a swap order
  3. A executeSwap(orderResponse: any, wallet: Keypair) function that signs and executes the swap
  4. A swap(params: { inputMint: string, outputMint: string, amount: string }, wallet: Keypair) function that orchestrates the full flow
  5. Proper error handling with structured error types that indicate whether errors are retryable
  6. Rate limit handling with backoff logic
  7. Structured logging that captures relevant request metadata

The code should use @solana/web3.js types (Keypair, VersionedTransaction, Connection) and the native fetch API. It does not need to compile or run -- focus on correct API integration patterns and robust error handling.

Install with Tessl CLI

npx tessl i tessl-skill-index-evals/jup-ag__agent-skills__integrating-jupiter@0.0.1

evals

scenario-1

rubric.json

task.md

tile.json