Skip to content

Adfin API (1.0.0)

Adfin uses OAuth 2.0 access tokens to authenticate all API requests.

There are two contexts in which tokens are issued:

  • Biller Access Tokens — Generated via the Authorization Code flow when a biller connects their Adfin account. These tokens grant access to that biller's data (invoices, payment requests, customers, etc.).

  • Platform Access Tokens — Generated via the Client Credentials flow when a platform authenticates as itself rather than as one of its billers. A platform uses one to manage its own webhook subscriptions under /api/apps/{clientId}/webhooks.

Download OpenAPI description
Languages
Servers
Mock server
https://developer.adfin.com/_mock/api-docs/prod/
Production API Server URL
https://api.adfin.com/api/
Staging API Server URL
https://api.staging.adfin.com/api/

oAuth2

Operations

Biller

Operations

Verifications

Operations

Customers

Operations

Direct debit mandates

Operations

Invoices

Operations

Recurring invoices

Operations

Payment requests

Operations

Bulk import payment requests

Request

Security
Biller Access Token (Production) or Biller Access Token (Staging)
Query
collectionMethodstringrequired

How the imported payment requests are expected to be collected. Currently, only NONE is supported.

Enum"AUTO_COLLECT""ON_DEMAND""NONE"
Example: collectionMethod=NONE
deleteMissingPaymentRequestsbooleanrequired

Whether missing payment requests created in previous imports should be deleted.

Example: deleteMissingPaymentRequests=false
Bodymultipart/form-datarequired
inputFilestring(binary)required

Input file to be processed during the bulk import.

curl -i -X POST \
  'https://developer.adfin.com/_mock/api-docs/prod/payment_requests/bulk_import?collectionMethod=NONE&deleteMissingPaymentRequests=false' \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
  -H 'Content-Type: multipart/form-data' \
  -F inputFile=string

Responses

The bulk import request has been accepted for processing.

Bodyapplication/json
jobIdstringrequired

The internal id of the bulk import job

typestringrequired

The type of the import job

Value"BULK_PAYMENT_REQUEST_IMPORT"
statusstringrequired

The status of the import job

Enum"PENDING""PROCESSING""COMPLETED""FAILED""DELETED"
creationTimestring(date-time)required

The creation time of the import job

countsByItemStatusArray of objects(ReviewSessionItemCountByStatus)required

The count of items for each review session item status

countsByItemStatus[].​statusstringrequired

The status of review session item

Enum"PENDING""PROCESSING""COMPLETED""FAILED"
countsByItemStatus[].​countinteger(int32)required

The count of items for this status

Response
application/json
{ "jobId": "550e8400-e29b-41d4-a716-446655440000", "type": "BULK_PAYMENT_REQUEST_IMPORT", "status": "PENDING", "creationTime": "2024-01-15T10:30:00Z", "countsByItemStatus": [] }

Get the collection preferences for a payment request

Request

The values in force, after the agent's settings and every override are resolved.

Security
Biller Access Token (Staging) or Biller Access Token (Production)
Path
paymentRequestIdstring(uuid)required

The identifier of the payment request.

curl -i -X GET \
  'https://developer.adfin.com/_mock/api-docs/prod/payment_requests/{paymentRequestId}/collection_preferences' \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>'

Responses

The collection method and preferences in force.

Bodyapplication/json
collectionMethodstringrequired

The collection method in force.

Enum"AUTO_COLLECT""ON_DEMAND"
preferencesobject(CollectionPreferences)required
preferences.​paymentRemindersobject(PreferenceToggle)
preferences.​mandateRemindersobject(PreferenceToggle)
preferences.​cardRemindersobject(PreferenceToggle)
preferences.​directDebitEncouragementobject(PreferenceToggle)
preferences.​statementsobject(PreferenceToggle)
preferences.​lateFeesobject(LateFeesPreference)
preferences.​partialPaymentsobject(PartialPaymentsPreference)
preferences.​surchargingobject(PreferenceToggle)
Response
application/json
{ "collectionMethod": "AUTO_COLLECT", "preferences": { "paymentReminders": { … }, "mandateReminders": { … }, "cardReminders": { … }, "directDebitEncouragement": { … }, "statements": { … }, "lateFees": { … }, "partialPayments": { … }, "surcharging": { … } } }

Reset the collection preferences for a payment request

Request

Clears every override, not only these settings, including any set by Adfin or in the Adfin app. To turn a single setting off, PATCH it with an enabled of false instead; a pause set with :pause_collection survives.

Security
Biller Access Token (Staging) or Biller Access Token (Production)
Path
paymentRequestIdstring(uuid)required

The identifier of the payment request.

curl -i -X DELETE \
  'https://developer.adfin.com/_mock/api-docs/prod/payment_requests/{paymentRequestId}/collection_preferences' \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>'

Responses

The overrides held against the payment request are cleared. A payment request that holds none is left as it is.

Response
No content

Recurring payment requests

Operations

Payments

Operations

Payouts

Operations

Tax rates

Operations

Items

Operations

Activities

What has happened to a customer, invoice, payment request or schedule.

Operations

Scheduled Activities

What is planned next for a customer or a payment request.

Operations

Webhooks

Operations

Referrals

Operations