Contents

List pending tracked revisions on a document working draft

GET /documents/{documentId}/revisions

Path parameters

  • documentId string Required

Headers

  • Authorization string Required

    Bearer <session token>: the signed-in user’s Scaffold session token.

  • x-org-id string Required

Returns

  • document object

    A document/version summary, as returned by the read-oriented document routes (overview, revisions, content).

    Show 16 fields
    • id string
    • seriesId string
    • version integer
    • versionKind string

      One of original working_draft

    • parentDocumentId string | null
    • title string
    • mimeType string
    • purpose string

      One of source_doc playbook

    • description string
    • hasXml boolean
    • hasText boolean
    • sizeBytes integer
    • fileName string
    • contentSha256 string | null
    • createdAt string
    • updatedAt string
  • revisions object[]
    Show 7 fields
    • ordinal integer Required

      The change's position in document order.

    • change_id string Required

      The id to pass in accepted_change_ids or rejected_change_ids.

    • kind string Required

      insert and delete are text changes, paragraph_mark is an inserted or deleted paragraph mark (a paragraph split or join; it carries no text of its own), proposed is a Scaffold change marker, and the -prop-change kinds are tracked formatting or structure changes.

      One of insert delete paragraph_mark proposed r-prop-change p-prop-change tbl-prop-change tr-prop-change tc-prop-change sect-prop-change

    • author string | null
    • date string | null
    • text_preview string Required

      A short excerpt of the changed text.

    • justification string | null

      The reason recorded with the change, shown to the reviewer.

  • renderContentBase64 string | null
  • agentAuthor string

    The name this caller's agent edits under ("Scaffold Assistant for <email>"). The agent's own changes are exactly the ones with this author; the edit answers name it too.

  • track object | null

    Null when the decisions store failed to load; the read still succeeds.

    Show 3 fields
    • items object[]
      Show 14 fields
      • id string Required
      • state string Required

        One of open in back

      • label string Required

        Positional label, e.g. "Change 3".

      • kind string | null
      • textPreview string
      • justification string | null

        The reason the change carries. On a decided entry, the reason it carried when it was decided (null for decisions made before that was recorded).

      • author string | null

        Present on both open and decided entries.

      • date string | null

        Open entries only.

      • decidedAt string

        Decided entries only.

      • decidedByUserId string | null

        Decided entries only.

      • decisionId string | null

        Decided entries only. The decision record's id, for the undo route.

      • decidedByName string | null

        Decided entries only. Who decided it: their display name, or their email when that is empty or equal to it; null when unknown.

      • decidedByYou boolean

        Decided entries only. True when the person reading the Track decided it.

      • undoable boolean

        Decided entries only. True when the decision has a snapshot, so the undo route can put the change back (it may still refuse if the paragraph changed since).

    • hereId string | null

      Id of the first open entry, or null when nothing is open.

    • counts object
      Show 4 fields
      • open integer Required
      • in integer Required
      • back integer Required
      • total integer Required