---
title: "Pick a random song, podcast episode or video and redirect (302) to its stream url"
method: GET
path: "/random"
tags: ["Streaming and Downloads"]
---

# Pick a random song, podcast episode or video and redirect (302) to its stream url

`GET /random`

## Query parameters

- `type` 'song' | 'podcast_episode' | 'video'
- `bitrate` integer
- `format` string
- `offset` integer
- `stats` 0 | 1

## Other responses

- `302` — Redirect to the stream url of the randomly picked object
- `400` — HTTP 400 Bad Request (errors 4705, 4710).
- `403` — HTTP 403 Forbidden (errors 4700, 4701, 4703, 4742).
- `404` — HTTP 404 Not Found (error 4704).
- `410` — HTTP 410 Gone (error 4706).
- `500` — HTTP 500 Internal Server Error (error 4702).

## Changes

- **2026-07-17** `9abb9bf6d3bf` — 1 breaking
  - api path removed without deprecation
- **2026-07-14** `aaf4166bdf3a` — 1 info
  - endpoint added

[Change history](https://skmtc.dev/ampache/apis/ampache-rest-api/changes/random/get.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/d49e75ffe66b/schema)
