POST {repositoryId}/Data/{id}/Attachment?fileName={fileName}
Adds an attachment to a Data resource.
The request body contains the attachment stream.
The content-type header must be "multipart/form-data".
Request Information
URI Parameters
Name | Description | Type | Additional information |
---|---|---|---|
repositoryId |
ID of the resource repository (optional). |
string |
Default value is |
id |
The ID of the Data resource. |
string |
Required |
fileName |
Optional file name, needed if the attachment stream is not a FileStream. |
string |
Default value is |
Body Parameters
None.
Response Information
Resource Description
"ResponseValue" = The attachment URL.
The "Location" Header in the HttpResponseMessage contains the new attachment URL.
Response Formats
application/json, text/json
Sample:
{ "sample string 1": "sample string 2", "sample string 3": "sample string 4" }
application/xml, text/xml
Sample:
<ArrayOfKeyValueOfstringstring xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.microsoft.com/2003/10/Serialization/Arrays"> <KeyValueOfstringstring> <Key>sample string 1</Key> <Value>sample string 2</Value> </KeyValueOfstringstring> <KeyValueOfstringstring> <Key>sample string 3</Key> <Value>sample string 4</Value> </KeyValueOfstringstring> </ArrayOfKeyValueOfstringstring>