Skip to main content
An entity is the core content unit in Replyke — it can represent a post, article, product listing, video, or any other piece of content in your application. Entities support reactions, comments, votes, file attachments, geo-location, and more.

Properties

PropertyTypeDescription
idstringUnique entity identifier (UUID).
foreignIdstring | nullYour system’s content ID, if this entity maps to existing data. Can also be a static identifier like "about-page".
shortIdstringAuto-generated short identifier, useful for sharing links.
projectIdstringThe project this entity belongs to.
sourceIdstring | nullGroups entities by content type within a project. Useful when one project hosts multiple distinct categories of content (e.g. "user-post" vs "blog-post"), allowing you to filter and separate them without creating separate projects.
spaceIdstring | nullThe space this entity belongs to, if any.
spaceSpace | nullPopulated space object when include contains "space".
userIdstring | nullID of the user this entity is associated with. null if the entity is not associated with any user.
userUser | nullThe author. Populated when include contains "user".
titlestring | nullOptional title.
contentstring | nullOptional text content.
mentionsMention[]Array of user mentions embedded in the content.
attachmentsRecord<string, any>[]Flexible array of media/attachment metadata objects.
filesFile[]System-managed file associations. Populated when include contains "files".
keywordsstring[]Tags used for filtering and discovery.
upvotesstring[]Legacy v6 field — array of user IDs that upvoted. Use reactionCounts instead.
downvotesstring[]Legacy v6 field — array of user IDs that downvoted. Use reactionCounts instead.
reactionCountsReactionCountsCounts for all 8 reaction types. See Reaction.
userReactionReactionType | nullThe current user’s reaction. Only present when the user is authenticated and has reacted to this entity.
repliesCountnumberTotal number of comments and replies on this entity.
viewsnumberView count. Auto-incremented on every fetch. Can also be incremented manually via the service-key-only PATCH /entities/:entityId/increment-views endpoint.
scorenumberComputed “hotness” score based on engagement activity.
scoreUpdatedAtDateWhen the score was last recalculated.
locationGeoPoint | nullOptional geo-location stored as a GeoJSON point.
metadataRecord<string, any>Custom key-value data (max 10 KB).
topCommentTopComment | nullThe highest-voted comment. Populated when include contains "topComment".
isSavedbooleanWhether the current user has saved this entity to a collection. Populated when include contains "saved".
isDraftboolean | nullWhether this entity is in draft state.
moderationStatus"approved" | "removed" | nullCurrent space moderation status.
moderatedAtDate | nullWhen the moderation action was taken.
moderatedByIdstring | nullID of the moderator who took the action.
moderatedByType"client" | "user" | nullWhether a client (admin) or user performed moderation.
moderationReasonstring | nullReason provided for moderation.
createdAtDateWhen the entity was created.
updatedAtDateWhen the entity was last updated.
deletedAtDate | nullSoft-delete timestamp. null for active entities.

Nested Types

TopComment

Included when the entity has at least one comment.
PropertyTypeDescription
idstringComment identifier.
userUserThe comment author.
upvotesCountnumberNumber of upvotes on this comment.
contentstringComment text content.
createdAtstringISO timestamp string.

GeoPoint

PropertyTypeDescription
type"Point"GeoJSON geometry type. Always "Point".
coordinates[number, number]Longitude and latitude, in that order.

Includes

Pass an include array to populate optional fields:
Include valuePopulates
"user"user — the entity author
"space"space — the associated space
"topComment"topComment — top-voted comment
"saved"isSaved — whether current user saved this entity
"files"files — managed file records

See Also