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

# Submit signed transaction to Stellar blockchain

> **System Function**: Submits a pre-signed DeFindex transaction to the Stellar blockchain network.
    
This endpoint allows users to submit transaction XDRs that have been prepared by other DeFindex endpoints and signed by the user. The service handles transaction submission and provides gas-free transaction processing for valid DeFindex operations.



## OpenAPI

````yaml POST /send
openapi: 3.0.0
info:
  title: DeFindex API
  description: >-
    Yield infrastructure for neobanks, fintechs and wallets.


    **Base URL:** `https://api.defindex.io`. Every route takes
    `?network=mainnet` (the default) or `?network=testnet`.


    **Auth:** send your API key as `Authorization: Bearer sk_...` (the console
    uses the JWT access token from `POST /login` the same way). Each operation's
    `security` says whether it needs one; `security: []` means it is public.

    - `401`: no credential, or an invalid API key. The body has a `code`
    (`MISSING_CREDENTIAL` or `INVALID_API_KEY`) and a `registerUrl` where you
    get a key, and `WWW-Authenticate` is set.

    - `403`: an expired or invalid JWT, or a valid credential without the
    required role.


    **Rate limits:** a token bucket per account (requests without a key are
    tracked by IP). Responses carry `X-RateLimit-Limit`, `X-RateLimit-Remaining`
    and `X-RateLimit-Reset` (seconds until the bucket is full). A `429` also
    carries `Retry-After` and `retryAfter` in the body.


    | Tier | Burst | Sustained |

    |---|---|---|

    | FREE | 5 | 1/s |

    | STARTER | 20 | 10/s |

    | PROFESSIONAL | 100 | 50/s |

    | BUSINESS | 200 | 100/s |


    **Units:**

    - Amounts are integers in the asset's smallest unit (7 decimals for every
    asset DeFindex lists today: 1 USDC = `10000000`). Responses send them as
    strings; request bodies take JSON integers.

    - Vault shares (dfTokens) are not underlying: `GET /vault/{address}/balance`
    returns both. The share price rises, so the underlying value of a position
    is not what was deposited.

    - Multi-asset vaults take one amount per vault asset, in the order of
    `assets` in `GET /vault/{address}`.

    - Vault `apy` is a percentage (`8.75` = 8.75%). `/strategies`
    `apy7d`/`apy30d`/`apyAllTime` are fractions (`0.0641` = 6.41%).

    - Fees are basis points (`10000` = 100%).


    **Writes never move funds by themselves.** Each write returns an unsigned
    transaction (`xdr`) for the `caller`. Sign it and submit it with `POST
    /send` (or your own RPC). `POST /send` is idempotent: resubmitting the same
    signed XDR returns the original result.
  version: 1.0.0
  contact: {}
  x-logo:
    url: https://links.paltalabs.io/defindex-full.svg
    backgroundColor: '#0e0e0e'
    altText: DeFindex Logo
    href: https://defindex.io
servers: []
security: []
tags: []
paths:
  /send:
    post:
      tags:
        - Stellar
      summary: Submit signed transaction to Stellar blockchain
      description: >-
        **System Function**: Submits a pre-signed DeFindex transaction to the
        Stellar blockchain network.
            
        This endpoint allows users to submit transaction XDRs that have been
        prepared by other DeFindex endpoints and signed by the user. The service
        handles transaction submission and provides gas-free transaction
        processing for valid DeFindex operations.


        **Idempotent.** A signed XDR has one hash and the network applies it at
        most once, so retrying is safe: if the transaction already landed, the
        response is its original result and nothing is resubmitted; if it is
        still queued, the call waits for it. The call waits up to 60 seconds for
        confirmation; on a timeout, submit the same XDR again. An XDR built by
        this API has no upper time bound (maxTime 0), so it stays valid until
        its source account's sequence number moves past it: if another
        transaction from that account lands first, rebuild and sign again.
      operationId: StellarController_sendTransaction
      parameters:
        - name: network
          required: true
          in: query
          description: Stellar network to submit transaction to (testnet or mainnet)
          schema:
            enum:
              - testnet
              - mainnet
            type: string
      requestBody:
        required: true
        description: Signed transaction data ready for blockchain submission.
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/SendXdrDto'
            examples:
              Submit signed transaction:
                value:
                  xdr: AAAAAgAAAAC7VYzjqMryr...
      responses:
        '201':
          description: >-
            Transaction applied on-chain (or already applied by an earlier call
            with the same XDR)
          content:
            application/json:
              schema:
                type: object
                properties:
                  txHash:
                    type: string
                    description: Transaction hash
                  success:
                    type: boolean
                    description: Whether the transaction succeeded
                  result:
                    type: object
                    nullable: true
                    description: Parsed contract return value
                    properties:
                      type:
                        type: string
                        description: >-
                          Result type. Currently always `unknown`: read `value`
                          against the function you called
                      value:
                        description: Parsed return value
                  ledger:
                    type: number
                    description: Ledger number where transaction was included
                  createdAt:
                    type: string
                    description: Transaction creation timestamp (ISO 8601)
                  latestLedger:
                    type: number
                    description: Latest known ledger number
                  latestLedgerCloseTime:
                    type: string
                    description: Latest ledger close time
                  feeBump:
                    type: boolean
                    description: Whether fee bump was applied
                  feeCharged:
                    type: string
                    description: Fee charged in stroops
                example:
                  txHash: >-
                    6599224a0f08186e59441397202c0513e4383490c54c6fcdb1cf31d35e086d6a
                  success: true
                  result:
                    type: unknown
                    value:
                      - - '4000000000'
                      - '4021025140'
                      - null
                  ledger: 65015482
                  createdAt: '1792363193'
                  latestLedger: 65112150
                  latestLedgerCloseTime: '1792846533'
                  feeBump: true
                  feeCharged: '287898'
          headers:
            X-RateLimit-Limit:
              $ref: '#/components/headers/X-RateLimit-Limit'
            X-RateLimit-Remaining:
              $ref: '#/components/headers/X-RateLimit-Remaining'
            X-RateLimit-Reset:
              $ref: '#/components/headers/X-RateLimit-Reset'
            x-correlation-id:
              $ref: '#/components/headers/x-correlation-id'
        '400':
          description: >-
            Invalid XDR, or the transaction failed on-chain: `message` is the
            Stellar result code (e.g. `txBadSeq`, `txBadAuth`, `txTooLate`)
          headers:
            X-RateLimit-Limit:
              $ref: '#/components/headers/X-RateLimit-Limit'
            X-RateLimit-Remaining:
              $ref: '#/components/headers/X-RateLimit-Remaining'
            X-RateLimit-Reset:
              $ref: '#/components/headers/X-RateLimit-Reset'
            x-correlation-id:
              $ref: '#/components/headers/x-correlation-id'
        '401':
          description: >-
            No credential, an invalid API key, or a valid JWT of a disabled
            account. Except for the disabled account, the answer carries
            `WWW-Authenticate` and a `registerUrl`.
          headers:
            X-RateLimit-Limit:
              $ref: '#/components/headers/X-RateLimit-Limit'
            X-RateLimit-Remaining:
              $ref: '#/components/headers/X-RateLimit-Remaining'
            X-RateLimit-Reset:
              $ref: '#/components/headers/X-RateLimit-Reset'
            x-correlation-id:
              $ref: '#/components/headers/x-correlation-id'
        '403':
          description: >-
            An expired or invalid JWT, or a valid credential without the
            required role.
          headers:
            X-RateLimit-Limit:
              $ref: '#/components/headers/X-RateLimit-Limit'
            X-RateLimit-Remaining:
              $ref: '#/components/headers/X-RateLimit-Remaining'
            X-RateLimit-Reset:
              $ref: '#/components/headers/X-RateLimit-Reset'
            x-correlation-id:
              $ref: '#/components/headers/x-correlation-id'
        '429':
          description: >-
            Rate limit exceeded for your tier. Wait `Retry-After` seconds and
            retry.
          headers:
            Retry-After:
              description: Seconds until the next request is allowed.
              schema:
                type: integer
                example: 1
            X-RateLimit-Limit:
              $ref: '#/components/headers/X-RateLimit-Limit'
            X-RateLimit-Remaining:
              $ref: '#/components/headers/X-RateLimit-Remaining'
            X-RateLimit-Reset:
              $ref: '#/components/headers/X-RateLimit-Reset'
            x-correlation-id:
              $ref: '#/components/headers/x-correlation-id'
          content:
            application/json:
              schema:
                type: object
                properties:
                  statusCode:
                    type: integer
                    example: 429
                  message:
                    type: string
                    example: Rate limit exceeded
                  error:
                    type: string
                    example: Too Many Requests
                  retryAfter:
                    type: integer
                    example: 1
              example:
                statusCode: 429
                message: Rate limit exceeded
                error: Too Many Requests
                retryAfter: 1
      security:
        - bearer: []
components:
  schemas:
    SendXdrDto:
      type: object
      properties:
        xdr:
          type: string
          description: The signed transaction in XDR format
      required:
        - xdr
  headers:
    X-RateLimit-Limit:
      description: 'Bucket size for your tier: the most requests you can burst.'
      schema:
        type: integer
        example: 5
    X-RateLimit-Remaining:
      description: Requests left in the bucket right now.
      schema:
        type: integer
        example: 4
    X-RateLimit-Reset:
      description: >-
        Seconds (not a timestamp) until the bucket is full again. On a 429,
        seconds until the next request is allowed.
      schema:
        type: integer
        example: 1
    x-correlation-id:
      description: >-
        Request ID. Send your own `x-correlation-id` to have it echoed back;
        quote it when you report a problem.
      schema:
        type: string
        example: 454a42d5-0166-40fe-a4ad-32e77aa44962
  securitySchemes:
    bearer:
      scheme: bearer
      bearerFormat: JWT
      type: http

````

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