Tearleads

GET/documents/{documentId}/attribution

Get document edit attribution

Operation documents.attribution.get

Description

Returns which writer first uploaded each stretch of a document's history, derived from the signed write headers of its stored updates; it is not proof of authorship. Requires read access. Responses carry an ETag, so a client that sends If-None-Match gets 304 when nothing changed; long histories are truncated here and paged through the attribution ranges route.

Authentication

Requires a signed-in session: the client sends its session token as a bearer token in the Authorization header.

Parameters

NameInTypeDetails
documentIdpathstringrequired
accept-encodingheaderstringoptional
if-none-matchheaderstringoptional

Responses

200 OK

application/jsonDocumentEditAttributionResponse

Who first uploaded each part of a document, as compact runs derived from the signed write headers of its updates.

4 fields
  • attributionRevisionintegerrequired
    • at least 0

    Changes whenever new updates change the attribution.

  • documentIdstringrequired
    • not empty
  • truncatedbooleanoptional

    True when the run list hit the response limit; page the rest through the ranges route.

Other fields are allowed.

Response headers

NameTypeDetails
cache-controlstringrequired
  • always private, no-cache
content-encodingstringoptional
content-typestringrequired
  • not empty
etagstringrequired
  • not empty
varystringrequired
  • pattern (?:^|,)\s*(?:[Aa][Cc][Cc][Ee][Pp][Tt]-[Ee][Nn][Cc][Oo][Dd][Ii][Nn][Gg]|\*)\s*(?:,|$)

304 Not Modified

No body.

Response headers

NameTypeDetails
cache-controlstringrequired
  • always private, no-cache
etagstringrequired
  • not empty
varystringrequired
  • pattern (?:^|,)\s*(?:[Aa][Cc][Cc][Ee][Pp][Tt]-[Ee][Nn][Cc][Oo][Dd][Ii][Nn][Gg]|\*)\s*(?:,|$)

Other responses

StatusMeaningBody
400Bad Request

application/jsonErrorResponse

401Unauthorized

application/jsonSessionFailureResponse

403Forbidden

application/jsonErrorResponse

404Not Found

application/jsonErrorResponse

409Conflict

application/jsonErrorResponse

500Internal Server Error

application/jsonErrorResponse

503Service Unavailable

application/jsonErrorResponse

Additional rules

The server also enforces these rules, which the schema above cannot express.

  • Document attribution segment start counters are less than end counters.