TTWrite API Documentation: create_post Endpoint
This document provides detailed information on creating posts and managing related settings in the TTWrite API.
Functionalities of the create_post
Endpoint
1. How It Works
- Media posts (images/videos): Upload media first, then publish the post.
- GIF/Text posts: Create the post in a single step.
2. Upload Post Media
API Endpoint
- URL:
mobile_api/upload_post_media
Parameters
Field | Value | Remarks |
---|
session_id | Access token ID | Example: de25cc16eb00960f076... |
type | Media file type (image/video) | Example: image |
file | Media file (image or video) | Example: media.jpg |
3. Delete Post Media
API Endpoint
- URL:
mobile_api/delete_post_media
Parameters
Field | Value | Remarks |
---|
session_id | Access token ID | Example: de25cc16eb00960f076... |
type | Media file type (image/video) | Example: image |
media_id | Media file ID | Example: 12345 |
4. Publish Post / Reply
API Endpoint
- URL:
mobile_api/publish_post
Parameters
Field | Value | Remarks |
---|
session_id | Access token ID | Example: de25cc16eb00960f076... |
post_text | Text message (Max. 600 characters) | Example: Hello world! |
thread_id | ID of the thread to reply to | Optional for replies |
5. Change Post Privacy
API Endpoint
- URL:
mobile_api/change_post_privacy
Parameters
Field | Value | Remarks |
---|
session_id | Access token ID | Example: de25cc16eb00960f076... |
post_id | ID of the post | Example: 12345 |
privacy_option | Reply permissions option | Example: public , followers , or none |