NNG_HTTP_REQ_GET_URI(3http)
π NAME π
nng_http_req_get_uri β bestie, this is the one that just hands you the URI of an HTTP request. Like, it returns it. That's the whole job. Slay.
β¨ SYNOPSIS β¨
so first you gotta include the girlies:
#include <nng/nng.h>
#include <nng/supplemental/http/http.h>
const char *nng_http_req_get_uri(nng_http_req *req);
π«Ά oh and hey β this is from the NNG Reference Manual, page nng_http_req_get_uri(3http). Just so you know where we are. iykyk.
π¦ DESCRIPTION π¦
Okay so the way that nng_http_req_get_uri() works is it returns the URI (that's the path, bestie) associated with the HTTP request req.
And ngl it's not just the path β the value you get back includes the path, plus any query information, plus any fragment. The whole package. Main character energy.
So it'll end up looking like a file system path with those optional lil components tacked on the end, like this:
/api/get_info.cgi?name=garrett
literally iconic. that's the vibe. π
π RETURN VALUES π
- The request URI, as a string. That's it, that's the tea. β¨
πΈ ERRORS πΈ
- None. π not a single one. zero errors. we love a low-drama function. π«Ά
π SEE ALSO π
π okay go read the others too, bestie β nng_http_req_set_uri(3http) is literally the other half of this situation and you're gonna need it fr fr.
mwah π that's the whole page β brought to you by the NNG Reference Manual, dated 2026-01-13. nng_http_req_get_uri(3http) out! π¦β¨
π¦ where this page comes from
- alpine 3.24: nng-doc 1.11-r0 Β· MIT
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms