RANDOM

Random Picker API

GET/pick

Choose a random item from a comma-separated list.

No signup or API key required.

Parameters

itemsstringrequired · query
Comma-separated options. 1 to 100 non-empty options, at most 100 characters each and 1500 characters in the decoded list. Whitespace is trimmed. Commas separate options and cannot appear inside one.
formatenumoptional · query
Response format. Defaults to json.
jsontext

No request body. Unknown or repeated query parameters return HTTP 400.

Returns 200 OK

A JSON object with the following fields.

resultstring
One randomly selected, trimmed option from items.

Plain text

With format=text: Only the result value, without the JSON wrapper.

Errors

Validation and service errors always return JSON, including when format=text.

errorstring
A machine-readable error code, such as invalid_parameter or rate_limited.
messagestring
A description of the problem.

400 Invalid parameters.

414 Query string exceeds 2048 characters.

429 Rate limit reached. Wait the seconds in Retry-After before retrying.

Usage notes

Required items: 1..100 comma-separated non-empty options. Whitespace is trimmed. Max 100 characters per option, 1500 in the decoded list, and 2048 in the encoded query.

Pick lunch, a team activity, or a sample option. Encode query values with URLSearchParams; commas delimit choices and cannot be part of a single option.

Responses are not cached. Browser requests are supported through open CORS.

120 requests per minute per IP, with up to 30 per 10 seconds, shared across APIs. Limits are approximate per Cloudflare location. Full usage limits ↗