GitHubClient.CreateRepositoryDispatchEventAsync Method

Definition

Create a repository dispatch event

public virtual System.Threading.Tasks.Task CreateRepositoryDispatchEventAsync(string repositoryOwner, string repositoryName, Azure.Connectors.Sdk.GitHub.Models.RepositoryDispatchEvent input, System.Threading.CancellationToken cancellationToken = default);
abstract member CreateRepositoryDispatchEventAsync : string * string * Azure.Connectors.Sdk.GitHub.Models.RepositoryDispatchEvent * System.Threading.CancellationToken -> System.Threading.Tasks.Task
override this.CreateRepositoryDispatchEventAsync : string * string * Azure.Connectors.Sdk.GitHub.Models.RepositoryDispatchEvent * System.Threading.CancellationToken -> System.Threading.Tasks.Task
Public Overridable Function CreateRepositoryDispatchEventAsync (repositoryOwner As String, repositoryName As String, input As RepositoryDispatchEvent, Optional cancellationToken As CancellationToken = Nothing) As Task

Parameters

repositoryOwner
String

Repository Owner

repositoryName
String

Repository Name

input
RepositoryDispatchEvent

The request body.

cancellationToken
CancellationToken

Cancellation token.

Returns

Remarks

This operation is to trigger a webhook event called repository_dispatch when you want activity that happens outside of GitHub to trigger a GitHub Actions workflow or GitHub App webhook. You must configure your GitHub Actions workflow or GitHub App to run when the repository_dispatch event occurs.

Applies to