> ## Documentation Index
> Fetch the complete documentation index at: https://docs.raydium.io/llms.txt
> Use this file to discover all available pages before exploring further.

# Get estimated transaction fees

> Retrieve estimated on-chain costs (lamports). Cached 60 seconds.



## OpenAPI

````yaml /api-reference/openapi/api-v3.yaml get /main/auto-fee
openapi: 3.0.3
info:
  title: Raydium API v3
  version: 3.0.0
  description: >-
    The Raydium API v3 provides REST endpoints for querying liquidity pools,
    mint information, farm details, IDO pools, and chain metadata for the Solana
    blockchain. Used by wallets, aggregators, and traders to source price feeds,
    pool data, and routing information.
servers:
  - url: https://api-v3.raydium.io
    description: Production (Mainnet)
  - url: https://api-v3-devnet.raydium.io
    description: Development (Devnet)
security: []
tags:
  - name: Main
    description: Core API endpoints for chain info, TVL, and configuration
  - name: Mint
    description: Token mint information and pricing
  - name: Pools
    description: Liquidity pool info, keys, and historical data
  - name: Farms
    description: Farm pool information and keys
  - name: IDO
    description: IDO pool information and keys
paths:
  /main/auto-fee:
    get:
      tags:
        - Main
      summary: Get estimated transaction fees
      description: Retrieve estimated on-chain costs (lamports). Cached 60 seconds.
      operationId: getMainAutoFee
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                allOf:
                  - $ref: '#/components/schemas/ApiResponse'
                  - type: object
                    properties:
                      data:
                        type: object
components:
  schemas:
    ApiResponse:
      type: object
      description: >-
        Common response envelope. The `data` field is supplied by each
        endpoint's response schema via `allOf` and is therefore not declared on
        the base envelope.
      required:
        - id
        - success
      properties:
        id:
          type: string
          description: Request ID (UUID)
        success:
          type: boolean
          description: Whether the request was successful
        msg:
          type: string
          description: Error message if success is false

````