# Affiliate link add

* To create a metafield follow the instructions -&#x20;

{% content-ref url="how-to-create-metafield" %}
[how-to-create-metafield](https://lezada.docs.hasthemes.com/product/product-metafield-for-online-store-2.0/how-to-create-metafield)
{% endcontent-ref %}

## Affiliate link add instead of the "Add To Cart" button

![](https://2660769954-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-MccyNuK6eTGishgIP-S%2F-Mhg5aJO6wr7aQECS7aL%2F-Mhg8MTfTo3etCPuFObg%2Faffi3.png?alt=media\&token=82d4a539-dc97-400a-92b7-edf5846eed65)

## Metafield Setup

* **Metafield name: &#x20;*****Product Affiliate Link***
* **Namespace and key:**  `meta.product_affiliate_link`

```
meta.product_affiliate_link
```

![](https://2660769954-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-MccyNuK6eTGishgIP-S%2F-Mhg9EMx_iVx-icBhet8%2F-Mhg9dCEin2p-VAUM-us%2Faffi1.png?alt=media\&token=b20e25a7-a25f-4571-bfe8-09c4cfa024e3)

### Add Affiliate link for a specific product <a href="#add-youtube-video-id-for-a-specific-product" id="add-youtube-video-id-for-a-specific-product"></a>

![](https://2660769954-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-MccyNuK6eTGishgIP-S%2F-Mhg9fbjjsDtaH_T0Q7W%2F-Mhg9qcjaZS3U6nKKMoe%2Faffi2.png?alt=media\&token=b5324abc-f5ec-4b21-84fb-a3d90ac866e7)


---

# 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://lezada.docs.hasthemes.com/product/product-metafield-for-online-store-2.0/affiliate-link-add.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.
