Follow these steps:
-
Log in to the FOXBOX console
Open your browser and log in with your user (e.g. admin).
-
Open the user settings
In the top-right corner, click on your username (e.g. ADMINISTRATOR).
From the dropdown menu, select Settings.
-
Go to the user/app configuration page
The User configuration / Application options page will open (like in the screenshot).
-
Enable webservices
Locate the Enable webservices field and set it to Yes.
Save or apply the changes if required (depending on your interface version).
-
Retrieve the Webservices token
On the same page, find the Webservices token field.
This field shows your token, for example:
cc524fe5d8f4b01474291e25fa86ee2d
Write down this token: you will use it as parameter h in all API calls (e.g. h=xxxxxxxxxxxxxxxxxxxxxxxx).
-
(Optional) Configure the Webservices IP range
If you want to restrict API usage to specific IPs, set the Webservices IP range field.
Otherwise, leave it with the default configuration.
-
Quick API test using the token
Once webservices are enabled and you’ve copied your token, you can run a quick test, for example by querying your credit:
curl -k "https://foxbox.local/ws/credit?u=admin&h=YOUR_TOKEN_HERE"
If everything is configured correctly, you will receive a JSON response:
{
"status": "OK",
"error": "0",
"credit": 1000000,
"error_string": null,
"timestamp": 1762709990
}
That’s it! Your FOXBOX Webservices API is now active and ready to use.