Search code examples
react-nativesmartsheet-api

What will be re-direct URL of mobile app for smartsheet


Beginner programmer here. I am trying for third party app development from Smartsheet api in React Native. Just following OAuth flow which is mentioned here http://smartsheet-platform.github.io/api-docs/?javascript#third-party-app-development Here is the request which i need to send "GET https://app.smartsheet.com/b/authorize"

And params with it are following: response_type: 'code', client_id: '1samp48lel5for68you', redirect_uri: 'http://localhost:3000/callback' (But i don't know what will be for my React Native app.), scope: 'CREATE_SHEETS WRITE_SHEETS',

So my question is what will be redirect_uri for my app ? If i use any dummy web callback uri it gives me error of invalid uri. I want to request for an Authorization Code from that api.

Please help me out i have already spent so many hours to solve this issue but in vain. Thanks in advance.


Solution

  • Setting up an application for the Smartsheet OAuth flow requires providing an HTTPS URL for the APP redirect URL when registering the app. For this you can setup an OAuth server (using Node.js & Express possibly) to do all of the authentication work. Then your mobile app talks to that server to trigger the authentication process. This server could also be used to do all of the interaction with the Smartsheet API itself. Then your mobile app talks to this server to get the data it needs from Smartsheet.