(sample_form_doc: deps.SampleFormDocDep)
| 164 | |
| 165 | @router.post("/create-sample-doc") |
| 166 | def create_sample_doc(sample_form_doc: deps.SampleFormDocDep) -> dict: |
| 167 | form_doc_path = settings.BEANCOUNT_DIR / ".beanhub" / "forms.yaml" |
| 168 | if form_doc_path.exists(): |
| 169 | return dict(code="already-exists") |
| 170 | form_doc_path.parent.mkdir(parents=True, exist_ok=True) |
| 171 | form_doc_path.write_text(sample_form_doc) |
| 172 | return dict(code="ok") |
nothing calls this directly
no outgoing calls
no test coverage detected