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

# Create Pro Sell Transaction

> Generate a sell transaction for a pro pool.

**Flow:** First call `/quote/pro/sell` to get a quote, then pass the `quote_response` and `pool` address here. The transaction sells tokens for SOL.



## OpenAPI

````yaml /openapi.json post /tx/pro/sell
openapi: 3.1.0
info:
  title: heaven-tx-api
  description: ''
  license:
    name: ''
  version: 0.1.14
servers:
  - url: https://tx.api.heaven.xyz
security: []
tags:
  - name: heaven-api
    description: Heaven API
paths:
  /tx/pro/sell:
    post:
      tags:
        - Pro Pool API
      summary: Create Pro Sell Transaction
      description: >-
        Generate a sell transaction for a pro pool.


        **Flow:** First call `/quote/pro/sell` to get a quote, then pass the
        `quote_response` and `pool` address here. The transaction sells tokens
        for SOL.
      operationId: create_pro_sell_tx
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CreateProSellTxRequest'
        required: true
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/CreateProSellTxResponse'
components:
  schemas:
    CreateProSellTxRequest:
      type: object
      required:
        - payer
        - quote_response
        - encoded_user_defined_event_data
        - pool
      properties:
        payer:
          type: string
          description: Public key of the wallet that will sign and pay for the transaction.
        quote_response:
          $ref: '#/components/schemas/QuoteSellResponse'
          description: >-
            The full quote response object from the Quote Pro Sell endpoint.
            Contains the calculated amounts, fees, and slippage parameters.
        encoded_user_defined_event_data:
          type: string
          description: >-
            Arbitrary string data emitted as an on-chain event. Useful for
            tracking or attributing transactions.
        pool:
          type: string
          description: >-
            On-chain address of the pro pool state account. Returned in the
            response when creating a pool.
        compute_unit_limit:
          type: integer
          format: int32
          minimum: 0
          nullable: true
          description: >-
            Maximum compute units for the transaction. Higher values allow more
            complex operations but cost more. Defaults to a sensible value if
            omitted.
        compute_unit_price:
          type: integer
          format: int64
          minimum: 0
          nullable: true
          description: >-
            Priority fee in micro-lamports per compute unit. Higher values
            increase transaction priority. Defaults to a sensible value if
            omitted.
        source:
          type: string
          nullable: true
          description: >-
            Optional source wallet. If different from payer, tokens will be
            debited from this wallet. Defaults to payer if omitted.
      description: >-
        Request to create a sell transaction for a pro pool. First call Quote
        Pro Sell to get the quote_response, then pass it here.
    CreateProSellTxResponse:
      type: object
      required:
        - tx
      properties:
        tx:
          type: string
          description: >-
            Base64 encoded versioned transaction. Decode, sign with the payer,
            and submit to the Solana network.
    QuoteSellResponse:
      type: object
      required:
        - amount_in
        - amount_in_ui
        - minimum_out
        - minimum_out_ui
        - config_version
        - mint
        - program_id
        - slippage_bps
      properties:
        amount_in:
          type: integer
          format: int64
          minimum: 0
          description: Amount of tokens to sell (native units).
        amount_in_ui:
          type: number
          format: double
          description: Amount of tokens to sell (human-readable with decimals).
        config_version:
          type: integer
          format: int32
          minimum: 0
          description: Protocol config version used for the quote.
        minimum_out:
          type: integer
          format: int64
          minimum: 0
          description: Minimum SOL output after slippage (lamports).
        minimum_out_ui:
          type: number
          format: double
          description: Minimum SOL output after slippage (human-readable).
        mint:
          type: string
          description: Mint address of the token being sold.
        program_id:
          type: string
          description: Heaven DEX program ID used.
        slippage_bps:
          type: integer
          format: int64
          minimum: 0
          description: Slippage tolerance applied (basis points).

````