1. Home
  2. For Workplace Communities
  3. Contexts

Contexts

Using the Grytics API for Workplace Communities implies using contexts. There are five of them :

  • Groups
  • Dashboard
  • MCGs
  • Axes
  • Segment

Groups context

If you want to get statistics and content from one group, you have to use this context. Network Group Id in the request and then the endpoint wanted. For example :

https://api.work.grytics.com/{network_type}/{network_guid}/groups/{network_group_id}/posts/?from=1&to=123456789&p=0&limit=25

https://api.work.grytics.com/{network_type}/{network_guid}/groups/{network_group_id}/posts/top/engaged/?from=1&to=123456789

Dashboard Context

The Dashboard context is reserved for statistics and list for all your groups except MCGs (as imported and configured on your Grytics account).

Using it is similar to the group context but you do not need a group id. Here are some calls :

https://api.work.grytics.com/{network_type}/{network_guid}/dashboard/posts/?from=1&to=123456789&p=0&limit=25

https://api.work.grytics.com/{network_type}/{network_guid}/dashboard/posts/top/engaged/?from=1&to=123456789

Some endpoints related to the members are not available here. Refer to the Member reference section.

MCGs Context

The MCGs context is the same as the Dashboard except it is dedicated to all your MCGs (if added to Grytics).

https://api.work.grytics.com/{network_type}/{network_guid}/mcgs/posts/?from=1&to=123456789&p=0&limit=25

https://api.work.grytics.com/{network_type}/{network_guid}/mcgs/posts/top/engaged/?from=1&to=123456789

Axes Context

The axes context allows you to get the list of segments and their stats for a given axis.

https://api.work.grytics.com/{network_type}/{network_guid}/axes/{axis_id}/segments/stats/?from=1&to=123456789&p=0

Segment Context

The segment context is similar to the dashboard and group contexts. This rely on the segment id (available on your Grytics account)

https://api.work.grytics.com/{network_type}/{network_guid}/segments/{segment_id}/posts/?from=1&to=123456789&p=0&limit=25

Was this article helpful to you? Yes No