{"openapi":"3.1.0","info":{"title":"Apizie","version":"2.0.0","description":"One API key, one envelope, many public data sources."},"servers":[{"url":"https://apizie.tech"}],"security":[{"ApiKeyAuth":[]}],"paths":{"/v1/ai:fungenerators-trivia/get-trivia":{"get":{"operationId":"ai_fungenerators_trivia_get_trivia","summary":"Get a Trivia entry for a given id. Retrieves a trivia question and answer based on the id.","description":"GET /trivia","tags":["ai"],"parameters":[{"name":"id","in":"query","required":false,"description":"ID of the trivia to fetch","schema":{"type":"string","description":"ID of the trivia to fetch"}}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}}},"4XX":{"$ref":"#/components/responses/Error"},"5XX":{"$ref":"#/components/responses/Error"}},"x-apizie-cache-ttl":60,"x-apizie-min-plan":null,"x-apizie-bulk":true,"x-apizie-status":"byok"}},"/v1/ai:fungenerators-trivia/put-trivia":{"post":{"operationId":"ai_fungenerators_trivia_put_trivia","summary":"Create a random Trivia entry.","description":"PUT /trivia","tags":["ai"],"parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["question","category","answer"],"properties":{"question":{"type":"string","description":"Trivia Question"},"category":{"type":"string","description":"Category of the trivia"},"answer":{"type":"string","description":"Answer(s) to the trivia question"}}}}}},"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}}},"4XX":{"$ref":"#/components/responses/Error"},"5XX":{"$ref":"#/components/responses/Error"}},"x-apizie-cache-ttl":0,"x-apizie-min-plan":null,"x-apizie-bulk":false,"x-apizie-status":"byok"}},"/v1/ai:fungenerators-trivia/delete-trivia":{"post":{"operationId":"ai_fungenerators_trivia_delete_trivia","summary":"Create a random Trivia entry.","description":"DELETE /trivia","tags":["ai"],"parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["id"],"properties":{"id":{"type":"string","description":"Trivia ID"}}}}}},"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}}},"4XX":{"$ref":"#/components/responses/Error"},"5XX":{"$ref":"#/components/responses/Error"}},"x-apizie-cache-ttl":0,"x-apizie-min-plan":null,"x-apizie-bulk":false,"x-apizie-status":"byok"}},"/v1/ai:fungenerators-trivia/get-trivia-categories":{"get":{"operationId":"ai_fungenerators_trivia_get_trivia_categories","summary":"Get a random Trivia.","description":"GET /trivia/categories","tags":["ai"],"parameters":[{"name":"start","in":"query","required":false,"description":"start","schema":{"type":"integer","description":"start"}}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}}},"4XX":{"$ref":"#/components/responses/Error"},"5XX":{"$ref":"#/components/responses/Error"}},"x-apizie-cache-ttl":60,"x-apizie-min-plan":null,"x-apizie-bulk":true,"x-apizie-status":"byok"}},"/v1/ai:fungenerators-trivia/get-trivia-random":{"get":{"operationId":"ai_fungenerators_trivia_get_trivia_random","summary":"Get a random trivia for a given category(optional)","description":"GET /trivia/random","tags":["ai"],"parameters":[{"name":"category","in":"query","required":false,"description":"Category to get the trivia from","schema":{"type":"string","description":"Category to get the trivia from"}}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}}},"4XX":{"$ref":"#/components/responses/Error"},"5XX":{"$ref":"#/components/responses/Error"}},"x-apizie-cache-ttl":60,"x-apizie-min-plan":null,"x-apizie-bulk":true,"x-apizie-status":"byok"}},"/v1/ai:fungenerators-trivia/get-trivia-search":{"get":{"operationId":"ai_fungenerators_trivia_get_trivia_search","summary":"Search for random trivia which has the text in the query, for a given category(optional).","description":"GET /trivia/search","tags":["ai"],"parameters":[{"name":"query","in":"query","required":false,"description":"Text to search for in the trivia","schema":{"type":"string","description":"Text to search for in the trivia"}},{"name":"category","in":"query","required":false,"description":"Category to get the trivia from","schema":{"type":"string","description":"Category to get the trivia from"}}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}}},"4XX":{"$ref":"#/components/responses/Error"},"5XX":{"$ref":"#/components/responses/Error"}},"x-apizie-cache-ttl":60,"x-apizie-min-plan":null,"x-apizie-bulk":true,"x-apizie-status":"byok"}}},"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"x-api-key"}},"schemas":{"RunEnvelope":{"type":"object","required":["project","data","timestamp"],"properties":{"project":{"type":"string","example":"dev-tools:hash"},"data":{},"timestamp":{"type":"string","format":"date-time"}}},"ErrorEnvelope":{"type":"object","properties":{"content":{},"message":{"type":"string"},"errors":{"type":"array","items":{}},"error":{"type":"object","properties":{"code":{"type":"string"},"message":{"type":"string"}}}}}},"responses":{"Error":{"description":"Invalid key, plan gate, rate limit or upstream failure","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}}}}}