arazzo: 1.0.1
info:
  title: DeltaSignal ATLAS-7 Public MCP x402 Handshake
  summary: Public discovery and payment onboarding for the DeltaSignal MCP server.
  description: >
    Agents without internal keys should use this workflow to confirm public
    MCP discovery and x402 payment behavior. The client issues tools/list
    for free discovery, then calls a real tool without payment to receive a
    402 challenge. An x402-capable payment client pays and retries that same
    tools/call request.
  version: 1.0.0
sourceDescriptions:
  - name: deltasignalOpenAPI
    type: openapi
    url: https://api.aitrailblazer.net/openapi.json
  - name: deltasignalX402
    type: other
    url: https://api.aitrailblazer.net/.well-known/x402
workflows:
  - workflowId: publicMcpX402Handshake
    summary: Public MCP onboarding and payment check.
    description: >
      Confirms that POST /mcp allows public metadata discovery before payment,
      and that tool execution remains x402-protected. No internal key is sent.
      x402-capable clients handle the payment step outside the Arazzo runner,
      then retry the identical tools/call request with payment proof.
    x-audience: public
    x-payment-rail: x402
    x-agent-intent:
      - onboarding
      - payment_handshake
      - mcp_discovery
    inputs:
      type: object
      properties:
        mcpRequest:
          type: object
          description: JSON-RPC tools/call request body used to trigger the payment challenge.
          default:
            jsonrpc: "2.0"
            id: readiness
            method: tools/call
            params:
              name: deltasignal_readiness
              arguments: {}
    steps:
      - stepId: unauthenticatedToolsList
        description: Call POST /mcp with tools/list and no internal auth header. Public discovery should succeed without payment.
        operationId: callDeltaSignalMCP
        x-deltasignal-path: /mcp
        x-http-method: POST
        x-payment-rail: none
        x-expected-status: 200
        requestBody:
          payload:
            jsonrpc: "2.0"
            id: tools
            method: tools/list
            params: {}
        successCriteria:
          - condition: $statusCode == 200
          - condition: $.result.tools.length >= 1
        failureActions:
          - name: unexpectedMcpResponse
            type: end
            criteria:
              - condition: $statusCode != 200
      - stepId: unpaidToolCallPaymentChallenge
        description: Call a real MCP tool without internal auth or payment. Tool execution should return a Base x402 payment challenge.
        operationId: callDeltaSignalMCP
        x-deltasignal-path: /mcp
        x-http-method: POST
        x-payment-rail: x402
        x-expected-status: 402
        requestBody:
          payload: $inputs.mcpRequest
        successCriteria:
          - condition: $statusCode == 402
        failureActions:
          - name: unexpectedPaidToolResponse
            type: end
            criteria:
              - condition: $statusCode != 402
        x-agent-next-action: >
          Let the x402 client pay the returned challenge, then retry this same
          tools/call request. Do not use x-api-key or mcp-api-key for public clients.
    outputs:
      initialStatus: $statusCode
      paymentRail: x402
      mcpEndpoint: https://api.aitrailblazer.net/mcp
      x402Discovery: https://api.aitrailblazer.net/.well-known/x402
