Workflow script for the Ulanzi Pixel Clock, based on the n8n.io automation software and Awtrix Light.
Display your Twitter Followers on your Ulanzi Pixel Clock
Template: Follower Count
Rounded down to three significant figures
Example: 725
- Navigate to your Ulanzi Pixel Clock admin screen (usually
192.168.1.128
) - Select the Icons Tab
- Type
25284
into the first field named Lametric Icon ID - Click Download
- Visit the Latest Releases section and download the
Twitter_Followers.json
file to your computer
- In your n8n automation server, create a new workflow
Import from File
and select the downloaded Workflow
-
Follow the below steps to get your Twitter API Key
- Sign in to the Twitter Developer Portal
- At the bottom of the page, click Sign up for Free Account
- Write up a description of your intended use of the API (you can find an example at the end of this page)
- Click all three check boxes and click Submit
- Click Create Project
- Git it a Name (eg "Ulanzi Clock"), hit Next
- Select a Use Case (eg "Exploring the API"), hit Next
- Add a description (can be the same as above), hit Next
- Type in your App Name (eg "Clock Display")
- Copy your API Key, API Key Secret & Bearer Token
- Continue by clicking App Settings
- Under User Authentication Settings, click Set Up
- Under App Permissions, select Read and set Request email from users to on.
- Under Type of App, select Web App, Automated App or Bot
- Under App info, enter the following:
- Callback URI / Redirect URL:
http://localhost:5678/rest/oauth1-credential/callback
- Website URL:
https://n8n.io
- Terms of service:
https://n8n.io
- Privacy policy:
https://n8n.io
- Callback URI / Redirect URL:
- Hit Save
-
Double-click and open the second step of the workflow, named Fetch Data
-
Under Authentication, select Generic Credential Type
-
Under Generic Auth Type, select OAuth1 API
-
Under Credential for OAuth1 API, select Create New Credential
-
In the pop up screen, enter the following:
- Authorization URL:
https://api.twitter.com/oauth/authorize
- Access Token URL:
https://api.twitter.com/oauth/access_token
- Consumer Key:
YOUR API KEY
- Consumer Secret:
YOUR API KEY SECRET
- Request Token URL:
https://api.twitter.com/oauth/request_token
- Signature Method:
HMAC-SHA1
- Hit Connect my account
- In the Twitter Pop-up window, make sure you are logged into the correct Twitter Account (if you have mutliple accounts), then click Authorize App
- Authorization URL:
- On the last step named Send to Clock, make sure the IP address in the URL field is correct (usually
192.168.1.128
) - On the Workflow canvas, click on the button
Execute Workflow
Set the workflow to "Active", to keep it running in the background
Visit the Lovely Discord and perhaps I can help you there.
"I want to use this API to display my Twitter Follower count on a physical device digital clock. This will be for personal use and will also be used on my Live Streams as a progress indicator. I will not show any public information related to my followers."