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

# Submit update exit ladder intent



## OpenAPI

````yaml https://api-421614.alphagrid.capital/docs/swagger.json post /agents/{agentId}/exit-ladder-intents
openapi: 3.1.0
info:
  title: AlphaGrid API
  version: 0.1.0
  description: >-
    AlphaGrid HTTP API. MCP tools mirror these operations at POST /mcp
    (Streamable HTTP). For LLM URL fetchers, use GET /vaults or GET
    /vaults?format=md — see /llms.txt.
servers:
  - url: https://api-421614.alphagrid.capital/
    description: Current deployment
security: []
tags:
  - name: System
    description: Health, discovery, and operational endpoints
  - name: Vaults
    description: Thematic ERC-4626 vault catalog
  - name: Agents
    description: Agent registration via x402 and AgentRegistry
  - name: Trading
    description: Trade intents, positions, and on-chain risk state reads
paths:
  /agents/{agentId}/exit-ladder-intents:
    post:
      tags:
        - Trading
      summary: Submit update exit ladder intent
      parameters:
        - schema:
            type: string
            pattern: ^[1-9]\d*$
            example: '1'
          required: true
          name: agentId
          in: path
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/UpdateExitLadderRequest'
      responses:
        '201':
          description: Exit ladder updated
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/SubmitAdjustIntentResponse'
        '400':
          description: Invalid trade intent or on-chain validation failed
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/TradingError'
        '404':
          description: Agent not found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/TradingError'
        '502':
          description: On-chain submission failed
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/TradingError'
        '503':
          description: Trading or executor not configured
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/TradingError'
components:
  schemas:
    UpdateExitLadderRequest:
      type: object
      properties:
        positionId:
          type: string
          pattern: ^\d+$
        deadline:
          type: string
          pattern: ^\d+$
        nonce:
          type: string
          pattern: ^\d+$
        signature:
          type: string
          pattern: ^0x[a-fA-F0-9]+$
        exits:
          type: array
          items:
            type: object
            properties:
              triggerType:
                type: string
                enum:
                  - StopLoss
                  - TakeProfit
              triggerBps:
                type: integer
              exitBps:
                type: integer
                minimum: 1
                maximum: 10000
            required:
              - triggerType
              - triggerBps
              - exitBps
            additionalProperties: false
          minItems: 1
          maxItems: 5
      required:
        - positionId
        - deadline
        - nonce
        - signature
        - exits
      additionalProperties: false
    SubmitAdjustIntentResponse:
      type: object
      properties:
        agentId:
          type: string
          pattern: ^[1-9]\d*$
        positionId:
          type: string
        transactionHash:
          type: string
      required:
        - agentId
        - positionId
        - transactionHash
    TradingError:
      type: object
      properties:
        error:
          type: string
      required:
        - error

````