CustomAPI new follower command.

When trying to create a custom API for nightbot to thank new followers in the chat when they follow using nightbot, I’m running into issues when trying to put the actual command into the cmd prompt. The guide I’m following is found here; Nightbot Alerts In Chat.

When I put in the command - ```
curl -X POST “https://api.nightbot.tv/oauth2/token” -d “client_id=<CLIENT_ID>&client_secret=<CLIENT_SECRET>&grant_type=refresh_token&refresh_token=<REFRESH_TOKEN>”


and enter my client ID and the client secret in the area's shown above it comes back with -

{"message":"Invalid client: client is invalid","code":400,"name":"invalid_client"}

not sure what to do about this now even after creating the custom widget through streamlabs to enable the custom javascript add on for the API to send it in the livechat.

Thanks

Hey @redtxgg!

Make sure the CLIENT_ID, CLIENT_SECRET and REFRESH_TOKEN are proper, don’t use these characters < > either.

1 Like

Hi @Emily

I’ve removed the < > characters now and make sure everything is correct which it is, however now I only receive this message in reply to what I sent previously;

{“status”:404,“message”:“Not Found”}

I can’t make sure my refresh token is correct as I meant to receive that after I send the first command which allows me to get my refresh token as well as my access token, however I can’t even get the first command to work yet.

I get it now, it’s because you’re using the wrong command, read the guide carefully, it works fine:

1 Like

Oh damn I’m blind lmao

Thanks a lot for the help, got it working now

1 Like

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.