API documentation for LegalOn services
LegalOn API (1.1.0)
- The server URL is `{api_base_url}/rest/v1`.
You can construct the server URL using the value of `api_base_url` provided in the response when obtaining an access token.
https://{api_base_url_without_scheme}/rest/v1/contracts/{document_id}/versions/{document_version_id}
- cURL
- JavaScript
- Python
- Java
- Go
curl -i -X DELETE \
'https://{api_base_url_without_scheme}/rest/v1/contracts/{document_id}/versions/{document_version_id}' \
-H 'Authorization: Bearer <YOUR_TOKEN_HERE>'Upload other file request payload
Other file name. Supported extensions are .pdf, .doc, .docx, .xls, .xlsx, .csv, .ppt, .pptx, .eml, .msg, .png, .gif, .jpg, and .jpeg.
Other file MIME type. Supported MIME types are application/pdf, application/msword, application/vnd.openxmlformats-officedocument.wordprocessingml.document, application/vnd.ms-excel, application/vnd.openxmlformats-officedocument.spreadsheetml.sheet, text/csv, application/vnd.ms-powerpoint, application/vnd.openxmlformats-officedocument.presentationml.presentation, message/rfc822, application/vnd.ms-outlook, image/png, image/gif, and image/jpeg.
- The server URL is `{api_base_url}/rest/v1`.
You can construct the server URL using the value of `api_base_url` provided in the response when obtaining an access token.
https://{api_base_url_without_scheme}/rest/v1/contracts/other-files
- cURL
- JavaScript
- Python
- Java
- Go
curl -i -X POST \
'https://{api_base_url_without_scheme}/rest/v1/contracts/other-files' \
-H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
-H 'Content-Type: multipart/form-data' \
-F workspace_id=00000023-0000-0000-0001-000000000020 \
-F file_name=appendix.xlsx \
-F mime_type=application/vnd.openxmlformats-officedocument.spreadsheetml.sheet \
-F 'file=<binary file content>'{ "workspace_id": "00000023-0000-0000-0001-000000000020", "other_file_id": "00000016-0000-0000-0001-100000000201", "file_name": "appendix.xlsx", "mime_type": "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet" }
Workspaces
Workspaces/folders are the common units used to store and organize resources such as contracts. This endpoint returns the workspaces/folders the calling user has access to, as a tree. For operations that target a workspace (e.g., the Contract API), specify the workspace_id obtained here. To manage workspaces across the tenant (creation, permissions, etc.), see the admin workspace operations (/spaces).