CommandRegister a new RTSP camera

Register a new RTSP camera

Creates a new RTSP camera aggregate for a simple plug-and-play camera

curl -X POST "https://api.spkey.co/rtsp-cameras/example_string/RegisterRtspCamera" \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer YOUR_API_TOKEN (JWT)" \
  -H "X-API-Key: YOUR_API_KEY" \
  -d '{
  "rtspCameraId": "example_string",
  "name": "John Doe",
  "rtspUrl": "example_string",
  "httpSnapshotUrl": "example_string",
  "username": "John Doe",
  "password": "example_string",
  "ownerId": "example_string",
  "orgId": "example_string"
}'
{
  "success": true,
  "aggregateId": "example_string",
  "version": 3.14,
  "event": "null"
}
POST
/rtsp-cameras/{id}/RegisterRtspCamera
POST
Base URLstring

Target server for requests. Edit to use your own host.

Bearer Token (JWT)
Bearer Tokenstring
Required

JWT token from SmartphoneKey authentication. Identifies the B2C user or B2B service.

JWT token from SmartphoneKey authentication. Identifies the B2C user or B2B service.
API Key (header: X-API-Key)
X-API-Keystring
Required

API key for B2B organization access. Provided during organization onboarding.

API key for B2B organization access. Provided during organization onboarding.
path
idstring
Required

RTSP Camera UUID

Content-Typestring
Required

The media type of the request body

Options: application/json
rtspCameraIdstring
Required

Camera UUID (caller-supplied or server-generated)

namestring
Required

Human-readable camera name

Min length: 1
rtspUrlstring
Required

RTSP stream URL (e.g. rtsp://192.168.1.1:554/stream)

Min length: 1
httpSnapshotUrlstring

HTTP snapshot URL for still image capture

usernamestring

Camera authentication username

passwordstring

Camera authentication password

ownerIdstring

User ID who owns this camera (B2C)

orgIdstring

Organisation ID that owns this camera (B2B)

Request Preview
Response

Response will appear here after sending the request

Authentication

header
Authorizationstring
Required

Bearer token (JWT). JWT token from SmartphoneKey authentication. Identifies the B2C user or B2B service.

header
X-API-Keystring
Required

API Key for authentication. API key for B2B organization access. Provided during organization onboarding.

Path Parameters

idstring
Required

RTSP Camera UUID

Body

application/json
rtspCameraIdstring
Required

Camera UUID (caller-supplied or server-generated)

namestring
Required

Human-readable camera name

rtspUrlstring
Required

RTSP stream URL (e.g. rtsp://192.168.1.1:554/stream)

httpSnapshotUrlstring

HTTP snapshot URL for still image capture

usernamestring

Camera authentication username

passwordstring

Camera authentication password

ownerIdstring

User ID who owns this camera (B2C)

orgIdstring

Organisation ID that owns this camera (B2B)

Responses

successboolean
Required
aggregateIdstring
Required
versionnumber
Required
eventobject,null
Required