Articles in this section

How to Configure Webhooks in Learnly

Published:

Webhooks allow Learnly to send real-time notifications to your applications whenever specific events occur. Instead of repeatedly checking Learnly for updates, your application automatically receives an HTTP POST request whenever a subscribed event is triggered.

You can use webhooks to automate workflows, synchronize data with third-party systems, trigger notifications, and update external applications in real time.

What You Can Use Webhooks For

  • Sync learners with your HR or CRM system

  • Track course progress and completions

  • Issue certificates automatically

  • Notify external applications when enrollments occur

  • Create reports and dashboards in real time

  • Trigger custom automation workflows

Step 1: Open Webhooks

Navigate to 'Global Settings' and select 'Webhooks'.

1

Step 2: Create a New Webhook

Click '+ Create Webhook'.

2

Step 3: Configure the Webhook

Enter a 'Webhook Name' and paste the 'Endpoint URL'.

3

Step 4: Events to Subscribe

Select one or more events that should trigger the webhook.

A single endpoint can subscribe to multiple webhook events.

Available Webhook Events

Below are the events currently supported by Learnly.

EventDescriptionExample Use Case
course.startedTriggered when a learner starts a course.Notify managers that learning has begun.
course.completedTriggered when a learner completes a course.Update an HR system or award points.
course.module.completedTriggered when a course module is completed.Track module-level progress.
assessment.startedTriggered when an assessment begins.Record assessment attempts.
assessment.completedTriggered when an assessment is submitted.Send scores to another platform.
training.enrolledTriggered when a learner enrolls in training.Update CRM or onboarding systems.
training.completedTriggered when a training program is completed.Trigger follow-up training or notifications.
certificate.issuedTriggered when a certificate is issued.Send certificate information to HR or LinkedIn.
user.createdTriggered when a new user account is created.Synchronize users with external systems.
user.deletedTriggered when a user is removed.Remove access from integrated applications.
team.createdTriggered when a team is created.Sync organizational structures.
team.deletedTriggered when a team is deleted.Remove teams from external systems.
enrollment.createdTriggered when a learner is enrolled.Trigger welcome emails or onboarding.
enrollment.removedTriggered when a learner is unenrolled.Revoke external access automatically.

4

Step 5: Secret (Optional)

Enter a 'Secret' to verify incoming webhook requests using HMAC-SHA256, then click 'Create Webhook'.

Whenever one of the selected events occurs, Learnly sends an HTTP POST request to your endpoint.

5

Step 6: Test Webhook

After creating a webhook, it appears in the 'Webhooks' list. Click the arrow icon and select 'Test Webhook' to send a test request. A notification appears once the test has been sent.

6

Step 7: Manage Existing Webhooks

From here, you can 'Enable' or 'Disable' the webhook. 'Edit' its configuration, 'Copy URL' or 'Delete' the webhook.

7

Sample Webhook Payloads

Course Started

The Course Started webhook triggers when a learner begins a course for the first time. Use this event to notify managers, update learning dashboards, or start onboarding workflows.

{
  "id": "evt_100001",
  "resource": "course",
  "action": "started",
  "created_at": "2026-07-14T09:15:00Z",
  "payload": {
    "course_id": 101,
    "course_name": "Workplace Safety Essentials",
    "user_id": 5001,
    "learner_name": "John Doe",
    "email": "john.doe@example.com",
    "started_at": "2026-07-14T09:15:00Z"
  }
}

Course Completed

The Course Completed webhook triggers when a learner successfully completes a course. Use this event to update HR systems, award badges, or notify managers.

{
  "id": "evt_100002",
  "resource": "course",
  "action": "completed",
  "created_at": "2026-07-14T11:45:00Z",
  "payload": {
    "course_id": 101,
    "course_name": "Workplace Safety Essentials",
    "user_id": 5001,
    "learner_name": "John Doe",
    "completion_percentage": 100,
    "completed_at": "2026-07-14T11:45:00Z"
  }
}

Course Module Completed

The Course Module Completed webhook triggers when a learner completes an individual module within a course.

{
  "id": "evt_100003",
  "resource": "course.module",
  "action": "completed",
  "created_at": "2026-07-14T10:20:00Z",
  "payload": {
    "course_id": 101,
    "module_id": 8,
    "module_name": "Emergency Procedures",
    "user_id": 5001,
    "completed_at": "2026-07-14T10:20:00Z"
  }
}

Assessment Started

The Assessment Started webhook triggers when a learner begins an assessment.

{
  "id": "evt_100004",
  "resource": "assessment",
  "action": "started",
  "created_at": "2026-07-14T12:00:00Z",
  "payload": {
    "assessment_id": 205,
    "assessment_name": "Safety Knowledge Check",
    "user_id": 5001,
    "started_at": "2026-07-14T12:00:00Z"
  }
}

Assessment Completed

The Assessment Completed webhook triggers when a learner submits an assessment.

{
  "id": "evt_100005",
  "resource": "assessment",
  "action": "completed",
  "created_at": "2026-07-14T12:25:00Z",
  "payload": {
    "assessment_id": 205,
    "assessment_name": "Safety Knowledge Check",
    "user_id": 5001,
    "score": 92,
    "passed": true,
    "completed_at": "2026-07-14T12:25:00Z"
  }
}

Training Enrolled

The Training Enrolled webhook triggers when a learner enrolls in a training program.

{
  "id": "evt_100006",
  "resource": "training",
  "action": "enrolled",
  "created_at": "2026-07-14T08:30:00Z",
  "payload": {
    "training_id": 301,
    "training_name": "New Employee Onboarding",
    "user_id": 5001,
    "enrolled_at": "2026-07-14T08:30:00Z"
  }
}

Training Completed

The Training Completed webhook triggers when a learner completes a training program.

{
  "id": "evt_100007",
  "resource": "training",
  "action": "completed",
  "created_at": "2026-07-18T16:40:00Z",
  "payload": {
    "training_id": 301,
    "training_name": "New Employee Onboarding",
    "user_id": 5001,
    "completed_at": "2026-07-18T16:40:00Z"
  }
}

Certificate Issued

The Certificate Issued webhook triggers when Learnly issues a certificate after successful course or training completion.

{
  "id": "evt_100008",
  "resource": "certificate",
  "action": "issued",
  "created_at": "2026-07-18T16:45:00Z",
  "payload": {
    "certificate_id": 7001,
    "certificate_name": "Workplace Safety Certification",
    "user_id": 5001,
    "course_id": 101,
    "issued_at": "2026-07-18T16:45:00Z"
  }
}

User Created

The User Created webhook triggers when a new learner account is created.

{
  "id": "evt_100009",
  "resource": "user",
  "action": "created",
  "created_at": "2026-07-14T08:00:00Z",
  "payload": {
    "user_id": 5001,
    "name": "John Doe",
    "email": "john.doe@example.com",
    "role": "Learner",
    "created_at": "2026-07-14T08:00:00Z"
  }
}

User Deleted

The User Deleted webhook triggers when a user account is removed from Learnly.

{
  "id": "evt_100010",
  "resource": "user",
  "action": "deleted",
  "created_at": "2026-08-01T10:00:00Z",
  "payload": {
    "user_id": 5001,
    "name": "John Doe",
    "email": "john.doe@example.com",
    "deleted_at": "2026-08-01T10:00:00Z"
  }
}

Team Created

The Team Created webhook triggers when a new team is created in Learnly.

{
  "id": "evt_100011",
  "resource": "team",
  "action": "created",
  "created_at": "2026-07-14T09:00:00Z",
  "payload": {
    "team_id": 45,
    "team_name": "Sales Team",
    "manager": "Sarah Wilson",
    "created_at": "2026-07-14T09:00:00Z"
  }
}

Team Deleted

The Team Deleted webhook triggers when an existing team is deleted.

{
  "id": "evt_100012",
  "resource": "team",
  "action": "deleted",
  "created_at": "2026-08-02T17:15:00Z",
  "payload": {
    "team_id": 45,
    "team_name": "Sales Team",
    "deleted_at": "2026-08-02T17:15:00Z"
  }
}

Enrollment Created

The Enrollment Created webhook triggers when a learner is enrolled in a course or training.

{
  "id": "evt_100013",
  "resource": "enrollment",
  "action": "created",
  "created_at": "2026-07-14T08:10:00Z",
  "payload": {
    "enrollment_id": 9001,
    "user_id": 5001,
    "course_id": 101,
    "course_name": "Workplace Safety Essentials",
    "enrolled_at": "2026-07-14T08:10:00Z"
  }
}

Enrollment Removed

The Enrollment Removed webhook triggers when a learner is unenrolled from a course or training.

{
  "id": "evt_100014",
  "resource": "enrollment",
  "action": "removed",
  "created_at": "2026-08-05T14:30:00Z",
  "payload": {
    "enrollment_id": 9001,
    "user_id": 5001,
    "course_id": 101,
    "course_name": "Workplace Safety Essentials",
    "removed_at": "2026-08-05T14:30:00Z"
  }
}

Verify Your Endpoint

Once your webhook is created:

  1. Trigger one of the subscribed events.

  2. Confirm your endpoint receives an HTTP POST request.

  3. Validate the request using your webhook secret (if configured).

  4. Return an HTTP 200 OK response to acknowledge successful delivery.

You have successfully configured webhooks in Learnly. Webhooks provide a reliable way to receive real-time event notifications, helping you automate workflows, synchronize data with external applications, and build powerful integrations without manual intervention.

Was this article useful?
Like
Dislike
Help us improve this page
Please provide feedback or comments
Access denied
Access denied