Switchboard Canvas

Making an image from a Tweet

You can use the Switchboard Canvas API to reference a tweet, and have the data from that tweet populate a template.

{
"template": "tweet2",
"sizes": [
{
"width": 1080,
"height": 1920
}
],
"tweet": "https://twitter.com/anafabrega11/status/1397581643083395074"
}

You can reference the tweet using the full URL to the tweet or just the ID:

{
"template": "tweet2",
"sizes": [
{
"width": 1080,
"height": 1920
}
],
"tweet": "1397581643083395074"
}

Your template must be set up with certain named elements. These values for these elements will be overwritten with data from the tweet when the API is called.

ElementTypeDescription
textTextThe main text of the tweet
created_atTextThe date the tweet was created
author_usernameTextThe tweet's author's handle
author_nameTextThe tweet's author's name
author_urlTextThe URL to the tweet's author's profile picture
verifiedAnyCan refer to any element. Opacity will be set to 1 if the user is verified.

We care about the protection of your data. Read our Privacy Policy.

© 2022 switchboard.ai. All rights reserved.
Privacy Terms Cookies