No version for distro humble showing jazzy. Known supported distros are highlighted in the buttons above.
Package symbol

cl_http package from SMACC2 repo

smacc2 cl_foundation_pose cl_gcalcli cl_generic_sensor cl_http cl_keyboard cl_lifecycle_node cl_mission_tracker cl_modbus_tcp_relay cl_moveit2z cl_nav2z backward_global_planner backward_local_planner forward_global_planner forward_local_planner nav2z_planners_common pure_spinning_local_planner undo_path_global_planner cl_px4_mr cl_ros2_timer eg_conditional_generator eg_random_generator smacc2_msgs sm_atomic_performance_trace_1 sm_atomic_subscribers_performance_test sm_coretest_action_client_1 sm_coretest_callback_rate_1 sm_coretest_exceptions_1 sm_coretest_features_1 sm_coretest_forced_finish_1 sm_coretest_idle_load_1 sm_coretest_object_churn_1 sm_coretest_poll_shutdown_1 sm_coretest_post_during_exit_1 sm_coretest_reactor_order_1 sm_coretest_signal_key_1 sm_coretest_timer_handoff_1 sm_coretest_transition_speed_1 sm_advanced_recovery_1 sm_atomic sm_atomic_http sm_atomic_lifecycle sm_atomic_mode_states sm_branching sm_cl_gcalcli_test_1 sm_cl_keyboard_unit_test_1 sm_cl_px4_mr_test_1 sm_cl_px4_mr_test_2 sm_cl_px4_mr_test_3 sm_cl_px4_mr_test_4 sm_cl_px4_mr_test_5 sm_cl_ros2_timer_unit_test_1 sm_data_sharing_1 sm_data_sharing_2 sm_modbus_tcp_relay_test_1 sm_mode_state_behavior_1 sm_multi_stage_1 sm_multithread_test_1 sm_nav2_gazebo_test_1 sm_nav2_gazebo_test_2 sm_nav2_gazebo_test_3 sm_nav2_gazebo_test_4 sm_pack_ml sm_panda_cl_moveit2z_cb_inventory sm_panda_cl_moveit2z_cb_inventory_isaacsim sm_retry_logic_1 sm_simple_action_client sm_three_some sr_all_events_go sr_conditional sr_event_countdown

ROS Distro
jazzy

Package Summary

Version 3.1.0
License Apache-2.0
Build type AMENT_CMAKE
Use RECOMMENDED

Repository Summary

Description
Checkout URI https://github.com/robosoft-ai/SMACC2.git
VCS Type git
VCS Version jazzy
Last Updated 2026-11-22
Dev Status DEVELOPED
Released RELEASED
Contributing Help Wanted (-)
Good First Issues (-)
Pull Requests to Review (-)

Package Description

The cl_http package

Maintainers

  • Brett Aldrich

Authors

No additional authors.

HTTP Client (cl_http)

SMACC2 client library for making HTTP/HTTPS requests using Boost.Beast.

Architecture

/home/brettpac/workspaces/isaac_ros-dev/src/SMACC2/smacc2_client_library/cl_http The cl_http follows a pure component-based architecture with three specialized components:

ClHttp (Client - Orchestrator)
├── CpHttpConnectionManager - io_context and thread management
├── CpHttpSessionManager - SSL context and session creation
└── CpHttpRequestExecutor - Request execution and response handling

Components

CpHttpConnectionManager

Responsibility: Manages the asynchronous I/O infrastructure

  • Owns boost::asio::io_context
  • Manages worker thread lifecycle
  • Provides strand for thread-safe operations

Lifetime: State machine scoped (created with ClHttp, destroyed with state machine)

CpHttpSessionManager

Responsibility: Manages HTTP/HTTPS session configuration

  • Parses server URLs (protocol, host, port)
  • Manages SSL context for HTTPS connections
  • Creates session objects (http_session or ssl_http_session)

Lifetime: State machine scoped

CpHttpRequestExecutor

Responsibility: Coordinates HTTP request execution

  • Accepts request parameters (method, path, body, headers)
  • Acquires strand from CpHttpConnectionManager
  • Acquires session from CpHttpSessionManager
  • Executes requests and emits response signals

Lifetime: State machine scoped

Signal Flow

User Code (Behavior)
    ↓
CpHttpRequestExecutor::executeRequest()
    ↓
Session created (http_session/ssl_http_session)
    ↓
Request executed asynchronously
    ↓
Response received
    ↓
CpHttpRequestExecutor::onResponseReceived_ (SmaccSignal)
    ↓ (backward compatibility)
ClHttp::onResponseReceived_ (forwarded)
    ↓
Behavior callback

Usage

Quick Start: Using Base Behaviors

The easiest way to make HTTP requests is using the provided base behaviors:

#include <cl_http/client_behaviors/cb_http_get_request.hpp>

class StHttpRequest : public smacc2::SmaccState<StHttpRequest, SmExample>
{
public:
  using SmaccState::SmaccState;

  void runtimeConfigure() override
  {
    auto behavior = this->configure<cl_http::CbHttpGetRequest>();
  }
};

Custom Behaviors: Component-Based Approach

For custom HTTP behavior, inherit from base class and override response handling:

```cpp #include <cl_http/client_behaviors/cb_http_request.hpp>

class CbCustomRequest : public cl_http::CbHttpRequestBase { public: CbCustomRequest() : CbHttpRequestBase(CpHttpRequestExecutor::HttpMethod::GET) {}

void onResponseReceived(const CpHttpRequestExecutor::TResponse& response) override {

File truncated at 100 lines see the full file

CHANGELOG

Changelog for package cl_http

2.3.19 (2025-06-17)

  • OpenAI example client ported to SMACC (#557)

    • initial commit for openAI example
    • Replaced get with post, added key fetch logic
    • Added ability to modify the body of an http request for the http client
    • Added functionality to encode and send image data to ChatGPT
    • Added APIs to add headers to an outgoing HTTP request
    • HTTP requests can now deal with CDNs

    * Expanded example openAI node to submit a more sophisticated request with an image

    • Using env variable for test iamge location
    • Fixed commit errors
    • Renamed instantiation of HTTP request CB to something more specific to OpenAI
  • Moved HTTP client behaviour to client library. Also added GET and POS… (#549)

    • Moved HTTP client behaviour to client library. Also added GET and POST-specific versions of the smacc HTTP client behaviour to make them easier to use
    • Added copyrights
    • Fixed typos
  • Http client (#522)

    • Ported http work over from smacc1
    • Added example showasing http requests
    • Fixed some typos in the HTTP example
    • Made provision for HTTP GET/POST in the HTTP client
    • Moved HTTP client into the client_libraries folder and made separate compilation units. Modified examples to use this new client

    * Update smacc_action_client_base.hpp Pretty sure this change was made accidently.

    * Update smacc_action_client_base.hpp Messed up first commit

    * Update http_client.cpp Added License to file to clean up format error

    * Update http_client.cpp Found better Copyright & License for CI Format error.

    * Update cb_http_request.hpp Another little format error

    * Update sm_atomic_http.py Somehow a bracket became a cNode

      • Fixed errors with HTTP requests not triggering,
    • Fixed response callback not triggering correctly and causing a crash

    • Fixed example not transitioning back to state 1 after a response has been received

    • Ported http work over from smacc1

    • Added example showasing http requests

    • Fixed some typos in the HTTP example

    • Made provision for HTTP GET/POST in the HTTP client

    • Moved HTTP client into the client_libraries folder and made separate compilation units. Modified examples to use this new client

    * Update http_client.cpp Added License to file to clean up format error

    * Update http_client.cpp Found better Copyright & License for CI Format error.

    * Update cb_http_request.hpp Another little format error

    * Update sm_atomic_http.py Somehow a bracket became a cNode

      • Fixed errors with HTTP requests not triggering,
    • Fixed response callback not triggering correctly and causing a crash

    • Fixed example not transitioning back to state 1 after a response has been received

    • Added helper class to handle server name related interactions

    • Added SSL implementation, need to make provision for SSL and non-SSLD requests

File truncated at 100 lines see the full file

Package Dependencies

System Dependencies

No direct system dependencies.

Dependant Packages

Name Deps
sm_atomic_http

Launch files

No launch files found

Messages

No message files found.

Services

No service files found

Plugins

No plugins found.

Recent questions tagged cl_http at Robotics Stack Exchange

Package symbol

cl_http package from SMACC2 repo

smacc2 cl_foundation_pose cl_gcalcli cl_generic_sensor cl_http cl_keyboard cl_lifecycle_node cl_mission_tracker cl_modbus_tcp_relay cl_moveit2z cl_nav2z backward_global_planner backward_local_planner forward_global_planner forward_local_planner nav2z_planners_common pure_spinning_local_planner undo_path_global_planner cl_px4_mr cl_ros2_timer eg_conditional_generator eg_random_generator smacc2_msgs sm_atomic_performance_trace_1 sm_atomic_subscribers_performance_test sm_coretest_action_client_1 sm_coretest_callback_rate_1 sm_coretest_exceptions_1 sm_coretest_features_1 sm_coretest_forced_finish_1 sm_coretest_idle_load_1 sm_coretest_object_churn_1 sm_coretest_poll_shutdown_1 sm_coretest_post_during_exit_1 sm_coretest_reactor_order_1 sm_coretest_signal_key_1 sm_coretest_timer_handoff_1 sm_coretest_transition_speed_1 sm_advanced_recovery_1 sm_atomic sm_atomic_http sm_atomic_lifecycle sm_atomic_mode_states sm_branching sm_cl_gcalcli_test_1 sm_cl_keyboard_unit_test_1 sm_cl_px4_mr_test_1 sm_cl_px4_mr_test_2 sm_cl_px4_mr_test_3 sm_cl_px4_mr_test_4 sm_cl_px4_mr_test_5 sm_cl_ros2_timer_unit_test_1 sm_data_sharing_1 sm_data_sharing_2 sm_modbus_tcp_relay_test_1 sm_mode_state_behavior_1 sm_multi_stage_1 sm_multithread_test_1 sm_nav2_gazebo_test_1 sm_nav2_gazebo_test_2 sm_nav2_gazebo_test_3 sm_nav2_gazebo_test_4 sm_pack_ml sm_panda_cl_moveit2z_cb_inventory sm_panda_cl_moveit2z_cb_inventory_isaacsim sm_retry_logic_1 sm_simple_action_client sm_three_some sr_all_events_go sr_conditional sr_event_countdown

ROS Distro
jazzy

Package Summary

Version 3.1.0
License Apache-2.0
Build type AMENT_CMAKE
Use RECOMMENDED

Repository Summary

Description
Checkout URI https://github.com/robosoft-ai/SMACC2.git
VCS Type git
VCS Version jazzy
Last Updated 2026-11-22
Dev Status DEVELOPED
Released RELEASED
Contributing Help Wanted (-)
Good First Issues (-)
Pull Requests to Review (-)

Package Description

The cl_http package

Maintainers

  • Brett Aldrich

Authors

No additional authors.

HTTP Client (cl_http)

SMACC2 client library for making HTTP/HTTPS requests using Boost.Beast.

Architecture

/home/brettpac/workspaces/isaac_ros-dev/src/SMACC2/smacc2_client_library/cl_http The cl_http follows a pure component-based architecture with three specialized components:

ClHttp (Client - Orchestrator)
├── CpHttpConnectionManager - io_context and thread management
├── CpHttpSessionManager - SSL context and session creation
└── CpHttpRequestExecutor - Request execution and response handling

Components

CpHttpConnectionManager

Responsibility: Manages the asynchronous I/O infrastructure

  • Owns boost::asio::io_context
  • Manages worker thread lifecycle
  • Provides strand for thread-safe operations

Lifetime: State machine scoped (created with ClHttp, destroyed with state machine)

CpHttpSessionManager

Responsibility: Manages HTTP/HTTPS session configuration

  • Parses server URLs (protocol, host, port)
  • Manages SSL context for HTTPS connections
  • Creates session objects (http_session or ssl_http_session)

Lifetime: State machine scoped

CpHttpRequestExecutor

Responsibility: Coordinates HTTP request execution

  • Accepts request parameters (method, path, body, headers)
  • Acquires strand from CpHttpConnectionManager
  • Acquires session from CpHttpSessionManager
  • Executes requests and emits response signals

Lifetime: State machine scoped

Signal Flow

User Code (Behavior)
    ↓
CpHttpRequestExecutor::executeRequest()
    ↓
Session created (http_session/ssl_http_session)
    ↓
Request executed asynchronously
    ↓
Response received
    ↓
CpHttpRequestExecutor::onResponseReceived_ (SmaccSignal)
    ↓ (backward compatibility)
ClHttp::onResponseReceived_ (forwarded)
    ↓
Behavior callback

Usage

Quick Start: Using Base Behaviors

The easiest way to make HTTP requests is using the provided base behaviors:

#include <cl_http/client_behaviors/cb_http_get_request.hpp>

class StHttpRequest : public smacc2::SmaccState<StHttpRequest, SmExample>
{
public:
  using SmaccState::SmaccState;

  void runtimeConfigure() override
  {
    auto behavior = this->configure<cl_http::CbHttpGetRequest>();
  }
};

Custom Behaviors: Component-Based Approach

For custom HTTP behavior, inherit from base class and override response handling:

```cpp #include <cl_http/client_behaviors/cb_http_request.hpp>

class CbCustomRequest : public cl_http::CbHttpRequestBase { public: CbCustomRequest() : CbHttpRequestBase(CpHttpRequestExecutor::HttpMethod::GET) {}

void onResponseReceived(const CpHttpRequestExecutor::TResponse& response) override {

File truncated at 100 lines see the full file

CHANGELOG

Changelog for package cl_http

2.3.19 (2025-06-17)

  • OpenAI example client ported to SMACC (#557)

    • initial commit for openAI example
    • Replaced get with post, added key fetch logic
    • Added ability to modify the body of an http request for the http client
    • Added functionality to encode and send image data to ChatGPT
    • Added APIs to add headers to an outgoing HTTP request
    • HTTP requests can now deal with CDNs

    * Expanded example openAI node to submit a more sophisticated request with an image

    • Using env variable for test iamge location
    • Fixed commit errors
    • Renamed instantiation of HTTP request CB to something more specific to OpenAI
  • Moved HTTP client behaviour to client library. Also added GET and POS… (#549)

    • Moved HTTP client behaviour to client library. Also added GET and POST-specific versions of the smacc HTTP client behaviour to make them easier to use
    • Added copyrights
    • Fixed typos
  • Http client (#522)

    • Ported http work over from smacc1
    • Added example showasing http requests
    • Fixed some typos in the HTTP example
    • Made provision for HTTP GET/POST in the HTTP client
    • Moved HTTP client into the client_libraries folder and made separate compilation units. Modified examples to use this new client

    * Update smacc_action_client_base.hpp Pretty sure this change was made accidently.

    * Update smacc_action_client_base.hpp Messed up first commit

    * Update http_client.cpp Added License to file to clean up format error

    * Update http_client.cpp Found better Copyright & License for CI Format error.

    * Update cb_http_request.hpp Another little format error

    * Update sm_atomic_http.py Somehow a bracket became a cNode

      • Fixed errors with HTTP requests not triggering,
    • Fixed response callback not triggering correctly and causing a crash

    • Fixed example not transitioning back to state 1 after a response has been received

    • Ported http work over from smacc1

    • Added example showasing http requests

    • Fixed some typos in the HTTP example

    • Made provision for HTTP GET/POST in the HTTP client

    • Moved HTTP client into the client_libraries folder and made separate compilation units. Modified examples to use this new client

    * Update http_client.cpp Added License to file to clean up format error

    * Update http_client.cpp Found better Copyright & License for CI Format error.

    * Update cb_http_request.hpp Another little format error

    * Update sm_atomic_http.py Somehow a bracket became a cNode

      • Fixed errors with HTTP requests not triggering,
    • Fixed response callback not triggering correctly and causing a crash

    • Fixed example not transitioning back to state 1 after a response has been received

    • Added helper class to handle server name related interactions

    • Added SSL implementation, need to make provision for SSL and non-SSLD requests

File truncated at 100 lines see the full file

Package Dependencies

System Dependencies

No direct system dependencies.

Dependant Packages

Name Deps
sm_atomic_http

Launch files

No launch files found

Messages

No message files found.

Services

No service files found

Plugins

No plugins found.

Recent questions tagged cl_http at Robotics Stack Exchange

No version for distro kilted showing jazzy. Known supported distros are highlighted in the buttons above.
Package symbol

cl_http package from SMACC2 repo

smacc2 cl_foundation_pose cl_gcalcli cl_generic_sensor cl_http cl_keyboard cl_lifecycle_node cl_mission_tracker cl_modbus_tcp_relay cl_moveit2z cl_nav2z backward_global_planner backward_local_planner forward_global_planner forward_local_planner nav2z_planners_common pure_spinning_local_planner undo_path_global_planner cl_px4_mr cl_ros2_timer eg_conditional_generator eg_random_generator smacc2_msgs sm_atomic_performance_trace_1 sm_atomic_subscribers_performance_test sm_coretest_action_client_1 sm_coretest_callback_rate_1 sm_coretest_exceptions_1 sm_coretest_features_1 sm_coretest_forced_finish_1 sm_coretest_idle_load_1 sm_coretest_object_churn_1 sm_coretest_poll_shutdown_1 sm_coretest_post_during_exit_1 sm_coretest_reactor_order_1 sm_coretest_signal_key_1 sm_coretest_timer_handoff_1 sm_coretest_transition_speed_1 sm_advanced_recovery_1 sm_atomic sm_atomic_http sm_atomic_lifecycle sm_atomic_mode_states sm_branching sm_cl_gcalcli_test_1 sm_cl_keyboard_unit_test_1 sm_cl_px4_mr_test_1 sm_cl_px4_mr_test_2 sm_cl_px4_mr_test_3 sm_cl_px4_mr_test_4 sm_cl_px4_mr_test_5 sm_cl_ros2_timer_unit_test_1 sm_data_sharing_1 sm_data_sharing_2 sm_modbus_tcp_relay_test_1 sm_mode_state_behavior_1 sm_multi_stage_1 sm_multithread_test_1 sm_nav2_gazebo_test_1 sm_nav2_gazebo_test_2 sm_nav2_gazebo_test_3 sm_nav2_gazebo_test_4 sm_pack_ml sm_panda_cl_moveit2z_cb_inventory sm_panda_cl_moveit2z_cb_inventory_isaacsim sm_retry_logic_1 sm_simple_action_client sm_three_some sr_all_events_go sr_conditional sr_event_countdown

ROS Distro
jazzy

Package Summary

Version 3.1.0
License Apache-2.0
Build type AMENT_CMAKE
Use RECOMMENDED

Repository Summary

Description
Checkout URI https://github.com/robosoft-ai/SMACC2.git
VCS Type git
VCS Version jazzy
Last Updated 2026-11-22
Dev Status DEVELOPED
Released RELEASED
Contributing Help Wanted (-)
Good First Issues (-)
Pull Requests to Review (-)

Package Description

The cl_http package

Maintainers

  • Brett Aldrich

Authors

No additional authors.

HTTP Client (cl_http)

SMACC2 client library for making HTTP/HTTPS requests using Boost.Beast.

Architecture

/home/brettpac/workspaces/isaac_ros-dev/src/SMACC2/smacc2_client_library/cl_http The cl_http follows a pure component-based architecture with three specialized components:

ClHttp (Client - Orchestrator)
├── CpHttpConnectionManager - io_context and thread management
├── CpHttpSessionManager - SSL context and session creation
└── CpHttpRequestExecutor - Request execution and response handling

Components

CpHttpConnectionManager

Responsibility: Manages the asynchronous I/O infrastructure

  • Owns boost::asio::io_context
  • Manages worker thread lifecycle
  • Provides strand for thread-safe operations

Lifetime: State machine scoped (created with ClHttp, destroyed with state machine)

CpHttpSessionManager

Responsibility: Manages HTTP/HTTPS session configuration

  • Parses server URLs (protocol, host, port)
  • Manages SSL context for HTTPS connections
  • Creates session objects (http_session or ssl_http_session)

Lifetime: State machine scoped

CpHttpRequestExecutor

Responsibility: Coordinates HTTP request execution

  • Accepts request parameters (method, path, body, headers)
  • Acquires strand from CpHttpConnectionManager
  • Acquires session from CpHttpSessionManager
  • Executes requests and emits response signals

Lifetime: State machine scoped

Signal Flow

User Code (Behavior)
    ↓
CpHttpRequestExecutor::executeRequest()
    ↓
Session created (http_session/ssl_http_session)
    ↓
Request executed asynchronously
    ↓
Response received
    ↓
CpHttpRequestExecutor::onResponseReceived_ (SmaccSignal)
    ↓ (backward compatibility)
ClHttp::onResponseReceived_ (forwarded)
    ↓
Behavior callback

Usage

Quick Start: Using Base Behaviors

The easiest way to make HTTP requests is using the provided base behaviors:

#include <cl_http/client_behaviors/cb_http_get_request.hpp>

class StHttpRequest : public smacc2::SmaccState<StHttpRequest, SmExample>
{
public:
  using SmaccState::SmaccState;

  void runtimeConfigure() override
  {
    auto behavior = this->configure<cl_http::CbHttpGetRequest>();
  }
};

Custom Behaviors: Component-Based Approach

For custom HTTP behavior, inherit from base class and override response handling:

```cpp #include <cl_http/client_behaviors/cb_http_request.hpp>

class CbCustomRequest : public cl_http::CbHttpRequestBase { public: CbCustomRequest() : CbHttpRequestBase(CpHttpRequestExecutor::HttpMethod::GET) {}

void onResponseReceived(const CpHttpRequestExecutor::TResponse& response) override {

File truncated at 100 lines see the full file

CHANGELOG

Changelog for package cl_http

2.3.19 (2025-06-17)

  • OpenAI example client ported to SMACC (#557)

    • initial commit for openAI example
    • Replaced get with post, added key fetch logic
    • Added ability to modify the body of an http request for the http client
    • Added functionality to encode and send image data to ChatGPT
    • Added APIs to add headers to an outgoing HTTP request
    • HTTP requests can now deal with CDNs

    * Expanded example openAI node to submit a more sophisticated request with an image

    • Using env variable for test iamge location
    • Fixed commit errors
    • Renamed instantiation of HTTP request CB to something more specific to OpenAI
  • Moved HTTP client behaviour to client library. Also added GET and POS… (#549)

    • Moved HTTP client behaviour to client library. Also added GET and POST-specific versions of the smacc HTTP client behaviour to make them easier to use
    • Added copyrights
    • Fixed typos
  • Http client (#522)

    • Ported http work over from smacc1
    • Added example showasing http requests
    • Fixed some typos in the HTTP example
    • Made provision for HTTP GET/POST in the HTTP client
    • Moved HTTP client into the client_libraries folder and made separate compilation units. Modified examples to use this new client

    * Update smacc_action_client_base.hpp Pretty sure this change was made accidently.

    * Update smacc_action_client_base.hpp Messed up first commit

    * Update http_client.cpp Added License to file to clean up format error

    * Update http_client.cpp Found better Copyright & License for CI Format error.

    * Update cb_http_request.hpp Another little format error

    * Update sm_atomic_http.py Somehow a bracket became a cNode

      • Fixed errors with HTTP requests not triggering,
    • Fixed response callback not triggering correctly and causing a crash

    • Fixed example not transitioning back to state 1 after a response has been received

    • Ported http work over from smacc1

    • Added example showasing http requests

    • Fixed some typos in the HTTP example

    • Made provision for HTTP GET/POST in the HTTP client

    • Moved HTTP client into the client_libraries folder and made separate compilation units. Modified examples to use this new client

    * Update http_client.cpp Added License to file to clean up format error

    * Update http_client.cpp Found better Copyright & License for CI Format error.

    * Update cb_http_request.hpp Another little format error

    * Update sm_atomic_http.py Somehow a bracket became a cNode

      • Fixed errors with HTTP requests not triggering,
    • Fixed response callback not triggering correctly and causing a crash

    • Fixed example not transitioning back to state 1 after a response has been received

    • Added helper class to handle server name related interactions

    • Added SSL implementation, need to make provision for SSL and non-SSLD requests

File truncated at 100 lines see the full file

Package Dependencies

System Dependencies

No direct system dependencies.

Dependant Packages

Name Deps
sm_atomic_http

Launch files

No launch files found

Messages

No message files found.

Services

No service files found

Plugins

No plugins found.

Recent questions tagged cl_http at Robotics Stack Exchange

No version for distro lyrical showing jazzy. Known supported distros are highlighted in the buttons above.
Package symbol

cl_http package from SMACC2 repo

smacc2 cl_foundation_pose cl_gcalcli cl_generic_sensor cl_http cl_keyboard cl_lifecycle_node cl_mission_tracker cl_modbus_tcp_relay cl_moveit2z cl_nav2z backward_global_planner backward_local_planner forward_global_planner forward_local_planner nav2z_planners_common pure_spinning_local_planner undo_path_global_planner cl_px4_mr cl_ros2_timer eg_conditional_generator eg_random_generator smacc2_msgs sm_atomic_performance_trace_1 sm_atomic_subscribers_performance_test sm_coretest_action_client_1 sm_coretest_callback_rate_1 sm_coretest_exceptions_1 sm_coretest_features_1 sm_coretest_forced_finish_1 sm_coretest_idle_load_1 sm_coretest_object_churn_1 sm_coretest_poll_shutdown_1 sm_coretest_post_during_exit_1 sm_coretest_reactor_order_1 sm_coretest_signal_key_1 sm_coretest_timer_handoff_1 sm_coretest_transition_speed_1 sm_advanced_recovery_1 sm_atomic sm_atomic_http sm_atomic_lifecycle sm_atomic_mode_states sm_branching sm_cl_gcalcli_test_1 sm_cl_keyboard_unit_test_1 sm_cl_px4_mr_test_1 sm_cl_px4_mr_test_2 sm_cl_px4_mr_test_3 sm_cl_px4_mr_test_4 sm_cl_px4_mr_test_5 sm_cl_ros2_timer_unit_test_1 sm_data_sharing_1 sm_data_sharing_2 sm_modbus_tcp_relay_test_1 sm_mode_state_behavior_1 sm_multi_stage_1 sm_multithread_test_1 sm_nav2_gazebo_test_1 sm_nav2_gazebo_test_2 sm_nav2_gazebo_test_3 sm_nav2_gazebo_test_4 sm_pack_ml sm_panda_cl_moveit2z_cb_inventory sm_panda_cl_moveit2z_cb_inventory_isaacsim sm_retry_logic_1 sm_simple_action_client sm_three_some sr_all_events_go sr_conditional sr_event_countdown

ROS Distro
jazzy

Package Summary

Version 3.1.0
License Apache-2.0
Build type AMENT_CMAKE
Use RECOMMENDED

Repository Summary

Description
Checkout URI https://github.com/robosoft-ai/SMACC2.git
VCS Type git
VCS Version jazzy
Last Updated 2026-11-22
Dev Status DEVELOPED
Released RELEASED
Contributing Help Wanted (-)
Good First Issues (-)
Pull Requests to Review (-)

Package Description

The cl_http package

Maintainers

  • Brett Aldrich

Authors

No additional authors.

HTTP Client (cl_http)

SMACC2 client library for making HTTP/HTTPS requests using Boost.Beast.

Architecture

/home/brettpac/workspaces/isaac_ros-dev/src/SMACC2/smacc2_client_library/cl_http The cl_http follows a pure component-based architecture with three specialized components:

ClHttp (Client - Orchestrator)
├── CpHttpConnectionManager - io_context and thread management
├── CpHttpSessionManager - SSL context and session creation
└── CpHttpRequestExecutor - Request execution and response handling

Components

CpHttpConnectionManager

Responsibility: Manages the asynchronous I/O infrastructure

  • Owns boost::asio::io_context
  • Manages worker thread lifecycle
  • Provides strand for thread-safe operations

Lifetime: State machine scoped (created with ClHttp, destroyed with state machine)

CpHttpSessionManager

Responsibility: Manages HTTP/HTTPS session configuration

  • Parses server URLs (protocol, host, port)
  • Manages SSL context for HTTPS connections
  • Creates session objects (http_session or ssl_http_session)

Lifetime: State machine scoped

CpHttpRequestExecutor

Responsibility: Coordinates HTTP request execution

  • Accepts request parameters (method, path, body, headers)
  • Acquires strand from CpHttpConnectionManager
  • Acquires session from CpHttpSessionManager
  • Executes requests and emits response signals

Lifetime: State machine scoped

Signal Flow

User Code (Behavior)
    ↓
CpHttpRequestExecutor::executeRequest()
    ↓
Session created (http_session/ssl_http_session)
    ↓
Request executed asynchronously
    ↓
Response received
    ↓
CpHttpRequestExecutor::onResponseReceived_ (SmaccSignal)
    ↓ (backward compatibility)
ClHttp::onResponseReceived_ (forwarded)
    ↓
Behavior callback

Usage

Quick Start: Using Base Behaviors

The easiest way to make HTTP requests is using the provided base behaviors:

#include <cl_http/client_behaviors/cb_http_get_request.hpp>

class StHttpRequest : public smacc2::SmaccState<StHttpRequest, SmExample>
{
public:
  using SmaccState::SmaccState;

  void runtimeConfigure() override
  {
    auto behavior = this->configure<cl_http::CbHttpGetRequest>();
  }
};

Custom Behaviors: Component-Based Approach

For custom HTTP behavior, inherit from base class and override response handling:

```cpp #include <cl_http/client_behaviors/cb_http_request.hpp>

class CbCustomRequest : public cl_http::CbHttpRequestBase { public: CbCustomRequest() : CbHttpRequestBase(CpHttpRequestExecutor::HttpMethod::GET) {}

void onResponseReceived(const CpHttpRequestExecutor::TResponse& response) override {

File truncated at 100 lines see the full file

CHANGELOG

Changelog for package cl_http

2.3.19 (2025-06-17)

  • OpenAI example client ported to SMACC (#557)

    • initial commit for openAI example
    • Replaced get with post, added key fetch logic
    • Added ability to modify the body of an http request for the http client
    • Added functionality to encode and send image data to ChatGPT
    • Added APIs to add headers to an outgoing HTTP request
    • HTTP requests can now deal with CDNs

    * Expanded example openAI node to submit a more sophisticated request with an image

    • Using env variable for test iamge location
    • Fixed commit errors
    • Renamed instantiation of HTTP request CB to something more specific to OpenAI
  • Moved HTTP client behaviour to client library. Also added GET and POS… (#549)

    • Moved HTTP client behaviour to client library. Also added GET and POST-specific versions of the smacc HTTP client behaviour to make them easier to use
    • Added copyrights
    • Fixed typos
  • Http client (#522)

    • Ported http work over from smacc1
    • Added example showasing http requests
    • Fixed some typos in the HTTP example
    • Made provision for HTTP GET/POST in the HTTP client
    • Moved HTTP client into the client_libraries folder and made separate compilation units. Modified examples to use this new client

    * Update smacc_action_client_base.hpp Pretty sure this change was made accidently.

    * Update smacc_action_client_base.hpp Messed up first commit

    * Update http_client.cpp Added License to file to clean up format error

    * Update http_client.cpp Found better Copyright & License for CI Format error.

    * Update cb_http_request.hpp Another little format error

    * Update sm_atomic_http.py Somehow a bracket became a cNode

      • Fixed errors with HTTP requests not triggering,
    • Fixed response callback not triggering correctly and causing a crash

    • Fixed example not transitioning back to state 1 after a response has been received

    • Ported http work over from smacc1

    • Added example showasing http requests

    • Fixed some typos in the HTTP example

    • Made provision for HTTP GET/POST in the HTTP client

    • Moved HTTP client into the client_libraries folder and made separate compilation units. Modified examples to use this new client

    * Update http_client.cpp Added License to file to clean up format error

    * Update http_client.cpp Found better Copyright & License for CI Format error.

    * Update cb_http_request.hpp Another little format error

    * Update sm_atomic_http.py Somehow a bracket became a cNode

      • Fixed errors with HTTP requests not triggering,
    • Fixed response callback not triggering correctly and causing a crash

    • Fixed example not transitioning back to state 1 after a response has been received

    • Added helper class to handle server name related interactions

    • Added SSL implementation, need to make provision for SSL and non-SSLD requests

File truncated at 100 lines see the full file

Package Dependencies

System Dependencies

No direct system dependencies.

Dependant Packages

Name Deps
sm_atomic_http

Launch files

No launch files found

Messages

No message files found.

Services

No service files found

Plugins

No plugins found.

Recent questions tagged cl_http at Robotics Stack Exchange

No version for distro rolling showing jazzy. Known supported distros are highlighted in the buttons above.
Package symbol

cl_http package from SMACC2 repo

smacc2 cl_foundation_pose cl_gcalcli cl_generic_sensor cl_http cl_keyboard cl_lifecycle_node cl_mission_tracker cl_modbus_tcp_relay cl_moveit2z cl_nav2z backward_global_planner backward_local_planner forward_global_planner forward_local_planner nav2z_planners_common pure_spinning_local_planner undo_path_global_planner cl_px4_mr cl_ros2_timer eg_conditional_generator eg_random_generator smacc2_msgs sm_atomic_performance_trace_1 sm_atomic_subscribers_performance_test sm_coretest_action_client_1 sm_coretest_callback_rate_1 sm_coretest_exceptions_1 sm_coretest_features_1 sm_coretest_forced_finish_1 sm_coretest_idle_load_1 sm_coretest_object_churn_1 sm_coretest_poll_shutdown_1 sm_coretest_post_during_exit_1 sm_coretest_reactor_order_1 sm_coretest_signal_key_1 sm_coretest_timer_handoff_1 sm_coretest_transition_speed_1 sm_advanced_recovery_1 sm_atomic sm_atomic_http sm_atomic_lifecycle sm_atomic_mode_states sm_branching sm_cl_gcalcli_test_1 sm_cl_keyboard_unit_test_1 sm_cl_px4_mr_test_1 sm_cl_px4_mr_test_2 sm_cl_px4_mr_test_3 sm_cl_px4_mr_test_4 sm_cl_px4_mr_test_5 sm_cl_ros2_timer_unit_test_1 sm_data_sharing_1 sm_data_sharing_2 sm_modbus_tcp_relay_test_1 sm_mode_state_behavior_1 sm_multi_stage_1 sm_multithread_test_1 sm_nav2_gazebo_test_1 sm_nav2_gazebo_test_2 sm_nav2_gazebo_test_3 sm_nav2_gazebo_test_4 sm_pack_ml sm_panda_cl_moveit2z_cb_inventory sm_panda_cl_moveit2z_cb_inventory_isaacsim sm_retry_logic_1 sm_simple_action_client sm_three_some sr_all_events_go sr_conditional sr_event_countdown

ROS Distro
jazzy

Package Summary

Version 3.1.0
License Apache-2.0
Build type AMENT_CMAKE
Use RECOMMENDED

Repository Summary

Description
Checkout URI https://github.com/robosoft-ai/SMACC2.git
VCS Type git
VCS Version jazzy
Last Updated 2026-11-22
Dev Status DEVELOPED
Released RELEASED
Contributing Help Wanted (-)
Good First Issues (-)
Pull Requests to Review (-)

Package Description

The cl_http package

Maintainers

  • Brett Aldrich

Authors

No additional authors.

HTTP Client (cl_http)

SMACC2 client library for making HTTP/HTTPS requests using Boost.Beast.

Architecture

/home/brettpac/workspaces/isaac_ros-dev/src/SMACC2/smacc2_client_library/cl_http The cl_http follows a pure component-based architecture with three specialized components:

ClHttp (Client - Orchestrator)
├── CpHttpConnectionManager - io_context and thread management
├── CpHttpSessionManager - SSL context and session creation
└── CpHttpRequestExecutor - Request execution and response handling

Components

CpHttpConnectionManager

Responsibility: Manages the asynchronous I/O infrastructure

  • Owns boost::asio::io_context
  • Manages worker thread lifecycle
  • Provides strand for thread-safe operations

Lifetime: State machine scoped (created with ClHttp, destroyed with state machine)

CpHttpSessionManager

Responsibility: Manages HTTP/HTTPS session configuration

  • Parses server URLs (protocol, host, port)
  • Manages SSL context for HTTPS connections
  • Creates session objects (http_session or ssl_http_session)

Lifetime: State machine scoped

CpHttpRequestExecutor

Responsibility: Coordinates HTTP request execution

  • Accepts request parameters (method, path, body, headers)
  • Acquires strand from CpHttpConnectionManager
  • Acquires session from CpHttpSessionManager
  • Executes requests and emits response signals

Lifetime: State machine scoped

Signal Flow

User Code (Behavior)
    ↓
CpHttpRequestExecutor::executeRequest()
    ↓
Session created (http_session/ssl_http_session)
    ↓
Request executed asynchronously
    ↓
Response received
    ↓
CpHttpRequestExecutor::onResponseReceived_ (SmaccSignal)
    ↓ (backward compatibility)
ClHttp::onResponseReceived_ (forwarded)
    ↓
Behavior callback

Usage

Quick Start: Using Base Behaviors

The easiest way to make HTTP requests is using the provided base behaviors:

#include <cl_http/client_behaviors/cb_http_get_request.hpp>

class StHttpRequest : public smacc2::SmaccState<StHttpRequest, SmExample>
{
public:
  using SmaccState::SmaccState;

  void runtimeConfigure() override
  {
    auto behavior = this->configure<cl_http::CbHttpGetRequest>();
  }
};

Custom Behaviors: Component-Based Approach

For custom HTTP behavior, inherit from base class and override response handling:

```cpp #include <cl_http/client_behaviors/cb_http_request.hpp>

class CbCustomRequest : public cl_http::CbHttpRequestBase { public: CbCustomRequest() : CbHttpRequestBase(CpHttpRequestExecutor::HttpMethod::GET) {}

void onResponseReceived(const CpHttpRequestExecutor::TResponse& response) override {

File truncated at 100 lines see the full file

CHANGELOG

Changelog for package cl_http

2.3.19 (2025-06-17)

  • OpenAI example client ported to SMACC (#557)

    • initial commit for openAI example
    • Replaced get with post, added key fetch logic
    • Added ability to modify the body of an http request for the http client
    • Added functionality to encode and send image data to ChatGPT
    • Added APIs to add headers to an outgoing HTTP request
    • HTTP requests can now deal with CDNs

    * Expanded example openAI node to submit a more sophisticated request with an image

    • Using env variable for test iamge location
    • Fixed commit errors
    • Renamed instantiation of HTTP request CB to something more specific to OpenAI
  • Moved HTTP client behaviour to client library. Also added GET and POS… (#549)

    • Moved HTTP client behaviour to client library. Also added GET and POST-specific versions of the smacc HTTP client behaviour to make them easier to use
    • Added copyrights
    • Fixed typos
  • Http client (#522)

    • Ported http work over from smacc1
    • Added example showasing http requests
    • Fixed some typos in the HTTP example
    • Made provision for HTTP GET/POST in the HTTP client
    • Moved HTTP client into the client_libraries folder and made separate compilation units. Modified examples to use this new client

    * Update smacc_action_client_base.hpp Pretty sure this change was made accidently.

    * Update smacc_action_client_base.hpp Messed up first commit

    * Update http_client.cpp Added License to file to clean up format error

    * Update http_client.cpp Found better Copyright & License for CI Format error.

    * Update cb_http_request.hpp Another little format error

    * Update sm_atomic_http.py Somehow a bracket became a cNode

      • Fixed errors with HTTP requests not triggering,
    • Fixed response callback not triggering correctly and causing a crash

    • Fixed example not transitioning back to state 1 after a response has been received

    • Ported http work over from smacc1

    • Added example showasing http requests

    • Fixed some typos in the HTTP example

    • Made provision for HTTP GET/POST in the HTTP client

    • Moved HTTP client into the client_libraries folder and made separate compilation units. Modified examples to use this new client

    * Update http_client.cpp Added License to file to clean up format error

    * Update http_client.cpp Found better Copyright & License for CI Format error.

    * Update cb_http_request.hpp Another little format error

    * Update sm_atomic_http.py Somehow a bracket became a cNode

      • Fixed errors with HTTP requests not triggering,
    • Fixed response callback not triggering correctly and causing a crash

    • Fixed example not transitioning back to state 1 after a response has been received

    • Added helper class to handle server name related interactions

    • Added SSL implementation, need to make provision for SSL and non-SSLD requests

File truncated at 100 lines see the full file

Package Dependencies

System Dependencies

No direct system dependencies.

Dependant Packages

Name Deps
sm_atomic_http

Launch files

No launch files found

Messages

No message files found.

Services

No service files found

Plugins

No plugins found.

Recent questions tagged cl_http at Robotics Stack Exchange

No version for distro github showing jazzy. Known supported distros are highlighted in the buttons above.
Package symbol

cl_http package from SMACC2 repo

smacc2 cl_foundation_pose cl_gcalcli cl_generic_sensor cl_http cl_keyboard cl_lifecycle_node cl_mission_tracker cl_modbus_tcp_relay cl_moveit2z cl_nav2z backward_global_planner backward_local_planner forward_global_planner forward_local_planner nav2z_planners_common pure_spinning_local_planner undo_path_global_planner cl_px4_mr cl_ros2_timer eg_conditional_generator eg_random_generator smacc2_msgs sm_atomic_performance_trace_1 sm_atomic_subscribers_performance_test sm_coretest_action_client_1 sm_coretest_callback_rate_1 sm_coretest_exceptions_1 sm_coretest_features_1 sm_coretest_forced_finish_1 sm_coretest_idle_load_1 sm_coretest_object_churn_1 sm_coretest_poll_shutdown_1 sm_coretest_post_during_exit_1 sm_coretest_reactor_order_1 sm_coretest_signal_key_1 sm_coretest_timer_handoff_1 sm_coretest_transition_speed_1 sm_advanced_recovery_1 sm_atomic sm_atomic_http sm_atomic_lifecycle sm_atomic_mode_states sm_branching sm_cl_gcalcli_test_1 sm_cl_keyboard_unit_test_1 sm_cl_px4_mr_test_1 sm_cl_px4_mr_test_2 sm_cl_px4_mr_test_3 sm_cl_px4_mr_test_4 sm_cl_px4_mr_test_5 sm_cl_ros2_timer_unit_test_1 sm_data_sharing_1 sm_data_sharing_2 sm_modbus_tcp_relay_test_1 sm_mode_state_behavior_1 sm_multi_stage_1 sm_multithread_test_1 sm_nav2_gazebo_test_1 sm_nav2_gazebo_test_2 sm_nav2_gazebo_test_3 sm_nav2_gazebo_test_4 sm_pack_ml sm_panda_cl_moveit2z_cb_inventory sm_panda_cl_moveit2z_cb_inventory_isaacsim sm_retry_logic_1 sm_simple_action_client sm_three_some sr_all_events_go sr_conditional sr_event_countdown

ROS Distro
jazzy

Package Summary

Version 3.1.0
License Apache-2.0
Build type AMENT_CMAKE
Use RECOMMENDED

Repository Summary

Description
Checkout URI https://github.com/robosoft-ai/SMACC2.git
VCS Type git
VCS Version jazzy
Last Updated 2026-11-22
Dev Status DEVELOPED
Released RELEASED
Contributing Help Wanted (-)
Good First Issues (-)
Pull Requests to Review (-)

Package Description

The cl_http package

Maintainers

  • Brett Aldrich

Authors

No additional authors.

HTTP Client (cl_http)

SMACC2 client library for making HTTP/HTTPS requests using Boost.Beast.

Architecture

/home/brettpac/workspaces/isaac_ros-dev/src/SMACC2/smacc2_client_library/cl_http The cl_http follows a pure component-based architecture with three specialized components:

ClHttp (Client - Orchestrator)
├── CpHttpConnectionManager - io_context and thread management
├── CpHttpSessionManager - SSL context and session creation
└── CpHttpRequestExecutor - Request execution and response handling

Components

CpHttpConnectionManager

Responsibility: Manages the asynchronous I/O infrastructure

  • Owns boost::asio::io_context
  • Manages worker thread lifecycle
  • Provides strand for thread-safe operations

Lifetime: State machine scoped (created with ClHttp, destroyed with state machine)

CpHttpSessionManager

Responsibility: Manages HTTP/HTTPS session configuration

  • Parses server URLs (protocol, host, port)
  • Manages SSL context for HTTPS connections
  • Creates session objects (http_session or ssl_http_session)

Lifetime: State machine scoped

CpHttpRequestExecutor

Responsibility: Coordinates HTTP request execution

  • Accepts request parameters (method, path, body, headers)
  • Acquires strand from CpHttpConnectionManager
  • Acquires session from CpHttpSessionManager
  • Executes requests and emits response signals

Lifetime: State machine scoped

Signal Flow

User Code (Behavior)
    ↓
CpHttpRequestExecutor::executeRequest()
    ↓
Session created (http_session/ssl_http_session)
    ↓
Request executed asynchronously
    ↓
Response received
    ↓
CpHttpRequestExecutor::onResponseReceived_ (SmaccSignal)
    ↓ (backward compatibility)
ClHttp::onResponseReceived_ (forwarded)
    ↓
Behavior callback

Usage

Quick Start: Using Base Behaviors

The easiest way to make HTTP requests is using the provided base behaviors:

#include <cl_http/client_behaviors/cb_http_get_request.hpp>

class StHttpRequest : public smacc2::SmaccState<StHttpRequest, SmExample>
{
public:
  using SmaccState::SmaccState;

  void runtimeConfigure() override
  {
    auto behavior = this->configure<cl_http::CbHttpGetRequest>();
  }
};

Custom Behaviors: Component-Based Approach

For custom HTTP behavior, inherit from base class and override response handling:

```cpp #include <cl_http/client_behaviors/cb_http_request.hpp>

class CbCustomRequest : public cl_http::CbHttpRequestBase { public: CbCustomRequest() : CbHttpRequestBase(CpHttpRequestExecutor::HttpMethod::GET) {}

void onResponseReceived(const CpHttpRequestExecutor::TResponse& response) override {

File truncated at 100 lines see the full file

CHANGELOG

Changelog for package cl_http

2.3.19 (2025-06-17)

  • OpenAI example client ported to SMACC (#557)

    • initial commit for openAI example
    • Replaced get with post, added key fetch logic
    • Added ability to modify the body of an http request for the http client
    • Added functionality to encode and send image data to ChatGPT
    • Added APIs to add headers to an outgoing HTTP request
    • HTTP requests can now deal with CDNs

    * Expanded example openAI node to submit a more sophisticated request with an image

    • Using env variable for test iamge location
    • Fixed commit errors
    • Renamed instantiation of HTTP request CB to something more specific to OpenAI
  • Moved HTTP client behaviour to client library. Also added GET and POS… (#549)

    • Moved HTTP client behaviour to client library. Also added GET and POST-specific versions of the smacc HTTP client behaviour to make them easier to use
    • Added copyrights
    • Fixed typos
  • Http client (#522)

    • Ported http work over from smacc1
    • Added example showasing http requests
    • Fixed some typos in the HTTP example
    • Made provision for HTTP GET/POST in the HTTP client
    • Moved HTTP client into the client_libraries folder and made separate compilation units. Modified examples to use this new client

    * Update smacc_action_client_base.hpp Pretty sure this change was made accidently.

    * Update smacc_action_client_base.hpp Messed up first commit

    * Update http_client.cpp Added License to file to clean up format error

    * Update http_client.cpp Found better Copyright & License for CI Format error.

    * Update cb_http_request.hpp Another little format error

    * Update sm_atomic_http.py Somehow a bracket became a cNode

      • Fixed errors with HTTP requests not triggering,
    • Fixed response callback not triggering correctly and causing a crash

    • Fixed example not transitioning back to state 1 after a response has been received

    • Ported http work over from smacc1

    • Added example showasing http requests

    • Fixed some typos in the HTTP example

    • Made provision for HTTP GET/POST in the HTTP client

    • Moved HTTP client into the client_libraries folder and made separate compilation units. Modified examples to use this new client

    * Update http_client.cpp Added License to file to clean up format error

    * Update http_client.cpp Found better Copyright & License for CI Format error.

    * Update cb_http_request.hpp Another little format error

    * Update sm_atomic_http.py Somehow a bracket became a cNode

      • Fixed errors with HTTP requests not triggering,
    • Fixed response callback not triggering correctly and causing a crash

    • Fixed example not transitioning back to state 1 after a response has been received

    • Added helper class to handle server name related interactions

    • Added SSL implementation, need to make provision for SSL and non-SSLD requests

File truncated at 100 lines see the full file

Package Dependencies

System Dependencies

No direct system dependencies.

Dependant Packages

Name Deps
sm_atomic_http

Launch files

No launch files found

Messages

No message files found.

Services

No service files found

Plugins

No plugins found.

Recent questions tagged cl_http at Robotics Stack Exchange

No version for distro galactic showing jazzy. Known supported distros are highlighted in the buttons above.
Package symbol

cl_http package from SMACC2 repo

smacc2 cl_foundation_pose cl_gcalcli cl_generic_sensor cl_http cl_keyboard cl_lifecycle_node cl_mission_tracker cl_modbus_tcp_relay cl_moveit2z cl_nav2z backward_global_planner backward_local_planner forward_global_planner forward_local_planner nav2z_planners_common pure_spinning_local_planner undo_path_global_planner cl_px4_mr cl_ros2_timer eg_conditional_generator eg_random_generator smacc2_msgs sm_atomic_performance_trace_1 sm_atomic_subscribers_performance_test sm_coretest_action_client_1 sm_coretest_callback_rate_1 sm_coretest_exceptions_1 sm_coretest_features_1 sm_coretest_forced_finish_1 sm_coretest_idle_load_1 sm_coretest_object_churn_1 sm_coretest_poll_shutdown_1 sm_coretest_post_during_exit_1 sm_coretest_reactor_order_1 sm_coretest_signal_key_1 sm_coretest_timer_handoff_1 sm_coretest_transition_speed_1 sm_advanced_recovery_1 sm_atomic sm_atomic_http sm_atomic_lifecycle sm_atomic_mode_states sm_branching sm_cl_gcalcli_test_1 sm_cl_keyboard_unit_test_1 sm_cl_px4_mr_test_1 sm_cl_px4_mr_test_2 sm_cl_px4_mr_test_3 sm_cl_px4_mr_test_4 sm_cl_px4_mr_test_5 sm_cl_ros2_timer_unit_test_1 sm_data_sharing_1 sm_data_sharing_2 sm_modbus_tcp_relay_test_1 sm_mode_state_behavior_1 sm_multi_stage_1 sm_multithread_test_1 sm_nav2_gazebo_test_1 sm_nav2_gazebo_test_2 sm_nav2_gazebo_test_3 sm_nav2_gazebo_test_4 sm_pack_ml sm_panda_cl_moveit2z_cb_inventory sm_panda_cl_moveit2z_cb_inventory_isaacsim sm_retry_logic_1 sm_simple_action_client sm_three_some sr_all_events_go sr_conditional sr_event_countdown

ROS Distro
jazzy

Package Summary

Version 3.1.0
License Apache-2.0
Build type AMENT_CMAKE
Use RECOMMENDED

Repository Summary

Description
Checkout URI https://github.com/robosoft-ai/SMACC2.git
VCS Type git
VCS Version jazzy
Last Updated 2026-11-22
Dev Status DEVELOPED
Released RELEASED
Contributing Help Wanted (-)
Good First Issues (-)
Pull Requests to Review (-)

Package Description

The cl_http package

Maintainers

  • Brett Aldrich

Authors

No additional authors.

HTTP Client (cl_http)

SMACC2 client library for making HTTP/HTTPS requests using Boost.Beast.

Architecture

/home/brettpac/workspaces/isaac_ros-dev/src/SMACC2/smacc2_client_library/cl_http The cl_http follows a pure component-based architecture with three specialized components:

ClHttp (Client - Orchestrator)
├── CpHttpConnectionManager - io_context and thread management
├── CpHttpSessionManager - SSL context and session creation
└── CpHttpRequestExecutor - Request execution and response handling

Components

CpHttpConnectionManager

Responsibility: Manages the asynchronous I/O infrastructure

  • Owns boost::asio::io_context
  • Manages worker thread lifecycle
  • Provides strand for thread-safe operations

Lifetime: State machine scoped (created with ClHttp, destroyed with state machine)

CpHttpSessionManager

Responsibility: Manages HTTP/HTTPS session configuration

  • Parses server URLs (protocol, host, port)
  • Manages SSL context for HTTPS connections
  • Creates session objects (http_session or ssl_http_session)

Lifetime: State machine scoped

CpHttpRequestExecutor

Responsibility: Coordinates HTTP request execution

  • Accepts request parameters (method, path, body, headers)
  • Acquires strand from CpHttpConnectionManager
  • Acquires session from CpHttpSessionManager
  • Executes requests and emits response signals

Lifetime: State machine scoped

Signal Flow

User Code (Behavior)
    ↓
CpHttpRequestExecutor::executeRequest()
    ↓
Session created (http_session/ssl_http_session)
    ↓
Request executed asynchronously
    ↓
Response received
    ↓
CpHttpRequestExecutor::onResponseReceived_ (SmaccSignal)
    ↓ (backward compatibility)
ClHttp::onResponseReceived_ (forwarded)
    ↓
Behavior callback

Usage

Quick Start: Using Base Behaviors

The easiest way to make HTTP requests is using the provided base behaviors:

#include <cl_http/client_behaviors/cb_http_get_request.hpp>

class StHttpRequest : public smacc2::SmaccState<StHttpRequest, SmExample>
{
public:
  using SmaccState::SmaccState;

  void runtimeConfigure() override
  {
    auto behavior = this->configure<cl_http::CbHttpGetRequest>();
  }
};

Custom Behaviors: Component-Based Approach

For custom HTTP behavior, inherit from base class and override response handling:

```cpp #include <cl_http/client_behaviors/cb_http_request.hpp>

class CbCustomRequest : public cl_http::CbHttpRequestBase { public: CbCustomRequest() : CbHttpRequestBase(CpHttpRequestExecutor::HttpMethod::GET) {}

void onResponseReceived(const CpHttpRequestExecutor::TResponse& response) override {

File truncated at 100 lines see the full file

CHANGELOG

Changelog for package cl_http

2.3.19 (2025-06-17)

  • OpenAI example client ported to SMACC (#557)

    • initial commit for openAI example
    • Replaced get with post, added key fetch logic
    • Added ability to modify the body of an http request for the http client
    • Added functionality to encode and send image data to ChatGPT
    • Added APIs to add headers to an outgoing HTTP request
    • HTTP requests can now deal with CDNs

    * Expanded example openAI node to submit a more sophisticated request with an image

    • Using env variable for test iamge location
    • Fixed commit errors
    • Renamed instantiation of HTTP request CB to something more specific to OpenAI
  • Moved HTTP client behaviour to client library. Also added GET and POS… (#549)

    • Moved HTTP client behaviour to client library. Also added GET and POST-specific versions of the smacc HTTP client behaviour to make them easier to use
    • Added copyrights
    • Fixed typos
  • Http client (#522)

    • Ported http work over from smacc1
    • Added example showasing http requests
    • Fixed some typos in the HTTP example
    • Made provision for HTTP GET/POST in the HTTP client
    • Moved HTTP client into the client_libraries folder and made separate compilation units. Modified examples to use this new client

    * Update smacc_action_client_base.hpp Pretty sure this change was made accidently.

    * Update smacc_action_client_base.hpp Messed up first commit

    * Update http_client.cpp Added License to file to clean up format error

    * Update http_client.cpp Found better Copyright & License for CI Format error.

    * Update cb_http_request.hpp Another little format error

    * Update sm_atomic_http.py Somehow a bracket became a cNode

      • Fixed errors with HTTP requests not triggering,
    • Fixed response callback not triggering correctly and causing a crash

    • Fixed example not transitioning back to state 1 after a response has been received

    • Ported http work over from smacc1

    • Added example showasing http requests

    • Fixed some typos in the HTTP example

    • Made provision for HTTP GET/POST in the HTTP client

    • Moved HTTP client into the client_libraries folder and made separate compilation units. Modified examples to use this new client

    * Update http_client.cpp Added License to file to clean up format error

    * Update http_client.cpp Found better Copyright & License for CI Format error.

    * Update cb_http_request.hpp Another little format error

    * Update sm_atomic_http.py Somehow a bracket became a cNode

      • Fixed errors with HTTP requests not triggering,
    • Fixed response callback not triggering correctly and causing a crash

    • Fixed example not transitioning back to state 1 after a response has been received

    • Added helper class to handle server name related interactions

    • Added SSL implementation, need to make provision for SSL and non-SSLD requests

File truncated at 100 lines see the full file

Package Dependencies

System Dependencies

No direct system dependencies.

Dependant Packages

Name Deps
sm_atomic_http

Launch files

No launch files found

Messages

No message files found.

Services

No service files found

Plugins

No plugins found.

Recent questions tagged cl_http at Robotics Stack Exchange

No version for distro iron showing jazzy. Known supported distros are highlighted in the buttons above.
Package symbol

cl_http package from SMACC2 repo

smacc2 cl_foundation_pose cl_gcalcli cl_generic_sensor cl_http cl_keyboard cl_lifecycle_node cl_mission_tracker cl_modbus_tcp_relay cl_moveit2z cl_nav2z backward_global_planner backward_local_planner forward_global_planner forward_local_planner nav2z_planners_common pure_spinning_local_planner undo_path_global_planner cl_px4_mr cl_ros2_timer eg_conditional_generator eg_random_generator smacc2_msgs sm_atomic_performance_trace_1 sm_atomic_subscribers_performance_test sm_coretest_action_client_1 sm_coretest_callback_rate_1 sm_coretest_exceptions_1 sm_coretest_features_1 sm_coretest_forced_finish_1 sm_coretest_idle_load_1 sm_coretest_object_churn_1 sm_coretest_poll_shutdown_1 sm_coretest_post_during_exit_1 sm_coretest_reactor_order_1 sm_coretest_signal_key_1 sm_coretest_timer_handoff_1 sm_coretest_transition_speed_1 sm_advanced_recovery_1 sm_atomic sm_atomic_http sm_atomic_lifecycle sm_atomic_mode_states sm_branching sm_cl_gcalcli_test_1 sm_cl_keyboard_unit_test_1 sm_cl_px4_mr_test_1 sm_cl_px4_mr_test_2 sm_cl_px4_mr_test_3 sm_cl_px4_mr_test_4 sm_cl_px4_mr_test_5 sm_cl_ros2_timer_unit_test_1 sm_data_sharing_1 sm_data_sharing_2 sm_modbus_tcp_relay_test_1 sm_mode_state_behavior_1 sm_multi_stage_1 sm_multithread_test_1 sm_nav2_gazebo_test_1 sm_nav2_gazebo_test_2 sm_nav2_gazebo_test_3 sm_nav2_gazebo_test_4 sm_pack_ml sm_panda_cl_moveit2z_cb_inventory sm_panda_cl_moveit2z_cb_inventory_isaacsim sm_retry_logic_1 sm_simple_action_client sm_three_some sr_all_events_go sr_conditional sr_event_countdown

ROS Distro
jazzy

Package Summary

Version 3.1.0
License Apache-2.0
Build type AMENT_CMAKE
Use RECOMMENDED

Repository Summary

Description
Checkout URI https://github.com/robosoft-ai/SMACC2.git
VCS Type git
VCS Version jazzy
Last Updated 2026-11-22
Dev Status DEVELOPED
Released RELEASED
Contributing Help Wanted (-)
Good First Issues (-)
Pull Requests to Review (-)

Package Description

The cl_http package

Maintainers

  • Brett Aldrich

Authors

No additional authors.

HTTP Client (cl_http)

SMACC2 client library for making HTTP/HTTPS requests using Boost.Beast.

Architecture

/home/brettpac/workspaces/isaac_ros-dev/src/SMACC2/smacc2_client_library/cl_http The cl_http follows a pure component-based architecture with three specialized components:

ClHttp (Client - Orchestrator)
├── CpHttpConnectionManager - io_context and thread management
├── CpHttpSessionManager - SSL context and session creation
└── CpHttpRequestExecutor - Request execution and response handling

Components

CpHttpConnectionManager

Responsibility: Manages the asynchronous I/O infrastructure

  • Owns boost::asio::io_context
  • Manages worker thread lifecycle
  • Provides strand for thread-safe operations

Lifetime: State machine scoped (created with ClHttp, destroyed with state machine)

CpHttpSessionManager

Responsibility: Manages HTTP/HTTPS session configuration

  • Parses server URLs (protocol, host, port)
  • Manages SSL context for HTTPS connections
  • Creates session objects (http_session or ssl_http_session)

Lifetime: State machine scoped

CpHttpRequestExecutor

Responsibility: Coordinates HTTP request execution

  • Accepts request parameters (method, path, body, headers)
  • Acquires strand from CpHttpConnectionManager
  • Acquires session from CpHttpSessionManager
  • Executes requests and emits response signals

Lifetime: State machine scoped

Signal Flow

User Code (Behavior)
    ↓
CpHttpRequestExecutor::executeRequest()
    ↓
Session created (http_session/ssl_http_session)
    ↓
Request executed asynchronously
    ↓
Response received
    ↓
CpHttpRequestExecutor::onResponseReceived_ (SmaccSignal)
    ↓ (backward compatibility)
ClHttp::onResponseReceived_ (forwarded)
    ↓
Behavior callback

Usage

Quick Start: Using Base Behaviors

The easiest way to make HTTP requests is using the provided base behaviors:

#include <cl_http/client_behaviors/cb_http_get_request.hpp>

class StHttpRequest : public smacc2::SmaccState<StHttpRequest, SmExample>
{
public:
  using SmaccState::SmaccState;

  void runtimeConfigure() override
  {
    auto behavior = this->configure<cl_http::CbHttpGetRequest>();
  }
};

Custom Behaviors: Component-Based Approach

For custom HTTP behavior, inherit from base class and override response handling:

```cpp #include <cl_http/client_behaviors/cb_http_request.hpp>

class CbCustomRequest : public cl_http::CbHttpRequestBase { public: CbCustomRequest() : CbHttpRequestBase(CpHttpRequestExecutor::HttpMethod::GET) {}

void onResponseReceived(const CpHttpRequestExecutor::TResponse& response) override {

File truncated at 100 lines see the full file

CHANGELOG

Changelog for package cl_http

2.3.19 (2025-06-17)

  • OpenAI example client ported to SMACC (#557)

    • initial commit for openAI example
    • Replaced get with post, added key fetch logic
    • Added ability to modify the body of an http request for the http client
    • Added functionality to encode and send image data to ChatGPT
    • Added APIs to add headers to an outgoing HTTP request
    • HTTP requests can now deal with CDNs

    * Expanded example openAI node to submit a more sophisticated request with an image

    • Using env variable for test iamge location
    • Fixed commit errors
    • Renamed instantiation of HTTP request CB to something more specific to OpenAI
  • Moved HTTP client behaviour to client library. Also added GET and POS… (#549)

    • Moved HTTP client behaviour to client library. Also added GET and POST-specific versions of the smacc HTTP client behaviour to make them easier to use
    • Added copyrights
    • Fixed typos
  • Http client (#522)

    • Ported http work over from smacc1
    • Added example showasing http requests
    • Fixed some typos in the HTTP example
    • Made provision for HTTP GET/POST in the HTTP client
    • Moved HTTP client into the client_libraries folder and made separate compilation units. Modified examples to use this new client

    * Update smacc_action_client_base.hpp Pretty sure this change was made accidently.

    * Update smacc_action_client_base.hpp Messed up first commit

    * Update http_client.cpp Added License to file to clean up format error

    * Update http_client.cpp Found better Copyright & License for CI Format error.

    * Update cb_http_request.hpp Another little format error

    * Update sm_atomic_http.py Somehow a bracket became a cNode

      • Fixed errors with HTTP requests not triggering,
    • Fixed response callback not triggering correctly and causing a crash

    • Fixed example not transitioning back to state 1 after a response has been received

    • Ported http work over from smacc1

    • Added example showasing http requests

    • Fixed some typos in the HTTP example

    • Made provision for HTTP GET/POST in the HTTP client

    • Moved HTTP client into the client_libraries folder and made separate compilation units. Modified examples to use this new client

    * Update http_client.cpp Added License to file to clean up format error

    * Update http_client.cpp Found better Copyright & License for CI Format error.

    * Update cb_http_request.hpp Another little format error

    * Update sm_atomic_http.py Somehow a bracket became a cNode

      • Fixed errors with HTTP requests not triggering,
    • Fixed response callback not triggering correctly and causing a crash

    • Fixed example not transitioning back to state 1 after a response has been received

    • Added helper class to handle server name related interactions

    • Added SSL implementation, need to make provision for SSL and non-SSLD requests

File truncated at 100 lines see the full file

Package Dependencies

System Dependencies

No direct system dependencies.

Dependant Packages

Name Deps
sm_atomic_http

Launch files

No launch files found

Messages

No message files found.

Services

No service files found

Plugins

No plugins found.

Recent questions tagged cl_http at Robotics Stack Exchange

No version for distro melodic showing jazzy. Known supported distros are highlighted in the buttons above.
Package symbol

cl_http package from SMACC2 repo

smacc2 cl_foundation_pose cl_gcalcli cl_generic_sensor cl_http cl_keyboard cl_lifecycle_node cl_mission_tracker cl_modbus_tcp_relay cl_moveit2z cl_nav2z backward_global_planner backward_local_planner forward_global_planner forward_local_planner nav2z_planners_common pure_spinning_local_planner undo_path_global_planner cl_px4_mr cl_ros2_timer eg_conditional_generator eg_random_generator smacc2_msgs sm_atomic_performance_trace_1 sm_atomic_subscribers_performance_test sm_coretest_action_client_1 sm_coretest_callback_rate_1 sm_coretest_exceptions_1 sm_coretest_features_1 sm_coretest_forced_finish_1 sm_coretest_idle_load_1 sm_coretest_object_churn_1 sm_coretest_poll_shutdown_1 sm_coretest_post_during_exit_1 sm_coretest_reactor_order_1 sm_coretest_signal_key_1 sm_coretest_timer_handoff_1 sm_coretest_transition_speed_1 sm_advanced_recovery_1 sm_atomic sm_atomic_http sm_atomic_lifecycle sm_atomic_mode_states sm_branching sm_cl_gcalcli_test_1 sm_cl_keyboard_unit_test_1 sm_cl_px4_mr_test_1 sm_cl_px4_mr_test_2 sm_cl_px4_mr_test_3 sm_cl_px4_mr_test_4 sm_cl_px4_mr_test_5 sm_cl_ros2_timer_unit_test_1 sm_data_sharing_1 sm_data_sharing_2 sm_modbus_tcp_relay_test_1 sm_mode_state_behavior_1 sm_multi_stage_1 sm_multithread_test_1 sm_nav2_gazebo_test_1 sm_nav2_gazebo_test_2 sm_nav2_gazebo_test_3 sm_nav2_gazebo_test_4 sm_pack_ml sm_panda_cl_moveit2z_cb_inventory sm_panda_cl_moveit2z_cb_inventory_isaacsim sm_retry_logic_1 sm_simple_action_client sm_three_some sr_all_events_go sr_conditional sr_event_countdown

ROS Distro
jazzy

Package Summary

Version 3.1.0
License Apache-2.0
Build type AMENT_CMAKE
Use RECOMMENDED

Repository Summary

Description
Checkout URI https://github.com/robosoft-ai/SMACC2.git
VCS Type git
VCS Version jazzy
Last Updated 2026-11-22
Dev Status DEVELOPED
Released RELEASED
Contributing Help Wanted (-)
Good First Issues (-)
Pull Requests to Review (-)

Package Description

The cl_http package

Maintainers

  • Brett Aldrich

Authors

No additional authors.

HTTP Client (cl_http)

SMACC2 client library for making HTTP/HTTPS requests using Boost.Beast.

Architecture

/home/brettpac/workspaces/isaac_ros-dev/src/SMACC2/smacc2_client_library/cl_http The cl_http follows a pure component-based architecture with three specialized components:

ClHttp (Client - Orchestrator)
├── CpHttpConnectionManager - io_context and thread management
├── CpHttpSessionManager - SSL context and session creation
└── CpHttpRequestExecutor - Request execution and response handling

Components

CpHttpConnectionManager

Responsibility: Manages the asynchronous I/O infrastructure

  • Owns boost::asio::io_context
  • Manages worker thread lifecycle
  • Provides strand for thread-safe operations

Lifetime: State machine scoped (created with ClHttp, destroyed with state machine)

CpHttpSessionManager

Responsibility: Manages HTTP/HTTPS session configuration

  • Parses server URLs (protocol, host, port)
  • Manages SSL context for HTTPS connections
  • Creates session objects (http_session or ssl_http_session)

Lifetime: State machine scoped

CpHttpRequestExecutor

Responsibility: Coordinates HTTP request execution

  • Accepts request parameters (method, path, body, headers)
  • Acquires strand from CpHttpConnectionManager
  • Acquires session from CpHttpSessionManager
  • Executes requests and emits response signals

Lifetime: State machine scoped

Signal Flow

User Code (Behavior)
    ↓
CpHttpRequestExecutor::executeRequest()
    ↓
Session created (http_session/ssl_http_session)
    ↓
Request executed asynchronously
    ↓
Response received
    ↓
CpHttpRequestExecutor::onResponseReceived_ (SmaccSignal)
    ↓ (backward compatibility)
ClHttp::onResponseReceived_ (forwarded)
    ↓
Behavior callback

Usage

Quick Start: Using Base Behaviors

The easiest way to make HTTP requests is using the provided base behaviors:

#include <cl_http/client_behaviors/cb_http_get_request.hpp>

class StHttpRequest : public smacc2::SmaccState<StHttpRequest, SmExample>
{
public:
  using SmaccState::SmaccState;

  void runtimeConfigure() override
  {
    auto behavior = this->configure<cl_http::CbHttpGetRequest>();
  }
};

Custom Behaviors: Component-Based Approach

For custom HTTP behavior, inherit from base class and override response handling:

```cpp #include <cl_http/client_behaviors/cb_http_request.hpp>

class CbCustomRequest : public cl_http::CbHttpRequestBase { public: CbCustomRequest() : CbHttpRequestBase(CpHttpRequestExecutor::HttpMethod::GET) {}

void onResponseReceived(const CpHttpRequestExecutor::TResponse& response) override {

File truncated at 100 lines see the full file

CHANGELOG

Changelog for package cl_http

2.3.19 (2025-06-17)

  • OpenAI example client ported to SMACC (#557)

    • initial commit for openAI example
    • Replaced get with post, added key fetch logic
    • Added ability to modify the body of an http request for the http client
    • Added functionality to encode and send image data to ChatGPT
    • Added APIs to add headers to an outgoing HTTP request
    • HTTP requests can now deal with CDNs

    * Expanded example openAI node to submit a more sophisticated request with an image

    • Using env variable for test iamge location
    • Fixed commit errors
    • Renamed instantiation of HTTP request CB to something more specific to OpenAI
  • Moved HTTP client behaviour to client library. Also added GET and POS… (#549)

    • Moved HTTP client behaviour to client library. Also added GET and POST-specific versions of the smacc HTTP client behaviour to make them easier to use
    • Added copyrights
    • Fixed typos
  • Http client (#522)

    • Ported http work over from smacc1
    • Added example showasing http requests
    • Fixed some typos in the HTTP example
    • Made provision for HTTP GET/POST in the HTTP client
    • Moved HTTP client into the client_libraries folder and made separate compilation units. Modified examples to use this new client

    * Update smacc_action_client_base.hpp Pretty sure this change was made accidently.

    * Update smacc_action_client_base.hpp Messed up first commit

    * Update http_client.cpp Added License to file to clean up format error

    * Update http_client.cpp Found better Copyright & License for CI Format error.

    * Update cb_http_request.hpp Another little format error

    * Update sm_atomic_http.py Somehow a bracket became a cNode

      • Fixed errors with HTTP requests not triggering,
    • Fixed response callback not triggering correctly and causing a crash

    • Fixed example not transitioning back to state 1 after a response has been received

    • Ported http work over from smacc1

    • Added example showasing http requests

    • Fixed some typos in the HTTP example

    • Made provision for HTTP GET/POST in the HTTP client

    • Moved HTTP client into the client_libraries folder and made separate compilation units. Modified examples to use this new client

    * Update http_client.cpp Added License to file to clean up format error

    * Update http_client.cpp Found better Copyright & License for CI Format error.

    * Update cb_http_request.hpp Another little format error

    * Update sm_atomic_http.py Somehow a bracket became a cNode

      • Fixed errors with HTTP requests not triggering,
    • Fixed response callback not triggering correctly and causing a crash

    • Fixed example not transitioning back to state 1 after a response has been received

    • Added helper class to handle server name related interactions

    • Added SSL implementation, need to make provision for SSL and non-SSLD requests

File truncated at 100 lines see the full file

Package Dependencies

System Dependencies

No direct system dependencies.

Dependant Packages

Name Deps
sm_atomic_http

Launch files

No launch files found

Messages

No message files found.

Services

No service files found

Plugins

No plugins found.

Recent questions tagged cl_http at Robotics Stack Exchange

No version for distro noetic showing jazzy. Known supported distros are highlighted in the buttons above.
Package symbol

cl_http package from SMACC2 repo

smacc2 cl_foundation_pose cl_gcalcli cl_generic_sensor cl_http cl_keyboard cl_lifecycle_node cl_mission_tracker cl_modbus_tcp_relay cl_moveit2z cl_nav2z backward_global_planner backward_local_planner forward_global_planner forward_local_planner nav2z_planners_common pure_spinning_local_planner undo_path_global_planner cl_px4_mr cl_ros2_timer eg_conditional_generator eg_random_generator smacc2_msgs sm_atomic_performance_trace_1 sm_atomic_subscribers_performance_test sm_coretest_action_client_1 sm_coretest_callback_rate_1 sm_coretest_exceptions_1 sm_coretest_features_1 sm_coretest_forced_finish_1 sm_coretest_idle_load_1 sm_coretest_object_churn_1 sm_coretest_poll_shutdown_1 sm_coretest_post_during_exit_1 sm_coretest_reactor_order_1 sm_coretest_signal_key_1 sm_coretest_timer_handoff_1 sm_coretest_transition_speed_1 sm_advanced_recovery_1 sm_atomic sm_atomic_http sm_atomic_lifecycle sm_atomic_mode_states sm_branching sm_cl_gcalcli_test_1 sm_cl_keyboard_unit_test_1 sm_cl_px4_mr_test_1 sm_cl_px4_mr_test_2 sm_cl_px4_mr_test_3 sm_cl_px4_mr_test_4 sm_cl_px4_mr_test_5 sm_cl_ros2_timer_unit_test_1 sm_data_sharing_1 sm_data_sharing_2 sm_modbus_tcp_relay_test_1 sm_mode_state_behavior_1 sm_multi_stage_1 sm_multithread_test_1 sm_nav2_gazebo_test_1 sm_nav2_gazebo_test_2 sm_nav2_gazebo_test_3 sm_nav2_gazebo_test_4 sm_pack_ml sm_panda_cl_moveit2z_cb_inventory sm_panda_cl_moveit2z_cb_inventory_isaacsim sm_retry_logic_1 sm_simple_action_client sm_three_some sr_all_events_go sr_conditional sr_event_countdown

ROS Distro
jazzy

Package Summary

Version 3.1.0
License Apache-2.0
Build type AMENT_CMAKE
Use RECOMMENDED

Repository Summary

Description
Checkout URI https://github.com/robosoft-ai/SMACC2.git
VCS Type git
VCS Version jazzy
Last Updated 2026-11-22
Dev Status DEVELOPED
Released RELEASED
Contributing Help Wanted (-)
Good First Issues (-)
Pull Requests to Review (-)

Package Description

The cl_http package

Maintainers

  • Brett Aldrich

Authors

No additional authors.

HTTP Client (cl_http)

SMACC2 client library for making HTTP/HTTPS requests using Boost.Beast.

Architecture

/home/brettpac/workspaces/isaac_ros-dev/src/SMACC2/smacc2_client_library/cl_http The cl_http follows a pure component-based architecture with three specialized components:

ClHttp (Client - Orchestrator)
├── CpHttpConnectionManager - io_context and thread management
├── CpHttpSessionManager - SSL context and session creation
└── CpHttpRequestExecutor - Request execution and response handling

Components

CpHttpConnectionManager

Responsibility: Manages the asynchronous I/O infrastructure

  • Owns boost::asio::io_context
  • Manages worker thread lifecycle
  • Provides strand for thread-safe operations

Lifetime: State machine scoped (created with ClHttp, destroyed with state machine)

CpHttpSessionManager

Responsibility: Manages HTTP/HTTPS session configuration

  • Parses server URLs (protocol, host, port)
  • Manages SSL context for HTTPS connections
  • Creates session objects (http_session or ssl_http_session)

Lifetime: State machine scoped

CpHttpRequestExecutor

Responsibility: Coordinates HTTP request execution

  • Accepts request parameters (method, path, body, headers)
  • Acquires strand from CpHttpConnectionManager
  • Acquires session from CpHttpSessionManager
  • Executes requests and emits response signals

Lifetime: State machine scoped

Signal Flow

User Code (Behavior)
    ↓
CpHttpRequestExecutor::executeRequest()
    ↓
Session created (http_session/ssl_http_session)
    ↓
Request executed asynchronously
    ↓
Response received
    ↓
CpHttpRequestExecutor::onResponseReceived_ (SmaccSignal)
    ↓ (backward compatibility)
ClHttp::onResponseReceived_ (forwarded)
    ↓
Behavior callback

Usage

Quick Start: Using Base Behaviors

The easiest way to make HTTP requests is using the provided base behaviors:

#include <cl_http/client_behaviors/cb_http_get_request.hpp>

class StHttpRequest : public smacc2::SmaccState<StHttpRequest, SmExample>
{
public:
  using SmaccState::SmaccState;

  void runtimeConfigure() override
  {
    auto behavior = this->configure<cl_http::CbHttpGetRequest>();
  }
};

Custom Behaviors: Component-Based Approach

For custom HTTP behavior, inherit from base class and override response handling:

```cpp #include <cl_http/client_behaviors/cb_http_request.hpp>

class CbCustomRequest : public cl_http::CbHttpRequestBase { public: CbCustomRequest() : CbHttpRequestBase(CpHttpRequestExecutor::HttpMethod::GET) {}

void onResponseReceived(const CpHttpRequestExecutor::TResponse& response) override {

File truncated at 100 lines see the full file

CHANGELOG

Changelog for package cl_http

2.3.19 (2025-06-17)

  • OpenAI example client ported to SMACC (#557)

    • initial commit for openAI example
    • Replaced get with post, added key fetch logic
    • Added ability to modify the body of an http request for the http client
    • Added functionality to encode and send image data to ChatGPT
    • Added APIs to add headers to an outgoing HTTP request
    • HTTP requests can now deal with CDNs

    * Expanded example openAI node to submit a more sophisticated request with an image

    • Using env variable for test iamge location
    • Fixed commit errors
    • Renamed instantiation of HTTP request CB to something more specific to OpenAI
  • Moved HTTP client behaviour to client library. Also added GET and POS… (#549)

    • Moved HTTP client behaviour to client library. Also added GET and POST-specific versions of the smacc HTTP client behaviour to make them easier to use
    • Added copyrights
    • Fixed typos
  • Http client (#522)

    • Ported http work over from smacc1
    • Added example showasing http requests
    • Fixed some typos in the HTTP example
    • Made provision for HTTP GET/POST in the HTTP client
    • Moved HTTP client into the client_libraries folder and made separate compilation units. Modified examples to use this new client

    * Update smacc_action_client_base.hpp Pretty sure this change was made accidently.

    * Update smacc_action_client_base.hpp Messed up first commit

    * Update http_client.cpp Added License to file to clean up format error

    * Update http_client.cpp Found better Copyright & License for CI Format error.

    * Update cb_http_request.hpp Another little format error

    * Update sm_atomic_http.py Somehow a bracket became a cNode

      • Fixed errors with HTTP requests not triggering,
    • Fixed response callback not triggering correctly and causing a crash

    • Fixed example not transitioning back to state 1 after a response has been received

    • Ported http work over from smacc1

    • Added example showasing http requests

    • Fixed some typos in the HTTP example

    • Made provision for HTTP GET/POST in the HTTP client

    • Moved HTTP client into the client_libraries folder and made separate compilation units. Modified examples to use this new client

    * Update http_client.cpp Added License to file to clean up format error

    * Update http_client.cpp Found better Copyright & License for CI Format error.

    * Update cb_http_request.hpp Another little format error

    * Update sm_atomic_http.py Somehow a bracket became a cNode

      • Fixed errors with HTTP requests not triggering,
    • Fixed response callback not triggering correctly and causing a crash

    • Fixed example not transitioning back to state 1 after a response has been received

    • Added helper class to handle server name related interactions

    • Added SSL implementation, need to make provision for SSL and non-SSLD requests

File truncated at 100 lines see the full file

Package Dependencies

System Dependencies

No direct system dependencies.

Dependant Packages

Name Deps
sm_atomic_http

Launch files

No launch files found

Messages

No message files found.

Services

No service files found

Plugins

No plugins found.

Recent questions tagged cl_http at Robotics Stack Exchange