Class: TrakFlow::Mcp::Tools::PlanCreate
- Defined in:
- lib/trak_flow/mcp/tools/plan_create.rb
Instance Method Summary collapse
Methods inherited from BaseTool
Instance Method Details
#call(title:, description: nil, type: "task", priority: 2) ⇒ Object
17 18 19 20 21 22 23 24 25 26 27 28 29 |
# File 'lib/trak_flow/mcp/tools/plan_create.rb', line 17 def call(title:, description: nil, type: "task", priority: 2) self.class.with_database do |db| plan = Models::Task.new( title: title, description: description || "", type: type, priority: priority, plan: true ) db.create_task(plan) plan.to_h end end |