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

# list_orders

> List Coinbase brokerage orders with optional filters. Returns canonical Order models.

## coinbase\_list\_orders

```python
import os
from opentools import trading

tools = trading.coinbase(
    api_key=os.environ["COINBASE_KEY"],
    api_secret=os.environ["COINBASE_SECRET"],
    model="openai",
    minimal=True,
    include=["coinbase_list_orders"],
)
```

**Request** (all optional)

* `status`: Coinbase order status filter
* `limit`: max orders to return
* `after`: RFC3339 start timestamp (inclusive)
* `until`: RFC3339 end timestamp (exclusive)
* `symbols`: list of product IDs, e.g. `["BTC-USD"]`
* `side`: `buy` or `sell`

**Response**

* Returns a list of canonical `Order` objects.

**Options**

* `include` / `exclude`: filter which tools are exposed (use full names like `coinbase_list_orders`).
* `minimal`: omit `provider` and `provider_fields` when `True`.


## OpenAPI

````yaml api-reference/openapi.json get /tools/coinbase/list_orders
openapi: 3.1.0
info:
  title: OpenTools Trading Tools
  version: 0.1.0
  description: >-
    Reference for OpenTools trading tool calls. These are SDK tools, documented
    as virtual endpoints for clarity.
servers: []
security: []
tags:
  - name: Alpaca
    description: >-
      Read-only account + assets + clock + orders + portfolio history +
      positions.
  - name: Coinbase
    description: >-
      Accounts + portfolios + portfolio breakdown + positions (derived) +
      brokerage products + orders (if available).
paths:
  /tools/coinbase/list_orders:
    get:
      tags:
        - Coinbase
      summary: list_orders
      description: >-
        List Coinbase brokerage orders with optional filters. Returns canonical
        Order models.
      operationId: coinbase_list_orders
      requestBody:
        required: false
        description: This is a request to obtain information. Your API keys are required.
        content:
          application/json:
            schema:
              type: object
              properties:
                status:
                  type: string
                  description: >-
                    Optional Coinbase order status filter (e.g. PENDING, OPEN,
                    FILLED, CANCELLED).
                limit:
                  type: integer
                  description: Max number of orders to return (first page only).
                after:
                  type: string
                  description: Start date/time (RFC3339) to fetch orders from, inclusive.
                until:
                  type: string
                  description: End date/time (RFC3339) to fetch orders until, exclusive.
                symbols:
                  type: array
                  items:
                    type: string
                  description: >-
                    Optional list of product IDs to filter by (e.g.
                    ['BTC-USD']).
                side:
                  type: string
                  enum:
                    - buy
                    - sell
                  description: Order side filter. Maps to Coinbase BUY/SELL.
              additionalProperties: false
            examples:
              default:
                value: {}
              recent_filled:
                value:
                  status: FILLED
                  limit: 25
              by_symbol:
                value:
                  symbols:
                    - BTC-USD
                  limit: 10
              by_time_range:
                value:
                  after: '2025-01-01T00:00:00Z'
                  until: '2025-02-01T00:00:00Z'
                  limit: 50
      responses:
        '200':
          description: Array of orders (OpenTools trading schema).
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                  additionalProperties: false
                  description: ''
                  properties:
                    provider:
                      type:
                        - string
                        - 'null'
                      description: Trading provider identifier. Omitted when minimal=True.
                    id:
                      type:
                        - string
                        - 'null'
                      description: Provider order ID.
                    client_order_id:
                      type:
                        - string
                        - 'null'
                      description: Client-supplied order ID when supported.
                    symbol:
                      type:
                        - string
                        - 'null'
                      description: Instrument symbol (e.g. 'AAPL', 'BTC/USD').
                    side:
                      type:
                        - string
                        - 'null'
                      enum:
                        - buy
                        - sell
                      description: Order side.
                    type:
                      type:
                        - string
                        - 'null'
                      description: >-
                        Order type (e.g. market, limit, stop, stop_limit).
                        Provider-dependent.
                    time_in_force:
                      type:
                        - string
                        - 'null'
                      description: >-
                        Time in force (e.g. day, gtc, ioc, fok).
                        Provider-dependent.
                    status:
                      type:
                        - string
                        - 'null'
                      description: >-
                        Order status as reported by the provider (e.g. accepted,
                        filled, canceled).
                    qty:
                      type:
                        - string
                        - 'null'
                      description: Requested quantity. String to preserve exact precision.
                    notional:
                      type:
                        - string
                        - 'null'
                      description: >-
                        Requested notional amount. String to preserve exact
                        precision.
                    filled_qty:
                      type:
                        - string
                        - 'null'
                      description: Filled quantity. String to preserve exact precision.
                    filled_avg_price:
                      type:
                        - string
                        - 'null'
                      description: Average fill price. String to preserve exact precision.
                    limit_price:
                      type:
                        - string
                        - 'null'
                      description: >-
                        Limit price when applicable. String to preserve exact
                        precision.
                    stop_price:
                      type:
                        - string
                        - 'null'
                      description: >-
                        Stop price when applicable. String to preserve exact
                        precision.
                    submitted_at:
                      type:
                        - string
                        - 'null'
                      format: date-time
                      description: Submitted timestamp.
                    filled_at:
                      type:
                        - string
                        - 'null'
                      format: date-time
                      description: Filled timestamp when applicable.
                    created_at:
                      type:
                        - string
                        - 'null'
                      format: date-time
                      description: Created timestamp.
                    updated_at:
                      type:
                        - string
                        - 'null'
                      format: date-time
                      description: Last update timestamp.
                    provider_fields:
                      type: object
                      additionalProperties: true
                      description: Provider-specific fields. Omitted when minimal=True.
                  examples:
                    - provider: <string>
                      id: <string>
                      client_order_id: <string>
                      symbol: <string>
                      side: buy
                      type: <string>
                      time_in_force: <string>
                      status: <string>
                      qty: <string>
                      notional: <string>
                      filled_qty: <string>
                      filled_avg_price: <string>
                      limit_price: <string>
                      stop_price: <string>
                      submitted_at: '2023-11-07T05:31:56Z'
                      filled_at: '2023-11-07T05:31:56Z'
                      created_at: '2023-11-07T05:31:56Z'
                      updated_at: '2023-11-07T05:31:56Z'
                      provider_fields: {}
        '401':
          description: Unauthorized (missing/invalid credentials).
          content:
            application/json:
              schema:
                type: object
                additionalProperties: false
                properties:
                  message:
                    type: string
                  domain:
                    type: string
                  provider:
                    type: string
                  details: {}
                required:
                  - message
        '429':
          description: Rate limited by provider or transport.
          content:
            application/json:
              schema:
                type: object
                additionalProperties: false
                properties:
                  message:
                    type: string
                  domain:
                    type: string
                  provider:
                    type: string
                  details: {}
                required:
                  - message
      x-codeSamples:
        - lang: python
          label: Python
          source: |
            import os
            from opentools import trading

            tools = trading.coinbase(
                api_key=os.environ["COINBASE_KEY"],
                api_secret=os.environ["COINBASE_SECRET"],
                model="openai",
                minimal=True,
                include=["coinbase_list_orders"],
            )

````