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

# Create Deployer Claim Transactions

> Build a bounded batch of version-0, sponsor-partially-signed transactions for pending pool deployer fees and the aggregate SOL deployer vault. The wallet must sign. Sponsorship is repaid from proceeds, with existing wallet SOL covering any shortfall. Claims that cannot be safely funded or simulated are returned in deferredClaims. The planner does not rely on profits from earlier transactions in the same batch or spend the same aggregate vault balance twice. Each withdrawal drains the wallet-wide deployer vault even when tokenMints filters pool collection. maxTransactions limits returned transactions; at most 20 pool claim candidates are attempted per request. Confirm each returned transaction in order, then request a fresh batch for remaining claims. The response is not cached.

Returns an ordered batch of version-0 transactions and explicit deferred claims. Each item uses `transaction`, must retain its sponsor signature, and requires the deployer wallet's signature. Confirm the batch before requesting the next one.

A `tokenMints` filter limits pending pool collection; every vault withdrawal still drains the wallet-wide deployer balance. See [Deployer Fees](/how-to-guides/deployer-fees#sign-and-submit-version-0-transactions) for signing, funding, and retry handling.


## OpenAPI

````yaml POST /fee-share/deployer/claim-txs
openapi: 3.1.0
info:
  title: Bags Public API v2
  description: API endpoints for Bags platform
  version: 2.0.0
  contact:
    name: Bags Support
    url: https://support.bags.fm
servers:
  - url: https://public-api-v2.bags.fm/api/v1
    description: Production server
security:
  - ApiKeyAuth: []
tags:
  - name: Token Launch
    description: Endpoints for creating and managing token launches
  - name: Fee Share
    description: Endpoints for managing fee sharing configs
  - name: Fee Share Admin
    description: >-
      Endpoints for fee share admin operations including listing, transferring
      admin authority, and updating configs
  - name: Analytics
    description: Endpoints for retrieving token analytics and metadata
  - name: Fee Claiming
    description: Endpoints for claiming fees from various sources
  - name: State
    description: Endpoints for retrieving on-chain state and derived state
  - name: Trade
    description: Endpoints for getting trade quotes and executing token swaps
  - name: Partner
    description: Endpoints for managing partner configurations and claiming partner fees
  - name: Solana
    description: Endpoints for direct Solana blockchain interactions
  - name: EVM
    description: Endpoints for reading Bags EVM token data
  - name: Robinhood Chain
    description: Read endpoints for Bags V2 tokens on Robinhood Chain (chain id 4663)
  - name: Dexscreener
    description: >-
      Endpoints for managing Dexscreener token info orders, payments, and image
      uploads
  - name: Auth
    description: Endpoints for retrieving authenticated user information
  - name: Agent
    description: Endpoints for AI agent wallet-signature authentication (V2)
paths:
  /fee-share/deployer/claim-txs:
    post:
      tags:
        - Fee Share
      summary: Create deployer claim transactions
      description: >-
        Build a bounded batch of version-0, sponsor-partially-signed
        transactions for pending pool deployer fees and the aggregate SOL
        deployer vault. The wallet must sign. Sponsorship is repaid from
        proceeds, with existing wallet SOL covering any shortfall. Claims that
        cannot be safely funded or simulated are returned in deferredClaims. The
        planner does not rely on profits from earlier transactions in the same
        batch or spend the same aggregate vault balance twice. Each withdrawal
        drains the wallet-wide deployer vault even when tokenMints filters pool
        collection. maxTransactions limits returned transactions; at most 20
        pool claim candidates are attempted per request. Confirm each returned
        transaction in order, then request a fresh batch for remaining claims.
        The response is not cached.
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CreateDeployerClaimTransactionsRequest'
      responses:
        '200':
          description: >-
            Successfully generated a claim plan; transactions may be empty and
            claims may be deferred
          content:
            application/json:
              schema:
                allOf:
                  - $ref: '#/components/schemas/SuccessResponse'
                  - type: object
                    properties:
                      response:
                        $ref: '#/components/schemas/DeployerClaimTransactionsData'
                        description: Successful deployer response payload.
                    required:
                      - response
        '400':
          description: >-
            Bad request - Invalid wallet, unknown fields, or out-of-range
            parameters
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/DeployerErrorResponse'
        '401':
          description: Unauthorized - Invalid or missing API key
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '429':
          description: Rate limit exceeded - Retry according to Retry-After when present
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '500':
          description: Internal server error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/DeployerErrorResponse'
        '503':
          description: >-
            Deployer claim state temporarily unavailable - Pending pool
            discovery or a consistent finalized on-chain snapshot could not be
            completed. Retry; do not treat this as an empty claim plan.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/DeployerErrorResponse'
          headers:
            Retry-After:
              description: Suggested delay before retrying, in seconds.
              schema:
                type: string
                example: '5'
      security:
        - ApiKeyAuth: []
components:
  schemas:
    CreateDeployerClaimTransactionsRequest:
      type: object
      properties:
        wallet:
          type: string
          description: >-
            Deployer wallet that will receive the fees and must sign every
            returned transaction. An API key alone cannot authorize withdrawal.
        tokenMints:
          type: array
          minItems: 1
          maxItems: 20
          items:
            type: string
          description: >-
            Optional filter of 1–20 base mints whose pending pool fees should be
            collected. Omit to consider all discovered tokens. This does not
            restrict the wallet-wide vault withdrawal.
        maxTransactions:
          type: integer
          minimum: 1
          maximum: 20
          default: 10
          description: >-
            Maximum number of returned transactions, from 1 to 20; defaults to
            10. At most 20 pool claim candidates are attempted per request,
            independently of this response limit. Deferred candidates do not
            consume transaction slots.
      required:
        - wallet
    SuccessResponse:
      type: object
      properties:
        success:
          type: boolean
          example: true
        response:
          description: ''
      required:
        - success
    DeployerClaimTransactionsData:
      type: object
      properties:
        wallet:
          type: string
          description: Deployer wallet that must sign the returned transactions.
        quoteMint:
          type: string
          enum:
            - So11111111111111111111111111111111111111112
          description: WSOL mint; successful sweeps unwrap the proceeds to native SOL.
        transactions:
          type: array
          description: >-
            Ordered, simulated version-0 transactions, partially signed by the
            gas sponsor. Each item uses transaction, not tx. Preserve existing
            signatures when adding the deployer signature, then submit and
            confirm every item in order. An empty array is valid; inspect
            deferredClaims.
          items:
            $ref: '#/components/schemas/TransactionWithBlockhash'
        remainingTokenMints:
          type: array
          description: >-
            Selected token mints with pending pool claims deferred by this
            request. After confirming the returned batch, fetch a new plan.
            Tokens excluded by tokenMints are not listed.
          items:
            type: string
        deferredClaims:
          type: array
          description: >-
            Claims not included in transactions, with a funding, simulation, or
            batch reason. A vault-only deferral can have tokenMint null and no
            entry in remainingTokenMints.
          items:
            $ref: '#/components/schemas/DeployerDeferredClaim'
        transactionVersion:
          type: integer
          enum:
            - 0
          description: >-
            Solana transaction message version. Deserialize with
            VersionedTransaction.deserialize.
      required:
        - wallet
        - quoteMint
        - transactions
        - remainingTokenMints
        - deferredClaims
        - transactionVersion
    DeployerErrorResponse:
      type: object
      properties:
        success:
          type: boolean
          enum:
            - false
          description: False when the deployer request cannot be completed.
        response:
          type: string
          description: >-
            Error message. Backend deployer validation, availability, and server
            errors use response; public gateway auth failures use the shared
            error envelope.
      required:
        - success
        - response
    ErrorResponse:
      type: object
      properties:
        success:
          type: boolean
          example: false
        error:
          type: string
          description: Error message
      required:
        - success
        - error
    TransactionWithBlockhash:
      type: object
      properties:
        blockhash:
          $ref: '#/components/schemas/BlockhashWithExpiryBlockHeight'
        transaction:
          type: string
          description: Base58 encoded serialized versioned transaction
      required:
        - blockhash
        - transaction
    DeployerDeferredClaim:
      type: object
      properties:
        tokenMint:
          type:
            - string
            - 'null'
          description: >-
            Base mint for a pending pool claim, or null for a wallet-wide
            vault-only withdrawal.
        protocol:
          type: string
          enum:
            - dbc
            - dammV2
            - vault
          description: Source of the deferred claim.
        reason:
          type: string
          enum:
            - needs_wallet_sol
            - simulation_failed
            - batch_limit
          description: >-
            The claim needs more wallet SOL, failed simulation for another
            reason, or was outside this request's batch limit. No transaction is
            returned for this item.
        additionalSolLamports:
          type: string
          pattern: ^[0-9]+$
          description: >-
            Additional wallet SOL estimated to be needed when the planner can
            determine a funding shortfall. Decimal lamports as string to support
            bigint.
      required:
        - tokenMint
        - protocol
        - reason
    BlockhashWithExpiryBlockHeight:
      type: object
      properties:
        blockhash:
          type: string
          description: Recent blockhash for the transaction
        lastValidBlockHeight:
          type: number
          description: The last block height for which the blockhash is valid
      required:
        - blockhash
        - lastValidBlockHeight
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: x-api-key
      description: API key authentication. Provide your API key as the header value.

````