Workflow
Deadline budget split API
Splits a total time budget across pipeline steps proportional to weights, reserving an optional safety margin and returning each step's budget and cumulative deadline. Answers 'How much time should each step get?', 'What is the deadline after each step?'.
Price$0.02per request
MethodPOST
Route/v1/workflow/deadline-budget
StatusLive
MIME typeapplication/json
Rate limit120/minute
Cache0s public
deadlinetimeoutbudgetsplitallocationpipelinetimeworkflow
API URL
Integration docshttps://x402.hexl.dev/v1/workflow/deadline-budgetExample request
{
"totalMs": 1000,
"steps": [
{
"name": "fetch",
"weight": 2
},
{
"name": "process",
"weight": 1
}
],
"reserveMs": 100
}Example response
{
"allocations": [
{
"name": "fetch",
"budgetMs": 600,
"deadlineAtMs": 600
},
{
"name": "process",
"budgetMs": 300,
"deadlineAtMs": 900
}
],
"usableMs": 900,
"reserveMs": 100,
"interpretation": "Split 900ms across 2 step(s) by weight; 100ms held in reserve."
}Input schema
{
"type": "object",
"required": [
"totalMs",
"steps"
],
"properties": {
"totalMs": {
"type": "number",
"examples": [
1000
]
},
"steps": {
"type": "array",
"examples": [
[
{
"name": "fetch",
"weight": 2
},
{
"name": "process",
"weight": 1
}
]
]
},
"reserveMs": {
"type": "number",
"examples": [
100
]
}
}
}Output schema
{
"type": "object",
"additionalProperties": true
}