204 No Content when media file is appended

media-upload

#1

Hi,

I am uploading media file and it returns “204 No Content” while APPEND.
INIT request:
<{command=[INIT],
media_type=[image/gif],
total_bytes=[5781],
media_category=[tweet_gif]},
{Content-Type=[application/x-www-form-urlencoded], Accept-Charset=[UTF-8]}>

INIT Response
mediaId=834006372517752832, expirationTime=86399

Append Request,
<{command=[APPEND],
media_id=[834006372517752832],
segment_index=[0],
media=[[B@5e327f6a]},
{Content-Type=[multipart/form-data]}>

media=[[B@5e327f6a]} - Is array of bytes of my file

Append response:
<204 No Content,{cache-control=[no-cache, no-store, must-revalidate, pre-check=0, post-check=0], content-length=[0], content-security-policy=[default-src ‘self’; connect-src ‘self’; font-src ‘self’ https://.twimg.com https://twitter.com https://ton.twitter.com data:; frame-src ‘self’ https://.twimg.com https://twitter.com https://ton.twitter.com; img-src ‘self’ https://.twimg.com https://twitter.com https://ton.twitter.com data:; media-src ‘self’ https://.twimg.com https://twitter.com https://ton.twitter.com; object-src ‘none’; script-src ‘self’ https://.twimg.com https://twitter.com https://ton.twitter.com; style-src ‘self’ https://.twimg.com https://twitter.com https://ton.twitter.com; report-uri https://twitter.com/i/csp_report?a=OBZG6ZTJNRSWE2LSMQ%3D%3D%3D%3D%3D%3D&ro=false;], content-type=[text/html;charset=utf-8], date=[Tue, 21 Feb 2017 11:46:29 GMT], expires=[Tue, 31 Mar 1981 05:00:00 GMT], last-modified=[Tue, 21 Feb 2017 11:46:29 GMT], pragma=[no-cache], server=[tsa_a], set-cookie=[lang=en; Path=/, guest_id=v1%3A148767758907572591; Domain=.twitter.com; Path=/; Expires=Thu, 21-Feb-2019 11:46:29 UTC], status=[204 No Content], strict-transport-security=[max-age=631138519], vary=[Origin], x-access-level=[read-write-directmessages], x-connection-hash=[51e7704e40ba5c10abc97b62e538fb45], x-frame-options=[SAMEORIGIN], x-mediaid=[834006372517752832], x-rate-limit-limit=[20000], x-rate-limit-remaining=[19998], x-rate-limit-reset=[1487680562], x-response-time=[361], x-segmentcount=[0], x-totalbytes=[0], x-transaction=[003a19b300983924], x-tsa-request-body-time=[1], x-twitter-response-tags=[BouncerCompliant], x-xss-protection=[1; mode=block]}>

What could be wrong from my side.
Appreciate your help.