You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit f7c6952
Browse filesBrowse the repository at this point in the historyBrowse files
Job status transitions follow: `queued` → `processing` → `completed`or `failed`. The `output` field is only present when status is `completed`.
133
+
Execution status transitions follow: `queued` → `running` → `completed`, `failed`, `cancelled`, or `paused`. The `data.output` field is populated for completed executions when `includeOutput=true`.
133
134
</Callout>
134
135
135
136
## Response Format
136
137
137
-
Successful responses include an `output` object with your workflow results and a `limits` object with your current rate limit and usage status:
138
+
Successful v2 responses wrap the run resource in `data`:
138
139
139
140
```json
140
141
{
141
-
"success": true,
142
-
"output": {
143
-
"result": "Hello, world!"
144
-
},
145
-
"limits": {
146
-
"workflowExecutionRateLimit": {
147
-
"sync": {
148
-
"requestsPerMinute": 60,
149
-
"maxBurst": 10,
150
-
"remaining": 59,
151
-
"resetAt": "2025-01-01T00:01:00Z"
152
-
},
153
-
"async": {
154
-
"requestsPerMinute": 30,
155
-
"maxBurst": 5,
156
-
"remaining": 30,
157
-
"resetAt": "2025-01-01T00:01:00Z"
158
-
}
159
-
},
160
-
"usage": {
161
-
"currentPeriodCost": 1.25,
162
-
"limit": 50.00,
163
-
"plan": "pro",
164
-
"isExceeded": false
165
-
}
142
+
"data": {
143
+
"runId": "c7a92e15-3f4b-4d8c-a1e6-9b0d5f2c8e74",
144
+
"workflowId": "{workflowId}",
145
+
"status": "completed",
146
+
"output": { "result": "Hello, world!" },
147
+
"error": null,
148
+
"durationMs": 842
166
149
}
167
150
}
168
151
```
169
152
170
153
## Error Handling
171
154
172
-
The API uses standard HTTP status codes. Error responses include a human-readable`error` message:
155
+
The API uses standard HTTP status codes. v2 errors include a stable code and human-readable message:
173
156
174
157
```json
175
158
{
176
-
"error": "Workflow not found"
159
+
"error": {
160
+
"code": "NOT_FOUND",
161
+
"message": "Workflow not found"
162
+
}
177
163
}
178
164
```
179
165
@@ -186,12 +172,12 @@ The API uses standard HTTP status codes. Error responses include a human-readabl
186
172
|`429`| Rate limit exceeded | Wait for the duration in the `Retry-After` header |
187
173
188
174
<Callouttype="info">
189
-
Use the [Get Usage Limits](/api-reference/billing/getBillingStatus)endpoint to check your current rate limit status and billing usage at any time.
175
+
Use [Get Billing Status](/api-reference/billing/getBillingStatus) to inspect current credit and storage usage.
190
176
</Callout>
191
177
192
178
## Rate Limits
193
179
194
-
Rate limits depend on your subscription plan and apply separately to synchronous and asynchronous executions. Every execution response includes a `limits` object showing your current rate limit status.
180
+
Rate limits depend on your subscription plan and apply separately to synchronous and asynchronous executions.
195
181
196
182
When rate limited, the API returns a `429` response with a `Retry-After` header indicating how many seconds to wait before retrying.
Job status transitions follow: `queued` → `processing` → `completed`or `failed`. The `output` field is only present when status is `completed`.
133
+
Execution status transitions follow: `queued` → `running` → `completed`, `failed`, `cancelled`, or `paused`. The `data.output` field is populated for completed executions when `includeOutput=true`.
133
134
</Callout>
134
135
135
136
## Response Format
136
137
137
-
Successful responses include an `output` object with your workflow results and a `limits` object with your current rate limit and usage status:
138
+
Successful v2 responses wrap the run resource in `data`:
138
139
139
140
```json
140
141
{
141
-
"success": true,
142
-
"output": {
143
-
"result": "Hello, world!"
144
-
},
145
-
"limits": {
146
-
"workflowExecutionRateLimit": {
147
-
"sync": {
148
-
"requestsPerMinute": 60,
149
-
"maxBurst": 10,
150
-
"remaining": 59,
151
-
"resetAt": "2025-01-01T00:01:00Z"
152
-
},
153
-
"async": {
154
-
"requestsPerMinute": 30,
155
-
"maxBurst": 5,
156
-
"remaining": 30,
157
-
"resetAt": "2025-01-01T00:01:00Z"
158
-
}
159
-
},
160
-
"usage": {
161
-
"currentPeriodCost": 1.25,
162
-
"limit": 50.00,
163
-
"plan": "pro",
164
-
"isExceeded": false
165
-
}
142
+
"data": {
143
+
"runId": "c7a92e15-3f4b-4d8c-a1e6-9b0d5f2c8e74",
144
+
"workflowId": "{workflowId}",
145
+
"status": "completed",
146
+
"output": { "result": "Hello, world!" },
147
+
"error": null,
148
+
"durationMs": 842
166
149
}
167
150
}
168
151
```
169
152
170
153
## Error Handling
171
154
172
-
The API uses standard HTTP status codes. Error responses include a human-readable`error` message:
155
+
The API uses standard HTTP status codes. v2 errors include a stable code and human-readable message:
173
156
174
157
```json
175
158
{
176
-
"error": "Workflow not found"
159
+
"error": {
160
+
"code": "NOT_FOUND",
161
+
"message": "Workflow not found"
162
+
}
177
163
}
178
164
```
179
165
@@ -186,12 +172,12 @@ The API uses standard HTTP status codes. Error responses include a human-readabl
186
172
|`429`| Rate limit exceeded | Wait for the duration in the `Retry-After` header |
187
173
188
174
<Callouttype="info">
189
-
Use the [Get Usage Limits](/api-reference/billing/getBillingStatus)endpoint to check your current rate limit status and billing usage at any time.
175
+
Use [Get Billing Status](/api-reference/billing/getBillingStatus) to inspect current credit and storage usage.
190
176
</Callout>
191
177
192
178
## Rate Limits
193
179
194
-
Rate limits depend on your subscription plan and apply separately to synchronous and asynchronous executions. Every execution response includes a `limits` object showing your current rate limit status.
180
+
Rate limits depend on your subscription plan and apply separately to synchronous and asynchronous executions.
195
181
196
182
When rate limited, the API returns a `429` response with a `Retry-After` header indicating how many seconds to wait before retrying.
0 commit comments