Skip to main content
POST
cURL

Authorizations

X-API-Key
string
header
required

Body

multipart/form-data
file
file
required

The media file to upload (image, video, etc.)

proxy
string
required

The proxy to use.Please use high-quality residential proxies and avoid free proxies. Required. Example: http://username:password@ip:port [blocked] . You can get proxy from: https://www.webshare.io/?referral_code=4e0q1n00a504

login_cookies
string
required

The login cookies of the user. You can get the login_cookie from /twitter/user_login_v2. Optional for media upload, required for posting tweets

is_long_video
boolean

If this is True, videos longer than 2:20 can be uploaded.(Twitter Premium only)

Response

Upload media response

media_id
string

The id of the uploaded media.

status
string

Status of the request.success or error

msg
string

Message of the request.error message