Get Recommendation

Get AI-powered starter template recommendations based on natural language queries. This endpoint uses GPT to analyze your requirements and provide personalized template suggestions.

GET /api/recommendation?question=string

Query Parameters

question

A natural language description of your requirements.

Type: string

Required: true

Example queries:

  • "I need a React starter with TypeScript and good documentation"
  • "Looking for a backend template with Docker and testing setup"
  • "Show me starters with authentication and database integration"

Response

Response Fields

question

The original query string.

extracted_query

The structured query parameters extracted by GPT.

starters

Array of matching starter templates.

recommendation

Natural language recommendation explaining the matches.

Example Response

{
  "question": "I need a React starter with TypeScript and good documentation",
  "extracted_query": {
    "technologies": ["React", "TypeScript"],
    "features": ["good documentation"],
    "min_quality": 3,
    "minMatched": 1,
    "limit": 3
  },
  "starters": [...],
  "recommendation": "I would recommend checking out the 'landy-react-template'..."
}

Error Responses

400 Bad Request

Returned when the question parameter is missing.

500 Internal Server Error

Returned when there's an error processing the request or communicating with OpenAI.