Skip to main content

Getting Started with Gas Station API

The Altude Gas Station API provides a simple, powerful way to interact with the Solana blockchain. Whether you’re building a mobile app, web application, or backend service, our API handles the complexity of blockchain interactions so you can focus on building great user experiences.

What is the Gas Station API?

The Gas Station API is a RESTful web service that abstracts away the complexities of direct Solana blockchain interaction. It provides:
  • Account Management: Create, query, and manage Solana accounts
  • Transaction Processing: Send individual or batch transactions
  • Balance Queries: Check token balances across different mints
  • Transaction History: Retrieve detailed account transaction history
  • Simplified Authentication: Easy API key-based authentication

Quick Setup

Step 1: Create Your Account

Before you can use the API, you’ll need to register for an account and get your API credentials:
  1. Visit the Dashboard: Go to https://dashboard.altude.so
  2. Register Your Account: Fill out the registration form with your details
  3. Verify Your Email: Check your email and verify your account
  4. Access the Dashboard: Log in to your new dashboard
  5. Create an App: Register your application to get API credentials
  6. Get Your API Key: Copy your unique API key for authentication
Important: Keep your API key secure and never expose it in client-side code. Always use it from your backend services.

Step 2: Make Your First API Call

Once you have your API key, you can start making requests to the Gas Station API:
curl -X POST "https://api.altude.so/api/Account/balance" \
  -H "X-API-Key: YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "accountAddress": "YOUR_ACCOUNT_ADDRESS",
    "mintAddress": "EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v"
  }'

Step 3: Explore the Endpoints

The Gas Station API is organized into two main categories:

Authentication

All API requests require authentication using your API key in the X-API-Key header:
X-API-Key: YOUR_API_KEY

Base URL

All API requests should be made to:
https://api.altude.so

Common Use Cases

Check Account Balance

Perfect for wallet applications and balance displays:
const response = await fetch('https://api.altude.so/api/Account/balance', {
  method: 'POST',
  headers: {
    'X-API-Key': 'YOUR_API_KEY',
    'Content-Type': 'application/json'
  },
  body: JSON.stringify({
    accountAddress: 'your_account_address',
    mintAddress: 'EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v' // USDC
  })
});

Send a Transaction

For payment processing and token transfers:
const response = await fetch('https://api.altude.so/api/Transaction/send', {
  method: 'POST',
  headers: {
    'X-API-Key': 'YOUR_API_KEY',
    'Content-Type': 'application/json'
  },
  body: JSON.stringify({
    signedTransaction: 'base64_encoded_signed_transaction'
  })
});

Batch Transactions

For efficient bulk operations:
const response = await fetch('https://api.altude.so/api/Transaction/sendbatch', {
  method: 'POST',
  headers: {
    'X-API-Key': 'YOUR_API_KEY',
    'Content-Type': 'application/json'
  },
  body: JSON.stringify({
    signedTransaction: 'base64_encoded_batch_transaction'
  })
});

Error Handling

The API uses standard HTTP status codes and returns JSON error responses:
{
  "error": "Invalid account address",
  "code": 400,
  "details": "The provided account address is not a valid Solana public key"
}
Common status codes:
  • 200: Success
  • 400: Bad Request (invalid parameters)
  • 401: Unauthorized (invalid API key)
  • 404: Not Found (resource doesn’t exist)
  • 500: Internal Server Error

Rate Limits

The API includes rate limiting to ensure fair usage:
  • Default: 1000 requests per minute
  • Burst: Up to 100 requests per second
Rate limit headers are included in all responses:
  • X-RateLimit-Limit: Requests allowed per window
  • X-RateLimit-Remaining: Requests remaining in current window
  • X-RateLimit-Reset: Time when the rate limit resets

SDKs Available

While you can use the API directly with HTTP requests, we also provide SDKs for easier integration:
  • Android/Kotlin SDK: Native Android development
  • TypeScript/JavaScript: Coming soon
  • Python: Coming soon
  • Unity: Coming soon

Next Steps

  1. Explore Account Endpoints: Learn about account management operations
  2. Explore Transaction Endpoints: Discover transaction processing capabilities
  3. Converting from Kinetic: If you’re migrating from Kinetic API

Need Help?

  • Documentation: Explore the detailed API reference for each endpoint
  • Support: Contact us at andrew@altude.so
  • Community: Join our Discord for developer support
Ready to build? Get your API key today and start integrating with the Solana blockchain in minutes!
I