Add response access and stop mangling non-HTTP request payloads

Stored responses were unreachable from the CLI even though the model
layer has had list/get/delete all along. After a send, an agent could
only see the body it just streamed: no status, no timing, no history.
`yaak response list|show|body|delete` closes that. `show` and `body`
accept a request ID as shorthand for its most recent response, which is
the common case, and `show` returns status, reason, timing, headers, the
final URL, and any transport error as JSON.

`request create` also accepted payloads for request types it cannot
create. A gRPC-shaped payload deserialized into an HttpRequest with the
unknown fields dropped, so the gRPC method name landed in `method`,
`service` vanished, and the result looked like a successful create. It
now rejects a non-`http_request` `model`, and any field that is not part
of the HTTP request schema, pointing at the app instead. `request update`
had the same silent-drop behavior and gets the same check.

The skill now points at `response show` rather than teaching agents to
grep verbose send output for the status line.
This commit is contained in:
Gregory Schier
2026-08-13 22:02:47 -07:00
parent 74369e8f23
commit f53887a114
6 changed files with 254 additions and 4 deletions
+1
View File
@@ -6,6 +6,7 @@ pub mod folder;
pub mod import_export;
pub mod plugin;
pub mod request;
pub mod response;
pub mod send;
pub mod template_function;
pub mod workspace;