{
'title': <title of the PR>,
'username': <author of the PR>,
'url': <url of PR>,
'state': <open or closed>,
'createdAt': <time of PR created>,
'updatedAt': <last event: commit or review or closing of PR>,
'repository': <name of the repository corresponding to the PR>,
'labels': <labels array>,
'assignees': <username of the assignee>
}
Route | Description |
---|---|
GET /pullrequests/user/:username | Returns latest PRs by the user in RDS |
GET /pullrequests/open | Returns n latest open PRs in RDS |
GET /pullrequests/stale | Returns n stale PRs in RDS |
Returns latest pull requests by an user in Real-Dev-Squad organisation
-
Params
username
-
Success Response:
-
Code: 200
- Content:
{
message: 'Pull requests returned successfully!'
pullRequests: [
{<Pull Request Object>},
{<Pull Request Object>},
{<Pull Request Object>},
{<Pull Request Object>},
{<Pull Request Object>}
]
}
- Error Response:
- Code: 500
- Content:
{ 'statusCode': 500, 'error': 'Internal Server Error', 'message': 'Something went wrong. Please contact admin' }
- Content:
- Code: 500
Returns n latest open PRs in Real-Dev-Squad organisation
- Params
None - Query
page=[integer], n=[integer] - Success Response:
- Code: 200
- Content:
{
message: 'Open PRs'
pullRequests: [
{<Pull Request Object>},
{<Pull Request Object>},
{<Pull Request Object>},
{<Pull Request Object>},
{<Pull Request Object>}
]
}
- Success Response:
- No Open PRs found
- Code: 200
- Content:
{
message: 'No pull requests found!'
pullRequests: []
}
- Error Response:
- Code: 500
- Content:
{ 'statusCode': 500, 'error': 'Internal Server Error', 'message': 'Something went wrong. Please contact admin' }
- Content:
- Code: 500
Returns n stale pull requests in Real-Dev-Squad organisation
- Params
None - Query
page=[integer], n=[integer] - Success Response:
- Code: 200
- Content:
{
message: 'Stale PRs'
pullRequests: [
{<Pull Request Object>},
{<Pull Request Object>},
{<Pull Request Object>},
{<Pull Request Object>},
{<Pull Request Object>}
]
}
- Success Response:
- No Stale PRs found:
- Code: 200
- Content:
{
message: 'No pull requests found!'
pullRequests: []
}
- Error Response:
- Code: 500
- Content:
{ 'statusCode': 500, 'error': 'Internal Server Error', 'message': 'Something went wrong. Please contact admin' }
- Content:
- Code: 500