app.zeens.getEngagement

zeens.app

Documentation

Like count and the viewer's own like for any record URI, one or a batch. Subject-agnostic: post_engagement is keyed by subject URI and the like hook counts likes on anything, so this serves zeens, events, articles and posts without a branch per lexicon. Pass `uris` to ask about a whole listing in one call -- the profile and studio Zeens tabs list from the author's repo, which carries no engagement, so without a batch each card would need its own round trip.

main query

Like count and the viewer's own like for any record URI, one or a batch. Subject-agnostic: post_engagement is keyed by subject URI and the like hook counts likes on anything, so this serves zeens, events, articles and posts without a branch per lexicon. Pass `uris` to ask about a whole listing in one call -- the profile and studio Zeens tabs list from the author's repo, which carries no engagement, so without a batch each card would need its own round trip.

Parameters

uri string at-uri Optional

A single record. Returns the bare object shape (uri/likeCount/viewer), which LikeButton and the zeen page depend on.

uris string Optional

Comma-separated AT-URIs, up to 100. Returns an `engagements` array instead of the single-record fields, with one entry per requested uri -- including subjects with no engagement row, which come back as a known 0 rather than being omitted (the caller draws nothing for "unknown" and a 0 for "none yet", and those differ).

viewer string did Optional

When given, the response carries this viewer's own like record.

Output

Encodingapplication/json
engagements array Optional

Present for a `uris` request. One entry per requested uri, in request order.

likeCount integer Optional

No description available.

uri stringat-uri Optional

An AT Protocol URI (e.g., at://did:plc:xyz/app.bsky.feed.post/abc).

Try It

Requests are sent directly from your browser. Some servers may block requests due to CORS.

Base URL for XRPC calls (e.g., https://api.bsky.social)
Parameters
A single record. Returns the bare object shape (uri/likeCount/viewer), which LikeButton and the zeen page depend on.
Comma-separated AT-URIs, up to 100. Returns an `engagements` array instead of the single-record fields, with one entry per requested uri -- including subjects with no engagement row, which come back as a known 0 rather than being omitted (the caller draws nothing for "unknown" and a 0 for "none yet", and those differ).
When given, the response carries this viewer's own like record.
View raw schema
{
  "description": "Like count and the viewer's own like for any record URI, one or a batch. Subject-agnostic: post_engagement is keyed by subject URI and the like hook counts likes on anything, so this serves zeens, events, articles and posts without a branch per lexicon. Pass `uris` to ask about a whole listing in one call -- the profile and studio Zeens tabs list from the author's repo, which carries no engagement, so without a batch each card would need its own round trip.",
  "output": {
    "encoding": "application/json",
    "schema": {
      "properties": {
        "engagements": {
          "description": "Present for a `uris` request. One entry per requested uri, in request order.",
          "items": {
            "ref": "#engagement",
            "type": "ref"
          },
          "type": "array"
        },
        "likeCount": {
          "type": "integer"
        },
        "uri": {
          "format": "at-uri",
          "type": "string"
        },
        "viewer": {
          "ref": "#viewerState",
          "type": "ref"
        }
      },
      "required": [],
      "type": "object"
    }
  },
  "parameters": {
    "properties": {
      "uri": {
        "description": "A single record. Returns the bare object shape (uri/likeCount/viewer), which LikeButton and the zeen page depend on.",
        "format": "at-uri",
        "type": "string"
      },
      "uris": {
        "description": "Comma-separated AT-URIs, up to 100. Returns an `engagements` array instead of the single-record fields, with one entry per requested uri -- including subjects with no engagement row, which come back as a known 0 rather than being omitted (the caller draws nothing for \"unknown\" and a 0 for \"none yet\", and those differ).",
        "type": "string"
      },
      "viewer": {
        "description": "When given, the response carries this viewer's own like record.",
        "format": "did",
        "type": "string"
      }
    },
    "required": [],
    "type": "params"
  },
  "type": "query"
}
engagement object

No description available.

Properties

likeCount integer Required

No description available.

uri string at-uri Required

An AT Protocol URI (e.g., at://did:plc:xyz/app.bsky.feed.post/abc).

viewer ref #viewerState Optional

No description available.

View raw schema
{
  "properties": {
    "likeCount": {
      "type": "integer"
    },
    "uri": {
      "format": "at-uri",
      "type": "string"
    },
    "viewer": {
      "ref": "#viewerState",
      "type": "ref"
    }
  },
  "required": [
    "uri",
    "likeCount"
  ],
  "type": "object"
}
viewerState object

No description available.

Properties

like string at-uri Optional

AT-URI of the viewer's like record, absent when they have not liked it. The record uri rather than a boolean, because unliking deletes it and a boolean would force a second lookup at the moment the user taps.

View raw schema
{
  "properties": {
    "like": {
      "description": "AT-URI of the viewer's like record, absent when they have not liked it. The record uri rather than a boolean, because unliking deletes it and a boolean would force a second lookup at the moment the user taps.",
      "format": "at-uri",
      "type": "string"
    }
  },
  "type": "object"
}

Lexicon Garden

@