This quickstart walks through a complete Line of Credit draw lifecycle: you check the credit line, request a draw that auto-disburses, observe accrued fees, repay using USDC from your Circle Mint wallet (or by wire as a fallback), and confirm the transfer closes out. For the conceptual model behind these calls, see the Credit API concept page.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, make sure that you’ve:- Contacted your Circle representative to activate Line of Credit on your Circle Mint account.
- Confirmed your Circle Mint wallet holds the required USDC
minBalancefor your credit line. - Configured API authentication per
Getting Started. Examples below
use
$API_KEYand the base URLhttps://api-sandbox.circle.com. - Identified the
fiatAccountIdof a wire bank account if you intend to use wire repayment as a fallback in Step 2.
Step 1. Check the credit line
CallGET /v1/credit to confirm your credit line is active and has sufficient
capacity for the draw.
productislineOfCredit.available.amountcovers the draw amount you plan to request.validationErrorsis an empty array.
validationErrors is non-empty, resolve each entry before requesting a draw:
INSUFFICIENT_BALANCE: top up your Circle Mint USDC wallet to at least the credit line’sminBalance.PENDING_FEES: wait for pending fees to settle, or repay them withPOST /v1/credit/cryptoRepayment.OVERDUE_TRANSFERS: repay overdue transfers by wire or crypto repayment to clear the block.
Step 2. Get wire repayment instructions (optional fallback)
Line of Credit supports crypto repayment directly from your Circle Mint wallet, so wire instructions are only needed if you plan to repay by wire. To retrieve them, callGET /v1/credit/repaymentAccounts/{fiatAccountId} with the ID of the
wire bank account you’ll send from.
unverified until Circle matches the first incoming
wire repayment to it, after which it transitions to active.
Step 3. Request a draw
CallPOST /v1/credit/transfers with an idempotency key and the draw amount. To
use Credit Express, include the optional destination field to disburse
directly to a verified address from your Circle Mint recipient address book;
omit it to land the disbursement in your Mint wallet. Line of Credit draws
auto-disburse—no manual review is required.
id from the response—it identifies this draw for the
remaining steps. The transfer starts in requested and transitions
automatically to disbursed once funds land in your Mint wallet, or onchain at
the verified address if you supplied a destination. For details on the
blockchain destination, see
Credit Express.
Step 4. Observe disbursement and fee accrual
Once the transfer isdisbursed, recurringFee begins accruing against the
outstanding balance at the credit line’s cadence.
4.1. Poll the transfer
CallGET /v1/credit/transfers/{id} to inspect the disbursement, due date, and
accrued fees.
outstanding amount is the principal plus accrued fees. For hourly cadence,
fees accrue every hour and the dueDate is 24 hours after disbursedDate; for
daily cadence, fees accrue every 24 hours and the dueDate is 7 days after
disbursedDate. See
fee cadence and repayment timing
for the underlying model.
If you supplied a Credit Express destination, the blockchainDestination
block tracks the onchain leg separately from the credit transfer. The
blockchainDestination.transferId references the underlying Circle Mint
transfer once disbursement initiates onchain.
4.2. Subscribe to webhooks
For asynchronous updates, subscribe tocreditTransfers, creditFees, and
creditRepayments in the Circle Mint Console. Webhook payloads mirror the
corresponding GET endpoints. See
webhook topics for what each
topic publishes.
Step 5. Repay with crypto (the fast path)
CallPOST /v1/credit/cryptoRepayment with the amount you want to apply against
the outstanding balance. The endpoint deducts USDC from your Circle Mint wallet
at the time of the call.
- The requested amount is capped at the outstanding balance across the credit line. A request that exceeds the cap returns HTTP 400.
- Crypto repayment is Line of Credit only. Settlement Advance does not support this endpoint—see the Settlement Advance quickstart for SA repayment.
Step 6. Repay with a wire (alternative)
If you prefer fiat repayment, wire USD to Circle using thewireInstructions
from Step 2. The trackingRef on the wire lets Circle match the payment to your
credit line.
In the sandbox, simulate the wire by posting a mock repayment:
Step 7. Confirm the repayment
List repayments filtered to your transfer by callingGET /v1/credit/repayments?transferId={id} and confirm a record exists with
status: completed. The type is crypto for repayments from Step 5 or fiat
for wire repayments from Step 6. Wire repayments initially return
status: pending and transition to completed once Circle matches the inbound
wire, so you may need to poll until settlement; the example below shows the
final settled state.
paymentAmount is the total repayment received and amountApplied is the
portion applied to this transfer’s outstanding balance (principal plus fees).
Then call GET /v1/credit/transfers/{id} again and confirm the transfer is
paid.
status: paid, outstanding is zero, and fees.unpaid
is zero—the draw lifecycle is complete.