I have an add-on that is performing actions on a repo via the API, triggering webhooks. The add-on operates at the 'account' context, so the actions are carried out by this 'team' account.
There are some inconsistencies in the `actor` webhook payload between a 'team' actor request and a 'user' actor, presumably due to the recent GDPR changes.
"actor": { "username": "myteam", "display_name": "MyTeam", "type": "team", "uuid": "{062ef8e7-1438-4007-ac7e-4dae77d4f999}", "links": { "self": { "href": "https://api.bitbucket.org/2.0/teams/%7B062ef8e7-1438-4007-ac7e-4dae77d4f999%7D" }, "html": { "href": "https://bitbucket.org/%7B062ef8e7-1438-4007-ac7e-4dae77d4f999%7D/" }, "avatar": { "href": "https://bitbucket.org/account/myteam/avatar/" } } }
"actor": {
"display_name": "Jane Bloggs",
"uuid": "{9230127a-58bf-4100-9626-6c389e3ee999}",
"links": {
"self": {
"href": "https://api.bitbucket.org/2.0/users/%7B9230127a-58bf-4100-9626-6c389e3ee999%7D"
},
"html": {
"href": "https://bitbucket.org/%7B9230127a-58bf-4100-9626-6c389e3ee999%7D/"
},
"avatar": {
"href": "https://avatar-management--avatars.us-west-2.prod.public.atl-paas.net/initials/jane.png"
}
},
"nickname": "jane.bloggs",
"type": "user",
"account_id": "5cd96a53d210950fd02d2999"
},
This is causing issues in some integrations, such as AWS CodeBuild, which expects an `account_id` to be present in the webhook payload.
{ "message": "Invalid Webhook request received: Missing 'actor account id' field" }
My question is, given the recent GDPR changes, is it expected that there is no `account_id` for a team, or is this something that is due to be added?