Banner
Update Profile Banner
POST
/tw-v2/profile/bannerDescription
Update the profile banner for the authenticated Twitter/X account. TweetAPI uploads the image from a URL or base64 payload, then applies it to the account profile.
Request Body
| Parameter | Type | Required | Description |
|---|---|---|---|
| authToken | string | required | Account authentication token (auth_token cookie value) |
| media | object | required | Image object. Use {url: string} or {data: string, type: string}. Direct media_id values are not supported for profile images. |
| proxy | string | optional | Optional proxy in format 'hostname:port@username:password' |
Media Input
- Use
media.urlfor an image URL. - Use
media.datawithmedia.typefor base64 image data. - Supported image MIME types:
image/jpeg,image/jpg,image/png,image/webp.
Code Examples
const body = {
authToken: 'YOUR_AUTH_TOKEN',
media: {
url: 'https://example.com/images/profile-banner.jpg'
}
};
const response = await fetch('https://api.tweetapi.com/tw-v2/profile/banner', {
method: 'POST',
headers: {
'X-API-Key': 'YOUR_API_KEY',
'Content-Type': 'application/json'
},
body: JSON.stringify(body)
});
const data = await response.json();
console.log(data);
Response
Success Response (200 OK)
200
{
"data": {
"id": "10017528",
"username": "sample_user_96991",
"name": "Sample User 96991",
"bio": "Sample profile bio for Sample User 96991.",
"location": null,
"website": null,
"avatar": "https://example.com/images/sample-avatar-96991.jpg",
"banner": "https://example.com/images/profile-banner.jpg",
"verified": false,
"isBlueVerified": true,
"isProtected": false,
"followerCount": 226995885,
"followingCount": 1218,
"tweetCount": 86745,
"createdAt": "2009-06-02T20:12:29.000Z"
}
}API Playground
POST
/tw-v2/profile/bannerSensitive Credentials Required
Requires your Twitter authToken. Use a test account.
Press ⌘ + Enter to execute
curl -X POST "https://api.tweetapi.com/tw-v2/profile/banner" \
-H "X-API-Key: YOUR_API_KEY" \
-H "Content-Type: application/json"Response
Click "Try It!" to see the response