Uniswap · Capability

Token Trading — Order

Token Trading — Order. 2 operations. Lead operation: Create a gasless order. Self-contained Naftiko capability covering one Uniswap business surface.

Run with Naftiko UniswapOrder

What You Can Do

POST
Postorder — Create a gasless order
/v1/order
GET
Getorder — Get gasless orders
/v1/orders

MCP Tools

create-gasless-order

Create a gasless order

get-gasless-orders

Get gasless orders

read-only idempotent

Capability Spec

trading-order.yaml Raw ↑
naftiko: 1.0.0-alpha2
info:
  label: Token Trading — Order
  description: 'Token Trading — Order. 2 operations. Lead operation: Create a gasless order. Self-contained Naftiko capability
    covering one Uniswap business surface.'
  tags:
  - Uniswap
  - Order
  created: '2026-05-19'
  modified: '2026-05-19'
binds:
- namespace: env
  keys:
    UNISWAP_API_KEY: UNISWAP_API_KEY
capability:
  consumes:
  - type: http
    namespace: trading-order
    baseUri: https://trade-api.gateway.uniswap.org/v1
    description: Token Trading — Order business capability. Self-contained, no shared references.
    resources:
    - name: order
      path: /order
      operations:
      - name: postorder
        method: POST
        description: Create a gasless order
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: body
          in: body
          type: object
          description: Request body (JSON).
          required: false
    - name: orders
      path: /orders
      operations:
      - name: getorder
        method: GET
        description: Get gasless orders
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
    authentication:
      type: apikey
      key: x-api-key
      value: '{{env.UNISWAP_API_KEY}}'
      placement: header
  exposes:
  - type: rest
    namespace: trading-order-rest
    port: 8080
    description: REST adapter for Token Trading — Order. One Spectral-compliant resource per consumed operation, prefixed
      with /v1.
    resources:
    - path: /v1/order
      name: order
      description: REST surface for order.
      operations:
      - method: POST
        name: postorder
        description: Create a gasless order
        call: trading-order.postorder
        with:
          body: rest.body
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/orders
      name: orders
      description: REST surface for orders.
      operations:
      - method: GET
        name: getorder
        description: Get gasless orders
        call: trading-order.getorder
        outputParameters:
        - type: object
          mapping: $.
  - type: mcp
    namespace: trading-order-mcp
    port: 9090
    transport: http
    description: MCP adapter for Token Trading — Order. One tool per consumed operation, routed inline through this capability's
      consumes block.
    tools:
    - name: create-gasless-order
      description: Create a gasless order
      hints:
        readOnly: false
        destructive: false
        idempotent: false
      call: trading-order.postorder
      with:
        body: tools.body
      outputParameters:
      - type: object
        mapping: $.
    - name: get-gasless-orders
      description: Get gasless orders
      hints:
        readOnly: true
        destructive: false
        idempotent: true
      call: trading-order.getorder
      outputParameters:
      - type: object
        mapping: $.