SignatureDoesNotMatch in direct upload

private static RestClient client = new RestClient("");
public static string GetSignedUrl(string version, string apiKey)
                var signedUrlRequest = new RestRequest($"ingest/{version}/upload", Method.POST);
                signedUrlRequest.AddHeader("Accept", "application/json");
                signedUrlRequest.AddHeader("x-api-key", apiKey);
                var signedUrlResponse = client.Execute(signedUrlRequest);
                var signedUrl = signedUrlResponse.Content;
                JObject json = JObject.Parse(signedUrl);
                // Lấy giá trị của trường "audio_link"
                signedUrl = (string)json["data"]["attributes"]["url"]; ;
                return signedUrl;
public static void UploadFile(string signedUrl, string filePath)
                var client2 = new RestClient(signedUrl);
                var request = new RestRequest(Method.PUT);
                request.AddFile("file", filePath);
                IRestResponse response = client2.Execute(request);
result response in uploadfile is:
everyone can help me

Does client2.Execute(request); add in the Content-Type header. Some clients do that automatically but in the PUT request you do not want to send a Content-Type header because when the signature is created it is created without it. When you include it, the signature will be different. The reason we omit is because when you GET the signed URL we don’t know in advance if you are uploading an image, video or audio file so we do not add a content type.

Please see if you can omit the Content-Type header from the PUT request and if that works. I am not familiar with the language or library but I hope that is possible.

If you can’t get it to work let us know and we can come up with another solution.

Thank you, Lucas. It seems that the client automatically adds the Content-Type header. I’m forced to use curl code to handle it. Thank your support.