dataforseo_labs_search_intent
Analyze search intent for keywords to identify user goals as informational, navigational, commercial, or transactional with probability scores.
Instructions
This endpoint will provide you with search intent data for up to 1,000 keywords. For each keyword that you specify when setting a task, the API will return the keyword's search intent and intent probability. Besides the highest probable search intent, the results will also provide you with other likely search intent(s) and their probability. Based on keyword data and search results data, our system has been trained to detect four types of search intent: informational, navigational, commercial, transactional.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| keywords | Yes | target keywords required field UTF-8 encoding maximum number of keywords you can specify in this array: 1000 | |
| language_code | No | language code required field Note: this endpoint currently supports the following languages only: ar, zh-TW, cs, da, nl, en, fi, fr, de, he, hi, it, ja, ko, ms, nb, pl, pt, ro, ru, es, sv, th, uk, vi, bg, hr, sr, sl, bs | en |
Implementation Reference
- src/core/modules/dataforseo-labs/tools/google/keyword-research/google-search-intent.tool.ts:62-72 (handler)The handle method implements the core tool logic by sending a POST request to the DataForSEO Labs API endpoint for Google search intent data using the provided keywords and language code, then processes the response or error.async handle(params: any): Promise<any> { try { const response = await this.client.makeRequest('/v3/dataforseo_labs/google/search_intent/live', 'POST', [{ keywords: params.keywords, language_code: params.language_code }]); return this.validateAndFormatResponse(response); } catch (error) { return this.formatErrorResponse(error); } }
- src/core/modules/dataforseo-labs/tools/google/keyword-research/google-search-intent.tool.ts:19-60 (schema)Zod schema defining the tool's input parameters: 'keywords' as an array of strings (up to 1000), and 'language_code' as a string defaulting to 'en' with supported languages listed.getParams(): z.ZodRawShape { return { keywords: z.array(z.string()).describe(`target keywords required field UTF-8 encoding maximum number of keywords you can specify in this array: 1000`), language_code: z.string().default("en").describe( `language code required field Note: this endpoint currently supports the following languages only: ar, zh-TW, cs, da, nl, en, fi, fr, de, he, hi, it, ja, ko, ms, nb, pl, pt, ro, ru, es, sv, th, uk, vi, bg, hr, sr, sl, bs`), }; }
- Registers the GoogleSearchIntentTool (line 43) along with other tools by instantiating them and adding to a record keyed by tool name, with description, params, and a wrapper around the handle method.getTools(): Record<string, ToolDefinition> { const tools = [ new GoogleRankedKeywordsTool(this.dataForSEOClient), new GoogleDomainCompetitorsTool(this.dataForSEOClient), new GoogleDomainRankOverviewTool(this.dataForSEOClient), new GoogleKeywordsIdeasTool(this.dataForSEOClient), new GoogleRelatedKeywordsTool(this.dataForSEOClient), new GoogleKeywordsSuggestionsTool(this.dataForSEOClient), new GoogleHistoricalSERP(this.dataForSEOClient), new GoogleSERPCompetitorsTool(this.dataForSEOClient), new GoogleBulkKeywordDifficultyTool(this.dataForSEOClient), new GoogleSubdomainsTool(this.dataForSEOClient), new GoogleKeywordOverviewTool(this.dataForSEOClient), new GoogleTopSearchesTool(this.dataForSEOClient), new GoogleSearchIntentTool(this.dataForSEOClient), new GoogleKeywordsForSiteTool(this.dataForSEOClient), new GoogleDomainIntersectionsTool(this.dataForSEOClient), new GoogleHistoricalDomainRankOverviewTool(this.dataForSEOClient), new GooglePageIntersectionsTool(this.dataForSEOClient), new GoogleBulkTrafficEstimationTool(this.dataForSEOClient), new DataForSeoLabsFilterTool(this.dataForSEOClient), new GoogleHistoricalKeywordDataTool(this.dataForSEOClient), // Add more tools here ]; return tools.reduce((acc, tool) => ({ ...acc, [tool.getName()]: { description: tool.getDescription(), params: tool.getParams(), handler: (params: any) => tool.handle(params), }, }), {}); }