---
title: "Schedules a celery task that will call custom action"
method: POST
path: "/v1/custom_actions/{context}/{action_id}/callback/"
---

# Schedules a celery task that will call custom action

`POST /v1/custom_actions/{context}/{action_id}/callback/`

## Request

- Base URL: `https://app.iconik.io/API/assets`
- URL: `https://app.iconik.io/API/assets/v1/custom_actions/{context}/{action_id}/callback/`
- Auth: none declared. Required headers: `App-ID`, `Auth-Token`
- TypeScript: <https://skmtc.dev/iconik/apis/iconik-assets/docs/v1/custom_actions/:context/:action_id/callback/post.ts> (a function with typed inputs; its response is checked against the schema)

Required roles:
 - can_read_custom_actions

## Path parameters

- `context` string, required
- `action_id` string, required

## Headers

- `App-ID` string, required
- `Auth-Token` string, required

## Request body

- CustomActionCallbackSchema
  - `asset_ids` string[]
  - `collection_ids` string[]
  - `from_collection_id` string, uuid, nullable: ID of a collection that the custom action was triggered from
  - `metadata_values` object
  - `metadata_view_id` string, uuid, nullable
  - `playlist_ids` string[]
  - `saved_search_ids` string[]

## Response `200`

Returns a custom action reply

- CustomActionCallbackReplySchema
  - `redirect_url` string

## Other responses

- `202`: Custom action call scheduled
- `400`: Bad request
- `401`: Token is invalid
- `404`: Requested page does not exist
- `409`: Custom action is disabled
- `default`: Error response

---

[API](https://skmtc.dev/iconik/apis/iconik-assets.md) - [All operations](https://skmtc.dev/iconik/apis/iconik-assets/llms.txt) - [OpenAPI document](https://skmtc.dev/iconik/apis/iconik-assets/revisions/62580d9e640e?raw)
