Get Apps returns an app’s spaceId, but does not indicate whether it is a guest space. Get Space requires that I know in advance whether a space is public or guest, because the URL is different in each case. It would be convenient if there were a Get Spaces API that returned information for all spaces in one call.
As it stands now, I have to assume that a space is public, call Get Space accordingly, then if that fails, issue the call again with a modified URL. I have to redundantly include the spaceId as part of the URL and as an argument.
Can you tell us little bit more about your case? Where are you trying to do it from? From a guest space? Or a (public) space?
I’m working on a .NET library that provides a common SQL-based interface to multiple data providers, including Kintone. The library can be used in a console or desktop app, with user/password supplied via a connection string. The library uses Get Apps to derive a list of “tables” that the authenticated user has access to. If the library references a table by name, and the corresponding spaceId is not null, there is no way to determine whether it is in a guest space other than the brute force method described in the last paragraph of my original post.
When executing the API from an external service, It is difficult to determine in advance that it is a guest space.
※When acquiring space information, the URI is different for space and guest space.
For this reason, we have to assume that it is a space, as you have done, and if you run the API and get an error, the only way to deal with it is to switch the URI.
Sorry about the inconvenience.
I can live with the workaround. Thanks for your reply.
John, thanks for sharing your use-case.
Sorry we couldn’t help out due to specification limitations - I’ve shared your scenario with our Kintone dev team!