# Aprimo

> Find, upload and organize assets in Aprimo DAM: records, their metadata and classifications, collections and downloads.

App · 23 actions. Web page: https://docs.lodol.com/docs/integrations/aprimo

## Actions

### Add record to classification

File a record under a classification, keeping its other classifications.

**Inputs**

- Record (`record_id`, text, required): The record: one asset in Aprimo DAM, with its files and metadata.
- Classification (`classification_id`, text, required): The classification: a node in Aprimo's tree of categories, such as a brand or a campaign.

**Outputs**

- `data` (object): The response from Aprimo.

**Example output**

```json
{
  "data": {
    "id": "example"
  }
}
```

### Add record to collection

Add a record to a collection you add records to yourself.

**Inputs**

- Collection (`collection_id`, text, required): The collection.
- Record (`record_id`, text, required): The record: one asset in Aprimo DAM, with its files and metadata.

**Outputs**

- `data` (object): The response from Aprimo.

**Example output**

```json
{
  "data": {
    "collection_id": "example",
    "record_id": "example"
  }
}
```

### Create collection

Create a collection you add records to yourself.

**Inputs**

- Name (`name`, text, required): The collection's name.
- Description (`description`, text): What the collection is for.

**Outputs**

- `data` (object): The response from Aprimo.

**Example output**

```json
{
  "data": {
    "id": "example"
  }
}
```

### Create record from file

Upload a file of up to 20 MB and make it a new record, optionally filed under a classification and with one field filled in.

**Inputs**

- File (`file`, text, required): The file to upload, up to 20 MB.
- File name (`file_name`, text): The file's name in Aprimo, with its extension. Leave empty to keep the uploaded file's name.
- Classification (`classification_id`, text): A classification to file the record under.
- Field (`field_id`, text): The metadata field to fill in, such as Description or Keywords.
- Value (`value`, text): The field's new value. For a date, use YYYY-MM-DD; for a list of options, the option's name.
- Language (`language_id`, text): The language of the value, for a field kept in several languages. Leave empty for a field that isn't.
- Save as draft (`draft`, true/false): Save the record as a draft rather than releasing it.

**Outputs**

- `data` (object): The response from Aprimo.

**Example output**

```json
{
  "data": {
    "id": "example"
  }
}
```

### Delete collection

Delete a collection. The records in it stay in Aprimo.

**Inputs**

- Collection (`collection_id`, text, required): The collection.

**Outputs**

- `data` (object): The response from Aprimo.

**Example output**

```json
{
  "data": {}
}
```

### Delete record

Delete a record and its files.

**Inputs**

- Record (`record_id`, text, required): The record: one asset in Aprimo DAM, with its files and metadata.

**Outputs**

- `data` (object): The response from Aprimo.

**Example output**

```json
{
  "data": {}
}
```

### Get classification

Get a classification's name, path and place in the tree.

**Inputs**

- Classification (`classification_id`, text, required): The classification: a node in Aprimo's tree of categories, such as a brand or a campaign.

**Outputs**

- `data` (object): The response from Aprimo.

**Example output**

```json
{
  "data": {
    "createdOn": "example",
    "hasChildren": true,
    "id": "example",
    "identifier": "example",
    "isRoot": true,
    "labelPath": "example",
    "modifiedOn": "example",
    "name": "example",
    "namePath": "example",
    "parentId": "example",
    "sortIndex": 1
  }
}
```

### Get collection

Get a collection's name, description, type and status.

**Inputs**

- Collection (`collection_id`, text, required): The collection.

**Outputs**

- `data` (object): The response from Aprimo.

**Example output**

```json
{
  "data": {
    "createdOn": "example",
    "description": "example",
    "id": "example",
    "isReadOnly": true,
    "modifiedOn": "example",
    "name": "example",
    "ownerId": "example",
    "status": "example",
    "type": "example"
  }
}
```

### Get order

Get a download order's status and, once it is done, the links to its files.

**Inputs**

- Order ID (`order_id`, text, required): The order's ID, from Order record download.

**Outputs**

- `data` (object): The response from Aprimo.

**Example output**

```json
{
  "data": {
    "createdOn": "example",
    "deliveredFiles": [
      "example"
    ],
    "failedTargetsCount": 1,
    "id": "example",
    "message": "example",
    "orderType": "example",
    "startedOn": "example",
    "status": "example",
    "totalFileSize": 1,
    "type": "example"
  }
}
```

### Get record

Get a record with its metadata fields, classifications and thumbnail.

**Inputs**

- Record (`record_id`, text, required): The record: one asset in Aprimo DAM, with its files and metadata.

**Outputs**

- `data` (object): The response from Aprimo.

**Example output**

```json
{
  "data": {
    "classifications": {
      "items": [
        {
          "id": "example",
          "name": "example",
          "namePath": "example"
        }
      ]
    },
    "contentType": "example",
    "createdOn": "example",
    "fields": {
      "items": [
        {
          "dataType": "example",
          "fieldName": "example",
          "id": "example",
          "label": "example",
          "localizedValues": [
            {
              "languageId": "example",
              "value": "example",
              "values": [
                "example"
              ]
            }
          ]
        }
      ]
    },
    "id": "example",
    "modifiedOn": "example",
    "status": "example",
    "tag": "example",
    "thumbnail": {
      "extension": "example",
      "height": 1,
      "size": 1,
      "uri": "example",
      "width": 1
    },
    "title": "example"
  }
}
```

### List classification children

List the classifications directly under a classification.

**Inputs**

- Classification (`classification_id`, text, required): The classification: a node in Aprimo's tree of categories, such as a brand or a campaign.
- Page (`page`, number): The page of results to return. Leave empty for the first page. At least 1.
- Results per page (`page_size`, number): How many results to return on a page, up to 100. Leave empty for 50. From 1 to 100.

**Outputs**

- `data` (object): The response from Aprimo.

**Example output**

```json
{
  "data": {
    "items": [
      {
        "createdOn": "example",
        "hasChildren": true,
        "id": "example",
        "identifier": "example",
        "isRoot": true,
        "labelPath": "example",
        "modifiedOn": "example",
        "name": "example",
        "namePath": "example",
        "parentId": "example",
        "sortIndex": 1
      }
    ],
    "totalCount": 1
  }
}
```

### List classifications

List the classifications the connected user can see.

**Inputs**

- Sort by (`sort`, text): The order to list classifications in. Leave empty for name, A to Z. One of: `CreatedOn desc` (Newest first), `ModifiedOn desc` (Recently changed first), `Name` (Name, A to Z).
- Page (`page`, number): The page of results to return. Leave empty for the first page. At least 1.
- Results per page (`page_size`, number): How many results to return on a page, up to 100. Leave empty for 50. From 1 to 100.

**Outputs**

- `data` (object): The response from Aprimo.

**Example output**

```json
{
  "data": {
    "items": [
      {
        "createdOn": "example",
        "hasChildren": true,
        "id": "example",
        "identifier": "example",
        "isRoot": true,
        "labelPath": "example",
        "modifiedOn": "example",
        "name": "example",
        "namePath": "example",
        "parentId": "example",
        "sortIndex": 1
      }
    ],
    "totalCount": 1
  }
}
```

### List collection records

List the records in a collection.

**Inputs**

- Collection (`collection_id`, text, required): The collection.
- Page (`page`, number): The page of results to return. Leave empty for the first page. At least 1.
- Results per page (`page_size`, number): How many results to return on a page, up to 100. Leave empty for 50. From 1 to 100.

**Outputs**

- `data` (object): The response from Aprimo.

**Example output**

```json
{
  "data": {
    "items": [
      {
        "contentType": "example",
        "createdOn": "example",
        "id": "example",
        "modifiedOn": "example",
        "status": "example",
        "tag": "example",
        "title": "example"
      }
    ],
    "totalCount": 1
  }
}
```

### List collections

List the collections the connected user can see.

**Inputs**

- Sort by (`sort`, text): The order to list collections in. Leave empty for newest first. One of: `CreatedOn desc` (Newest first), `ModifiedOn desc` (Recently changed first), `Name` (Name, A to Z).
- Page (`page`, number): The page of results to return. Leave empty for the first page. At least 1.
- Results per page (`page_size`, number): How many results to return on a page, up to 100. Leave empty for 50. From 1 to 100.

**Outputs**

- `data` (object): The response from Aprimo.

**Example output**

```json
{
  "data": {
    "items": [
      {
        "createdOn": "example",
        "description": "example",
        "id": "example",
        "isReadOnly": true,
        "modifiedOn": "example",
        "name": "example",
        "ownerId": "example",
        "status": "example",
        "type": "example"
      }
    ],
    "totalCount": 1
  }
}
```

### List fields

List the metadata fields defined in Aprimo DAM, with their names, labels and types.

**Inputs**

- Page (`page`, number): The page of results to return. Leave empty for the first page. At least 1.
- Results per page (`page_size`, number): How many results to return on a page, up to 100. Leave empty for 50. From 1 to 100.

**Outputs**

- `data` (object): The response from Aprimo.

**Example output**

```json
{
  "data": {
    "items": [
      {
        "createdOn": "example",
        "dataType": "example",
        "id": "example",
        "isReadOnly": true,
        "isRequired": true,
        "isUniqueIdentifier": true,
        "label": "example",
        "languageMode": "example",
        "modifiedOn": "example",
        "name": "example",
        "scope": "example"
      }
    ],
    "totalCount": 1
  }
}
```

### List languages

List the languages Aprimo DAM keeps field values in.

**Inputs**

- Page (`page`, number): The page of results to return. Leave empty for the first page. At least 1.
- Results per page (`page_size`, number): How many results to return on a page, up to 100. Leave empty for 50. From 1 to 100.

**Outputs**

- `data` (object): The response from Aprimo.

**Example output**

```json
{
  "data": {
    "items": [
      {
        "culture": "example",
        "id": "example",
        "isEnabled": true,
        "name": "example"
      }
    ],
    "totalCount": 1
  }
}
```

### List users

List the users in Aprimo DAM.

**Inputs**

- Page (`page`, number): The page of results to return. Leave empty for the first page. At least 1.
- Results per page (`page_size`, number): How many results to return on a page, up to 100. Leave empty for 50. From 1 to 100.

**Outputs**

- `data` (object): The response from Aprimo.

**Example output**

```json
{
  "data": {
    "items": [
      {
        "createdOn": "example",
        "email": "example",
        "firstName": "example",
        "id": "example",
        "isActive": true,
        "lastName": "example",
        "modifiedOn": "example",
        "name": "example"
      }
    ],
    "totalCount": 1
  }
}
```

### Order record download

Ask Aprimo to prepare the latest version of a record's main file for download. Read the link with Get order once the order is done.

**Inputs**

- Record (`record_id`, text, required): The record: one asset in Aprimo DAM, with its files and metadata.
- Email me when ready (`notify`, true/false): Also email the connected Aprimo user when the download is ready.

**Outputs**

- `data` (object): The response from Aprimo.

**Example output**

```json
{
  "data": {
    "createdOn": "example",
    "deliveredFiles": [
      "example"
    ],
    "failedTargetsCount": 1,
    "id": "example",
    "message": "example",
    "orderType": "example",
    "startedOn": "example",
    "status": "example",
    "totalFileSize": 1,
    "type": "example"
  }
}
```

### Remove record from classification

Take a record out of one classification. The record and its other classifications stay.

**Inputs**

- Record (`record_id`, text, required): The record: one asset in Aprimo DAM, with its files and metadata.
- Classification (`classification_id`, text, required): The classification: a node in Aprimo's tree of categories, such as a brand or a campaign.

**Outputs**

- `data` (object): The response from Aprimo.

**Example output**

```json
{
  "data": {
    "id": "example"
  }
}
```

### Remove record from collection

Take a record out of a collection. The record stays in Aprimo.

**Inputs**

- Collection (`collection_id`, text, required): The collection.
- Record (`record_id`, text, required): The record: one asset in Aprimo DAM, with its files and metadata.

**Outputs**

- `data` (object): The response from Aprimo.

**Example output**

```json
{
  "data": {
    "collection_id": "example",
    "record_id": "example"
  }
}
```

### Search records

Find records (assets) by title, classification, when they were added or changed, or an Aprimo search expression.

**Inputs**

- Title contains (`title_contains`, text): Only records whose title contains this text.
- Classification (`classification_id`, text): The classification: a node in Aprimo's tree of categories, such as a brand or a campaign.
- Added after (`created_after`, date and time): Only records added at or after this time.
- Changed after (`modified_after`, date and time): Only records changed at or after this time.
- Search expression (`expression`, text): An Aprimo search expression for anything else, such as FieldName('Status').Option.Name = 'Approved'. It is combined with the filters above.
- Sort by (`sort`, text): The order to return records in. Leave empty for Aprimo's default. One of: `CreatedOn desc` (Newest first), `ModifiedOn desc` (Recently changed first), `Title` (Title, A to Z), `Rank desc` (Best match first).
- Page (`page`, number): The page of results to return. Leave empty for the first page. At least 1.
- Results per page (`page_size`, number): How many results to return on a page, up to 100. Leave empty for 50. From 1 to 100.

**Outputs**

- `data` (object): The response from Aprimo.

**Example output**

```json
{
  "data": {
    "items": [
      {
        "contentType": "example",
        "createdOn": "example",
        "id": "example",
        "modifiedOn": "example",
        "status": "example",
        "tag": "example",
        "title": "example"
      }
    ],
    "nextCursor": "example",
    "totalCount": 1
  }
}
```

### Update collection

Rename a collection, change its description, or archive or restore it. Fields left empty stay as they are.

**Inputs**

- Collection (`collection_id`, text, required): The collection.
- Name (`name`, text): The new name.
- Description (`description`, text): The new description.
- Status (`status`, text): Archive the collection, or make an archived one active again. One of: `Active`, `Archived`.

**Outputs**

- `data` (object): The response from Aprimo.

**Example output**

```json
{
  "data": {}
}
```

### Update record field

Set one metadata field of a record. Other fields stay as they are.

**Inputs**

- Record (`record_id`, text, required): The record: one asset in Aprimo DAM, with its files and metadata.
- Field (`field_id`, text, required): The metadata field to fill in, such as Description or Keywords.
- Value (`value`, text, required): The field's new value. For a date, use YYYY-MM-DD; for a list of options, the option's name.
- Language (`language_id`, text): The language of the value, for a field kept in several languages. Leave empty for a field that isn't.

**Outputs**

- `data` (object): The response from Aprimo.

**Example output**

```json
{
  "data": {
    "id": "example"
  }
}
```
