For AI agents: a documentation index is available at the root level at /llms.txt and /llms-full.txt. Append /llms.txt to any URL for a page-level index, or .md for the markdown version of any page.
  • Cloudflare
    • GETpayload example
    • POSThttps://social-media-posting-dev.deao.workers.dev/post
        • POSTCreate Post: https://api.x.com/2/tweets
        • POSTRefresh Token: https://api.x.com/2/oauth2/token
          • GET4. Get Media upload status: https://api.x.com/2/media/upload?media_id={video_id}
          • POST1. Initialize media upload: https://api.x.com/2/media/upload/initialize
          • POST2. Append Media upload: https://api.x.com/2/media/upload/{video_id}/append
          • POST3. Finalize Media upload: https://api.x.com/2/media/upload/{video_id}/finalize
LogoLogo
CloudflareSocial Media PostingXUpload Video

  1. Finalize Media upload: https://api.x.com/2/media/upload/{video_id}/finalize

||View as Markdown|
POST
/2/media/upload/:video_id/finalize
POST
/2/media/upload/:video_id/finalize
$curl -X POST https://graph.facebook.com/2/media/upload/2035553946807222272/finalize \
> -H "Content-Type: multipart/form-data"
200Social Media Posting_X_Upload Video_3. Finalize Media upload: https://api.x.com/2/media/upload/{video_id}/finalize_example
1{
2 "data": {
3 "id": "2035547185891143681",
4 "size": 67108864,
5 "media_key": "7_2035547185891143681",
6 "processing_info": {
7 "state": "pending",
8 "check_after_secs": 1
9 },
10 "expires_after_secs": 86400
11 }
12}
Was this page helpful?
Previous

2. Append Media upload: https://api.x.com/2/media/upload/{video_id}/append

Next

Upload Media: https://api.x.com/2/media/upload

Built with

Path parameters

video_idstringRequired

Request

This endpoint expects a multipart form.

Response headers

perfstring
CF-RAYstring
api-versionstring
x-served-bystring
Cache-Controlstring
origin-cf-raystring
x-access-levelstring
cf-cache-statusstring
x-frame-optionsstring
x-response-timestring
x-transaction-idstring
x-xss-protectionstring
x-rate-limit-limitstring
x-rate-limit-resetstring
content-dispositionstring
x-content-type-optionsstring
x-rate-limit-remainingstring
strict-transport-securitystring

Response

OK
dataobject
  1. Append Media upload: https://api.x.com/2/media/upload/{video_id}/append

Upload Media: https://api.x.com/2/media/upload