19#ifndef _RES_WEBSOCKET_CLIENT_H
20#define _RES_WEBSOCKET_CLIENT_H
54#define AST_WS_CLIENT_FIELD_USER_START 24
Support for WebSocket connections within the Asterisk HTTP server and client WebSocket connections to...
ast_websocket_result
Result code for a websocket client.
ast_websocket_type
WebSocket connection/configuration types.
Sorcery Data Access Layer API.
#define AST_DECLARE_STRING_FIELDS(field_list)
Declare the fields needed in a structure.
#define AST_STRING_FIELD(name)
Declare a string field.
Interface for a sorcery object type observer.
unsigned int reconnect_interval
const ast_string_field uri
enum ast_websocket_type connection_type
const ast_string_field ca_list_path
const ast_string_field cert_file
const ast_string_field password
const ast_string_field username
const ast_string_field ca_list_file
int verify_server_hostname
const ast_string_field protocols
const ast_string_field priv_key_file
enum ast_ws_client_fields invalid_fields
unsigned int reconnect_attempts
Structure definition for session.
struct ao2_container * ast_websocket_client_retrieve_all(void)
Retrieve a container of all websocket client objects.
int ast_websocket_client_reload(void)
Force res_websocket_client to reload its configuration.
@ AST_WS_CLIENT_FIELD_RECONNECT_INTERVAL
@ AST_WS_CLIENT_FIELD_NONE
@ AST_WS_CLIENT_FIELD_URI
@ AST_WS_CLIENT_FIELD_PROTOCOLS
@ AST_WS_CLIENT_NEEDS_RECONNECT
@ AST_WS_CLIENT_FIELD_CA_LIST_PATH
@ AST_WS_CLIENT_FIELD_TLS_ENABLED
@ AST_WS_CLIENT_FIELD_CA_LIST_FILE
@ AST_WS_CLIENT_FIELD_USERNAME
@ AST_WS_CLIENT_FIELD_VERIFY_SERVER_CERT
@ AST_WS_CLIENT_FIELD_PASSWORD
@ AST_WS_CLIENT_FIELD_CONNECTION_TIMEOUT
@ AST_WS_CLIENT_FIELD_RECONNECT_ATTEMPTS
@ AST_WS_CLIENT_FIELD_CONNECTION_TYPE
@ AST_WS_CLIENT_FIELD_VERIFY_SERVER_HOSTNAME
@ AST_WS_CLIENT_FIELD_CERT_FILE
@ AST_WS_CLIENT_FIELD_PRIV_KEY_FILE
enum ast_ws_client_fields ast_websocket_client_get_field_diff(struct ast_websocket_client *old_wc, struct ast_websocket_client *new_wc)
Detect changes between two websocket client configurations.
struct ast_websocket_client * ast_websocket_client_retrieve_by_id(const char *id)
Retrieve a websocket client object by ID.
void ast_websocket_client_observer_remove(const struct ast_sorcery_observer *callbacks)
Remove sorcery observers for websocket client events.
int ast_websocket_client_observer_add(const struct ast_sorcery_observer *callbacks)
Add sorcery observers for websocket client events.
struct ast_websocket * ast_websocket_client_connect(struct ast_websocket_client *wc, void *lock_obj, const char *display_name, enum ast_websocket_result *result)
Connect to a websocket server using the configured authentication, retry and TLS options.