# uip ah applications, components, documents, media, store-listings, store-reviews

> Syntax and options for the Automation Hub application inventory, reusable components, attached documents/media, and the Automation Store marketplace (published listings and reviews).

The **application inventory** is what automations are tagged against (`--application-id` filters elsewhere reference it). **Components** are reusable building blocks, optionally scoped to one automation. **Documents** and **media** are files attached to an automation — a PDD, a screenshot, a demo video. The **Automation Store** is Automation Hub's internal marketplace: **store-listings** are published automations, **store-reviews** are the reviews left on them. See [`uip ah`](./uip-ah.md) for shared concepts (projection/`--all-fields`, paged vs. unpaged lists) that apply to every verb here.

## uip ah applications

Manage the application inventory that automations are tagged against.

### Synopsis

```text
uip ah applications list [--search <text>] [--category-id <id...>] [--limit <n>] [--offset <n>] [--all-fields]
uip ah applications update --file <json-file>
uip ah applications delete <application-id> [-y, --yes]
```

### uip ah applications list

#### Options

| Long | Value | Description |
|---|---|---|
| `--search <text>` | string | Free-text search. |
| `--category-id <id...>` | repeatable | Only applications in these categories. |
| `--limit <n>` / `--offset <n>` | integer | Paging. Default `--limit 20`. |
| `--all-fields` | flag | Return the raw payload. |

#### Example

```bash
uip ah applications list
```

#### Data shape (--output json)

```json
{
  "Code": "AhApplicationsList",
  "Data": [
    { "Id": 1, "Name": "SAP", "Version": "S/4HANA", "Language": null, "Code": "SAP", "IsActive": 1, "AddedByEndUser": 0, "CategoryIds": [4], "CreatedEpoch": 1735689600000 }
  ],
  "Pagination": { "Returned": 1, "Limit": 20, "Offset": 0 }
}
```

### uip ah applications update

Update existing applications in the inventory from a file. This edits entries that already exist — it cannot add one, because the service requires an `application_id` on every element.

#### Options

| Long | Value | Required | Description |
|---|---|---|---|
| `--file <json-file>` | path | **yes** | JSON array of applications to update. Each element needs `application_id` and `categoryIds` — take the shape from `applications list --all-fields`. |

#### Example

```bash
uip ah applications update --file ./applications.json
```

#### Data shape (--output json)

```json
{ "Code": "AhApplicationsUpdate", "Data": { "Status": "Updated" } }
```

### uip ah applications delete

#### Arguments

| Name | Required | Purpose |
|---|---|---|
| `<application-id>` | yes | Application id. |

#### Options

| Long | Description |
|---|---|
| `-y, --yes` | Confirm this irreversible operation. Required — the CLI never prompts. |

#### Example

```bash
uip ah applications delete 7 --yes
```

#### Data shape (--output json)

```json
{ "Code": "AhApplicationsDelete", "Data": { "Id": 7, "Status": "Deleted" } }
```

## uip ah components

Read reusable components, tenant-wide or per automation. Read-only — there is no create/update/delete on this surface.

### uip ah components list

#### Options

| Long | Value | Description |
|---|---|---|
| `--automation-id <id>` | integer | Scope to the components attached to this automation — a separate endpoint that takes no other filters. |
| `--type <type>` | string | Only this component type. Cannot combine with `--automation-id`. |
| `--category-id <id...>` | repeatable | Only these categories. Cannot combine with `--automation-id`. |
| `--application-id <id...>` | repeatable | Only components using these applications. Cannot combine with `--automation-id`. |
| `--limit <n>` / `--offset <n>` | integer | Paging. Default `--limit 20`. |
| `--all-fields` | flag | Return the raw payload. |

`--type`/`--category-id`/`--application-id` combined with `--automation-id` fails client-side — the per-automation list is a different endpoint that takes no filters.

#### Examples

```bash
uip ah components list
```

```bash
uip ah components list --automation-id 20
```

#### Data shape (--output json)

```json
{
  "Code": "AhComponentsList",
  "Data": [
    { "Id": 3, "Name": "Invoice parser", "Slug": "invoice-parser", "Description": "...", "TypeId": 1, "ReviewCount": 4, "ReviewAverage": 4.5, "DownloadCount": 12, "StatusId": 1, "PhaseId": 3, "UpdatedEpoch": 1738368000000 }
  ],
  "Pagination": { "Returned": 1, "Limit": 20, "Offset": 0 }
}
```

## uip ah documents

Manage the documents attached to an automation.

### uip ah documents list

#### Arguments

| Name | Required | Purpose |
|---|---|---|
| `<automation-id>` | yes | Automation id. |

#### Options

| Long | Description |
|---|---|
| `--limit <n>` / `--offset <n>` | Paging. Default `--limit 20`. |
| `--all-fields` | Return the raw payload. |

#### Example

```bash
uip ah documents list 20
```

#### Data shape (--output json)

```json
{
  "Code": "AhDocumentsList",
  "Data": [
    { "Id": 11, "AutomationId": 20, "Title": "PDD", "Description": "...", "TypeId": 1, "FileId": 42, "FileType": "docx", "EmbedLink": null, "IsActive": 1, "CreatedEpoch": 1735689600000 }
  ],
  "Pagination": { "Returned": 1, "Limit": 20, "Offset": 0 }
}
```

`FileId` is what `documents download` takes.

### uip ah documents create

Attach a document to an automation — upload the file's bytes with `--file`, or link to it with `--embed-link` (exactly one of the two).

#### Arguments

| Name | Required | Purpose |
|---|---|---|
| `<automation-id>` | yes | Automation id. |

#### Options

| Long | Value | Required | Description |
|---|---|---|---|
| `--title <text>` | string | **yes** | Document title. |
| `--description <text>` | string | **yes** | Document description. |
| `--document-type-id <id>` | integer | **yes** | Document type id. |
| `--file <path>` | path | conditionally | Local document file to upload. Exactly one of `--file`/`--embed-link` is required. No server-side mimetype allowlist — unrecognized extensions upload as `application/octet-stream`. |
| `--embed-link <url>` | url | conditionally | Link to an already-hosted document. Exactly one of `--file`/`--embed-link` is required. |
| `--submitter <email>` | email | no | Email of the submitting Automation Hub user. Defaults to the caller. |

#### Examples

```bash
uip ah documents create 20 --title "Process definition" --description "PDD v2" --document-type-id 1 --file ./pdd.docx
```

```bash
uip ah documents create 20 --title "Process definition" --description "PDD v2" --document-type-id 1 --embed-link https://acme.sharepoint.com/pdd.docx
```

#### Data shape (--output json)

```json
{ "Code": "AhDocumentsCreate", "Data": { "AutomationId": 20, "Id": 11, "Title": "Process definition", "FileId": 42, "File": "pdd.docx" } }
```

With `--embed-link`, `Data` carries `EmbedLink` instead of `FileId`/`File`.

### uip ah documents download

#### Arguments

| Name | Required | Purpose |
|---|---|---|
| `<file-id>` | yes | File id — the `FileId` from `documents list <automation-id>`. |

#### Options

| Long | Value | Required | Description |
|---|---|---|---|
| `--destination <path>` | path | **yes** | Local path to write the file to. |

#### Example

```bash
uip ah documents download 42 --destination ./pdd.pdf
```

#### Data shape (--output json)

```json
{ "Code": "AhDocumentsDownload", "Data": { "FileId": 42, "Destination": "./pdd.pdf", "Bytes": 20481, "ContentType": "application/pdf" } }
```

## uip ah media

Attach media (screenshots, video) to an automation. Separate from `documents` — its own upload endpoint, and there's no list or delete.

### uip ah media create

#### Arguments

| Name | Required | Purpose |
|---|---|---|
| `<automation-id>` | yes | Automation id. |

#### Options

| Long | Value | Required | Description |
|---|---|---|---|
| `--file <path>` | path | **yes** | Local media file to upload — `jpg`, `jpeg`, `png`, `gif`, or `mp4` only; any other extension is rejected client-side. |
| `--submitter <email>` | email | no | Email of the submitting Automation Hub user. Defaults to the caller. |

#### Example

```bash
uip ah media create 20 --file ./screen.png
```

#### Data shape (--output json)

```json
{ "Code": "AhMediaCreate", "Data": { "Id": 7, "MediaFileId": 501, "AutomationId": 20, "File": "screen.png" } }
```

## uip ah store-listings

Read the automations published to the Automation Store. Read-only.

### uip ah store-listings list

#### Options

| Long | Value | Description |
|---|---|---|
| `--search <text>` | string | Free-text search. |
| `--category-id <id...>` | repeatable | Only these categories. |
| `--application-id <id...>` | repeatable | Only listings using these applications. |
| `--business-unit <name>` | string | Only this business unit. |
| `--plain-text` | flag | Convert rich-text fields to plain text. |
| `--limit <n>` / `--offset <n>` | integer | Paging. Default `--limit 20`. |
| `--all-fields` | flag | Return the raw payload. |

#### Example

```bash
uip ah store-listings list
```

#### Data shape (--output json)

```json
{
  "Code": "AhStoreListingsList",
  "Data": [
    { "Id": 20, "Name": "Invoice intake", "Slug": "invoice-intake", "ReviewCount": 4, "ReviewScore": 4.2, "DownloadCount": 4, "VoteCount": 9, "IsPublished": 1, "BusinessUnit": "EMEA", "UpdatedEpoch": 1738368000000 }
  ],
  "Pagination": { "Returned": 1, "Limit": 20, "Offset": 0 }
}
```

## uip ah store-reviews

Read the Automation Store reviews on an automation. Its own resource group rather than a verb under `store-listings`. Read-only.

### uip ah store-reviews list

#### Arguments

| Name | Required | Purpose |
|---|---|---|
| `<automation-id>` | yes | Automation id — must be published to the store. |

#### Options

| Long | Description |
|---|---|
| `--limit <n>` / `--offset <n>` | Paging. Default `--limit 20`. |
| `--all-fields` | Return the raw payload. |

#### Example

```bash
uip ah store-reviews list 20
```

#### Data shape (--output json)

```json
{
  "Code": "AhStoreReviewsList",
  "Data": [
    { "Id": 5, "AutomationId": 20, "Score": 5, "Title": "Great automation", "Description": "...", "UserId": 3, "CreatedEpoch": 1735689600000 }
  ],
  "Pagination": { "Returned": 1, "Limit": 20, "Offset": 0 }
}
```

## Related

- [`uip ah`](./uip-ah.md) — overview, concepts, `audit-logs`, `auth-info`.
- [Automations, idea-flows, business-cases, phases, questionnaires, pipelines](./uip-ah-automations.md)
- [Categories, tags, collaborators, roles, users](./uip-ah-people.md)

## See also

- [Tools (plugins)](./concepts-tools.md)
- [Global options](./global-options.md)
- [Exit codes](./exit-codes.md)
