benjypng / logseq-tweet-plugin

MIT License
13 stars 1 forks source link

:gift_heart: Sponsor this project on Github or :coffee: Get me a coffee if you like this plugin!

In v2.0.0 onwards, your Bearer token is required to embed tweet threads.

Overview

Easily tweet from within Logseq!

Installation

If you find it in the marketplace, do install it from there for a more seamless experience.

If you can't find the plugin in the marketplace, please download the latest release here and manually install the plugin in Logseq.

Usage

Tweeting single tweets and tweet threads

  1. Install the plugin as above.

  2. Navigate to the plugin settings.

  3. Key in your API key, API secret, Access token, Access secret, Bearer token. Then close the settings window.

  4. Start by typing /tweet anywhere. You can then start tweeting in the next block.

  5. If you only have 1 block, you will be sending just 1 tweet.

  6. If you have multiple blocks, you will be sending a tweet thread.

  7. When you are done composing your tweet/s, simply hit the big blue tweet button to send off your tweets!

Deleting tweets & tweet threads

Once you have tweeted, the tweet button would disappear and be replaced by the date/time stamp of the tweet/thread, and a link to the tweet (or first tweet of the thread). To delete this tweet/thread, right click on the block and select Delete tweet/thread.

Note: If you try to delete your tweet immediately after you post it, all the tweets may not get deleted as the Twitter API needs some time to be updated. Do give it a few seconds before initiating the delete.

Embedding tweet or thread

This plugin also allows you to embed tweets and threads. Simply type /Embed tweet/thread and enter the url of the first tweet of the thread. It will automaticaly scan to see if it's a single tweet or thread and embed it accordingly/and embed it accordingly.

Customisation

Setting custom hashtags for successful tweets

Successful tweets will look something like this: #tweeted on Feb 22nd, 2022 at 15:34. You can replace #tweeted on with your own custom hashtag by changing the plugin settings.

{
  "customHashtag": "#tweeted on"
}

How to get your Twitter keys, secrets and tokens

  1. Sign up for a developer account and log in.

  2. Go to your developer portal.

  3. Create a project.

  4. Go to your app settings and ensure that your user authentication settings are set to OAuth 1.0a. It should reflect as below after you're done:

  1. Go to your keys and tokens page using the tab below:

  1. On this page, generate your:
  1. The information in (6) will need to go in the plugin settings as above.

Important Notes