Agent Commerce Kit (ACK)

repository·main·Indexed 40 days ago

https://github.com/agentcommercekit/ack

A set of vendor-neutral protocols and components for AI agents to participate in commerce. It includes ACK-ID for verifiable identity using DIDs and Verifiable Credentials (VCs), and ACK-Pay for secure payment processing and receipt issuance across on-chain stablecoins (Base Sepolia, Solana devnet) and simulated credit card payments.

Tokens
83K
Snippets
252
Records
353
Agent score
100%

What's inside ACK

  1. Overview of Agent Commerce Kit (ACK)

    main

    Agent Commerce Kit (ACK) is a framework designed to enable AI agents to participate in the digital economy by bridging the gap between autonomous AI workflows and traditional financial infrastructure. It provides open standard protocols and patterns to solve three core challenges:

    1. Verifiable Agent Identity: Uses open identity standards to cryptographically link AI agents to their accountable human or organizational owners.
    2. Agent-Native Payments: Provides protocols for secure payment initiation and execution across various financial rails, including standardized, verifiable digital receipts.
    3. Integrated Oversight: Includes mechanisms for human oversight to handle compliance, support, and risk escalations.

    ACK is open-source and available under the MIT license.

  2. Overview of the ACK-Pay Payments Protocol

    main

    ACK-Pay is a framework for agentic financial transactions designed to enable secure, automated, and compliant payments. It uses standard interaction patterns and leverages Verifiable Credentials (VCs) to issue receipts, ensuring accountability in automated environments.

    Key features include:

    • Flexible Interaction Flows: Supports both server-initiated and client-initiated payment sequences.
    • Settlement Abstraction: Uses the Payment Service abstraction to allow integration with various settlement rails, such as:
      • Traditional finance and card networks (e.g., Stripe, PayPal, Visa, Mastercard).
      • Blockchain-based digital assets (e.g., via the x402 protocol).
    • Identity Integration: When used alongside ACK-ID, it provides a foundation for trust and accountability by linking payments to verifiable identities.
  3. Explore ACK-Pay use cases for agentic commerce

    main

    ACK-Pay is designed for scenarios where autonomous agents must execute financial transactions. Key application patterns include:

    • Agent-to-Human Payments: Paying human experts (e.g., legal professionals) for validation, feedback, or data annotation.
    • Service Procurement: Agents purchasing specialized analysis or data from other models/services without human intervention, often governed by pre-defined spending thresholds.
    • Subscription Management: Automating renewals and tier upgrades for paywalled data feeds or services.
    • Outcome-Based Payments: Executing transactions only upon verifiable outcomes (e.g., marketing conversions).
    • Micropayments: Continuous, low-value payments for real-time data streaming (e.g., traffic updates for autonomous vehicles).
    • Human-to-Agent Authorization: Users authorizing an AI shopping agent to settle payments with vendors, receiving verifiable receipts.
    • MCP Server Access: Facilitating automatic payments between an LLM-driven workflow and a Model Context Protocol (MCP) server to grant access to specialized resources.
  4. What is ACK-Pay (Agent-Native Payments)?

    main

    ACK-Pay is a transport-agnostic pattern for agent commerce that defines how to initiate payments, generate verifiable receipts, and conduct secure transaction verification. While it supports HTTP-centric standards like Coinbase's x402 (utilizing the 402 status code), it is designed to work across diverse settlement layers (traditional and blockchain-based) and transport protocols.

    Key capabilities include:

    • Standard Payment Initiation: Communicating payment requirements or initiating payments for known obligations.
    • Flexible Execution: Using intermediary Payment Services to support various settlement networks.
    • Verifiable Proof: Generating standardized, cryptographically secure receipts in the form of Verifiable Credentials.
    • Human Oversight: Providing integration points for human approval and risk management within automated workflows.
  5. What is the ACK-Pay protocol?

    main

    The ACK Payment Protocol (ACK-Pay) is an agent-native payments protocol designed for secure, verifiable, and interoperable financial transactions between autonomous agents, services, and humans.

    Unlike traditional payment systems, ACK-Pay is protocol-agnostic; while many implementations use HTTP, the standard defines payloads and interactions that can work across various communication mechanisms. It is designed to be interoperable with network-specific solutions (like Visa Intelligent Commerce or Mastercard Agent Pay) and stablecoin-oriented blockchain solutions (such as Coinbase's x402, l402, or h402).

    For maximum security and accountability, ACK-Pay is intended to be used in conjunction with the ACK-ID identity protocol, which provides verifiable agent identities and clear chains of ownership.

  6. Overview of the ACK End-to-End Demo workflow

    main

    The interactive CLI demo follows a specific sequence of protocol interactions to demonstrate how ACK components work together:

    1. Identity Creation: Creation of Client and Server Agents and their respective identities.
    2. Proof of Ownership: Establishing proof of ownership between Users and the Agents they control.
    3. Agent Communication: Agent-to-agent communication that is interrupted by a paywall.
    4. Payment Execution: The Client Agent performs an on-chain (simulated) payment.
    5. Receipt Issuance: A Receipt Issuer provides a Receipt for the completed payment.
    6. Resuming Interaction: The Client Agent retries the request, including the payment receipt.
    7. Verification & Delivery: The Server Agent verifies the receipt and delivers the requested service.
  7. What is ACK-ID (Verifiable Agent Identity)?

    main

    ACK-ID is a framework for managing verifiable agent identities, ownership chains, and authorization processes. It is designed to solve the identity challenges of AI actors by providing:

    • Verifiable Ownership: An auditable cryptographic link between accountable legal entities (Owners) and their autonomous agents.
    • Secure Authentication: Allowing agents to prove their identity and authorization levels.
    • Privacy Preservation: Enabling agents to disclose only the specific identity attributes required for a transaction.

    ACK-ID is built upon W3C open standards, specifically Decentralized Identifiers (DIDs) and Verifiable Credentials (VCs), making it interoperable while remaining extensible to future technologies.

  8. What is ACK-ID?

    main

    ACK-ID (Agent Commerce Kit Identity Protocol) is a protocol designed to establish verifiable identities for AI agents and link them to their human or organizational owners. It provides a framework for secure, auditable, and privacy-preserving identity management in agentic workflows.

    ACK-ID solves three primary challenges:

    1. Verifiable Ownership: Creates auditable links between legal entities and the autonomous agents acting on their behalf.
    2. Secure Authentication: Allows agents to prove their identity to other parties during automated interactions.
    3. Privacy Preservation: Enables agents to share specific identity attributes required for compliance or authorization without over-sharing sensitive data.

    It is built upon decentralized identity protocols to ensure that entities maintain control over their own digital identifiers without relying on central authorities.

  9. Structure of a DID Document

    main

    A DID Document is a standard way to broadcast public keys. ACK-ID utilizes specific fields to enable Ownership Chains and Service Discovery.

    Key Fields for ACK-ID

    • controller: An attribute used to assert ownership by pointing to the owner's DID. Note: This requires a method like did:web that supports custom attributes; did:key and did:pkh are not suitable for this.
    • service: An array of service objects used for discovery. Each object includes an id, a type (e.g., MessagingEndpoint, IdentityService), and a serviceEndpoint URL.
    • verificationMethod: Contains the public keys and their metadata.
    • authentication / assertionMethod: Lists the IDs of the verification methods used for these specific purposes.
    {
      "@context": [
        "https://www.w3.org/ns/did/v1",
        "https://w3id.org/security/jwk/v1"
      ],
      "id": "did:web:agent.example.com",
      "verificationMethod": [
        {
          "id": "did:web:agent.example.com#jwk-1",
          "type": "JsonWebKey2020",
          "controller": "did:web:agent.example.com",
          "publicKeyJwk": {
            "kty": "EC",
            "crv": "secp256k1",
            "x": "9XnNNAuc_GLLYl6BEr5CJ_bhWRBzEon---ELTxCo51M",
            "y": "l0jv5rBkUx11hDSf4Nx8xSiQOEyRUDbz_YSab2KczP4"
          }
        }
      ],
      "authentication": ["did:web:agent.example.com#jwk-1"],
      "assertionMethod": ["did:web:agent.example.com#jwk-1"],
      "controller": "did:key:zQ3shg46zUAVeEV8pwAYtx4oKj3PvM8vAfpUM1bGKmx3Zibrz",
      "service": [
        {
          "id": "did:web:agent.example.com/v1/messages",
          "type": "MessagingEndpoint",
          "serviceEndpoint": "http://agent.example.com/v1/messages"
        },
        {
          "id": "did:web:agent.example.com/identity",
          "type": "IdentityService",
          "serviceEndpoint": "http://agent.example.com/identity"
        }
      ]
    }
  10. Implement Selective Disclosure with Verifiable Credentials

    main

    To protect privacy, use the Selective Disclosure capability of Verifiable Credentials (VCs). This allows an agent to reveal only the specific attributes required for a transaction rather than exposing an entire identity profile.

    Example Scenario: An agent can present a VC that proves it is authorized to make a payment up to a specific limit without revealing other unrelated credentials or personal identity details it holds.

  11. Understand the ACK-ID Agent Ownership model

    main

    ACK-ID uses a hierarchical identity model to ensure accountability in commercial interactions. It distinguishes between the entity responsible for an agent and the agent itself:

    • Owner Identity: The human or legal entity (e.g., a company) responsible for the agent's actions. This is typically a long-lived identity tied to real-world verification (KYC/KYB).
    • Agent Identity: The identity of the AI agent. It derives authority from the Owner Identity and is used for authentication during interactions. Agent identities can be permanent or temporary but must always be linked to a verified Owner Identity.

    This model ensures a clear chain of responsibility for autonomous agents.

  12. How did:web resolution works in local-did-host

    main

    The local-did-host server simulates the did:web resolution process. When a did:web document is resolved, the resolver fetches a .well-known/did.json file from the host.

    Resolution Logic:

    • did:web:example.com resolves to https://example.com/.well-known/did.json.
    • did:web:example.com:special resolves to https://example.com/special/.well-known/did.json.

    In this local implementation, the server uses dynamic routes to serve these files at subpaths. Note that while this example builds DID Documents dynamically per-request, production environments should serve did.json as a static file.