Sign a PDF digest with the platform DID key
POST
/api/v1/protected/sign-pdf
const url = 'https://localhost:8080/api/v1/protected/sign-pdf';const options = { method: 'POST', headers: {Authorization: '<Authorization>', 'Content-Type': 'application/json'}, body: '{"dataHash":"b94d27b9934d3e08a52e52d7da7dabfac484efe37a5380ee9088f7ace2efcde9"}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://localhost:8080/api/v1/protected/sign-pdf \ --header 'Authorization: <Authorization>' \ --header 'Content-Type: application/json' \ --data '{ "dataHash": "b94d27b9934d3e08a52e52d7da7dabfac484efe37a5380ee9088f7ace2efcde9" }'Sign a 32-byte SHA-256 digest (hex-encoded) using the shared organization-key DID key
Authorizations
Section titled “Authorizations ”Request Body
Section titled “Request Body ”Hex encoded PDF SHA-256 hash to sign
Media type application/json
object
dataHash
required
string
Example
b94d27b9934d3e08a52e52d7da7dabfac484efe37a5380ee9088f7ace2efcde9Responses
Section titled “ Responses ”Signature created successfully
Media type application/json
object
certificate
string
signature
string
Example
{ "certificate": "-----BEGIN CERTIFICATE-----\nMIIB...\n-----END CERTIFICATE-----\n", "signature": "3045022100a1b2c3d4e5f6..."}Bad request - Invalid data
Media type application/json
object
error
string
error_description
string
Example
{ "error": "Unauthorized", "error_description": "Invalid token"}Unauthorized
Media type application/json
object
error
string
error_description
string
Example
{ "error": "Unauthorized", "error_description": "Invalid token"}Forbidden - requires Organization Owner or Project Owner role
Media type application/json
object
error
string
error_description
string
Example
{ "error": "Unauthorized", "error_description": "Invalid token"}Internal server error
Media type application/json
object
error
string
error_description
string
Example
{ "error": "Unauthorized", "error_description": "Invalid token"}