Query streams of a specific type
GET /api/event-stores/{eventStoreName}/stream-types/{streamType}/streams
GET
/api/event-stores/{eventStoreName}/stream-types/{streamType}/streams
Retrieves streams of a specific type with filtering options.
This endpoint provides a specialized query for streams of a particular type, making it easier to:
- Find all streams of a specific entity type (e.g., all user streams, all order streams)
- Monitor streams of a particular domain or business context
- Generate reports on specific types of streams
The streams are returned with their metadata, positions, and timestamps for further analysis.
Authorizations
Section titled “Authorizations ”Parameters
Section titled “ Parameters ”Path Parameters
Section titled “Path Parameters ” eventStoreName
required
Event store name (automatically scoped to your organization)
string
Event store name (automatically scoped to your organization)
streamType
required
The stream type to query (e.g., “user”, “order”, “cart”)
string
The stream type to query (e.g., “user”, “order”, “cart”)
Query Parameters
Section titled “Query Parameters ” streamId
string
streamIdPattern
string
minPosition
string
maxPosition
string
fromDate
string format: date-time
toDate
string format: date-time
includeArchived
string
includeMetadata
string
limit
string
offset
string
sortBy
string
sortDirection
string
includeCount
string
Responses
Section titled “ Responses ”Type-specific streams retrieved successfully
object
streams
required
Array<object>
object
streamId
required
string
streamPosition
required
number
streamType
required
string
streamMetadata
object
key
additional properties
isArchived
required
boolean
lastArchivedPosition
required
number
createdAt
required
ISO 8601 formatted timestamp in UTC
string
updatedAt
required
ISO 8601 formatted timestamp in UTC
string
pagination
required
object
limit
required
number
offset
required
number
total
number
hasMore
required
boolean
Examples
User streams example
Example of query results for user streams
{ "streams": [ { "streamId": "user-123", "streamPosition": 5, "streamType": "user", "streamMetadata": { "tenant": "example-tenant", "tags": [ "important", "customer" ] }, "isArchived": false, "lastArchivedPosition": 0, "createdAt": "2023-01-15T12:30:45Z", "updatedAt": "2023-01-16T09:15:30Z" }, { "streamId": "user-456", "streamPosition": 2, "streamType": "user", "streamMetadata": { "tenant": "example-tenant" }, "isArchived": false, "lastArchivedPosition": 0, "createdAt": "2023-01-17T10:22:15Z", "updatedAt": "2023-01-17T10:25:18Z" } ], "pagination": { "limit": 100, "offset": 0, "total": 2, "hasMore": false }}Invalid query parameters
object
error
required
string
details
required
Array<object>
object
code
required
string
message
required
string
path
required
Array
Unauthorized: Organization ID not found in authentication context
object
error
required
string
message
required
string
Examples
{ "error": "UNAUTHORIZED", "message": "Unauthorized: Organization ID not found in authentication context"}