Taskcluster-Github Exchanges


The github service publishes a pulse message for supported github events, translating Github webhook events into pulse messages.

This document describes the exchange offered by the taskcluster github service

Exchanges

NameExchangeSummary
pullRequestexchange/taskcluster-github/v1/pull-requestGitHub Pull Request Event
pushexchange/taskcluster-github/v1/pushGitHub push Event
releaseexchange/taskcluster-github/v1/releaseGitHub release Event
taskGroupDefinedexchange/taskcluster-github/v1/task-group-definedGitHub release Event

pullRequest

Exchange
exchange/taskcluster-github/v1/pull-request
Signature
"pullRequest(routingKeyPattern)"

When a GitHub pull request event is posted it will be broadcast on this exchange with the designated organization and repository in the routing-key along with event specific metadata in the payload.

Routing Key

IndexNameSummary
0
routingKeyKind

Identifier for the routing-key kind. This is always "primary" for the formalized routing key.

constant-key

1
organization

The GitHub organization which had an event. All periods have been replaced by % - such that foo.bar becomes foo%bar - and all other special characters aside from - and _ have been stripped.

2
repository

The GitHub repository which had an event.All periods have been replaced by % - such that foo.bar becomes foo%bar - and all other special characters aside from - and _ have been stripped.

3
action

The GitHub action which triggered an event. See for possible values see the payload actions property.

Message Payload

GitHub Pull Request Message (source)

Message reporting that a GitHub pull request has occurred

version
  • 1

Message version

organizationstring[1:100]^([a-zA-Z0-9-_%]*)$

The GitHub organization which had an event.

repositorystring[1:100]^([a-zA-Z0-9-_%]*)$

The GitHub repository which had an event.

installationIdinteger[0:10000000000]

The installation which had an event.

action
  • assigned
  • unassigned
  • labeled
  • unlabeled
  • opened
  • edited
  • closed
  • reopened
  • synchronize
  • review_requested
  • review_request_removed

The GitHub action which triggered an event.

eventIdstring^[a-zA-Z0-9]{8}-[a-zA-Z0-9]{4}-[a-zA-Z0-9]{4}-[a-zA-Z0-9]{4}-[a-zA-Z0-9]{12}$

The GitHub webhook deliveryId. Extracted from the header 'X-GitHub-Delivery'

detailsObject of

Metadata describing the pull request (for version 0)

Anything ¯\_(ツ)_/¯
bodyObject of

The raw body of github event (for version 1)

Anything ¯\_(ツ)_/¯
tasks_forstring

The type of the event (for version 1)

branchstring

The head ref of the event (for version 1)



push

Exchange
exchange/taskcluster-github/v1/push
Signature
"push(routingKeyPattern)"

When a GitHub push event is posted it will be broadcast on this exchange with the designated organization and repository in the routing-key along with event specific metadata in the payload.

Routing Key

IndexNameSummary
0
routingKeyKind

Identifier for the routing-key kind. This is always "primary" for the formalized routing key.

constant-key

1
organization

The GitHub organization which had an event. All periods have been replaced by % - such that foo.bar becomes foo%bar - and all other special characters aside from - and _ have been stripped.

2
repository

The GitHub repository which had an event.All periods have been replaced by % - such that foo.bar becomes foo%bar - and all other special characters aside from - and _ have been stripped.

Message Payload

GitHub Push Message (source)

Message reporting that a GitHub push has occurred

version
  • 1

Message version

organizationstring[1:100]^([a-zA-Z0-9-_%]*)$

The GitHub organization which had an event.

repositorystring[1:100]^([a-zA-Z0-9-_%]*)$

The GitHub repository which had an event.

installationIdinteger[0:10000000000]

The installation which had an event.

eventIdstring^[a-zA-Z0-9]{8}-[a-zA-Z0-9]{4}-[a-zA-Z0-9]{4}-[a-zA-Z0-9]{4}-[a-zA-Z0-9]{12}$

The GitHub webhook deliveryId. Extracted from the header 'X-GitHub-Delivery'

detailsObject of

Metadata describing the push (for version 0)

Anything ¯\_(ツ)_/¯
bodyObject of

The raw body of github event (for version 1)

Anything ¯\_(ツ)_/¯
tasks_forstring

The type of the event (for version 1)

branchstring

The head ref of the event (for version 1)



release

Exchange
exchange/taskcluster-github/v1/release
Signature
"release(routingKeyPattern)"

When a GitHub release event is posted it will be broadcast on this exchange with the designated organization and repository in the routing-key along with event specific metadata in the payload.

Routing Key

IndexNameSummary
0
routingKeyKind

Identifier for the routing-key kind. This is always "primary" for the formalized routing key.

constant-key

1
organization

The GitHub organization which had an event. All periods have been replaced by % - such that foo.bar becomes foo%bar - and all other special characters aside from - and _ have been stripped.

2
repository

The GitHub repository which had an event.All periods have been replaced by % - such that foo.bar becomes foo%bar - and all other special characters aside from - and _ have been stripped.

Message Payload

GitHub Release Message (source)

Message reporting that a GitHub release has occurred

version
  • 1

Message version

organizationstring[1:100]^([a-zA-Z0-9-_%]*)$

The GitHub organization which had an event.

repositorystring[1:100]^([a-zA-Z0-9-_%]*)$

The GitHub repository which had an event.

installationIdinteger[0:10000000000]

The installation which had an event.

eventIdstring^[a-zA-Z0-9]{8}-[a-zA-Z0-9]{4}-[a-zA-Z0-9]{4}-[a-zA-Z0-9]{4}-[a-zA-Z0-9]{12}$

The GitHub webhook deliveryId. Extracted from the header 'X-GitHub-Delivery'

detailsObject of

Metadata describing the release (for version 0)

Anything ¯\_(ツ)_/¯
bodyObject of

The raw body of github event (for version 1)

Anything ¯\_(ツ)_/¯
tasks_forstring

The type of the event (for version 1)

branchstring

The head ref of the event (for version 1)



taskGroupDefined

Exchange
exchange/taskcluster-github/v1/task-group-defined
Signature
"taskGroupDefined(routingKeyPattern)"

used for creating status indicators in GitHub UI using Statuses API

Routing Key

IndexNameSummary
0
routingKeyKind

Identifier for the routing-key kind. This is always "primary" for the formalized routing key.

constant-key

1
organization

The GitHub organization which had an event. All periods have been replaced by % - such that foo.bar becomes foo%bar - and all other special characters aside from - and _ have been stripped.

2
repository

The GitHub repository which had an event.All periods have been replaced by % - such that foo.bar becomes foo%bar - and all other special characters aside from - and _ have been stripped.

Message Payload

Task Group Defined - Create Status (source)

Indicates that this service has created a new task group in response to a GitHub event. This message is for internal use only and should not be relied on for other purposes. Full specification on GitHub docs

version
  • 1

Message version

organizationstring[1:100]^([a-zA-Z0-9-_%]*)$

The GitHub organization which had an event.

repositorystring[1:100]^([a-zA-Z0-9-_%]*)$

The GitHub repository which had an event.

taskGroupIdstring

The id of the taskGroup that had been created.