Get the files that are associated with the object
get/documents/{objectTypeName}/{objectId}/files
Gets the files that are associated with an object and returns them as a collection.
1{2 "links": [3 {4 "method": "GET",5 "rel": "self",6 "href": "/svi-datahub/documents/alerts/281eb4b9-c936-4918-a36a-7d2ae57fbee6/files?start=0&limit=10",7 "uri": "/svi-datahub/documents/alerts/281eb4b9-c936-4918-a36a-7d2ae57fbee6/files?start=0&limit=10",8 "type": "application/vnd.sas.collection",9 "itemType": "application/vnd.sas.datahub.file"10 },11 {12 "method": "GET",13 "rel": "collection",14 "href": "/svi-datahub/documents/alerts/281eb4b9-c936-4918-a36a-7d2ae57fbee6/files",15 "uri": "/svi-datahub/documents/alerts/281eb4b9-c936-4918-a36a-7d2ae57fbee6/files",16 "type": "application/vnd.sas.collection",17 "itemType": "application/vnd.sas.datahub.file"18 },19 {20 "method": "POST",21 "rel": "create",22 "href": "/svi-datahub/documents/alerts/281eb4b9-c936-4918-a36a-7d2ae57fbee6/files",23 "uri": "/svi-datahub/documents/alerts/281eb4b9-c936-4918-a36a-7d2ae57fbee6/files",24 "type": "application/vnd.sas.datahub.file",25 "responseType": "application/vnd.sas.datahub.file"26 }27 ],28 "name": "files",29 "accept": "application/vnd.sas.datahub.file",30 "start": 0,31 "count": 2,32 "items": [33 {34 "version": 1,35 "id": "237f217b-4911-4f5b-9e1a-bc36a6c06ab0",36 "name": "DocumentsPdf.pdf",37 "category": "Attachment",38 "location": "/svi-datahub/documents/alerts/281eb4b9-c936-4918-a36a-7d2ae57fbee6/files/237f217b-4911-4f5b-9e1a-bc36a6c06ab0",39 "type": "application/pdf",40 "size": 22159,41 "uploadedAt": "2022-05-31T12:23:14.493Z",42 "uploadedBy": "videmo",43 "links": [44 {45 "method": "GET",46 "rel": "self",47 "href": "/svi-datahub/documents/alerts/281eb4b9-c936-4918-a36a-7d2ae57fbee6/files/237f217b-4911-4f5b-9e1a-bc36a6c06ab0",48 "uri": "/svi-datahub/documents/alerts/281eb4b9-c936-4918-a36a-7d2ae57fbee6/files/237f217b-4911-4f5b-9e1a-bc36a6c06ab0",49 "type": "application/vnd.sas.datahub.file"50 },51 {52 "method": "GET",53 "rel": "content",54 "href": "/svi-datahub/documents/alerts/281eb4b9-c936-4918-a36a-7d2ae57fbee6/files/237f217b-4911-4f5b-9e1a-bc36a6c06ab0/content",55 "uri": "/svi-datahub/documents/alerts/281eb4b9-c936-4918-a36a-7d2ae57fbee6/files/237f217b-4911-4f5b-9e1a-bc36a6c06ab0/content",56 "type": "application/pdf"57 },58 {59 "method": "DELETE",60 "rel": "delete",61 "href": "/svi-datahub/documents/alerts/281eb4b9-c936-4918-a36a-7d2ae57fbee6/files/237f217b-4911-4f5b-9e1a-bc36a6c06ab0",62 "uri": "/svi-datahub/documents/alerts/281eb4b9-c936-4918-a36a-7d2ae57fbee6/files/237f217b-4911-4f5b-9e1a-bc36a6c06ab0"63 },64 {65 "method": "GET",66 "rel": "up",67 "href": "/svi-datahub/documents/alerts/281eb4b9-c936-4918-a36a-7d2ae57fbee6/files",68 "uri": "/svi-datahub/documents/alerts/281eb4b9-c936-4918-a36a-7d2ae57fbee6/files",69 "type": "application/vnd.sas.collection",70 "itemType": "application/vnd.sas.datahub.file"71 },72 {73 "method": "POST",74 "rel": "addFile",75 "href": "/svi-datahub/documents/alerts/281eb4b9-c936-4918-a36a-7d2ae57fbee6/files",76 "uri": "/svi-datahub/documents/alerts/281eb4b9-c936-4918-a36a-7d2ae57fbee6/files",77 "type": "application/vnd.sas.datahub.file",78 "responseType": "application/vnd.sas.datahub.file"79 }80 ]81 },82 {83 "version": 1,84 "id": "1ebb707a-9e54-47ec-a957-9b2bd64d62a0",85 "name": "super.txt",86 "category": "Attachment",87 "location": "/svi-datahub/documents/alerts/281eb4b9-c936-4918-a36a-7d2ae57fbee6/files/1ebb707a-9e54-47ec-a957-9b2bd64d62a0",88 "type": "text/plain",89 "size": 5,90 "uploadedAt": "2022-05-31T12:22:42.067Z",91 "uploadedBy": "videmo",92 "links": [93 {94 "method": "GET",95 "rel": "self",96 "href": "/svi-datahub/documents/alerts/281eb4b9-c936-4918-a36a-7d2ae57fbee6/files/1ebb707a-9e54-47ec-a957-9b2bd64d62a0",97 "uri": "/svi-datahub/documents/alerts/281eb4b9-c936-4918-a36a-7d2ae57fbee6/files/1ebb707a-9e54-47ec-a957-9b2bd64d62a0",98 "type": "application/vnd.sas.datahub.file"99 },100 {101 "method": "GET",102 "rel": "content",103 "href": "/svi-datahub/documents/alerts/281eb4b9-c936-4918-a36a-7d2ae57fbee6/files/1ebb707a-9e54-47ec-a957-9b2bd64d62a0/content",104 "uri": "/svi-datahub/documents/alerts/281eb4b9-c936-4918-a36a-7d2ae57fbee6/files/1ebb707a-9e54-47ec-a957-9b2bd64d62a0/content",105 "type": "text/plain"106 },107 {108 "method": "DELETE",109 "rel": "delete",110 "href": "/svi-datahub/documents/alerts/281eb4b9-c936-4918-a36a-7d2ae57fbee6/files/1ebb707a-9e54-47ec-a957-9b2bd64d62a0",111 "uri": "/svi-datahub/documents/alerts/281eb4b9-c936-4918-a36a-7d2ae57fbee6/files/1ebb707a-9e54-47ec-a957-9b2bd64d62a0"112 },113 {114 "method": "GET",115 "rel": "up",116 "href": "/svi-datahub/documents/alerts/281eb4b9-c936-4918-a36a-7d2ae57fbee6/files",117 "uri": "/svi-datahub/documents/alerts/281eb4b9-c936-4918-a36a-7d2ae57fbee6/files",118 "type": "application/vnd.sas.collection",119 "itemType": "application/vnd.sas.datahub.file"120 },121 {122 "method": "POST",123 "rel": "addFile",124 "href": "/svi-datahub/documents/alerts/281eb4b9-c936-4918-a36a-7d2ae57fbee6/files",125 "uri": "/svi-datahub/documents/alerts/281eb4b9-c936-4918-a36a-7d2ae57fbee6/files",126 "type": "application/vnd.sas.datahub.file",127 "responseType": "application/vnd.sas.datahub.file"128 }129 ]130 }131 ],132 "limit": 10,133 "version": 2134}
| Name | Type | Required | Description |
|---|---|---|---|
objectId | string | true | The ID of the object. |
objectTypeName | string | true | The name of the object type to which the object belongs. |
| Name | Type | Required | Description |
|---|---|---|---|
filter | string | false | The criteria by which to filter the files. |
limit | integer | false | The maximum number of files to return in this page of results. The actual number of returned items is fewer if the collection is exhausted. Default: 10 |
sortBy | string | false | The criteria by which to sort the files. |
start | integer | false | The starting index of the first file in the collection. Default: 0 |
| Status | Meaning | Description | ||
|---|---|---|---|---|
| 200 | OK | The request succeeded. A collection of metadata for the files that are associated associated with the object was returned. | Schema | |
| 400 | Bad Request | The start or limit parameter was invalid. | Schema | |
| 404 | Not Found | The object does not exist or the user does not have the correct permissions to view the object. | Schema |