I cannot see my uploaded image by using API with libcurl on Twitter


#1

I want to upload a png file which size is only 31.1KB by using POST media/upload (INIT) (APPEND) (FINALIZE) api with libcurl,

  1. POST media/upload (INIT)
    return HTTP code 202 and I can get media_id_string from response data

response like this :
{“media_id”:1007163900490465280,“media_id_string”:“1007163900490465280”,“expires_after_secs”:86400,“media_key”:“3_1007163900490465280”}

  1. POST media/upload(APPEND)
    return HTTP code 204

  2. POST media/upload(FINALIZE)
    return HTTP code 201
    and response data like this:

{“media_id”:1007163900490465280,“media_id_string”:“1007163900490465280”,“media_key”:“3_1007163900490465280”,“size”:31890,“expires_after_secs”:86400,“image”:{“image_type”:“image/png”,“w”:1920,“h”:1080}}

I compare the requst data and response data by using api with I upload image on twitter,
and I think all are the same.
But, I cannot see my image on Twitter by by using API with libcurl

What’s wrong with my steps or do I miss the other steps?
Can anyone answer me

thanks