List the prompts defined in the source of a project, a branch or an environment to find one to use or edit; returns every prompt with the source files that could not be read as prompts. Requires project.agents.read.
Arguments
projectReferenceString!requiredsourceTargetKindSourceTargetKindThe source to read; default runtimeTargetKind, else project. One of
project,main_branch,environment,preview_branch.runtimeTargetKindRuntimeTargetKindUsed as the source to read when sourceTargetKind is omitted. One of
main_branch,environment,preview_branch.targetEnvironmentIdIDRequired with the kind environment.
targetBranchIdIDRequired with the kind preview_branch.
Responses
query Prompts($projectReference: String!) { prompts(projectReference: $projectReference) { data { id name description sourcePath editMode } pageInfo { hasNextPage hasPreviousPage startCursor endCursor } diagnostics { kind severity sourceKind sourcePath sourceId code message details } }}{ "data": { "prompts": { "data": [ { "id": "string", "name": "string", "description": "string", "sourcePath": "string", "editMode": "structured" } ], "pageInfo": { "hasNextPage": false, "hasPreviousPage": false, "startCursor": "string", "endCursor": "string" }, "diagnostics": [ { "kind": "string", "severity": "warning", "sourceKind": "string", "sourcePath": "string", "sourceId": "string", "code": "string", "message": "string", "details": {} } ] } }}The PromptList! in data.prompts.