Social API reference

Social API · Reposts

post/v1/communities/{community_id}/posts/{post_id}/repostAuth

Repost a source post on behalf of an actor. Idempotent — returns the existing repost row with `created: false` on retry.

Visibility is inherited from the source. The reposter must be allowed to read the source (else 404). Self-repost 422; private-source repost 422. Bumps `source.repost_count` and the reposter's `post_count`. Fires a `repost` notification to the source author (subject to per-kind preferences from task 021).

Path parameters

community_id*string

Social community UUID. Must belong to the PAK's workspace.

post_id*string

Source post UUID.

Request body

actor_id*string · uuid

Reposting actor UUID — the customer-backend supplies the end-user identity here.

Example: "aaaaaaaa-0000-0000-0000-000000000001"

Response · 201 Repost created (or returned via idempotent retry).

repost*object

The newly-created (or existing) repost post row.

source*object

The source post, with refreshed `repost_count`.

created*boolean

`true` on first call; `false` on idempotent retry of an existing repost.

Example: true

Example

Request

POST https://social.productcraft.co/v1/communities/{community_id}/posts/{post_id}/repost
Authorization: Bearer YOUR_TOKEN
Content-Type: application/json

{
  "actor_id": "aaaaaaaa-0000-0000-0000-000000000001"
}

Response

{
  "repost": {},
  "source": {},
  "created": true
}