How to send allowedorigins and requiresignedurls in Upload-Metadata header?

190 views Asked by At

I’m trying to implement TUS and according to this doc I can send requireSignedUrls and allowedOrigin options in Upload-Metadata header. https://developers.cloudflare.com/stream/uploading-videos/upload-video-file#supported-options-in-upload-metadata

I’ve tried sending like Upload-Metadata: requiresignedurls, allowedOrigins=“abcd.com,efgh.com”

requiresignedurls works fine but not allowedorigins

1

There are 1 answers

0
Catalin On

Values need to be encoded in base64, so correct header would be:

Upload-Metadata: requiresignedurls,allowedOrigins=YWJjZC5jb20sZWZnaC5jb20=