Online Onboarding Webhooks
Introduction
This guide details how to integrate Lemonway’s webhook notifications into your application to manage both individual and/or legal entity onboarding. It encompasses the entire flow—from account creation to final status updates and includes best practices for ensuring reliability.
Overview
Webhooks let Lemonway notify your application when important events occur, such as account creation, profile status changes, and KYC compliance decisions. By listening for these events, you can:
- Track onboarding progress in near real-time.
- Update your internal records and user interfaces automatically.
- Take appropriate actions (e.g., sending reminders or restricting functionality) if the onboarding stalls or is denied.
Account Creation and Status
Endpoints
- Individual Accounts:
POST /accounts/individual
- Legal Entity Accounts:
POST /accounts/legal-entity
Typical Flow
- Create an Account: You call the relevant endpoint to register an individual or legal entity.
- Account Creation Response: Lemonway responds with:
accountId
: The unique identifier for the account.accountStatus
: Usuallycreated
, meaning the account was created.
- Possible Account Status Values:
- created: Account is successfully registered but not yet validated.
- accepted: Account is activated; a wallet is created. Onboarding is complete.
- denied: Account is refused due to regulatory or compliance reasons. Onboarding process ends.
Webhook Notifications (ID: 50)
When an account status changes, a webhook is sent:
{
"EventDate": "2025-03-14T16:44:55.883",
"AccountID": "37373",
"ProfileID": "93843",
"IntId": "32",
"ExtId": "jdkc",
"Status": "2"
}
Where Status
can be:
1
= Created2
= Accepted3
= Denied
Onboarding Profiles
Onboarding Endpoints
If the account requires additional data, call one of the onboarding endpoints:
POST /onboardings/individual
POST /onboardings/company
POST /onboardings/association
POST /onboardings/sole-trader
Response:
onboardingID
: Unique IDonboardingUrl
: A link for collecting further information and documentation.
Profile Status
Once the onboarding is initiated, a profile is created to track the specific onboarding steps. Lemonway will notify you when the profile progresses through various stages.
Common Profile Statuses:
- creation_in_progress: No onboarding required.
- awaiting_information: Onboarding required.
- information_collection_in_progress: The end-user is in the process of providing data/documents.
- identity_verification_in_progress: The end-user is completing an identity verification workflow.
- under_analysis: The end-user has submitted the form, and Lemonway’s team is reviewing.
- accepted: Lemonway approved the profile.
- denied: Lemonway declined onboarding.
- rejected: Additional info is still needed; the end-user must resubmit.
Webhook Notifications (ID: 49)
When a profile status changes, a webhook is sent:
{
"EventDate": "2025-03-14T16:44:55.883",
"AccountID": "37373",
"ProfileID": "454545",
"IntId": "32",
"ExtId": "jdkc",
"Status": "2"
}
Where Status
can be:
1
= Onboarding in progress2
= Under analysis3
= Accepted4
= Denied5
= Rejected
Webhook Handling Strategy
- Set Up Webhook Endpoints: Configure URL endpoints in your system to receive the
Account status
(ID 50) andProfile status
(ID 49) notifications. - Authentication & Security:
- Use HTTPS and verify that requests originate from Lemonway.
- Process Incoming Webhooks:
- Parse the JSON payload.
- Identify the
Status
and update your database records.
- Follow Up:
- If
Status
isaccepted
, enable relevant user functionality. - If
Status
isdenied
, notify the user or mark the process as closed. - If
Status
isrejected
, prompt the user to provide missing documents.
- If
- Error Handling:
- Implement retries and handle potential duplicate notifications.
- Store logs for troubleshooting.
Best Practices
- Perform a GET after receiving a notification if real-time accuracy is crucial, as some notifications may arrive with a delay.
- Poll if Needed: If webhooks are delayed, consider periodic checks for status updates.
- Track Timelines: KYC processing may take minutes or up to 48 hours.
By integrating Lemonway webhooks effectively, you ensure that your platform remains in sync with the latest onboarding events. This reduces friction for end-users and helps maintain compliance with regulatory requirements. If you have any questions about handling specific statuses or require further assistance, consult the official Lemonway documentation or contact our support team.
Updated 19 days ago