Figma Avatar
Update your Twitter avatar and banner from the comfort of Figma.
How to use this project
- Rename
env_sample
to.env
and add the following information:
- Your Figma access token and the ID of your Figma file.
- The Twitter app credentials.
- A passcode that you'll use to protect your app.
- Install the dependecies with
yarn install
- Run the server with
yarn start
- Create a POST webhook with the following information:
-
Your
FIGMA_TOKEN
andPASSCODE
from the first step -
Your
TEAM_ID
-
Your
APP_ENDPOINT
-
The
EVENT_TYPE
you want to use to trigger the avatar & banner change (for example: FILE_VERSION_UPDATE)curl -X POST -H 'X-FIGMA-TOKEN: [FIGMA_TOKEN]' -H "Content-Type: application/json" 'https://api.figma.com/v2/webhooks' -d '{"event_type":" [EVENT_TYPE]","team_id":"[TEAM_ID]","endpoint":"[APP_ENDPOINT]/ping","passcode":"[PASSCODE]"}'
After these steps and whenever you add changes to the version history of your Figma file, your avatar and banner will get [magically] updated.
Important: this project uses the Figma Webhooks v2 API which is in beta and only available for paid teams.