Repository issues
Provides functionality for interacting with an issue tracker. Authentication is necesary to access private issue tracker, to get more detailed information, to create and to update an issue.
Prepare:
$issue = new Bitbucket\API\Repositories\Issues();
$issue->setCredentials( new Bitbucket\API\Authentication\Basic($bb_user, $bb_pass) );
Fetch a list of issues:
$issue->all($account_name, $repo_slug);
Fetch a single issue:
$issue->get($account_name, $repo_slug, 3);
Fetch 5 issues that contains word bug
in title:
$issue->all($account_name, $repo_slug, array(
'limit' => 5,
'start' => 0,
'search' => 'bug'
));
Add a new issue:
$issue->create($account_name, $repo_slug, array(
'title' => 'dummy title',
'content' => 'dummy content',
'kind' => 'proposal',
'priority' => 'blocker'
));
Update an existing issue:
$issue->update($account_name, $repo_slug, 5, array(
'title' => 'dummy title (edited)'
));
Delete issue:
$issue->delete($account_name, $repo_slug, 5);