Peplink Portal Docs

Create a webhook

Create a webhook to push events to your endpoint.

For postpaid SIM service only

403 will be returned if your partner account does not have postpaid SIM service.

Your partner account can have up to 10 webhooks. See Overview for what your endpoint receives.

Required Capabilities

Webhook Manager

Request

POST/webhooks

Body parameters

namestringrequired

Name of the webhook.

urlstringrequired

URL to push events to. It must be an https URL on a public internet address; an address on a private network is refused.

tokenstringrequired

A secret of your choice, at least 16 characters, sent as Authorization: Bearer <token> with every push so your endpoint can verify the request.

eventTypesenum arrayrequired

Event types to subscribe to. At least 1 is required.

  • POSTPAID_SIM_USAGE_UPDATED — The live usage of one or more postpaid SIMs in your partner account changes

Response

200 The webhook is created successfully

A json of the created webhook is returned in the response body with the following fields:

idstring

ID of the webhook.

namestring

Name of the webhook.

urlstring

URL events are pushed to.

tokenstring

Token sent with every push, masked to its first and last 4 characters, e.g. s3cr...6789.

eventTypesenum array

Event types the webhook subscribes to.

  • POSTPAID_SIM_USAGE_UPDATED — The live usage of one or more postpaid SIMs in your partner account changes
createdAtdatetime string

Time of when the webhook is created.

createdBystring

Name of whom created the webhook.

createdByEmailnullable string

Email of whom created the webhook. null if not applicable.

updatedAtnullable datetime string

Time of when the webhook is updated. null if not applicable.

updatedBynullable string

Name of whom updated the webhook. null if not applicable.

updatedByEmailnullable string

Email of whom updated the webhook. null if not applicable.

400 Request is invalid

No webhook is created as the request is invalid, or your partner account already has 10 webhooks.

Check the response body for the error details.

Examples

Request

curl -X POST 'https://portal.peplink.com/api/e/v1/cp/webhooks' \  -H 'Authorization: Bearer {token}' \  -H 'Content-Type: application/json' \  --data-raw  '{"name": "Usage feed","url": "https://partner.example.com/peplink/events","token": "s3cr3t-token-0123456789","eventTypes": ["POSTPAID_SIM_USAGE_UPDATED"]}'

Response

{
  "id": "6704f1a2c3d4e5f6a7b8c9d0",
  "name": "Usage feed",
  "url": "https://partner.example.com/peplink/events",
  "token": "s3cr...6789",
  "eventTypes": ["POSTPAID_SIM_USAGE_UPDATED"],
  "createdAt": "2026-10-08T03:12:45.123Z",
  "createdBy": "Jane Doe",
  "createdByEmail": "[email protected]",
  "updatedAt": null,
  "updatedBy": null,
  "updatedByEmail": null
}

On this page