arthur-shaw / susoapi

R interface for Survey Solutions' APIs
https://arthur-shaw.github.io/susoapi/
Other
9 stars 5 forks source link

Workspace argument in `set_credentials` function #24

Closed ashwinikalantri closed 2 years ago

ashwinikalantri commented 2 years ago

May I suggest adding a workspace argument in the set_credentials function. This will reduce the need to set workspace for every function.

I feel that most processes don't work with different workspaces at a time. And even if there is such a scenario, the set workspace can be over-ridden in the function.

arthur-shaw commented 2 years ago

This is a great idea! When I updated the package to accommodate workspaces, I thought about this. At the time, I thought it would be better to let users set the workspace for each call. But after "eating my own dogfood" by using my package for a few projects, I think that your recommendation is right: let users set credentials and workspace for their "default" workspace, and make changes to the workspace if they need ot touch other workspaces on their servers.