Pithub::Issues(3pm) | User Contributed Perl Documentation | Pithub::Issues(3pm) |
Pithub::Issues - Github v3 Issues API
version 0.01040
Provides access to Pithub::Issues::Assignees.
Provides access to Pithub::Issues::Comments.
POST /repos/:user/:repo/issues
Parameters:
Examples:
my $i = Pithub::Issues->new; my $result = $i->create( user => 'plu', repo => 'Pithub', data => { assignee => 'octocat', body => "I'm having a problem with this.", labels => [ 'Label1', 'Label2' ], milestone => 1, title => 'Found a bug' } );
Response: Status: 201 Created
{ "url": "https://api.github.com/repos/octocat/Hello-World/issues/1", "html_url": "https://github.com/octocat/Hello-World/issues/1", "number": 1347, "state": "open", "title": "Found a bug", "body": "I'm having a problem with this.", "user": { "login": "octocat", "id": 1, "gravatar_url": "https://github.com/images/error/octocat_happy.gif", "url": "https://api.github.com/users/octocat" }, "labels": [ { "url": "https://api.github.com/repos/octocat/Hello-World/labels/bug", "name": "bug", "color": "f29513" } ], "assignee": { "login": "octocat", "id": 1, "gravatar_url": "https://github.com/images/error/octocat_happy.gif", "url": "https://api.github.com/users/octocat" }, "milestone": { "url": "https://api.github.com/repos/octocat/Hello-World/milestones/1", "number": 1, "state": "open", "title": "v1.0", "description": "", "creator": { "login": "octocat", "id": 1, "gravatar_url": "https://github.com/images/error/octocat_happy.gif", "url": "https://api.github.com/users/octocat" }, "open_issues": 4, "closed_issues": 8, "created_at": "2011-04-10T20:09:31Z", "due_on": null }, "comments": 0, "pull_request": { "html_url": "https://github.com/octocat/Hello-World/issues/1", "diff_url": "https://github.com/octocat/Hello-World/issues/1.diff", "patch_url": "https://github.com/octocat/Hello-World/issues/1.patch" }, "closed_at": null, "created_at": "2011-04-22T13:33:48Z", "updated_at": "2011-04-22T13:33:48Z" }
Provides access to Pithub::Issues::Events.
GET /repos/:user/:repo/issues/:id
Parameters:
Examples:
my $i = Pithub::Issues->new; my $result = $i->get( user => 'plu', repo => 'Pithub', issue_id => 1, );
Response: Status: 200 OK
{ "url": "https://api.github.com/repos/octocat/Hello-World/issues/1", "html_url": "https://github.com/octocat/Hello-World/issues/1", "number": 1347, "state": "open", "title": "Found a bug", "body": "I'm having a problem with this.", "user": { "login": "octocat", "id": 1, "gravatar_url": "https://github.com/images/error/octocat_happy.gif", "url": "https://api.github.com/users/octocat" }, "labels": [ { "url": "https://api.github.com/repos/octocat/Hello-World/labels/bug", "name": "bug", "color": "f29513" } ], "assignee": { "login": "octocat", "id": 1, "gravatar_url": "https://github.com/images/error/octocat_happy.gif", "url": "https://api.github.com/users/octocat" }, "milestone": { "url": "https://api.github.com/repos/octocat/Hello-World/milestones/1", "number": 1, "state": "open", "title": "v1.0", "description": "", "creator": { "login": "octocat", "id": 1, "gravatar_url": "https://github.com/images/error/octocat_happy.gif", "url": "https://api.github.com/users/octocat" }, "open_issues": 4, "closed_issues": 8, "created_at": "2011-04-10T20:09:31Z", "due_on": null }, "comments": 0, "pull_request": { "html_url": "https://github.com/octocat/Hello-World/issues/1", "diff_url": "https://github.com/octocat/Hello-World/issues/1.diff", "patch_url": "https://github.com/octocat/Hello-World/issues/1.patch" }, "closed_at": null, "created_at": "2011-04-22T13:33:48Z", "updated_at": "2011-04-22T13:33:48Z" }
Provides access to Pithub::Issues::Labels.
GET /issues
This API call can be influenced via the "params" hashref with following parameters:
Examples:
my $i = Pithub::Issues->new; my $result = $i->list( params => { filter => 'assigned', state => 'open', labels => 'bug', sort => 'updated', direction => 'asc', } );
Response: Status: 200 OK
[ { "url": "https://api.github.com/repos/octocat/Hello-World/issues/1", "html_url": "https://github.com/octocat/Hello-World/issues/1", "number": 1347, "state": "open", "title": "Found a bug", "body": "I'm having a problem with this.", "user": { "login": "octocat", "id": 1, "gravatar_url": "https://github.com/images/error/octocat_happy.gif", "url": "https://api.github.com/users/octocat" }, "labels": [ { "url": "https://api.github.com/repos/octocat/Hello-World/labels/bug", "name": "bug", "color": "f29513" } ], "assignee": { "login": "octocat", "id": 1, "gravatar_url": "https://github.com/images/error/octocat_happy.gif", "url": "https://api.github.com/users/octocat" }, "milestone": { "url": "https://api.github.com/repos/octocat/Hello-World/milestones/1", "number": 1, "state": "open", "title": "v1.0", "description": "", "creator": { "login": "octocat", "id": 1, "gravatar_url": "https://github.com/images/error/octocat_happy.gif", "url": "https://api.github.com/users/octocat" }, "open_issues": 4, "closed_issues": 8, "created_at": "2011-04-10T20:09:31Z", "due_on": null }, "comments": 0, "pull_request": { "html_url": "https://github.com/octocat/Hello-World/issues/1", "diff_url": "https://github.com/octocat/Hello-World/issues/1.diff", "patch_url": "https://github.com/octocat/Hello-World/issues/1.patch" }, "closed_at": null, "created_at": "2011-04-22T13:33:48Z", "updated_at": "2011-04-22T13:33:48Z" } ]
GET /repos/:user/:repo/issues
Parameters:
This API call can be influenced via the "params" hashref with following parameters:
Examples:
my $i = Pithub::Issues->new; my $result = $i->list( user => 'plu', repo => 'Pithub', params => { milestone => 42, state => 'open', labels => 'bug', sort => 'updated', direction => 'asc', } );
Response: Status: 200 OK
[ { "url": "https://api.github.com/repos/octocat/Hello-World/issues/1", "html_url": "https://github.com/octocat/Hello-World/issues/1", "number": 1347, "state": "open", "title": "Found a bug", "body": "I'm having a problem with this.", "user": { "login": "octocat", "id": 1, "gravatar_url": "https://github.com/images/error/octocat_happy.gif", "url": "https://api.github.com/users/octocat" }, "labels": [ { "url": "https://api.github.com/repos/octocat/Hello-World/labels/bug", "name": "bug", "color": "f29513" } ], "assignee": { "login": "octocat", "id": 1, "gravatar_url": "https://github.com/images/error/octocat_happy.gif", "url": "https://api.github.com/users/octocat" }, "milestone": { "url": "https://api.github.com/repos/octocat/Hello-World/milestones/1", "number": 1, "state": "open", "title": "v1.0", "description": "", "creator": { "login": "octocat", "id": 1, "gravatar_url": "https://github.com/images/error/octocat_happy.gif", "url": "https://api.github.com/users/octocat" }, "open_issues": 4, "closed_issues": 8, "created_at": "2011-04-10T20:09:31Z", "due_on": null }, "comments": 0, "pull_request": { "html_url": "https://github.com/octocat/Hello-World/issues/1", "diff_url": "https://github.com/octocat/Hello-World/issues/1.diff", "patch_url": "https://github.com/octocat/Hello-World/issues/1.patch" }, "closed_at": null, "created_at": "2011-04-22T13:33:48Z", "updated_at": "2011-04-22T13:33:48Z" } ]
Provides access to Pithub::Issues::Milestones.
PATCH /repos/:user/:repo/issues/:id
Parameters:
Examples:
my $i = Pithub::Issues->new; my $result = $i->update( user => 'plu', repo => 'Pithub', issue_id => 1, data => { assignee => 'octocat', body => "I'm having a problem with this.", labels => [ 'Label1', 'Label2' ], milestone => 1, state => 'open', title => 'Found a bug' } );
Johannes Plunien <plu@cpan.org>
This software is copyright (c) 2011 by Johannes Plunien.
This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.
2022-10-04 | perl v5.34.0 |