Block · Capability

Square API — Orders

Square API — Orders. 1 operations. Lead operation: Block Square Create Order. Self-contained Naftiko capability covering one Block business surface.

Run with Naftiko BlockOrders

What You Can Do

POST
Createorder — Block Square Create Order
/v1/orders

MCP Tools

block-square-create-order

Block Square Create Order

Capability Spec

square-orders.yaml Raw ↑
naftiko: 1.0.0-alpha2
info:
  label: Square API — Orders
  description: 'Square API — Orders. 1 operations. Lead operation: Block Square Create Order. Self-contained Naftiko capability
    covering one Block business surface.'
  tags:
  - Block
  - Orders
  created: '2026-05-19'
  modified: '2026-05-19'
binds:
- namespace: env
  keys:
    BLOCK_API_KEY: BLOCK_API_KEY
capability:
  consumes:
  - type: http
    namespace: square-orders
    baseUri: https://connect.squareup.com/v2
    description: Square API — Orders business capability. Self-contained, no shared references.
    resources:
    - name: orders
      path: /orders
      operations:
      - name: createorder
        method: POST
        description: Block Square Create Order
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: body
          in: body
          type: object
          description: Request body (JSON).
          required: true
    authentication:
      type: bearer
      token: '{{env.BLOCK_API_KEY}}'
  exposes:
  - type: rest
    namespace: square-orders-rest
    port: 8080
    description: REST adapter for Square API — Orders. One Spectral-compliant resource per consumed operation, prefixed with
      /v1.
    resources:
    - path: /v1/orders
      name: orders
      description: REST surface for orders.
      operations:
      - method: POST
        name: createorder
        description: Block Square Create Order
        call: square-orders.createorder
        with:
          body: rest.body
        outputParameters:
        - type: object
          mapping: $.
  - type: mcp
    namespace: square-orders-mcp
    port: 9090
    transport: http
    description: MCP adapter for Square API — Orders. One tool per consumed operation, routed inline through this capability's
      consumes block.
    tools:
    - name: block-square-create-order
      description: Block Square Create Order
      hints:
        readOnly: false
        destructive: false
        idempotent: false
      call: square-orders.createorder
      with:
        body: tools.body
      outputParameters:
      - type: object
        mapping: $.