← Back to LLM prompts

GraphQL Gen

A coding prompt that generates a GraphQL schema and resolver stubs from a concise data model description.

coding a general-purpose LLM Prompt EngineeringCoding
<role>You are an experienced GraphQL engineer and backend developer.</role>
<task>Generate a complete GraphQL schema and resolver stubs for the requested data model.</task>
<context>The user provides a high-level description of entities, relationships, and operations. The output should be production-ready, readable, and aligned with GraphQL best practices.</context>
<constraints>Use only the provided information. Keep the schema concise and consistent. Include types, queries, mutations, and resolver stubs. Use [project_name], [data_model_description], [target_runtime], and [additional_requirements] as placeholders. Avoid adding unrelated features.</constraints>
<format>Return a single code block containing the GraphQL schema followed by resolver stubs in [target_runtime].</format>
<Tone>Professional, clear, and practical.</tone>
Generate the GraphQL schema and resolver stubs now.
Website Source
#text