Credits

Quote a credit pack

Prices one pack and says how it would be paid. When the account owner allowed purchases with the saved card in the app (Settings > Billing, up to a monthly limit), the key or connection belongs to the owner and the price fits the limits, the quote names the card and the purchase is charged at once; otherwise the purchase returns a payment link the user pays themselves and payment.saved_card.reason says why. Nothing is charged here. Show the quote to the person who pays and buy only after their yes. A quote holds for 24 hours; a saved-card purchase must follow within 15 minutes.

CostWhat it doesKey scopes
FreeReads onlyargorant:manage_lists
post/api/v1/credits/quote

Request

  • Base URL: https://app.argorant.com
  • URL: https://app.argorant.com/api/v1/credits/quote
  • Auth: HTTP bearer

Headers

Idempotency-Keystring

Any unique text up to 128 characters. A retry with the same key and the same body within 24 hours returns the first answer (with the header Idempotent-Replayed: true) instead of doing the work twice. The same key with another body answers 409 idempotency_conflict.

X-Request-Idstring

Your own id for this request, 8 to 64 letters, digits, dot, dash or underscore. Returned as X-Request-Id; one is made for you when you send none.

Request body

credits500 | 5000 | 25000 | 100000 required

Credits in the pack: 500, 5000, 25000 or 100000.

currency'usd' | 'eur'

usd (default) or eur.

Example request

{
  "credits": 5000
}

Response

OK

quote_idstring uuid

Pass to the purchase.

creditsinteger

Credits in the pack.

currencystring

Currency.

amount_centsinteger

Price in cents.

pricestring

Price as text.

valid_for_daysinteger

Days the credits stay valid.

expires_atstring date-time

When the quote ends.

summarystring

The quote in one sentence, ready to show to the person who pays.

paymentobject

How it would be paid: saved_card {usable, card, charge_before, reason} and a summary.

next_stepstring

What to do next.

Changes

No recorded changes to this operation across all 1 revision of this API.