mirror of
https://github.com/asterisk/asterisk.git
synced 2025-09-04 03:50:31 +00:00
ARI: Support channel variables in originate
This adds back in support for specifying channel variables during an originate without compromising the ability to specify query parameters in the JSON body. This was accomplished by generating the body-parsing code in a separate function instead of being integrated with the URI query parameter parsing code such that it could be called by paths with body parameters. This is transparent to the user of the API and prevents manual duplication of code or data structures. (closes issue ASTERISK-23051) Review: https://reviewboard.asterisk.org/r/3122/ Reported by: Matt Jordan ........ Merged revisions 406003 from http://svn.asterisk.org/svn/asterisk/branches/12 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@406006 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
@@ -74,6 +74,17 @@ struct ast_ari_applications_subscribe_args {
|
||||
/*! \brief Parsing context for event_source. */
|
||||
char *event_source_parse;
|
||||
};
|
||||
/*!
|
||||
* \brief Body parsing function for /applications/{applicationName}/subscription.
|
||||
* \param body The JSON body from which to parse parameters.
|
||||
* \param[out] args The args structure to parse into.
|
||||
* \retval zero on success
|
||||
* \retval non-zero on failure
|
||||
*/
|
||||
int ast_ari_applications_subscribe_parse_body(
|
||||
struct ast_json *body,
|
||||
struct ast_ari_applications_subscribe_args *args);
|
||||
|
||||
/*!
|
||||
* \brief Subscribe an application to a event source.
|
||||
*
|
||||
@@ -95,6 +106,17 @@ struct ast_ari_applications_unsubscribe_args {
|
||||
/*! \brief Parsing context for event_source. */
|
||||
char *event_source_parse;
|
||||
};
|
||||
/*!
|
||||
* \brief Body parsing function for /applications/{applicationName}/subscription.
|
||||
* \param body The JSON body from which to parse parameters.
|
||||
* \param[out] args The args structure to parse into.
|
||||
* \retval zero on success
|
||||
* \retval non-zero on failure
|
||||
*/
|
||||
int ast_ari_applications_unsubscribe_parse_body(
|
||||
struct ast_json *body,
|
||||
struct ast_ari_applications_unsubscribe_args *args);
|
||||
|
||||
/*!
|
||||
* \brief Unsubscribe an application from an event source.
|
||||
*
|
||||
|
Reference in New Issue
Block a user