const response = await fetch("https://algapsa.com/api/v1/time-entries/bulk", {
method: "POST",
headers: {
"X-API-Key": "$ALGA_API_KEY",
"Content-Type": "application/json",
},
body: JSON.stringify({
"entries": [
{
"work_item_id": "01HN2K7VRB9PQ3Y0000000000",
"work_item_type": "ticket",
"start_time": "2026-04-18T15:22:14Z",
"end_time": "2026-04-18T15:22:14Z",
"notes": "string",
"service_id": "01HN2K7VRB9PQ3Y0000000000",
"tax_region": "string",
"tax_rate_id": "01HN2K7VRB9PQ3Y0000000000",
"contract_line_id": "01HN2K7VRB9PQ3Y0000000000",
"is_billable": true
}
]
})
});
const data = await response.json();