3 Replies Latest reply on Dec 7, 2012 2:24 AM by mrowbory Branched from an earlier case.

    Re: How do I get the current user with the API


      Thanks, another basic question that I should really have started a new thread for...


      How do I pass a place ID... surely it needs to contain a container type and ID?  I was looking for an api abc but couldn't see something to that basic level.  Well the search doesn't appear to work at all, at least not in chrome: Jive REST API v3.0 → Place service


      Get Activity

      GET /places/{placeID}/activities

        • Re: How do I get the current user with the API

          GET /places does return place IDs.

          • Re: How do I get the current user with the API

            Yep ... a new thread would definnitely help people find the answer more easily. 


            In the V3 API, all of the places (spaces, groups, projects, etc.) have been unified into a single REST endpoint -- you distinguish what type a particular place is by consulting the "type" field.  To pull this off, there has to be a Jive-instance-wide unique numeric identifier for each place that is used for {placeID} in the URLs.  This is *not* the same as the "id" value that is included in the response (which is only unique within an object type).


            The best policy is to never construct URLs yourself.  If you want to get the activities for a place:

            • Retrieve the place object itself, by searching or browsing or whatever.
            • In the "resources" field, find the "activities" resource and follow the URL there.

            This approach completely insulates you from having to understand how URLs are constructed, and protects your application from breaking if the way that works is ever changed.


            By the way, the same unification concept applies to content as well -- the {contentID} you see in the API documentation has nothing to do with the "id" fields that are returned.