WeSignature
Lets you connects with WeSignature account and provide you a secret api key.
The generated api key can be used to access other features.
Request
curl POST https://app.wesignature.com/apihandler/login_api
-H 'Accept: application/json'
-H 'Content-Type: application/json'
-d '{
"email":"*****************",
"password": "*************"
}'
Response
{
"status":"authorized",
"message":"success",
"data":{
"user":"**************",
"api_key":"**************"
}
}
Lets user to send a document for signature on WeSignature interface.
Request
curl POST https://app.wesignature.com/apihandler/senddocumentapi
-H 'Accept: application/json'
-H 'Content-Type: application/json'
-d '{
"user_id":"*****************",
"api_key": "*************",
"sign_type": 3,
"file_list": [
{
"file_url": https://www.domain.com/demoimage.png"
}
],
"is_for_embedded_signing": 0,
"signers": [
{
"name": "Jack",
"email_address": "jack@demo-mail.com" OR "email_address": "XXXXXXXXXX"
},
{
"name": "Jill",
"email_address": "jill@demo-mail.com" OR "email_address": "XXXXXXXXXX"
}
],
"mail_data":{
"mail_subject":"Please Sign the document.",
"mail_message":"Kindly sign document immediately."
}
}'
Response
{
"status":"success",
"message":"Document Details",
"data":
{
"guid":"group-xxxxxxxxxxxxxxxxxxxxxxx",
"document_name":"demoimage.png",
"document_status":"draft",
"signature_type":"they-sign",
"signing_link":"********************",
"edit_link":"********************",
"delete_link":"********************",
"download_link":"********************",
"SignerMails":[[
{
"name":"Jack",
"email_address":"jack@demo-mail.com"
},
{
"name":"Jill",
"email_address":"jill@demo-mail.com"
}]]
}
}
Lets user to upload and send a document for signature on WeSignature interface.
Request
curl POST https://app.wesignature.com/apihandler/senddocumentapi_upload
-H 'Accept: application/json'
-H 'Content-Type: application/json'
-d '{
"user_id":"*****************",
"api_key": "*************",
"sign_type": 3,
"uploaddocument": [ Upload file post data OR "content":"Base64-encoded(file content)" with key "filename": "dummy.pdf"],
"is_for_embedded_signing": 0,
"signers": [
{
"name": "Jack",
"email_address": "jack@demo-mail.com" OR "email_address": "XXXXXXXXXX"
},
{
"name": "Jill",
"email_address": "jill@demo-mail.com" OR "email_address": "XXXXXXXXXX"
}
],
"mail_subject":"Please Sign the document.",
"mail_message":"Kindly sign document immediately."
}'
Response
{
"status":"success",
"message":"Document Details",
"data":
{
"guid":"group-xxxxxxxxxxxxxxxxxxxxxxx",
"document_name":"demoimage.png",
"document_status":"draft",
"signature_type":"they-sign",
"signing_link":"********************",
"edit_link":"********************",
"delete_link":"********************",
"download_link":"********************",
"SignerMails":[[
{
"name":"Jack",
"email_address":"jack@demo-mail.com"
},
{
"name":"Jill",
"email_address":"jill@demo-mail.com"
}]]
}
}
Api used to get the document list which are sent by a user for signatures.
Request
curl POST https://app.wesignature.com/apihandler/getsentdocumentsapi
-H 'Accept: */*'
-H "content-type: application/json; boundary=----WebKitFormBoundary7MA4YWxkTrZu0gW"
-d '{
"api_key": "*************",
"user_id": "*************",
"guid": "*************",
}'
Response
{
"status":"success",
"message":{
"data":[{
"guid":"group-xxxxxxxxxxxxxxxxxxxxxxx",
"document_name":"nameofdocumentimage.png",
"document_status":"draft",
"signature_type":"they-sign",
"signing_link":"********************",
"edit_link":"********************",
"delete_link":"********************",
"download_link":"********************",
"SignerMails":[{
"email":"signer1@email.com",
"signaturestatus":"0",
"name":"Signer1"
},
{
"email":"signer2@email.com",
"signaturestatus":"0",
"name":"Signer2"
},
{
"email":"signer3@email.com",
"signaturestatus":"0",
"name":"Signer3"
}]
}]
}
}
To get status of a sent document.
Request
curl GET https://app.wesignature.com/apihandler/documentstatusapi
-H 'Accept: */*'
-d '{
"api_key": "*************",
"user_id": "*************",
"guid": "*************"
}'
Response
{
"status":"success",
"message":"document data",
"data":
{
"signature_request_id":"********","request_type":"1","is_embedded":"1","document_status":"1","signature_type":"3","client_id":"*******","userid":"**",
"signer_data":
[
{
"signer_status":"1","signer_mail":"test12new@yopmail.com","signer_id":"******"
},
{
"signer_status":"3","signer_mail":"test1@yopmail.com","signer_id":"*****"
}
]
}
}
The document data is only generated when the document is send out for signature and the signer_id will generated only on an is_for_embedded_type 1 request to generate embedded frame for signing.
To get download_completed_doc after 48 hours when link goes to expired
Request
curl POST https://app.wesignature.com/apihandler/download_completed_doc
-H 'Accept: */*'
-d '{
"api_key": "*************",
"user_id": "*************",
"guid": "*************"
}'
Response
API did not return a response; the file was downloaded automatically.
The API is optional and can be used when a user receives a download_link from the https://app.wesignature.com/apihandler/getsentdocumentsapi response. This download_link, which allows document downloads, is valid for 48 hours. If you need to download the document after the 48-hour period, you must call this API again to obtain a new download_link. The API automatically facilitates the download of the file.
Application responds with these error codes, message and status in json format.
| #Error Code | Description |
|---|---|
| 500 | Internal server error. |
| 401 | Unauthorised. |
| 200 | Success in api's. |
| 400 | Parameters missing. |