---
title: "Flag or unflag an item as favourite"
method: POST
path: "/flag/{object_id}"
tags: ["Ratings and Flags"]
---

# Flag or unflag an item as favourite

`POST /flag/{object_id}`

## Path parameters

- `object_id` string, required

## Query parameters

- `type` 'song' | 'album' | 'artist' | 'playlist' | 'podcast' | 'podcast_episode' | 'video' | 'tvshow' | 'tvshow_season', required
- `flag` 0 | 1, required

## Response `200`

Updated

- SuccessResponse
  - `success` string

## Changes

- **2026-02-19** `07f53972fdd7` — 1 info
  - endpoint added

[Change history](https://skmtc.dev/ampache/apis/ampache-rest-api/changes/flag/:object_id/post.md)

---

[API](https://skmtc.dev/ampache/apis/ampache-rest-api.md) · [All operations](https://skmtc.dev/ampache/apis/ampache-rest-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/ampache/ampache-rest-api/revisions/07f53972fdd7/schema)
