Skip to content

fix: flapi_create_endpoint persists the endpoint and accepts a template (#155) - #177

Merged
jrosskopf merged 1 commit into
mainfrom
fix/gh-155-mcp-create-endpoint
Oct 2, 2026
Merged

jrosskopf merged 1 commit into
mainfrom
fix/gh-155-mcp-create-endpoint

Conversation

@jrosskopf

@jrosskopf jrosskopf commented Oct 2, 2026 •

Copy link
Copy Markdown
Contributor

Summary

  • Create declared only path and read the undeclared template_source; the endpoint lived only in memory, so update_template wrote to the directory and reload found nothing
  • Now declares path/method/template-source/connection, validates, writes <slug>.yaml + a placeholder SQL, and registers it: serves, reloads, survives restart
  • template-source outside the templates directory is rejected

Test plan

  • test_mcp_create_endpoint.py (6 tests, all failed before): schema, full create->update->reload->serve, restart persistence, default template, traversal
  • Unit 808/809 (1 skipped); mcp config tools/workflow/dry-run suites

Closes #155

🤖 Generated with Claude Code


View with [code]smith Autofix with [code]smith
Need help on this PR? Tag @codesmith-bot with what you need. Autofix is disabled.

…te (#155)

- Declare path/method/template-source/connection; read template-source
- Write <slug>.yaml and a placeholder SQL file so update_template, reload and restart work
- Validate the endpoint; reject template-source outside the templates directory
- End-to-end test over /mcp/jsonrpc incl. serve + restart
- Closes #155
@jrosskopf
jrosskopf merged commit 7dcc973 into main Oct 2, 2026
9 checks passed
@jrosskopf
jrosskopf deleted the fix/gh-155-mcp-create-endpoint branch October 2, 2026 06:35
jrosskopf added a commit that referenced this pull request Oct 2, 2026
fix: flapi_delete_endpoint removes the endpoint YAML; remove test files committed in #177
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

MCP config tools: an endpoint created via flapi_create_endpoint can't be given a template, persisted or served

1 participant