Adjútor from Lendsqr
API ReferenceLendsqr
  • Introduction
    • Overview
    • Getting Started
    • Test and Live mode
    • Making your first API call
    • Webhooks
  • Authentication
    • Authentication Type
    • Generating your API key
  • USE CASES
    • Introduction
    • Loan repayment with Direct Debit
    • Corporate Cash and Treasury Management
    • Buy Now Pay Later (BNPL)
    • Embedded Credit/ Finance
    • Loan scoring/ Credit scoring
    • Customer Validation
    • Implementing GSI with Direct Debit
  • Adjutor API Endpoints
    • Oraculi Mobile SDK (Beta)
      • Installing the SDK
      • The Oraculi SDK data journey
    • Validation
      • Bank Verification Number
      • Bank Account Verification
      • Karma Lookup
      • Ecosystem Lookup
    • Decisioning
      • Decision Model Lookup
      • Oraculi scoring
    • Credit Bureaus
    • Direct Debit
      • How Direct Debit works
      • The Direct Debit process
      • Understanding Mandate Statuses
    • Embedded Loans and Payments
    • Platform Data
      • Data for Lenders
      • Operational Services
    • Transactions and Balances with Kolo
      • Initializing Authorization
      • Using your access token
      • Permission Scopes
    • Core Services
  • ADDITIONAL INFORMATION
    • FAQs
    • Getting Support
    • Pricing
    • Glossary
Powered by GitBook
On this page
  • Step 1: Obtain Authorization Code
  • Step 2: Exchange Authorization Code for Access Token
  • Step 3: Receive the Access Token

Was this helpful?

  1. Adjutor API Endpoints
  2. Transactions and Balances with Kolo

Initializing Authorization

In order to gain access to the customer's data using Kolo's API, you need to initialize the authorization process. This involves exchanging an authorization code for an access token, which will allow you to interact with the other API endpoints securely and with consent.

Step 1: Obtain Authorization Code

In order to obtain an authorization code, you need to redirect users to the Kolo authorization URL so they can grant you consent to access their data. Here’s the format of the authorization URL:

GET https://app.kolo.finance/data-share?response_type=code&client_id={CLIENT_ID}&redirect_uri={REDIRECT_URI}&scope={SCOPE}
Parameter
Description

response_type

Set this to code to receive an authorization code.

client_id

Your Adjutor application's client ID. You get this when creating an app on Adjutor.

redirect_uri

The URI to redirect to after authorization.

scope

The scope of the access request (e.g., transaction:list).

Example Request:

GET https://app.kolo.finance/data-share?response_type=code&client_id=your_client_id&redirect_uri=https://app.adjutor.io&scope=transaction:list

Step 2: Exchange Authorization Code for Access Token

Once the user authorizes your application and grants you access, they will be redirected back to your specified redirect_uri with an authorization code. You need to exchange this code for an access token. Using this access token, you can then call the other endpoints. The format for this can be found below:

POST https://adjutor.lendsqr.com/v2/kolo/auth

Request Body:

code=authorization_code&grant_type=authorization_code&redirect_uri=https://app.adjutor.io
Parameter
Description

code

The authorization code received from the previous step.

grant_type

Set this to authorization_code.

redirect_uri

The same redirect URI used in the authorization request.

Example Request:

curl --location 'https://adjutor.lendsqr.com/v2/kolo/auth' \
--data '{
    "redirect_uri": "https://app.adjutor.io",
    "grant_type": "authorization_code",
    "code": "kEhA1fQsT86ZxCqh"
}'

Step 3: Receive the Access Token

If the request is successful, you will receive a response containing the access token and other related information.

Example Response:

{
    "access_token": "your_access_token",
    "refresh_token": "your_refresh_token",
    "username": "username",
    "scope": "transaction:list",
    "token_type": "Bearer"
}
Parameter
Description

access_token

The token to be used for authenticated requests

token_type

Type of token, typically "Bearer".

username

The name of the user

refresh_token

Token used to refresh the access token.

scope

Scopes granted by the access token

By following these steps, you can successfully initialize the authorization process and start using the Kolo API to access customer financial data securely.

PreviousTransactions and Balances with KoloNextUsing your access token

Last updated 9 months ago

Was this helpful?