Android upload video

video

#1

Hi, trying to upload a video on android, extending fabrics TwitterApiClient.
INIT : success returns media id
APPEND : success 2XX
FINALIZE : com.twitter.sdk.android.core.TwitterApiException: 400 Bad Request.

also tried to upload the same video or any video using twurl.
and I get “Invalid or unsupported media, Reason: UnsupportedMedia.” on FINALIZE.

I have been trying to crack this for a while. Is there a restriction on the video codecs I should use? Can someone please shade some light on this?


#2

The video would need to be MP4 and inside the supported size range (length and file size). This is described in the Uploading Media docs.


#3

@andypiper I went through the docs when trying to upload the video. Yes the video is mp4 and in the size range like 7seconds and 1.5MB. Here is the video for your reference
https://www.dropbox.com/s/t620a85n0vc290s/VMS_1449543038282.mp4?dl=0

Thanks.


#4

Thanks. I’ve just tried the same, and it doesn’t seem to work.

My working theory is that ISO Media MP4 format is not supported, but I’m unable to confirm that at the moment. Is there any way to generate the video in a different codec/format and retry?


#5

Thanks @andypiper I will try a different codec.


#6

What was the verdict on this issue?


#7

It seems the video codec I am using(mpeg4), is somehow rejected by the server. I tried with an h264 codec, and it worked.


#8