# Request example

## Android Banner Request

```json
{
    "id": "92ca2c72-53c0-4552-be3c-7559398564cb",
    "imp": [
        {
            "id": "92ca2c72-53c0-4552-be3c-7559398564cb",
            "instl": 0,
            "clickbrowser": 0,
            "secure": 1,
            "banner": {
                "api": [5],
                "format": [
                    {"w": 300, "h": 250},
                    {"w": 320, "h": 50}
                ]
            },
            "ext": {
                "prebid": {
                    "storedrequest": {
                        "id": "testnexx"
                    }
                }
            }
        }
    ],
    "app": {
        "name": "Prebid Java Demo",
        "bundle": "org.prebid.mobile.javademo",
        "ver": "1.0.0",
        "publisher": {
            "id": "1109"
        },
        "ext": {
            "prebid": {
                "source": "prebid-mobile",
                "version": "2.2.0"
            }
        }
    },
    "device": {
        "ua": "Mozilla/5.0 (Linux; Android 12; sdk_gphone64_x86_64 Build/SE1A.211212.001.B1; wv) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/91.0.4472.114 Mobile Safari/537.36",
        "lmt": 0,
        "devicetype": 4,
        "make": "Google",
        "model": "sdk_gphone64_x86_64",
        "os": "Android",
        "osv": "12",
        "language": "en",
        "carrier": "T-Mobile",
        "mccmnc": "310-260",
        "ifa": "a4ea4cad-5806-46a7-90b1-a64f9e3f0d25",
        "h": 3120,
        "w": 1440,
        "connectiontype": 2,
        "pxratio": 3.5
    },
    "regs": {
        "ext": {
            "gdpr": 0
        }
    },
    "user": {},
    "source": {
        "tid": "92ca2c72-53c0-4552-be3c-7559398564cb"
    },
    "ext": {
        "prebid": {
            "storedrequest": {
                "id": "1109"
            },
            "cache": {
                "bids": {}
            },
            "targeting": {}
        }
    }
}
```

## iOS Banner Request

```json
{
    "id": "b7c8d9e0-f1a2-3b4c-5d6e-7f8g9h0i1j2k",
    "imp": [
        {
            "id": "b7c8d9e0-f1a2-3b4c-5d6e-7f8g9h0i1j2k",
            "instl": 0,
            "clickbrowser": 0,
            "secure": 1,
            "banner": {
                "api": [5, 6, 7],
                "format": [
                    {"w": 300, "h": 250}
                ]
            },
            "ext": {
                "prebid": {
                    "storedrequest": {
                        "id": "testnexx"
                    }
                }
            }
        }
    ],
    "app": {
        "name": "My iOS App",
        "bundle": "com.example.myiosapp",
        "ver": "2.0.0",
        "publisher": {
            "id": "1109"
        },
        "ext": {
            "prebid": {
                "source": "prebid-mobile",
                "version": "2.2.0"
            }
        }
    },
    "device": {
        "ua": "Mozilla/5.0 (iPhone; CPU iPhone OS 17_0 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) Mobile/15E148",
        "lmt": 0,
        "devicetype": 4,
        "make": "Apple",
        "model": "iPhone14,5",
        "os": "iOS",
        "osv": "17.0",
        "language": "en",
        "ifa": "6D92078A-8246-4BA4-AE5B-76104861E7DC",
        "h": 2532,
        "w": 1170,
        "connectiontype": 2,
        "pxratio": 3.0,
        "ext": {
            "atts": 3,
            "ifv": "A1B2C3D4-E5F6-7890-ABCD-EF1234567890"
        }
    },
    "regs": {
        "ext": {
            "gdpr": 1
        }
    },
    "user": {
        "ext": {
            "consent": "BOEFEAyOEFEAyAHABDENAI4AAAB9vABAASA"
        }
    },
    "source": {
        "tid": "b7c8d9e0-f1a2-3b4c-5d6e-7f8g9h0i1j2k",
        "ext": {
            "omidpv": "1.4.0"
        }
    },
    "ext": {
        "prebid": {
            "storedrequest": {
                "id": "1109"
            },
            "cache": {
                "bids": {}
            },
            "targeting": {}
        }
    }
}
```

## Interstitial Request

For interstitial ads, set `instl: 1` in the impression object:

```json
{
    "id": "interstitial-request-id",
    "imp": [
        {
            "id": "interstitial-imp-id",
            "instl": 1,
            "clickbrowser": 0,
            "secure": 1,
            "banner": {
                "api": [5, 6],
                "format": [
                    {"w": 320, "h": 480},
                    {"w": 480, "h": 320}
                ]
            },
            "ext": {
                "prebid": {
                    "storedrequest": {
                        "id": "testnexx-interstitial"
                    }
                }
            }
        }
    ],
    "app": {
        "name": "My App",
        "bundle": "com.example.myapp",
        "ver": "1.0.0",
        "publisher": {
            "id": "1109"
        },
        "ext": {
            "prebid": {
                "source": "prebid-mobile",
                "version": "2.2.0"
            }
        }
    },
    "device": {
        "ua": "Mozilla/5.0 (Linux; Android 13; Pixel 7) AppleWebKit/537.36",
        "os": "Android",
        "osv": "13",
        "make": "Google",
        "model": "Pixel 7",
        "ifa": "a4ea4cad-5806-46a7-90b1-a64f9e3f0d25",
        "h": 2400,
        "w": 1080,
        "connectiontype": 2
    },
    "source": {
        "tid": "interstitial-request-id"
    },
    "ext": {
        "prebid": {
            "storedrequest": {"id": "1109"},
            "cache": {"bids": {}},
            "targeting": {}
        }
    }
}
```

## Video Request

```json
{
    "id": "video-request-id",
    "imp": [
        {
            "id": "video-imp-id",
            "instl": 0,
            "secure": 1,
            "video": {
                "mimes": ["video/mp4", "video/x-m4v"],
                "protocols": [2, 3, 5, 6],
                "w": 320,
                "h": 480,
                "linearity": 1,
                "minduration": 5,
                "maxduration": 30,
                "playbackmethod": [1, 2],
                "api": [7]
            },
            "ext": {
                "prebid": {
                    "storedrequest": {
                        "id": "testnexx-video"
                    }
                }
            }
        }
    ],
    "app": {
        "name": "My App",
        "bundle": "com.example.myapp",
        "ver": "1.0.0",
        "publisher": {
            "id": "1109"
        },
        "ext": {
            "prebid": {
                "source": "prebid-mobile",
                "version": "2.2.0"
            }
        }
    },
    "device": {
        "ua": "Mozilla/5.0 (iPhone; CPU iPhone OS 17_0 like Mac OS X)",
        "os": "iOS",
        "osv": "17.0",
        "make": "Apple",
        "model": "iPhone",
        "ifa": "6D92078A-8246-4BA4-AE5B-76104861E7DC",
        "h": 2532,
        "w": 1170,
        "connectiontype": 2
    },
    "source": {
        "tid": "video-request-id",
        "ext": {
            "omidpv": "1.4.0"
        }
    },
    "ext": {
        "prebid": {
            "storedrequest": {"id": "1109"},
            "cache": {"bids": {}, "vastxml": {}},
            "targeting": {}
        }
    }
}
```

## Native Request

```json
{
    "id": "native-request-id",
    "imp": [
        {
            "id": "native-imp-id",
            "instl": 0,
            "secure": 1,
            "native": {
                "request": "{\"ver\":\"1.2\",\"assets\":[{\"id\":1,\"required\":1,\"title\":{\"len\":90}},{\"id\":2,\"required\":1,\"img\":{\"type\":3,\"wmin\":300,\"hmin\":250}},{\"id\":3,\"required\":0,\"data\":{\"type\":2,\"len\":90}}]}",
                "ver": "1.2"
            },
            "ext": {
                "prebid": {
                    "storedrequest": {
                        "id": "testnexx-native"
                    }
                }
            }
        }
    ],
    "app": {
        "name": "My App",
        "bundle": "com.example.myapp",
        "ver": "1.0.0",
        "publisher": {
            "id": "1109"
        },
        "ext": {
            "prebid": {
                "source": "prebid-mobile",
                "version": "2.2.0"
            }
        }
    },
    "device": {
        "ua": "Mozilla/5.0 (Linux; Android 13; Pixel 7) AppleWebKit/537.36",
        "os": "Android",
        "osv": "13",
        "make": "Google",
        "model": "Pixel 7",
        "ifa": "a4ea4cad-5806-46a7-90b1-a64f9e3f0d25",
        "h": 2400,
        "w": 1080,
        "connectiontype": 2
    },
    "source": {
        "tid": "native-request-id"
    },
    "ext": {
        "prebid": {
            "storedrequest": {"id": "1109"},
            "cache": {"bids": {}},
            "targeting": {}
        }
    }
}
```

## Key Fields Reference

### Device Object

| Field            | Type    | Description                                       |
| ---------------- | ------- | ------------------------------------------------- |
| `ua`             | string  | User agent string                                 |
| `os`             | string  | Operating system (Android, iOS)                   |
| `osv`            | string  | OS version                                        |
| `make`           | string  | Device manufacturer                               |
| `model`          | string  | Device model                                      |
| `ifa`            | string  | Advertising ID (IDFA for iOS, AAID for Android)   |
| `w`              | integer | Screen width in pixels                            |
| `h`              | integer | Screen height in pixels                           |
| `connectiontype` | integer | 2=WiFi, 3=Cellular                                |
| `lmt`            | integer | Limit Ad Tracking (0=tracking allowed, 1=limited) |

### Banner API Values

| Value | Framework |
| ----- | --------- |
| 3     | MRAID 1.0 |
| 5     | MRAID 2.0 |
| 6     | MRAID 3.0 |
| 7     | OMID 1.0  |

### iOS ATT Status (device.ext.atts)

| Value | Status         |
| ----- | -------------- |
| 0     | Not determined |
| 1     | Restricted     |
| 2     | Denied         |
| 3     | Authorized     |


---

# 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://developer.nexx360.io/integration-methods/inapp/request-example.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.
