Managing Streams
A stream is a logical entity created through the Stream Management APIs. It allows you to organize telemetry data from resources that share the same set of subscriptions.
Prerequisites
-
To use Observability APIs, the user must have the
Fabric Stream Subscription Manager
role. -
Submit your user credentials, Client ID, and Client Secret for OAuth2 authentication. Refer to API Authentication for more information on how to authenticate your requests to the Equinix API.
Creating Streams
Once your Assets are created, you will need to create a Stream to manage these Assets. Send a POST
request to the /fabric/v4/streams
endpoint to create a Stream.
Sample cURL request:
curl -X 'POST' 'https://api.equinix.com/fabric/v4/streams' \
-H 'Content-Type: application/json' \
-H 'Authorization: Bearer <Bearer Token>' \
-d '{
"type": "TELEMETRY_STREAM",
"name": "splunk1",
"description": "subscription 1",
"project": {
"projectId": "<projectId>"
}
}'
Sample Response:
{
"uuid": "241372e9-79c9-4ef8-b77a-8b8176c2098b4",
"href": "https://api.equinix.com/fabric/v4/streams/241372e9-79c9-4ef8-b77a-8b8176c228b4",
"type": "TELEMETRY_STREAM",
"name": "splunk1",
"description": "subscription 1",
"project": {
"projectId": "<projectId>"
},
"enabled": true,
"state": "PROVISIONING",
"assetsCount": 0,
"streamSubscriptionsCount": 0,
"changelog": {
"createdBy": "testuser",
"createdDateTime": "2024-08-12T21:14:17.689103902Z"
}
}
Retrieving Streams
To get the details of a Stream, send a GET
request to the /fabric/v4/streams/{stream_id}
endpoint.
Sample cURL Request:
curl -X 'GET' 'https://api.equinix.com/fabric/v4/streams/241372e9-79c9-4ef8-b77a-8b8176c2098b4' \
-H 'Content-Type: application/json' \
-H 'Authorization: Bearer <Bearer Token>'
Sample Response:
{
"href": "https://api.equinix.com/fabric/v4/streams/241372e9-79c9-4ef8-b77a-8b8176c228b4",
"uuid": "241372e9-79c9-4ef8-b77a-8b8176c2098b4",
"type": "STREAM_SUSBSCRIPTION",
"name": "splunk1",
"description": "subscription 1",
"project": {
"projectId": "<projectId>"
},
"enabled": true,
"state": "PROVISIONED",
"changelog": {
"createdBy": "testuser",
"createdDateTime": "2024-08-12T21:14:17.689104Z"
}
}
Deleting Streams
To delete a stream, send a DELETE
request to the /fabric/v4/streams/{stream_id}
endpoint.
Sample cURL Request:
curl -X 'DELETE' 'https://api.equinix.com/fabric/v4/streams/241372e9-79c9-4ef8-b77a-8b8176c2098b4' \
-H 'Content-Type: application/json' \
-H 'Authorization: Bearer <Bearer Token>'