Appearance
Printer-attached cameras
This page is for internal cameras connected directly to the printer by cable. The printer registers such a camera itself and receives its camera token.
Not for other cameras
For any other camera, create it in Prusa Connect or the Prusa app instead. See getting a token.
Flow
Register the camera
POST https://connect.prusa3d.com/p/cameraHeaders
| Header | Value |
|---|---|
Token | The printer's LINK token (20 characters), found in the printer's details in Prusa Connect |
Fingerprint | The camera's fingerprint (16-64 characters), unique per camera |
Content-Type | application/json |
Token is the printer's, Fingerprint is the camera's
In this request, Token is the printer's LINK token, not a camera token. Fingerprint is the camera's fingerprint, not the printer's. Send the same camera fingerprint in the header and in the body, and use it for every later Camera Service call.
The camera fingerprint must be unique per camera. Never reuse the printer's fingerprint or share one value between cameras. See choosing a fingerprint.
Body
| Field | Type | Required | Description |
|---|---|---|---|
fingerprint | string | yes | The camera's fingerprint, 16-64 characters, unique and stable per camera, same as the Fingerprint header |
config | object | yes | Must contain name |
config.name | string | yes | Camera name |
Other fields are accepted but not used for registration. Send the camera's details with PUT /v1/camera-info after registering.
json
{
"fingerprint": "b94d27b9934d3e08a52e52d7da7dabfa",
"config": { "name": "Internal camera" }
}Response
200 with an empty body. The camera token is in the Token response header:
HTTP/1.1 200 OK
Token: T0nSPU2v05v0pJeKYFYVExample
sh
curl -i -X POST https://connect.prusa3d.com/p/camera \
-H "Token: $printer_token" \
-H "Fingerprint: $camera_fingerprint" \
-H "Content-Type: application/json" \
-d '{"fingerprint": "'"$camera_fingerprint"'", "config": {"name": "Internal camera"}}'Behaviour
- Idempotent. Registering the same camera fingerprint for the same printer again returns the same camera token. It is safe to call on every boot.
- Fingerprint bound immediately. The camera fingerprint is bound to the token at registration, so the 15-minute registration window does not apply.
- Camera type. A new camera gets the type
LINK. Re-registering keeps an existing type. Report the real type indevice.typewithPUT /v1/camera-info, see camera types. - Another printer. The same camera fingerprint on a different printer registers a new camera with a new token.
Errors
Errors on this endpoint come from Prusa Connect, not the Camera Service, so they do not use the Camera Service error shape.
| Status | Cause |
|---|---|
| 400 | Invalid body, for example a missing fingerprint or config.name |
| 401 | Missing Token or Fingerprint header |
| 403 | Invalid printer token, or the camera fingerprint is too short |
| 503 | Prusa Connect or the Camera Service is unavailable, retry later |
Next
Use the camera token and the camera fingerprint for every Camera Service call: