---
title: "Upload preset app packages"
type: reference
method: POST
path: /rest-api/preset-app-package/upload-packages.do
tag: "Targeting Rules"
---

# Upload preset app packages

`POST https://YOUR-NETWORK-DOMAIN/rest-api/preset-app-package/upload-packages.do`

Bulk-imports application package identifiers into the specified preset group from an uploaded file. The file should contain one application package identifier per line. Returns a JSON object with import statistics including the number of processed records. Requires PRESET_APP_PACKAGES_GROUP_MANAGEMENT permission. The action is recorded in the audit log.

## Query params

| Name | Type | Required | Example | Description |
|---|---|---|---|---|
| `groupId` | integer | yes | `100` | Unique numeric ID of the preset application package group to import packages into |

## Body

A multipart form: `file` (file).

## Responses

- `200` — Success
- `400` — Missing required parameter
- `401` — Unauthorized
- `403` — Forbidden
- `404` — Preset group not found
- `500` — Internal server error

## Example request

```bash
curl --request POST \
  --url 'https://YOUR-NETWORK-DOMAIN/rest-api/preset-app-package/upload-packages.do?groupId=100' \
  --header 'X-Api-Key: YOUR_API_KEY' \
  --form 'file=@data.csv'
```

Source: https://epom.com/ad-server/docs/api/targeting-rules/post-preset-app-package-upload-packages