QuickSerp API Documentation

Welcome to the QuickSerp API documentation. Our API provides access to search engine results, URL scraping, and YouTube transcript services.

API Base URL

https://quickserp.com/api

Authentication

All API requests require authentication using a Bearer token. Include your API key in the Authorization header:

Authorization: Bearer YOUR_API_KEY

Rate Limiting and Credits

Each API request consumes 1 credit from your balance. If your credit balance reaches 0, requests will return a 402 Payment Required status code.

Google Search API

Retrieve Google search results including organic results, related questions, and related searches.

Endpoint

GET /api/google

Query Parameters

  • q (required) - Search query string
  • country (optional) - Country/region for search results (default: "US")
  • lang (optional) - Language/location for search results (default: "en")
  • num (optional) - Number of results to return (default: "10")

Notes

  • URL-like entries are automatically filtered from related searches
  • Response is not cached
  • Each request consumes 1 credit from your balance

Example Requests

curl -X GET "https://quickserp.com/api/google?q=search+term" \
-H "Authorization: Bearer YOUR_API_KEY"

Response

{
  "organicResults": [
    {
      "position": 1,
      "title": "Result title",
      "link": "https://example.com",
      "snippet": "Result description",
      "displayedLink": "https://example.com"
    }
  ],
  "peopleAlsoAskedFor": ["Related question 1", "Related question 2"],
  "relatedSearches": ["Related search 1", "Related search 2"]
}

URL Scraping API

Extract content from any webpage in a clean, readable markdown format. Uses multiple fallback methods to ensure reliable content extraction.

Endpoint

GET /api/scrape-url

Query Parameters

  • url (required) - URL to scrape (max length: 2048 characters)

Notes

  • Content is automatically converted to markdown format
  • Scripts, styles, iframes, and other non-content elements are removed
  • Content longer than 60,000 characters is truncated
  • Response is cached for 1 hour with a stale-while-revalidate period of 24 hours
  • Each request consumes 1 credit from your balance

Example Requests

curl -X GET "https://quickserp.com/api/scrape-url?url=https://example.com" \
-H "Authorization: Bearer YOUR_API_KEY"

Response

{
  "title": "Page Title",
  "url": "https://example.com",
  "markdown": "Extracted content in markdown format (truncated at 60,000 characters)"
}

YouTube Transcript API

Extract transcripts from YouTube videos. Supports both youtube.com and youtu.be URL formats.

Endpoint

GET /api/youtube-transcript

Query Parameters

  • url (required) - Full YouTube video URL. Supports both formats:
    • youtube.com: https://www.youtube.com/watch?v=VIDEO_ID
    • youtu.be: https://youtu.be/VIDEO_ID

Example Requests

curl -X GET "https://quickserp.com/api/youtube-transcript?url=https://www.youtube.com/watch?v=VIDEO_ID" \
-H "Authorization: Bearer YOUR_API_KEY"

Response

{
  "message": "Video details fetched successfully",
  "transcripts": "This is the full transcript text with music indicators filtered out",
  "video_title": "Title of the YouTube video"
}

Error Responses

  • 400 Bad Request - When YouTube URL is missing or invalid
  • 401 Unauthorized - When session is invalid or API key is missing/invalid
  • 402 Payment Required - When credit balance is insufficient
  • 500 Internal Server Error - When transcript service fails, no transcript is found, or empty response received

Notes

  • Music indicators like [संगीत] and [Music] are automatically filtered out from the transcript
  • Video title is extracted from the transcript service response
  • Response is cached for 1 hour with a stale-while-revalidate period of 24 hours
  • Each request consumes 1 credit from your balance
  • The service uses youtubetotranscript.com as the transcript provider

Error Responses

All endpoints may return the following error responses:

  • 400 Bad Request - Missing or invalid parameters
  • 401 Unauthorized - Missing or invalid API key, or invalid session
  • 402 Payment Required - Insufficient credit balance
  • 404 Not Found - Resource not found or no content available
  • 500 Internal Server Error - Server error or service failure
{
  "error": "Error message description",
  "currentBalance": 0,  // Only included in 402 responses
  "requiredBalance": 1  // Only included in 402 responses
}