Skip to main content

User-related API environment

Production user-related API docs

These pages describe the Production user-related API stack.

Use production OAuth credentials, production API base URLs, and production app URLs when following this documentation.

Need to test before going live? Switch to the Pre-live docs using the environment switcher above.

Set or toggle a post reaction​

The /v1/posts/{id}/reactions route requires an OAuth user access token in x-auth-token; client-credentials tokens are not accepted. The unversioned /posts/{id}/reactions alias instead requires the existing native session cookie. Both require a post visible to the authenticated user. Adds a reaction when none exists, changes a different reaction without changing the total, or removes the same reaction when selected again. This is a toggle, not an idempotent setter: do not automatically retry a mutation with an unknown outcome. Legacy likes are reaction1. Newly applied reactions use the existing like notification flow; changes and removals do not create another notification. Returns the service-native payload directly, with null values included for absent reactions. Gateway exposure and scope enforcement are managed separately.

Path Parameters
    id number required

    Numeric post identifier.

Header Parameters
    x-auth-token string required

    OAuth user access token for the documented /v1 route. The unversioned /posts alias uses the native session cookie instead.

Request Body required
    reactionType string required

    Possible values: non-empty and <= 32 characters, Value must match regular expression ^[a-z][a-z0-9_]{0,31}$

    Stable, case-sensitive reaction identifier: 1–32 lowercase letters, digits or underscores, starting with a letter. Identifiers are generic so the available reactions can evolve without an API change.

Responses

Reaction applied, changed, or removed.


Schema
    reactionType string nullable required

    The resulting reaction, or null when the selected reaction was removed.

    previousReactionType string nullable required

    The preceding reaction, or null when there was none. Legacy likes are reaction1.

    action string required

    Possible values: [applied, changed, removed]

    reactionsCount number required

    The post’s aggregate reaction count after the mutation.

Loading...