assess_create_collection
Create a new collection in the Assess realm to organize tasks, projects, and ideas using the ADD framework for structured task management.
Instructions
Create a new collection in Assess realm.
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| collectionName | Yes | Collection name |
Implementation Reference
- src/index.ts:307-317 (registration)Tool registration including name, description, and input schema definition.{ name: 'assess_create_collection', description: 'Create a new collection in Assess realm.', inputSchema: { type: 'object', properties: { collectionName: { type: 'string', description: 'Collection name' } }, required: ['collectionName'] } },
- src/index.ts:1326-1330 (handler)The main handler function that executes the tool. Currently a mock implementation that generates a record name and returns a success message. In production, this would use CloudKitService.saveRecord().private async createCollection(collectionName: string) { const recordName = `collection_${uuidv4()}`; // Mock collection creation via CloudKit return { content: [{ type: 'text', text: `Collection "${collectionName}" created with recordName: ${recordName}` }] }; }
- src/index.ts:165-179 (schema)TypeScript interface defining the structure of a Collections record for CloudKit, used in create operations.interface ZenTaskticCollection { recordName?: string; recordType: 'Collections'; fields: { collectionName: { value: string }; // Collection name uniqueId: { value: string }; // UUID, max 58 chars creationDate?: { value: number }; // Timestamp lastModified: { value: number }; // Timestamp // References (relationships in Core Data) ideas?: { value: CKReference[] }; // List of references to Ideas records projects?: { value: CKReference[] }; // List of references to Projects records tasks?: { value: CKReference[] }; // List of references to Task records }; }
- src/index.ts:677-679 (handler)Dispatch handler in the main tool switch statement that validates arguments and calls the createCollection method.case 'assess_create_collection': this.validateArgs(args, ['collectionName']); return await this.createCollection(args.collectionName);
- Supporting method in CloudKitService for querying collections, which would be used alongside create operations in a full implementation.async getCollections(): Promise<any[]> { return this.queryRecords('Collections', { sortBy: [{ fieldName: 'collectionName', ascending: true }] }); }