Receiving a 413 error for post to POST statuses/update_with_media


#1

I was trying to upload an image to statuses/update_with_media (which i just realised is deprecated)

I know the limit is 3 meg and smaller images did work but when i tried to post an image of 2.6meg i got a 413 error.

Not sure if its an issue on my end but googling didn’t show up much. The apps being built to demo high res images. i can resize them on my end but i would like to push as high res of images as possible


#2

just to add more information- the file when it comes down from amazon s3 is 2747286 in size then when its sent to twitter and fails the response says its 5390336…

heres the api response

      [url] => https://upload.twitter.com/1.1/media/upload.json
        [content_type] => 
        [http_code] => 413
        [header_size] => 209
        [request_size] => 638
        [filetime] => -1
        [ssl_verify_result] => 0
        [redirect_count] => 0
        [total_time] => 90.448432
        [namelookup_time] => 0.030676
        [connect_time] => 0.236404
        [pretransfer_time] => 0.722808
        [size_upload] => 5390336
        [size_download] => 0
        [speed_download] => 0
        [speed_upload] => 59595
        [download_content_length] => 0
        [upload_content_length] => 5494740
        [starttransfer_time] => 1.249717
        [redirect_time] => 0
        [redirect_url] => 
        [primary_ip] => xxxxxxx
        [certinfo] => Array
            (
            )

        [primary_port] => 443
        [local_ip] => 192.168.11.2
        [local_port] => 59879