Jokes One API

Games & Comics / API Key Intermediate HTTPS CORS
Varies by plan (check documentation)

Overview

Jokes One is a REST API offering a curated "Joke of the Day" and a large searchable collection of jokes organized by categories. You need a free API key from jokes.one to access the full catalog. It is a good choice for adding daily humor to newsletters, widgets, or chat bots.

Beginner Tip

Use the /jod endpoint to get the Joke of the Day without any parameters, then explore the /categories endpoint to discover all available joke categories.

Available Data

joke text (setup/punchline)
joke category
joke type (single/twopart)

Example Response

JSON Response
{
  "error": false,
  "category": "Programming",
  "type": "twopart",
  "setup": "Why do programmers prefer dark mode?",
  "delivery": "Because light attracts bugs.",
  "id": 42,
  "lang": "en"
}

Field Reference

contents.jokes[].joke.title The title or headline of the joke.
contents.jokes[].joke.text The full joke body text.
contents.jokes[].joke.category Category label for this joke, such as jod or knock-knock.
contents.jokes[].joke.id Unique string identifier for the joke entry.
success.total Total number of jokes returned in this response.

Implementation Example

Request
const url = "https://jokes.one/api/joke/";
// Replace headers or query params with the values required by this API.
const response = await fetch(url, {
  headers: {
  "X-API-Key": "YOUR_API_KEY"
  }
});
if (!response.ok) throw new Error(`Request failed: ${response.status}`);
const data = await response.json();
console.log(data);

What Can You Build?

Note: These code examples are AI-generated and unverified. Always refer to the official API documentation for accurate usage.

Common Errors & Troubleshooting

401 Unauthorized The X-JokesOne-Api-Secret header is missing or contains an invalid key.
Register at jokes.one to get a free API key and pass it in the X-JokesOne-Api-Secret header.
429 Too Many Requests Free plan is limited to a small number of requests per hour.
Cache the Joke of the Day response for 24 hours since it only changes once per day.
Empty contents array The requested category has no jokes matching your filter.
Fetch the /categories endpoint first to see valid category identifiers before filtering.

Metadata Score Breakdown

Estimated from metadata — endpoint not independently tested

This score is estimated from observable metadata — HTTPS support, authentication model, declared CORS, and documentation reachability — because the API requires authentication or exposes no publicly testable endpoint. The five-signal breakdown is only shown for live-tested APIs.

Metadata estimate · endpoint not independently tested

Technical Specifications

Auth API Key
HTTPS REQUIRED
CORS YES
Category Games & Comics
Difficulty Intermediate
Verified: 2026-04-04

Related Tags

Similar APIs

View All →