Quick Start Guide
This guide provides straightforward usage instructions for the Smart Search project, enabling users to search internal knowledge or other searchable sources.
Welcome to Smart Search! This guide will help you get started with web search in minutes.
📋 Prerequisites — Click to expand setup requirements
Before you begin, make sure you have:
A Smart Search Token — Required for authentication
Service Access — Ensure the Smart Search service is available
🔑 Authentication
Generate a Smart Search Token by following the instructions in 👉 Generate Access Token.
Once obtained, store it securely and include it in the Authorization header of every request:
export SMARTSEARCH_TOKEN="your-access-token"✅ Service Availability
Verify that Smart Search is running and accessible:
curl -X GET "https://search-api.gdplabs.id/health-check"Expected response:
{"message":"I'm alive"}Your First Web Search
Choose one of the three integration methods below to get started:
📦 Option 1: SDK (Python)
SDK Integration Guide — Ideal for Python developers
1. Set Environment Variables:
export SMARTSEARCH_BASE_URL="https://search-api.gdplabs.id"
export SMARTSEARCH_TOKEN="your-access-token"2. Install the SDK:
git clone https://github.com/GDP-ADMIN/smart-search-sdk.git
cd smart-search-sdk/python/smart-search-sdk
pip install .3. Perform a Web Search:
import asyncio
import os
from smart_search_sdk.web.client import WebSearchClient
from smart_search_sdk.web.models import GetWebSearchResultsRequest
async def main():
client = WebSearchClient(base_url=os.getenv("SMARTSEARCH_BASE_URL"))
await client.authenticate(token=os.getenv("SMARTSEARCH_TOKEN"))
result = await client.search_web(GetWebSearchResultsRequest(query="gdp labs", size=5))
print(result)
asyncio.run(main())More details on Smart Search SDK.
🔌 Option 2: MCP
MCP Integration Guide — Ideal for agentic systems and AI assistants
Integrate Smart Search into any MCP-compatible system (Cursor, Windsurf, VS Code, etc.) for agent-based workflows.
Installation
For Cursor:
Open Cursor Settings
Go to
Features>MCP ServersClick
+ Add new global MCP serverEnter the following configuration:
{
"mcpServers": {
"smart_search_mcp": {
"url": "https://search-api.gdplabs.id/mcp/",
"headers": {
"Authorization": "Bearer <SMARTSEARCH_TOKEN>"
}
}
}
}Replace <SMARTSEARCH_TOKEN> with your Smart Search Token.
For Windsurf:
Add this to your ./.codeium/windsurf/mcp_config.json:
{
"mcpServers": {
"smart_search_mcp": {
"url": "https://search-api.gdplabs.id/mcp/",
"headers": {
"Authorization": "Bearer <SMARTSEARCH_TOKEN>"
}
}
}
}For VS Code:
Open VS Code Settings
Navigate to MCP Servers configuration
Add the Smart Search MCP server with the URL and authorization header
After adding, refresh the MCP server list to see the new tools. The Composer Agent will automatically use Smart Search MCP when appropriate, but you can explicitly request it by describing your web search needs.
Available Tools:
get_web_search_results- Perform web searches with snippets, keypoints, or summariesget_web_search_urls- Get a list of relevant URLsget_web_page- Fetch full web page contentget_web_page_snippets- Extract snippets from a pageget_web_page_keypoints- Generate key insights from a page
See the Smart Search MCP page for full tool documentation.
🌐 Option 3: REST API
REST API Integration Guide — Ideal for direct HTTP access and language-agnostic integrations
Call Smart Search directly via HTTP for maximum flexibility:
Sample Response:
This approach is ideal for quick integrations, custom dashboards, or system-to-system connections where you need full control over HTTP requests and responses.
Quick Reference
Last updated
