Quickstart
Let your users connect their cards so their agent can pay on their behalf from the Agentcard Wallet — setup to payment in five steps.
Agentcard lets your users connect their cards so their agent can make payments on their behalf using cards from the Agentcard Wallet. Your users add their cards once; from then on their agent pays merchants with a card from the wallet — the card details are handed to the agent just in time and are never stored by Linq.
Prerequisites
Section titled “Prerequisites”- A Linq organization with API access. Create an API token at
dashboard.linqapp.com/api-tooling
and send it on every request as
Authorization: Bearer <LINQ_API_KEY>. - Base URL:
https://api.linqapp.com/api/partner/v3. - A webhook endpoint to receive payment and connection events (see Webhooks & lifecycle).
The five steps
Section titled “The five steps”-
Connect the provider (once)
Onboard your organization to Agentcard from the Linq dashboard — go to Payments and connect Agentcard. Do this a single time per org.
-
Connect a customer
Start a connection for a customer handle (phone in E.164, or email). Linq drives the one-time code and consent through the messaging channel; hold the returned
connect_id.Terminal window curl -X POST https://api.linqapp.com/api/partner/v3/payments/handles/+14155550123/connect \-H "Authorization: Bearer $LINQ_API_KEY"When the customer replies with their code, complete the connection:
Terminal window curl -X POST https://api.linqapp.com/api/partner/v3/payments/handles/+14155550123/verify \-H "Authorization: Bearer $LINQ_API_KEY" \-H "Content-Type: application/json" \-d '{ "connect_id": "cs_01HZY8", "code": "482913" }'Full walkthrough with screens: Connect a customer.
-
Create a payment
Call the payments endpoint with the handle,
amount_cents, currency, and merchant. Send anIdempotency-Keyso a retry never double-charges.Terminal window curl -X POST https://api.linqapp.com/api/partner/v3/payments \-H "Authorization: Bearer $LINQ_API_KEY" \-H "Idempotency-Key: $(uuidgen)" \-H "Content-Type: application/json" \-d '{"handle": "+14155550123","amount_cents": 2500,"currency": "usd","description": "Burger order","merchant": { "name": "DoorDash", "url": "doordash.com" }}'amount_cents: 2500is $25.00 — amounts are always in the currency’s minor units. -
Retrieve the card
When the payment is
ready, fetch the credential handoff. Your agent uses it to read the card directly from Agentcard — the number never passes through Linq.Terminal window curl https://api.linqapp.com/api/partner/v3/payments/550e8400-e29b-41d4-a716-446655440000/credentials \-H "Authorization: Bearer $LINQ_API_KEY"See Cards & credentials for the handoff shape and how the agent redeems it.
-
Track the lifecycle
Subscribe to webhooks instead of polling:
payment.authorized,payment.declined,connection.created, andconnection.revoked. Treat the event as a nudge and re-fetch the payment for authoritative status — there is nopayment.succeededwebhook, so pollGET /payments/{id}for the finalsucceededstate.
- Amounts are in the currency’s minor units —
amount_cents(cents forusd). - A payment is idempotent on the
Idempotency-Keyheader. - Card credentials are fetched directly from Agentcard and are never stored by Linq.
- Connect a customer — connect and verify, with screens.
- Create & complete a payment — statuses and retrieval.
- Webhooks & lifecycle — events and payloads.
- Agentcard vs Stripe — pick the right rail.