diff --git a/buildkite/builds.go b/buildkite/builds.go index 65d7c042..cbe80062 100644 --- a/buildkite/builds.go +++ b/buildkite/builds.go @@ -16,8 +16,9 @@ type BuildsService struct { // Author of a commit (used in CreateBuild) type Author struct { - Name string `json:"name,omitempty" yaml:"name,omitempty"` - Email string `json:"email,omitempty" yaml:"email,omitempty"` + Username string `json:"username,omitempty" yaml:"username,omitempty"` + Name string `json:"name,omitempty" yaml:"name,omitempty"` + Email string `json:"email,omitempty" yaml:"email,omitempty"` } // CreateBuild - Create a build. diff --git a/buildkite/builds_test.go b/buildkite/builds_test.go index 9420a3d0..87fe1380 100644 --- a/buildkite/builds_test.go +++ b/buildkite/builds_test.go @@ -336,6 +336,11 @@ func TestBuildsUnmarshalWebhook(t *testing.T) { "branch": "master", "tag": null, "source": "ui", + "author": { + "username": "foojim", + "name": "Uhh, Jim", + "email": "slam@space.jam" + }, "creator": { "id": "foo", "name": "Uhh, Jim",