{"openapi":"3.1.0","info":{"title":"MooM Beam API","description":"API-first rolling recording, live monitoring and durable clip export. All editorial ranges are half-open UTC intervals. API bearer credentials are required.","version":"0.1.0"},"paths":{"/health/live":{"get":{"tags":["Health"],"summary":"Live","operationId":"live_health_live_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/health/ready":{"get":{"tags":["Health"],"summary":"Ready","operationId":"ready_health_ready_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/v1/auth/login":{"post":{"tags":["Accounts"],"summary":"Login","operationId":"login_v1_auth_login_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LoginBody"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LoginOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/auth/me":{"get":{"tags":["Accounts"],"summary":"Me","operationId":"me_v1_auth_me_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserOut"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/auth/logout":{"post":{"tags":["Accounts"],"summary":"Logout","operationId":"logout_v1_auth_logout_post","responses":{"204":{"description":"Successful Response"}},"security":[{"HTTPBearer":[]}]}},"/v1/auth/password":{"post":{"tags":["Accounts"],"summary":"Change Password","operationId":"change_password_v1_auth_password_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ChangePassword"}}},"required":true},"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/users":{"get":{"tags":["Accounts"],"summary":"Users","operationId":"users_v1_users_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/UserOut"},"type":"array","title":"Response Users V1 Users Get"}}}}},"security":[{"HTTPBearer":[]}]},"post":{"tags":["Accounts"],"summary":"Create User","operationId":"create_user_v1_users_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/NewUser"}}},"required":true},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/users/{user_id}":{"patch":{"tags":["Accounts"],"summary":"Update User","operationId":"update_user_v1_users__user_id__patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"user_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"User Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserPatch"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/users/{user_id}/password":{"post":{"tags":["Accounts"],"summary":"Reset Password","operationId":"reset_password_v1_users__user_id__password_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"user_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"User Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/NewPassword"}}}},"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/recorders":{"get":{"tags":["Recorders"],"summary":"List Recorders","operationId":"list_recorders_v1_recorders_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/RecorderOut"},"type":"array","title":"Response List Recorders V1 Recorders Get"}}}}},"security":[{"HTTPBearer":[]}]},"post":{"tags":["Recorders"],"summary":"Create Recorder","operationId":"create_recorder_v1_recorders_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RecorderCreate"}}},"required":true},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RecorderOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/recorders/{recorder_id}":{"get":{"tags":["Recorders"],"summary":"Get Recorder","operationId":"get_recorder_v1_recorders__recorder_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"recorder_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Recorder Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RecorderOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["Recorders"],"summary":"Patch Recorder","operationId":"patch_recorder_v1_recorders__recorder_id__patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"recorder_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Recorder Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RecorderPatch"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RecorderOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/recorders/{recorder_id}/start":{"post":{"tags":["Recorders"],"summary":"Start","operationId":"start_v1_recorders__recorder_id__start_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"recorder_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Recorder Id"}}],"responses":{"202":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RecorderOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/recorders/{recorder_id}/stop":{"post":{"tags":["Recorders"],"summary":"Stop","operationId":"stop_v1_recorders__recorder_id__stop_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"recorder_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Recorder Id"}}],"responses":{"202":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RecorderOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/recorders/{recorder_id}/cache":{"get":{"tags":["Cache"],"summary":"Cache","operationId":"cache_v1_recorders__recorder_id__cache_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"recorder_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Recorder Id"}},{"name":"start","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Start"}},{"name":"end","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"End"}},{"name":"cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Cursor"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":2000,"minimum":1,"default":500,"title":"Limit"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CachePage"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/recorders/{recorder_id}/playback.m3u8":{"get":{"tags":["Cache"],"summary":"Playback","operationId":"playback_v1_recorders__recorder_id__playback_m3u8_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"recorder_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Recorder Id"}},{"name":"start","in":"query","required":true,"schema":{"type":"string","format":"date-time","title":"Start"}},{"name":"end","in":"query","required":true,"schema":{"type":"string","format":"date-time","title":"End"}}],"responses":{"200":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/segments/{segment_id}/media":{"get":{"tags":["Cache"],"summary":"Media","operationId":"media_v1_segments__segment_id__media_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"segment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Segment Id"}}],"responses":{"200":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/clips":{"post":{"tags":["Clips"],"summary":"Create Clip","operationId":"create_clip_v1_clips_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"idempotency-key","in":"header","required":false,"schema":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Idempotency-Key"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ClipCreate"}}}},"responses":{"202":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ClipOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["Clips"],"summary":"Clips","operationId":"clips_v1_clips_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":500,"minimum":1,"default":100,"title":"Limit"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/ClipOut"},"title":"Response Clips V1 Clips Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/clips/{clip_id}":{"get":{"tags":["Clips"],"summary":"Clip","operationId":"clip_v1_clips__clip_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"clip_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Clip Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ClipOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/clips/{clip_id}/retry":{"post":{"tags":["Clips"],"summary":"Retry","operationId":"retry_v1_clips__clip_id__retry_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"clip_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Clip Id"}}],"responses":{"202":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ClipOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/clips/{clip_id}/download":{"get":{"tags":["Clips"],"summary":"Download","operationId":"download_v1_clips__clip_id__download_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"clip_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Clip Id"}},{"name":"range","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Range"}}],"responses":{"200":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/recorders/{recorder_id}/thumbnail":{"get":{"tags":["Live"],"summary":"Thumbnail","operationId":"thumbnail_v1_recorders__recorder_id__thumbnail_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"recorder_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Recorder Id"}}],"responses":{"200":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/live/ice-servers":{"get":{"tags":["Live"],"summary":"Ice Servers","operationId":"ice_servers_v1_live_ice_servers_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/recorders/{recorder_id}/whep":{"post":{"tags":["Live"],"summary":"Whep","operationId":"whep_v1_recorders__recorder_id__whep_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"recorder_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Recorder Id"}}],"responses":{"200":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"requestBody":{"required":true,"content":{"application/sdp":{"schema":{"type":"string"}}}}}},"/v1/recorders/{recorder_id}/whep/{session_id}":{"delete":{"tags":["Live"],"summary":"Whep Session","operationId":"delete_whep_session","security":[{"HTTPBearer":[]}],"parameters":[{"name":"recorder_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Recorder Id"}},{"name":"session_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Session Id"}}],"responses":{"200":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["Live"],"summary":"Whep Session","operationId":"patch_whep_session","security":[{"HTTPBearer":[]}],"parameters":[{"name":"recorder_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Recorder Id"}},{"name":"session_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Session Id"}}],"responses":{"200":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}}},"components":{"schemas":{"CachePage":{"properties":{"segments":{"items":{"$ref":"#/components/schemas/CacheSegment"},"type":"array","title":"Segments"},"next_cursor":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Next Cursor"},"window_start":{"type":"string","title":"Window Start"},"window_end":{"type":"string","title":"Window End"}},"type":"object","required":["segments","next_cursor","window_start","window_end"],"title":"CachePage"},"CacheSegment":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"flow_id":{"type":"string","format":"uuid","title":"Flow Id"},"start":{"type":"string","title":"Start"},"end":{"type":"string","title":"End"},"bytes":{"type":"integer","title":"Bytes"}},"type":"object","required":["id","flow_id","start","end","bytes"],"title":"CacheSegment"},"ChangePassword":{"properties":{"password":{"type":"string","maxLength":128,"minLength":15,"title":"Password"},"current_password":{"type":"string","maxLength":128,"minLength":1,"title":"Current Password"}},"type":"object","required":["password","current_password"],"title":"ChangePassword"},"ClipCreate":{"properties":{"recorder_id":{"type":"string","format":"uuid","title":"Recorder Id"},"name":{"type":"string","maxLength":120,"minLength":1,"title":"Name"},"start":{"type":"string","format":"date-time","title":"Start"},"end":{"type":"string","format":"date-time","title":"End"}},"additionalProperties":false,"type":"object","required":["recorder_id","name","start","end"],"title":"ClipCreate"},"ClipOut":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"recorder_id":{"type":"string","format":"uuid","title":"Recorder Id"},"name":{"type":"string","title":"Name"},"start":{"type":"string","title":"Start"},"end":{"type":"string","title":"End"},"state":{"type":"string","title":"State"},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error"},"tams_flow_id":{"type":"string","format":"uuid","title":"Tams Flow Id"},"download_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Download Url"}},"type":"object","required":["id","recorder_id","name","start","end","state","error","tams_flow_id","download_url"],"title":"ClipOut"},"HTTPValidationError":{"properties":{"detail":{"items":{"$ref":"#/components/schemas/ValidationError"},"type":"array","title":"Detail"}},"type":"object","title":"HTTPValidationError"},"LoginBody":{"properties":{"username":{"type":"string","maxLength":80,"minLength":1,"pattern":"^[A-Za-z0-9_.@-]+$","title":"Username"},"password":{"type":"string","maxLength":128,"minLength":1,"title":"Password"}},"type":"object","required":["username","password"],"title":"LoginBody"},"LoginOut":{"properties":{"access_token":{"type":"string","title":"Access Token"},"token_type":{"type":"string","const":"bearer","title":"Token Type"},"expires_in":{"type":"integer","title":"Expires In"},"user":{"$ref":"#/components/schemas/UserOut"}},"type":"object","required":["access_token","token_type","expires_in","user"],"title":"LoginOut"},"NewPassword":{"properties":{"password":{"type":"string","maxLength":128,"minLength":15,"title":"Password"}},"type":"object","required":["password"],"title":"NewPassword"},"NewUser":{"properties":{"username":{"type":"string","maxLength":80,"minLength":1,"pattern":"^[A-Za-z0-9_.@-]+$","title":"Username"},"password":{"type":"string","maxLength":128,"minLength":15,"title":"Password"},"role":{"type":"string","enum":["admin","operator","viewer"],"title":"Role","default":"viewer"}},"type":"object","required":["username","password"],"title":"NewUser"},"RecorderCreate":{"properties":{"name":{"type":"string","maxLength":120,"minLength":1,"title":"Name"},"input_url":{"type":"string","maxLength":2048,"title":"Input Url","description":"SRT caller URL or listener URL on 0.0.0.0:10000–10999. Treated as a secret."},"retention_hours":{"type":"integer","maximum":720.0,"minimum":1.0,"title":"Retention Hours","default":48}},"additionalProperties":false,"type":"object","required":["name","input_url"],"title":"RecorderCreate"},"RecorderOut":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"type":"string","title":"Name"},"retention_hours":{"type":"integer","title":"Retention Hours"},"desired":{"type":"string","title":"Desired"},"state":{"type":"string","title":"State"},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error"},"heartbeat":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Heartbeat"},"thumbnail_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Thumbnail At"},"listener_port":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Listener Port"},"thumbnail_url":{"type":"string","title":"Thumbnail Url"},"whep_url":{"type":"string","title":"Whep Url"}},"type":"object","required":["id","name","retention_hours","desired","state","error","heartbeat","thumbnail_at","listener_port","thumbnail_url","whep_url"],"title":"RecorderOut"},"RecorderPatch":{"properties":{"name":{"anyOf":[{"type":"string","maxLength":120,"minLength":1},{"type":"null"}],"title":"Name"},"retention_hours":{"anyOf":[{"type":"integer","maximum":720.0,"minimum":1.0},{"type":"null"}],"title":"Retention Hours"}},"additionalProperties":false,"type":"object","title":"RecorderPatch"},"UserOut":{"properties":{"id":{"type":"string","title":"Id"},"username":{"type":"string","title":"Username"},"role":{"type":"string","title":"Role"},"enabled":{"type":"boolean","title":"Enabled"},"must_change_password":{"type":"boolean","title":"Must Change Password"}},"type":"object","required":["id","username","role","enabled","must_change_password"],"title":"UserOut"},"UserPatch":{"properties":{"role":{"anyOf":[{"type":"string","enum":["admin","operator","viewer"]},{"type":"null"}],"title":"Role"},"enabled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Enabled"}},"type":"object","title":"UserPatch"},"ValidationError":{"properties":{"loc":{"items":{"anyOf":[{"type":"string"},{"type":"integer"}]},"type":"array","title":"Location"},"msg":{"type":"string","title":"Message"},"type":{"type":"string","title":"Error Type"},"input":{"title":"Input"},"ctx":{"type":"object","title":"Context"}},"type":"object","required":["loc","msg","type"],"title":"ValidationError"}},"securitySchemes":{"HTTPBearer":{"type":"http","scheme":"bearer"}}}}