Jokes

Jokes

Games & Comics

Programming and general jokes

Visit API

📚 Documentation & Examples

Everything you need to integrate with Jokes

🚀 Quick Start Examples

Jokes Javascript Examplejavascript
// Jokes API Example
const response = await fetch('https://github.com/15Dkatz/official_joke_api', {
    method: 'GET',
    headers: {
        'Content-Type': 'application/json'
    }
});

const data = await response.json();
console.log(data);

The Official Joke API - A Collection of Jokes

The official joke API is a fun and entertaining API that provides a collection of jokes for everyone to enjoy. This API has over 150 unique jokes, and it is available for free.

Getting Started

You can access the official joke API by sending HTTP requests to https://official-joke-api.appspot.com. The API responds with JSON formatted data for all of the endpoints.

Endpoints

The following endpoints are available in the API:

Random Joke

This endpoint returns a randomly selected joke.

fetch('https://official-joke-api.appspot.com/jokes/random')
  .then(response => response.json())
  .then(data => console.log(data));

Ten Random Jokes

This endpoint returns ten randomly selected jokes.

fetch('https://official-joke-api.appspot.com/jokes/ten')
  .then(response => response.json())
  .then(data => console.log(data));

Get a Joke by ID

This endpoint returns a joke by its ID.

fetch('https://official-joke-api.appspot.com/jokes/10')
  .then(response => response.json())
  .then(data => console.log(data));

Get a List of Jokes by Type

This endpoint returns a list of jokes by their type.

fetch('https://official-joke-api.appspot.com/jokes/programming/random')
  .then(response => response.json())
  .then(data => console.log(data));

Conclusion

The official joke API is a great addition to any fun and exciting project. With over 150 unique jokes, this API has something for everyone. Using the API is easy, and you can start implementing it into your project right away!

📊 30-Day Uptime History

Daily uptime tracking showing online vs offline minutes

Jul 23Jul 25Jul 27Jul 29Jul 31Aug 2Aug 4Aug 6Aug 8Aug 10Aug 12Aug 14Aug 16Aug 18Aug 2104008001440Minutes
Online
Offline

Related APIs in Games & Comics