-
Re: How do I get the number of active users in a group for a time period?
jleviMay 11, 2016 10:34 AM (in response to akoblentz)
1 person found this helpfulAre you looking at the Data Export Service and API? Using the V2 Jive Data Export Service (Analytics)
-
Re: How do I get the number of active users in a group for a time period?
akoblentz May 11, 2016 12:53 PM (in response to jlevi)I looked at the Data Export Service and couldn't figure out how to specify a certain group, my filters also didn't seem to be useful. When I did finally get data to show up in the preview, clicking on the download csv buttons gave me empty files.
This seems like something that shouldn't be this hard, especially since the data is pulled already internally for the graph on the user adoption report.
-
Re: How do I get the number of active users in a group for a time period?
jleviMay 11, 2016 2:22 PM (in response to akoblentz)
1 person found this helpfulHere is an example of using the Data Export UX to get all of the user activities for a given group:
I used the Destination Activities Filter using "DisplayName" filter
-
Re: How do I get the number of active users in a group for a time period?
jleviMay 11, 2016 9:39 PM (in response to akoblentz)
3 people found this helpfulAnother way to do this is using CURL to call the API.
First, you make a call to get the authorization code based on the client ID and secret:
curl -XPOST -i "https://api.jivesoftware.com/analytics/v1/auth/login?clientId=<client-id-from-addons>&clientSecret=<client-secret-from-addons>"
And then you make the call:
This get s all activity but just the listed fields in a CSV. You can then use filters in Excel to filter the results.
curl -XGET -H "Authorization: <authorization-id>" "https://api.jivesoftware.com/analytics/v2/export/activity/csv?fields=activity.actor.name,activity.destination.name" > group.csv
-
Re: How do I get the number of active users in a group for a time period?
jleviMay 11, 2016 9:50 PM (in response to jlevi)
2 people found this helpfulAnd to refine this, you can limit to a specific place in the call like this:
curl -XGET -H "Authorization: <authorization-id>" "https://api.jivesoftware.com/analytics/v2/export/activity/csv/lastweek?filter=place(O365+Integration+Demo)&fields=activity.actor.name,activity.destination.name" > group.csv
-
Re: How do I get the number of active users in a group for a time period?
jleviMay 12, 2016 6:11 AM (in response to jlevi)
2 people found this helpfulNote that you must replace white space with + in the filters! Thanks to Stewart Wachs for helping me figure that out!
-
Re: How do I get the number of active users in a group for a time period?
akoblentz May 12, 2016 6:12 AM (in response to jlevi)Thanks, I'll try this right now.
-
Re: How do I get the number of active users in a group for a time period?
jleviMay 12, 2016 10:00 AM (in response to akoblentz)
1 person found this helpfulLet us know how it goes. Also, check out Simple Script for Jive Data Export Service
It automates things a bit. I went through the steps of using the API directly from the examples in the link I mentioned above as I am trying to learn more about these details myself. The simple script also allows you to select the time range and add filters.
-
Re: How do I get the number of active users in a group for a time period?
akoblentz May 12, 2016 10:49 AM (in response to jlevi)I'm definitely making progress, I just need to figure out how to handle additional filters.
We have 3 types of users:
- Customers
- Employees
- Partners
Ideally I would only get the numbers for customers and partners. In the user adoption report, I can pick one at a time with a "member type" drop down to filter. I wasn't around when Jive was implemented in my org, when I look at the JSON for an employee there's roleBadge section like this:
"roleBadge" : {
"groupBadgeUri" : "/resources/statics/rolebadges/roleBadge-4-1006-1418046805657.png",
"groupBadgeRoleName" : "Employee",
"type" : "roleBadge"
}
and partners have
"roleBadge" : {
"groupBadgeUri" : "/resources/statics/rolebadges/roleBadge-4-1039-1438623350004.png?a=1438623350029",
"groupBadgeRoleName" : "Expert",
"type" : "roleBadge"
}
Customers do not have a roleBadge, and as far as I can tell, that's the only thing differentiating the different types of members. Any idea how to filter based on that? I've been pulling all of the user data in my code and just counting them if they meet critera based on roleBadge in the JSON. Ideally I would do that server side through Jive.
-
Re: How do I get the number of active users in a group for a time period?
jleviMay 12, 2016 11:31 AM (in response to akoblentz)
1 person found this helpfulI don't see a way to get all of that to happen on the Jive side. Possibly using the batch service but that is out of my depth. Since you get enough user information from analytics to then invoke more REST calls, it sounds like you are doing the right things. Let me see if anyone internal to Jive has some experience or ideas here.
-
Re: How do I get the number of active users in a group for a time period?
akoblentz May 12, 2016 11:43 AM (in response to jlevi)-
Re: How do I get the number of active users in a group for a time period?
jleviMay 12, 2016 1:03 PM (in response to akoblentz)
1 person found this helpful"Ah, that means that your community profile has a profile field called "Member Type" that is filterable and that is why it is showing up there. If you go to the people browser, you should see the same filter option. So your community was set up to designate the member type in their profile. The analytics API doesn't capture all of the profile fields for doing this type of filtering so it must be a mix of REST and analytics calls. I wasn't thinking about CMR when you first posted this so let me ask that team how they do that."
Edited: This was a wrong assumption on my part. I am also learning how all of this works so see below for a solution. The API does bring forward the user profile fields from Jive and allows you to filter by these fields as you asked previously.
-
Re: How do I get the number of active users in a group for a time period?
akoblentz May 12, 2016 12:59 PM (in response to jlevi)Thanks so much Joey Levi I really appreciate the help, I've been incorrectly reporting metrics on my community because I was misinformed about the exporter and active buckets working differently than they do, so now I'm scrambling to get this done so I can redo my historic data.
-
-
-
-
Re: How do I get the number of active users in a group for a time period?
Scott A Johnson May 12, 2016 11:38 AM (in response to akoblentz)1 person found this helpfulIf the roleBadge field is present in the Analytics response, you may be able to use a combination of filters to "exclude" Employees like this.
filter=not(match(activity.actor.roleBadge.groupBadgeRoleName,Employee))
-
Re: How do I get the number of active users in a group for a time period?
jleviMay 12, 2016 1:00 PM (in response to akoblentz)
1 person found this helpfulOkay - I think this will solve your problem. You can add a filter to match on specific profile fields. I just wasn't sure how to construct the filter but I found it in a post internally.
This query will pull back activities for a place where the user's profile field "Title" is "Chief Training Officer":
curl -XGET -H "Authorization: <authorization id>" "https://api.jivesoftware.com/analytics/v2/export/activity/csv/lastweek?filter=place(O365+Integration+Demo)&filter=match(activity.actor.profile.title,Chief+Training+Officer)&fields=activity.actor.name,activity.destination.name" > groups.csv
The results of this are:
activity.actor.name activity.destination.name name timestamp Buck Rivard O365 Integration Demo ACTIVITY_CREATE_TILEINSTANCE 1.46299E+12 Buck Rivard O365 Integration Demo ACTIVITY_CREATE_TILEINSTANCE 1.46299E+12 Buck Rivard O365 Integration Demo ACTIVITY_CREATE_TILEINSTANCE 1.46299E+12
So I ave selected a place and then specific type of user based on a profile field match.
-
Re: How do I get the number of active users in a group for a time period?
jleviMay 12, 2016 1:02 PM (in response to jlevi)
1 person found this helpfulI meant to add in your case it would be filter=match(activity.actor.profile.MemberType,Customer)
-
Re: How do I get the number of active users in a group for a time period?
akoblentz May 13, 2016 8:31 AM (in response to jlevi)One more quick question, then I think I might have gotten what I need... How do I match for multiples?
In my case it'd be filter=match(activity.actor.profile.MemberType,Customer) and filter=match(activity.actor.profile.MemberType,Partner)
-
Re: How do I get the number of active users in a group for a time period?
Scott A Johnson May 13, 2016 8:40 AM (in response to akoblentz)2 people found this helpfulCheck out the 'or' filter.
-
Re: How do I get the number of active users in a group for a time period?
jleviMay 13, 2016 8:44 AM (in response to Scott A Johnson)
1 person found this helpfulI didn't read that. Yes, you need the 'or" filter!
-
Re: How do I get the number of active users in a group for a time period?
jleviMay 13, 2016 8:48 AM (in response to jlevi)
So my example changes to:
curl -XGET -H "Authorization: <auth-id>" "https://api.jivesoftware.com/analytics/v2/export/activity/csv?count=all&filter=or(match(activity.actor.profile.department,Sales),match(activity.actor.profile.title,Territory+Sales+Manager))&filter=place(Corporate+Communications)&fields=activity.actor.name,activity.destination.name" >groups.csv
-
-
-
Re: How do I get the number of active users in a group for a time period?
jleviMay 13, 2016 8:43 AM (in response to akoblentz)
1 person found this helpfulHere is a test I just used:
curl -XGET -H "Authorization: <auth-id>" "https://api.jivesoftware.com/analytics/v2/export/activity/csv?count=all&filter=match(activity.actor.profile.department,Sales)&filter=match(activity.actor.profile.title,Territory+Sales+Manager)&filter=place(Corporate+Communications)&fields=activity.actor.name,activity.destination.name" > groups.csv
This gets all activities for any users whose profiles match Department=Sales and Title=Territory Sales Manager in the Corporate Communications place.
-
Re: How do I get the number of active users in a group for a time period?
akoblentz May 13, 2016 8:44 AM (in response to jlevi)Thanks so much guys, I'll play with this a bit, I think I'm in great shape though.
-
-
-
Re: How do I get the number of active users in a group for a time period?
akoblentz May 13, 2016 9:00 AM (in response to jlevi)Okay, it seems that isn't working. For fun, I tried to specify activity.actor.profile.MemberType as one of the fields for the csv just so I can see what's happening, and I got an error:
Invalid field header specified: "activity.actor.profile.MemberType" The field either does not exist or may not exist within the time range specified.
Any other ideas how that might be represented? I guess I can start dumping profile objects. But as far as I can tell it's done through the role badge I mentioned before.
-
Re: How do I get the number of active users in a group for a time period?
jleviMay 13, 2016 9:14 AM (in response to akoblentz)
Adam, I sent you a direct message.
-
-
-
-
-
-
-
-
-
-