Related articles
Authentication:
Insert authentication like this:
Where
Username is the Company Key
Password is the API Key
Send document to signing
Now let's create an endpoint which we can call "Send document to signing"
It should have the URL: https://onboarding.taktikal.is/api/management/signing
And the JSON should be like this:
{
"pdfDocument": "JVBERi0xLjQKJeLjz9MKMSAwIG9iago8PC9UeXBlL0NhdGFsb2cvUGFnZXMgMiAwIFI+PgplbmRvYmoKMiAwIG9iago8PC9UeXBlL1BhZ2VzL0tpZHNbMyAwIFJdL0NvdW50IDE+PgplbmRvYmoKMyAwIG9iago8PC9UeXBlL1BhZ2UvUGFyZW50IDIgMCBSL1Jlc291cmNlczw8L1Byb2NTZXQgWy9QREYgL1RleHRdL0ZvbnQgPDwvRjEgNCAwIFI+Pj4+L0NvbnRlbnRzIDUgMCBSPj4KZW5kb2JqCjQgMCBvYmoKPDwvVHlwZS9Gb250L1N1YnR5cGUvVHlwZTEvQmFzZUZvbnQvVGltZXMtUm9tYW4+PgplbmRvYmoKNSAwIG9iago8PC9MZW5ndGggNDg+PgpzdHJlYW0KQlQKL0YxIDE4IFRmCjAgVCAoSGVsbG8sIFdvcmxkISkgVGoKRVQKZW5kc3RyZWFtCmVuZG9iagp4cmVmCjAgNgoxMDAwMDAwMDAxIDY1NTM1IGYgCjAwMDAwMDAwMDAgMDAwMDAgbiAKMDAwMDAwMDAxMCAwMDAwMCBuIAowMDAwMDAwMDc5IDAwMDAwIG4gCjAwMDAwMDAxNTcgMDAwMDAgbiAKMDAwMDAwMDMzNSAwMDAwMCBuIAp0cmFpbGVyCjw8Ci9TaXplIDYKL0luZm8gMSAwIFIKL1Jvb3QgMSAwIFIKPj4Kc3RhcnR4cmVmCjQwNQolJUVPRgo=",
"pdfFileName": "example.pdf",
"flowKey": "yourflowkey",
"user": "useremail@demo.com",
"SignInOrder": false,
"RequiresAuth": false,
"SignatureLocation": "TopFirstPage",
"flattenDocument": false,
"reminderRule": "1:3",
"createSignees": [
{
"name": "James Smith",
"ssn": "1234561239",
"email": "james@demo.com",
"phoneNumber": "+3546661234",
"communicationDeliveryType": "email",
"SignatureType": "Qualified",
"Reason": "Undirritun",
"Language": "En"
}
]
}
But you need to replace:
yourflowkey --> you should get this from Taktikal
useremail@demo.com --> this should be an email of one of the users you have in Taktikal, the one who is "sending the document for signing" - they need to have a user on app.taktikal.is and then they can see the signature in their portal. The email template is also used from this user. This can also be empty if you don't want to use a specific Taktikal user.
James Smith --> Your name (or someone you want to test the signing with)
1234561239 --> Your SSN
james@demo.com --> Your email
+3546661234 --> Your phone number
Then press "save" and then "test" in (you can see them on the image here above)
You should then get a success response like this:
If this is successful you just need to change the type of pdfDocument to file and save:
Webhooks
We use webhooks to listen to when the document has been signed, here are more information about webhooks.
Create a new endpoint but now select "Webhook".
Leave "Subscrive using external url" as selected
JSON for Request value used to subscribe, using your own Flowkey
{
"Url": "",
"Type": "AllSigned",
"FlowKey": "yourflowkey"
}
JSON for Payload values the webhook returns
{
"Id": "3e9922f5fd7f4a9baa75a3fa90cb9caf",
"EventData": {
"Meta": {
"pdfUrl": "https://fill.dropandsign.is/api/flow/665a62b4a97a/pdf",
"pdfFieldData": "{\"Nafn\":\"Test User\",\"userInfo\":\"info\",\"ssn\":\"123456-7890\"}"
},
"FlowKey": "yourflowkey",
"Signees": [
{
"Key": "si7abef56540bd49f9a9b8a33969a9cf8c",
"Ssn": "1234567890",
"City": "Reykjavík",
"Name": "Test User",
"Email": "testUser@taktikal.com",
"Signed": true,
"Address": "Address 5",
"SignedAt": "yyyy-MM-ddTHH:mm:ss.fffffZ",
"ProcessKey": "sp231f52f87d6f4caaa2e29ecac92d055b",
"PhoneNumber": "1234567",
"CommunicationDeliveryType": "Email"
}
],
"FlowName": "Non-disclosure agreement",
"EventType": 2,
"CompanyKey": "fae93sfa4sh4",
"ProcessKey": "sp231f52f87d6f4caaa2e29ecac92d055b",
"SignedDocument": "JVBERi0xLjQ...",
"AttachmentReferences": [
{
"Id": "at3357",
"Url": "https://app.taktikal.is/attachment/sp231f52f87d6f4caaa2e29ecac92d055b/at3357/pep-Test User-64f-1.pdf",
"FileName": "pep-Test User-63f-1.pdf",
"SigneeKey": "si7abef56540bd49f9a9b8a33969a9cf8c",
"ProcessKey": "sp231f52f87d6f4caaa2e29ecac92d055b",
"ContentType": "application/pdf",
"Description": "PEP for Test User",
"ContentLength": 90570,
"AttachmentType": 20
}
],
"SignedDocumentDownloadUrl": "https://app.taktikal.is/sp231f52f87d6f4caaa2e29ecac92d055b/si7abef56540bd49f9a9b8a33969a9cf8c.pdf"
},
"EventSignature": {
"Guid": "2065b6c0-934f-4d18-81d3-46c29b913311",
"Signature": "5qN29xaZHKZ65PLMB6ajRgpcxUU9dFRAXhkw36C2d38=",
"TimeStamp": 637030223561542300,
"SignedData": "6370302235615422902065b6c0-934f-4d18-81d3-46c29b913311"
}
}
Click on "Add conditions" - you need to put in one condition, the Process key.
Press Save and the condition should look like this
In this webhook you also can get the signed file and use it so you do not need to have another enpoint to get the file.
Next steps are adding actions to your journey to send file to e-signing