Exemplo n.º 1
0
 /// <summary>
 /// Triggers an event of type "custom"
 /// </summary>
 /// <remarks>
 /// Required permissions: Webhooks.View.
 /// </remarks>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='eventData'>
 /// Any custom event data payload
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task <CustomEventDto> TriggerCustomAsync(this IWebhooks operations, object eventData, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken))
 {
     using (var _result = await operations.TriggerCustomWithHttpMessagesAsync(eventData, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }
Exemplo n.º 2
0
 /// <summary>
 /// Triggers an event of type "custom"
 /// </summary>
 /// <remarks>
 /// Client Credentials Flow required permissions: Webhooks or Webhooks.Write.
 ///
 /// Required permissions: Webhooks.View.
 /// </remarks>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='body'>
 /// Any custom event data payload
 /// </param>
 /// <param name='expand'>
 /// Indicates the related entities to be represented inline. The maximum depth
 /// is 2.
 /// </param>
 /// <param name='select'>
 /// Limits the properties returned in the result.
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task <CustomEventDto> TriggerCustomAsync(this IWebhooks operations, IDictionary <string, object> body = default(IDictionary <string, object>), string expand = default(string), string select = default(string), CancellationToken cancellationToken = default(CancellationToken))
 {
     using (var _result = await operations.TriggerCustomWithHttpMessagesAsync(body, expand, select, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }