NeoGraph 0.10.0
A C++17 Graph Agent Engine Library — LangGraph for C++
Loading...
Searching...
No Matches
endpoint.h File Reference

URL → (host, port, path-prefix, tls) decomposition for async_post. More...

#include <string>
Include dependency graph for endpoint.h:

Go to the source code of this file.

Classes

struct  neograph::async::AsyncEndpoint
 Result of decomposing a URL into the pieces async_post needs. More...
 

Functions

AsyncEndpoint neograph::async::split_async_endpoint (const std::string &base_url)
 Parse a base URL like https://api.openai.com or http://localhost:8080/v1.
 

Detailed Description

URL → (host, port, path-prefix, tls) decomposition for async_post.

Stage 3 / Semester 2.8 — hoisted from three near-identical copies that accumulated in openai_provider.cpp, schema_provider.cpp, and mcp/client.cpp during Semester 2.3-2.6. Each provider parses its configured base_url into the shape neograph::async::async_post wants (host/port/path/tls separately, unlike httplib which takes the scheme+authority verbatim).

Header-only — the function is small and used at most once per request.

Definition in file endpoint.h.

Function Documentation

◆ split_async_endpoint()

AsyncEndpoint neograph::async::split_async_endpoint ( const std::string &  base_url)
inline

Parse a base URL like https://api.openai.com or http://localhost:8080/v1.

Returns an AsyncEndpoint with the pieces split out. Tolerant of missing scheme (defaults to http, non-tls) and missing path (prefix empty).

Definition at line 35 of file endpoint.h.

References neograph::async::split_async_endpoint().

Referenced by neograph::async::split_async_endpoint().