POST
/
private
/
v2
/
align
/
Alignment Model
curl --request POST \
  --url https://api.{environment}.corti.app/v2/private/v2/align/ \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --header 'Tenant-Name: <tenant-name>' \
  --data '{
  "sourceDocument": "<string>",
  "targetDocument": "<string>",
  "compareSegments": false
}'
{
  "alignmentPercentage": 123,
  "alignedSegments": [
    {
      "targetSegment": {
        "text": "<string>",
        "range": [
          123
        ]
      },
      "sourceReference": [
        {
          "text": "<string>",
          "range": [
            123
          ]
        }
      ],
      "alignmentPercentage": 123
    }
  ]
}

Authorizations

Authorization
string
header
required

Input your token

Headers

Tenant-Name
string
required

Identifies a distinct entity within Corti's multi-tenant system. Ensures correct routing and authentication of the request.

Example:

"copiloteu"

Body

application/json
sourceDocument
string
required

The content of the source document.

targetDocument
string
required

The content of the target document.

compareSegments
boolean

Indicates if segments from the source should be compared with the target.

Example:

false

Response

Alignment results with percentage and optionally aligned segments.

alignmentPercentage
number

Alignment percentage between the source and target documents.

alignedSegments
object[]