Request:
mutation {
makeSecurityDocument(
input: {
name: "PPM",
extension: "pdf",
securityId: "5f30ff94-8bb7-490e-be24-8b935d786b93",
shareWith: []
})
{
uploadInfo
securityDocumentId
accountDocumentId
documentId
}
}
Response:
{
"data": {
"makeSecurityDocument": {
"uploadInfo": {
"url": "https://s3.amazonaws.com/documents.vertalo",
"fields": {
"key": "example/ed0b1825-b86c-4b0f-a2a0-2aff4eb18d34.pdf",
"Content-Type": "application/pdf",
"bucket": "documents.vertalo",
"X-Amz-Algorithm": "AWS4-HMAC-SHA256",
"X-Amz-Credential": "...2JXETTCGRODP/20220212/us-east-1/s3/aws4_request",
"X-Amz-Date": "20220212T164558Z",
"X-Amz-Security-Token": "IQoJb3JpZ2luX2VjEBQaCXVzLWVhc3QtMiJGME...p5kLZtLsrlro2vJQ==",
"Policy": "eyJleHBpcmF0aW9uIjoiMjAyMi0wMi0xMlQxNzo0NTo1OFoiLCJjb25...szZHJBVRPT0ifV19",
"X-Amz-Signature": "652018d81b2c8c48fc1585f3d1a...ed21e4aa2d24ac55cefdb8b0be2"
}
},
"securityDocumentId": "50846d44-537e-4e80-9ae9-1059b6d2195a",
"accountDocumentId": null,
"documentId": "ed0b1825-b86c-4b0f-a2a0-2aff4eb18d34"
}
}
}
Input parameters:
- name: file name
- extension: file extension without leading “.”
- id: security ID
- shareWith: array of role
[Note: If shareWith is an empty array, only the role responsible for the upload will have read-access to the file.]
The Vertalo platform requires that a signed URL (SURL) be generated for any file that is to be uploaded. (Vertalo uses Amazon S3 for file storage.) In this example, a SURL is being generated for a security document that corresponds to a specific security. Vertalo does not provide a file upload facility; you will have to program this yourself as appropriate for your development environment. See the example in this section.