Skip to main content
POST
Get Trivia Questions

Request contract

  • Method and path: POST /apis/v1/api-ninjas/get-trivia
  • Availability: enabled
  • Request URL template: https://api.aisa.one/apis/v1/api-ninjas/get-trivia
Complete OpenAPI definition Effective request declaration (including authentication and referenced schemas):

Cost and request rules

Usage-based pricing. Default request estimate: $0.00089 USD. The final charge depends on actual usage. Your account price may differ; use a request quote where supported.

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

application/json
category
enum<string>

Valid trivia categories for API Ninjas trivia endpoint.

Available options:
artliterature,
language,
sciencenature,
general,
fooddrink,
peopleplaces,
geography,
historyholidays,
entertainment,
toysgames,
music,
mathematics,
religionmythology,
sportsleisure
Examples:

"music"

"geography"

"sciencenature"

limit
integer
default:1

Number of trivia questions to return. Must be between 1 and 30. Default is 1. Note: Requesting more than 1 question is a premium feature.

Required range: 1 <= x <= 30
Examples:

1

5

10

Response

Tool result data

trivia
object[]
required