The HERO API provides a comprehensive and secure interface for integrating with our platform. This RESTful API enables seamless access to user management.
This documentation aims to provide all the information needed to work with our API.
Please read the documentation carefully. Below you will find a list of all the endpoints and their respective operations.
To authenticate requests, include an Authorization
header with the value "Bearer {YOUR_AUTH_KEY}"
.
All authenticated endpoints are marked with a requires authentication
badge in the documentation below.
To setup OAuth2 authentication please contact us at dev@horeca-hero.com.
APIs for managing users
Get a paginated list of users based on your client.
import requests
import json
url = 'https://horeca-hero.com/api-clients/v1/employees'
headers = {
'Authorization': 'Bearer {YOUR_AUTH_KEY}',
'Accept': 'application/json',
'Content-Type': 'application/json'
}
response = requests.request('GET', url, headers=headers)
response.json()
{
"data": [
{
"business_id": "business_live_87f15f0118f64e9fb9facaa95a24e2ab",
"employee_id": "user_54321",
"email": "john6@example.com",
"first_name": "John",
"last_name": "Doe",
"status": "inactive",
"role": "User",
"created_at": "2025-05-09T10:06:52.000000Z",
"updated_at": "2025-05-09T10:06:52.000000Z"
},
{
"business_id": "business_live_87f15f0118f64e9fb9facaa95a24e2ab",
"employee_id": "user_54321",
"email": "john7@example.com",
"first_name": "John",
"last_name": "Doe",
"status": "active",
"role": "User",
"created_at": "2025-05-09T10:07:34.000000Z",
"updated_at": "2025-05-09T10:07:34.000000Z"
}
],
"links": {
"first": "https://horeca-hero.com/api-clients/v1/employees?page=1",
"last": "https://horeca-hero.com/api-clients/v1/employees?page=2",
"prev": null,
"next": "https://horeca-hero.com/api-clients/v1/employees?page=2"
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 2,
"links": [
{
"url": null,
"label": "« Zurück",
"active": false
},
{
"url": "https://horeca-hero.com/api-clients/v1/employees?page=1",
"label": "1",
"active": true
},
{
"url": "https://horeca-hero.com/api-clients/v1/employees?page=2",
"label": "2",
"active": false
},
{
"url": "https://horeca-hero.com/api-clients/v1/employees?page=2",
"label": "Weiter »",
"active": false
}
],
"path": "https://horeca-hero.com/api-clients/v1/employees",
"per_page": 2,
"to": 2,
"total": 3
}
}
Create a user based on your body parameters.
import requests
import json
url = 'https://horeca-hero.com/api-clients/v1/employees'
payload = {
"business_id": "business_live_87f88f0888f64e8fb9facaa88a24e2ab",
"employee_id": "user_54321",
"email": "example@test.com",
"first_name": "John",
"last_name": "Doe",
"role": "User",
"status": "active"
}
headers = {
'Authorization': 'Bearer {YOUR_AUTH_KEY}',
'Content-Type': 'application/json',
'Accept': 'application/json'
}
response = requests.request('POST', url, headers=headers, json=payload)
response.json()
{
"data": {
"business_id": "business_live_87f88f0888f64e8fb9facaa88a24e2ab",
"employee_id": "user_54321",
"email": "example@test.com",
"first_name": "John",
"last_name": "Doe",
"status": "inactive",
"role": "User",
"created_at": "2025-05-09T10:06:52.000000Z",
"updated_at": "2025-05-09T10:06:52.000000Z"
}
}
Update a user based on your body parameters by the given client and user id.
The ID of the user.
import requests
import json
url = 'https://horeca-hero.com/api-clients/v1/employees/user_54321'
payload = {
"business_id": "business_live_87f88f0888f64e8fb9facaa88a24e2ab",
"employee_id": "user_54321",
"email": "example@test.com",
"first_name": "John",
"last_name": "Doe",
"role": "User",
"status": "active"
}
headers = {
'Authorization': 'Bearer {YOUR_AUTH_KEY}',
'Content-Type': 'application/json',
'Accept': 'application/json'
}
response = requests.request('PUT', url, headers=headers, json=payload)
response.json()
{
"data": {
"business_id": "business_live_87f88f0888f64e8fb9facaa88a24e2ab",
"employee_id": "user_54321",
"email": "example@test.com",
"first_name": "John",
"last_name": "Doe",
"status": "inactive",
"role": "User",
"created_at": "2025-05-09T10:06:52.000000Z",
"updated_at": "2025-05-09T10:06:52.000000Z"
}
}
Show user details based on your client and user id.
The ID of the user.
import requests
import json
url = 'https://horeca-hero.com/api-clients/v1/employees/user_54321'
headers = {
'Authorization': 'Bearer {YOUR_AUTH_KEY}',
'Content-Type': 'application/json',
'Accept': 'application/json'
}
response = requests.request('GET', url, headers=headers)
response.json()
{
"data": {
"business_id": "business_live_87f88f0888f64e8fb9facaa88a24e2ab",
"employee_id": "user_54321",
"email": "example@test.com",
"first_name": "John",
"last_name": "Doe",
"status": "inactive",
"role": "User",
"created_at": "2025-05-09T10:06:52.000000Z",
"updated_at": "2025-05-09T10:06:52.000000Z"
}
}
Delete a user based on the given client and user id.
The ID of the user.
import requests
import json
url = 'https://horeca-hero.com/api-clients/v1/employees/user_54321'
headers = {
'Authorization': 'Bearer {YOUR_AUTH_KEY}',
'Content-Type': 'application/json',
'Accept': 'application/json'
}
response = requests.request('DELETE', url, headers=headers)
response.json()
[Empty response]