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

# Edit Order (Beta)

> Edit an open order. This feature is in beta please reach out to your Coinbase Prime account manager for more information.



## OpenAPI

````yaml PUT  /v1/portfolios/{portfolio_id}/orders/{order_id}/edit
openapi: 3.0.1
info:
  title: REST API
  description: >-
    The Coinbase Prime REST API provides programmatic access to trading,
    custody, staking, market data, and account management functionality.
  version: '0.1'
servers:
  - url: https://api.prime.coinbase.com/
security: []
tags:
  - name: PrimeRESTAPI
paths:
  /v1/portfolios/{portfolio_id}/orders/{order_id}/edit:
    put:
      tags:
        - Orders
      summary: Edit Order (Beta)
      description: >-
        Edit an open order. This feature is in beta please reach out to your
        Coinbase Prime account manager for more information.
      operationId: PrimeRESTAPI_EditOrder
      parameters:
        - name: portfolio_id
          in: path
          description: The ID of the portfolio that owns the order
          required: true
          schema:
            type: string
        - name: order_id
          in: path
          description: The ID of the order being edited
          required: true
          schema:
            type: string
      requestBody:
        content:
          application/json:
            schema:
              required:
                - client_order_id
                - orig_client_order_id
              type: object
              properties:
                product_id:
                  type: string
                  description: 'Deprecated: The product ID of the order being edited'
                orig_client_order_id:
                  type: string
                  description: The client order ID of the order being edited
                client_order_id:
                  type: string
                  description: The updated version of the client order ID
                base_quantity:
                  type: string
                  description: >-
                    Order size in base asset units (either `base_quantity` or
                    `quote_value` is required)
                quote_value:
                  type: string
                  description: >-
                    Order size in quote asset units, i.e. the amount the user
                    wants to spend (when buying) or receive (when selling); the
                    quantity in base units will be determined based on the
                    market liquidity and indicated `quote_value` (either
                    `base_quantity` or `quote_value` is required)
                limit_price:
                  type: string
                  description: >-
                    The limit price (required for TWAP, VWAP, LIMIT, and
                    STOP_LIMIT orders)
                expiry_time:
                  type: string
                  description: >-
                    The expiry time of the order in UTC (TWAP, VWAP, LIMIT, and
                    STOP_LIMIT GTD only)
                  format: date-time
                display_quote_size:
                  type: string
                  description: >-
                    The maximum order size that will show up on venue order
                    books. Specifying a value here effectively makes a LIMIT
                    order into an "iceberg" style order.
                display_base_size:
                  type: string
                  description: >-
                    The maximum order size that will show up on venue order
                    books. Specifying a value here effectively makes a LIMIT
                    order into an "iceberg" style order.
                stop_price:
                  type: string
                  description: >-
                    Specifies the stop price at which the order activates. The
                    order is activated if the last trade price on Coinbase
                    Exchange crosses the stop price specified on the order
                offset:
                  type: string
                  description: >-
                    New peg offset value for PEG orders. 0 means peg to BBO.
                    Only non-negative values are allowed. The order's
                    peg_offset_type is immutable and is reused server-side to
                    interpret this value (PEG orders only)
                wig_level:
                  type: string
                  description: >-
                    New WIG (Would if Good) level for PEG orders - the best
                    price a pegged order would be placed on venues, opposite to
                    limit_price. Cannot be added or removed post-placement (PEG
                    orders only)
        required: true
      responses:
        '200':
          description: A successful response.
          content:
            application/json:
              schema:
                $ref: >-
                  #/components/schemas/coinbase.public_rest_api.EditOrderResponse
components:
  schemas:
    coinbase.public_rest_api.EditOrderResponse:
      type: object
      properties:
        order_id:
          type: string
          description: The ID of the order being edited

````