OpenXchangeClient.Api.Config (open_xchange_client v0.10.1)
API calls for all endpoints tagged Config
.
Link to this section Summary
Functions
Gets data of a configuration node. The configuration is stored in a tree. Each node of the tree has a name and a value. The values of leaf nodes are strings which store the actual configuration data. The values of inner nodes are defined recursively as objects with one field for each child node. The name and the value of each field is the name and the value of the corresponding child node, respectively.
Gets a property of the configuration.
Sets the value of a configuration node. The configuration is stored in a tree. Each node of the tree has a name and a value. The values of leaf nodes are strings which store the actual configuration data. The values of inner nodes are defined recursively as objects with one field for each child node. The name and the value of each field is the name and the value of the corresponding child node, respectively.
Sets a property of the configuration.
Link to this section Functions
get_config_node(connection, path, session, opts \\ [])
@spec get_config_node(Tesla.Env.client(), String.t(), String.t(), keyword()) :: {:ok, OpenXchangeClient.Model.ConfigResponse.t()} | {:error, Tesla.Env.t()}
Gets data of a configuration node. The configuration is stored in a tree. Each node of the tree has a name and a value. The values of leaf nodes are strings which store the actual configuration data. The values of inner nodes are defined recursively as objects with one field for each child node. The name and the value of each field is the name and the value of the corresponding child node, respectively.
parameters
Parameters
- connection (OpenXchangeClient.Connection): Connection to server
- path (String.t): The path to the node.
- session (String.t): A session ID previously obtained from the login module.
- opts (KeywordList): [optional] Optional parameters
returns
Returns
on success {:error, Tesla.Env.t} on failure
get_config_property(connection, session, name, opts \\ [])
@spec get_config_property(Tesla.Env.client(), String.t(), String.t(), keyword()) :: {:ok, OpenXchangeClient.Model.ConfigPropertyResponse.t()} | {:error, Tesla.Env.t()}
Gets a property of the configuration.
parameters
Parameters
- connection (OpenXchangeClient.Connection): Connection to server
- session (String.t): A session ID previously obtained from the login module.
- name (String.t): The name of the property to return.
- opts (KeywordList): [optional] Optional parameters
returns
Returns
on success {:error, Tesla.Env.t} on failure
put_config_node(connection, path, session, body, opts \\ [])
@spec put_config_node( Tesla.Env.client(), String.t(), String.t(), OpenXchangeClient.Model.ConfigBody.t(), keyword() ) :: {:ok, OpenXchangeClient.Model.CommonResponse.t()} | {:error, Tesla.Env.t()}
Sets the value of a configuration node. The configuration is stored in a tree. Each node of the tree has a name and a value. The values of leaf nodes are strings which store the actual configuration data. The values of inner nodes are defined recursively as objects with one field for each child node. The name and the value of each field is the name and the value of the corresponding child node, respectively.
parameters
Parameters
- connection (OpenXchangeClient.Connection): Connection to server
- path (String.t): The path to the node.
- session (String.t): A session ID previously obtained from the login module.
- body (ConfigBody): A JSON object containing the value of the config node.
- opts (KeywordList): [optional] Optional parameters
returns
Returns
on success {:error, Tesla.Env.t} on failure
set_config_property(connection, session, name, body, opts \\ [])
@spec set_config_property( Tesla.Env.client(), String.t(), String.t(), OpenXchangeClient.Model.ConfigPropertyBody.t(), keyword() ) :: {:ok, OpenXchangeClient.Model.ConfigPropertyResponse.t()} | {:error, Tesla.Env.t()}
Sets a property of the configuration.
parameters
Parameters
- connection (OpenXchangeClient.Connection): Connection to server
- session (String.t): A session ID previously obtained from the login module.
- name (String.t): The name of the property to return.
- body (ConfigPropertyBody): A JSON object providing the value to set (Example: {"value":"test123"}).
- opts (KeywordList): [optional] Optional parameters
returns
Returns
on success {:error, Tesla.Env.t} on failure