Reactions and Social Graph
Use the built-in integration between Reactions and Social Graph to filter and count user reactions by others that fans follow.
Common parameters
The relationship_type
parameter species what kind of relationship to filter responses by. Its value should be the relationship type key like follows
belonging to the relationship type from the social graph to filter by.
The relationship_from_profile_id
species the perspective that the filtering should be from. Its value should be the profile ID in the from part of the relationship. For example, if Alice follows Bob, then the relationship is from Alice to Bob, and Alice would be the from part. If this parameter is not provided then it defaults to the authenticated user.
Filter reactions by profile relationship
Use the relationship_type
and relationship_from_profile_id
parameters on the List user reactions endpoint to filter reactions by authors matching the given relationship. For example, to find reactions from users that example-profile-id follows:
GET /api/v1/user-reactions/?relationship_type=follow&relationship_from_profile_id=example-profile-id&reaction_space_id=example-space-id
If the relationship_from_profile_id
is omitted, it is assumed to be the authenticated profile:
GET /api/v1/user-reactions/?relationship_type=follow&reaction_space_id=example-space-id
The above will return reactions from users that the authenticated user follows.
Count reactions by profile relationship
Use the relationship_type
and relationship_from_profile_id
parameters on the Get user reaction count endpoint to count reactions from users that match the given relationship.
GET /api/v1/user-reactions-count/?relationship_type=follow&relationship_from_profile_id=example-profile-id&reaction_space_id=example-space-id
Updated 2 days ago