# Ad Server setup

## Self Google Ad Manager Setup

### Targeting send to Adserver

The following targeting is sent to the adserver.

```typescript
 {
    n360_type: 'amp',
    n360_bidder: 'appnexus',
    n360_pb: '1.08',
    n360_pb_test: '1.08',
    n360_price: 1.08,
    n360_cache_id: '25b93401-2bf1-4867-a1b3-8665515b31fe',
    n360_label: 'Goodtest',
    n360_tag_id: 'adjusted',
    n360_consent: 1
}
```

### Creative

The following creative need to be implemented.

```javascript
<script src='https://cdn.nexx360-static.io/creative.js'></script>
<script>
	try {
		n360Tag.renderAd(document, %%PATTERN:TARGETINGMAP%%);
	} catch (e) {
		console.log(e);
	}
</script>
```

Safeframe needs to be activated.

You need to setup multiple Creative to properly deliver the ads.

## Connect the Google Ad Manager (GAM) account

In order to generate bids on your inventory, Nexx360 requires a connection to your Google Ad Manager (GAM) account to push SSPs orders and line items. This will enable competition between your direct campaigns, Google Ad Exchange and the SSPs configured in Nexx360.

Few steps are required, see below.

### 1. Enable API Access

In your GAM account, go to *“Admin”* > *“Global settings”* > *“Network settings”* section. Enable API access (if it’s not already done) and add a service account user with the following information:

* *Email:* <gamlineitemtool@nexx360.iam.gserviceaccount.com>
* *Role:* Administrator

![](/files/-MYnoSl5Cjle574TGrlY)

### 2. Add new GAM account

Please send a message to [tech@nexx360.io](https://malto:tech@nexx360.io) with your Network name and Network ID (this information can be found on the top of your GAM account menu or in the "*Admin”* > *“Global settings”* > *“Network settings”* section). This step will allow the Nexx360 team to finalize the set up.

![](/files/-MYnpc4Hed7_JlfYrZlQ)

### 3. Generate AMP line items

Once the set up is finalized, the AMP line items will be generated automatically in your GAM account with a campaign for each SSP. Then, you can locate all created campaigns in your GAM account under “Nexx360 - AMP - SSP”.

{% hint style="warning" %}
If you have multiple GAM accounts, it's essential to repeat this process for each network.
{% endhint %}


---

# 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/amp/connect-your-gam-account.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.
