MCPcopy Create free account
hub / github.com/DeusData/codebase-memory-mcp / dm_preview_status

Function dm_preview_status

tests/test_doc_mentions.c:4552–4565  ·  view source on GitHub ↗

Return the actual MCP envelope, including structuredContent for JSON, so a * test exercises both transport boundaries instead of a formatter in isolation. */

Source from the content-addressed store, hash-verified

4550/* Return the actual MCP envelope, including structuredContent for JSON, so a
4551 * test exercises both transport boundaries instead of a formatter in isolation. */
4552static yyjson_doc *dm_preview_status(const char *project, bool json) {
4553 cbm_mcp_server_t *srv = cbm_mcp_server_new(NULL);
4554 if (!srv) {
4555 return NULL;
4556 }
4557 char args[1200];
4558 snprintf(args, sizeof(args), "{\"project\":\"%s\",\"diagnostics\":\"full\"%s}", project,
4559 json ? ",\"format\":\"json\"" : "");
4560 char *response = cbm_mcp_handle_tool(srv, "index_status", args);
4561 yyjson_doc *out = response ? yyjson_read(response, strlen(response), 0) : NULL;
4562 free(response);
4563 cbm_mcp_server_free(srv);
4564 return out;
4565}
4566
4567static const char *dm_preview_text(yyjson_doc *envelope) {
4568 yyjson_val *root = envelope ? yyjson_doc_get_root(envelope) : NULL;

Callers 5

dm_preview_bounds_checksFunction · 0.85
dm_preview_text_caseFunction · 0.85
dm_preview_order_checksFunction · 0.85
dm_unknown_reason_checksFunction · 0.85

Calls 3

cbm_mcp_server_newFunction · 0.85
cbm_mcp_handle_toolFunction · 0.85
cbm_mcp_server_freeFunction · 0.85

Tested by

no test coverage detected