Payment Intents Overview
Description
The Payment Intent API group provides a robust set of endpoints to manage and process cryptocurrency payments, focusing on stablecoins like USDC and USDT. Designed for merchants and developers, it enables the creation, retrieval, listing, and cancellation of payment intents, offering seamless integration with blockchain-based transactions across multiple chains such as Base and Ethereum.
API Endpoints
- Create Payment Intent: Generates a payment intent for direct wallet transfers with a one-time address.
- Get Payment Intent: Fetches details of a specific payment intent.
- List Payment Intents: Returns a paginated list of payment intents.
- Cancel Payment Intent: Cancels a payment intent and updates its status.
API Endpoint Reference
| Method | Endpoint | Description |
|---|---|---|
| POST | /v1/payment_intents | Creates a new payment intent for a transaction. |
| GET | /v1/payment_intents/:id | Retrieves details of a specific payment intent. |
| GET | /v1/payment_intents?offset=0&limit=10 | Lists payment intents with pagination. |
| POST | /v1/payment_intents/:id/cancel | Cancels a payment intent by its ID. |
The PaymentIntent Object
The PaymentIntent object represents the details of a payment intent. It is returned by various endpoints in this group.
Attributes
| Attribute | Type | Description |
|---|---|---|
id | string | Unique identifier for the payment intent (e.g., pay_t24b28nbodnk4icGMyE7). |
account_id | string | ID of the account associated with the intent. |
payer_address | string or null | Address of the payer, if provided. |
one_time_address | string | One-time address for the payer to send funds (e.g., 0xa1A0340cF7b9326eA4210AB49c17e20e0c32a2FB). |
chain | string | Blockchain chain used (e.g., base). |
amount | string | Total amount to be paid (e.g., 15.0). |
currency | string | Currency of the transaction (e.g., USDC). |
amount_received | string | Amount received so far (e.g., 0.0). |
description | string or null | Optional description of the payment intent. |
metadata | object or null | Additional metadata, if provided. |
customer_id | string or null | ID of the customer, if associated. |
customer_email | string or null | Customer email, if provided. |
status | string | Current status of the payment intent (e.g., requires_payment_method). |
tx_hash | string or null | Transaction hash, if available. |
created_at | timestamp | Time when the payment intent was created. |
updated_at | timestamp | Time when the payment intent was last updated. |
expired_at | timestamp or null | Time when the payment intent expires. |
Status Enum
The status field indicates the current state of the payment intent. Possible values are:
requires_payment_method: The payment intent requires a payment method to be provided.requires_confirmation: The payment intent is awaiting confirmation from the user or system.requires_additional_payment: Additional payment is needed to complete the intent.confirmed: The payment intent has been confirmed and is being processed.succeeded: The payment intent has successfully completed.canceled: The payment intent has been canceled.failed: The payment intent failed due to an error.