# Working on a Bounty

## 1 - Look for an issue on the [app.lightningbounties.com](https://app.lightningbounties.com/) feed

In this example, we are using:[ 'Add color to logo in this repo'](https://github.com/MIT-Bitcoin-2024/experiments-1/issues/34)

<figure><img src="/files/e8r0nzUa1kVXGYFbmyds" alt=""><figcaption></figcaption></figure>

### 1.1 - Click on the issue to get details

<figure><img src="/files/YMGPm1wmK6yY8pXfOjLf" alt=""><figcaption></figcaption></figure>

### 1.2 - Click on 🔗 to see the issue in GitHub

<figure><img src="/files/6kjOiE6jIigJYJbJfUKY" alt=""><figcaption></figcaption></figure>

## 2 - Fix the issue

### 2.1 - Fork the owner repo to your repository

<figure><img src="/files/CjLZ5gfRUGS1APr0BdpY" alt=""><figcaption></figcaption></figure>

### 2.2 - Work on the issue

This is the part where developers work on fixing the code after they fork the repo.  🧑‍💻

*In this example, the colored logo has been added to the repo as* [*issue* ](https://github.com/MIT-Bitcoin-2024/experiments-1/issues/34)*requested.*&#x20;

<figure><img src="/files/MbKINquCD3nxZivM1fE1" alt=""><figcaption></figcaption></figure>

## 3 - Create a Pull Request

Create a pull request to the bounty poster repo.

<figure><img src="/files/S2xTIHqxjGmtXEsr6BpC" alt=""><figcaption></figcaption></figure>

### 3.1 - Close the issue you fix on the Pull Request description

<figure><img src="/files/SGPteHFB1YVFAKeg6oMA" alt=""><figcaption></figcaption></figure>

## <mark style="background-color:orange;">⚠️ Note: This step is crucial⚠️</mark>

### If you forget to add the tag `close #(issue-number)`,  & the PR is already merged.&#x20;

### You have 2 options:

<details>

<summary><mark style="background-color:orange;"><strong>[1]</strong></mark><strong>  Edit the Pull Request Message</strong> </summary>

#### <mark style="background-color:orange;">**We got you covered! 👇**</mark>

***

### 1. Go to your merged PR and Click Into It

<figure><img src="https://images.tango.us/workflows/2cc8efaf-a4f0-4968-9904-46440dbc5702/steps/4e2d550c-f01d-4237-a4f7-c6fe181421dd/62131c99-b762-490b-a637-812a364fee5a.png?crop=focalpoint&#x26;fit=crop&#x26;fp-x=0.1544&#x26;fp-y=0.5551&#x26;fp-z=2.2887&#x26;w=1200&#x26;border=2%2CF4F2F7&#x26;border-radius=8%2C8%2C8%2C8&#x26;border-radius-inner=8%2C8%2C8%2C8&#x26;blend-align=bottom&#x26;blend-mode=normal&#x26;blend-x=0&#x26;blend-w=1200&#x26;blend64=aHR0cHM6Ly9pbWFnZXMudGFuZ28udXMvc3RhdGljL21hZGUtd2l0aC10YW5nby13YXRlcm1hcmstdjIucG5n&#x26;mark-x=236&#x26;mark-y=357&#x26;m64=aHR0cHM6Ly9pbWFnZXMudGFuZ28udXMvc3RhdGljL2JsYW5rLnBuZz9tYXNrPWNvcm5lcnMmYm9yZGVyPTYlMkNGRjc0NDImdz0zNzYmaD03MiZmaXQ9Y3JvcCZjb3JuZXItcmFkaXVzPTEw" alt="1. Go to your merged PR and Click Into It"><figcaption><p>Step 1 </p></figcaption></figure>

### 2. Click the "..." button at the top-right of your PR description

<figure><img src="https://images.tango.us/workflows/2cc8efaf-a4f0-4968-9904-46440dbc5702/steps/2dbdf227-9745-4e4d-9b13-23c503433fe9/aa31a1c4-1ac4-48e0-8fbc-f75165c1328e.png?crop=focalpoint&#x26;fit=crop&#x26;fp-x=0.6504&#x26;fp-y=0.4077&#x26;fp-z=2.7859&#x26;w=1200&#x26;border=2%2CF4F2F7&#x26;border-radius=8%2C8%2C8%2C8&#x26;border-radius-inner=8%2C8%2C8%2C8&#x26;blend-align=bottom&#x26;blend-mode=normal&#x26;blend-x=0&#x26;blend-w=1200&#x26;blend64=aHR0cHM6Ly9pbWFnZXMudGFuZ28udXMvc3RhdGljL21hZGUtd2l0aC10YW5nby13YXRlcm1hcmstdjIucG5n&#x26;mark-x=554&#x26;mark-y=328&#x26;m64=aHR0cHM6Ly9pbWFnZXMudGFuZ28udXMvc3RhdGljL2JsYW5rLnBuZz9tYXNrPWNvcm5lcnMmYm9yZGVyPTYlMkNGRjc0NDImdz05MyZoPTEyOSZmaXQ9Y3JvcCZjb3JuZXItcmFkaXVzPTEw" alt="2. Click the &#x22;...&#x22; button at the top-right of your PR description"><figcaption><p>Step 2 </p></figcaption></figure>

### 3. Select "Edit"

<figure><img src="https://images.tango.us/workflows/2cc8efaf-a4f0-4968-9904-46440dbc5702/steps/83f6f31a-08b7-462c-953a-206ecc35eb76/3632c0ea-dd2b-407d-9cbe-a4683defcbe7.png?crop=focalpoint&#x26;fit=crop&#x26;fp-x=0.5852&#x26;fp-y=0.5517&#x26;fp-z=2.1423&#x26;w=1200&#x26;border=2%2CF4F2F7&#x26;border-radius=8%2C8%2C8%2C8&#x26;border-radius-inner=8%2C8%2C8%2C8&#x26;blend-align=bottom&#x26;blend-mode=normal&#x26;blend-x=0&#x26;blend-w=1200&#x26;blend64=aHR0cHM6Ly9pbWFnZXMudGFuZ28udXMvc3RhdGljL21hZGUtd2l0aC10YW5nby13YXRlcm1hcmstdjIucG5n&#x26;mark-x=386&#x26;mark-y=352&#x26;m64=aHR0cHM6Ly9pbWFnZXMudGFuZ28udXMvc3RhdGljL2JsYW5rLnBuZz9tYXNrPWNvcm5lcnMmYm9yZGVyPTYlMkNGRjc0NDImdz00MjkmaD04MiZmaXQ9Y3JvcCZjb3JuZXItcmFkaXVzPTEw" alt="3. Select &#x22;Edit&#x22;"><figcaption><p>Step 3</p></figcaption></figure>

### 4. Add close #\[issue-number] to the PR description text

<mark style="background-color:orange;">**Example**</mark>: If fixing issue `#5`, add `close #5` to your PR description.

<figure><img src="https://images.tango.us/workflows/2cc8efaf-a4f0-4968-9904-46440dbc5702/steps/8c78e0a9-8fc1-48d1-9458-acda6930cb8d/1019ec27-54fa-47de-80b6-56bbbaf2fcb6.png?crop=focalpoint&#x26;fit=crop&#x26;fp-x=0.5000&#x26;fp-y=0.5000&#x26;w=1200&#x26;border=2%2CF4F2F7&#x26;border-radius=8%2C8%2C8%2C8&#x26;border-radius-inner=8%2C8%2C8%2C8&#x26;blend-align=bottom&#x26;blend-mode=normal&#x26;blend-x=0&#x26;blend-w=1200&#x26;blend64=aHR0cHM6Ly9pbWFnZXMudGFuZ28udXMvc3RhdGljL21hZGUtd2l0aC10YW5nby13YXRlcm1hcmstdjIucG5n&#x26;mark-x=122&#x26;mark-y=192&#x26;m64=aHR0cHM6Ly9pbWFnZXMudGFuZ28udXMvc3RhdGljL2JsYW5rLnBuZz9tYXNrPWNvcm5lcnMmYm9yZGVyPTQlMkNGRjc0NDImdz0zNzMmaD0xNjcmZml0PWNyb3AmY29ybmVyLXJhZGl1cz0xMA%3D%3D" alt="4. Add close #[issue-number] to the PR description text"><figcaption><p>Step 4 </p></figcaption></figure>

### 5. Click on "Update Comment"

<figure><img src="https://images.tango.us/workflows/2cc8efaf-a4f0-4968-9904-46440dbc5702/steps/2491ffd4-6656-42c6-9251-8761f051bcc1/f739b2f6-3f6c-46ba-b6f7-5292fc690195.png?crop=focalpoint&#x26;fit=crop&#x26;fp-x=0.6085&#x26;fp-y=0.6863&#x26;fp-z=2.3474&#x26;w=1200&#x26;border=2%2CF4F2F7&#x26;border-radius=8%2C8%2C8%2C8&#x26;border-radius-inner=8%2C8%2C8%2C8&#x26;blend-align=bottom&#x26;blend-mode=normal&#x26;blend-x=0&#x26;blend-w=1200&#x26;blend64=aHR0cHM6Ly9pbWFnZXMudGFuZ28udXMvc3RhdGljL21hZGUtd2l0aC10YW5nby13YXRlcm1hcmstdjIucG5n&#x26;mark-x=423&#x26;mark-y=344&#x26;m64=aHR0cHM6Ly9pbWFnZXMudGFuZ28udXMvc3RhdGljL2JsYW5rLnBuZz9tYXNrPWNvcm5lcnMmYm9yZGVyPTYlMkNGRjc0NDImdz0zNTUmaD05OCZmaXQ9Y3JvcCZjb3JuZXItcmFkaXVzPTEw" alt="5. Click on &#x22;Update Comment&#x22;"><figcaption><p>Step 5</p></figcaption></figure>

### # That's it!

This connects your PR to the issue and will trigger your bounty payment automatically.

***

### ℹ️ Important Notes:

* The `close`keyword must be in the PR description itself, not in regular comments.
* Adding this connection after merging will automatically trigger the lightning bounty payment.&#x20;
* If you cannot edit the PR, ask the repo owner to add the `close`syntax for you.

</details>

<details>

<summary><mark style="background-color:orange;"><strong>[2]</strong></mark><strong> Creating a New Pull Request When You Forgot to Add close #issue-number</strong></summary>

If your original pull request has been merged but you forgot to include the `close #issue-number` syntax needed for Lightning Bounties payment:

## Steps to Create a New PR

### **1. Create a new branch** from the current main/master branch

{% code fullWidth="false" %}

```bash
git checkout main
git pull
git checkout -b fix-bounty-issue-reference
```

{% endcode %}

### **2. Make a minimal change** (can be as simple as updating documentation or adding a comment)

*Example: Add a small comment or documentation update* :arrow\_down:

{% code fullWidth="true" %}

```bash
git add .
git commit -m "Add reference to close issue #X for Lightning Bounty"
```

{% endcode %}

### 3. Push your branch

```bash
git push origin fix-bounty-issue-reference
```

### **4. Create the new pull request**

* Go to the repository on GitHub
* Click "Compare & pull request"
* **Important**: Include `close #X` or `closes #X` in the PR description (where X is your issue number)
* Explain that this PR is to properly close the issue for Lightning Bounty payment
* Reference your original PR: "This PR references the work completed in #Y"

### ℹ️ Important Notes:&#x20;

* The repository owner will need to review and approve this new PR
* This is a technical solution to trigger the Lightning Bounties payment system
* The minimal change is necessary as GitHub requires actual content changes for a PR

</details>

## 4 - Claim reward in [app.lightningbounties.com](https://app.lightningbounties.com/)

Once the Pull Request gets approved, the developer can claim the reward

<figure><img src="/files/OSEfS0qYUeasw0ttWECZ" alt=""><figcaption></figcaption></figure>

### 4.1 - Click on "Claim Reward" and add pull requested number

<figure><img src="/files/4PdrtTkWRC7J92XBSr7J" alt=""><figcaption></figcaption></figure>

### 4.2 - Reward will be added to the balance

<figure><img src="/files/EKvi25Yax1WBG6N5C194" alt=""><figcaption></figcaption></figure>


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.lightningbounties.com/docs/getting-started/solving-a-bounty/working-on-the-bounty.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
