feat: start a project from another one's configuration
Creating a project can name one the creator owns or administers: its statuses, transitions, types, areas, custom fields and automation rules are copied once (paused rules stay paused; rules assigning to someone who is not in the new project are left out). GraphQL templateProjectId, REST template (id or key), MCP create_project template, and a select in the web's new-project form. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -1729,6 +1729,11 @@ export interface components {
|
||||
* @default false
|
||||
*/
|
||||
isPublic: boolean;
|
||||
/**
|
||||
* @description A project you own or administer (id or key) to start from: its statuses, transitions, types, areas, custom fields and automation rules are copied
|
||||
* @example API
|
||||
*/
|
||||
template?: string | null;
|
||||
};
|
||||
CommandResultDto: {
|
||||
/** @description Id of the aggregate written */
|
||||
|
||||
@@ -40,7 +40,7 @@ export class ProjectsResolver {
|
||||
@Tool({
|
||||
name: 'create_project',
|
||||
description:
|
||||
'Create a project; the user becomes its owner. The key prefixes its tickets (WEB → WEB-1) and cannot change later.',
|
||||
'Create a project; the user becomes its owner. The key prefixes its tickets (WEB → WEB-1) and cannot change later. With template, it starts with the statuses, transitions, types, areas, custom fields and automation rules of that project.',
|
||||
paramsSchema: z.object({
|
||||
key: z
|
||||
.string()
|
||||
@@ -52,6 +52,12 @@ export class ProjectsResolver {
|
||||
.boolean()
|
||||
.default(false)
|
||||
.describe('Anyone can read it, also without signing in'),
|
||||
template: z
|
||||
.string()
|
||||
.optional()
|
||||
.describe(
|
||||
'Key of a project the user owns or administers to copy its configuration and automation rules from',
|
||||
),
|
||||
}),
|
||||
annotations: { readOnlyHint: false, destructiveHint: false },
|
||||
})
|
||||
@@ -61,6 +67,7 @@ export class ProjectsResolver {
|
||||
name: string;
|
||||
description?: string;
|
||||
isPublic: boolean;
|
||||
template?: string;
|
||||
},
|
||||
ctx: McpContext,
|
||||
) {
|
||||
|
||||
Reference in New Issue
Block a user