API ReferenceReferenceWebhooks
Register a webhook endpoint
Authorization
BearerAuth AuthorizationBearer <token>
Bearer token in the Authorization header. Key prefix determines
environment: lrn_test_ → Base Sepolia, lrn_live_ → Base mainnet.
In: header
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
application/json
curl -X POST "https://api.learncoin.me/v1/webhooks" \ -H "Content-Type: application/json" \ -d '{ "url": "http://example.com", "events": [ "batch.created" ] }'{
"id": "string",
"url": "http://example.com",
"events": [
"batch.created"
],
"signing_secret": "string",
"description": "string",
"active": true,
"created_at": "2019-08-24T14:15:22Z"
}{
"error": {
"code": "credential_not_found",
"message": "string",
"request_id": "req_01HXYZABCDEF"
}
}{
"error": {
"code": "credential_not_found",
"message": "string",
"request_id": "req_01HXYZABCDEF"
}
}