I realise the status/update_with_media endpoint is now deprecated, but I have an interesting issue with it I would like to understand. I have some code (written by someone else) that correctly calls the endpoint, with a correct oauth header etc and works fine (with one exception). I can supply text and an image, and a tweet is created with both. Most of that same code is also used to call statuses/update method, and this also works.
Here is the weird thing; when the text for the tweet status contains an accented char, the call for update_with_media fails with a 401 unauthorised response, and an error from Twitter saying I couldn’t be authenticated. The same code that calculates the auth signature etc. is also used by the statuses/update endpoint and that works fine with accented characters. I thought it was probably an issue encoding the accented character in the oauth base string, but the same code is used to generate the auth header and from what I can tell the character is encoded the same way for both calls.
Using the upload media endpoint followed by the statuses/update endpoint with a list of uploaded media id’s also works fine, even with an accented character. It is only calling the older endpoint with both an image and accented character that causes the issue.
So basically I can tweet with accented characters, or images, but not both in the same status. Does anyone have any idea what might cause this?