Skip to main content

Record REST

REST API · openapi/partner-api/openapi.yaml · 4 operations

Manage Records attached to signatures

Create or replace a Record​

PUT/signature/{signature_id}/record

PutSignatureRecord

Create or fully replace the Record attached to a signature.

This is a full-replace upsert: the stored Record becomes exactly the provided Record (last write wins, no field merging). It may be called for any signature registered by the partner, regardless of when the signature was registered.

A signature without a Record is treated as private.

Supports optimistic concurrency: pass the current ETag in an If-Match header to make the write conditional; a stale precondition returns 412 Precondition Failed.

Authentication
HTTP Bearer (JWT)
Source
openapi/partner-api/openapi.yaml

Parameters

Path parameters

  • signature_idSignatureIDrequired
    The SignatureID of the signature whose Record to manage

Header parameters

  • If-Matchstringoptional
    Optimistic-concurrency precondition (a strong validator). Set it to the ETag returned by a prior read or write of this Record — the signature's current revision, e.g. "5". When present, the write is applied only if the signature's revision still matches; a stale precondition is rejected with 412 Precondition Failed and nothing is modified. Omit for last-write-wins. A write to a revoked signature is rejected with 409 Conflict whether or not this header is sent.

Request body

required

The Record to store. Read-only fields are ignored.

application/jsonRecord
  • share_stateShareStaterequired
  • allowed_publish_urlsarray<string>optional
    URL patterns the browser-facing display URL of the media is allowed to match (only meaningful with the restricted share state).
  • allowed_source_urlsarray<string>optional
    URL patterns the storage/CDN address of the media bytes is allowed to match (only meaningful with the restricted share state).
  • allowed_fromstring (date-time)optional
    The media is not allowed to be available before this time (supports embargo dates)
  • allowed_tostring (date-time)optional
    The media is not allowed to be available after this time
  • bylinestringoptionalmaxLength 256
    Display text the publisher is expected to show alongside the media (e.g. photographer credit).
  • purchase_urlstringoptionalmaxLength 2048format uri
    URL where the media can be purchased or licensed.
  • licenseestringoptionalmaxLength 256
    Legal business name of the entity that has licensed the media asset. Aids enforcers when the licence agreement is not bound to a specific location.
  • asset_source_idstringoptionalmaxLength 256
    The creator's own upstream source ID for the asset: the creator's identifier for the media in their own system.
  • custom_fieldsmap<string, FieldValue>optional
    Custom fields, keyed by a creator-chosen name. Custom fields are display/metadata only: they never participate in distribution guidance evaluation, so they may be set under any share state. Each custom field is disclosed to other parties like any other Record field: to the creators the owner has granted it to, or to every looker once the owner marks it public. SASHA manages these settings on the creator's behalf.
  • created_atstring (date-time)optionalread-only
    The date and time the Record was first created
  • updated_atstring (date-time)optionalread-only
    The date and time the Record was last replaced

Responses

  • 204The Record was stored

    Headers

    • ETagstringoptional
      The signature's current revision as a strong validator, e.g. "5". Pass it back in an If-Match header on a later write to make that write conditional.
    • SASHA-Request-IDstringoptional
      The identifier of this request, set on every response. Quote it when contacting SASHA support: it is what joins your call to the server-side logs. On an error response the same value is repeated in the payload's request_id.

    No body.

  • 400The request was rejected. A validation failure lists every offending field in details; other failures carry message only.

    Headers

    • SASHA-Request-IDstringoptional
      The identifier of this request, set on every response. Quote it when contacting SASHA support: it is what joins your call to the server-side logs. On an error response the same value is repeated in the payload's request_id.
    application/jsonErrorResponse
  • 401An authorization error has occurred.

    Headers

    • SASHA-Request-IDstringoptional
      The identifier of this request, set on every response. Quote it when contacting SASHA support: it is what joins your call to the server-side logs. On an error response the same value is repeated in the payload's request_id.
    application/jsonUnauthorizedResponse
  • 403An authorization error has occurred.

    Headers

    • SASHA-Request-IDstringoptional
      The identifier of this request, set on every response. Quote it when contacting SASHA support: it is what joins your call to the server-side logs. On an error response the same value is repeated in the payload's request_id.
    application/jsonUnauthorizedResponse
  • 404The requested resource was not found.

    Headers

    • SASHA-Request-IDstringoptional
      The identifier of this request, set on every response. Quote it when contacting SASHA support: it is what joins your call to the server-side logs. On an error response the same value is repeated in the payload's request_id.
    application/jsonErrorResponse
  • 409The signature is revoked; its Record can no longer be modified.

    Headers

    • SASHA-Request-IDstringoptional
      The identifier of this request, set on every response. Quote it when contacting SASHA support: it is what joins your call to the server-side logs. On an error response the same value is repeated in the payload's request_id.
    application/jsonErrorResponse
  • 412The If-Match precondition did not match the signature's current revision; the Record was not modified. Re-read the Record and retry with the new ETag.

    Headers

    • SASHA-Request-IDstringoptional
      The identifier of this request, set on every response. Quote it when contacting SASHA support: it is what joins your call to the server-side logs. On an error response the same value is repeated in the payload's request_id.
    application/jsonErrorResponse
  • 413The request body is larger than the server accepts. A media file uploaded as multipart/form-data that is too large is answered with 400 instead.

    Headers

    • SASHA-Request-IDstringoptional
      The identifier of this request, set on every response. Quote it when contacting SASHA support: it is what joins your call to the server-side logs. On an error response the same value is repeated in the payload's request_id.
    application/jsonErrorResponse
  • 500An unexpected error occurred on the server.

    Headers

    • SASHA-Request-IDstringoptional
      The identifier of this request, set on every response. Quote it when contacting SASHA support: it is what joins your call to the server-side logs. On an error response the same value is repeated in the payload's request_id.
    application/jsonErrorResponse
  • 503The service is temporarily unable to handle the request. The request can be retried, preferably after a short wait.

    Headers

    • SASHA-Request-IDstringoptional
      The identifier of this request, set on every response. Quote it when contacting SASHA support: it is what joins your call to the server-side logs. On an error response the same value is repeated in the payload's request_id.
    application/jsonErrorResponse

Update Record fields​

PATCH/signature/{signature_id}/record

PatchSignatureRecord

Partially update the Record attached to a signature using JSON Merge Patch (RFC 7386).

Fields present in the patch replace the stored value (arrays and objects are replaced wholesale, not merged), fields set to null are cleared, and absent fields are left unchanged. The patch applies against the currently attached Record (or an empty one when none is attached), and the resulting Record must satisfy the same consistency rules as a full replace; a contradictory result is rejected and the stored Record is left unchanged.

Supports optimistic concurrency: pass the current ETag in an If-Match header to make the write conditional; a stale precondition returns 412 Precondition Failed.

Authentication
HTTP Bearer (JWT)
Source
openapi/partner-api/openapi.yaml

Parameters

Path parameters

  • signature_idSignatureIDrequired
    The SignatureID of the signature whose Record to manage

Header parameters

  • If-Matchstringoptional
    Optimistic-concurrency precondition (a strong validator). Set it to the ETag returned by a prior read or write of this Record — the signature's current revision, e.g. "5". When present, the write is applied only if the signature's revision still matches; a stale precondition is rejected with 412 Precondition Failed and nothing is modified. Omit for last-write-wins. A write to a revoked signature is rejected with 409 Conflict whether or not this header is sent.

Request body

required

The Record fields to change.

application/merge-patch+jsonRecordPatch
  • share_stateShareStateoptional
  • allowed_publish_urlsarray<string>optional
    URL patterns the browser-facing display URL of the media is allowed to match (only meaningful with the restricted share state).
  • allowed_source_urlsarray<string>optional
    URL patterns the storage/CDN address of the media bytes is allowed to match (only meaningful with the restricted share state).
  • allowed_fromstring (date-time)optional
    The media is not allowed to be available before this time (supports embargo dates)
  • allowed_tostring (date-time)optional
    The media is not allowed to be available after this time
  • bylinestringoptionalmaxLength 256
    Display text the publisher is expected to show alongside the media (e.g. photographer credit).
  • purchase_urlstringoptionalmaxLength 2048format uri
    URL where the media can be purchased or licensed.
  • licenseestringoptionalmaxLength 256
    Legal business name of the entity that has licensed the media asset. Aids enforcers when the licence agreement is not bound to a specific location.
  • asset_source_idstringoptionalmaxLength 256
    The creator's own upstream source ID for the asset: the creator's identifier for the media in their own system.
  • custom_fieldsmap<string, FieldValue>optional
    Custom fields, keyed by a creator-chosen name. Custom fields are display/metadata only: they never participate in distribution guidance evaluation, so they may be set under any share state. Each custom field is disclosed to other parties like any other Record field: to the creators the owner has granted it to, or to every looker once the owner marks it public. SASHA manages these settings on the creator's behalf.
  • created_atstring (date-time)optionalread-only
    The date and time the Record was first created
  • updated_atstring (date-time)optionalread-only
    The date and time the Record was last replaced

Responses

  • 204The Record was updated

    Headers

    • ETagstringoptional
      The signature's current revision as a strong validator, e.g. "5". Pass it back in an If-Match header on a later write to make that write conditional.
    • SASHA-Request-IDstringoptional
      The identifier of this request, set on every response. Quote it when contacting SASHA support: it is what joins your call to the server-side logs. On an error response the same value is repeated in the payload's request_id.

    No body.

  • 400The request was rejected. A validation failure lists every offending field in details; other failures carry message only.

    Headers

    • SASHA-Request-IDstringoptional
      The identifier of this request, set on every response. Quote it when contacting SASHA support: it is what joins your call to the server-side logs. On an error response the same value is repeated in the payload's request_id.
    application/jsonErrorResponse
  • 401An authorization error has occurred.

    Headers

    • SASHA-Request-IDstringoptional
      The identifier of this request, set on every response. Quote it when contacting SASHA support: it is what joins your call to the server-side logs. On an error response the same value is repeated in the payload's request_id.
    application/jsonUnauthorizedResponse
  • 403An authorization error has occurred.

    Headers

    • SASHA-Request-IDstringoptional
      The identifier of this request, set on every response. Quote it when contacting SASHA support: it is what joins your call to the server-side logs. On an error response the same value is repeated in the payload's request_id.
    application/jsonUnauthorizedResponse
  • 404The requested resource was not found.

    Headers

    • SASHA-Request-IDstringoptional
      The identifier of this request, set on every response. Quote it when contacting SASHA support: it is what joins your call to the server-side logs. On an error response the same value is repeated in the payload's request_id.
    application/jsonErrorResponse
  • 409The signature is revoked; its Record can no longer be modified.

    Headers

    • SASHA-Request-IDstringoptional
      The identifier of this request, set on every response. Quote it when contacting SASHA support: it is what joins your call to the server-side logs. On an error response the same value is repeated in the payload's request_id.
    application/jsonErrorResponse
  • 412The If-Match precondition did not match the signature's current revision; the Record was not modified. Re-read the Record and retry with the new ETag.

    Headers

    • SASHA-Request-IDstringoptional
      The identifier of this request, set on every response. Quote it when contacting SASHA support: it is what joins your call to the server-side logs. On an error response the same value is repeated in the payload's request_id.
    application/jsonErrorResponse
  • 413The request body is larger than the server accepts. A media file uploaded as multipart/form-data that is too large is answered with 400 instead.

    Headers

    • SASHA-Request-IDstringoptional
      The identifier of this request, set on every response. Quote it when contacting SASHA support: it is what joins your call to the server-side logs. On an error response the same value is repeated in the payload's request_id.
    application/jsonErrorResponse
  • 500An unexpected error occurred on the server.

    Headers

    • SASHA-Request-IDstringoptional
      The identifier of this request, set on every response. Quote it when contacting SASHA support: it is what joins your call to the server-side logs. On an error response the same value is repeated in the payload's request_id.
    application/jsonErrorResponse
  • 503The service is temporarily unable to handle the request. The request can be retried, preferably after a short wait.

    Headers

    • SASHA-Request-IDstringoptional
      The identifier of this request, set on every response. Quote it when contacting SASHA support: it is what joins your call to the server-side logs. On an error response the same value is repeated in the payload's request_id.
    application/jsonErrorResponse

Get a Record​

GET/signature/{signature_id}/record

GetSignatureRecord

Get the Record attached to a signature.

Only the partner that registered the signature can read its Record here. A lookup returns the full Record only to that same partner; any other partner receives at most the fields the owner has disclosed to it.

Authentication
HTTP Bearer (JWT)
Source
openapi/partner-api/openapi.yaml

Parameters

Path parameters

  • signature_idSignatureIDrequired
    The SignatureID of the signature whose Record to manage

Responses

  • 200Successful operation

    Headers

    • ETagstringoptional
      The signature's current revision as a strong validator, e.g. "5". Pass it back in an If-Match header on a later write to make that write conditional.
    • SASHA-Request-IDstringoptional
      The identifier of this request, set on every response. Quote it when contacting SASHA support: it is what joins your call to the server-side logs. On an error response the same value is repeated in the payload's request_id.
    application/jsonRecord
    • share_stateShareStaterequired
    • allowed_publish_urlsarray<string>optional
      URL patterns the browser-facing display URL of the media is allowed to match (only meaningful with the restricted share state).
    • allowed_source_urlsarray<string>optional
      URL patterns the storage/CDN address of the media bytes is allowed to match (only meaningful with the restricted share state).
    • allowed_fromstring (date-time)optional
      The media is not allowed to be available before this time (supports embargo dates)
    • allowed_tostring (date-time)optional
      The media is not allowed to be available after this time
    • bylinestringoptionalmaxLength 256
      Display text the publisher is expected to show alongside the media (e.g. photographer credit).
    • purchase_urlstringoptionalmaxLength 2048format uri
      URL where the media can be purchased or licensed.
    • licenseestringoptionalmaxLength 256
      Legal business name of the entity that has licensed the media asset. Aids enforcers when the licence agreement is not bound to a specific location.
    • asset_source_idstringoptionalmaxLength 256
      The creator's own upstream source ID for the asset: the creator's identifier for the media in their own system.
    • custom_fieldsmap<string, FieldValue>optional
      Custom fields, keyed by a creator-chosen name. Custom fields are display/metadata only: they never participate in distribution guidance evaluation, so they may be set under any share state. Each custom field is disclosed to other parties like any other Record field: to the creators the owner has granted it to, or to every looker once the owner marks it public. SASHA manages these settings on the creator's behalf.
    • created_atstring (date-time)optionalread-only
      The date and time the Record was first created
    • updated_atstring (date-time)optionalread-only
      The date and time the Record was last replaced
  • 400An error has occurred.

    Headers

    • SASHA-Request-IDstringoptional
      The identifier of this request, set on every response. Quote it when contacting SASHA support: it is what joins your call to the server-side logs. On an error response the same value is repeated in the payload's request_id.
    application/jsonErrorResponse
  • 401An authorization error has occurred.

    Headers

    • SASHA-Request-IDstringoptional
      The identifier of this request, set on every response. Quote it when contacting SASHA support: it is what joins your call to the server-side logs. On an error response the same value is repeated in the payload's request_id.
    application/jsonUnauthorizedResponse
  • 403An authorization error has occurred.

    Headers

    • SASHA-Request-IDstringoptional
      The identifier of this request, set on every response. Quote it when contacting SASHA support: it is what joins your call to the server-side logs. On an error response the same value is repeated in the payload's request_id.
    application/jsonUnauthorizedResponse
  • 404The requested resource was not found.

    Headers

    • SASHA-Request-IDstringoptional
      The identifier of this request, set on every response. Quote it when contacting SASHA support: it is what joins your call to the server-side logs. On an error response the same value is repeated in the payload's request_id.
    application/jsonErrorResponse
  • 500An unexpected error occurred on the server.

    Headers

    • SASHA-Request-IDstringoptional
      The identifier of this request, set on every response. Quote it when contacting SASHA support: it is what joins your call to the server-side logs. On an error response the same value is repeated in the payload's request_id.
    application/jsonErrorResponse
  • 503The service is temporarily unable to handle the request. The request can be retried, preferably after a short wait.

    Headers

    • SASHA-Request-IDstringoptional
      The identifier of this request, set on every response. Quote it when contacting SASHA support: it is what joins your call to the server-side logs. On an error response the same value is repeated in the payload's request_id.
    application/jsonErrorResponse

Delete a Record​

DELETE/signature/{signature_id}/record

DeleteSignatureRecord

Delete the Record attached to a signature.

Deleting a Record removes the attached metadata only; the signature itself remains valid and reverts to the default "no Record = private" interpretation.

Deleting is idempotent: deleting a signature's Record when none is attached succeeds.

Supports optimistic concurrency: pass the current ETag in an If-Match header to make the delete conditional; a stale precondition returns 412 Precondition Failed.

Authentication
HTTP Bearer (JWT)
Source
openapi/partner-api/openapi.yaml

Parameters

Path parameters

  • signature_idSignatureIDrequired
    The SignatureID of the signature whose Record to manage

Header parameters

  • If-Matchstringoptional
    Optimistic-concurrency precondition (a strong validator). Set it to the ETag returned by a prior read or write of this Record — the signature's current revision, e.g. "5". When present, the write is applied only if the signature's revision still matches; a stale precondition is rejected with 412 Precondition Failed and nothing is modified. Omit for last-write-wins. A write to a revoked signature is rejected with 409 Conflict whether or not this header is sent.

Responses

  • 204The Record was deleted (or no Record was attached)

    Headers

    • ETagstringoptional
      The signature's current revision as a strong validator, e.g. "5". Pass it back in an If-Match header on a later write to make that write conditional.
    • SASHA-Request-IDstringoptional
      The identifier of this request, set on every response. Quote it when contacting SASHA support: it is what joins your call to the server-side logs. On an error response the same value is repeated in the payload's request_id.

    No body.

  • 400An error has occurred.

    Headers

    • SASHA-Request-IDstringoptional
      The identifier of this request, set on every response. Quote it when contacting SASHA support: it is what joins your call to the server-side logs. On an error response the same value is repeated in the payload's request_id.
    application/jsonErrorResponse
  • 401An authorization error has occurred.

    Headers

    • SASHA-Request-IDstringoptional
      The identifier of this request, set on every response. Quote it when contacting SASHA support: it is what joins your call to the server-side logs. On an error response the same value is repeated in the payload's request_id.
    application/jsonUnauthorizedResponse
  • 403An authorization error has occurred.

    Headers

    • SASHA-Request-IDstringoptional
      The identifier of this request, set on every response. Quote it when contacting SASHA support: it is what joins your call to the server-side logs. On an error response the same value is repeated in the payload's request_id.
    application/jsonUnauthorizedResponse
  • 404The requested resource was not found.

    Headers

    • SASHA-Request-IDstringoptional
      The identifier of this request, set on every response. Quote it when contacting SASHA support: it is what joins your call to the server-side logs. On an error response the same value is repeated in the payload's request_id.
    application/jsonErrorResponse
  • 409The signature is revoked; its Record can no longer be modified.

    Headers

    • SASHA-Request-IDstringoptional
      The identifier of this request, set on every response. Quote it when contacting SASHA support: it is what joins your call to the server-side logs. On an error response the same value is repeated in the payload's request_id.
    application/jsonErrorResponse
  • 412The If-Match precondition did not match the signature's current revision; the Record was not modified. Re-read the Record and retry with the new ETag.

    Headers

    • SASHA-Request-IDstringoptional
      The identifier of this request, set on every response. Quote it when contacting SASHA support: it is what joins your call to the server-side logs. On an error response the same value is repeated in the payload's request_id.
    application/jsonErrorResponse
  • 500An unexpected error occurred on the server.

    Headers

    • SASHA-Request-IDstringoptional
      The identifier of this request, set on every response. Quote it when contacting SASHA support: it is what joins your call to the server-side logs. On an error response the same value is repeated in the payload's request_id.
    application/jsonErrorResponse
  • 503The service is temporarily unable to handle the request. The request can be retried, preferably after a short wait.

    Headers

    • SASHA-Request-IDstringoptional
      The identifier of this request, set on every response. Quote it when contacting SASHA support: it is what joins your call to the server-side logs. On an error response the same value is repeated in the payload's request_id.
    application/jsonErrorResponse