The authorization header
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 for Adfin's own integrations and system events. These tokens authenticate Adfin as the platform itself (not as a specific biller) and are required for endpoints like
/api/webhook.
Download OpenAPI description
Languages
Servers
Mock server
https://developer.adfin.com/_mock/products/direct-integration/direct-integration-api-reference/
Production API Server URL
https://api.adfin.com/api/
Staging API Server URL
https://api.staging.adfin.com/api/
- Mock serverhttps://developer.adfin.com/_mock/products/direct-integration/direct-integration-api-reference/oauth2/token
- Production API Server URLhttps://api.adfin.com/api/oauth2/token
- Staging API Server URLhttps://api.staging.adfin.com/api/oauth2/token
- curl
- JavaScript
- Node.js
- Python
- Java
- C#
- PHP
- Go
- Ruby
- R
- Payload
curl -i -X POST \
'https://developer.adfin.com/_mock/products/direct-integration/direct-integration-api-reference/oauth2/token?grant_type=string&client_id=string&client_secret=string&code=string&refresh_token=string&redirect_uri=string&scope=string' \
-H 'Authorization: Bearer <YOUR_TOKEN_HERE>'Response
application/json
AccessTokenExample
{ "access_token": "eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCIsImtpZCI6IjV0ZGx6cUxiZ3ZVTXJ6SC1WZVZrZyJ9.eyJpc3MiOiJodHRwczovL2F1dGhlbnRpY2F0aW9uLnN0YWdpbmcuYWRmaW4uY29tLyIsInN1YiI6IkpkandtWEZPMXdqOGN2OXFtbEhFM2xoaVpVZWFqTlpYQGNsaWVudHMiLCJhdWQiOiJodHRwczovL3N0YWdpbmctYXV0aC1hZGZpbi5ldS5hdXRoMC5jb20vYXBpL3YyLyIsImlhdCI6MTc2MTI5NjA2NiwiZXhwIjoxNzYxMzAzMjY2LCJzY29wZSI6ImNyZWF0ZTpjbGllbnRfY3JlZGVudGlhbHMgcmVhZDpjbGllbnRfY3JlZGVudGlhbHMgdXBkYXRlOmNsaWVudF9jcmVkZW50aWFscyBkZWxldGU6Y2xpZW50X2NyZWRlbnRpYWxzIiwiZ3R5IjoiY2xpZW50LWNyZWRlbnRpYWxzIiwiYXpwIjoiSmRqd21YRk8xd2o4Y3Y5cW1sSEUzbGhpWlVlYWpOWlgifQ.V2K-38NuyrDkTlu5-4b8g3oIrPWjT8ESIJ7DqB9iawwjYsLGGCU1sPxIK974l6GQVRdF904IeDdLBJc4bLR-G0odtcTM9_SQpHFeZOTUi9WhIh-T_v81VvAN6j_OTW2qA30LfSGPQHJD6Z0fAAHpWqLVkFksuifCxi7LyJ6ufCI9FtoYz6XsG_AMaSbk71dEoc56ChjskXCofi5fmgDH1jZukj_oyzk00IURTpzmB3DjhZI_3TrDTk5tXjxmORiLM8yakJji6s0vqNxSGHUSWxCuMObbCrqeq7jYaUMzPDMhfwllBsGw5tQf1iAA1LUWgNRDjNgTqeY3Mk5oZVTEST", "expires_in": 7200, "token_type": "Bearer" }
- Mock serverhttps://developer.adfin.com/_mock/products/direct-integration/direct-integration-api-reference/oauth2/revoke
- Production API Server URLhttps://api.adfin.com/api/oauth2/revoke
- Staging API Server URLhttps://api.staging.adfin.com/api/oauth2/revoke
- curl
- JavaScript
- Node.js
- Python
- Java
- C#
- PHP
- Go
- Ruby
- R
- Payload
curl -i -X POST \
'https://developer.adfin.com/_mock/products/direct-integration/direct-integration-api-reference/oauth2/revoke?client_id=string&client_secret=string&token=string' \
-H 'Authorization: Bearer <YOUR_TOKEN_HERE>'