---
title: "Store items in last task run's dataset"
method: POST
path: "/v2/actor-tasks/{actorTaskId}/runs/last/dataset/items"
tags: ["Last Actor task run's default dataset"]
---

# Store items in last task run's dataset

`POST /v2/actor-tasks/{actorTaskId}/runs/last/dataset/items`

Appends an item or an array of items to the end of the last Actor task run's default dataset.

This endpoint is a shortcut that resolves the last task run's `defaultDatasetId` and proxies to the
[Store items](/api/v2/dataset-items-post) endpoint.

To save bandwidth and speed up your upload, you can send the request payload compressed and set the `Content-Encoding` header accordingly.

Below is a list of supported `Content-Encoding` types.

* Brotli: `Content-Encoding: br`
* Gzip: `Content-Encoding: gzip`
* Deflate: `Content-Encoding: deflate`

## Path parameters

- `actorTaskId` string, required

## Query parameters

- `status` string
- `origin` 'DEVELOPMENT' | 'WEB' | 'API' | 'SCHEDULER' | 'TEST' | 'WEBHOOK' | 'ACTOR' | 'CLI' | 'CI' | 'STANDBY' | 'MCP'

## Headers

- `Content-Encoding` 'br' | 'gzip' | 'deflate' | 'identity'

## Request body

- union
  - PutItemsRequest — The request body containing the item(s) to add to the dataset. Can be a single object or an array of objects. Each object represents one dataset item.
  - PutItemsRequest[]

## Response `201`

- object

## Other responses

- `400`
- `401` — Unauthorized - authentication required or invalid token.
- `403` — Forbidden - insufficient permissions to perform this action.
- `404` — Not found - the requested resource does not exist.
- `405` — Method not allowed.
- `413` — Payload too large - the request body exceeds the size limit.
- `415` — Unsupported media type - the Content-Encoding of the request is not supported.
- `429` — Too many requests - rate limit exceeded.

---

[API](https://skmtc.net/apify/apis/apify-api.md) · [All operations](https://skmtc.net/apify/apis/apify-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/apify/apify-api/versions/01a71794279b/schema)
