Last update:2026-07-15 17:46:03
When sending transcoding requests, you must include an authentication token in the Authorization header. This token is a security measure that ensures only authorized requests are processed.
Important: The token includes your
AccessKeyand is cryptographically signed using yourAccessKey Secret. Make sure you have obtained your uniqueAccessKeyandAccessKey Secretbefore proceeding.
The authentication token uses the following format:
Token = [AccessKey]:[EncodeSign]
Where:
AccessKey: Your unique public identifier.EncodeSign: A URL-safe Base64-encoded HMAC-SHA1 signature.The process of generating the authentication token involves the following steps:
EncodeSignTokenThe following sections describe each step in detail.
EncodeSign is generated by applying a series of transformations to StringToSign and your AccessKey Secret.
EncodeSign = Urlsafe_base64_encode(HMAC_SHA1(StringToSign, AccessKey Secret))
The process is outlined below.
StringToSign is constructed based on the request type. For media processing requests, it uses the following format:
StringToSign = '/fops' + '\n' + [Request Body]
/fops: A fixed string that indicates the operation.\n: A newline character.[Request Body]: The body of your transcoding request.If your Request Body is bucket=[bucket_name]key=[file_to_process]fops=[processing_operations], your StringToSign will be:
/fops\nbucket=[bucket_name]key=[file_to_process]fops=[processing_operations]
Note: The example
Request Bodyshown here is the original string for clarity. In your actual request, you may use a Base64-encoded string.
After formulating StringToSign, use your AccessKey Secret as the key to compute the HMAC-SHA1 signature:
Signature = HMAC_SHA1(StringToSign, AccessKey Secret)
You can obtain your AccessKey and AccessKey Secret by navigating to Basic Information > Account Management > API Information Management > AccessKey Management.
Finally, apply URL-safe Base64 encoding to the computed Signature to obtain EncodeSign:
EncodeSign = Urlsafe_base64_encode(Signature)
After generating EncodeSign and obtaining your AccessKey, combine them in the following format to create your authentication token:
Token = [AccessKey]:[EncodeSign]
This token must be included in the Authorization header of your transcoding requests.