Upload a custom gateway artifact
/apiplatform/administration/v1/artifacts
Uploads a custom gateway artifact.
Users requesting this resource must be assigned the Administrator role.
Note: only a single artifact with a given name/type/version can be created on the tenant. Multiple revisions of the same version not supported. If an artifact exists with the same name/type/version it will be replaced.
Request
- multipart/form-data
-
artifact: file
An artifact file.
-
json: string(json)
Metadata about the artifact file, in JSON format:
{"name": "testArtifact","type": "zip","version": "1","revision": "1"}
A description is optional.
Response
- application/json
200 Response
201 Response
403 Response
object
-
detail(optional):
string
Detailed error message
-
errorCode(optional):
string
Application specific error code
-
errorDetails(optional):
array errorDetails
additional errors
-
errorPath(optional):
string
-
instance(optional):
string
URI to the link that provides more detail about the error
-
status(optional):
string
HTTP status code
-
title:
string
Summary error message
-
type:
string
Error type
500 Response
object
-
detail(optional):
string
Detailed error message
-
errorCode(optional):
string
Application specific error code
-
errorDetails(optional):
array errorDetails
additional errors
-
errorPath(optional):
string
-
instance(optional):
string
URI to the link that provides more detail about the error
-
status(optional):
string
HTTP status code
-
title:
string
Summary error message
-
type:
string
Error type
Examples
The following example shows how to upload a custom artifact by submitting a POST request on the REST resource using cURL. For more information about cURL, see Use cURL.
curl -i -X POST -u apicsadmin:password -H "Content-Type:multipart/form-data" -F json=@artifact.json -F artifact=@newArtifact.zip https://example.com/apiplatform/administration/v1/artifacts
Example of Request Body
The following sample request body in JSON format (included with the request above in a file named artifact.json
) contains metadata about the artifact you are uploading.
{ "name": "newArtifact", "type": "zip", "version": "1", "revision": "1" }
Example of Response Headers
The following shows an example of the response headers.
HTTP/1.1 204 No Content Server: Oracle-Traffic-Director/12.2.1.0.0 Date: Mon, 02 Jan 2017 14:08:24 GMT Content-length: 386 Content-type: application/json X-oracle-dms-ecid: eD_kd0OmR00000000 X-oracle-dms-rid: 0:1 Via: 1.1 otd_opc Proxy-agent: Oracle-Traffic-Director/12.2.1.0.0