# Functions Subscription

### Connect MetaMask

Go to [Chainlink Functions](https://functions.chain.link/) and perform the following actions:

1. Make sure you are on Avalanche Fuji Testnet from the drop-down menu
2. Click the “Connect wallet” icon at the top right to connect your MetaMask wallet

<figure><img src="/files/cY1BjtlpNsOzrHqIoOWS" alt=""><figcaption><p>Connect MetaMask to Chainlink Functions</p></figcaption></figure>

<figure><img src="/files/WceLnTOnOySjnWFeOZKr" alt=""><figcaption><p>Click the MetaMask icon the left</p></figcaption></figure>

MetaMask will pop-up to connect your wallet, click "Next":

<div align="left"><figure><img src="/files/ogoUDW3ucKCA85WoXcae" alt=""><figcaption><p>Click "Next"</p></figcaption></figure></div>

Now click "Connect":

<div align="left"><figure><img src="/files/PRfOP81kVjyrQQnGWm71" alt=""><figcaption><p>Click "Connect"</p></figcaption></figure></div>

### Create a Subscription and Add Funds

Once you are connected to Chainlink Functions and on the Avalanche Fuji Testnet, click the “Create Subscription” button:

<figure><img src="/files/sI3pOdzuDlpbkJerFQZJ" alt=""><figcaption><p>Time to create a Chainlink subscription</p></figcaption></figure>

The next steps are:

* &#x20;add your email address (#1),&#x20;
* put in “Bootcamp Project” for “Subscription name” (#2) and
* accept the privacy policy and click the “Create Subscription” button (#3)

<figure><img src="/files/woouxy9cf3s2Nsmf9FUv" alt=""><figcaption><p>Create Functions Subscription</p></figcaption></figure>

MetaMask will pop-up with a “Confirm” request, so click the “Confirm” button at the bottom right:

<div align="left"><figure><img src="/files/pVmj6TYWiciySJUPmqwp" alt=""><figcaption><p>Click "Confirm"</p></figcaption></figure></div>

You need to approve the Functions terms of service and the subscription creation on the next MetaMask window, click the “Confirm” button at the bottom right to approve this request:

<figure><img src="/files/Q1ObgUVob0DD60H23B8d" alt=""><figcaption><p>Approve the subscription by cliicking "Confimr"</p></figcaption></figure>

After the transaction to approve the subscription, you need to sign the message to save your subscription name and email address. Click the “Sign” button at the bottom right to sign the message:

<figure><img src="/files/n7OBW1bjOYgtX6YEJxCf" alt=""><figcaption><p>Sign the message</p></figcaption></figure>

Upon a successful subscription creation, you need to add LINK to your Functions Subscription to fund the Chainlink oracles to run Chainlink Functions . Click the “Add funds'' button at the bottom:

<figure><img src="/files/6jDyDnrfCqWNi6LdJDuK" alt=""><figcaption><p>You will need to ass funds to pay for the subscription</p></figcaption></figure>

On the following page,  put in `5` for the LINK amount (#1) and then click the “Add funds” blue button (#2):

<figure><img src="/files/WNNjNgORVcQQCZN4dVMo" alt=""><figcaption><p>Adding LINK to our subscription</p></figcaption></figure>

You will now need to confirm the transaction to send LINK to your Subscription.  MetaMask will pop-up and click the “Confirm” button at the bottom right to approve adding funds:

<figure><img src="/files/Qh11gNloxx2CugwuBBt7" alt=""><figcaption><p>Confirm the adding of funds</p></figcaption></figure>

Once done, you can refresh the page, and see your subsciption's details and LINK balance.

<figure><img src="/files/y4TGHgBRP6rOsr9GVTJq" alt=""><figcaption><p>Successfully funded our subscription with LINK</p></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://cll-devrel.gitbook.io/bootcamp-2024/9.-off-chain-data-with-chainlink-functions/functions-subscription.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.
