@ -2171,6 +2171,7 @@ int ast_ari_validate_application_replaced(struct ast_json *json)
struct ast_json_iter * iter ;
int has_type = 0 ;
int has_application = 0 ;
int has_timestamp = 0 ;
for ( iter = ast_json_object_iter ( json ) ; iter ; iter = ast_json_object_iter_next ( json , iter ) ) {
if ( strcmp ( " asterisk_id " , ast_json_object_iter_key ( iter ) ) = = 0 ) {
@ -2204,6 +2205,7 @@ int ast_ari_validate_application_replaced(struct ast_json *json)
} else
if ( strcmp ( " timestamp " , ast_json_object_iter_key ( iter ) ) = = 0 ) {
int prop_is_valid ;
has_timestamp = 1 ;
prop_is_valid = ast_ari_validate_date (
ast_json_object_iter_value ( iter ) ) ;
if ( ! prop_is_valid ) {
@ -2229,6 +2231,11 @@ int ast_ari_validate_application_replaced(struct ast_json *json)
res = 0 ;
}
if ( ! has_timestamp ) {
ast_log ( LOG_ERROR , " ARI ApplicationReplaced missing required field timestamp \n " ) ;
res = 0 ;
}
return res ;
}
@ -2243,6 +2250,7 @@ int ast_ari_validate_bridge_attended_transfer(struct ast_json *json)
struct ast_json_iter * iter ;
int has_type = 0 ;
int has_application = 0 ;
int has_timestamp = 0 ;
int has_destination_type = 0 ;
int has_is_external = 0 ;
int has_result = 0 ;
@ -2281,6 +2289,7 @@ int ast_ari_validate_bridge_attended_transfer(struct ast_json *json)
} else
if ( strcmp ( " timestamp " , ast_json_object_iter_key ( iter ) ) = = 0 ) {
int prop_is_valid ;
has_timestamp = 1 ;
prop_is_valid = ast_ari_validate_date (
ast_json_object_iter_value ( iter ) ) ;
if ( ! prop_is_valid ) {
@ -2455,6 +2464,11 @@ int ast_ari_validate_bridge_attended_transfer(struct ast_json *json)
res = 0 ;
}
if ( ! has_timestamp ) {
ast_log ( LOG_ERROR , " ARI BridgeAttendedTransfer missing required field timestamp \n " ) ;
res = 0 ;
}
if ( ! has_destination_type ) {
ast_log ( LOG_ERROR , " ARI BridgeAttendedTransfer missing required field destination_type \n " ) ;
res = 0 ;
@ -2494,6 +2508,7 @@ int ast_ari_validate_bridge_blind_transfer(struct ast_json *json)
struct ast_json_iter * iter ;
int has_type = 0 ;
int has_application = 0 ;
int has_timestamp = 0 ;
int has_channel = 0 ;
int has_context = 0 ;
int has_exten = 0 ;
@ -2532,6 +2547,7 @@ int ast_ari_validate_bridge_blind_transfer(struct ast_json *json)
} else
if ( strcmp ( " timestamp " , ast_json_object_iter_key ( iter ) ) = = 0 ) {
int prop_is_valid ;
has_timestamp = 1 ;
prop_is_valid = ast_ari_validate_date (
ast_json_object_iter_value ( iter ) ) ;
if ( ! prop_is_valid ) {
@ -2634,6 +2650,11 @@ int ast_ari_validate_bridge_blind_transfer(struct ast_json *json)
res = 0 ;
}
if ( ! has_timestamp ) {
ast_log ( LOG_ERROR , " ARI BridgeBlindTransfer missing required field timestamp \n " ) ;
res = 0 ;
}
if ( ! has_channel ) {
ast_log ( LOG_ERROR , " ARI BridgeBlindTransfer missing required field channel \n " ) ;
res = 0 ;
@ -2673,6 +2694,7 @@ int ast_ari_validate_bridge_created(struct ast_json *json)
struct ast_json_iter * iter ;
int has_type = 0 ;
int has_application = 0 ;
int has_timestamp = 0 ;
int has_bridge = 0 ;
for ( iter = ast_json_object_iter ( json ) ; iter ; iter = ast_json_object_iter_next ( json , iter ) ) {
@ -2707,6 +2729,7 @@ int ast_ari_validate_bridge_created(struct ast_json *json)
} else
if ( strcmp ( " timestamp " , ast_json_object_iter_key ( iter ) ) = = 0 ) {
int prop_is_valid ;
has_timestamp = 1 ;
prop_is_valid = ast_ari_validate_date (
ast_json_object_iter_value ( iter ) ) ;
if ( ! prop_is_valid ) {
@ -2742,6 +2765,11 @@ int ast_ari_validate_bridge_created(struct ast_json *json)
res = 0 ;
}
if ( ! has_timestamp ) {
ast_log ( LOG_ERROR , " ARI BridgeCreated missing required field timestamp \n " ) ;
res = 0 ;
}
if ( ! has_bridge ) {
ast_log ( LOG_ERROR , " ARI BridgeCreated missing required field bridge \n " ) ;
res = 0 ;
@ -2761,6 +2789,7 @@ int ast_ari_validate_bridge_destroyed(struct ast_json *json)
struct ast_json_iter * iter ;
int has_type = 0 ;
int has_application = 0 ;
int has_timestamp = 0 ;
int has_bridge = 0 ;
for ( iter = ast_json_object_iter ( json ) ; iter ; iter = ast_json_object_iter_next ( json , iter ) ) {
@ -2795,6 +2824,7 @@ int ast_ari_validate_bridge_destroyed(struct ast_json *json)
} else
if ( strcmp ( " timestamp " , ast_json_object_iter_key ( iter ) ) = = 0 ) {
int prop_is_valid ;
has_timestamp = 1 ;
prop_is_valid = ast_ari_validate_date (
ast_json_object_iter_value ( iter ) ) ;
if ( ! prop_is_valid ) {
@ -2830,6 +2860,11 @@ int ast_ari_validate_bridge_destroyed(struct ast_json *json)
res = 0 ;
}
if ( ! has_timestamp ) {
ast_log ( LOG_ERROR , " ARI BridgeDestroyed missing required field timestamp \n " ) ;
res = 0 ;
}
if ( ! has_bridge ) {
ast_log ( LOG_ERROR , " ARI BridgeDestroyed missing required field bridge \n " ) ;
res = 0 ;
@ -2849,6 +2884,7 @@ int ast_ari_validate_bridge_merged(struct ast_json *json)
struct ast_json_iter * iter ;
int has_type = 0 ;
int has_application = 0 ;
int has_timestamp = 0 ;
int has_bridge = 0 ;
int has_bridge_from = 0 ;
@ -2884,6 +2920,7 @@ int ast_ari_validate_bridge_merged(struct ast_json *json)
} else
if ( strcmp ( " timestamp " , ast_json_object_iter_key ( iter ) ) = = 0 ) {
int prop_is_valid ;
has_timestamp = 1 ;
prop_is_valid = ast_ari_validate_date (
ast_json_object_iter_value ( iter ) ) ;
if ( ! prop_is_valid ) {
@ -2929,6 +2966,11 @@ int ast_ari_validate_bridge_merged(struct ast_json *json)
res = 0 ;
}
if ( ! has_timestamp ) {
ast_log ( LOG_ERROR , " ARI BridgeMerged missing required field timestamp \n " ) ;
res = 0 ;
}
if ( ! has_bridge ) {
ast_log ( LOG_ERROR , " ARI BridgeMerged missing required field bridge \n " ) ;
res = 0 ;
@ -2953,6 +2995,7 @@ int ast_ari_validate_bridge_video_source_changed(struct ast_json *json)
struct ast_json_iter * iter ;
int has_type = 0 ;
int has_application = 0 ;
int has_timestamp = 0 ;
int has_bridge = 0 ;
for ( iter = ast_json_object_iter ( json ) ; iter ; iter = ast_json_object_iter_next ( json , iter ) ) {
@ -2987,6 +3030,7 @@ int ast_ari_validate_bridge_video_source_changed(struct ast_json *json)
} else
if ( strcmp ( " timestamp " , ast_json_object_iter_key ( iter ) ) = = 0 ) {
int prop_is_valid ;
has_timestamp = 1 ;
prop_is_valid = ast_ari_validate_date (
ast_json_object_iter_value ( iter ) ) ;
if ( ! prop_is_valid ) {
@ -3031,6 +3075,11 @@ int ast_ari_validate_bridge_video_source_changed(struct ast_json *json)
res = 0 ;
}
if ( ! has_timestamp ) {
ast_log ( LOG_ERROR , " ARI BridgeVideoSourceChanged missing required field timestamp \n " ) ;
res = 0 ;
}
if ( ! has_bridge ) {
ast_log ( LOG_ERROR , " ARI BridgeVideoSourceChanged missing required field bridge \n " ) ;
res = 0 ;
@ -3050,6 +3099,7 @@ int ast_ari_validate_channel_caller_id(struct ast_json *json)
struct ast_json_iter * iter ;
int has_type = 0 ;
int has_application = 0 ;
int has_timestamp = 0 ;
int has_caller_presentation = 0 ;
int has_caller_presentation_txt = 0 ;
int has_channel = 0 ;
@ -3086,6 +3136,7 @@ int ast_ari_validate_channel_caller_id(struct ast_json *json)
} else
if ( strcmp ( " timestamp " , ast_json_object_iter_key ( iter ) ) = = 0 ) {
int prop_is_valid ;
has_timestamp = 1 ;
prop_is_valid = ast_ari_validate_date (
ast_json_object_iter_value ( iter ) ) ;
if ( ! prop_is_valid ) {
@ -3141,6 +3192,11 @@ int ast_ari_validate_channel_caller_id(struct ast_json *json)
res = 0 ;
}
if ( ! has_timestamp ) {
ast_log ( LOG_ERROR , " ARI ChannelCallerId missing required field timestamp \n " ) ;
res = 0 ;
}
if ( ! has_caller_presentation ) {
ast_log ( LOG_ERROR , " ARI ChannelCallerId missing required field caller_presentation \n " ) ;
res = 0 ;
@ -3170,6 +3226,7 @@ int ast_ari_validate_channel_connected_line(struct ast_json *json)
struct ast_json_iter * iter ;
int has_type = 0 ;
int has_application = 0 ;
int has_timestamp = 0 ;
int has_channel = 0 ;
for ( iter = ast_json_object_iter ( json ) ; iter ; iter = ast_json_object_iter_next ( json , iter ) ) {
@ -3204,6 +3261,7 @@ int ast_ari_validate_channel_connected_line(struct ast_json *json)
} else
if ( strcmp ( " timestamp " , ast_json_object_iter_key ( iter ) ) = = 0 ) {
int prop_is_valid ;
has_timestamp = 1 ;
prop_is_valid = ast_ari_validate_date (
ast_json_object_iter_value ( iter ) ) ;
if ( ! prop_is_valid ) {
@ -3239,6 +3297,11 @@ int ast_ari_validate_channel_connected_line(struct ast_json *json)
res = 0 ;
}
if ( ! has_timestamp ) {
ast_log ( LOG_ERROR , " ARI ChannelConnectedLine missing required field timestamp \n " ) ;
res = 0 ;
}
if ( ! has_channel ) {
ast_log ( LOG_ERROR , " ARI ChannelConnectedLine missing required field channel \n " ) ;
res = 0 ;
@ -3258,6 +3321,7 @@ int ast_ari_validate_channel_created(struct ast_json *json)
struct ast_json_iter * iter ;
int has_type = 0 ;
int has_application = 0 ;
int has_timestamp = 0 ;
int has_channel = 0 ;
for ( iter = ast_json_object_iter ( json ) ; iter ; iter = ast_json_object_iter_next ( json , iter ) ) {
@ -3292,6 +3356,7 @@ int ast_ari_validate_channel_created(struct ast_json *json)
} else
if ( strcmp ( " timestamp " , ast_json_object_iter_key ( iter ) ) = = 0 ) {
int prop_is_valid ;
has_timestamp = 1 ;
prop_is_valid = ast_ari_validate_date (
ast_json_object_iter_value ( iter ) ) ;
if ( ! prop_is_valid ) {
@ -3327,6 +3392,11 @@ int ast_ari_validate_channel_created(struct ast_json *json)
res = 0 ;
}
if ( ! has_timestamp ) {
ast_log ( LOG_ERROR , " ARI ChannelCreated missing required field timestamp \n " ) ;
res = 0 ;
}
if ( ! has_channel ) {
ast_log ( LOG_ERROR , " ARI ChannelCreated missing required field channel \n " ) ;
res = 0 ;
@ -3346,6 +3416,7 @@ int ast_ari_validate_channel_destroyed(struct ast_json *json)
struct ast_json_iter * iter ;
int has_type = 0 ;
int has_application = 0 ;
int has_timestamp = 0 ;
int has_cause = 0 ;
int has_cause_txt = 0 ;
int has_channel = 0 ;
@ -3382,6 +3453,7 @@ int ast_ari_validate_channel_destroyed(struct ast_json *json)
} else
if ( strcmp ( " timestamp " , ast_json_object_iter_key ( iter ) ) = = 0 ) {
int prop_is_valid ;
has_timestamp = 1 ;
prop_is_valid = ast_ari_validate_date (
ast_json_object_iter_value ( iter ) ) ;
if ( ! prop_is_valid ) {
@ -3437,6 +3509,11 @@ int ast_ari_validate_channel_destroyed(struct ast_json *json)
res = 0 ;
}
if ( ! has_timestamp ) {
ast_log ( LOG_ERROR , " ARI ChannelDestroyed missing required field timestamp \n " ) ;
res = 0 ;
}
if ( ! has_cause ) {
ast_log ( LOG_ERROR , " ARI ChannelDestroyed missing required field cause \n " ) ;
res = 0 ;
@ -3466,6 +3543,7 @@ int ast_ari_validate_channel_dialplan(struct ast_json *json)
struct ast_json_iter * iter ;
int has_type = 0 ;
int has_application = 0 ;
int has_timestamp = 0 ;
int has_channel = 0 ;
int has_dialplan_app = 0 ;
int has_dialplan_app_data = 0 ;
@ -3502,6 +3580,7 @@ int ast_ari_validate_channel_dialplan(struct ast_json *json)
} else
if ( strcmp ( " timestamp " , ast_json_object_iter_key ( iter ) ) = = 0 ) {
int prop_is_valid ;
has_timestamp = 1 ;
prop_is_valid = ast_ari_validate_date (
ast_json_object_iter_value ( iter ) ) ;
if ( ! prop_is_valid ) {
@ -3557,6 +3636,11 @@ int ast_ari_validate_channel_dialplan(struct ast_json *json)
res = 0 ;
}
if ( ! has_timestamp ) {
ast_log ( LOG_ERROR , " ARI ChannelDialplan missing required field timestamp \n " ) ;
res = 0 ;
}
if ( ! has_channel ) {
ast_log ( LOG_ERROR , " ARI ChannelDialplan missing required field channel \n " ) ;
res = 0 ;
@ -3586,6 +3670,7 @@ int ast_ari_validate_channel_dtmf_received(struct ast_json *json)
struct ast_json_iter * iter ;
int has_type = 0 ;
int has_application = 0 ;
int has_timestamp = 0 ;
int has_channel = 0 ;
int has_digit = 0 ;
int has_duration_ms = 0 ;
@ -3622,6 +3707,7 @@ int ast_ari_validate_channel_dtmf_received(struct ast_json *json)
} else
if ( strcmp ( " timestamp " , ast_json_object_iter_key ( iter ) ) = = 0 ) {
int prop_is_valid ;
has_timestamp = 1 ;
prop_is_valid = ast_ari_validate_date (
ast_json_object_iter_value ( iter ) ) ;
if ( ! prop_is_valid ) {
@ -3677,6 +3763,11 @@ int ast_ari_validate_channel_dtmf_received(struct ast_json *json)
res = 0 ;
}
if ( ! has_timestamp ) {
ast_log ( LOG_ERROR , " ARI ChannelDtmfReceived missing required field timestamp \n " ) ;
res = 0 ;
}
if ( ! has_channel ) {
ast_log ( LOG_ERROR , " ARI ChannelDtmfReceived missing required field channel \n " ) ;
res = 0 ;
@ -3706,6 +3797,7 @@ int ast_ari_validate_channel_entered_bridge(struct ast_json *json)
struct ast_json_iter * iter ;
int has_type = 0 ;
int has_application = 0 ;
int has_timestamp = 0 ;
int has_bridge = 0 ;
for ( iter = ast_json_object_iter ( json ) ; iter ; iter = ast_json_object_iter_next ( json , iter ) ) {
@ -3740,6 +3832,7 @@ int ast_ari_validate_channel_entered_bridge(struct ast_json *json)
} else
if ( strcmp ( " timestamp " , ast_json_object_iter_key ( iter ) ) = = 0 ) {
int prop_is_valid ;
has_timestamp = 1 ;
prop_is_valid = ast_ari_validate_date (
ast_json_object_iter_value ( iter ) ) ;
if ( ! prop_is_valid ) {
@ -3784,6 +3877,11 @@ int ast_ari_validate_channel_entered_bridge(struct ast_json *json)
res = 0 ;
}
if ( ! has_timestamp ) {
ast_log ( LOG_ERROR , " ARI ChannelEnteredBridge missing required field timestamp \n " ) ;
res = 0 ;
}
if ( ! has_bridge ) {
ast_log ( LOG_ERROR , " ARI ChannelEnteredBridge missing required field bridge \n " ) ;
res = 0 ;
@ -3803,6 +3901,7 @@ int ast_ari_validate_channel_hangup_request(struct ast_json *json)
struct ast_json_iter * iter ;
int has_type = 0 ;
int has_application = 0 ;
int has_timestamp = 0 ;
int has_channel = 0 ;
for ( iter = ast_json_object_iter ( json ) ; iter ; iter = ast_json_object_iter_next ( json , iter ) ) {
@ -3837,6 +3936,7 @@ int ast_ari_validate_channel_hangup_request(struct ast_json *json)
} else
if ( strcmp ( " timestamp " , ast_json_object_iter_key ( iter ) ) = = 0 ) {
int prop_is_valid ;
has_timestamp = 1 ;
prop_is_valid = ast_ari_validate_date (
ast_json_object_iter_value ( iter ) ) ;
if ( ! prop_is_valid ) {
@ -3890,6 +3990,11 @@ int ast_ari_validate_channel_hangup_request(struct ast_json *json)
res = 0 ;
}
if ( ! has_timestamp ) {
ast_log ( LOG_ERROR , " ARI ChannelHangupRequest missing required field timestamp \n " ) ;
res = 0 ;
}
if ( ! has_channel ) {
ast_log ( LOG_ERROR , " ARI ChannelHangupRequest missing required field channel \n " ) ;
res = 0 ;
@ -3909,6 +4014,7 @@ int ast_ari_validate_channel_hold(struct ast_json *json)
struct ast_json_iter * iter ;
int has_type = 0 ;
int has_application = 0 ;
int has_timestamp = 0 ;
int has_channel = 0 ;
for ( iter = ast_json_object_iter ( json ) ; iter ; iter = ast_json_object_iter_next ( json , iter ) ) {
@ -3943,6 +4049,7 @@ int ast_ari_validate_channel_hold(struct ast_json *json)
} else
if ( strcmp ( " timestamp " , ast_json_object_iter_key ( iter ) ) = = 0 ) {
int prop_is_valid ;
has_timestamp = 1 ;
prop_is_valid = ast_ari_validate_date (
ast_json_object_iter_value ( iter ) ) ;
if ( ! prop_is_valid ) {
@ -3987,6 +4094,11 @@ int ast_ari_validate_channel_hold(struct ast_json *json)
res = 0 ;
}
if ( ! has_timestamp ) {
ast_log ( LOG_ERROR , " ARI ChannelHold missing required field timestamp \n " ) ;
res = 0 ;
}
if ( ! has_channel ) {
ast_log ( LOG_ERROR , " ARI ChannelHold missing required field channel \n " ) ;
res = 0 ;
@ -4006,6 +4118,7 @@ int ast_ari_validate_channel_left_bridge(struct ast_json *json)
struct ast_json_iter * iter ;
int has_type = 0 ;
int has_application = 0 ;
int has_timestamp = 0 ;
int has_bridge = 0 ;
int has_channel = 0 ;
@ -4041,6 +4154,7 @@ int ast_ari_validate_channel_left_bridge(struct ast_json *json)
} else
if ( strcmp ( " timestamp " , ast_json_object_iter_key ( iter ) ) = = 0 ) {
int prop_is_valid ;
has_timestamp = 1 ;
prop_is_valid = ast_ari_validate_date (
ast_json_object_iter_value ( iter ) ) ;
if ( ! prop_is_valid ) {
@ -4086,6 +4200,11 @@ int ast_ari_validate_channel_left_bridge(struct ast_json *json)
res = 0 ;
}
if ( ! has_timestamp ) {
ast_log ( LOG_ERROR , " ARI ChannelLeftBridge missing required field timestamp \n " ) ;
res = 0 ;
}
if ( ! has_bridge ) {
ast_log ( LOG_ERROR , " ARI ChannelLeftBridge missing required field bridge \n " ) ;
res = 0 ;
@ -4110,6 +4229,7 @@ int ast_ari_validate_channel_state_change(struct ast_json *json)
struct ast_json_iter * iter ;
int has_type = 0 ;
int has_application = 0 ;
int has_timestamp = 0 ;
int has_channel = 0 ;
for ( iter = ast_json_object_iter ( json ) ; iter ; iter = ast_json_object_iter_next ( json , iter ) ) {
@ -4144,6 +4264,7 @@ int ast_ari_validate_channel_state_change(struct ast_json *json)
} else
if ( strcmp ( " timestamp " , ast_json_object_iter_key ( iter ) ) = = 0 ) {
int prop_is_valid ;
has_timestamp = 1 ;
prop_is_valid = ast_ari_validate_date (
ast_json_object_iter_value ( iter ) ) ;
if ( ! prop_is_valid ) {
@ -4179,6 +4300,11 @@ int ast_ari_validate_channel_state_change(struct ast_json *json)
res = 0 ;
}
if ( ! has_timestamp ) {
ast_log ( LOG_ERROR , " ARI ChannelStateChange missing required field timestamp \n " ) ;
res = 0 ;
}
if ( ! has_channel ) {
ast_log ( LOG_ERROR , " ARI ChannelStateChange missing required field channel \n " ) ;
res = 0 ;
@ -4198,6 +4324,7 @@ int ast_ari_validate_channel_talking_finished(struct ast_json *json)
struct ast_json_iter * iter ;
int has_type = 0 ;
int has_application = 0 ;
int has_timestamp = 0 ;
int has_channel = 0 ;
int has_duration = 0 ;
@ -4233,6 +4360,7 @@ int ast_ari_validate_channel_talking_finished(struct ast_json *json)
} else
if ( strcmp ( " timestamp " , ast_json_object_iter_key ( iter ) ) = = 0 ) {
int prop_is_valid ;
has_timestamp = 1 ;
prop_is_valid = ast_ari_validate_date (
ast_json_object_iter_value ( iter ) ) ;
if ( ! prop_is_valid ) {
@ -4278,6 +4406,11 @@ int ast_ari_validate_channel_talking_finished(struct ast_json *json)
res = 0 ;
}
if ( ! has_timestamp ) {
ast_log ( LOG_ERROR , " ARI ChannelTalkingFinished missing required field timestamp \n " ) ;
res = 0 ;
}
if ( ! has_channel ) {
ast_log ( LOG_ERROR , " ARI ChannelTalkingFinished missing required field channel \n " ) ;
res = 0 ;
@ -4302,6 +4435,7 @@ int ast_ari_validate_channel_talking_started(struct ast_json *json)
struct ast_json_iter * iter ;
int has_type = 0 ;
int has_application = 0 ;
int has_timestamp = 0 ;
int has_channel = 0 ;
for ( iter = ast_json_object_iter ( json ) ; iter ; iter = ast_json_object_iter_next ( json , iter ) ) {
@ -4336,6 +4470,7 @@ int ast_ari_validate_channel_talking_started(struct ast_json *json)
} else
if ( strcmp ( " timestamp " , ast_json_object_iter_key ( iter ) ) = = 0 ) {
int prop_is_valid ;
has_timestamp = 1 ;
prop_is_valid = ast_ari_validate_date (
ast_json_object_iter_value ( iter ) ) ;
if ( ! prop_is_valid ) {
@ -4371,6 +4506,11 @@ int ast_ari_validate_channel_talking_started(struct ast_json *json)
res = 0 ;
}
if ( ! has_timestamp ) {
ast_log ( LOG_ERROR , " ARI ChannelTalkingStarted missing required field timestamp \n " ) ;
res = 0 ;
}
if ( ! has_channel ) {
ast_log ( LOG_ERROR , " ARI ChannelTalkingStarted missing required field channel \n " ) ;
res = 0 ;
@ -4390,6 +4530,7 @@ int ast_ari_validate_channel_unhold(struct ast_json *json)
struct ast_json_iter * iter ;
int has_type = 0 ;
int has_application = 0 ;
int has_timestamp = 0 ;
int has_channel = 0 ;
for ( iter = ast_json_object_iter ( json ) ; iter ; iter = ast_json_object_iter_next ( json , iter ) ) {
@ -4424,6 +4565,7 @@ int ast_ari_validate_channel_unhold(struct ast_json *json)
} else
if ( strcmp ( " timestamp " , ast_json_object_iter_key ( iter ) ) = = 0 ) {
int prop_is_valid ;
has_timestamp = 1 ;
prop_is_valid = ast_ari_validate_date (
ast_json_object_iter_value ( iter ) ) ;
if ( ! prop_is_valid ) {
@ -4459,6 +4601,11 @@ int ast_ari_validate_channel_unhold(struct ast_json *json)
res = 0 ;
}
if ( ! has_timestamp ) {
ast_log ( LOG_ERROR , " ARI ChannelUnhold missing required field timestamp \n " ) ;
res = 0 ;
}
if ( ! has_channel ) {
ast_log ( LOG_ERROR , " ARI ChannelUnhold missing required field channel \n " ) ;
res = 0 ;
@ -4478,6 +4625,7 @@ int ast_ari_validate_channel_userevent(struct ast_json *json)
struct ast_json_iter * iter ;
int has_type = 0 ;
int has_application = 0 ;
int has_timestamp = 0 ;
int has_eventname = 0 ;
int has_userevent = 0 ;
@ -4513,6 +4661,7 @@ int ast_ari_validate_channel_userevent(struct ast_json *json)
} else
if ( strcmp ( " timestamp " , ast_json_object_iter_key ( iter ) ) = = 0 ) {
int prop_is_valid ;
has_timestamp = 1 ;
prop_is_valid = ast_ari_validate_date (
ast_json_object_iter_value ( iter ) ) ;
if ( ! prop_is_valid ) {
@ -4585,6 +4734,11 @@ int ast_ari_validate_channel_userevent(struct ast_json *json)
res = 0 ;
}
if ( ! has_timestamp ) {
ast_log ( LOG_ERROR , " ARI ChannelUserevent missing required field timestamp \n " ) ;
res = 0 ;
}
if ( ! has_eventname ) {
ast_log ( LOG_ERROR , " ARI ChannelUserevent missing required field eventname \n " ) ;
res = 0 ;
@ -4609,6 +4763,7 @@ int ast_ari_validate_channel_varset(struct ast_json *json)
struct ast_json_iter * iter ;
int has_type = 0 ;
int has_application = 0 ;
int has_timestamp = 0 ;
int has_value = 0 ;
int has_variable = 0 ;
@ -4644,6 +4799,7 @@ int ast_ari_validate_channel_varset(struct ast_json *json)
} else
if ( strcmp ( " timestamp " , ast_json_object_iter_key ( iter ) ) = = 0 ) {
int prop_is_valid ;
has_timestamp = 1 ;
prop_is_valid = ast_ari_validate_date (
ast_json_object_iter_value ( iter ) ) ;
if ( ! prop_is_valid ) {
@ -4698,6 +4854,11 @@ int ast_ari_validate_channel_varset(struct ast_json *json)
res = 0 ;
}
if ( ! has_timestamp ) {
ast_log ( LOG_ERROR , " ARI ChannelVarset missing required field timestamp \n " ) ;
res = 0 ;
}
if ( ! has_value ) {
ast_log ( LOG_ERROR , " ARI ChannelVarset missing required field value \n " ) ;
res = 0 ;
@ -4801,6 +4962,7 @@ int ast_ari_validate_contact_status_change(struct ast_json *json)
struct ast_json_iter * iter ;
int has_type = 0 ;
int has_application = 0 ;
int has_timestamp = 0 ;
int has_contact_info = 0 ;
int has_endpoint = 0 ;
@ -4836,6 +4998,7 @@ int ast_ari_validate_contact_status_change(struct ast_json *json)
} else
if ( strcmp ( " timestamp " , ast_json_object_iter_key ( iter ) ) = = 0 ) {
int prop_is_valid ;
has_timestamp = 1 ;
prop_is_valid = ast_ari_validate_date (
ast_json_object_iter_value ( iter ) ) ;
if ( ! prop_is_valid ) {
@ -4881,6 +5044,11 @@ int ast_ari_validate_contact_status_change(struct ast_json *json)
res = 0 ;
}
if ( ! has_timestamp ) {
ast_log ( LOG_ERROR , " ARI ContactStatusChange missing required field timestamp \n " ) ;
res = 0 ;
}
if ( ! has_contact_info ) {
ast_log ( LOG_ERROR , " ARI ContactStatusChange missing required field contact_info \n " ) ;
res = 0 ;
@ -4905,6 +5073,7 @@ int ast_ari_validate_device_state_changed(struct ast_json *json)
struct ast_json_iter * iter ;
int has_type = 0 ;
int has_application = 0 ;
int has_timestamp = 0 ;
int has_device_state = 0 ;
for ( iter = ast_json_object_iter ( json ) ; iter ; iter = ast_json_object_iter_next ( json , iter ) ) {
@ -4939,6 +5108,7 @@ int ast_ari_validate_device_state_changed(struct ast_json *json)
} else
if ( strcmp ( " timestamp " , ast_json_object_iter_key ( iter ) ) = = 0 ) {
int prop_is_valid ;
has_timestamp = 1 ;
prop_is_valid = ast_ari_validate_date (
ast_json_object_iter_value ( iter ) ) ;
if ( ! prop_is_valid ) {
@ -4974,6 +5144,11 @@ int ast_ari_validate_device_state_changed(struct ast_json *json)
res = 0 ;
}
if ( ! has_timestamp ) {
ast_log ( LOG_ERROR , " ARI DeviceStateChanged missing required field timestamp \n " ) ;
res = 0 ;
}
if ( ! has_device_state ) {
ast_log ( LOG_ERROR , " ARI DeviceStateChanged missing required field device_state \n " ) ;
res = 0 ;
@ -4993,6 +5168,7 @@ int ast_ari_validate_dial(struct ast_json *json)
struct ast_json_iter * iter ;
int has_type = 0 ;
int has_application = 0 ;
int has_timestamp = 0 ;
int has_dialstatus = 0 ;
int has_peer = 0 ;
@ -5028,6 +5204,7 @@ int ast_ari_validate_dial(struct ast_json *json)
} else
if ( strcmp ( " timestamp " , ast_json_object_iter_key ( iter ) ) = = 0 ) {
int prop_is_valid ;
has_timestamp = 1 ;
prop_is_valid = ast_ari_validate_date (
ast_json_object_iter_value ( iter ) ) ;
if ( ! prop_is_valid ) {
@ -5109,6 +5286,11 @@ int ast_ari_validate_dial(struct ast_json *json)
res = 0 ;
}
if ( ! has_timestamp ) {
ast_log ( LOG_ERROR , " ARI Dial missing required field timestamp \n " ) ;
res = 0 ;
}
if ( ! has_dialstatus ) {
ast_log ( LOG_ERROR , " ARI Dial missing required field dialstatus \n " ) ;
res = 0 ;
@ -5133,6 +5315,7 @@ int ast_ari_validate_endpoint_state_change(struct ast_json *json)
struct ast_json_iter * iter ;
int has_type = 0 ;
int has_application = 0 ;
int has_timestamp = 0 ;
int has_endpoint = 0 ;
for ( iter = ast_json_object_iter ( json ) ; iter ; iter = ast_json_object_iter_next ( json , iter ) ) {
@ -5167,6 +5350,7 @@ int ast_ari_validate_endpoint_state_change(struct ast_json *json)
} else
if ( strcmp ( " timestamp " , ast_json_object_iter_key ( iter ) ) = = 0 ) {
int prop_is_valid ;
has_timestamp = 1 ;
prop_is_valid = ast_ari_validate_date (
ast_json_object_iter_value ( iter ) ) ;
if ( ! prop_is_valid ) {
@ -5202,6 +5386,11 @@ int ast_ari_validate_endpoint_state_change(struct ast_json *json)
res = 0 ;
}
if ( ! has_timestamp ) {
ast_log ( LOG_ERROR , " ARI EndpointStateChange missing required field timestamp \n " ) ;
res = 0 ;
}
if ( ! has_endpoint ) {
ast_log ( LOG_ERROR , " ARI EndpointStateChange missing required field endpoint \n " ) ;
res = 0 ;
@ -5221,6 +5410,7 @@ int ast_ari_validate_event(struct ast_json *json)
struct ast_json_iter * iter ;
int has_type = 0 ;
int has_application = 0 ;
int has_timestamp = 0 ;
const char * discriminator ;
discriminator = ast_json_string_get ( ast_json_object_get ( json , " type " ) ) ;
@ -5384,6 +5574,7 @@ int ast_ari_validate_event(struct ast_json *json)
} else
if ( strcmp ( " timestamp " , ast_json_object_iter_key ( iter ) ) = = 0 ) {
int prop_is_valid ;
has_timestamp = 1 ;
prop_is_valid = ast_ari_validate_date (
ast_json_object_iter_value ( iter ) ) ;
if ( ! prop_is_valid ) {
@ -5409,6 +5600,11 @@ int ast_ari_validate_event(struct ast_json *json)
res = 0 ;
}
if ( ! has_timestamp ) {
ast_log ( LOG_ERROR , " ARI Event missing required field timestamp \n " ) ;
res = 0 ;
}
return res ;
}
@ -5744,6 +5940,7 @@ int ast_ari_validate_peer_status_change(struct ast_json *json)
struct ast_json_iter * iter ;
int has_type = 0 ;
int has_application = 0 ;
int has_timestamp = 0 ;
int has_endpoint = 0 ;
int has_peer = 0 ;
@ -5779,6 +5976,7 @@ int ast_ari_validate_peer_status_change(struct ast_json *json)
} else
if ( strcmp ( " timestamp " , ast_json_object_iter_key ( iter ) ) = = 0 ) {
int prop_is_valid ;
has_timestamp = 1 ;
prop_is_valid = ast_ari_validate_date (
ast_json_object_iter_value ( iter ) ) ;
if ( ! prop_is_valid ) {
@ -5824,6 +6022,11 @@ int ast_ari_validate_peer_status_change(struct ast_json *json)
res = 0 ;
}
if ( ! has_timestamp ) {
ast_log ( LOG_ERROR , " ARI PeerStatusChange missing required field timestamp \n " ) ;
res = 0 ;
}
if ( ! has_endpoint ) {
ast_log ( LOG_ERROR , " ARI PeerStatusChange missing required field endpoint \n " ) ;
res = 0 ;
@ -5848,6 +6051,7 @@ int ast_ari_validate_playback_continuing(struct ast_json *json)
struct ast_json_iter * iter ;
int has_type = 0 ;
int has_application = 0 ;
int has_timestamp = 0 ;
int has_playback = 0 ;
for ( iter = ast_json_object_iter ( json ) ; iter ; iter = ast_json_object_iter_next ( json , iter ) ) {
@ -5882,6 +6086,7 @@ int ast_ari_validate_playback_continuing(struct ast_json *json)
} else
if ( strcmp ( " timestamp " , ast_json_object_iter_key ( iter ) ) = = 0 ) {
int prop_is_valid ;
has_timestamp = 1 ;
prop_is_valid = ast_ari_validate_date (
ast_json_object_iter_value ( iter ) ) ;
if ( ! prop_is_valid ) {
@ -5917,6 +6122,11 @@ int ast_ari_validate_playback_continuing(struct ast_json *json)
res = 0 ;
}
if ( ! has_timestamp ) {
ast_log ( LOG_ERROR , " ARI PlaybackContinuing missing required field timestamp \n " ) ;
res = 0 ;
}
if ( ! has_playback ) {
ast_log ( LOG_ERROR , " ARI PlaybackContinuing missing required field playback \n " ) ;
res = 0 ;
@ -5936,6 +6146,7 @@ int ast_ari_validate_playback_finished(struct ast_json *json)
struct ast_json_iter * iter ;
int has_type = 0 ;
int has_application = 0 ;
int has_timestamp = 0 ;
int has_playback = 0 ;
for ( iter = ast_json_object_iter ( json ) ; iter ; iter = ast_json_object_iter_next ( json , iter ) ) {
@ -5970,6 +6181,7 @@ int ast_ari_validate_playback_finished(struct ast_json *json)
} else
if ( strcmp ( " timestamp " , ast_json_object_iter_key ( iter ) ) = = 0 ) {
int prop_is_valid ;
has_timestamp = 1 ;
prop_is_valid = ast_ari_validate_date (
ast_json_object_iter_value ( iter ) ) ;
if ( ! prop_is_valid ) {
@ -6005,6 +6217,11 @@ int ast_ari_validate_playback_finished(struct ast_json *json)
res = 0 ;
}
if ( ! has_timestamp ) {
ast_log ( LOG_ERROR , " ARI PlaybackFinished missing required field timestamp \n " ) ;
res = 0 ;
}
if ( ! has_playback ) {
ast_log ( LOG_ERROR , " ARI PlaybackFinished missing required field playback \n " ) ;
res = 0 ;
@ -6024,6 +6241,7 @@ int ast_ari_validate_playback_started(struct ast_json *json)
struct ast_json_iter * iter ;
int has_type = 0 ;
int has_application = 0 ;
int has_timestamp = 0 ;
int has_playback = 0 ;
for ( iter = ast_json_object_iter ( json ) ; iter ; iter = ast_json_object_iter_next ( json , iter ) ) {
@ -6058,6 +6276,7 @@ int ast_ari_validate_playback_started(struct ast_json *json)
} else
if ( strcmp ( " timestamp " , ast_json_object_iter_key ( iter ) ) = = 0 ) {
int prop_is_valid ;
has_timestamp = 1 ;
prop_is_valid = ast_ari_validate_date (
ast_json_object_iter_value ( iter ) ) ;
if ( ! prop_is_valid ) {
@ -6093,6 +6312,11 @@ int ast_ari_validate_playback_started(struct ast_json *json)
res = 0 ;
}
if ( ! has_timestamp ) {
ast_log ( LOG_ERROR , " ARI PlaybackStarted missing required field timestamp \n " ) ;
res = 0 ;
}
if ( ! has_playback ) {
ast_log ( LOG_ERROR , " ARI PlaybackStarted missing required field playback \n " ) ;
res = 0 ;
@ -6112,6 +6336,7 @@ int ast_ari_validate_recording_failed(struct ast_json *json)
struct ast_json_iter * iter ;
int has_type = 0 ;
int has_application = 0 ;
int has_timestamp = 0 ;
int has_recording = 0 ;
for ( iter = ast_json_object_iter ( json ) ; iter ; iter = ast_json_object_iter_next ( json , iter ) ) {
@ -6146,6 +6371,7 @@ int ast_ari_validate_recording_failed(struct ast_json *json)
} else
if ( strcmp ( " timestamp " , ast_json_object_iter_key ( iter ) ) = = 0 ) {
int prop_is_valid ;
has_timestamp = 1 ;
prop_is_valid = ast_ari_validate_date (
ast_json_object_iter_value ( iter ) ) ;
if ( ! prop_is_valid ) {
@ -6181,6 +6407,11 @@ int ast_ari_validate_recording_failed(struct ast_json *json)
res = 0 ;
}
if ( ! has_timestamp ) {
ast_log ( LOG_ERROR , " ARI RecordingFailed missing required field timestamp \n " ) ;
res = 0 ;
}
if ( ! has_recording ) {
ast_log ( LOG_ERROR , " ARI RecordingFailed missing required field recording \n " ) ;
res = 0 ;
@ -6200,6 +6431,7 @@ int ast_ari_validate_recording_finished(struct ast_json *json)
struct ast_json_iter * iter ;
int has_type = 0 ;
int has_application = 0 ;
int has_timestamp = 0 ;
int has_recording = 0 ;
for ( iter = ast_json_object_iter ( json ) ; iter ; iter = ast_json_object_iter_next ( json , iter ) ) {
@ -6234,6 +6466,7 @@ int ast_ari_validate_recording_finished(struct ast_json *json)
} else
if ( strcmp ( " timestamp " , ast_json_object_iter_key ( iter ) ) = = 0 ) {
int prop_is_valid ;
has_timestamp = 1 ;
prop_is_valid = ast_ari_validate_date (
ast_json_object_iter_value ( iter ) ) ;
if ( ! prop_is_valid ) {
@ -6269,6 +6502,11 @@ int ast_ari_validate_recording_finished(struct ast_json *json)
res = 0 ;
}
if ( ! has_timestamp ) {
ast_log ( LOG_ERROR , " ARI RecordingFinished missing required field timestamp \n " ) ;
res = 0 ;
}
if ( ! has_recording ) {
ast_log ( LOG_ERROR , " ARI RecordingFinished missing required field recording \n " ) ;
res = 0 ;
@ -6288,6 +6526,7 @@ int ast_ari_validate_recording_started(struct ast_json *json)
struct ast_json_iter * iter ;
int has_type = 0 ;
int has_application = 0 ;
int has_timestamp = 0 ;
int has_recording = 0 ;
for ( iter = ast_json_object_iter ( json ) ; iter ; iter = ast_json_object_iter_next ( json , iter ) ) {
@ -6322,6 +6561,7 @@ int ast_ari_validate_recording_started(struct ast_json *json)
} else
if ( strcmp ( " timestamp " , ast_json_object_iter_key ( iter ) ) = = 0 ) {
int prop_is_valid ;
has_timestamp = 1 ;
prop_is_valid = ast_ari_validate_date (
ast_json_object_iter_value ( iter ) ) ;
if ( ! prop_is_valid ) {
@ -6357,6 +6597,11 @@ int ast_ari_validate_recording_started(struct ast_json *json)
res = 0 ;
}
if ( ! has_timestamp ) {
ast_log ( LOG_ERROR , " ARI RecordingStarted missing required field timestamp \n " ) ;
res = 0 ;
}
if ( ! has_recording ) {
ast_log ( LOG_ERROR , " ARI RecordingStarted missing required field recording \n " ) ;
res = 0 ;
@ -6376,6 +6621,7 @@ int ast_ari_validate_stasis_end(struct ast_json *json)
struct ast_json_iter * iter ;
int has_type = 0 ;
int has_application = 0 ;
int has_timestamp = 0 ;
int has_channel = 0 ;
for ( iter = ast_json_object_iter ( json ) ; iter ; iter = ast_json_object_iter_next ( json , iter ) ) {
@ -6410,6 +6656,7 @@ int ast_ari_validate_stasis_end(struct ast_json *json)
} else
if ( strcmp ( " timestamp " , ast_json_object_iter_key ( iter ) ) = = 0 ) {
int prop_is_valid ;
has_timestamp = 1 ;
prop_is_valid = ast_ari_validate_date (
ast_json_object_iter_value ( iter ) ) ;
if ( ! prop_is_valid ) {
@ -6445,6 +6692,11 @@ int ast_ari_validate_stasis_end(struct ast_json *json)
res = 0 ;
}
if ( ! has_timestamp ) {
ast_log ( LOG_ERROR , " ARI StasisEnd missing required field timestamp \n " ) ;
res = 0 ;
}
if ( ! has_channel ) {
ast_log ( LOG_ERROR , " ARI StasisEnd missing required field channel \n " ) ;
res = 0 ;
@ -6464,6 +6716,7 @@ int ast_ari_validate_stasis_start(struct ast_json *json)
struct ast_json_iter * iter ;
int has_type = 0 ;
int has_application = 0 ;
int has_timestamp = 0 ;
int has_args = 0 ;
int has_channel = 0 ;
@ -6499,6 +6752,7 @@ int ast_ari_validate_stasis_start(struct ast_json *json)
} else
if ( strcmp ( " timestamp " , ast_json_object_iter_key ( iter ) ) = = 0 ) {
int prop_is_valid ;
has_timestamp = 1 ;
prop_is_valid = ast_ari_validate_date (
ast_json_object_iter_value ( iter ) ) ;
if ( ! prop_is_valid ) {
@ -6554,6 +6808,11 @@ int ast_ari_validate_stasis_start(struct ast_json *json)
res = 0 ;
}
if ( ! has_timestamp ) {
ast_log ( LOG_ERROR , " ARI StasisStart missing required field timestamp \n " ) ;
res = 0 ;
}
if ( ! has_args ) {
ast_log ( LOG_ERROR , " ARI StasisStart missing required field args \n " ) ;
res = 0 ;
@ -6578,6 +6837,7 @@ int ast_ari_validate_text_message_received(struct ast_json *json)
struct ast_json_iter * iter ;
int has_type = 0 ;
int has_application = 0 ;
int has_timestamp = 0 ;
int has_message = 0 ;
for ( iter = ast_json_object_iter ( json ) ; iter ; iter = ast_json_object_iter_next ( json , iter ) ) {
@ -6612,6 +6872,7 @@ int ast_ari_validate_text_message_received(struct ast_json *json)
} else
if ( strcmp ( " timestamp " , ast_json_object_iter_key ( iter ) ) = = 0 ) {
int prop_is_valid ;
has_timestamp = 1 ;
prop_is_valid = ast_ari_validate_date (
ast_json_object_iter_value ( iter ) ) ;
if ( ! prop_is_valid ) {
@ -6656,6 +6917,11 @@ int ast_ari_validate_text_message_received(struct ast_json *json)
res = 0 ;
}
if ( ! has_timestamp ) {
ast_log ( LOG_ERROR , " ARI TextMessageReceived missing required field timestamp \n " ) ;
res = 0 ;
}
if ( ! has_message ) {
ast_log ( LOG_ERROR , " ARI TextMessageReceived missing required field message \n " ) ;
res = 0 ;