✨(backend) offer an endpoint to save recording
I've protected this endpoint with a feature flag, and an authentication class, as it will be exposed on the public internet. I've tried to keep the viewset logic as minimal as possible, I've to ship smth and will continue iterating on this piece of code. At some point, abstracting webhook endpoint and authentication class might be beneficial for the project. YAGNI as of today.
This commit is contained in:
committed by
aleb_the_flash
parent
e11bdc6d28
commit
7afa165013
@@ -50,6 +50,9 @@ class StorageEventAuthentication(BaseAuthentication):
|
||||
if not settings.RECORDING_ENABLE_STORAGE_EVENT_AUTH:
|
||||
return MachineUser(), None
|
||||
|
||||
if not settings.RECORDING_ENABLE_STORAGE_EVENT_AUTH:
|
||||
return MachineUser(), None
|
||||
|
||||
required_token = settings.RECORDING_STORAGE_EVENT_TOKEN
|
||||
if not required_token:
|
||||
if settings.RECORDING_ENABLE_STORAGE_EVENT_AUTH:
|
||||
|
||||
Reference in New Issue
Block a user