Text Analysis

Extract Keywords

Extracts keywords from text using frequency analysis to identify the most significant terms. Access via MCP in Cursor or Windsurf, or call GET /v1/text/keywords directly. Pass any text and get ranked keywords with occurrence counts — useful for content analysis, SEO research, or document summarization in AI workflows.

API Endpoint

GET /v1/text/keywords

Code Examples

curl "https://tinyfn.io/v1/text/keywords" \
  -H "X-API-Key: YOUR_API_KEY"
const response = await fetch('https://tinyfn.io/v1/text/keywords', {
  headers: { 'X-API-Key': 'YOUR_API_KEY' }
});
const data = await response.json();
console.log(data);
import requests

response = requests.get('https://tinyfn.io/v1/text/keywords',
    headers={'X-API-Key': 'YOUR_API_KEY'})
data = response.json()
print(data)

Use via MCP

Add to your AI agent

Connect your AI agent (Claude, Cursor, Windsurf, etc.) to TinyFn's text analysis tools:

{
  "mcpServers": {
    "tinyfn-text": {
      "url": "https://tinyfn.io/mcp/text",
      "headers": {
        "X-API-Key": "YOUR_API_KEY"
      }
    }
  }
}

Learn more about MCP setup →

FAQ

How does frequency-based keyword extraction work?

It counts word occurrences while filtering out common stop words (the, and, is), then ranks remaining terms by frequency. More sophisticated than simple word counting since it excludes non-meaningful words.

Can I use this for SEO keyword research with Claude or Cursor?

Yes, through MCP integration. Feed article content or competitor pages to extract primary keywords, then use AI agents to analyze keyword density and suggest content optimizations.

What format does the keyword extraction API return?

Returns JSON with keywords ranked by frequency, typically including the term and its count. Format: [{"keyword": "example", "frequency": 5}, {"keyword": "text", "frequency": 3}]

Does it handle different languages or just English?

Depends on the stop word filtering implementation. Most frequency-based extractors work better with English due to built-in English stop word lists, but can process other languages with reduced accuracy.

How is this different from TF-IDF or advanced NLP keyword extraction?

This uses simple frequency counting rather than term frequency-inverse document frequency. It's faster and deterministic but less sophisticated than semantic analysis methods that consider context and document relationships.

Try Extract Keywords Now

Get your free API key and start using Extract Keywords in seconds.

Get Free API Key