Skip to main content
Credits and paymentFastclinic Credits

Payment through a shared credit ledger

One credit balance per person or organisation. Your service holds credits when work starts, captures what was used and releases the hold if the work does not take place. Retried requests do not charge twice.

  • OAuth 2.0
  • Idempotent operations
  • Hold and capture

What you can connect to

  • Balance checks. Confirm whether a person has sufficient credits before a service starts.
  • Hold, capture and release. Reserve credits when work begins, capture what was actually used, or release the whole hold if the work does not take place.
  • Refunds. Reverse a captured charge, once.
  • History. Show a person or an organisation their credit movements within your product.
  • Organisation accounts. Bill an organisation instead of an individual, with limits per person and spending caps.

How a charge works

  1. Hold

    When a service starts, your application places a hold on the person's balance. The credits are set aside but remain theirs.

  2. Capture or release

    When the service ends, capture what was used. If the service is cancelled or does not take place, release the hold and the credits return at once.

  3. Holds expire

    Every hold has a lifetime. If you do not capture or release it in time, Fastclinic Credits releases it automatically, so credits do not remain on hold indefinitely.

Idempotent retries

Every operation carries a reference derived from the work it belongs to. If the same request is sent twice, after a timeout or a dropped connection, it resolves to the same ledger entry instead of charging again. A payment notification that arrives twice counts once.

The ledger is append-only. Entries are not edited or deleted, each entry records the resulting balance, and concurrent charges against the same balance cannot corrupt it.

Standards

  • OAuth 2.0 tokens from Fastclinic Account identify your service, with the same sign-in used everywhere else at Fastclinic.
  • Idempotent operations throughout, each keyed on a reference derived from the work.
  • One credit equals one naira. Top-ups go through Paystack, so card details never reach Fastclinic.

Getting access

If your service should charge against a person's or an organisation's credits, contact us and we will take you through the integration.