Overview
The "Nevermined Payments" node integrates with the Nevermined platform to manage AI-related payments, subscriptions, and access control. Specifically, the Order Plan operation allows users to place orders for subscription or credit plans using various payment methods including cryptocurrencies (USDC, Ethereum) and fiat options (credit card, bank transfer). This node is useful in scenarios where automated plan purchases are needed, such as buying multiple credits for AI API usage, managing subscription renewals, or applying promotional discounts.
Practical examples:
- A developer automates purchasing a bulk credit pack for an AI service using Ethereum.
- A business sets up recurring subscription payments via credit card with auto-renew enabled.
- A user redeems a promo code to get a discount on their plan order.
Properties
| Name | Meaning |
|---|---|
| Plan ID | The unique identifier of the plan to order. |
| Payment Method | The method used to pay for the order. Options: - Crypto - USDC - Crypto - ETH - Fiat - Credit Card - Fiat - Bank Transfer |
| Order Options | Additional options for the order: - Quantity: Number of plans to order (bulk purchase) - Recipient Address: Ethereum address to receive credits if different from payer - Promo Code: Promotional code for discount - Auto-Renew: Whether to automatically renew subscription plans (only for credit card or bank transfer payments) - Notes: Additional notes or references for the order |
Output
The output JSON object contains detailed information about the created order:
orderId: Unique identifier for the order.transactionId: Unique transaction identifier.planId: The ordered plan's ID.status: Current status of the order (initially "pending").paymentMethod: The selected payment method string.paymentDetails: Object describing payment type, subtype, and additional info depending on crypto or fiat:- For crypto: recipient address, network, required confirmations.
- For fiat: auto-renew flag, payment processor name.
pricing: Pricing breakdown including quantity, base price, subtotal, promo code details (if any), total amount, and currency.orderNotes: Optional notes provided by the user.createdAt: Timestamp when the order was created.expiresAt: Expiration timestamp for the order (30 minutes after creation).environment: Indicates whether the environment is production or test.message: Human-readable message about the order status and next steps.nextSteps: Array of instructions for completing the payment.- For fiat payments, additional fields:
paymentUrl: URL to complete payment.checkoutSessionId: Session ID for checkout.
- For crypto payments, additional fields:
paymentAddress: Ethereum address to send payment.paymentAmount: Amount in USD.paymentAmountInCrypto: Equivalent amount in cryptocurrency (ETH or USDC).
Dependencies
- Requires an API key credential for authenticating with the Nevermined Payments API.
- The node uses environment configuration to determine API base URLs for production or testing.
- No other external dependencies are required beyond standard HTTP requests to the Nevermined API endpoints.
Troubleshooting
- Missing or invalid Plan ID: The node throws an error if the Plan ID is not provided or empty. Ensure the Plan ID is correctly specified.
- Invalid quantity: Quantity must be at least 1; otherwise, an error is thrown.
- Invalid Ethereum address: If paying with crypto and specifying a recipient address, it must start with "0x". Otherwise, an error occurs.
- API Key missing: The node requires a valid API key credential; without it, execution fails.
- Payment method mismatch: Auto-renew option is only available for fiat payment methods (credit card or bank transfer). Using it with crypto will cause errors.
- Network or API errors: If the Nevermined API is unreachable or returns errors, the node will throw descriptive errors suggesting checking API keys and configurations.
To resolve errors, verify all required inputs, ensure correct formatting (especially JSON fields and addresses), and confirm API credentials and environment settings.