Error while trying to access TikTok API OAuth2 credential

Hi everybody ! :slight_smile:

I’m french and I don’t speak a perfect english so please, if it’s hard to understand what i’m saying, please forgive me :).

I try to creat a new generic “OAuth2 API” creditential for working with the TikTok API.

I’ve followed the documentations available here : TikTok for Developers

And here : TikTok for Developers

My creditential looks like that :

Important information : I’ve creat and app on the TikTok Developer portal and I’ve been approved by TikTok admin. The App’s status is “Live in production”.

I click on “Connect my account”, it opens a second windows and I have the authorisation page : I connect to my TikTok account, “Do you allow the app…blablabla…to access to your informations…blablabla”.

I click on “Accept” and here is the final window I see :

And I’m stuck. The creditential is not connected.

If anybody have an idea, that can really helping me.

Anyway, please don’t forget the most important : have a nice day :slight_smile: !

1 Like

It looks like your topic is missing some important information. Could you provide the following if applicable.

  • n8n version:
  • Database (default: SQLite):
  • n8n EXECUTIONS_PROCESS setting (default: own, main):
  • Running n8n via (Docker, npm, n8n cloud, desktop app):
  • Operating system:

n8n version: 1.39.1
Database: SQLite
n8n EXECUTIONS_PROCESS setting: own (not sure to understand)
Running n8n via : npm/pm2
Operating system : Ubuntu 23.10 (GNU/Linux 6.5.0-1021-oracle aarch64)

Couple things:

  1. Your client id is set to just 0, is that normally correct and only for the screenshot?
  2. What do your TikTok app settings look like?
  3. TikTok mentions a backup auth URL, try this: https://www.tiktok.com/auth/authorize/
  4. I’m not entirely sure how oauth or rather how it works in tiktok’s backend. But I looked into janus. It is probably this: https://janus.conf.meetecho.com/

No changing the client ID is not for the screenchot but that doesn’t make any différence because TikTok API doesn’t respect strictly OAuth 2 specifications.

TikTok doesn’t use the value “client-id” but rename it “client-key”. That’s why you can see “client_key=xxxxxxxxxxxxxxxxxxx” in the Auth URI Query Parameters.

I think that creditentials doesn’t replic the “Auth URI Query Parameters” in the access token URL. Maybe that’s why I have this problème.

Any updates? I’m facing the same problem.

No update from me. :pleading_face:

having the same issue. Someone have a solution for that?

I had the same problem, opened a ticket in the discord thread but was redirected to this forum.

is it possible to add an OAuth API for TikTok?

1 Like

The same problem

It doesn’t work

It’s already 2025, has anyone solved this problem with TikTok? Maybe it’s time for developers to pay attention to us?)

Sadly the community node does not work due to it crashing in one of its helpers function. I did create a PR that ‘might’ fix it but the repo seems dead.

The authentication works for me (with the client_key hack from above).

But the bearer access_token seem not to be set or added in header correctly for futur requests:

NodeApiError: Unable to sign without access token at ExecuteContext.execute (/home2/xxxxxx/nodevenv/n8nApp/20/lib/node_modules/n8n-nodes-base/nodes/HttpRequest/V3/HttpRequestV3.node.ts:752:15)

If I compute the access_token manually with this Pyhton code and add it to the header, it works:

The auth is successful but the access_token is not set correctly in oauth2 workflow for futur requests.

image

To late for me to continu :slight_smile:
Good night!