The bitbucket 'events' REST resource provides information about user events and repository events.
Getting a List of Events for a User
GET /users/USERNAME/events/
Parameters:
USERNAME: The user's username.
In addition, you can add the following query string parameters:
start: The offset to start with. The default is '0'.limit: The number of events returned. The default is 25.
Example with a query string parameter:
$ curl https://api.bitbucket.org/1.0/users/jespern/events/?limit=5
Getting a List of Events for a Repository
GET /repositories/USERNAME/REPO_SLUG/events/
Parameters:
USERNAME: The owner's username.REPO_SLUG: The slug of the repository.
In addition, you can add the following query string parameters:
start: The offset to start with. The default is '0'.limit: The number of events returned. The default is 25.type: A filter for the event type to retrieve. e.g.issue_comment
Example with a query string parameter:
$ curl https://api.bitbucket.org/1.0/repositories/sarahmaddox/sarahmaddox/events/?limit=5
RELATED TOPICS
Labels






9 Comments
Hide/Show CommentsMar 30, 2011
Tom Davies
Can I get events from my private repos too? -- even authenticated I only seem to see them from public repos.
Explicit private repo access as in the second case above 404s.
Mar 30, 2011
Erik van Zijst [Atlassian]
You should explicitly follow any repo you want to see events for. You might not be following those provate repos.
Jul 06, 2011
Ville Säävuori
I seem to have the same problem: events from private repos don't seem to show on the events list even when I'm authenticated. Fetching them explicitly for a repo works, though. And yes, I do follow the repos in question.
Not a big deal, just wanted to note it :)
Aug 31, 2011
Anonymous
Events for a repository which involve reporting or updating an issue do not seem to carry enough information to identify the associated issue.
Is there an alternative route to this information available?
Oct 26, 2011
Jon S Akhtar
Events also can take a parameter
type, which should be the event type, e.g.issue_commenthttps://api.bitbucket.org/1.0/repositories/atlassian/jetbrains-bitbucket-connector/events?type=issue_comment
Nov 11, 2011
Grace Batumbya
For an event of type: issue_comment, how can I tell what the issue number is?
For example https://api.bitbucket.org/1.0/repositories/atlassian/jetbrains-bitbucket-connector/events?type=issue_comment&limit=1
returns (see below), but where is the actual issue on which the comment was made?
{
- {
]- "node": null,
- "description": "739707",
- "repository": {
- "created_on": "2011-10-26 10:11:35",
- "user": {
- "event": "issue_comment"
}- "website": "http://www.jetbrains.com/",
- "scm": "hg",
- "name": "jetbrains-bitbucket-connector",
- "followers_count": 11,
- "owner": "atlassian",
- "logo": "https://bitbucket-assetroot.s3.amazonaws.com:443/c/photos/2011/Aug/10/jetbrains-bitbucket-connector-logo-4199472643-0_avatar.png",
- "resource_uri": "/api/1.0/repositories/atlassian/jetbrains-bitbucket-connector",
- "slug": "jetbrains-bitbucket-connector",
- "description": "A Bitbucket plugin for Jetbrains IDEs -- PyCharm, IDEA, RubyMine, PHPStorm and others."
},- "username": "sylvanaar2",
- "first_name": "Jon",
- "last_name": "Akhtar",
- "avatar": "https://secure.gravatar.com/avatar/d9314e008d15617514278285a320099a?d=identicon&s=32",
- "resource_uri": "/1.0/users/sylvanaar2"
},}
Nov 11, 2011
Jon S Akhtar
As far as I can tell, you have to turn around and scrape the web page.
Nov 11, 2011
Grace Batumbya
I have filed an enhancement issue for this. https://bitbucket.org/site/master/issue/3262/events-rest-api-issue_comment-include
I wonder what the turn around is on new issues?
Feb 07, 2012
Anonymous
Still no way to get user events so that whatever is shown in Dashboard can be replicated, anyone?
Add Comment