BizKitHub
DocsAPI ReferencePost/bff/post/history-diff
getPostAdmin BFF

/bff/post/history-diff

Returns a structured diff between two revisions of the same post + locale. Title is word-grain (titles are short, word grain reads naturally), content is line-grain (HTML/markdown bodies — line grain keeps block edits readable). Both revisions must belong to the same post and locale; cross-post or cross-locale diffs are rejected as caller errors.

PostgetBffPostHistory-diff

Parameters

2 query

Query parameters

· 2
fromstringRequired

Older revision handle (left side of the diff).

ExamplevErSiOnHaNdLe123
tostringRequired

Newer revision handle (right side of the diff).

ExamplevErSiOnHaNdLe456

Response schema

1 status code documented

200Success
fromobjectRequired
idstringRequired

Version handle.

insertedDateDate | string | string | numberRequired
One of 4:
Variant 1
Date
Variant 2
stringdate-time
Variant 3
stringdate
Variant 4
number
titlestringRequired
contentSizenumberRequired
localestringRequired
authorobjectRequired
idstring | nullRequired
One of 2:
Variant 1
string
Variant 2
null
namestringRequired
toobjectRequired
idstringRequired

Version handle.

insertedDateDate | string | string | numberRequired
One of 4:
Variant 1
Date
Variant 2
stringdate-time
Variant 3
stringdate
Variant 4
number
titlestringRequired
contentSizenumberRequired
localestringRequired
authorobjectRequired
idstring | nullRequired
One of 2:
Variant 1
string
Variant 2
null
namestringRequired
titleDiffobject[]Required
Each array item:
type"context" | "add" | "remove"Required

context = unchanged region, add = present only in to, remove = present only in from.

valuestringRequired

Verbatim slice of the document. Whitespace preserved.

contentDiffobject[]Required
Each array item:
type"context" | "add" | "remove"Required

context = unchanged region, add = present only in to, remove = present only in from.

valuestringRequired

Verbatim slice of the document. Whitespace preserved.

statsobjectRequired
titleAddednumberRequired

Words added to the title.

titleRemovednumberRequired

Words removed from the title.

contentAddedLinesnumberRequired

Lines added to the content.

contentRemovedLinesnumberRequired

Lines removed from the content.

Response example

application/json
{
  "from": {
    "id": "example_id",
    "title": "example_title",
    "contentSize": 0,
    "locale": "example_locale",
    "author": {
      "name": "example_name"
    }
  },
  "to": {
    "id": "example_id",
    "title": "example_title",
    "contentSize": 0,
    "locale": "example_locale",
    "author": {
      "name": "example_name"
    }
  },
  "titleDiff": [
    {
      "value": "example_value"
    }
  ],
  "contentDiff": [
    {
      "value": "example_value"
    }
  ],
  "stats": {
    "titleAdded": 0,
    "titleRemoved": 0,
    "contentAddedLines": 0,
    "contentRemovedLines": 0
  }
}

Request example

GET /bff/post/history-diff

get
curl -X GET "https://api.bizkithub.com/bff/post/history-diff?from=vErSiOnHaNdLe123&to=vErSiOnHaNdLe456" \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer YOUR_API_KEY"

Need an API key?

All BizKitHub public API endpoints require authentication via API key.

Get API Key