Bounties
On this page, we'll dive into the different bounty endpoints you can use to manage bounties programmatically. We'll look at how to query, create, update, and delete bounties.
The Bounty model
The Bounty model contains all the information about your bounties, such as their amount, status, and task.
Required properties
- Name
id
- Type
- string
- Description
Unique identifier for the object.
- Name
task
- Type
- Task
- Description
Task to be done to collect the bounty such as resolving a bug, implementing a new feature or submitting a code review.
- Name
amount
- Type
- integer
- Description
Amount intended to be rewarded by the bounty. A positive integer representing how much to charge in the smallest currency unit (e.g., 100 cents to charge $1.00 or 100 to charge ¥100, a zero-decimal currency). The minimum amount is $0.50 US or equivalent in charge currency. The amount value supports up to eight digits (e.g., a value of 99999999 for a USD charge of $999,999.99).
- Name
currency
- Type
- string
- Description
Three-letter ISO currency code, in uppercase. Currently, only
USD
is allowed. If you'd like to pay in another currency, please get in touch with us.This value only determines what currency the bounty will be paid in. The solver can receive the payment in many other currencies via currency conversions as needed.
- Name
status
- Type
- string
- Description
Status of the bounty
Can be one of:
active
,inactive
- Name
created_at
- Type
- string
- Description
Timestamp of when the bounty was created, in ISO 8601 format:
YYYY-MM-DDTHH:MM:SSSZ
.
- Name
updated_at
- Type
- string
- Description
Timestamp of when the bounty was last updated, in ISO 8601 format:
YYYY-MM-DDTHH:MM:SSSZ
.
List bounties by org
This public endpoint allows you to retrieve a paginated list of bounties created by the given organization.
Optional attributes
- Name
limit
- Type
- integer
- Description
A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- Name
cursor
- Type
- string
- Description
A cursor for use in pagination. It's an object ID that defines your place in the list.
Request
curl "https://console.algora.io/api/orgs/Uber4Coding/bounties?limit=1"
Response
{
"next_cursor": "clcg36as9000bs8swc544ee8c",
"items": [
{
"id": "clcg36as9000as8swwd5lmovp",
"forge": "github",
"repo_owner": "Uber4Coding",
"repo_name": "dev",
"number": 7,
"amount": 10000,
"currency": "USD",
"status": "active",
"created_at": "2023-01-03T10:27:05.626Z",
"updated_at": "2023-01-03T10:27:08.192Z",
"issue": {
"id": 1450490527,
"url": "https://api.github.com/repos/Uber4Coding/dev/issues/7",
"repository_url": "https://api.github.com/repos/Uber4Coding/dev",
"labels_url": "https://api.github.com/repos/Uber4Coding/dev/issues/7/labels{/name}",
"comments_url": "https://api.github.com/repos/Uber4Coding/dev/issues/7/comments",
"events_url": "https://api.github.com/repos/Uber4Coding/dev/issues/7/events",
"html_url": "https://github.com/Uber4Coding/dev/pull/7",
"number": 7,
"state": "open",
"state_reason": null,
"title": "Update README.md",
"body": null,
"locked": false,
"active_lock_reason": null,
"comments": 0,
"closed_at": null,
"created_at": "2022-11-15T22:49:51.000Z",
"updated_at": "2022-11-15T22:49:51.000Z",
"draft": false,
"body_html": null,
"body_text": null,
"timeline_url": "https://api.github.com/repos/Uber4Coding/dev/issues/7/timeline",
"author_association": "MEMBER",
"user": {
"id": 17045339,
"login": "zcesur",
"avatar_url": "https://avatars.githubusercontent.com/u/17045339?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/zcesur",
"html_url": "https://github.com/zcesur",
"followers_url": "https://api.github.com/users/zcesur/followers",
"following_url": "https://api.github.com/users/zcesur/following{/other_user}",
"gists_url": "https://api.github.com/users/zcesur/gists{/gist_id}",
"starred_url": "https://api.github.com/users/zcesur/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/zcesur/subscriptions",
"organizations_url": "https://api.github.com/users/zcesur/orgs",
"repos_url": "https://api.github.com/users/zcesur/repos",
"events_url": "https://api.github.com/users/zcesur/events{/privacy}",
"received_events_url": "https://api.github.com/users/zcesur/received_events",
"type": "User",
"site_admin": false,
"name": null,
"email": null
},
"pull_request": {
"merged_at": null,
"diff_url": "https://github.com/Uber4Coding/dev/pull/7.diff",
"html_url": "https://github.com/Uber4Coding/dev/pull/7",
"patch_url": "https://github.com/Uber4Coding/dev/pull/7.patch",
"url": "https://api.github.com/repos/Uber4Coding/dev/pulls/7"
}
}
}
]
}
List bounties
This endpoint allows you to retrieve a paginated list of your organization's bounties.
Optional attributes
- Name
limit
- Type
- integer
- Description
A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- Name
cursor
- Type
- string
- Description
A cursor for use in pagination. It's an object ID that defines your place in the list.
Request
curl "https://console.algora.io/api/bounties?limit=1" \
-H "authorization: Bearer $TOKEN"
Response
{
"next_cursor": "clcg36as9000bs8swc544ee8c",
"items": [
{
"id": "clcg36as9000as8swwd5lmovp",
"forge": "github",
"repo_owner": "Uber4Coding",
"repo_name": "dev",
"number": 7,
"amount": 10000,
"currency": "USD",
"status": "active",
"created_at": "2023-01-03T10:27:05.626Z",
"updated_at": "2023-01-03T10:27:08.192Z",
"issue": {
"id": 1450490527,
"url": "https://api.github.com/repos/Uber4Coding/dev/issues/7",
"repository_url": "https://api.github.com/repos/Uber4Coding/dev",
"labels_url": "https://api.github.com/repos/Uber4Coding/dev/issues/7/labels{/name}",
"comments_url": "https://api.github.com/repos/Uber4Coding/dev/issues/7/comments",
"events_url": "https://api.github.com/repos/Uber4Coding/dev/issues/7/events",
"html_url": "https://github.com/Uber4Coding/dev/pull/7",
"number": 7,
"state": "open",
"state_reason": null,
"title": "Update README.md",
"body": null,
"locked": false,
"active_lock_reason": null,
"comments": 0,
"closed_at": null,
"created_at": "2022-11-15T22:49:51.000Z",
"updated_at": "2022-11-15T22:49:51.000Z",
"draft": false,
"body_html": null,
"body_text": null,
"timeline_url": "https://api.github.com/repos/Uber4Coding/dev/issues/7/timeline",
"author_association": "MEMBER",
"user": {
"id": 17045339,
"login": "zcesur",
"avatar_url": "https://avatars.githubusercontent.com/u/17045339?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/zcesur",
"html_url": "https://github.com/zcesur",
"followers_url": "https://api.github.com/users/zcesur/followers",
"following_url": "https://api.github.com/users/zcesur/following{/other_user}",
"gists_url": "https://api.github.com/users/zcesur/gists{/gist_id}",
"starred_url": "https://api.github.com/users/zcesur/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/zcesur/subscriptions",
"organizations_url": "https://api.github.com/users/zcesur/orgs",
"repos_url": "https://api.github.com/users/zcesur/repos",
"events_url": "https://api.github.com/users/zcesur/events{/privacy}",
"received_events_url": "https://api.github.com/users/zcesur/received_events",
"type": "User",
"site_admin": false,
"name": null,
"email": null
},
"pull_request": {
"merged_at": null,
"diff_url": "https://github.com/Uber4Coding/dev/pull/7.diff",
"html_url": "https://github.com/Uber4Coding/dev/pull/7",
"patch_url": "https://github.com/Uber4Coding/dev/pull/7.patch",
"url": "https://api.github.com/repos/Uber4Coding/dev/pulls/7"
}
}
}
]
}
Retrieve a bounty
Retrieves the details of a bounty.
Request
curl "https://console.algora.io/api/bounties/clcg36as9000as8swwd5lmovp"
Response
{
"id": "clcg36as9000as8swwd5lmovp",
"forge": "github",
"repo_owner": "Uber4Coding",
"repo_name": "dev",
"number": 7,
"amount": 10000,
"currency": "USD",
"status": "active",
"created_at": "2023-01-03T10:27:05.626Z",
"updated_at": "2023-01-03T10:27:08.192Z",
"issue": {
"id": 1450490527,
"url": "https://api.github.com/repos/Uber4Coding/dev/issues/7",
"repository_url": "https://api.github.com/repos/Uber4Coding/dev",
"labels_url": "https://api.github.com/repos/Uber4Coding/dev/issues/7/labels{/name}",
"comments_url": "https://api.github.com/repos/Uber4Coding/dev/issues/7/comments",
"events_url": "https://api.github.com/repos/Uber4Coding/dev/issues/7/events",
"html_url": "https://github.com/Uber4Coding/dev/pull/7",
"number": 7,
"state": "open",
"state_reason": null,
"title": "Update README.md",
"body": null,
"locked": false,
"active_lock_reason": null,
"comments": 0,
"closed_at": null,
"created_at": "2022-11-15T22:49:51.000Z",
"updated_at": "2022-11-15T22:49:51.000Z",
"draft": false,
"body_html": null,
"body_text": null,
"timeline_url": "https://api.github.com/repos/Uber4Coding/dev/issues/7/timeline",
"author_association": "MEMBER",
"user": {
"id": 17045339,
"login": "zcesur",
"avatar_url": "https://avatars.githubusercontent.com/u/17045339?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/zcesur",
"html_url": "https://github.com/zcesur",
"followers_url": "https://api.github.com/users/zcesur/followers",
"following_url": "https://api.github.com/users/zcesur/following{/other_user}",
"gists_url": "https://api.github.com/users/zcesur/gists{/gist_id}",
"starred_url": "https://api.github.com/users/zcesur/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/zcesur/subscriptions",
"organizations_url": "https://api.github.com/users/zcesur/orgs",
"repos_url": "https://api.github.com/users/zcesur/repos",
"events_url": "https://api.github.com/users/zcesur/events{/privacy}",
"received_events_url": "https://api.github.com/users/zcesur/received_events",
"type": "User",
"site_admin": false,
"name": null,
"email": null
},
"pull_request": {
"merged_at": null,
"diff_url": "https://github.com/Uber4Coding/dev/pull/7.diff",
"html_url": "https://github.com/Uber4Coding/dev/pull/7",
"patch_url": "https://github.com/Uber4Coding/dev/pull/7.patch",
"url": "https://api.github.com/repos/Uber4Coding/dev/pulls/7"
}
}
}
Create bounties
Creates one or more bounties. Only 1 bounty per issue is allowed by each organization. Duplicate bounty attempts on the same issue will be skipped silently.
Required attributes
- Name
bounties
- Type
- array of objects
- Description
List of bounties to create.
- Name
forge
- Type
- string
- Description
Platform where the issue resides.
Can be one of:
github
If you'd like to use another forge, please get in touch with us.
- Name
repo_owner
- Type
- string
- Description
Owner of the repository.
- Name
repo_name
- Type
- string
- Description
Name of the repository.
- Name
number
- Type
- integer
- Description
Number of the issue.
- Name
amount
- Type
- integer
- Description
Amount intended to be rewarded by the bounty. A positive integer representing how much to charge in the smallest currency unit (e.g., 100 cents to charge $1.00 or 100 to charge ¥100, a zero-decimal currency). The minimum amount is $0.50 US or equivalent in charge currency. The amount value supports up to eight digits (e.g., a value of 99999999 for a USD charge of $999,999.99).
- Name
currency
- Type
- string
- Description
Three-letter ISO currency code, in uppercase. Currently, only
USD
is allowed. If you'd like to pay in another currency, please get in touch with us.This value only determines what currency the bounty will be paid in. The solver can receive the payment in many other currencies via currency conversions as needed.
Request
curl "https://console.algora.io/api/bounties" \
-H "authorization: Bearer $TOKEN" \
-H "content-Type: application/json" \
--data-raw '{"bounties":[{"forge":"github","repo_owner":"Uber4Coding","repo_name":"dev","number":7,"amount":10000,"currency":"USD"},{"forge":"github","repo_owner":"Uber4Coding","repo_name":"dev","number":8,"amount":10000,"currency":"USD"}]}'
Response
{ "count": 2 }
Update a bounty
Updates properties on a bounty.
Optional attributes
- Name
forge
- Type
- string
- Description
Platform where the issue resides.
Can be one of:
github
If you'd like to use another forge, please get in touch with us.
- Name
repo_owner
- Type
- string
- Description
Owner of the repository.
- Name
repo_name
- Type
- string
- Description
Name of the repository.
- Name
amount
- Type
- integer
- Description
Amount intended to be rewarded by the bounty. A positive integer representing how much to charge in the smallest currency unit (e.g., 100 cents to charge $1.00 or 100 to charge ¥100, a zero-decimal currency). The minimum amount is $0.50 US or equivalent in charge currency. The amount value supports up to eight digits (e.g., a value of 99999999 for a USD charge of $999,999.99).
- Name
currency
- Type
- string
- Description
Three-letter ISO currency code, in uppercase. Currently, only
USD
is allowed. If you'd like to pay in another currency, please get in touch with us.This value only determines what currency the bounty will be paid in. The solver can receive the payment in many other currencies via currency conversions as needed.
- Name
status
- Type
- string
- Description
Status of the bounty
Can be one of:
active
,inactive
Request
curl "https://console.algora.io/api/bounties/clcg36as9000as8swwd5lmovp" \
-X "PATCH" \
-H "authorization: Bearer $TOKEN" \
-H "content-Type: application/json" \
--data-raw '{"amount":20000,"currency":"USD"}'
Response
{
"id": "clcg36as9000as8swwd5lmovp",
"forge": "github",
"repo_owner": "Uber4Coding",
"repo_name": "dev",
"number": 7,
"amount": 20000,
"currency": "USD",
"status": "active",
"created_at": "2023-01-03T10:27:05.626Z",
"updated_at": "2023-01-03T10:27:08.192Z",
"issue": {
"id": 1450490527,
"url": "https://api.github.com/repos/Uber4Coding/dev/issues/7",
"repository_url": "https://api.github.com/repos/Uber4Coding/dev",
"labels_url": "https://api.github.com/repos/Uber4Coding/dev/issues/7/labels{/name}",
"comments_url": "https://api.github.com/repos/Uber4Coding/dev/issues/7/comments",
"events_url": "https://api.github.com/repos/Uber4Coding/dev/issues/7/events",
"html_url": "https://github.com/Uber4Coding/dev/pull/7",
"number": 7,
"state": "open",
"state_reason": null,
"title": "Update README.md",
"body": null,
"locked": false,
"active_lock_reason": null,
"comments": 0,
"closed_at": null,
"created_at": "2022-11-15T22:49:51.000Z",
"updated_at": "2022-11-15T22:49:51.000Z",
"draft": false,
"body_html": null,
"body_text": null,
"timeline_url": "https://api.github.com/repos/Uber4Coding/dev/issues/7/timeline",
"author_association": "MEMBER",
"user": {
"id": 17045339,
"login": "zcesur",
"avatar_url": "https://avatars.githubusercontent.com/u/17045339?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/zcesur",
"html_url": "https://github.com/zcesur",
"followers_url": "https://api.github.com/users/zcesur/followers",
"following_url": "https://api.github.com/users/zcesur/following{/other_user}",
"gists_url": "https://api.github.com/users/zcesur/gists{/gist_id}",
"starred_url": "https://api.github.com/users/zcesur/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/zcesur/subscriptions",
"organizations_url": "https://api.github.com/users/zcesur/orgs",
"repos_url": "https://api.github.com/users/zcesur/repos",
"events_url": "https://api.github.com/users/zcesur/events{/privacy}",
"received_events_url": "https://api.github.com/users/zcesur/received_events",
"type": "User",
"site_admin": false,
"name": null,
"email": null
},
"pull_request": {
"merged_at": null,
"diff_url": "https://github.com/Uber4Coding/dev/pull/7.diff",
"html_url": "https://github.com/Uber4Coding/dev/pull/7",
"patch_url": "https://github.com/Uber4Coding/dev/pull/7.patch",
"url": "https://api.github.com/repos/Uber4Coding/dev/pulls/7"
}
}
}
Delete a bounty
Deletes a bounty.
Request
curl "https://console.algora.io/api/bounties/clcg36as9000as8swwd5lmovp" \
-X "DELETE" \
-H "authorization: Bearer $TOKEN" \
-H "content-Type: application/json"
Response
{
"id": "clcg36as9000as8swwd5lmovp",
"forge": "github",
"repo_owner": "Uber4Coding",
"repo_name": "dev",
"number": 7,
"amount": 20000,
"currency": "USD",
"status": "active",
"created_at": "2023-01-03T10:27:05.626Z",
"updated_at": "2023-01-03T10:27:08.192Z",
"issue": {
"id": 1450490527,
"url": "https://api.github.com/repos/Uber4Coding/dev/issues/7",
"repository_url": "https://api.github.com/repos/Uber4Coding/dev",
"labels_url": "https://api.github.com/repos/Uber4Coding/dev/issues/7/labels{/name}",
"comments_url": "https://api.github.com/repos/Uber4Coding/dev/issues/7/comments",
"events_url": "https://api.github.com/repos/Uber4Coding/dev/issues/7/events",
"html_url": "https://github.com/Uber4Coding/dev/pull/7",
"number": 7,
"state": "open",
"state_reason": null,
"title": "Update README.md",
"body": null,
"locked": false,
"active_lock_reason": null,
"comments": 0,
"closed_at": null,
"created_at": "2022-11-15T22:49:51.000Z",
"updated_at": "2022-11-15T22:49:51.000Z",
"draft": false,
"body_html": null,
"body_text": null,
"timeline_url": "https://api.github.com/repos/Uber4Coding/dev/issues/7/timeline",
"author_association": "MEMBER",
"user": {
"id": 17045339,
"login": "zcesur",
"avatar_url": "https://avatars.githubusercontent.com/u/17045339?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/zcesur",
"html_url": "https://github.com/zcesur",
"followers_url": "https://api.github.com/users/zcesur/followers",
"following_url": "https://api.github.com/users/zcesur/following{/other_user}",
"gists_url": "https://api.github.com/users/zcesur/gists{/gist_id}",
"starred_url": "https://api.github.com/users/zcesur/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/zcesur/subscriptions",
"organizations_url": "https://api.github.com/users/zcesur/orgs",
"repos_url": "https://api.github.com/users/zcesur/repos",
"events_url": "https://api.github.com/users/zcesur/events{/privacy}",
"received_events_url": "https://api.github.com/users/zcesur/received_events",
"type": "User",
"site_admin": false,
"name": null,
"email": null
},
"pull_request": {
"merged_at": null,
"diff_url": "https://github.com/Uber4Coding/dev/pull/7.diff",
"html_url": "https://github.com/Uber4Coding/dev/pull/7",
"patch_url": "https://github.com/Uber4Coding/dev/pull/7.patch",
"url": "https://api.github.com/repos/Uber4Coding/dev/pulls/7"
}
}
}