Batch Create Vision Events
Record up to 100 Vision Events in a single request to ingest many observations at once.
About
This endpoint records multiple Vision Events in a single request, up to 100 at a time. Use it when a deployment needs to ingest many observations at once, which is more efficient than creating events individually. To record a single event, see Create a Vision Event.
HTTP API
Create up to 100 vision events in a single request. This is more efficient than creating events individually when you need to ingest multiple events at once.
Required scope: vision-events:write or device:update
Create up to 100 vision events in a single request. Each event is checked the same way as in Create a Vision Event. If any event fails the required field check, no event is stored and the error names the event's index. An empty events array stores nothing and returns created 0. Requires the vision-events:write or device:update scope.
Roboflow API key passed as a Bearer token.
Events created successfully.
Number of events created.
Deprecated field names used in the request.
events is missing or has more than 100 items, or one event fails the required field check.
Insufficient permissions for this resource.
POST /vision-events/batch HTTP/1.1
Host: api.roboflow.com
Authorization: Bearer YOUR_SECRET_TOKEN
Content-Type: application/json
Accept: */*
Content-Length: 346
{
"events": [
{
"eventId": "f47ac10b-58cc-4372-a567-0e02b2c3d479",
"eventType": "quality_check",
"useCaseId": "a1b3c8e1",
"timestamp": "2024-01-15T10:30:00Z",
"eventData": {
"result": "pass"
}
},
{
"eventId": "9c4d6a2e-81f3-4b7a-bc9e-3f1a2d4e5c6b",
"eventType": "quality_check",
"useCaseId": "a1b3c8e1",
"timestamp": "2024-01-15T10:31:00Z",
"eventData": {
"result": "fail"
}
}
]
}{
"created": 2,
"eventIds": [
"f47ac10b-58cc-4372-a567-0e02b2c3d479",
"9c4d6a2e-81f3-4b7a-bc9e-3f1a2d4e5c6b"
]
}Each event is validated the same way as a single event. See Validation and Warnings.
Python SDK
Create multiple vision events in a single request. The server allows up to 100 events per batch.
Each event in the list follows the same schema as a single event. For full details on event schemas and validation behavior, see the REST API reference.
Last updated
Was this helpful?