11 Replies Latest reply on Jan 4, 2016 4:31 PM by moesingh

    How to get partcipated content of all users belong to a specific Company

    hymavathi

      Hi,

      We want to show users list of all content that is participated by users belong to a company they enter . I know that we can get the list of people filtered by company through

      /api/core/v3/people?filter=company(COMPANY). Once I have the userids how can I get the content participated by each user? When I looked over the existing APIs I see we can filter content by list of authors but participated filter can only be applied to the logged in user.

      Any suggestions/ideas from any one?

       

      Pawan Shah

        • Re: How to get partcipated content of all users belong to a specific Company
          pawans

          Hi Hymavathi Oruganti,

          There is no api to support this.

           

          But a Jugaad technique came to my mind right now.

          Worth a try if this is super important for you (btw meaning of jugaad here --> Jugaad - Wikipedia, the free encyclopedia  )

          I have never tried this, but in theory this should work. And I admit at the very start, this is crazy solution

          But may be this will lead you to a better solution.

           

          you can have company specific service accounts on your jive instance.

          Lets say the company name is coffee, you will have a service account for it called coffee_bot.

          Now when a user joins the company, you might want to show them activities of all people in the company, or of people with specific roles (Dev, UX, etc)

          So this service account of yours can have multiple streams.

          And these streams obviously will show authored as well as participated content of all users.

           

          you can use webhooks to ensure every new user joining this company's group is added to the streams of this service account.

           

          Now when the user joins a group, you can have a custom tile on that group.

          Your tile service which has access to this service account's streams can push the activities of all users in that group to the tile.

          This way you will be in a position to show data you need.

           

           

          The service account concept is bit used in some drive integration in jive I guess.

          google drive by default expects content owned by a user, not a group.

          The way drive integration works is when you enable drive for a group, some folder is created in google drive where owner is a service account.

          even if any user created a document, its saved in drive under service account's ownership.

          This drive example is not relevant to the solution you are looking for, but just gave an example of how service accounts can help achieve stuff.

            • Re: How to get partcipated content of all users belong to a specific Company
              hymavathi

              Hi Pawan,

              Interesting approach. But If I do understand correct, the streams will show the activity of people in streams that is being created new going forward. Or will it show the old dat as well? I am planning to get the people from the people service filter by company and get the content browseIDs for the userIDs.The contentBrowseIds will be passed to the content api and wil show the content created/partcipated by the people of that comapny.

              Do you think that this shoild work?

                • Re: How to get partcipated content of all users belong to a specific Company
                  pawans

                  Hi Hymavathi Oruganti,

                  Good catch there. the solution might show only the content participated in from the day you setup the so called magic user with streams.

                   

                  For the solution you mentioned, i would suggest get people from people service filtered by company, and then use the activity resource url which somes as part of the api response for every user's data.

                  Here you might have to do some magic to sort the activities.\

                  BTW, just in process of giving a jugaad solution, forgot to ask one few questions.

                   

                  • Where exactly are you planning to display the activities to a logged in user?
                  • Does every company already have one big group where every user of the company is member of? If that's the case, we can just utilize some activity tile on that group
                  • If thats not the case, then part of the solution i gave or you had can help.
                    • Re: How to get partcipated content of all users belong to a specific Company
                      hymavathi

                      Hi Pawan Shah

                       

                      Happy New Year!!! Sorry was on vacation so could not respond to your questions.

                       

                      Our business wants to show it in "All content" page and I do not think it is possible correct?

                      • Does every company already have one big group where every user of the company is member of? If that's the case, we can just utilize some activity tile on that group

                      Yes  we have companies and their associated groups. I like the tile approach. But there is some open content which can be shown to any one. Our business wants users to search content belongs to not only their organization but also of anybody's which they are authorized to view. Can we check the user entitlements on a content? Is it not resource intensive if I want to check all this in an add on?

                       

                       

                      I am also checking if Add on or Plugin is a n option to achieve the requirement. Please let me know your thought.

                • Re: How to get partcipated content of all users belong to a specific Company
                  Adam Arrowsmith

                  Hi Hymavathi Oruganti I basically have the same question. Ideally a way to summarize and report on user community activity/ranking by "company" (for example, to rank our top contributors by partner). I'm quite new to Jive but is there a way to reliably (i.e. not trusting user-entered data) populate the company or other field on the user profile object that could be used for aggregation?

                  • Re: How to get partcipated content of all users belong to a specific Company
                    moesingh

                    you can do sql for a db lookup for users who are within a company?  turn that into an action that shoots out json and you should be good to go.