How microsoft/cpprestsdk works
The archived C++ REST SDK is a native C++ library for asynchronous cloud client/server communication. Its principal user workflow is to construct an HTTP client, send a request, and receive an asynchronous response; the repository also provides server listening, WebSocket client, OAuth, JSON, URI, stream, and task capabilities. The graph preserves those documented product areas. Some implementation links are dashed because the available excerpts and source index show references, not the runtime calls that would verify control flow.
Main entry points: http_client.h HTTP client API · http_client.cpp Client orchestration · http_msg.h HTTP messages · http_listener.cpp HTTP listener
Components 18
HTTP communication
- HTTP client API
Release/include/cpprest/http_client.h - Client orchestration
Release/src/http/client/http_client.cpp - Client transport
Release/src/http/client/http_client_asio.cpp - HTTP messages
Release/include/cpprest/http_msg.h - HTTP listener
Release/src/http/listener/http_listener.cpp - Server transport
Release/src/http/listener/http_server_asio.cpp - OAuth flows
Release/src/http/oauth/oauth2.cpp
WebSocket client
- WebSocket API
Release/include/cpprest/ws_client.h - WebSocket runtime
Release/src/websockets/client/ws_client.cpp - WebSocket messages
Release/src/websockets/client/ws_msg.cpp
Data and streams
- JSON parsing
Release/src/json/json_parsing.cpp - JSON serialization
Release/src/json/json_serialization.cpp - URI handling
Release/src/uri/uri.cpp - Async streams
Release/include/cpprest/streams.h - File streams
Release/src/streams/fileio_posix.cpp
Async foundation
- PPL tasks
Release/include/pplx/pplxtasks.h - Thread pool
Release/src/pplx/threadpool.cpp
Other components
- SDK user
Connections 16
- SDK user → HTTP client API: sends requests
- SDK user → HTTP listener: serves requests
- SDK user → WebSocket API: opens connection
- HTTP client API → Client orchestration: delegates
- Client orchestration → Client transport: dispatches
- Client orchestration → HTTP messages: handles messages
- HTTP listener → Server transport: uses transport
- HTTP client API → OAuth flows: supports OAuth
Release/include/cpprest/http_client.h - WebSocket API → WebSocket runtime: delegates
Release/src/websockets/client/ws_client.cpp - WebSocket runtime → WebSocket messages: handles messages
- HTTP messages → JSON parsing: supports JSON
Release/include/cpprest/http_msg.h - HTTP messages → Async streams: uses streams
Release/include/cpprest/http_msg.h - HTTP client API → URI handling: uses URI
Release/include/cpprest/http_client.h - File streams → Async streams: provides streams
- Client orchestration → PPL tasks: completes tasks
- Thread pool → PPL tasks: supports execution