

Last date modified: July 07 2025
The Resource File API allows clients to manage resource files for the Relativity applications in their environment. It includes support for the following features:
Review the following guidelines for working with this service.
The URLs for REST endpoints contain path parameters that you need to set before making a call:
For example, you can use the following URL to retrieve a resource file:
1
<host>/relativity.rest/api/relativity-environment/{versionNumber}/workspaces/-1/resource-files/{resourceFileID}
Set the path parameters as follows:
To use the Resource File service, send requests by making calls with the required HTTP methods. See the following base URL for this service:
1
<host>/Relativity.REST/API/relativity-environment/{versionNumber}/workspaces/-1/resource-files/{applicationID}/
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
public async Task<ResourceFileResponse> ReadResourceFile(int resourceFileID)
{
ResourceFileResponse response = null;
using (HttpClient client = new HttpClient())
{
client.DefaultRequestHeaders.Add("X-CSRF-Header", string.Empty);
client.DefaultRequestHeaders.Add("Authorization", "Basic " + Convert.ToBase64String(Encoding.GetEncoding("ISO-8859-1").GetBytes("relativity.admin@kcura.com:Test1234!")));
client.DefaultRequestHeaders.Add("X-Kepler-Version", "2.0");
client.BaseAddress = new Uri("https://localhost/");
string url = $"/Relativity.REST/API/relativity-environment/v1/workspaces/-1/resource-files/{resourceFileArtifactId}/";
System.Net.Http.HttpResponseMessage httpResponse = await client.GetAsync(url);
httpResponse.EnsureSuccessStatusCode();
string content = await httpResponse.Content.ReadAsStringAsync();
response = JsonConvert.DeserializeObject<LibraryApplicationResponse>(content);
}
return response;
}
To create a resource file, send a POST request with a URL in the following format:
1
<host>/relativity.rest/api/relativity-environment/{versionNumber}/workspaces/-1/resource-files
1
2
3
4
5
6
7
8
{
"resourceFileRequest": {
"Application": {
"Guids":["3E86B18F-8B55-45C4-9A57-9E0CBD7BAF46"]
},
"FileName": "TestEventHandlerFailures.dll"
}
}
The newly created artifact ID of the resource file will be returned in the response.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
{
"ObjectIdentifier": {
"ArtifactID": 1669611,
"Guids": []
},
"Application": {
"Secured": false,
"Value": {
"Name": "Default",
"ArtifactID": 950,
"Guids": [
"3e86b18f-8b55-45c4-9a57-9e0cbd7baf46"
]
}
},
"FileName": "TestEventHandlerFailures.dll",
"AgentTypes": [],
"EventHandlers": [],
"MassOperations": [],
"Services": [],
"Keywords": "",
"Notes": "",
"CreatedOn": "2020-11-05T20:08:25.717",
"CreatedBy": {
"Name": "Admin, Relativity",
"ArtifactID": 9,
"Guids": []
},
"LastModifiedBy": {
"Name": "Admin, Relativity",
"ArtifactID": 9,
"Guids": []
},
"LastModifiedOn": "2020-11-05T20:08:25.717",
"Meta": {
"Unsupported": [],
"ReadOnly": [
"Name",
"Application"
]
},
"Actions": [
{
"Name": "Delete",
"Href": "relativity-environment/workspaces/-1/resource-files/1669611",
"Verb": "DELETE",
"IsAvailable": true,
"Reason": []
},
{
"Name": "Update",
"Href": "relativity-environment/workspaces/-1/resource-files/1669611",
"Verb": "PUT",
"IsAvailable": true,
"Reason": []
}
]
}
To read a resource sile, send a POST request with a URL in one of the following formats:
1
2
<host>/relativity.rest/api/relativity-environment/{versionNumber}/workspaces/-1/resource-files/{resourceFileID}
<host>/relativity.rest/api/relativity-environment/{versionNumber}/workspaces/-1/resource-files/{resourceFileID}/{includeMetadata}/{IncludeActions}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
{
"ObjectIdentifier": {
"ArtifactID": 1669611,
"Guids": []
},
"Application": {
"Secured": false,
"Value": {
"Name": "Default",
"ArtifactID": 950,
"Guids": [
"3e86b18f-8b55-45c4-9a57-9e0cbd7baf46"
]
}
},
"FileName": "TestEventHandlerFailures.dll",
"AgentTypes": [],
"EventHandlers": [],
"MassOperations": [],
"Services": [],
"Keywords": "",
"Notes": "",
"CreatedOn": "2020-11-05T20:08:25.717",
"CreatedBy": {
"Name": "Admin, Relativity",
"ArtifactID": 9,
"Guids": []
},
"LastModifiedBy": {
"Name": "Admin, Relativity",
"ArtifactID": 9,
"Guids": []
},
"LastModifiedOn": "2020-11-05T20:08:25.717",
"Actions": []
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
{
"ObjectIdentifier": {
"ArtifactID": 1669611,
"Guids": []
},
"Application": {
"Secured": false,
"Value": {
"Name": "Default",
"ArtifactID": 950,
"Guids": [
"3e86b18f-8b55-45c4-9a57-9e0cbd7baf46"
]
}
},
"FileName": "TestEventHandlerFailures.dll",
"AgentTypes": [],
"EventHandlers": [],
"MassOperations": [],
"Services": [],
"Keywords": "",
"Notes": "",
"CreatedOn": "2020-11-05T20:08:25.717",
"CreatedBy": {
"Name": "Admin, Relativity",
"ArtifactID": 9,
"Guids": []
},
"LastModifiedBy": {
"Name": "Admin, Relativity",
"ArtifactID": 9,
"Guids": []
},
"LastModifiedOn": "2020-11-05T20:08:25.717",
"Meta": {
"Unsupported": [],
"ReadOnly": [
"Name",
"Application"
]
},
"Actions": [
{
"Name": "Delete",
"Href": "relativity-environment/workspaces/-1/resource-files/1669611",
"Verb": "DELETE",
"IsAvailable": true,
"Reason": []
},
{
"Name": "Update",
"Href": "relativity-environment/workspaces/-1/resource-files/1669611",
"Verb": "PUT",
"IsAvailable": true,
"Reason": []
}
]
}
To read a resource sile, send a POST request with a URL in one of the following formats:
1
2
<host>/relativity.rest/api/relativity-environment/{versionNumber}/workspaces/-1/resource-files/{resourceFileID}
<host>/relativity.rest/api/relativity-environment/{versionNumber}/workspaces/-1/resource-files/{resourceFileID}/contents/{contentsKey}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
{
"ObjectIdentifier": {
"ArtifactID": 1669628,
"Guids": []
},
"Application": {
"Secured": false,
"Value": {
"Name": "Default",
"ArtifactID": 950,
"Guids": [
"3e86b18f-8b55-45c4-9a57-9e0cbd7baf46"
]
}
},
"FileName": "New1.txt",
"AgentTypes": [],
"EventHandlers": [],
"MassOperations": [],
"Services": [],
"Keywords": "update2",
"Notes": "update2",
"CreatedOn": "2020-11-06T14:14:24.603",
"CreatedBy": {
"Name": "Admin, Relativity",
"ArtifactID": 9,
"Guids": []
},
"LastModifiedBy": {
"Name": "Admin, Relativity",
"ArtifactID": 9,
"Guids": []
},
"LastModifiedOn": "2020-11-09T06:13:05.973",
"Meta": {
"Unsupported": [],
"ReadOnly": [
"Name",
"Application"
]
},
"Actions": [
{
"Name": "Delete",
"Href": "relativity-environment/workspaces/-1/resource-files/1669628",
"Verb": "DELETE",
"IsAvailable": true,
"Reason": []
},
{
"Name": "Update",
"Href": "relativity-environment/workspaces/-1/resource-files/1669628",
"Verb": "PUT",
"IsAvailable": true,
"Reason": []
}
]
}
1
2
3
4
5
6
7
8
9
10
{
"resourceFileRequest": {
"Application": {
"Guids":["3E86B18F-8B55-45C4-9A57-9E0CBD7BAF46"]
},
"FileName":"New1.txt",
"Notes":"update3",
"Keywords":"update3"
}
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
{
"ObjectIdentifier": {
"ArtifactID": 1669628,
"Guids": []
},
"Application": {
"Secured": false,
"Value": {
"Name": "Default",
"ArtifactID": 950,
"Guids": [
"3e86b18f-8b55-45c4-9a57-9e0cbd7baf46"
]
}
},
"FileName": "New1.txt",
"AgentTypes": [],
"EventHandlers": [],
"MassOperations": [],
"Services": [],
"Keywords": "update3",
"Notes": "update3",
"CreatedOn": "2020-11-06T14:14:24.603",
"CreatedBy": {
"Name": "Admin, Relativity",
"ArtifactID": 9,
"Guids": []
},
"LastModifiedBy": {
"Name": "Admin, Relativity",
"ArtifactID": 9,
"Guids": []
},
"LastModifiedOn": "2020-11-09T06:17:33.393",
"Meta": {
"Unsupported": [],
"ReadOnly": [
"Name",
"Application"
]
},
"Actions": [
{
"Name": "Delete",
"Href": "relativity-environment/workspaces/-1/resource-files/1669628",
"Verb": "DELETE",
"IsAvailable": true,
"Reason": []
},
{
"Name": "Update",
"Href": "relativity-environment/workspaces/-1/resource-files/1669628",
"Verb": "PUT",
"IsAvailable": true,
"Reason": []
}
]
}
To modify properties of a resource file using contents key(Guid).
1
2
3
4
5
6
7
8
9
10
{
"resourceFileRequest": {
"Application": {
"Guids":["3E86B18F-8B55-45C4-9A57-9E0CBD7BAF46"]
},
"FileName":"New1.txt",
"Notes":"update4",
"Keywords":"update4"
}
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
{
"ObjectIdentifier": {
"ArtifactID": 1669628,
"Guids": []
},
"Application": {
"Secured": false,
"Value": {
"Name": "Default",
"ArtifactID": 950,
"Guids": [
"3e86b18f-8b55-45c4-9a57-9e0cbd7baf46"
]
}
},
"FileName": "New1.txt",
"AgentTypes": [],
"EventHandlers": [],
"MassOperations": [],
"Services": [],
"Keywords": "update4",
"Notes": "update4",
"CreatedOn": "2020-11-06T14:14:24.603",
"CreatedBy": {
"Name": "Admin, Relativity",
"ArtifactID": 9,
"Guids": []
},
"LastModifiedBy": {
"Name": "Admin, Relativity",
"ArtifactID": 9,
"Guids": []
},
"LastModifiedOn": "2020-11-09T06:18:41.683",
"Meta": {
"Unsupported": [],
"ReadOnly": [
"Name",
"Application"
]
},
"Actions": [
{
"Name": "Delete",
"Href": "relativity-environment/workspaces/-1/resource-files/1669628",
"Verb": "DELETE",
"IsAvailable": true,
"Reason": []
},
{
"Name": "Update",
"Href": "relativity-environment/workspaces/-1/resource-files/1669628",
"Verb": "PUT",
"IsAvailable": true,
"Reason": []
}
]
}
To delete a resource file, send a DELETE request with a URL in the following format:
1
<host>/relativity.rest/api/relativity-environment/{versionNumber}/workspaces/-1/resource-files/{resourceFileID}
The body of this request should be empty.
The body of the response will also be empty. If the delete is successful it will just return a 200 status code.
To downloads the contents associated with a resource file, send a GET request with a URL in the following format:
1
<host>/relativity.rest/api/relativity-environment/{versionNumber}/workspaces/-1/resource-files/{resourceFileID}/contents/
The body of this request should be empty.
Depending from the file type the raw JSON response might not be human-readable.
To upload the contents associated with a resource file, send a POST request with a URL in the following format:
1
<host>/relativity.rest/api/relativity-environment/{versionNumber}/workspaces/-1/resource-files/contents/
1
2
3
{
"ContentsKey": "eed948ff-ef0b-4e7d-8ab5-c836e9918071"
}
To create or update a resource file, send a PATCH request with a URL in the following format:
1
<host>/relativity.rest/api/relativity-environment/{versionNumber}/workspaces/-1/resource-files/
1
2
3
4
5
6
{"applicationIdentifier":
{
"Guids":["3E86B18F-8B55-45C4-9A57-9E0CBD7BAF46"]
},
"fileName":"New.txt"
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
{
"ObjectIdentifier": {
"ArtifactID": 1669627,
"Guids": []
},
"Application": {
"Secured": false,
"Value": {
"Name": "Default",
"ArtifactID": 950,
"Guids": [
"3e86b18f-8b55-45c4-9a57-9e0cbd7baf46"
]
}
},
"FileName": "New.txt",
"AgentTypes": [],
"EventHandlers": [],
"MassOperations": [],
"Services": [],
"Keywords": "",
"Notes": "",
"CreatedOn": "2020-11-06T14:04:30.927",
"CreatedBy": {
"Name": "Admin, Relativity",
"ArtifactID": 9,
"Guids": []
},
"LastModifiedBy": {
"Name": "Admin, Relativity",
"ArtifactID": 9,
"Guids": []
},
"LastModifiedOn": "2020-11-06T14:04:30.927",
"Meta": {
"Unsupported": [],
"ReadOnly": [
"Name",
"Application"
]
},
"Actions": [
{
"Name": "Delete",
"Href": "relativity-environment/workspaces/-1/resource-files/1669627",
"Verb": "DELETE",
"IsAvailable": true,
"Reason": []
},
{
"Name": "Update",
"Href": "relativity-environment/workspaces/-1/resource-files/1669627",
"Verb": "PUT",
"IsAvailable": true,
"Reason": []
}
]
}
To retrieve a list of eligible applications, send a GET request with a URL in the following format:
1
<host>/Relativity.REST/api/relativity-environment/{versionNumber}/workspaces/-1/resource-files/eligible-applications
The body of this request should be empty.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
{
"HasSecuredItems": false,
"ViewableItems": [
{
"ObjectIdentifier": {
"Name": "Default",
"ArtifactID": 950,
"Guids": [
"3e86b18f-8b55-45c4-9a57-9e0cbd7baf46"
]
},
"IsGlobalApplication": false,
"Required": "Optional"
},
{
"ObjectIdentifier": {
"Name": "Imaging",
"ArtifactID": 1015285,
"Guids": [
"c9e4322e-6bd8-4a37-ae9e-c3c9be31776b"
]
},
"IsGlobalApplication": false,
"Version": "12.1.0.0",
"SchemaVersion": "11.2.199.24",
"FileName": "Relativity.Conversion.rap",
"Required": "Required"
},
{
"ObjectIdentifier": {
"Name": "Search Terms Report",
"ArtifactID": 1015286,
"Guids": [
"f807ac5a-6f0c-4ef3-9c7d-db2bae51a5f4"
]
},
"IsGlobalApplication": false,
"Version": "13.3.1.0",
"SchemaVersion": "12.0.9.13",
"FileName": "SearchTermsReport.rap",
"Required": "Required"
},
{
"ObjectIdentifier": {
"Name": "Analytics Core",
"ArtifactID": 1015510,
"Guids": [
"62284add-91f5-4f35-a582-bbcfa439ad8c"
]
},
"IsGlobalApplication": false,
"Version": "3003.1.0.3",
"SchemaVersion": "3000.4.0.9",
"FileName": "Analytics.Core.rap",
"Required": "Required"
},
{
"ObjectIdentifier": {
"Name": "OCR",
"ArtifactID": 1015511,
"Guids": [
"8354d537-689a-4dde-b057-5ef2fe4dba2b"
]
},
"IsGlobalApplication": false,
"Version": "100.0.0.19",
"SchemaVersion": "11.2.154.4",
"FileName": "Relativity.OCR.rap",
"Required": "RequiredIfPresent"
},
...
]
}
On this page
Why was this not helpful?
Check one that applies.
Thank you for your feedback.
Want to tell us more?
Great!
Additional Resources |
|||
DevHelp Community | GitHub | Release Notes | NuGet |