Description Usage Details Value Examples
To use the Academic Twitter API, you first need to register for an account and get a Bearer token (see details below). You can then use this function to store the token. This is only required once (unless you change your token).
1 |
First register for a Twitter Academic API licence (https://developer.twitter.com/en/solutions/academic-research). You can then get your "Bearer" key from your Twitter Project & Apps dashboard (https://developer.twitter.com/en/portal/projects-and-apps).
Here you should see something along the lines of "Academic Research", with a "Project App". In the Project app you should see a button looking like a key. On the next page you can generate a new Bearer token (you don't need the other tokens) When you generate a new token you should copy it immediately, because you cannot look it up again (only generate a new one). Then just run the set_bearer_token() function, and enter the Token in the password prompt.
Nothing, just stores the thing
1 | set_bearer_token() ## opens a password prompt
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.