Access Tokens allow secure, programmatic access to Hawzu APIs without requiring user login. They are designed for automation, integrations, and CI/CD pipelines and do not provide UI access.
Access Tokens are long-lived credentials that authenticate API requests.
They are commonly used for:
Access tokens are sent using the Authorization header.
Authorization: Bearer <ACCESS_TOKEN>
curl -H "Authorization: Bearer YOUR_ACCESS_TOKEN" \
https://api.hawzu.com/v1/test-runs
Access tokens are ideal for automated pipelines.
curl -X POST \
-H "Authorization: Bearer $HAWZU_ACCESS_TOKEN" \
-H "Content-Type: application/json" \
https://api.hawzu.com/v1/executions
Best Practice
import requests
headers = {
"Authorization": "Bearer YOUR_ACCESS_TOKEN",
"Content-Type": "application/json"
}
response = requests.get(
"https://api.hawzu.com/v1/testcases",
headers=headers
)
print(response.json())
import axios from "axios";
const api = axios.create({
baseURL: "https://api.hawzu.com/v1",
headers: {
Authorization: `Bearer ${process.env.HAWZU_TOKEN}`
}
});
const response = await api.get("/test-runs");
console.log(response.data);
Access tokens can be used with tools such as:
curl -H "Authorization: Bearer YOUR_ACCESS_TOKEN" \
-H "Content-Type: application/json" \
-d '{"status": "completed"}' \
https://api.hawzu.com/v1/webhooks/execution
An access token can be assigned to multiple projects, each with a specific project role.
Permissions are enforced per project, based on the assigned role.