By default users are not shown the permission dialog if they have already approved the set of scopes for this application.
But I can't see how to reach this behaviour. Working with the demo app https://github.com/smartcar/getting-started-express in test mode what I see is that the permission dialog is always displayed, and upon completion of the flow the backend receives a fresh access token but if I call getUser with it then it resolves to the same user id. But whichever vehicles are authorised replace any previously authorised vehicles for that user.
Is this a peculiarity of the test environment, or that's how it works in live too?
Is there a way to authorise additional vehicles for an existing user id?
The docs for
getAuthUrl
say:https://github.com/smartcar/node-sdk/blob/master/doc/readme.md#authclientgetauthurlscope-options--string
But I can't see how to reach this behaviour. Working with the demo app https://github.com/smartcar/getting-started-express in test mode what I see is that the permission dialog is always displayed, and upon completion of the flow the backend receives a fresh access token but if I call
getUser
with it then it resolves to the same user id. But whichever vehicles are authorised replace any previously authorised vehicles for that user.Is this a peculiarity of the test environment, or that's how it works in live too?
Is there a way to authorise additional vehicles for an existing user id?