Vault | Safe Endpoints

Vault | Safe Endpoints

🚧

Important

Don’t forget to include tokenAPI and cryptKey in your request.

Ex : https://secure.d4sign.com.br/api/v1/safes?tokenAPI=\{YOUR-TOKEN\}&cryptKey=\{YOUR-CRYPT-KEY\}

List all vaults | safes

GET /safes

Test Endpoint 🧪

This object will return ALL VAULTS in your account.

{
    "Content-Type": "application/json"
}
{
    "uuid-safe": "9f08bf18-bf4b-410f-9701-c286e5b1cad1",
    "name-safe": "Contracts"
},
{...}

List all documents in a vault | safe or folder

GET /documents/{UUID-SAFE}/safe

Test Endpoint 🧪

This object returns all documents associated with the specified vault and folder.

To filter by folder, use /documents/{UUID-SAFE}/safe/{UUID-FOLDER}

📘

The response returns 500 documents per page.
Use the pg parameter in the URL to paginate.

Example:
https://secure.d4sign.com.br/api/v1/documents?tokenAPI=\{YOUR-TOKEN}&cryptKey=\{crypt-key}&pg=2

The first block in the response will show the total number of available pages.

{
    "Content-Type": "application/json"
}
{
    "uuidDoc": "9f08bf18-bf4b-410f-9701-c286e5b1cad1",
    "nameDoc": "test.pdf",
    "type": "application/pdf",
    "size": "118990",
    "pages": "6",
    "uuidSafe": "06b3ddb1-abc9-4ab8-b944-0d7c940486af",
    "safeName": "Support",
    "statusId": "3",
    "statusName": "Waiting for Signatures",
    "statusComment": "Cancellation comment",
    "whoCanceled": "Email of the user who canceled the document"
}

Request Parameters

ParameterDescription
UUID-SAFE (required)UUID of the VAULT to be listed.
UUID-FOLDERUUID of the FOLDER (optional)

List folders in a vault | safe

GET /folders/{UUID-SAFE}/find

Test Endpoint 🧪\

This object returns ALL FOLDERS in the specified vault.

{
    "Content-Type": "application/json"
}
[{
    "uuid_safe": "9f08bf18-bf4b-410f-9701-c286e5b1cad1",
    "uuid_folder": "9f08bf18-bf4b-410f-9701-c286e5b1cad1",
    "name": "Contracts",
    "dt_cadastro": "2017-08-21 21:43:42"
},
{...}]

Request Parameters

ParameterDescription
UUID-SAFE (required)UUID of the VAULT to be listed

Create a folder or subfolder in a vault | safe

POST/folders/{UUID-SAFE}/create

Test Endpoint 🧪\

This method creates a folder inside the specified vault.

{
    "Content-Type": "application/json"
}
{
  "uuid_folder":"ffcf0410-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "folder_name": "Folder name"
}
{
    "message": "Folder created",
    "uuid": "{UUID-FOLDER}"
}
ParameterDescription
uuid_folder (optional)UUID (parent hierarchy) of the folder or subfolder to contain the new element.
folder_name (required)Name of the folder or subfolder

Rename a folder or subfolder in a vault | safe

POST/folders/{UUID-SAFE}/rename

Test Endpoint 🧪\

This method renames a folder inside the specified vault.

{
    "Content-Type": "application/json"
}
{
    "folder_name": " New Folder name",
    "uuid_folder": "{UUID-FOLDER}"
}
{
    "message": "Folder changed"
}
ParameterDescription
folder_name (required)Name of the folder or subfolder
uuid_folder (required)UUID of the folder or subfolder to be renamed

Create a batch

POST/batches

Testar endpoint 🧪\

This method creates a batch of documents.

{
    "Content-Type": "application/json"
}
{
    "keys": [
    	"0b2ec469-6b49-42bb-809f-d977279baeeb",
    	"db75a09b-6b30-48b9-b9f0-873351a050ed",
    	"42334730-5a93-48ae-b5e4-e8e82d62610a"
    	]
    
}
{
    "message": "Batches created",
    "uuid_batches": "lote_embed_232342asd-ss134asd-xASdwe",
    "total": "25"
}
ParameterDescription
keys (required)UUIDs of the documents to be included in the batch. Note: A maximum of 25 documents per batch.

Check account balance

GET/account/balance

Test Endpoint 🧪\

This method returns your account balance.

{
    "Content-Type": "application/json"
}

{
    "credit": "999",
    "sent": "372",
    "used_balance": "372/999"
}