Assets API
Provides operations on OMN assets and related asset information.
Chunked upload. Start
| /dam/assets/bin/chunked/start Initializes a chunk upload session for the file |
Chunk upload workflow consist of 3 general steps:
Resource path |
/api/core/v1/dam/assets/bin/chunked/start |
HTTP method |
POST |
Request content type |
application/json |
Response content type |
|
Return Type
OmnType with filled ResponsesType
Response type contains upload tid - the unique identity of the upload session. Upload tid is required for next upload steps.
Responses
| Code | Message | Datatype |
|---|---|---|
200 |
OmnType with filled ResponsesType |
|
400 |
Invalid input provided |
|
500 |
An unknown internal error occurred |
Samples
| Please use transform endpoint to get the JSON/compact-JSON samples from the XML one. |
Start upload session
curl --location --request POST 'https://<OMN_SERVER>/api/core/v1/dam/assets/bin/chunked/start' \
--header 'Authorization: Bearer <TOKEN>' \
--header 'Content-Type: application/json' \
--data-raw '{
"path":"/MAM/demo/file2.jpg",
"tid": "AAAAA-AAAAA-AAAAAA-AAAAAA",
}'
{
"tid":"0AA31C0C-F2AE-422C-9C6A-25BAB368706E",
"path": "/MAM/demo/filename.jpg"
}
<?xml version="1.0" encoding="UTF-8"?>
<pim xmlns="http://www.apollon.de/omn">
<responses>
<response tid="9f9417cc-031b-4bf4-ae98-e1df1fc93fef">
<status>SUCCESS</status>
<description>Chunk upload could be started by upload UUID/tid</description>
</response>
</responses>
</pim>
Error responses
<?xml version="1.0" encoding="UTF-8"?>
<response xmlns="http://www.apollon.de/omn">
<details>
<itm key="supportId">f21311c9-a868-4d4e-bc48-adaa96436335</itm>
</details>
<issues>
<itm key="code">1000</itm>
<itm key="description">An unknown internal error occurred</itm>
<itms type="details">
<itm key="errorMessage">File already exists by path: '/demo/file.jpg'</itm>
</itms>
</issues>
<status>ERROR</status>
</response>
<?xml version="1.0" encoding="UTF-8"?>
<response xmlns="http://www.apollon.de/omn">
<details>
<itm key="supportId">f21311c9-a868-4d4e-bc48-adaa96436335</itm>
</details>
<issues>
<itm key="code">1000</itm>
<itm key="description">An unknown internal error occurred</itm>
<itms type="details">
<itm key="errorMessage">File already exists by path: '/demo/file.jpg'</itm>
</itms>
</issues>
<status>ERROR</status>
</response>
<?xml version="1.0" encoding="UTF-8"?>
<response xmlns="http://www.apollon.de/omn">
<details>
<itm key="supportId">9fdfc6ce-6999-4f3b-8513-be5c431974ee</itm>
</details>
<issues>
<itm key="code">1000</itm>
<itm key="description">An unknown internal error occurred</itm>
<itms type="details">
<itm key="errorMessage">No permissions to upload by path: /demo/file.jpg</itm>
</itms>
</issues>
<status>ERROR</status>
</response>
<?xml version="1.0" encoding="UTF-8"?>
<response xmlns="http://www.apollon.de/omn">
<details>
<itm key="supportId">9fdfc6ce-6999-4f3b-8513-be5c431974ee</itm>
</details>
<issues>
<itm key="code">1000</itm>
<itm key="description">An unknown internal error occurred</itm>
<itms type="details">
<itm key="errorMessage">No target directory by path: '[demo]' in rnc: 'MAM'</itm>
</itms>
</issues>
<status>ERROR</status>
</response>
Chunked upload. Upload a chunk
| /dam/assets/bin/chunked/upload/{uploadTid} Upload a specified chunk of an asset. |
| Upload session must be started before a chunk upload. |
Resource path |
|
HTTP method |
POST |
Request content type |
multipart/form-data |
Response content type |
|
Path Parameters
| Name | Description | Required | Default | Pattern |
|---|---|---|---|---|
uploadTid |
The session identifier of the started chunked upload. |
X |
Form Parameters
| Name | Description | Required | Default | Pattern |
|---|---|---|---|---|
chunkId |
Identity of an asset chunk which should be uploaded integer |
X |
Int32. Positive numbers starting from 0. |
|
payload |
Blob file |
X |
Responses
| Code | Message | Datatype |
|---|---|---|
200 |
PimType with filled ResponsesType |
|
500 |
An unknown internal error occurred |
Samples
| Please use transform endpoint to get the JSON/compact-JSON samples from the XML one. |
Upload a chunk
curl --location --request POST 'https://<OMN_SERVER>/api/core/v1/dam/assets/bin/chunked/upload/9f9417cc-031b-4bf4-ae98-e1df1fc93fef' \
--header 'Authorization: Bearer <TOKEN>' \
--form 'payload=@"<PATH_TO_FILE>500x500.jpg"' \
--form 'chunkId="0";type=application/json'
<?xml version="1.0" encoding="UTF-8"?>
<pim xmlns="http://www.apollon.de/omn">
<responses>
<response action="create" id="0" tid="c15af96a-4ce2-4d05-8965-e375c00daf1b">
<status>SUCCESS</status>
<description>Chunk has been uploaded</description>
</response>
</responses>
</pim>
Chunked upload. Finish
| /dam/assets/bin/chunked/persist/{uploadTid} Finalize the chunking upload of an asset. |
| Some chunks should be uploaded before notifying the server that API consumer uploaded all chunks. |
Resource path |
|
HTTP method |
PUT |
Request content type |
application/json |
Response content type |
|
Path Parameters
| Name | Description | Required | Default | Pattern |
|---|---|---|---|---|
uploadTid |
The session identifier of the started chunked upload. |
X |
Body parameters
Specified by AssetUploadRequest.
The AssetUploadRequest's path and tid parameters should be the same as was sent for /dam/assets/bin/chunked/start
| path is required and should contain the file name. |
Return Type
PimType with filled ResponsesType
Response type contains status and info about asset that were uploaded to the system.
Responses
| Code | Message | Datatype |
|---|---|---|
200 |
PimType with filled ResponsesType |
|
400 |
Invalid input provided |
|
500 |
An unknown internal error occurred |
Samples
| Please use transform endpoint to get the JSON/compact-JSON samples from the XML one. |
Finalize upload session
curl --location --request POST 'https://<OMN_SERVER>/api/core/v1/dam/assets/bin/chunked/persist/c9fd0ff5-69e6-4053-b895-887be66ccfd9' \
--header 'Authorization: Bearer <TOKEN>' \
--header 'Content-Type: application/json' \
--data-raw '{
"path":"/MAM/demo/file2.jpg",
"tid": "AAAAA-AAAAA-AAAAAA-AAAAAA",
"doPreviewsAsync": true,
"doOverwrite": true
}'
{
"tid":"0AA31C0C-F2AE-422C-9C6A-25BAB368706E",
"path": "/MAM/demo/filename.jpg",
"doPreviewsAsync": true,
"doOverwrite": true
}
<?xml version="1.0" encoding="UTF-8"?>
<pim xmlns="http://www.apollon.de/omn">
<responses>
<response action="create"
dataType="asset"
id="75440"
path="/demo/file.jpg"
tid="1296BDF9-E367-492C-ACB8-59FA7C310CE8">
<status>SUCCESS</status>
<description>The asset has been uploaded</description>
</response>
</responses>
</pim>
Error responses
It is possible, that during chunks upload, the another file with the same name and path or tid was uploaded to the system, target or the target directory is not available.
<?xml version="1.0" encoding="UTF-8"?>
<response xmlns="http://www.apollon.de/omn">
<details>
<itm key="supportId">f21311c9-a868-4d4e-bc48-adaa96436335</itm>
</details>
<issues>
<itm key="code">1000</itm>
<itm key="description">An unknown internal error occurred</itm>
<itms type="details">
<itm key="errorMessage">File already exists by path: '/demo/file.jpg'</itm>
</itms>
</issues>
<status>ERROR</status>
</response>
<?xml version="1.0" encoding="UTF-8"?>
<response xmlns="http://www.apollon.de/omn">
<details>
<itm key="supportId">f21311c9-a868-4d4e-bc48-adaa96436335</itm>
</details>
<issues>
<itm key="code">1000</itm>
<itm key="description">An unknown internal error occurred</itm>
<itms type="details">
<itm key="errorMessage">File already exists by path: '/demo/file.jpg'</itm>
</itms>
</issues>
<status>ERROR</status>
</response>
<?xml version="1.0" encoding="UTF-8"?>
<response xmlns="http://www.apollon.de/omn">
<details>
<itm key="supportId">9fdfc6ce-6999-4f3b-8513-be5c431974ee</itm>
</details>
<issues>
<itm key="code">1000</itm>
<itm key="description">An unknown internal error occurred</itm>
<itms type="details">
<itm key="errorMessage">No permissions to upload by path: /demo/file.jpg</itm>
</itms>
</issues>
<status>ERROR</status>
</response>
<?xml version="1.0" encoding="UTF-8"?>
<response xmlns="http://www.apollon.de/omn">
<details>
<itm key="supportId">9fdfc6ce-6999-4f3b-8513-be5c431974ee</itm>
</details>
<issues>
<itm key="code">1000</itm>
<itm key="description">An unknown internal error occurred</itm>
<itms type="details">
<itm key="errorMessage">No target directory by path: '[demo]' in rnc: 'MAM'</itm>
</itms>
</issues>
<status>ERROR</status>
</response>
Retrieve Binary Assets
| /dam/assets/bin/retrieve Retrieves binary data of asset(s). |
Resource path |
/api/core/v1/dam/assets/bin/retrieve |
HTTP method |
POST |
Request content type |
application/json |
Response content type |
application/octet-stream |
Body parameters
Specified by AssetRequest
-
tids - (List of String) - Filter parameter, asset TIDs (Metatag GUID), identifying unique objects
-
ids - (List of Integer) - Filter parameter, asset IDs, identifying unique objects
-
formats - (List of String) - Filter parameter, asset formats, identifying preview format or asset.
Return Type
Binary data. In case when multiple assets and / or multiple formats are requested, then files will be compressed into the zip. The zip file should be of the following structure: One directory per tid/id. In this directory the file name of the asset + the format prefix (+ file-suffix) should be used as file name.
Responses
| Code | Message | Datatype |
|---|---|---|
200 |
OmnType with list of keywords |
|
400 |
Invalid input provided |
|
404 |
The requested resource could not be found |
|
500 |
An unknown internal error occurred |
Samples
curl --location --request POST 'http://<OMN_SERVER>/api/core/v1/dam/assets/bin/retrieve' \
--header 'content-type: application/json' \
--header 'Authorization: Bearer <TOKEN> ' \
--data-raw <REQUEST_BODY>
Initial data: 2 files
1st file:
-
name: apollon_logo.jpg
-
identity: 1331131
-
tid: 05954601-9289-49A7-8652-BE74A7DB0E06
2nd file:
-
name: apollon_bg.png
-
identity: 22738178
-
tid: 7CD062AE-B69E-47D5-8422-8840E4A22E88
1. Retrieve asset by id
{
"ids": [1331131]
}
apollon_logo_original.png
2. Retrieve single asset by tid
{
"tids": ["7CD062AE-B69E-47D5-8422-8840E4A22E88"]
}
apollon_bg_original.png
3. Retrieve multiple assets by tids/ids:
{
"ids": [1331131, 22738178]
}
or
{
"tids": ["7CD062AE-B69E-47D5-8422-8840E4A22E88", "05954601-9289-49A7-8652-BE74A7DB0E06"]
}
result.zip
|----- 7CD062AE-B69E-47D5-8422-8840E4A22E88
| |---- apollon_logo_original.jpg
|
|----- 05954601-9289-49A7-8652-BE74A7DB0E06
|---- apollon_bg_original.png
4. Retrieve single asset’s single preview
{
"ids": [1331131],
"formats": ["previewThumbnail"]
}
apollon_logo_previewThumbnail.png
5. Retrieve single asset’s multiple previews:
{
"ids": [1331131],
"formats": ["previewThumbnail", "previewOriginal"]
}
result.zip
|----- 7CD062AE-B69E-47D5-8422-8840E4A22E88
|---- apollon_logo_previewThumbnail.jpg
|---- apollon_logo_previewOriginal.jpg
6. Retrieve multiple asset’s multiple previews:
{
"tids": ["7CD062AE-B69E-47D5-8422-8840E4A22E88", "05954601-9289-49A7-8652-BE74A7DB0E06"],
"formats": ["previewThumbnail", "previewOriginal"]
}
result.zip
|----- 7CD062AE-B69E-47D5-8422-8840E4A22E88
| |---- apollon_logo_previewThumbnail.jpg
| |---- apollon_logo_previewOriginal.jpg
|
|----- 05954601-9289-49A7-8652-BE74A7DB0E06
|---- apollon_bg_previewThumbnail.jpg
|---- apollon_bg_previewOriginal.jpg
Asset upload
| /dam/assets/bin/persist Upload asset to the system. |
Semantic is the same as in chunked asset upload. Within this endpoint it’s possible to upload file per one request without splitting to chunks.
Resource path |
|
HTTP method |
POST |
Request content type |
multipart/form-data |
Response content type |
|
Form Parameters
| AssetUploadRequest.path should be provided to the OMN known directory. |
| Name | Description | Required | Default | Pattern |
|---|---|---|---|---|
params |
Upload parameters AssetUploadRequest |
X |
||
payload |
Blob file |
X |
Return Type
PimType with filled ResponsesType
Response type contains status and info about upload asset operation.
Responses
| Code | Message | Datatype |
|---|---|---|
200 |
PimType with filled ResponsesType |
|
400 |
Invalid input |
|
409 |
File already exists |
|
500 |
An unknown internal error occurred |
Samples
| Please use transform endpoint to get the JSON/compact-JSON samples from the XML one. |
Upload a file
curl --location --request POST 'https://<OMN_SERVER>/api/core/v1/dam/assets/bin/persist' \
--header 'Authorization: Bearer <TOKEN>' \
--form 'payload=@"/<FILE_PATH>/artworks-bQbImNIL55TZ52he-gAKJ7w-t500x500.jpg"' \
--form 'params="{
\"path\":\"/MAM/demo/\",
\"tid\": \"AAAAA-AAAAA-AAAAAA-AAAAAA\",
\"doPreviewsAsync\": true,
\"doOverwrite\": true
}";type=application/json''
{
"path":"/MAM/demo/",
"tid": "AAAAA-AAAAA-AAAAAA-AAAAAA",
"doPreviewsAsync": true,
"doOverwrite": true
}
<?xml version="1.0" encoding="UTF-8"?>
<pim xmlns="http://www.apollon.de/omn">
<responses>
<response action="create"
dataType="asset"
id="86670"
path="/MAM/demo/file.jpg"
tid="AAAAA-AAAAA-AAAAAA-AAAAAA">
<status>SUCCESS</status>
<description>The asset has been uploaded</description>
</response>
</responses>
</pim>
Error response
<?xml version="1.0" encoding="UTF-8"?>
<response xmlns="http://www.apollon.de/omn">
<details>
<itm key="supportId">9fdfc6ce-6999-4f3b-8513-be5c431974ee</itm>
</details>
<issues>
<itm key="code">1000</itm>
<itm key="description">An unknown internal error occurred</itm>
<itms type="details">
<itm key="errorMessage">No permissions to upload by path: /demo/file.jpg</itm>
</itms>
</issues>
<status>ERROR</status>
</response>
<?xml version="1.0" encoding="UTF-8"?>
<response xmlns="http://www.apollon.de/omn">
<details>
<itm key="supportId">d2540d63-e9b5-4647-b875-bcb0c9dfabe5</itm>
</details>
<issues>
<itm key="code">1003</itm>
<itm key="description">The resource already exists</itm>
<itms type="details">
<itm key="errorMessage">File already exists by path: '/demo/file.jpg'</itm>
</itms>
</issues>
<status>ERROR</status>
</response>
Retrieve assets previews info
| /dam/assets/previews/retrieve Retrieve assets previews information. |
Resource path |
/api/core/v1/dam/assets/previews/retrieve |
HTTP method |
POST |
Request content type |
application/json |
Response content type |
|
Body parameters
Specified by PreviewInfoRequest
Return Type
OmnType with filled AssetsType. More info AssetType
Responses
| Code | Message | Datatype |
|---|---|---|
200 |
OmnType with assets preview info in AssetType |
|
500 |
Error in ResponseType |
Samples
| Please use transform endpoint to get the JSON/compact-JSON samples from the XML one. |
Get previews info
curl --location --request POST 'https://<OMN_SERVER>/api/core/v1/dam/assets/previews/retrieve' \
--header 'Authorization: Bearer <TOKEN>' \
--header 'Content-Type: application/json' \
--data-raw '{
"tids":[
"11319367-DE26-4FB8-9148-3C341766C1BA"
],
"formats": [
"original",
"previewOriginal",
"previewCoarse",
"previewThumbnail",
"previewCustom",
"previewOriginalPixel",
"previewOriginalVector",
"previewOriginalMultimedia"
]
}'
Request body:
{
"ids": [
74628354
],
"formats": [
"original",
"previewOriginal",
"previewCoarse",
"previewThumbnail",
"previewCustom",
"previewOriginalPixel",
"previewOriginalVector",
"previewOriginalMultimedia"
]
}
{
"tids": [
"11319367-DE26-4FB8-9148-3C341766C1BA"
],
"formats": [
"original",
"previewOriginal",
"previewCoarse",
"previewThumbnail",
"previewCustom",
"previewOriginalPixel",
"previewOriginalVector",
"previewOriginalMultimedia"
]
}
{
"paths": [
"/MAM/rootDirectory/childDirectory1/pic.jpeg"
],
"formats": [
"original",
"previewOriginal",
"previewCoarse",
"previewThumbnail",
"previewCustom",
"previewOriginalPixel",
"previewOriginalVector",
"previewOriginalMultimedia"
]
}
<?xml version="1.0" encoding="UTF-8"?>
<pim xmlns="http://www.apollon.de/omn" schemaVersion="5.6.0">
<meta>
<itm key="messageType">request</itm>
<itm key="messageTime">2022-09-19T09:46:46.471Z</itm>
<itm key="sourceEnv">web</itm>
</meta>
<assets>
<asset tid="11319367-DE26-4FB8-9148-3C341766C1BA">
<name>artworks-bQbImNIL55TZ52he-gAKJ7w-t500x500_print_variation_print_variation.jpg</name>
<meta>
<itm key="identity">87961</itm>
<itm key="pathStringStr">/demo/artworks-bQbImNIL55TZ52he-gAKJ7w-t500x500_print_variation_print_variation.jpg</itm>
</meta>
<previews>
<preview tid="E5B04787-87BD-4D18-AAA6-6CD26498EB0A" type="ORIGINAL_PIXEL">
<meta>
<itm key="extension">jpeg</itm>
<itm key="height">230</itm>
<itm key="modificationDate">2022-09-08T13:11:29.802Z</itm>
<itm key="pageNumber">-1</itm>
<itm key="size">0</itm>
<itm key="status">ORIGINAL</itm>
<itm key="url">/dam/assets/bin?assetTid=11319367-DE26-4FB8-9148-3C341766C1BA&format=previewOriginalPixel</itm>
<itm key="width">219</itm>
</meta>
</preview>
<preview tid="0B0A042E-6F51-44C2-8CE7-5F13E4719FCF" type="THUMBNAIL">
<meta>
<itm key="extension">jpeg</itm>
<itm key="height">40</itm>
<itm key="modificationDate">2022-09-08T13:11:29.802Z</itm>
<itm key="pageNumber">-1</itm>
<itm key="size">0</itm>
<itm key="status">ORIGINAL</itm>
<itm key="url">/dam/assets/bin?assetTid=11319367-DE26-4FB8-9148-3C341766C1BA&format=previewThumbnail</itm>
<itm key="width">38</itm>
</meta>
</preview>
<preview tid="11F00126-6D35-4355-99C3-2763A9743C00" type="COARSE">
<meta>
<itm key="extension">jpeg</itm>
<itm key="height">480</itm>
<itm key="modificationDate">2022-09-08T13:11:29.802Z</itm>
<itm key="pageNumber">-1</itm>
<itm key="size">0</itm>
<itm key="status">ORIGINAL</itm>
<itm key="url">/dam/assets/bin?assetTid=11319367-DE26-4FB8-9148-3C341766C1BA&format=previewCoarse</itm>
<itm key="width">457</itm>
</meta>
</preview>
</previews>
</asset>
</assets>
</pim>
Perform actions on assets
| /dam/assets/perform Perform different types of actions on DAM assets |
Available action types:
-
Delete
-
Move
-
Copy
-
Checkin (unlock)
-
Checkout (lock)
-
Clean checkout (force unlock)
Resource path |
/api/core/v1/dam/assets/perform |
HTTP method |
POST |
Request content type |
|
Response content type |
|
Body parameters
PimType with ActionTypes
API consumer should provide one of asset identifiers (usually tid) to perform action/s on the asset.
Some actions require additional info that should be provided in MetaType in key/value way.
ActionType's type is required and be provided.
Possible values:
-
delete
-
checkout
-
checkin
-
cleanCheckout
-
unlink
-
move
-
copy
ActionType's dataType is - asset
|
Tables legend
"As <action> attribute" describes, that parameter is in the xml attribute of <action> tag. Otherwise, parameter should be in ItemType. "Required groups" - one of parameter in the one group is required e.g. entity identifier (e.g. tid or id or path) |
| Parameter Name | As <action> attribute | Required | Type | Description | Format |
|---|---|---|---|---|---|
tid |
X |
X |
string |
Tid of the asset that should be deleted |
| Parameter Name | As <action> attribute | Required | Type | Description | Format |
|---|---|---|---|---|---|
tid |
X |
X G1 |
string |
Tid of the asset that should be moved |
|
id |
X |
X G1 |
Long |
Asset identity |
int64 |
path |
X |
X G1 |
string |
Path to the asset. Starts from RNC name. |
/ (forward slash) - as separator. RNC identifier - as root entry. |
destinationDirTid |
X G2 |
string |
Destination directory Tid |
||
destinationDirId |
X G2 |
Long |
Destination directory Id |
int64 |
|
destinationDirPath |
X G2 |
string |
Path to the destination directory. Starts from RNC name. |
/ (forward slash) - as separator. RNC identifier - as root entry. |
|
overwrite |
boolean |
Overwrite file if exists |
true/false |
| Parameter Name | As <action> attribute | Required | Type | Description | Format |
|---|---|---|---|---|---|
tid |
X |
X |
string |
Tid of the asset that should checked-in/checked-out or cleaned from checkout |
Return Type
PimType with filled ResponsesType
Response types contains status information about each action passed to perform.
Responses
| Actions are processed separately. ResponseType for individual action need to checked. Exceptions thrown during the execution of actions will be reported in ResponseType. |
| Code | Message | Datatype |
|---|---|---|
200 |
PimType with filled ResponsesType. |
|
400 |
Invalid input provided |
|
500 |
An unknown internal error occurred |
Samples
| Please use transform endpoint to get the JSON/compact-JSON samples from the XML one. |
Delete
Delete asset by tid
curl
curl --location --request POST 'https://<OMN_SERVER>/api/core/v1/dam/assets/perform' \
--header 'Authorization: Bearer <TOKEN>' \
--header 'Content-Type: application/json' \
--data-raw '<?xml version="1.0" encoding="UTF-8"?>
<pim xmlns="http://www.apollon.de/omn" schemaVersion="5.6.0">
<actions>
<action dataType="asset" tid="37590039-3AEA-4A13-9C3A-C6EC3C94ADCE" type="delete"/>
</actions>
</pim>'
<?xml version="1.0" encoding="UTF-8"?>
<pim xmlns="http://www.apollon.de/omn" schemaVersion="5.6.0">
<actions>
<action dataType="asset" tid="37590039-3AEA-4A13-9C3A-C6EC3C94ADCE" type="delete"/>
</actions>
</pim>
<?xml version="1.0" encoding="UTF-8"?>
<pim xmlns="http://www.apollon.de/omn" schemaVersion="5.6.0">
<meta>
<itm key="messageType">request</itm>
<itm key="messageTime">2022-06-04T13:24:53.286Z</itm>
<itm key="sourceEnv">web</itm>
</meta>
<responses>
<response dataType="asset"
tid="37590039-3AEA-4A13-9C3A-C6EC3C94ADCE"
action="delete">
<status>SUCCESS</status>
<description>The asset has been deleted successfully</description>
</response>
</responses>
</pim>
Error response case
<?xml version="1.0" encoding="UTF-8"?>
<pim xmlns="http://www.apollon.de/omn" schemaVersion="5.6.0">
<meta>
<itm key="messageType">request</itm>
<itm key="messageTime">2022-06-04T13:36:54.983Z</itm>
<itm key="sourceEnv">web</itm>
</meta>
<responses>
<response dataType="asset"
tid="37590039-3AEA-4A13-9C3A-C6EC3C94ADCE2"
action="delete">
<status>ERROR</status>
<description>There is no asset with the given tid</description>
</response>
</responses>
</pim>
Move
Move asset by tid/id/path
curl
curl --location --request POST 'https://<OMN_SERVER>/api/core/v1/dam/assets/perform' \
--header 'Authorization: Bearer <TOKEN>' \
--header 'Content-Type: application/xml; charset=UTF8' \
--data-raw '<?xml version="1.0" encoding="UTF-8"?>
<pim xmlns="http://www.apollon.de/omn" schemaVersion="5.6.0">
<actions>
<action dataType="asset" tid="52F78637-63AE-4F3E-8D4B-664E070C6AA1" type="move">
<meta>
<itm key="destinationDirTid">52F78637-63AE-4F3E-8D4B-664E070C6AB8</itm>
<itm key="overwrite">false</itm>
</meta>
</action>
</actions>
</pim>'
Move request body examples:
<?xml version="1.0" encoding="UTF-8"?>
<pim xmlns="http://www.apollon.de/omn" schemaVersion="5.6.0">
<actions>
<action dataType="asset" tid="52F78637-63AE-4F3E-8D4B-664E070C6AA1" type="move">
<meta>
<itm key="destinationDirTid">52F78637-63AE-4F3E-8D4B-664E070C6AB8</itm>
<itm key="overwrite">false</itm>
</meta>
</action>
</actions>
</pim>
<?xml version="1.0" encoding="UTF-8"?>
<pim xmlns="http://www.apollon.de/omn" schemaVersion="5.6.0">
<actions>
<action dataType="asset" id="74638" type="move">
<meta>
<itm key="destinationDirId">55273453</itm>
<itm key="overwrite">false</itm>
</meta>
</action>
</actions>
</pim>
<?xml version="1.0" encoding="UTF-8"?>
<pim xmlns="http://www.apollon.de/omn" schemaVersion="5.6.0">
<actions>
<action dataType="asset" path="/MAM/demo/photo.jpg" type="move">
<meta>
<itm key="destinationDirPath">/MAM/demo/copies/</itm>
<itm key="overwrite">false</itm>
</meta>
</action>
</actions>
</pim>
<?xml version="1.0" encoding="UTF-8"?>
<pim xmlns="http://www.apollon.de/omn" schemaVersion="5.6.0">
<meta>
<itm key="messageType">request</itm>
<itm key="messageTime">2022-08-17T10:53:35.841Z</itm>
<itm key="sourceEnv">web</itm>
</meta>
<responses>
<response dataType="asset"
tid="52F78637-63AE-4F3E-8D4B-664E070C6AA1"
id="74638"
action="move"
path="/MAM/demo/copies/photo.jpg">
<status>SUCCESS</status>
<description>asset has been moved</description>
<details>
<itm key="monitorId">77833</itm>
</details>
</response>
</responses>
</pim>
Error responses
<?xml version="1.0" encoding="UTF-8"?>
<pim xmlns="http://www.apollon.de/omn" schemaVersion="5.6.0">
<meta>
<itm key="messageType">request</itm>
<itm key="messageTime">2022-08-17T10:54:05.989Z</itm>
<itm key="sourceEnv">web</itm>
</meta>
<responses>
<response dataType="asset" action="move" path="/MAM/demo/copies/photo2.jpg">
<status>ERROR</status>
<description>The asset does not exist</description>
</response>
</responses>
</pim>
<?xml version="1.0" encoding="UTF-8"?>
<pim xmlns="http://www.apollon.de/omn" schemaVersion="5.6.0">
<meta>
<itm key="messageType">request</itm>
<itm key="messageTime">2022-08-17T10:54:31.036Z</itm>
<itm key="sourceEnv">web</itm>
</meta>
<responses>
<response dataType="asset" action="move" path="/MAM/demo/photo.jpg">
<status>ERROR</status>
<description>The destination does not exist</description>
</response>
</responses>
</pim>
<?xml version="1.0" encoding="UTF-8"?>
<pim xmlns="http://www.apollon.de/omn" schemaVersion="5.6.0">
<meta>
<itm key="messageType">request</itm>
<itm key="messageTime">2022-08-17T11:06:29.771Z</itm>
<itm key="sourceEnv">web</itm>
</meta>
<responses>
<response dataType="asset"
tid="9EC194D7-07B6-48A1-BDD3-19C729492F7E"
id="76890"
action="move"
path="/MAM/demo/copies/tempAR/photo.jpg">
<status>ERROR</status>
<description>Error during moving: No access to source objects</description>
</response>
</responses>
</pim>
<?xml version="1.0" encoding="UTF-8"?>
<pim xmlns="http://www.apollon.de/omn" schemaVersion="5.6.0">
<meta>
<itm key="messageType">request</itm>
<itm key="messageTime">2022-08-17T10:54:57.295Z</itm>
<itm key="sourceEnv">web</itm>
</meta>
<responses>
<response dataType="asset"
tid="0F837828-AE84-431A-BC79-65B967C6400D"
id="73442"
action="move"
path="/MAM/demo/photo.jpg">
<status>ERROR</status>
<description>Error during moving: No access to destination object '/demo/copies/tempAR'</description>
</response>
</responses>
</pim>
<?xml version="1.0" encoding="UTF-8"?>
<pim xmlns="http://www.apollon.de/omn" schemaVersion="5.6.0">
<meta>
<itm key="messageType">request</itm>
<itm key="messageTime">2022-08-17T11:07:26.533Z</itm>
<itm key="sourceEnv">web</itm>
</meta>
<responses>
<response dataType="asset"
tid="E40ACAEB-963C-4D06-B3ED-7C01B3E51C37"
id="77971"
action="move"
path="/MAM/demo/photo.jpg">
<status>ERROR</status>
<description>Collision during move. Collision asset name:'photo.jpg'</description>
<details>
<itm key="collision">true</itm>
<itm key="monitorId">77835</itm>
</details>
</response>
</responses>
</pim>
Copy
Copy asset by tid/id/path
curl
curl --location --request POST 'https://<OMN_SERVER>/api/core/v1/dam/assets/perform' \
--header 'Authorization: Bearer <TOKEN>' \
--header 'Content-Type: application/xml; charset=UTF8' \
--data-raw '<?xml version="1.0" encoding="UTF-8"?>
<pim xmlns="http://www.apollon.de/omn" schemaVersion="5.6.0">
<actions>
<action dataType="asset" tid="52F78637-63AE-4F3E-8D4B-664E070C6AA1" type="copy">
<meta>
<itm key="destinationDirTid">52F78637-63AE-4F3E-8D4B-664E070C6AB8</itm>
<itm key="overwrite">false</itm>
</meta>
</action>
</actions>
</pim>'
Copy request body examples:
<?xml version="1.0" encoding="UTF-8"?>
<pim xmlns="http://www.apollon.de/omn" schemaVersion="5.6.0">
<actions>
<action dataType="asset" tid="52F78637-63AE-4F3E-8D4B-664E070C6AA1" type="copy">
<meta>
<itm key="destinationDirTid">52F78637-63AE-4F3E-8D4B-664E070C6AB8</itm>
<itm key="overwrite">false</itm>
</meta>
</action>
</actions>
</pim>
<?xml version="1.0" encoding="UTF-8"?>
<pim xmlns="http://www.apollon.de/omn" schemaVersion="5.6.0">
<actions>
<action dataType="asset" id="74638" type="copy">
<meta>
<itm key="destinationDirId">55273453</itm>
<itm key="overwrite">false</itm>
</meta>
</action>
</actions>
</pim>
<?xml version="1.0" encoding="UTF-8"?>
<pim xmlns="http://www.apollon.de/omn" schemaVersion="5.6.0">
<actions>
<action dataType="asset" path="/MAM/demo/photo.jpg" type="copy">
<meta>
<itm key="destinationDirPath">/MAM/demo/copies/</itm>
<itm key="overwrite">false</itm>
</meta>
</action>
</actions>
</pim>
<?xml version="1.0" encoding="UTF-8"?>
<pim xmlns="http://www.apollon.de/omn" schemaVersion="5.6.0">
<meta>
<itm key="messageType">request</itm>
<itm key="messageTime">2022-08-17T10:53:35.841Z</itm>
<itm key="sourceEnv">web</itm>
</meta>
<responses>
<response dataType="asset"
tid="52F78637-63AE-4F3E-8D4B-664E070C6AA1"
id="74638"
action="copy"
path="/MAM/demo/copies/photo.jpg">
<status>SUCCESS</status>
<description>asset has been copied</description>
<details>
<itm key="monitorId">77833</itm>
</details>
</response>
</responses>
</pim>
Error responses
<?xml version="1.0" encoding="UTF-8"?>
<pim xmlns="http://www.apollon.de/omn" schemaVersion="5.6.0">
<meta>
<itm key="messageType">request</itm>
<itm key="messageTime">2022-08-17T10:54:05.989Z</itm>
<itm key="sourceEnv">web</itm>
</meta>
<responses>
<response dataType="asset" action="copy" path="/MAM/demo/copies/photo2.jpg">
<status>ERROR</status>
<description>The asset does not exist</description>
</response>
</responses>
</pim>
<?xml version="1.0" encoding="UTF-8"?>
<pim xmlns="http://www.apollon.de/omn" schemaVersion="5.6.0">
<meta>
<itm key="messageType">request</itm>
<itm key="messageTime">2022-08-17T10:54:31.036Z</itm>
<itm key="sourceEnv">web</itm>
</meta>
<responses>
<response dataType="asset" action="copy" path="/MAM/demo/photo.jpg">
<status>ERROR</status>
<description>The destination does not exist</description>
</response>
</responses>
</pim>
<?xml version="1.0" encoding="UTF-8"?>
<pim xmlns="http://www.apollon.de/omn" schemaVersion="5.6.0">
<meta>
<itm key="messageType">request</itm>
<itm key="messageTime">2022-08-17T11:06:29.771Z</itm>
<itm key="sourceEnv">web</itm>
</meta>
<responses>
<response dataType="asset"
tid="9EC194D7-07B6-48A1-BDD3-19C729492F7E"
id="76890"
action="copy"
path="/MAM/demo/copies/tempAR/photo.jpg">
<status>ERROR</status>
<description>Error during moving: No access to source objects</description>
</response>
</responses>
</pim>
<?xml version="1.0" encoding="UTF-8"?>
<pim xmlns="http://www.apollon.de/omn" schemaVersion="5.6.0">
<meta>
<itm key="messageType">request</itm>
<itm key="messageTime">2022-08-17T10:54:57.295Z</itm>
<itm key="sourceEnv">web</itm>
</meta>
<responses>
<response dataType="asset"
tid="0F837828-AE84-431A-BC79-65B967C6400D"
id="73442"
action="copy"
path="/MAM/demo/photo.jpg">
<status>ERROR</status>
<description>Error during moving: No access to destination object '/demo/copies/tempAR'</description>
</response>
</responses>
</pim>
<?xml version="1.0" encoding="UTF-8"?>
<pim xmlns="http://www.apollon.de/omn" schemaVersion="5.6.0">
<meta>
<itm key="messageType">request</itm>
<itm key="messageTime">2022-08-17T11:07:26.533Z</itm>
<itm key="sourceEnv">web</itm>
</meta>
<responses>
<response dataType="asset"
tid="E40ACAEB-963C-4D06-B3ED-7C01B3E51C37"
id="77971"
action="copy"
path="/MAM/demo/photo.jpg">
<status>ERROR</status>
<description>Collision during copy. Collision asset name:'photo.jpg'</description>
<details>
<itm key="collision">true</itm>
<itm key="monitorId">77845</itm>
</details>
</response>
</responses>
</pim>
Checkin
Checkin asset by tid
curl
curl --location --request POST 'https://<OMN_SERVER>/api/core/v1/dam/assets/perform' \
--header 'Authorization: Bearer <TOKEN>' \
--header 'Content-Type: application/xml; charset=UTF8' \
--data-raw '<?xml version="1.0" encoding="UTF-8"?>
<pim xmlns="http://www.apollon.de/omn" schemaVersion="5.6.0">
<actions>
<action dataType="asset" tid="71A1021B-786C-4538-8883-70A1C6754034" type="checkin"/>
</actions>
</pim>'
<?xml version="1.0" encoding="UTF-8"?>
<pim xmlns="http://www.apollon.de/omn" schemaVersion="5.6.0">
<actions>
<action dataType="asset" tid="71A1021B-786C-4538-8883-70A1C6754034" type="checkin"/>
</actions>
</pim>
<?xml version="1.0" encoding="UTF-8"?>
<pim xmlns="http://www.apollon.de/omn" schemaVersion="5.6.0">
<meta>
<itm key="messageType">request</itm>
<itm key="messageTime">2022-06-17T09:23:08.154Z</itm>
<itm key="sourceEnv">web</itm>
</meta>
<responses>
<response dataType="asset"
tid="71A1021B-786C-4538-8883-70A1C6754034"
action="update">
<status>SUCCESS</status>
<description>The asset has been checked-in</description>
</response>
</responses>
</pim>
Error responses
<?xml version="1.0" encoding="UTF-8"?>
<pim xmlns="http://www.apollon.de/omn" schemaVersion="5.6.0">
<meta>
<itm key="messageType">request</itm>
<itm key="messageTime">2022-06-14T14:38:06.734Z</itm>
<itm key="sourceEnv">web</itm>
</meta>
<responses>
<response dataType="asset" tid="DB2B33D8-C9DF-4A0B-BCC4-F5222CB8A5122" action="update">
<status>ERROR</status>
<description>Isy object with meta tag guid 'DB2B33D8-C9DF-4A0B-BCC4-F5222CB8A5122' is not found.</description>
</response>
</responses>
</pim>
<?xml version="1.0" encoding="UTF-8"?>
<pim xmlns="http://www.apollon.de/omn" schemaVersion="5.6.0">
<meta>
<itm key="messageType">request</itm>
<itm key="messageTime">2022-06-14T14:40:00.264Z</itm>
<itm key="sourceEnv">web</itm>
</meta>
<responses>
<response dataType="asset" tid="DB2B33D8-C9DF-4A0B-BCC4-F5222CB8A512" action="update">
<status>ERROR</status>
<description>The asset is checked-out (locked) by another user</description>
</response>
</responses>
</pim>
<?xml version="1.0" encoding="UTF-8"?>
<pim xmlns="http://www.apollon.de/omn" schemaVersion="5.6.0">
<meta>
<itm key="messageType">request</itm>
<itm key="messageTime">2022-06-14T14:40:00.264Z</itm>
<itm key="sourceEnv">web</itm>
</meta>
<responses>
<response dataType="asset" tid="DB2B33D8-C9DF-4A0B-BCC4-F5222CB8A512" action="update">
<status>ERROR</status>
<description>The asset access is denied</description>
</response>
</responses>
</pim>
Checkout
Checkout asset by tid
curl
curl --location --request POST 'https://<OMN_SERVER>/api/core/v1/dam/assets/perform' \
--header 'Authorization: Bearer <TOKEN>' \
--header 'Content-Type: application/xml; charset=UTF8' \
--data-raw '<?xml version="1.0" encoding="UTF-8"?>
<pim xmlns="http://www.apollon.de/omn" schemaVersion="5.6.0">
<actions>
<action dataType="asset" tid="71A1021B-786C-4538-8883-70A1C6754034" type="checkout"/>
</actions>
</pim>'
<?xml version="1.0" encoding="UTF-8"?>
<pim xmlns="http://www.apollon.de/omn" schemaVersion="5.6.0">
<actions>
<action dataType="asset" tid="71A1021B-786C-4538-8883-70A1C6754034" type="checkout"/>
</actions>
</pim>
<?xml version="1.0" encoding="UTF-8"?>
<pim xmlns="http://www.apollon.de/omn" schemaVersion="5.6.0">
<meta>
<itm key="messageType">request</itm>
<itm key="messageTime">2022-06-17T09:23:08.154Z</itm>
<itm key="sourceEnv">web</itm>
</meta>
<responses>
<response dataType="asset"
tid="71A1021B-786C-4538-8883-70A1C6754034"
action="update">
<status>SUCCESS</status>
<description>The asset has been checked-out</description>
</response>
</responses>
</pim>
Error responses
<?xml version="1.0" encoding="UTF-8"?>
<pim xmlns="http://www.apollon.de/omn" schemaVersion="5.6.0">
<meta>
<itm key="messageType">request</itm>
<itm key="messageTime">2022-06-14T14:38:06.734Z</itm>
<itm key="sourceEnv">web</itm>
</meta>
<responses>
<response dataType="asset" tid="DB2B33D8-C9DF-4A0B-BCC4-F5222CB8A5122" action="update">
<status>ERROR</status>
<description>Isy object with meta tag guid 'DB2B33D8-C9DF-4A0B-BCC4-F5222CB8A5122' is not found.</description>
</response>
</responses>
</pim>
<?xml version="1.0" encoding="UTF-8"?>
<pim xmlns="http://www.apollon.de/omn" schemaVersion="5.6.0">
<meta>
<itm key="messageType">request</itm>
<itm key="messageTime">2022-06-14T14:40:00.264Z</itm>
<itm key="sourceEnv">web</itm>
</meta>
<responses>
<response dataType="asset" tid="DB2B33D8-C9DF-4A0B-BCC4-F5222CB8A512" action="update">
<status>ERROR</status>
<description>The asset is checked-out (locked) by another user</description>
</response>
</responses>
</pim>
<?xml version="1.0" encoding="UTF-8"?>
<pim xmlns="http://www.apollon.de/omn" schemaVersion="5.6.0">
<meta>
<itm key="messageType">request</itm>
<itm key="messageTime">2022-06-14T14:40:00.264Z</itm>
<itm key="sourceEnv">web</itm>
</meta>
<responses>
<response dataType="asset" tid="DB2B33D8-C9DF-4A0B-BCC4-F5222CB8A512" action="update">
<status>ERROR</status>
<description>The asset access is denied</description>
</response>
</responses>
</pim>
Clean checkout
Clean checkout asset by tid
curl
curl --location --request POST 'https://<OMN_SERVER>/api/core/v1/dam/assets/perform' \
--header 'Authorization: Bearer <TOKEN>' \
--header 'Content-Type: application/xml; charset=UTF8' \
--data-raw '<?xml version="1.0" encoding="UTF-8"?>
<pim xmlns="http://www.apollon.de/omn" schemaVersion="5.6.0">
<actions>
<action dataType="asset" tid="71A1021B-786C-4538-8883-70A1C6754034" type="cleanCheckout"/>
</actions>
</pim>'
<?xml version="1.0" encoding="UTF-8"?>
<pim xmlns="http://www.apollon.de/omn" schemaVersion="5.6.0">
<actions>
<action dataType="asset" tid="71A1021B-786C-4538-8883-70A1C6754034" type="cleanCheckout"/>
</actions>
</pim>
<?xml version="1.0" encoding="UTF-8"?>
<pim xmlns="http://www.apollon.de/omn" schemaVersion="5.6.0">
<meta>
<itm key="messageType">request</itm>
<itm key="messageTime">2022-06-17T09:23:08.154Z</itm>
<itm key="sourceEnv">web</itm>
</meta>
<responses>
<response dataType="asset"
tid="71A1021B-786C-4538-8883-70A1C6754034"
action="update">
<status>SUCCESS</status>
<description>The asset has been clean from checkout</description>
</response>
</responses>
</pim>
Error responses
<?xml version="1.0" encoding="UTF-8"?>
<pim xmlns="http://www.apollon.de/omn" schemaVersion="5.6.0">
<meta>
<itm key="messageType">request</itm>
<itm key="messageTime">2022-06-14T14:38:06.734Z</itm>
<itm key="sourceEnv">web</itm>
</meta>
<responses>
<response dataType="asset" tid="DB2B33D8-C9DF-4A0B-BCC4-F5222CB8A5122" action="update">
<status>ERROR</status>
<description>Isy object with meta tag guid 'DB2B33D8-C9DF-4A0B-BCC4-F5222CB8A5122' is not found.</description>
</response>
</responses>
</pim>
<?xml version="1.0" encoding="UTF-8"?>
<pim xmlns="http://www.apollon.de/omn" schemaVersion="5.6.0">
<meta>
<itm key="messageType">request</itm>
<itm key="messageTime">2022-06-14T14:40:00.264Z</itm>
<itm key="sourceEnv">web</itm>
</meta>
<responses>
<response dataType="asset" tid="DB2B33D8-C9DF-4A0B-BCC4-F5222CB8A512" action="update">
<status>ERROR</status>
<description>The asset access is denied</description>
</response>
</responses>
</pim>
Retrieve assets
| /dam/assets/retrieve Retrieve asset information and attributes details. |
The endpoint can also provide information about previews and asset’s history.
Resource path |
/api/core/v1/dam/assets/retrieve |
HTTP method |
POST |
Request content type |
application/json |
Response content type |
|
Asset attributes
Asset attributes are stored in AssetType.vals
Asset attributes type and examples
| Attribute type | Is localized | Response template | Example |
|---|---|---|---|
Boolean |
|
|
|
Boolean |
X |
|
|
Date |
|
|
|
Date |
X |
|
|
Enumeration |
|
|
|
Enumeration |
X |
|
|
Number |
|
|
|
Number |
X |
|
|
String |
|
|
|
String |
X |
|
|
XMP |
|
|
Body parameters
Specified by AssetRequest
Return Type
PimType with filled AssetsType. More info AssetType
Responses
| Code | Message | Datatype |
|---|---|---|
200 |
PimType with list of assets |
|
500 |
Error in ResponseType |
Samples
| Please use transform endpoint to get the JSON/compact-JSON samples from the XML one. |
Get asset details with asset history and previews info
curl --location --request POST 'https://<OMN_SERVER>/api/core/v1/dam/assets/retrieve' \
--header 'Authorization: Bearer <TOKEN>' \
--header 'Content-Type: application/json' \
--data-raw '{
"ids": [
24478
],
"retrieveHistory": true,
"retrievePreviews": true
}'
<?xml version="1.0" encoding="UTF-8"?>
<pim xmlns="http://www.apollon.de/omn" schemaVersion="5.6.0">
<assets>
<asset parent="01427CB0-AF41-41CF-96FC-51EC7B6ADEC1"
tid="6FC0022A-E978-4ADF-ABFE-DBF0BE99042F"
type="IMG">
<name>100192855000_96p.jpg</name>
<meta>
<itm key="annotationstate">false</itm>
<itm key="archivestate">ONLINE</itm>
<itm key="creationDate">2022-10-04T11:39:13.943+02:00</itm>
<itm key="discriminator">IMG</itm>
<itm key="fileCreationDate">2022-10-04T11:39:13.937+02:00</itm>
<itm key="fileModificationDate">2022-10-04T11:39:13.937+02:00</itm>
<itm key="fileTypeShortName">JPEG</itm>
<itm key="hidden">false</itm>
<itm key="identity">24478</itm>
<itm key="imageColorspace">YCBCR</itm>
<itm key="imageHeightInMM">705.5555555555555</itm>
<itm key="imageHeightInPixel">2000</itm>
<itm key="imageICCProfile">sRGB IEC61966-2-1 withBPC</itm>
<itm key="imageWidthInMM">465.66666666666663</itm>
<itm key="imageWidthInPixel">1320</itm>
<itm key="imageXResolutionValue">72.0</itm>
<itm key="imageYResolutionValue">72.0</itm>
<itm key="modificationDate">2022-10-04T11:39:16.272+02:00</itm>
<itm key="nameWithoutExtension">100192855000_96p</itm>
<itm key="numberOfVersions">0</itm>
<itm key="online">true</itm>
<itm key="pathStringStr">/Productimages/100/192/855/100192855000_96p.jpg</itm>
<itm key="previewCoarse">1C85040C-D61C-41E7-97CC-15B08B0675FE</itm>
<itm key="previewOriginal"/>
<itm key="previewOriginalMultimedia"/>
<itm key="previewOriginalPixel">48C064B8-B3EC-4476-A84B-11474684FF2B</itm>
<itm key="previewOriginalVector"/>
<itm key="previewThumbnail">FC24D91C-69FE-4FB3-A6FA-B9A66EB37CBC</itm>
<itm key="resourceSize">0</itm>
<itm key="rncIdentifier">MAM</itm>
<itm key="size">112209</itm>
<itm key="totalChecksum">8a6c74821055ccc8da8603eed6976017</itm>
<itm key="totalChecksumHashAlgorithm">MD5</itm>
<itm key="totalSize">112209</itm>
</meta>
<vals>
<val attr="xmp.IPTC.Description" type="xmp">
<itm>100192296041383437</itm>
</val>
<val attr="xmp.dc:description" type="xmp">
<itm>100192296041383437</itm>
</val>
<val attr="xmp.dc:subject" type="xmp">
<itm>1001/100192/855000/19;</itm>
</val>
<val attr="xmp.tiff.Orientation" type="xmp">
<itm>1</itm>
</val>
<val attr="xmp.dc:creator" type="xmp">
<itm>p</itm>
</val>
<val attr="xmp.IPTC.Keywords" type="xmp">
<itm>1001/100192/855000/19;</itm>
</val>
<val attr="xmp.dc:format" type="xmp">
<itm>image/jpeg</itm>
</val>
<val attr="xmp.IPTC.Creator" type="xmp">
<itm>p</itm>
</val>
<val attr="xmp.exif:ExposureTime" type="xmp">
<itm>1/160</itm>
</val>
<val attr="STRING_SIMPLE">
<itm>string</itm>
</val>
<val attr="ENUMERATION_L" type="multi_loc">
<i18n loc="en_EN">
<itm pos="0">Brown</itm>
<itm pos="1">Yellow</itm>
</i18n>
</val>
</vals>
<histories>
<history id="37220">
<meta>
<itm key="changedProperty">STRING_SIMPLE</itm>
<itm key="eventDate">2022-10-21T15:45:04.110+02:00</itm>
<itm key="eventDescription">Saving object details.</itm>
<itm key="eventIdentifier">SAVE_DETAILS</itm>
<itm key="newValue">testttest</itm>
<itm key="oldValue">aeorosol</itm>
<itm key="userIdentifier">test@apollon.de</itm>
</meta>
</history>
<history id="54321">
<meta>
<itm key="changedProperty">STRING_SIMPLE</itm>
<itm key="eventDate">2022-10-21T15:45:15.928+02:00</itm>
<itm key="eventDescription">Saving object details.</itm>
<itm key="eventIdentifier">SAVE_DETAILS</itm>
<itm key="newValue">hi</itm>
<itm key="oldValue">testttest</itm>
<itm key="userIdentifier">test@apollon.de</itm>
</meta>
</history>
</histories>
<previews>
<preview tid="E5B04787-87BD-4D18-AAA6-6CD26498EB0A" type="ORIGINAL_PIXEL">
<meta>
<itm key="extension">jpeg</itm>
<itm key="height">230</itm>
<itm key="modificationDate">2022-09-08T13:11:29.802Z</itm>
<itm key="pageNumber">-1</itm>
<itm key="size">0</itm>
<itm key="status">ORIGINAL</itm>
<itm key="url">/dam/assets/bin?assetTid=11319367-DE26-4FB8-9148-3C341766C1BA&format=previewOriginalPixel</itm>
<itm key="width">219</itm>
</meta>
</preview>
<preview tid="0B0A042E-6F51-44C2-8CE7-5F13E4719FCF" type="THUMBNAIL">
<meta>
<itm key="extension">jpeg</itm>
<itm key="height">40</itm>
<itm key="modificationDate">2022-09-08T13:11:29.802Z</itm>
<itm key="pageNumber">-1</itm>
<itm key="size">0</itm>
<itm key="status">ORIGINAL</itm>
<itm key="url">/dam/assets/bin?assetTid=11319367-DE26-4FB8-9148-3C341766C1BA&format=previewThumbnail</itm>
<itm key="width">38</itm>
</meta>
</preview>
<preview tid="11F00126-6D35-4355-99C3-2763A9743C00" type="COARSE">
<meta>
<itm key="extension">jpeg</itm>
<itm key="height">480</itm>
<itm key="modificationDate">2022-09-08T13:11:29.802Z</itm>
<itm key="pageNumber">-1</itm>
<itm key="size">0</itm>
<itm key="status">ORIGINAL</itm>
<itm key="url">/dam/assets/bin?assetTid=11319367-DE26-4FB8-9148-3C341766C1BA&format=previewCoarse</itm>
<itm key="width">457</itm>
</meta>
</preview>
</previews>
</asset>
</assets>
</pim>
Persist assets
| /dam/assets/persist Saves asset information and asset attributes details. |
Allows to
Resource path |
/api/core/v1/dam/assets/persist |
HTTP method |
POST |
Request content type |
|
Response content type |
|
Asset attribute persisting
Asset attributes are stored in AssetType.vals. More info about asset attributes
| Only provided attribute values are persisted, other values that are not provided in AssetType.vals will be not changed. |
| Only values of attributes registered in OMN could be saved. |
Keyword link persisting
Keyword links are stored in AssetType.links. See below for sample
<?xml version="1.0" encoding="UTF-8"?>
<pim xmlns="http://www.apollon.de/omn" schemaVersion="5.6.0">
<meta>
<itm key="messageType">request</itm>
<itm key="messageTime">2024-05-08T09:42:06.853Z</itm>
<itm key="sourceEnv">ocd_dev</itm>
</meta>
<assets>
<asset id="58525" parent="7CFD9FB3-8124-4363-8C06-B844CC58249C" tid="5B8EF672-A396-43BC-B880-E8B1FC2F7376" type="IMG">
<name>MyAsset.jpg</name>
<links>
<itms mode="delta" type="kwds">
<itm pos="1">/MyRootKW/MySubKW</itm>
</itms>
</links>
</asset>
</assets>
</pim>
| Only existing keywords can be linked. Non-existent keywords won’t be created automatically. |
Body parameters
Accepts PimType with AssetsType
Return Type
PimType with statuses ResponsesType about each persisted asset.
Responses
| Code | Message | Datatype |
|---|---|---|
200 |
PimType with list of responses |
|
500 |
Error in ResponseType |
Samples
| Please use transform endpoint to get the JSON/compact-JSON samples from the XML one. |
Save asset attributes and new name
curl --location --request POST 'https://<OMN_SERVER>/api/core/v1/dam/assets/retrieve' \
--header 'Authorization: Bearer <TOKEN>' \
--header 'Content-Type: application/json' \
--data-raw '<BODY>'
<?xml version="1.0" encoding="UTF-8"?>
<pim xmlns="http://www.apollon.de/omn" schemaVersion="5.6.0">
<assets>
<asset parent="01427CB0-AF41-41CF-96FC-51EC7B6ADEC1"
tid="6FC0022A-E978-4ADF-ABFE-DBF0BE99042F"
type="IMG">
<name>100192855000_96p.jpg</name>
<vals>
<val attr="STRING_SIMPLE">
<itm>string</itm>
</val>
<val attr="NUMBER_SIMPLE">
<itm>6395629</itm>
</val>
<val attr="ENUMERATION_L" type="multi_loc">
<i18n loc="en_EN">
<itm pos="0">Brown</itm>
<itm pos="1">Yellow</itm>
</i18n>
</val>
<val attr="xmp.IPTC.Description" type="xmp">
<itm>100192296041383437</itm>
</val>
<val attr="xmp.dc:description" type="xmp">
<itm>100192296041383437</itm>
</val>
<val attr="xmp.dc:subject" type="xmp">
<itm>1001/100192/855000/19;</itm>
</val>
<val attr="xmp.tiff.Orientation" type="xmp">
<itm>1</itm>
</val>
<val attr="xmp.IPTC.Keywords" type="xmp">
<itm>1001/100192/855000/19;</itm>
</val>
<val attr="xmp.dc:format" type="xmp">
<itm>image/jpeg</itm>
</val>
<val attr="xmp.IPTC.Creator" type="xmp">
<itm>p</itm>
</val>
<val attr="xmp.exif:ExposureTime" type="xmp">
<itm>1/160</itm>
</val>
</vals>
</asset>
</assets>
</pim>
<?xml version="1.0" encoding="UTF-8"?>
<pim xmlns="http://www.apollon.de/omn" schemaVersion="5.6.0">
<meta>
<itm key="messageType">request</itm>
<itm key="messageTime">2022-06-03T07:28:00.168Z</itm>
<itm key="sourceEnv">web</itm>
</meta>
<responses>
<response dataType="ASSET" tid="71A1021B-786C-4538-8883-70A1C6754034" action="update">
<status>SUCCESS</status>
<description>The asset has been saved successfully</description>
</response>
</responses>
</pim>
Link keywords to asset
curl --location --request POST 'https://<OMN_SERVER>/api/core/v1/dam/assets/retrieve' \
--header 'Authorization: Bearer <TOKEN>' \
--header 'Content-Type: application/json' \
--data-raw '<BODY>'
<?xml version="1.0" encoding="UTF-8"?>
<pim xmlns="http://www.apollon.de/omn" schemaVersion="5.6.0">
<meta>
<itm key="messageType">request</itm>
<itm key="messageTime">2024-05-08T09:42:06.853Z</itm>
<itm key="sourceEnv">ocd_dev</itm>
</meta>
<assets>
<asset id="58525" parent="7CFD9FB3-8124-4363-8C06-B844CC58249C" tid="5B8EF672-A396-43BC-B880-E8B1FC2F7376" type="IMG">
<name>MyAsset.jpg</name>
<links>
<itms mode="delta" type="kwds">
<itm pos="0">/MyRootKeyword</itm>
<itm pos="1">/AnotherRootKeyword/MySubKeyword</itm>
</itms>
</links>
</asset>
</assets>
</pim>
<?xml version="1.0" encoding="UTF-8"?>
<pim xmlns="http://www.apollon.de/omn" schemaVersion="5.6.0">
<meta>
<itm key="messageType">request</itm>
<itm key="messageTime">2022-06-03T07:28:00.168Z</itm>
<itm key="sourceEnv">web</itm>
</meta>
<responses>
<response dataType="ASSET" tid="71A1021B-786C-4538-8883-70A1C6754034" action="update">
<status>SUCCESS</status>
<description>The asset has been saved successfully</description>
</response>
</responses>
</pim>
Error responses
<?xml version="1.0" encoding="UTF-8"?>
<pim xmlns="http://www.apollon.de/omn" schemaVersion="5.6.0">
<meta>
<itm key="messageType">request</itm>
<itm key="messageTime">2022-06-03T07:46:16.200Z</itm>
<itm key="sourceEnv">web</itm>
</meta>
<responses>
<response dataType="asset" tid="71A1021B-786C-4538-8883-70A1C675403422" action="update">
<status>ERROR</status>
<description>The asset does not exist</description>
</response>
</responses>
</pim>
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<pim xmlns="http://www.apollon.de/omn">
<meta>
<itm key="messageType">response</itm>
<itm key="messageTime">2024-05-13T04:54:05.030Z</itm>
<itm key="refMessageId">1131</itm>
<itm key="sourceEnv">ocd_dev</itm>
</meta>
<responses>
<response dataType="asset" tid="5B8EF672-A396-43BC-B880-E8B1FC2F7376">
<status>SUCCESS</status>
<issues type="1002">
<itm key="description">Keyword could not be linked: Keyword with path '/nonexistentkeyword' not found.</itm>
</issues>
</response>
</responses>
</pim>
<?xml version="1.0" encoding="UTF-8"?>
<pim xmlns="http://www.apollon.de/omn" schemaVersion="5.6.0">
<meta>
<itm key="messageType">request</itm>
<itm key="messageTime">2022-06-03T07:46:16.200Z</itm>
<itm key="sourceEnv">web</itm>
</meta>
<responses>
<response dataType="asset" tid="71A1021B-786C-4538-8883-70A1C675403422" action="update">
<status>ERROR</status>
<description>The asset does not exist</description>
</response>
</responses>
</pim>
<?xml version="1.0" encoding="UTF-8"?>
<pim xmlns="http://www.apollon.de/omn" schemaVersion="5.6.0">
<meta>
<itm key="messageType">request</itm>
<itm key="messageTime">2022-06-04T09:15:35.301Z</itm>
<itm key="sourceEnv">web</itm>
</meta>
<responses>
<response dataType="ASSET" tid="71A1021B-786C-4538-8883-70A1C6754034" action="update">
<status>WARNING</status>
<description>The asset has been saved successfully. Some attributes were not saved due to Access Rights</description>
</response>
</responses>
</pim>
Query assets
| /dam/assets/query Gets list of asset tids by allowed criteria |
Allows to get assets tids by:
-
By modification date (from/until)
-
By file type
-
By directory
Tip: Criteria combined with AND operator.
Resource path |
/api/core/v1/dam/assets/query |
HTTP method |
POST |
Request content type |
application/json; |
Response content type |
application/json; |
Body parameters
Accepts AssetQuery
Return Type
Filled with asset tids AssetRequest
Responses
| Code | Message | Datatype |
|---|---|---|
200 |
Found assets ids |
|
400 |
Invalid input error ResponseType |
|
500 |
Error in ResponseType |
Samples
Query asset by modified dates, asset discriminator, parent directory
curl --location --request POST 'https://<OMN_SERVER>/api/core/v1/dam/assets/query' \
--header 'Authorization: Bearer <TOKEN>' \
--header 'Content-Type: application/json' \
--data-raw '{
"modifiedFrom": "2022-12-09T08:33:09.734Z",
"modifiedUntil": "2022-12-12T08:33:09.734Z",
"fileTypes": [
"IMG"
],
"directory": {
"path": "/MAM/dir1/dir2/dir3"
}
}
'
Request body examples:
{
"modifiedFrom": "2022-12-09T08:33:09.734Z",
"modifiedUntil": "2022-12-12T08:33:09.734Z",
"fileTypes": [
"IMG"
],
"directory": {
"path": "/MAM/dir1/dir2/dir3"
}
}
{
"directory": {
"tid": "DBF6D18D-6CB4-4765-8966-10000DD22A6E"
}
}
{
"directory": {
"id": 74628354
}
}
{
"directory": {
"path": "/MAM/rootDirectory/childDirectory"
}
}
{
"tids": [
"8E93BA7A-0521-4FB2-A7B7-40941C7A5AFA",
"218BCAED-A63B-4CE4-B23F-42B479E4E9FB",
"C3617CA4-0869-4A60-9CDC-32DCA0322F63",
"2BA8E460-964E-4197-9292-1E4365B29386",
"5BD22A27-7C2E-49B9-B90F-00F209900480",
"A168315F-24BF-4EF3-8BF9-619C71502D42",
"C9229729-D0D6-4CDA-92C8-3B916D1B4F85",
"2ABE86E5-6261-4BBF-A30B-235964B6EDBD",
"365F8ED1-1B75-4218-824A-E0B394D1DFEE",
"2312639C-F5D7-4F82-BEEF-4DD5E9668425",
"8195578A-AB9D-4BFD-9B86-2519E0A74E85",
"FC2E1C48-5904-4754-9E4E-8032ABE6949C",
"599641D5-7637-46DB-97BC-635F915C188A",
"D1019EE5-F1E0-49FA-8C2B-AD7FE3F8402C",
"6BD4B93B-2F35-4B9F-909E-974443B7C96B",
"DA32F94E-98B8-4F62-B588-EE804D97717B",
"08E3AF9C-1D28-4962-9C82-4E54633A9A4B",
"F008FE89-7372-4C17-83AB-670A664B57D9",
"95E7D312-1C4B-43BF-93C9-2219248ABF33",
"A905D075-8312-49EA-AB09-65D6FDBEE573",
"19F2C143-68D0-410C-BC24-53B33B70D270"
],
"retrieveHistory": false,
"retrievePreviews": false
}
Retrieve statuses of an assets
| /dam/assets/status Gets the status information for given assets. |
The endpoint could provide information about asset import and object statuses.
Resource path |
/api/core/v1/dam/assets/status |
HTTP method |
POST |
Request content type |
application/json |
Response content type |
|
Body parameters
Specified by AssetRequest
-
ids: it might be used to get assets statuses by asset’s id's
-
tids: it might be used to get assets statuses by asset’s tid's
| Assets statuses are retrieved by tids OR ids. ids are ignored if the request contains tids and ids. |
Return Type
OmnType with filled AssetsType. More info AssetType
Responses
| Value | Description |
|---|---|
pending |
Import is in processing queue |
running |
General status if import is running |
available |
Asset, previews and metadata available |
incomplete |
Import failed at some state and is incomplete (most of the time Asset is available but not synchronized) |
| Value | Description |
|---|---|
import incomplete |
Object is not synchronized (check-in not complete) |
available |
Asset, previews and metadata available after import/checkin |
locked |
Asset is "checked out" |
marked for deletion |
Asset is marked for deletion |
| Code | Message | Datatype |
|---|---|---|
200 |
PimType with filled AssetsType |
|
400 |
Invalid input provided |
|
401 |
Not authorized |
|
404 |
Not found |
|
500 |
An unknown internal error occurred |
Samples
| Please use transform endpoint to get the JSON/compact-JSON samples from the XML one. |
1. To get a list of assets statuses by assets tids
curl
curl --location --request POST 'http://<OMN_SERVER>/api/core/v1/dam/assets/status' \
--header 'Authorization: Bearer <TOKEN>' \
--header 'Content-Type: application/json' \
--data-raw '{
"tids": ["986A971D-1B8B-4E72-ACB3-0ED272CB504"]
}'
{
"tids": ["986A971D-1B8B-4E72-ACB3-0ED272CB504"]
}
<?xml version="1.0" encoding="UTF-8"?>
<pim xmlns="http://www.apollon.de/omn" schemaVersion="5.6.0">
<meta>
<itm key="messageType">request</itm>
<itm key="messageTime">2022-09-27T12:41:38.795Z</itm>
<itm key="itemInformationType">asset</itm>
</meta>
<assets>
<asset tid="986A971D-1B8B-4E72-ACB3-0ED272CB504" id="64556">
<meta>
<itm key="ImportState">available</itm>
<itm key="ObjectState">available</itm>
</meta>
</asset>
</assets>
</pim>
2. To get a list of assets statuses by assets ids
curl
curl --location --request POST 'http://<OMN_SERVER>/api/core/v1/dam/assets/status' \
--header 'Authorization: Bearer <TOKEN>' \
--header 'Content-Type: application/json' \
--data-raw '{
"ids": ["15185"]
}'
{
"ids": ["15185"]
}
<?xml version="1.0" encoding="UTF-8"?>
<pim xmlns="http://www.apollon.de/omn" schemaVersion="5.6.0">
<meta>
<itm key="messageType">request</itm>
<itm key="messageTime">2022-09-27T12:41:38.795Z</itm>
<itm key="itemInformationType">asset</itm>
</meta>
<assets>
<asset tid="986A971D-1B8B-4E72-ACB3-0ED272CBCCC" id="15185">
<meta>
<itm key="ImportState">available</itm>
<itm key="ObjectState">available</itm>
</meta>
</asset>
</assets>
</pim>
Retrieve Histories
| /dam/assets/histories/retrieve Retrieve asset histories by specified path. |
Resource path |
/api/core/v1/dam/assets/histories/retrieve |
HTTP method |
POST |
Request content type |
application/json |
Response content type |
|
Body parameters
Specified by HistoryRequest
-
tids - (List of String) - Filter parameter, asset TIDs (Metatag GUID), identifying unique objects
-
ids - (List of Integer) - Filter parameter, asset IDs, identifying unique objects
-
paths - (List of String) - Filter parameter, asset paths, identifying unique objects
Return Type
OmnType with filled HistoriesType
Responses
| Code | Message | Datatype |
|---|---|---|
200 |
OmnType with list of histories |
|
404 |
The requested resource could not be found |
|
500 |
An unknown internal error occurred |
Samples
| Please use transform endpoint to get the JSON/compact-JSON samples from the XML one. |
Retrieve history for assets by tids/ids/paths
Request body:
{
"tids": ["71A1021B-786C-4538-8883-70A1C6754034", "5FB0C015-2937-4B5C-AD45-7E7A49EEF026"]
}
{
"ids": [25151, 25167]
}
{
"paths": ["/MAM/test/invisible/image1.png", "/MAM/test/simple/image2.png"]
}
<?xml version="1.0" encoding="UTF-8"?>
<pim xmlns="http://www.apollon.de/omn" schemaVersion="5.6.0">
<meta>
<itm key="messageType">request</itm>
<itm key="messageTime">2022-05-24T06:45:03.459Z</itm>
<itm key="sourceEnv">web</itm>
</meta>
<assets>
<asset tid="71A1021B-786C-4538-8883-70A1C6754034">
<name>image1.png</name>
<meta>
<itm key="identity">25151</itm>
<itm key="pathStringStr">MAM/test/invisible/image1.png</itm>
</meta>
<histories>
<history id="98765">
<itm key='changedProperty'>prop1</itm>
<itm key='eventDate'>02.02.2022</itm>
<itm key='eventDescription'>Description</itm>
<itm key='eventIdentifier'>SAVE_DETAILS</itm>
<itm key='newValue'>NewText</itm>
<itm key='oldValue'>OldText</itm>
<itm key='userIdentifier'>admin</itm>
</history>
</histories>
</asset>
<asset tid="5FB0C015-2937-4B5C-AD45-7E7A49EEF026">
<name>image2.png</name>
<meta>
<itm key="identity">25167</itm>
<itm key="pathStringStr">MAM/test/simple/image2.png</itm>
</meta>
<history id="54321">
<itm key='changedProperty'>prop2</itm>
<itm key='eventDate'>02.02.2022</itm>
<itm key='eventDescription'>Description</itm>
<itm key='eventIdentifier'>SAVE_DETAILS</itm>
<itm key='newValue'>future</itm>
<itm key='oldValue'>past</itm>
<itm key='userIdentifier'>user</itm>
</history>
</histories>
</asset>
</assets>
</pim>