# APIs de Ofertas

```
GET https://api.offer18.com/api/m/offers
```

:link: [<mark style="color:azul;">**Clique para testar a API de Ofertas**</mark> ](https://offer18.readme.io/reference/offers-api-2)

### **Parâmetros Comuns**

<table data-header-hidden><thead><tr><th width="282.21480547854435">Query</th><th width="191.2954426994595"> </th><th> </th></tr></thead><tbody><tr><td><strong>Query</strong></td><td><strong>Tipo</strong></td><td><strong>Descrição</strong>  </td></tr><tr><td>mid</td><td>Inteiro</td><td>ID da Conta da Rede</td></tr><tr><td>api-key</td><td>String</td><td>Chave de API da Rede</td></tr><tr><td>secret-key</td><td>String</td><td>Chave Secreta da Rede</td></tr></tbody></table>

***

### Filtros

| **Query**         | **Tipo** | **Descrição**                                                                                                                   |
| ----------------- | -------- | ------------------------------------------------------------------------------------------------------------------------------- |
| advertiser\_id    | String   | ID do Anunciante                                                                                                                |
| offer\_id         | String   | ID da Oferta                                                                                                                    |
| category          | String   | Categoria da Oferta                                                                                                             |
| status            | Inteiro  | <p>offer\_status <br>  <strong>1</strong> : Aprovado<br>  <strong>2</strong> : Pendente<br>  <strong>3</strong> : Encerrado</p> |
| offer\_name       | String   | Nome da Oferta                                                                                                                  |
| model\_affiliate  | String   | Modelo do Afiliado (CPA, CPC, etc)                                                                                              |
| model\_advertiser | String   | Modelo do Anunciante (CPA, CPC, etc)                                                                                            |
| limit             | Inteiro  | Número da oferta                                                                                                                |
| page              | Inteiro  | Número da página                                                                                                                |

{% code overflow="wrap" %}

```
https://api.offer18.com/api/m/offers?mid=000&api-key=000000&secret-key=000000000&advertiser_id=00000&offer_id=00000&status=1&offer_name=offername&model_affiliate=CPA&model_advertiser=CPA&limit=100
```

{% endcode %}

***

### Exemplo de Requisição API

<figure><img src="https://4294454144-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F41f2EboJipeUA6flsLGK%2Fuploads%2FbuGgTqI0QfyGt2txDVG1%2Fimage.png?alt=media&#x26;token=e3142acc-8816-4e07-a092-c64b4e0ffbf7" alt=""><figcaption></figcaption></figure>

***

### Resposta da API

```
{
    "response": "200",
    "data": {
        "00011": {
            "offerid": "00011",
            "offer_name": "Oferta de teste",
            "logo": "https://example.com/sample.jpeg",
            "status": "Aprovado",
            "category": "",
            "currency": "INR",
            "price_affiliate": "10",
            "model_affiliate": "CPA",
            "price_advertiser": "10",
            "model_advertiser": "CPA",
            "advertiser_id": "11111",
            "external_offer_id": "",
            "app_id": "",
            "visibility": "public",
            "deep_links": "disabled",
            "private_note": "",
            "start_datetime": "2023-02-13 09:35:00",
            "end_datetime": "2025-02-13 09:35:00",
            "preview_url": "",
            "offer_description": "Termos e condições padrão da oferta.. ",
            "offer_kpi": "",
            "country_allow": "US",
            "os_allow": "android,ios",
            "device_allow": "smartphone",
            "browser_allow": "ch",
            "capping": [
    {
        "affiliate_visibility": "show",
        "rule_type": "shared_capping",
        "event": "",
        "type": "gross_conversions",
        "period": "daily",
        "value": 10,
        "over_capping_action": "conversion_pending",
        "timezone": "",
        "rule_id": "1001"
    },
    {
        "affiliate_visibility": "show",
        "rule_type": "affiliate_capping",
        "affiliates": "",
        "event": "",
        "type": "approved_conversions",
        "period": "daily",
        "value": 10,
        "over_capping_action": "conversion_pending",
        "timezone": "",
        "rule_id": "1002"
    }
],
            "events": [
    {
        "event_name": "reagistration",
        "event_token": "reagistration"
    }
],
            "affiliate_payout_tier": "",
            "payout": [
    {
        "affiliate_price": "10.00000",
        "advertiser_price": "10.00000",
        "currency": "USD",
        "affiliate_model": "CPA",
        "advertiser_model": "CPA",
        "condition": [
            [
                {
                    "field": "event",
                    "operator_type": "is_equal",
                    "value": "reagistration"
                }
            ]
        ],
        "rule_id": "1101"
    },
    {
        "affiliate_price": "15.00000",
        "advertiser_price": "15.00000",
        "currency": "USD",
        "affiliate_model": "CPA",
        "advertiser_model": "CPA",
        "condition": [
            [
                {
                    "field": "affiliate_id",
                    "operator_type": "is_equal",
                    "value": "00001"
                }
            ]
        ],
        "rule_id": "1102"
    }
],
            "affiliates": {
    "00001": {
        "name": "Afiliado",
        "status": "approved",
        "tracking_url": "https:\/\/test.o18.link\/c?o=00011&m=0000&a=00001",
        "impression_url": "https:\/\/test.o18.link\/i?o=00011&m=0000&a=00001"
    }
},
            "impression_url": "https:\/\/www.impression.com",
            "offer_url": "https:\/\/www.example.com",
            "postback_type": "S2S",
            "fallback_url": "https:\/\/fallbackurl.com",
            "fallback": "enabled",
            "conversion_lifespan": "2592000 seconds",
            "multi_conversions": "no",
            "conversion_approval": "auto",
            "multi_ip_conversions": "allow",
            "default_event": "initial",
            "event_mismatch_action": "registrar conversão como evento inicial",
            "landing_pages": null,
            "creatives": [
    {
        "type": "image",
        "url": "https:\/\/d25e10dl5yrpaz.cloudfront.net\/3872\/21005008\/21005008-1707817058301480-con.png"
    }
]
        }
    }
}
```


---

# 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://knowledgebase.offer18.com/pt/rede/api-da-rede/apis-de-ofertas.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.
