POST
/endpoint/Register Webhook
Register webhook
Implementation Notes
This API call allows you to set up a WebHook that receives data generated by EventsShop.
- Once a WebHook is defined, data is automatically delivered to the specified endpoint.
- The WebHook will send POST requests with JSON payloads corresponding to
eventsinfo,eventimpact, orhoteldemanddata.
Authentication:
- The user must provide either Basic Auth (Username & Password) or OAuth 2.0 (Token).
- If Basic Auth is used, the system will generate a new token.
Supported Authentication Types:
"authType": "Basic Auth""authType": "OAuth 2.0"
Mandatory Fields:
- authType
- endpoint
Example Input 1 (Basic Auth):
{ "authType": "Basic Auth", "endpoint": "http://35.84.42.213:5000/", "userName": "events", "password": "*******", "token": "********" }
Example Input 2 (OAuth 2.0):
{ "authType": "OAuth 2.0", "endpoint": "http://35.84.42.213:5000/", "userName": "events", "password": "*******", "token": "********" }
POST
/endpoint/Parameter Details
| Name | In | Type | Required | Description |
|---|---|---|---|---|
body | body | object | Required | none |
» authType | body | string | Optional | Authentication method to use. |
» endpoint | body | string | Optional | URL of the WebHook endpoint. |
» userName | body | string | Optional | Username for Basic Auth (leave empty for OAuth 2.0). |
» password | body | string | Optional | Password for Basic Auth (leave empty for OAuth 2.0). |
» token | body | string | Optional | OAuth 2.0 Token (leave empty for Basic Auth). |
Responses
| Status | Meaning | Description | Schema |
|---|---|---|---|
| 202 | Accepted | Successfully registered the WebHook. | None |
| 400 | Bad Request | Bad Request | None |
| 401 | Unauthorized | Unauthorized | None |
| 429 | Too Many Requests | Too Many Requests | None |
| 500 | Internal Server Error | Internal Server Error. | None |
Example Request
# You can also use wget
curl -X POST https://api.events.example.com/api/v1/endpoint/ \
-H 'Content-Type: application/json' \
-H 'Authorization: Bearer {access-token}'
Example responses
202 Response
{
"authType": "Basic Auth",
"endpoint": "http://35.84.42.213:5000/",
"userName": "events",
"password": "*******",
"token": "********"
}Body parameter
{
"authType": "",
"endpoint": "",
"userName": "",
"password": "",
"token": "********"
}
Need Support?
Our team is here to help you integrate and make the most of our APIs. Get in touch for technical support, custom solutions, or any questions.