twitterFavoriteList

Objective

Reflect linked articles liked on twitter in notion's dashboard.

environment

go version go1.18.1

settings

You need to register twitter developer portal and make notion integration. In this app, use twitter Bearer token, twitter user ID, notion integration token and notion database ID.

twitter Bearer token

twitter Bearer token can get from twitter developer portal -> projects -> project_name -> Authentication Token -> Bearer Token

twitter user ID

twitter user ID isn't string ID like @hon_d7174. You need to convert it to number ID.

notion integration token

notion integration token can get from Notion My integration -> integration -> Secret -> Internal Integration Token. This integration need Capabilities(Update content, Insert content).

notion database ID

notion database ID can get from notion page. "https://www.notion.so/${notion database ID}?v=xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx" In this app, we use notion Board. So you should make notion Board like below image.

.env

env file locate on same path of main.go

BEARERTOKEN=${twitter api Bearer token}
USERID=${twitter user ID(number)}
NOTIONINTEGRATIONTOKEN=${notion integration token}
NOTIONDBID=${notion database ID}