> For the complete documentation index, see [llms.txt](https://docs.podplay.app/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.podplay.app/api/replay-servers-device-auth.md).

# Replay Servers Device Auth

## POST /replay-servers/device

>

```json
{"openapi":"3.0.0","info":{"title":"PodPlay Inc API","version":"2.0"},"tags":[{"name":"Replay Servers - Device Auth"}],"servers":[{"url":"/apis/v2","description":"Current Server"}],"paths":{"/replay-servers/device":{"post":{"operationId":"ReplayServersDeviceController_create","parameters":[],"requestBody":{"required":true,"description":"Register a new device","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RegisterDeviceDto"}}}},"responses":{"200":{"description":"Returns server ID for polling status","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RegisterDeviceResponseDto"}}}}},"tags":["Replay Servers - Device Auth"]}}},"components":{"schemas":{"RegisterDeviceDto":{"type":"object","properties":{"deviceId":{"type":"string","description":"Unique device identifier (e.g., Mac mini MAC address or UUID)"},"hostname":{"type":"string","description":"Device hostname for display"},"version":{"type":"string","description":"Software version running on the device"},"displayName":{"type":"string","description":"Display name for the device (set during first-time setup)"},"serverUrl":{"type":"string","description":"External DDNS or URL where this server is reachable"},"localIp":{"type":"string","description":"Local network IP address of the device"}},"required":["deviceId"]},"RegisterDeviceResponseDto":{"type":"object","properties":{"serverId":{"type":"string","description":"The server ID to use for polling status","readOnly":true},"status":{"type":"string","description":"Current status of the registration","enum":["PENDING","APPROVED","REVOKED"],"readOnly":true},"pollInterval":{"type":"number","description":"Recommended polling interval in seconds","readOnly":true},"displayName":{"type":"string","description":"Existing display name (if already set)","readOnly":true}},"required":["serverId","status","pollInterval"]}}}}
```

## GET /replay-servers/device/{serverId}/status

>

```json
{"openapi":"3.0.0","info":{"title":"PodPlay Inc API","version":"2.0"},"tags":[{"name":"Replay Servers - Device Auth"}],"servers":[{"url":"/apis/v2","description":"Current Server"}],"paths":{"/replay-servers/device/{serverId}/status":{"get":{"operationId":"ReplayServersDeviceController_getStatus","parameters":[{"name":"serverId","required":true,"in":"path","description":"The server ID from registration","schema":{"type":"string"}},{"name":"version","required":false,"in":"query","description":"Current software version running on the device","schema":{"type":"string"}},{"name":"serverUrl","required":false,"in":"query","description":"External DDNS or URL where this server is reachable","schema":{"type":"string"}},{"name":"localIp","required":false,"in":"query","description":"Local network IP address of the device","schema":{"type":"string"}}],"responses":{"200":{"description":"Returns current status and token when approved","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeviceStatusResponseDto"}}}},"404":{"description":"Server not found"}},"tags":["Replay Servers - Device Auth"]}}},"components":{"schemas":{"DeviceStatusResponseDto":{"type":"object","properties":{"status":{"type":"string","description":"Current status","enum":["PENDING","APPROVED","REVOKED"],"readOnly":true},"accessToken":{"type":"string","description":"The access token (only when approved)","readOnly":true},"area":{"description":"Area the server is assigned to (only when approved)","readOnly":true,"allOf":[{"$ref":"#/components/schemas/ItemRefDto"}]},"pendingUpdate":{"description":"Pending update information (only when an update is available)","allOf":[{"$ref":"#/components/schemas/PendingUpdateDto"}]},"config":{"description":"Server configuration to apply","allOf":[{"$ref":"#/components/schemas/ReplayServerConfigDto"}]}},"required":["status"]},"ItemRefDto":{"type":"object","properties":{"id":{"type":"string","description":"The unique identifier of the resource"}},"required":["id"]},"PendingUpdateDto":{"type":"object","properties":{"version":{"type":"string","description":"Target version to update to","readOnly":true}},"required":["version"]},"ReplayServerConfigDto":{"type":"object","properties":{"apiBaseUrl":{"type":"string","description":"API base URL for pairing"},"gcpStorageBucket":{"type":"string","description":"GCP storage bucket name"},"logoPath":{"type":"string","description":"Path to logo overlay image"},"logoPlacement":{"type":"string","description":"Logo placement","enum":["bottom-right","bottom-center"]},"gcpCredentialsPath":{"type":"string","description":"Path to GCP credentials JSON file"},"postrollPath":{"type":"string","description":"Path to postroll video file"},"cleanupEnabled":{"type":"boolean","description":"Enable auto-cleanup of old chunks and clips"},"cameras":{"description":"Camera configurations","type":"array","items":{"$ref":"#/components/schemas/CameraConfigDto"}}}},"CameraConfigDto":{"type":"object","properties":{"id":{"type":"string","description":"Camera ID"},"name":{"type":"string","description":"Camera name"},"feed":{"type":"string","description":"RTSP feed URL"},"feed2":{"type":"string","description":"Secondary RTSP feed URL"},"isEnabled":{"type":"boolean","description":"Whether the camera is enabled"},"videoCodec":{"type":"string","description":"Video codec","enum":["h264","h265"]},"audioCodec":{"type":"string","description":"Audio codec","enum":["aac","alaw","mulaw"]},"distortion1":{"type":"number","description":"Lens distortion correction 1"},"distortion2":{"type":"number","description":"Lens distortion correction 2"},"rotation":{"type":"number","description":"Image rotation in degrees"},"scale":{"type":"number","description":"Image scale factor"},"vignette":{"type":"number","description":"Vignette effect intensity"},"lutPath":{"type":"string","description":"Path to LUT file for color grading"}},"required":["id","name","feed","isEnabled"]}}}}
```


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.podplay.app/api/replay-servers-device-auth.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
