GnistAI GnistAI
Log in

Getting Started with Famous Quotes

Famous quotes collection — search by author, keyword, or category, get random quotes.

All Tutorials   |   Overview   |   Playground   |   MCP   |   REST API   |   Home
Reference

Data source: Curated public-domain collection

Overview

Famous Quotes wraps Curated public-domain collection, handling authentication, pagination, and rate limits for you. This tutorial covers all 6 tools with working code examples you can copy and run.

Prerequisites

  1. Sign up at https://context.gnist.ai/signup for a free API key (100 calls/day).
  2. Choose your integration method: MCP protocol or REST API.

Connect via MCP

Add to your MCP client config (Claude Desktop, Cursor, etc.):

MCP Config
{
  "mcpServers": {
    "gnist-famous-quotes": {
      "url": "https://context.gnist.ai/mcp/famous-quotes/",
      "headers": {
        "Gnist-API-Key": "YOUR_API_KEY"
      }
    }
  }
}

Tools (6)

get_random_quote

Get a random famous quote. Returns a quote with author name and category. Optionally filter by category.

ParameterTypeRequiredDescription
categoryanyoptionalFilter by category (e.g. wisdom, science, humor). Omit for any category.
curl -X POST "https://context.gnist.ai/mcp/famous-quotes/" \
  -H "Content-Type: application/json" \
  -H "Gnist-API-Key: YOUR_API_KEY" \
  -d '{"jsonrpc": "2.0", "method": "tools/call", "id": 1, "params": {"name": "get_random_quote", "arguments": {"category": "wisdom"}}}'
import httpx

resp = httpx.post(
    "https://context.gnist.ai/mcp/famous-quotes/",
    headers={"Gnist-API-Key": "YOUR_API_KEY"},
    json={'id': 1,
 'jsonrpc': '2.0',
 'method': 'tools/call',
 'params': {'arguments': {'category': 'wisdom'}, 'name': 'get_random_quote'}},
)
print(resp.json())

search_quotes

Search for famous quotes by keyword. Searches across quote text, author names, and categories. Case-insensitive.

ParameterTypeRequiredDescription
querystringrequiredSearch keyword — matches quote text, author name, or category.
max_resultsanyoptionalMaximum number of results (default: 10, max: 100).
curl -X POST "https://context.gnist.ai/mcp/famous-quotes/" \
  -H "Content-Type: application/json" \
  -H "Gnist-API-Key: YOUR_API_KEY" \
  -d '{"jsonrpc": "2.0", "method": "tools/call", "id": 1, "params": {"name": "search_quotes", "arguments": {"query": "renewable energy"}}}'
import httpx

resp = httpx.post(
    "https://context.gnist.ai/mcp/famous-quotes/",
    headers={"Gnist-API-Key": "YOUR_API_KEY"},
    json={'id': 1,
 'jsonrpc': '2.0',
 'method': 'tools/call',
 'params': {'arguments': {'query': 'renewable energy'},
            'name': 'search_quotes'}},
)
print(resp.json())

get_quotes_by_author

Get all quotes by a specific author. Partial name matching — e.g. "einstein" matches "Albert Einstein".

ParameterTypeRequiredDescription
authorstringrequiredAuthor name (case-insensitive, partial match).
max_resultsanyoptionalMaximum number of results (default: 10, max: 100).
curl -X POST "https://context.gnist.ai/mcp/famous-quotes/" \
  -H "Content-Type: application/json" \
  -H "Gnist-API-Key: YOUR_API_KEY" \
  -d '{"jsonrpc": "2.0", "method": "tools/call", "id": 1, "params": {"name": "get_quotes_by_author", "arguments": {"author": "example"}}}'
import httpx

resp = httpx.post(
    "https://context.gnist.ai/mcp/famous-quotes/",
    headers={"Gnist-API-Key": "YOUR_API_KEY"},
    json={'id': 1,
 'jsonrpc': '2.0',
 'method': 'tools/call',
 'params': {'arguments': {'author': 'example'}, 'name': 'get_quotes_by_author'}},
)
print(resp.json())

list_categories

List all available quote categories. Returns the category names that can be used to filter random quotes.

curl -X POST "https://context.gnist.ai/mcp/famous-quotes/" \
  -H "Content-Type: application/json" \
  -H "Gnist-API-Key: YOUR_API_KEY" \
  -d '{"jsonrpc": "2.0", "method": "tools/call", "id": 1, "params": {"name": "list_categories", "arguments": {}}}'
import httpx

resp = httpx.post(
    "https://context.gnist.ai/mcp/famous-quotes/",
    headers={"Gnist-API-Key": "YOUR_API_KEY"},
    json={'id': 1,
 'jsonrpc': '2.0',
 'method': 'tools/call',
 'params': {'arguments': {}, 'name': 'list_categories'}},
)
print(resp.json())

list_authors

List all authors in the quotes database. Returns author names that can be used to look up quotes by author.

curl -X POST "https://context.gnist.ai/mcp/famous-quotes/" \
  -H "Content-Type: application/json" \
  -H "Gnist-API-Key: YOUR_API_KEY" \
  -d '{"jsonrpc": "2.0", "method": "tools/call", "id": 1, "params": {"name": "list_authors", "arguments": {}}}'
import httpx

resp = httpx.post(
    "https://context.gnist.ai/mcp/famous-quotes/",
    headers={"Gnist-API-Key": "YOUR_API_KEY"},
    json={'id': 1,
 'jsonrpc': '2.0',
 'method': 'tools/call',
 'params': {'arguments': {}, 'name': 'list_authors'}},
)
print(resp.json())

report_feedback

Report a bug, feature request, or general feedback for this data source. Use this when something doesn't work as expected, when you'd like a new feature, or when you have suggestions for improvement. Args: feedback: Describe the issue or suggestion. feedback_type: One of 'bug', 'feature_request', or 'general'.

ParameterTypeRequiredDescription
feedbackstringrequired
feedback_typestringoptional (default: general)
curl -X POST "https://context.gnist.ai/mcp/famous-quotes/" \
  -H "Content-Type: application/json" \
  -H "Gnist-API-Key: YOUR_API_KEY" \
  -d '{"jsonrpc": "2.0", "method": "tools/call", "id": 1, "params": {"name": "report_feedback", "arguments": {"feedback": "example"}}}'
import httpx

resp = httpx.post(
    "https://context.gnist.ai/mcp/famous-quotes/",
    headers={"Gnist-API-Key": "YOUR_API_KEY"},
    json={'id': 1,
 'jsonrpc': '2.0',
 'method': 'tools/call',
 'params': {'arguments': {'feedback': 'example'}, 'name': 'report_feedback'}},
)
print(resp.json())

Common Patterns

Search then retrieve
Use search_quotes to find items, then get_random_quote to get full details. This two-step pattern is common for exploring data before drilling down.
Pagination
Several tools support limit, offset, or page parameters. Start with small limits during development, then increase for production queries.

FAQ

What data does Famous Quotes provide?

Famous quotes collection — search by author, keyword, or category, get random quotes. It exposes 6 tools: get_random_quote, search_quotes, get_quotes_by_author, list_categories, list_authors, report_feedback.

What do I need to get started?

A Gnist API key (free tier: 100 calls/day). Sign up at https://context.gnist.ai/signup.

What format does the Famous Quotes API return?

JSON, via either MCP protocol (JSON-RPC 2.0) or REST API.

Next Steps

Related Tutorials