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

# Get token

> Returns one Sunrise-supported Solana token by mint address. Pass "native" for SOL, the native Solana token. Includes the linked stock when available. Earnings, shares, dividends and market cap are all included for keys with stock data access when no flag is passed; once any flag is passed, only sections set to true are included. Sections that fail to load are omitted.



## OpenAPI

````yaml https://api.sunrise.xyz/openapi get /v1/tokens/{address}
openapi: 3.1.0
info:
  title: Sunrise API
  description: >-
    Authenticated API for Sunrise.


    Errors carry a `code`; each code means one next step (see the Errors page).
    New codes may be added: for a code you don't know, get a new quote on a 409,
    and send the same request again on a 5xx from execute.


    A path that doesn't exist answers 404 `not_found`, and a method a path
    doesn't take answers 405 `method_not_allowed`.
  version: 1.0.0
servers:
  - url: https://api.sunrise.xyz
security:
  - bearerAuth: []
paths:
  /v1/tokens/{address}:
    get:
      tags:
        - Tokens
      summary: Get token
      description: >-
        Returns one Sunrise-supported Solana token by mint address. Pass
        "native" for SOL, the native Solana token. Includes the linked stock
        when available. Earnings, shares, dividends and market cap are all
        included for keys with stock data access when no flag is passed; once
        any flag is passed, only sections set to true are included. Sections
        that fail to load are omitted.
      operationId: getToken
      parameters:
        - in: path
          name: address
          schema:
            type: string
          required: true
          description: Solana mint address, or "native" for SOL.
        - in: query
          name: includeEarnings
          schema:
            enum:
              - 'true'
              - 'false'
            type: string
          description: >-
            When true, include the four most recently reported and the next
            upcoming earnings for the linked stock. When no flag is passed,
            every section is included for keys with stock data access; once any
            flag is passed, only sections set to true are included. Omitted for
            tokens without a linked stock or when the section fails to load.
        - in: query
          name: includeShares
          schema:
            enum:
              - 'true'
              - 'false'
            type: string
          description: >-
            When true, include the linked stock's latest shares outstanding.
            When no flag is passed, every section is included for keys with
            stock data access; once any flag is passed, only sections set to
            true are included. Omitted for tokens without a linked stock or when
            the section fails to load.
        - in: query
          name: includeDividends
          schema:
            enum:
              - 'true'
              - 'false'
            type: string
          description: >-
            When true, include the linked stock's recent dividends. When no flag
            is passed, every section is included for keys with stock data
            access; once any flag is passed, only sections set to true are
            included. Omitted for tokens without a linked stock or when the
            section fails to load.
        - in: query
          name: includeMarketCap
          schema:
            enum:
              - 'true'
              - 'false'
            type: string
          description: >-
            When true, include the linked stock's market capitalization. When no
            flag is passed, every section is included for keys with stock data
            access; once any flag is passed, only sections set to true are
            included. Omitted for tokens without a linked stock or when the
            section fails to load.
      responses:
        '200':
          description: The requested token.
          content:
            application/json:
              schema:
                type: object
                properties:
                  success:
                    enum:
                      - true
                    type: boolean
                  data:
                    type: object
                    properties:
                      token:
                        type: object
                        properties:
                          chain:
                            type: string
                            description: Blockchain where the token is issued.
                          address:
                            type: string
                            description: Solana mint address.
                          symbol:
                            type: string
                            description: Token ticker symbol.
                          name:
                            type: string
                            description: Display name of the token.
                          decimals:
                            type: integer
                            minimum: 0
                            description: Number of decimal places used by the token.
                          platform:
                            type: string
                            description: Platform associated with the token.
                          assetClass:
                            type: string
                            description: Asset classification of the token.
                          issuer:
                            anyOf:
                              - type: string
                              - type: 'null'
                            description: Issuer associated with the token, when available.
                          icon:
                            anyOf:
                              - type: string
                              - type: 'null'
                            description: Token icon URL, when available.
                          tokenProgram:
                            anyOf:
                              - type: string
                              - type: 'null'
                            description: Solana token program address, when available.
                          stock:
                            anyOf:
                              - type: object
                                properties:
                                  ticker:
                                    type: string
                                    description: Ticker of the linked stock.
                                  currency:
                                    anyOf:
                                      - type: string
                                      - type: 'null'
                                    description: >-
                                      Currency associated with the linked stock,
                                      when available.
                                  exchange:
                                    anyOf:
                                      - type: object
                                        properties:
                                          marketIdentifierCode:
                                            type: string
                                            description: Market Identifier Code for the exchange.
                                          name:
                                            type: string
                                            description: Display name of the exchange.
                                        required:
                                          - marketIdentifierCode
                                          - name
                                      - type: 'null'
                                    description: >-
                                      Exchange where the linked stock is listed,
                                      when available.
                                  earnings:
                                    type: array
                                    items:
                                      anyOf:
                                        - type: object
                                          properties:
                                            fiscalPeriodEndDate:
                                              type: string
                                              format: date
                                            reportDate:
                                              type: string
                                              format: date
                                            reportSession:
                                              enum:
                                                - pre-market
                                                - post-market
                                                - during-market
                                                - unknown
                                              type: string
                                            eps:
                                              type: object
                                              properties:
                                                reported:
                                                  type: number
                                                  description: Reported earnings per share.
                                                estimated:
                                                  anyOf:
                                                    - type: number
                                                    - type: 'null'
                                                  description: >-
                                                    Consensus EPS estimate, or null when
                                                    unavailable.
                                                surpriseAmount:
                                                  anyOf:
                                                    - type: number
                                                    - type: 'null'
                                                  description: >-
                                                    Reported minus estimated EPS, or null
                                                    without an estimate.
                                                surprisePercent:
                                                  anyOf:
                                                    - type: number
                                                    - type: 'null'
                                                  description: >-
                                                    EPS surprise as a percentage of the
                                                    estimate, or null without an estimate or
                                                    when the estimate is within 0.05 of
                                                    zero.
                                              required:
                                                - reported
                                                - estimated
                                                - surpriseAmount
                                                - surprisePercent
                                          required:
                                            - fiscalPeriodEndDate
                                            - reportDate
                                            - reportSession
                                            - eps
                                        - type: object
                                          properties:
                                            fiscalPeriodEndDate:
                                              type: string
                                              format: date
                                            reportDate:
                                              type: string
                                              format: date
                                            reportSession:
                                              enum:
                                                - pre-market
                                                - post-market
                                                - during-market
                                                - unknown
                                              type: string
                                            eps:
                                              type: object
                                              properties:
                                                reported:
                                                  type: 'null'
                                                  description: Null until the company reports.
                                                estimated:
                                                  anyOf:
                                                    - type: number
                                                    - type: 'null'
                                                  description: >-
                                                    Consensus EPS estimate, or null when
                                                    unavailable.
                                                surpriseAmount:
                                                  type: 'null'
                                                  description: Null until the company reports.
                                                surprisePercent:
                                                  type: 'null'
                                                  description: Null until the company reports.
                                              required:
                                                - reported
                                                - estimated
                                                - surpriseAmount
                                                - surprisePercent
                                          required:
                                            - fiscalPeriodEndDate
                                            - reportDate
                                            - reportSession
                                            - eps
                                    maxItems: 5
                                    description: >-
                                      Up to the four most recently reported
                                      quarters, oldest first, then the next
                                      scheduled report when one is known. Only
                                      that last entry can have eps.reported
                                      null.
                                  dividends:
                                    type: array
                                    items:
                                      type: object
                                      properties:
                                        exDividendDate:
                                          type: string
                                          format: date
                                        declarationDate:
                                          anyOf:
                                            - type: string
                                              format: date
                                            - type: 'null'
                                        recordDate:
                                          anyOf:
                                            - type: string
                                              format: date
                                            - type: 'null'
                                        paymentDate:
                                          anyOf:
                                            - type: string
                                              format: date
                                            - type: 'null'
                                        amountPerShare:
                                          type: number
                                          minimum: 0
                                      required:
                                        - exDividendDate
                                        - declarationDate
                                        - recordDate
                                        - paymentDate
                                        - amountPerShare
                                    description: Recent dividends, newest first.
                                  shares:
                                    type: object
                                    properties:
                                      outstanding:
                                        anyOf:
                                          - type: object
                                            properties:
                                              date:
                                                type: string
                                                format: date
                                              basic:
                                                anyOf:
                                                  - type: number
                                                  - type: 'null'
                                              diluted:
                                                anyOf:
                                                  - type: number
                                                  - type: 'null'
                                            required:
                                              - date
                                              - basic
                                              - diluted
                                          - type: 'null'
                                        description: >-
                                          Latest reported shares outstanding, or
                                          null when unavailable.
                                    required:
                                      - outstanding
                                  marketCap:
                                    type: number
                                    minimum: 0
                                    description: Market capitalization of the linked stock.
                                required:
                                  - ticker
                                  - currency
                                  - exchange
                              - type: 'null'
                            description: Linked stock, or null for tokens without one.
                        required:
                          - chain
                          - address
                          - symbol
                          - name
                          - decimals
                          - platform
                          - assetClass
                          - issuer
                          - icon
                          - tokenProgram
                          - stock
                    required:
                      - token
                  timestamp:
                    type: string
                  requestId:
                    type: string
                    description: >-
                      Identifies this request; also sent as the X-Request-Id
                      header. Quote it when asking Sunrise about a request.
                required:
                  - success
                  - data
                  - timestamp
                  - requestId
        '400':
          description: |-
            invalid_request: A field or parameter is wrong or missing.
            invalid_token: A token address is not valid for the chain.
          x-codes:
            - invalid_request
            - invalid_token
          content:
            application/json:
              schema:
                type: object
                properties:
                  success:
                    enum:
                      - false
                    type: boolean
                  error:
                    type: object
                    properties:
                      code:
                        type: string
                        description: >-
                          One of the codes this response lists in its
                          description and x-codes.
                      message:
                        type: string
                      details:
                        type: object
                        properties:
                          txHash:
                            type: string
                            description: >-
                              The hash of the order's transaction, which was
                              sent to the chain.
                          fields:
                            type: array
                            items:
                              type: string
                            description: The request fields that aren't valid.
                        required: []
                        additionalProperties: false
                    required:
                      - code
                      - message
                    additionalProperties: false
                  requestId:
                    type: string
                    description: >-
                      Identifies this request; also sent as the X-Request-Id
                      header. Quote it when asking Sunrise about a request.
                  timestamp:
                    type: string
                required:
                  - success
                  - error
                  - requestId
                  - timestamp
                additionalProperties: false
        '401':
          description: 'unauthorized: The API key is missing or invalid.'
          x-codes:
            - unauthorized
          content:
            application/json:
              schema:
                type: object
                properties:
                  success:
                    enum:
                      - false
                    type: boolean
                  error:
                    type: object
                    properties:
                      code:
                        type: string
                        description: >-
                          One of the codes this response lists in its
                          description and x-codes.
                      message:
                        type: string
                      details:
                        type: object
                        properties:
                          txHash:
                            type: string
                            description: >-
                              The hash of the order's transaction, which was
                              sent to the chain.
                          fields:
                            type: array
                            items:
                              type: string
                            description: The request fields that aren't valid.
                        required: []
                        additionalProperties: false
                    required:
                      - code
                      - message
                    additionalProperties: false
                  requestId:
                    type: string
                    description: >-
                      Identifies this request; also sent as the X-Request-Id
                      header. Quote it when asking Sunrise about a request.
                  timestamp:
                    type: string
                required:
                  - success
                  - error
                  - requestId
                  - timestamp
                additionalProperties: false
        '403':
          description: 'forbidden: The key can''t make this request or use this route.'
          x-codes:
            - forbidden
          content:
            application/json:
              schema:
                type: object
                properties:
                  success:
                    enum:
                      - false
                    type: boolean
                  error:
                    type: object
                    properties:
                      code:
                        type: string
                        description: >-
                          One of the codes this response lists in its
                          description and x-codes.
                      message:
                        type: string
                      details:
                        type: object
                        properties:
                          txHash:
                            type: string
                            description: >-
                              The hash of the order's transaction, which was
                              sent to the chain.
                          fields:
                            type: array
                            items:
                              type: string
                            description: The request fields that aren't valid.
                        required: []
                        additionalProperties: false
                    required:
                      - code
                      - message
                    additionalProperties: false
                  requestId:
                    type: string
                    description: >-
                      Identifies this request; also sent as the X-Request-Id
                      header. Quote it when asking Sunrise about a request.
                  timestamp:
                    type: string
                required:
                  - success
                  - error
                  - requestId
                  - timestamp
                additionalProperties: false
        '404':
          description: 'not_found: The path or token does not exist.'
          x-codes:
            - not_found
          content:
            application/json:
              schema:
                type: object
                properties:
                  success:
                    enum:
                      - false
                    type: boolean
                  error:
                    type: object
                    properties:
                      code:
                        type: string
                        description: >-
                          One of the codes this response lists in its
                          description and x-codes.
                      message:
                        type: string
                      details:
                        type: object
                        properties:
                          txHash:
                            type: string
                            description: >-
                              The hash of the order's transaction, which was
                              sent to the chain.
                          fields:
                            type: array
                            items:
                              type: string
                            description: The request fields that aren't valid.
                        required: []
                        additionalProperties: false
                    required:
                      - code
                      - message
                    additionalProperties: false
                  requestId:
                    type: string
                    description: >-
                      Identifies this request; also sent as the X-Request-Id
                      header. Quote it when asking Sunrise about a request.
                  timestamp:
                    type: string
                required:
                  - success
                  - error
                  - requestId
                  - timestamp
                additionalProperties: false
        '429':
          description: >-
            rate_limited: Too many requests; see Retry-After.

            verification_rate_limited: The API key's verification budget is used
            up; see Retry-After.
          x-codes:
            - rate_limited
            - verification_rate_limited
          content:
            application/json:
              schema:
                type: object
                properties:
                  success:
                    enum:
                      - false
                    type: boolean
                  error:
                    type: object
                    properties:
                      code:
                        type: string
                        description: >-
                          One of the codes this response lists in its
                          description and x-codes.
                      message:
                        type: string
                      details:
                        type: object
                        properties:
                          txHash:
                            type: string
                            description: >-
                              The hash of the order's transaction, which was
                              sent to the chain.
                          fields:
                            type: array
                            items:
                              type: string
                            description: The request fields that aren't valid.
                        required: []
                        additionalProperties: false
                    required:
                      - code
                      - message
                    additionalProperties: false
                  requestId:
                    type: string
                    description: >-
                      Identifies this request; also sent as the X-Request-Id
                      header. Quote it when asking Sunrise about a request.
                  timestamp:
                    type: string
                required:
                  - success
                  - error
                  - requestId
                  - timestamp
                additionalProperties: false
          headers:
            X-Sunrise-RateLimit-Scope:
              description: >-
                Local per-key verification budget exceeded; back off requests
                for this key.
              schema:
                type: string
                enum:
                  - key
            Retry-After:
              description: Seconds to wait; present for local verification throttling.
              schema:
                type: integer
                example: 60
        '500':
          description: 'internal_error: An unexpected error in the Sunrise API.'
          x-codes:
            - internal_error
          content:
            application/json:
              schema:
                type: object
                properties:
                  success:
                    enum:
                      - false
                    type: boolean
                  error:
                    type: object
                    properties:
                      code:
                        type: string
                        description: >-
                          One of the codes this response lists in its
                          description and x-codes.
                      message:
                        type: string
                      details:
                        type: object
                        properties:
                          txHash:
                            type: string
                            description: >-
                              The hash of the order's transaction, which was
                              sent to the chain.
                          fields:
                            type: array
                            items:
                              type: string
                            description: The request fields that aren't valid.
                        required: []
                        additionalProperties: false
                    required:
                      - code
                      - message
                    additionalProperties: false
                  requestId:
                    type: string
                    description: >-
                      Identifies this request; also sent as the X-Request-Id
                      header. Quote it when asking Sunrise about a request.
                  timestamp:
                    type: string
                required:
                  - success
                  - error
                  - requestId
                  - timestamp
                additionalProperties: false
        '502':
          description: 'bad_gateway: A service behind the API failed.'
          x-codes:
            - bad_gateway
          content:
            application/json:
              schema:
                type: object
                properties:
                  success:
                    enum:
                      - false
                    type: boolean
                  error:
                    type: object
                    properties:
                      code:
                        type: string
                        description: >-
                          One of the codes this response lists in its
                          description and x-codes.
                      message:
                        type: string
                      details:
                        type: object
                        properties:
                          txHash:
                            type: string
                            description: >-
                              The hash of the order's transaction, which was
                              sent to the chain.
                          fields:
                            type: array
                            items:
                              type: string
                            description: The request fields that aren't valid.
                        required: []
                        additionalProperties: false
                    required:
                      - code
                      - message
                    additionalProperties: false
                  requestId:
                    type: string
                    description: >-
                      Identifies this request; also sent as the X-Request-Id
                      header. Quote it when asking Sunrise about a request.
                  timestamp:
                    type: string
                required:
                  - success
                  - error
                  - requestId
                  - timestamp
                additionalProperties: false
        '503':
          description: 'service_unavailable: A service is temporarily unavailable.'
          x-codes:
            - service_unavailable
          content:
            application/json:
              schema:
                type: object
                properties:
                  success:
                    enum:
                      - false
                    type: boolean
                  error:
                    type: object
                    properties:
                      code:
                        type: string
                        description: >-
                          One of the codes this response lists in its
                          description and x-codes.
                      message:
                        type: string
                      details:
                        type: object
                        properties:
                          txHash:
                            type: string
                            description: >-
                              The hash of the order's transaction, which was
                              sent to the chain.
                          fields:
                            type: array
                            items:
                              type: string
                            description: The request fields that aren't valid.
                        required: []
                        additionalProperties: false
                    required:
                      - code
                      - message
                    additionalProperties: false
                  requestId:
                    type: string
                    description: >-
                      Identifies this request; also sent as the X-Request-Id
                      header. Quote it when asking Sunrise about a request.
                  timestamp:
                    type: string
                required:
                  - success
                  - error
                  - requestId
                  - timestamp
                additionalProperties: false
components:
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.