Create a prompt source file in the project source or a preview branch so agents and clients can reuse its text; returns the prompt source document. Requires project.agents.write.
Arguments
projectReferenceString!requiredinputCreatePromptInput!requiredinput.idString!requiredBecomes the file name and the prompt id.
input.descriptionStringinput.contentString!requiredinput.sourceTargetKindWriteTargetKindThe source to write; default project. One of
project,preview_branch.input.targetBranchIdIDRequired with the kind preview_branch.
Responses
mutation CreatePrompt($projectReference: String!, $input: CreatePromptInput!) { createPrompt(projectReference: $projectReference, input: $input) { id name description content sourcePath source editMode sourceOnlyReasons }}{ "data": { "createPrompt": { "id": "string", "name": "string", "description": "string", "content": "string", "sourcePath": "string", "source": "string", "editMode": "structured", "sourceOnlyReasons": [ "string" ] } }}The PromptSource! in data.createPrompt.