Threads
Threads channels post to a Threads profile through the UmbHost.Automate.Threads package and its Create Threads Post action (threads.createPost).
dotnet add package UmbHost.Automate.ThreadsEach site uses its own Meta app and its own access. UmbHost doesn’t need access to your app, and your posts never pass through UmbHost.
What Threads needs
Section titled “What Threads needs”-
Sign in to Meta for Developers and choose Create app. If you already have a Meta app for your Facebook page, you can add Threads to it instead.
-
When asked what the app should do, choose the Access the Threads API use case.
-
In the use case, under Permissions, add
threads_basic,threads_content_publishandthreads_manage_replies. UmbSocial needs the last one to post a thread’s later parts as replies. -
In the use case’s Settings, add the redirect callback URL
https://<your-site>/umbraco/automate/oauth/callback/threads. Copy the Threads app ID and Threads app secret shown there. They are not the same as the Meta app’s own ID and secret. -
Until Meta approves your app, it can only post as the Threads accounts you add as testers. To add one, open App roles → Roles, add the account as a Threads Tester, then accept the invitation in the Threads app under Settings → Account → Website permissions.
-
To post as other accounts, submit the app for App Review, requesting advanced access to
threads_basic,threads_content_publishandthreads_manage_replies. Meta reviews each request, which can take several days, and may ask for a screencast showing how the app posts. -
Add the Threads app ID and secret to configuration:
{"Umbraco": {"Automate": {"Providers": {"Threads": { "ClientId": "<Threads app ID>", "ClientSecret": "<Threads app secret>" }}}}}Keep the secret out of
appsettings.jsonin source control, in user secrets or an environment variable (Umbraco__Automate__Providers__Threads__ClientSecret). Without aClientId, the Threads provider is skipped, and UmbSocial doesn’t offer Threads.
The Automate connection
Section titled “The Automate connection”Automate → Connections → Create → Threads → Authorize, signed in to Threads as the profile you want to post as. Validate names the profile.
Threads gives a token that lasts only an hour when you authorise. The package swaps it straight away, during the authorisation itself, for one that lasts 60 days, so there’s nothing to do within the hour. After that, the package renews the token whenever the connection is used and the token is more than a week old.
Then add the channel as described in Connecting networks.
Channel options
Section titled “Channel options”None.
What is sent
Section titled “What is sent”| Post field | Sent as |
|---|---|
| Text | The post text. The link, if any, is added at the end of the text, where Threads makes it clickable. |
| Image | Optional. Threads fetches it from your site, so the site must be reachable from the internet. UmbSocial sends a JPEG, and Threads takes images up to 8 MB. |
| Image alt text | Sent (up to 1,000 characters). |
| Link title and description | Not sent. |
| Thread | Each part is posted as a reply to the one before. |
Threads allows 500 characters, and counts each emoji by its size in bytes, so most emoji count as 4 and an emoji with a skin tone as 8. See Network limits.
When a post fails
Section titled “When a post fails”Threads has no idempotency key. Nothing is visible on Threads until a post is published, so a failure before that is retried as normal. If the request that publishes the post fails without a clear answer, the action doesn’t retry, and UmbSocial records the post as Unknown: check the profile before retrying. A thread that stops part-way is handled as described in Writing and scheduling posts.