Skip to content
This repository was archived by the owner on Nov 28, 2023. It is now read-only.

Mikusch/opentdb-api

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 

Repository files navigation

OpenTDB API

A simple wrapper for the OpenTDB API by PixelTail Games.

Usage

// Create a new OpenTDB object and wait until it has received a token
OpenTDB api = OpenTDB.newOpenTDB().awaitToken();

// Send a request for 10 questions to the API
CompletableFuture<List<Question<?, ?>>> future = api.fetchQuestionsAsync(10);

// Await the requests's completion and print the received questions
future.thenAccept(questions -> questions.forEach(System.out::println));

Releases

Packages

Used by

Contributors

Languages