The PadConnector assumes that requests over the web socket are JSON objects.
The requests contain a "messageId" field.
The requests contain a "type" field.
The requests may contain a "data" field whose structure varies for different message types.
Replies are JSON objects.
Replies may contain a "messageId" field.
Replies may contain a "data" field.
The messageId may be a field of the "data" field.
Lazy replies are replies that may be sent in the future.
Lazy replies contain a "type" field.
Lazy replies contain a "data" field that has a "messageId" field and a sequence of fields with keys "valueEl PadConnector asume que las peticiones a través del socket web son objetos JSON. .
Las peticiones contienen un campo "messageId".
Las peticiones contienen un campo "type".
Las peticiones pueden contener un campo "data" cuya estructura varía para los diferentes tipos de mensajes..
Las respuestas son objetos JSON.
Las respuestas pueden contener un campo "messageId"..
Las respuestas pueden contener un campo "data”.
El messageId puede ser un campo del campo "data”.
Las respuestas estáticas son respuestas que pueden enviarse en el futuro.
Las respuestas estáticas contienen un campo "type”.
Las respuestas estáticas contienen un campo «data» que tiene un campo «messageId» y una secuencia de campos con claves «value[0-9]+».".
...
Tipos
Table of Contents | ||||
---|---|---|---|---|
|
Requests, replies, lazy replies.
executeDeviceSearch
searches devices and selects one of them.
The reply contains "data" with "ret" with a one(1) in case of success.
finishSigning
ends a running signature capture in a similar way as the OK click on the device.
This should lead to a lazy "onStaticAppletSignatureFinished" reply.
getBioData
gets biodata.
The reply contains "data" that contains a "ret" field with the biodata as a base64-encoded sequence of naturaSignV2 records.
getButtonConfigs
gets the current button configuration of the signature pad. Since v2.2.0
...
|
getButtonEvents
observes the button clicks on the pad. Since v2.2.0
...
|
getDevice
gets the name of the selected device
The reply contains "data" with "ret" with the name.
getDeviceCertificate
gets a certificate which is necessary to verify the last signature.
The reply contains "data" with "ret" with a base64 encoded DER encoded X.509 certificate.
getDeviceCount
gets the number of attached signature devices
reply contains "data" with "ret" with the number of devices.
getDeviceInfo
gets information on the selected device.
...
|
getDeviceOpened
gets whether the device has been opened.
The reply contains "data" with "ret" with "true" or "false".
getDeviceSerial
Replies "data" that contains a "ret" with the device serial number
getEncryptedAesKey
gets a key that is necessary for decrypting the bioData captured during in the last signature process.
request
"data" contains a "darray" field which is a JSON array of numbers each being an octet of the preliminary document hash
reply
"data" that contains a "ret" field with the base64-encoded encrypted AES key
getNotaryInfo
Replies "data" that contains a "ret" with the notary info.
getPreliminaryData
gets preliminary data including the last signature image.
request
"data" that contains
"withAlpha", whether to use an alpha channel for transparency,
"width" the desired width of the image,
"height" the desired height of the image.
reply
contains "data" with "ret" which contains an array with these items
the bio data,
the certificate necessary to verify the signature as baset64 text,
the last signature image as base64 text,
the notary information as base64 text,
the device name,
the device serial number.
getSignatureImage
gets the signature image in one of two ways.
...
"withAlpha", whether to use an alpha channel for transparency, (true or false),
"width" the desired width,
"height" the desired height.
getSignedFinalDocHash
is obsolete.
getVersion
gets the version of the PadConnector.
The reply contains "data" with "ret" with the version.
keepAlive
Replies "data" that contains a "ret" with the text "ok".
onStaticAppletGetImage
is a lazy reply of
a startSigning or a
a startViewing request.
...
|
setButtonConfigs
sets the button configuation. Since v2.2.0.
...
|
setFinalDocHash
sets the final document hash to be signed.
request
"data" contains a "darray" field which is a JSON array of numbers each being an octet of the final document hash
reply
"data" contains a "ret" with the text "ok".
lazy reply
"type" is "onStaticAppletSignedFinalDocHash" contains "data" with "value0" field
that is a JSON array of numbers each being an octet of an RSA signature.
start
resets state and replies ok.
The lazy reply "onStaticAppletLoaded" is sent when the operation completed.
startSigning
starts a signing process.
request
"data" should contain
"page", the page of the signature field,
"x", "y", "width", "height", the position of the signature field in inch/72
where"y" is the upper border from top
"x" is the left border from left
"resolution" tells with how many dots per inch the page will be rendered
and sent as a reply to "onStaticAppletGetImage".
...
the "cryptoId" to use with the selected pad
"signatureImageIntervalMillis" to change the interval of the image stream,
"signMode" which can be
"inDoc"
"standard",
"afterSignMode" which can be
"noModeChange",
"documentViewing",
"customerLogo"
"textLines" that contains a sequence of key value pairs,
the keys being [0-9]+, the values being lines of text to be displayed on the pad;"buttonConfigs", since v2.2.0, an array of button configs, to change the buttons.
reply
"data" contains a "ret" with the text "ok".
Lazy replies
"onStaticAppletCaptureStarted", is sent when the signer starts to sign.
...
"onStaticAppletError" is sent in case of error. If the pad has been disconnected, it contains "data" with "value0" "DISCONNECT".
Remarks
With color pads, this uses the sign-in-document mode, if
...
If "config" was absent, the PC switches the pad to the customerLogo mode.
startViewing
starts a document viewing process. Supported devices can display document pages.
request
"data" may contain
"pages" with a number being the number of pages.
"buttonConfigs", since v2.2.0, an array of button configs, to change the buttons.
reply
"Ok".
lazy reply
"onStaticAppletGetImage" is sent when the PadConnector requires an image.
stopSigning
stops a signing process.
"data" may contain "showManufacturerLogo", a boolean that tells whether the pad should switch to manufacturer logo mode, also known as customer logo mode, also known as standby mode.