Link Search Menu Expand Document (external link)

Generates a list of document signers

Table of contents
  1. Endpoint
  2. URL parameter description
  3. Request body parameter description
  4. Response body parameter description
    1. Successful response
    2. Failed response
  5. Sample request
  6. Sample response
    1. Sample success response
    2. Sample failed response
  7. Implementation
    1. CURL
    2. Using php-client

Short description

Endpoint

Path /api/document/{documentId}/signers.json
Method POST
Request Body Schema application/json

URL parameter description

Key Requirement Type Description
documentId Mandatory String Document UUID

Request body parameter description

Key Requirement Type Description
access_token Mandatory String API Access Token

Response body parameter description

Successful response

Key Type Description
status String Status of the request, ok in this case
signers Array of Objects Signers list

Failed response

Key Type Description
status String Status of the request, error in this case
message String Brief message about what is wrong

Sample request

POST /api/document/{documentId}/signers.json HTTP/1.1
Host: app.marksign.local
Content-Type: application/json

{
    "access_token": "d7aaXNN5wodRH3514RuhkMqYUTRnd4o07IYliG8fxQicLfldCBmbZXV5",
    "document_id": "8c1b611f-ddcb-11ec-a74f-84c5a60a22fb"
}

Sample response

Sample success response

{
    "status": "ok",
    "signers": [
        {
            "name": "KIRIL",
            "surname": "MATOVIČ",
            "isSignatureValid": "true",
            "signStatus": "signed",
            "rejectionReason": "reason"
        }
    ]
}

Sample failed response

{
    "status": "error",
    "message": "message text"
}

Implementation

CURL

curl --location --request POST 'https://app.marksign.local/api/document/{documentId}/signers.json
--header 'Content-Type: application/json' 
--data-raw '{
  "access_token": "d7aaXNN5wodRH3514RuhkMqYUTRnd4o07IYliG8fxQicLfldCBmbZXV5",
  "document_id": "8c1b611f-ddcb-11ec-a74f-84c5a60a22fb"
}'

Using php-client

To use the php-client, please follow the installation and basic usage here, and use AppBundle\GatewaySDKPhp\RequestBuilder\IframeGeneratesDocumentSignersListRequestBuilder as request builder.

/**
 * The document uuid that was found from "Document upload" request.
 * The following is a dummy to use as example.
 */

$signersListReq = (new IframeGeneratesDocumentSignersListRequestBuilder)
  ->withDocumentId('8c1b611f-ddcb-11ec-a74f-84c5a60a22fb')
  ->createRequest();
$signersListRes = $client->postRequest($signersListReq);
$signersListResArray = $signersListRes->toArray();
var_dump($signersListResArray);