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

# Create Vote Request

> Create an unsigned vote transaction for TRX staking.



## OpenAPI

````yaml POST /api/v1/tron/{network}/staking/vote
openapi: 3.0.0
info:
  title: Staking API
  description: API used for staking
  version: 1.0.0
  contact: {}
servers:
  - url: https://api.p2p.org/api
security:
  - bearer: []
tags:
  - name: Aptos
    description: Aptos staking operations (stake, unstake, withdraw, claim).
  - name: Celestia
    description: Celestia staking operations (stake, unstake, redelegate, claim).
  - name: Cosmos
    description: Cosmos Hub staking operations (stake, unstake, redelegate, claim).
  - name: EigenLayer
    description: EigenLayer restaking operations.
  - name: Ethereum
    description: Ethereum staking operations (direct, SSV, pooled).
  - name: Hyperliquid
    description: Hyperliquid staking operations.
  - name: Monad
    description: Monad staking operations (delegate, undelegate, withdraw).
  - name: P2P SSV
    description: P2P-managed SSV validator operations (deposit, claim, withdraw).
  - name: Polkadot
    description: Polkadot staking and nomination pool operations.
  - name: Polygon
    description: Polygon staking operations.
  - name: Pooled Staking
    description: Pooled staking vault operations (deposit, unstake, withdraw).
  - name: Sei
    description: Sei staking operations (stake, unstake, redelegate, claim).
  - name: Solana
    description: Solana staking operations (stake, split, merge, deactivate, withdraw).
  - name: SSV
    description: SSV network validator operations.
  - name: Story
    description: Story network staking operations.
  - name: Sui
    description: Sui staking operations.
  - name: TON
    description: TON staking operations (single nominator, whales pool).
  - name: TRON
    description: TRON staking operations (freeze, delegate, vote, withdraw).
  - name: Unified
    description: Unified multi-chain staking interface.
paths:
  /api/v1/tron/{network}/staking/vote:
    post:
      tags:
        - TRON
      summary: Create Vote Request
      description: Create an unsigned vote transaction for TRX staking.
      operationId: tron-staking-vote
      parameters:
        - name: network
          required: true
          in: path
          description: >-
            <p>TRON network:</p><ul><li>`mainnet` — TRON
            mainnet.</li><li>`testnet-nile` — TRON testnet.</li></ul>
          schema:
            enum:
              - mainnet
              - testnet-nile
            type: string
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/TronVoteRequest'
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                allOf:
                  - $ref: '#/components/schemas/SuccessResponse'
                  - type: object
                    properties:
                      result:
                        $ref: '#/components/schemas/TronVoteResponse'
        '400':
          description: Bad request
          content:
            application/json:
              schema:
                allOf:
                  - $ref: '#/components/schemas/ExceptionResponse'
                  - type: object
                    properties:
                      error:
                        oneOf:
                          - $ref: >-
                              #/components/schemas/TronInvalidDelegatorAddressException
                          - $ref: '#/components/schemas/TronGetAccountFailedException'
                          - $ref: >-
                              #/components/schemas/TronVoteWithoutFrozenBalanceException
                          - $ref: '#/components/schemas/TronInvalidVoteCountException'
                          - $ref: '#/components/schemas/TronVoteTransactionException'
              examples:
                InvalidDelegatorAddressException:
                  value:
                    error:
                      code: 125102
                      message: >-
                        Invalid delegator address provided. Please ensure the
                        address is a valid TRON address format.
                      name: InvalidDelegatorAddressException
                      type: client
                    result: null
                GetAccountFailedException:
                  value:
                    error:
                      code: 125103
                      message: >-
                        Delegator account is not activated or does not exist
                        on-chain. Please fund the account before proceeding.
                      name: GetAccountFailedException
                      type: client
                    result: null
                VoteWithoutFrozenBalanceException:
                  value:
                    error:
                      code: 125109
                      message: >-
                        Delegator does not have any frozen TRX available for
                        voting. Please freeze TRX before attempting to vote.
                      name: VoteWithoutFrozenBalanceException
                      type: client
                    result: null
                InvalidVoteCountException:
                  value:
                    error:
                      code: 125110
                      message: 'Invalid vote count: %s. Allowed range is from %s to %s.'
                      name: InvalidVoteCountException
                      type: client
                    result: null
                VoteTransactionException:
                  value:
                    error:
                      code: 125116
                      message: >-
                        An error occurred while constructing or broadcasting the
                        vote transaction. Ensure the vote count and SR address
                        are valid.
                      name: VoteTransactionException
                      type: client
                    result: null
        '401':
          description: Unauthorized
          content:
            application/json:
              schema:
                allOf:
                  - $ref: '#/components/schemas/ExceptionResponse'
                  - type: object
                    properties:
                      error:
                        oneOf:
                          - $ref: '#/components/schemas/AuthNoTokenException'
                          - $ref: '#/components/schemas/AuthWrongTokenException'
              examples:
                NoTokenException:
                  value:
                    error:
                      code: 101111
                      message: >-
                        No Bearer token has been provided. To obtain an
                        authentication token, follow the instructions at
                        https://docs.p2p.org/docs/authentication.
                      name: NoTokenException
                      type: authentication
                    result: null
                WrongTokenException:
                  value:
                    error:
                      code: 101109
                      message: >-
                        An invalid Bearer token has been provided. Please
                        specify the correct authentication token.
                      name: WrongTokenException
                      type: authentication
                    result: null
        '429':
          $ref: '#/components/responses/TooManyRequests'
      security:
        - bearer: []
components:
  schemas:
    TronVoteRequest:
      type: object
      properties:
        delegatorAddress:
          type: string
          format: tron-address
          description: Delegator account address used for freezing tokens.
          example: TNDzfERDpxLDS2w1q6yaFC7pzqaSQ3Bg3r
          nullable: false
        voteCount:
          type: integer
          description: >-
            Number of votes to add to the default vote account. Existing votes
            (including votes for other validators) are preserved and this amount
            is added on top. Omit this field to delegate all remaining available
            votes.
          example: 5
          minimum: 1
          format: int32
      required:
        - delegatorAddress
    SuccessResponse:
      type: object
      properties:
        error:
          type: object
          nullable: true
          default: null
          description: Error object. Always null on successful responses.
        result:
          type: object
          description: Response payload containing the requested data.
      description: Standard API success response envelope wrapping the result payload.
      required:
        - error
        - result
    TronVoteResponse:
      type: object
      properties:
        delegatorAddress:
          type: string
          format: tron-address
          description: Delegator account address.
          example: TNDzfERDpxLDS2w1q6yaFC7pzqaSQ3Bg3r
          nullable: false
        voteAccount:
          type: string
          description: Vote account address receiving the delegation.
          example: TXYZ...abc
        voteCount:
          type: integer
          format: int32
          description: Number of votes delegated to the vote account.
          example: 10
        unsignedTransaction:
          type: object
          description: Original unsigned transaction object returned by tronWeb.
          additionalProperties: false
        unsignedTransactionSerialized:
          type: string
          description: >-
            Unsigned serialized transaction in Base64 encrypted format ready for
            signing.
          example: eyJ0eElEIjoidHJ4SWQifQ==
        createdAt:
          type: string
          format: date-time
          description: Timestamp of the transaction in the ISO 8601 format.
          example: '2025-06-03T12:00:00.000Z'
          readOnly: true
      required:
        - delegatorAddress
        - voteAccount
        - voteCount
        - unsignedTransaction
        - unsignedTransactionSerialized
        - createdAt
    ExceptionResponse:
      type: object
      properties:
        error:
          type: object
          description: Error object containing exception details. Null on success.
        result:
          type: object
          nullable: true
          default: null
          description: Result payload. Always null on error responses.
        requestId:
          type: string
          description: >-
            Identifier of the request (the `x-request-id` header). Quote this
            value to correlate the response with server logs.
          example: 90c16e9e-6e99-4651-a033-60290356df2f
        timestamp:
          type: string
          format: date-time
          description: ISO 8601 timestamp of when the error response was generated.
          example: '2026-05-20T22:29:03.126Z'
      description: Standard API error response envelope wrapping the exception details.
      required:
        - error
        - result
        - timestamp
    TronInvalidDelegatorAddressException:
      type: object
      properties:
        type:
          type: string
          default: client
          example: client
          description: Exception category.
        code:
          type: integer
          format: int32
          default: 125102
          example: 125102
          description: Numeric error code identifying the exception type.
        message:
          type: string
          default: >-
            Invalid delegator address provided. Please ensure the address is a
            valid TRON address format.
          example: >-
            Invalid delegator address provided. Please ensure the address is a
            valid TRON address format.
          description: Human-readable error message describing what went wrong.
        errors:
          description: Validation error details when applicable.
          type: array
          items:
            $ref: '#/components/schemas/ValidationErrorResponse'
        name:
          type: string
          default: InvalidDelegatorAddressException
          example: InvalidDelegatorAddressException
          description: Exception class name for runtime error identification.
      required:
        - type
        - code
        - message
        - errors
        - name
    TronGetAccountFailedException:
      type: object
      properties:
        type:
          type: string
          default: client
          example: client
          description: Exception category.
        code:
          type: integer
          format: int32
          default: 125103
          example: 125103
          description: Numeric error code identifying the exception type.
        message:
          type: string
          default: >-
            Delegator account is not activated or does not exist on-chain.
            Please fund the account before proceeding.
          example: >-
            Delegator account is not activated or does not exist on-chain.
            Please fund the account before proceeding.
          description: Human-readable error message describing what went wrong.
        errors:
          description: Validation error details when applicable.
          type: array
          items:
            $ref: '#/components/schemas/ValidationErrorResponse'
        name:
          type: string
          default: GetAccountFailedException
          example: GetAccountFailedException
          description: Exception class name for runtime error identification.
      required:
        - type
        - code
        - message
        - errors
        - name
    TronVoteWithoutFrozenBalanceException:
      type: object
      properties:
        type:
          type: string
          default: client
          example: client
          description: Exception category.
        code:
          type: integer
          format: int32
          default: 125109
          example: 125109
          description: Numeric error code identifying the exception type.
        message:
          type: string
          default: >-
            Delegator does not have any frozen TRX available for voting. Please
            freeze TRX before attempting to vote.
          example: >-
            Delegator does not have any frozen TRX available for voting. Please
            freeze TRX before attempting to vote.
          description: Human-readable error message describing what went wrong.
        errors:
          description: Validation error details when applicable.
          type: array
          items:
            $ref: '#/components/schemas/ValidationErrorResponse'
        name:
          type: string
          default: VoteWithoutFrozenBalanceException
          example: VoteWithoutFrozenBalanceException
          description: Exception class name for runtime error identification.
      required:
        - type
        - code
        - message
        - errors
        - name
    TronInvalidVoteCountException:
      type: object
      properties:
        type:
          type: string
          default: client
          example: client
          description: Exception category.
        code:
          type: integer
          format: int32
          default: 125110
          example: 125110
          description: Numeric error code identifying the exception type.
        message:
          type: string
          default: 'Invalid vote count: %s. Allowed range is from %s to %s.'
          example: 'Invalid vote count: %s. Allowed range is from %s to %s.'
          description: Human-readable error message describing what went wrong.
        errors:
          description: Validation error details when applicable.
          type: array
          items:
            $ref: '#/components/schemas/ValidationErrorResponse'
        name:
          type: string
          default: InvalidVoteCountException
          example: InvalidVoteCountException
          description: Exception class name for runtime error identification.
      required:
        - type
        - code
        - message
        - errors
        - name
    TronVoteTransactionException:
      type: object
      properties:
        type:
          type: string
          default: client
          example: client
          description: Exception category.
        code:
          type: integer
          format: int32
          default: 125116
          example: 125116
          description: Numeric error code identifying the exception type.
        message:
          type: string
          default: >-
            An error occurred while constructing or broadcasting the vote
            transaction. Ensure the vote count and SR address are valid.
          example: >-
            An error occurred while constructing or broadcasting the vote
            transaction. Ensure the vote count and SR address are valid.
          description: Human-readable error message describing what went wrong.
        errors:
          description: Validation error details when applicable.
          type: array
          items:
            $ref: '#/components/schemas/ValidationErrorResponse'
        name:
          type: string
          default: VoteTransactionException
          example: VoteTransactionException
          description: Exception class name for runtime error identification.
      required:
        - type
        - code
        - message
        - errors
        - name
    AuthNoTokenException:
      type: object
      properties:
        type:
          type: string
          default: authentication
          example: authentication
          description: Exception category.
        code:
          type: integer
          format: int32
          default: 101111
          example: 101111
          description: Numeric error code identifying the exception type.
        message:
          type: string
          default: >-
            No Bearer token has been provided. To obtain an authentication
            token, follow the instructions at
            https://docs.p2p.org/docs/authentication.
          example: >-
            No Bearer token has been provided. To obtain an authentication
            token, follow the instructions at
            https://docs.p2p.org/docs/authentication.
          description: Human-readable error message describing what went wrong.
        name:
          type: string
          default: NoTokenException
          example: NoTokenException
          description: Exception class name for runtime error identification.
      required:
        - type
        - code
        - message
        - name
    AuthWrongTokenException:
      type: object
      properties:
        type:
          type: string
          default: authentication
          example: authentication
          description: Exception category.
        code:
          type: integer
          format: int32
          default: 101109
          example: 101109
          description: Numeric error code identifying the exception type.
        message:
          type: string
          default: >-
            An invalid Bearer token has been provided. Please specify the
            correct authentication token.
          example: >-
            An invalid Bearer token has been provided. Please specify the
            correct authentication token.
          description: Human-readable error message describing what went wrong.
        name:
          type: string
          default: WrongTokenException
          example: WrongTokenException
          description: Exception class name for runtime error identification.
      required:
        - type
        - code
        - message
        - name
    ValidationErrorResponse:
      type: object
      properties:
        property:
          type: string
          description: Name of the property that failed validation.
        constraints:
          type: object
          additionalProperties:
            type: string
          description: Validation constraint details describing what was expected.
      required:
        - property
        - constraints
  responses:
    TooManyRequests:
      description: >-
        Too Many Requests — the client exceeded its rate limit. The response
        advertises when to retry and the active quota via headers.
      headers:
        Retry-After:
          description: Number of seconds to wait before retrying the request.
          schema:
            type: integer
            example: 60
        RateLimit-Limit:
          description: >-
            The request quota (maximum number of requests) for the most
            restrictive applicable window.
          schema:
            type: integer
            example: 120
        RateLimit-Reset:
          description: >-
            Number of seconds until the rate-limit window resets and requests
            are accepted again.
          schema:
            type: integer
            example: 60
        RateLimit-Policy:
          description: >-
            The active rate-limit policy as `<limit>;w=<window-seconds>`,
            comma-separated when multiple windows apply.
          schema:
            type: string
            example: 120;w=60
      content:
        application/json:
          schema:
            type: object
            properties:
              error:
                type: object
                properties:
                  code:
                    type: integer
                  name:
                    type: string
                    example: ThrottlerException
                  message:
                    type: string
                    example: ThrottlerException
                  errors:
                    type: array
                    nullable: true
                    items:
                      type: object
              result:
                type: object
                nullable: true
                example: null
              requestId:
                type: string
                description: >-
                  Identifier of the request (the `x-request-id` header). Quote
                  this value to correlate the response with server logs.
                example: 90c16e9e-6e99-4651-a033-60290356df2f
              timestamp:
                type: string
                format: date-time
                description: ISO 8601 timestamp of when the error response was generated.
                example: '2026-05-20T22:29:03.126Z'
  securitySchemes:
    bearer:
      scheme: bearer
      bearerFormat: JWT
      type: http

````

## Related topics

- [TRON](/docs/unified-api-tron.md)
- [Solana](/docs/unified-api-solana.md)
- [Create Undelegate Request](/reference/tron-staking-undelegate.md)
- [Create Delegate Request](/reference/tron-staking-delegate.md)
- [Create Staking Request](/reference/create-sei-stake-transaction.md)
