I´m neewbie in working with the Monday-APIv2 so far.
Therefore I will ask my newbie question as well
I´m working for a company where we are already working with about 5 Monday-Accounts.
For my further project I would like to show up each boards per User on our own Website.
We have already all that Users SignedUp on our own Website.
Next step should be to generate the API-Token for every User, so that each User will have his own API-Token which will refer to his Boards when LoggingIn to our Website.
My Question:
Where can I generate the API-Tokens for each User?
So far I have only find this Option for my Monday-Admin-Account but not for the other Users.
There are a couple of ways to generate an API token for a given user:
Using the OAuth2 protocol. You can set up a monday App (link to docs) and use our SDK to let each user authorize your project separately. Check out the documentation for our OAuth implementation here. You can also see a simple code example using the OAuth flow here.
Asking each user for their API key. Each user can access their tokens in the monday apps section. This is not recommended because of the manual work, but is an option. To do this, they need to first activate “monday apps” in the monday.labs section of their account (link to article). Then, they will be able to get their tokens in the “My Tokens” tab of the developers section:
thank you for your support!
I guess the best decision for me would be number one.
Therefore I tried to set up the github sample you have recommended.
Setting everything up (nodejs, monday-app, permissions and so on) was working fine.
Unfortunatelly I do not understand the reason for using the ngrok-tool.
Can´t I just connect my website with my monday app with oauth2 without ngrok?
Furthermore I do not understand what kind of url i should set up for the redirect url.
What should the redirect url look like?
I tried a existing URL of my localhost (http://localhost/monday-oauth-example-master/public/finish.html) but I received the error message:
|error|“invalid_request”|
|error_description|“Invalid redirect_uri”|
the whole purpose of ngrok is expose your localhost to a public URL.
In other words, monday.com gets a connection to the machine you are running ngrok on.
thank you for your support!
I have tried running the sample now with ngrok and nodejs.
I get the index.js running on the npm and start up ngrok with localhost on port 3000.
If I navigate to the ngrok https-link,
it is loading the correct Start Page including the Start Button.
Unfortunatelly when clicking on it I receive the following invalid request error:
|error|“invalid_request”|
|error_description|“Invalid redirect_uri”|
I think I have to fix some configuration on the monday app but I´m not sure.
Can you tell me which link I need to configure for redirect?
In the ngrok console I receive a error message for:
Get /favicon.ico 404 Not Found
The redirect URI must match the URIs that you have set up in your app. To check which URIs are valid, go to your app > OAuth & Permissions > Redirect URIs.
If you’re using ngrok, you might need to change this configuration each time you generate a new ngrok tunnel (since each one has a unique URL).
hi @max91 I’m running into the SAME issue!! All the individual components load for me too, but clicking on the btn brings up the “invalid redirect_uri” error Did ever get it resolved? If so, can you please share what you did?