Use the Stablecoin Payins API to accept an onchain USDC or EURC payment into your Circle Mint account. You create a payment intent, share the deposit address that Circle assigns, and then confirm the payment after the customer transfers funds. For background on how payment intents and payments relate to one another, see Stablecoin payins and payouts.Documentation Index
Fetch the complete documentation index at: https://developers.circle.com/llms.txt
Use this file to discover all available pages before exploring further.
Prerequisites
Before you begin:- Stablecoin Payins is enabled on your Circle Mint account. Activation is scoped to the Americas (Circle LLC)—contact your Circle representative or reach out through the Circle Mint contact form to request access.
- You have a Circle Mint sandbox API key. See Getting started for setup.
- You have selected a blockchain that the Stablecoin Payins API supports. The Payins API supports a narrower set of blockchains than the Payouts API. See Supported chains and currencies to confirm coverage.
- You have a
merchantWalletIdfor the wallet that receives settled funds. You do not need a funded Mint account—this is a receive flow.
Steps
Create a payment intent
Send a The response includes the intent
POST request to /v1/paymentIntents to create a payment intent. Use
continuous mode, the default, unless you need a fixed-amount,
single-checkout intent.id and a timeline showing the created
status. The deposit address is not yet populated.Transient variant
Transient variant
To create a fixed-amount, single-use intent, set
type to transient and
include an amount. The deposit address that Circle assigns is single-use and
the intent expires after expiresOn. Send the same POST /v1/paymentIntents
request with this body instead:Get the deposit address
Circle assigns the deposit address asynchronously after the intent is created.
Use webhooks or polling to retrieve it.For memo-based blockchains such as Stellar (XLM) and Hedera (HBAR), the payment
method also includes an
- Webhook
- Polling
Subscribe to
paymentIntents notifications. When Circle assigns the address,
you receive a payload whose paymentMethods[0].address is populated and whose
timeline advances to pending.addressTag. If your customer’s wallet enforces memos,
they must include this tag when sending funds.Customer transfers funds
Display the deposit address (and
addressTag if applicable) to your customer.
The customer sends USDC or EURC to that address from their wallet. This step
takes place outside the API.Confirm the payment
After the onchain transfer settles, Circle creates a
payment object linked to
the intent. The intent’s own state machine differs by mode:- Continuous intents stay at
active. The intent timeline does not advance tocomplete, and the intent’spaymentIdsarray is not populated. Reconcile each settled transfer through thepaymentswebhook or by listing payments withGET /v1/payments?paymentIntentId={id}. - Transient intents transition to
completeafter the single expected transfer settles. The latest timeline entry carries a context ofpaid,underpaid, oroverpaid, and the intent’spaymentIdsarray lists the settled payments.
- Webhook (any intent)
- Polling (continuous)
- Polling (transient)
A For transient intents only, a
payments notification fires whenever an inbound transfer settles. The
payload includes the payment status, the originating fromAddresses, the
onchain transactionHash, and the paymentIntentId that links the payment back
to its intent. This works the same for continuous and transient intents.paymentIntents notification also fires when the
intent reaches complete, with a new timeline entry whose status is
complete and whose context describes the outcome (paid, underpaid, or
overpaid). Continuous intents do not produce this notification.Handle completion contexts (transient intents)
Completion contexts apply only to transient intents, because they have a target amount to compare against. Continuous intents stay atactive and never reach
complete, so no context is produced.
When a transient intent reaches complete, the context on the latest timeline
entry tells you how the amount paid compares to what was expected. Each context
calls for a different downstream action.
| Context | Meaning | Typical handling |
|---|---|---|
paid | The customer paid the expected amount. For transient intents, amountPaid equals amount. | Fulfill the order. |
underpaid | The customer paid less than the expected amount on a transient intent. | Refund the partial payment or contact the customer to top up. See Refund a stablecoin payin. |
overpaid | The customer paid more than expected. | Refund the excess to the sender, or refund the full amount and ask the customer to retry. |
See also
- Stablecoin payins and payouts: Concepts for payment intents, payments, and refunds.
- Refund a stablecoin payin: How to issue a full or partial refund.
- Supported chains and currencies: Confirm which blockchains the Payins API supports.
- Notifications quickstart:
Subscribe to
paymentIntentsandpaymentswebhooks.