Document Ingestion API can be used to detect signatures in documents in two ways:

  1. Get the bounding boxes of detected signatures in the document.
  2. Get the context of the signatures detected in the document.

Getting Bounding Boxes of Signatures

Bounding boxes of signatures can be detected by setting detectSignature to true in the settings JSON object when calling the parse API.

{
    "settings": {
        "detectSignature": true
    }
}

Response

The bounding boxes of signatures are present in the Document object returned by the parse API. This is a JSON object which contains all the detected objects in the document such as tables, figures, charts, signatures, etc.

      "page_fragments": [
        {
          "bbox": {
            "x1": 97,
            "x2": 212,
            "y1": 621,
            "y2": 661
          },
          "content": {
            "content": "Signature detected"
          },
          "fragment_type": "signature",
          "reading_order": -1
        },
      ]

Getting Context of Signatures

Context of signatures can be detected by using the Structured Extraction API. You can specify a schema that captures the context, such as has the signature been signed by the signee, name of the personal signing, etc.

A sample schema for signature context is shown below:

{
  "type": "object",
  "properties": {
    "signatures": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "has_signed": {
            "type": "string",
            "description": "Has the signee signed the signature"
          },
          "name_signee": {
            "type": "string",
            "description": "Name of the signee"
          }
        }
      },
      "description": "Signatures detected in the page "
    }
  },
  "title": "signatures"
}