MCPcopy Create free account
hub / github.com/appdevforall/CodeOnTheGo / res_ok

Function res_ok

subprojects/llama.cpp/tools/server/server-models.cpp:753–756  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

751//
752
753static void res_ok(std::unique_ptr<server_http_res> & res, const json & response_data) {
754 res->status = 200;
755 res->data = safe_json_to_str(response_data);
756}
757
758static void res_err(std::unique_ptr<server_http_res> & res, const json & error_data) {
759 res->status = json_value(error_data, "code", 500);

Callers 1

init_routesMethod · 0.85

Calls 1

safe_json_to_strFunction · 0.85

Tested by

no test coverage detected