cronos-paytech

n8n node for Cronos x402 Agentic Payments

Package Information

Downloads: 36 weekly / 68 monthly
Latest Version: 0.1.4
Author: Ainun

Documentation

n8n-nodes-cronos-x402

Cronos X402 Logo

This is an n8n community node that enables Agentic Payments, On-Chain Notarization, and Web3 Authentication on the Cronos EVM chain directly within your n8n workflows.

It is designed to help AI Agents pay for resources, accept payments, sign/verify messages, and create immutable audit logs.

n8n is a fair-code licensed workflow automation platform.

Features

  • Agentic Payments (x402): Send and receive payments autonomously using the ERC-20 standard and facilitator payment headers.
  • On-Chain Notarization: Write arbitrary text or JSON data to the blockchain for immutable audit logging and reputation tracking.
  • Web3 Authentication: Sign messages (SIWE - Sign In With Ethereum) and recover addresses to verify sender identity without transactions.
  • Smart Contract Interaction: Poll for event logs and check native token balances.

Installation

Community Node Install

You can install this node directly in your n8n instance:

  1. Go to Settings > Community Nodes.
  2. Select Install.
  3. Enter n8n-nodes-cronos-paytech.

Manual Install (For Development)

To install the node from the source code for local development:

  1. Clone this repository.
  2. Run npm install and npm run build && npm link.
  3. Link the package to your n8n installation:
    # In your n8n custom nodes directory (usually ~/.n8n/custom)
    rm node_modules/n8n-nodes-cronos-paytech  && npm link n8n-nodes-cronos-paytech
    
  4. Restart n8n.

Credentials

Cronos Wallet

  • Private Key: The private key of the wallet you wish to control.
  • Environment: Select Mainnet or Testnet.

Note: Credentials are optional for public actions like Recover Address, Generate Challenge, and Get Event Logs.

Operations

1. Payment Functions

  • Pay From Wallet (Client Mode): Sign a payment transaction or authorization for a resource. Used by agents to pay for services.
  • Generate Challenge (Merchant Mode): Create a 402 Payment Request. Used by services to request payment from agents.
  • Verify Payment (Merchant Mode): specific Verify valid payment headers received from a client.

2. Identity & Authentication

  • Sign Message (Auth): Sign a text message using the wallet's private key (compatible with EIP-191/SIWE).
  • Recover Address (Verify Auth): Recover the signer's public address from a message and signature. useful for verifying identity without gas fees.

3. Audit & Data

  • Notarize (Data): Write arbitrary text or compressed JSON data on-chain. Ideal for creating immutable audit logs of AI decisions.
  • Get Event Logs: Poll a smart contract for specific events (e.g., watching for a PaymentReceived event).

4. Utility

  • Get Balance: Check the native CRO balance of the connected wallet.

Usage Examples

AI Agent Paying for an API

  1. Generate Challenge: The API (Merchant) generates a payment challenge.
  2. Pay From Wallet: The AI Agent (Client) receives the challenge and signs a payment using this node.
  3. Verify Payment: The API verifies the payment header before releasing the resource.

Immutable Audit Log

  1. AI Decision: Your AI works through a complex reasoning chain.
  2. Compress: Summarize the decision to a short string or hash.
  3. Notarize: Use the Notarize action to write this summary to the Cronos blockchain.
  4. Verify: Anyone can later prove the AI made that specific decision at that time by checking the transaction data.

License

MIT

Discussion