import-functions-parse-before-dispatch
IN premise
API import functions (`import_json`, `import_beliefs`, `import_agent`) read and parse files into structured data in the API layer before delegating to `PgApi` — PgApi never receives raw file paths
Summary
The API layer handles all file reading and parsing itself, so PgApi only ever receives already-structured data like parsed JSON objects or belief arrays. This means PgApi has no file system dependencies and can be tested or replaced without needing access to the original files.
Details
| Source | entries/2026/05/11/tests-test_pg_dispatch.md |