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

# getTokenSupply

> Returns the total supply of an SPL Token type



## OpenAPI

````yaml gettokensupply post /
openapi: 3.1.0
info:
  title: Solana RPC
  version: 1.0.0
  description: Solana RPC HTTP method reference.
servers:
  - url: https://rpc-mainnet.solanatracker.io
    description: Mainnet RPC endpoint
security: []
paths:
  /:
    post:
      summary: Run `getTokenSupply`
      description: Returns the total supply of an SPL Token type
      operationId: gettokensupply
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                jsonrpc:
                  allOf:
                    - type: string
                      enum:
                        - '2.0'
                      description: The JSON-RPC protocol version.
                      example: '2.0'
                      default: '2.0'
                id:
                  allOf:
                    - type: string
                      description: A unique identifier for the request.
                      example: '1'
                      default: '1'
                method:
                  allOf:
                    - type: string
                      enum:
                        - getTokenSupply
                      description: The name of the RPC method to invoke.
                      example: getTokenSupply
                      default: getTokenSupply
                params:
                  allOf:
                    - type: array
                      description: Parameters for querying the token supply.
                      default:
                        - 7xKXtg2CW87d97TXJSDpbD5jBkheTqA83TZRuJosgAsU
                      items:
                        oneOf:
                          - type: string
                            description: >-
                              Solana token mint address to retrieve supply
                              metrics for (SPL token's unique identifier).
                            example: 7xKXtg2CW87d97TXJSDpbD5jBkheTqA83TZRuJosgAsU
                          - type: object
                            description: Configuration object.
                            properties:
                              commitment:
                                type: string
                                description: The commitment level for the request.
                                enum:
                                  - confirmed
                                  - finalized
                                  - processed
                                example: finalized
              required:
                - jsonrpc
                - id
                - method
                - params
            examples:
              requestExample:
                value:
                  jsonrpc: '2.0'
                  id: db16f277-1a22-41ff-9f85-f37e2cd77900
                  method: getTokenSupply
                  params:
                    - 7xKXtg2CW87d97TXJSDpbD5jBkheTqA83TZRuJosgAsU
      responses:
        '200':
          description: Successfully retrieved the token supply.
          content:
            application/json:
              schema:
                type: object
                properties:
                  jsonrpc:
                    allOf:
                      - type: string
                        enum:
                          - '2.0'
                        description: The JSON-RPC protocol version.
                        example: '2.0'
                  id:
                    allOf:
                      - type: string
                        description: Identifier matching the request.
                        example: '1'
                  result:
                    allOf:
                      - type: object
                        description: Context and token supply details.
                        properties:
                          context:
                            type: object
                            description: Context of the response.
                            properties:
                              slot:
                                type: integer
                                description: Slot in which the data was fetched.
                                example: 1114
                          value:
                            type: object
                            description: Token supply details.
                            properties:
                              amount:
                                type: string
                                description: >-
                                  The raw total Solana token supply as a precise
                                  integer string without decimal formatting.
                                example: '100000'
                              decimals:
                                type: integer
                                description: >-
                                  Number of decimal places defined by the token
                                  for accurate supply representation.
                                example: 2
                              uiAmount:
                                type: number
                                description: >-
                                  The human-readable token supply with proper
                                  decimal formatting (deprecated).
                                example: 1000
                              uiAmountString:
                                type: string
                                description: >-
                                  The canonical string representation of the
                                  total token supply with correct decimal
                                  places.
                                example: '1000'
              examples:
                responseExample:
                  value:
                    jsonrpc: '2.0'
                    id: db16f277-1a22-41ff-9f85-f37e2cd77900
                    result:
                      context:
                        slot: 1114
                      value:
                        amount: '100000'
                        decimals: 2
                        uiAmount: 1000
                        uiAmountString: '1000'
      security:
        - ApiKeyQuery: []
components:
  securitySchemes:
    ApiKeyQuery:
      type: apiKey
      in: query
      name: api_key

````