> ## Documentation Index
> Fetch the complete documentation index at: https://developers.criteo.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Line Item Bidding

> Retrieve and set the bidding configuration for an Onsite Display Auction or Sponsored Product Auction line item.

## Overview

Use the Line Item Bidding endpoints to retrieve and set the bidding configuration of a line item.

The endpoints support both Onsite Display Auction and Sponsored Product Auction line items.

> [!NOTE]
>
> **Availability: Available**
>
> This endpoint is available in the **Experimental** version of the Retail Media API only. Experimental endpoints may change without prior notice. See the [versioning policy](https://developers.criteo.com/criteo-apis/docs/versioning-policy.md) for details.

The response identifies the active strategy and includes preserved settings for the inactive strategy when available. This allows clients to inspect both Standard page-type bids and the Adaptive maximum bid without losing previously configured values.

## Endpoints

| Method | Endpoint | Description | Availability |
| - | - | - | - |
| `GET` | `/experimental/retail-media/line-items/{line-item-id}/bidding` | Retrieve the current bidding configuration for a line item. | Available |
| `POST` | `/experimental/retail-media/line-items/{line-item-id}/set-bidding` | Set the bidding configuration for a line item. | Available |

## Get Bidding

GET

```http theme={null}
https://api.criteo.com/experimental/retail-media/line-items/{line-item-id}/bidding
```

### Path parameter

| Parameter | Type | Required | Description |
| - | - | - | - |
| `line-item-id` | string | Yes | The unique identifier of the line item to retrieve. |

The authenticated user must have permission to view the requested line item.

### Sample request

```bash theme={null}
curl -X GET "https://api.criteo.com/experimental/retail-media/line-items/123456789012345678/bidding" \
  -H "Authorization: Bearer <MY_ACCESS_TOKEN>" \
  -H "Accept: application/json"
```

### Response attributes

All attributes below are nested under `data.attributes` in the response envelope.

| Attribute | Type | Description |
| - | - | - |
| `maxBid` | number or null | The ceiling on how much the auction may bid for the line item, in the line item's currency. |

### Sample response

```json theme={null}
{
  "data": {
    "type": "LineItemBiddingResponse",
    "attributes": {
      "maxBid": 2.8
    }
  }
}
```

### Responses

| Status | Code | Description |
| - | - | - |
| `200 OK` | | Returns the current bidding configuration for a line item. |
| `400 Bad Request` | `unsupported-line-item-type` | The bidding configuration is available only for Onsite Display Auction and Sponsored Product Auction line items. |
| `400 Bad Request` | `unsupported-bid-strategy` | The bidding configuration is available only for line items that use Adaptive bidding. |
| `401 Unauthorized` | `unauthorized` | The caller is not authenticated. |
| `403 Forbidden` | `forbidden` | The caller does not have access to the requested line item. |
| `500 Internal Server Error` | `internal-error` | The bidding configuration could not be retrieved, usually because a dependent service failed. Retry the request. If the failure persists, contact support. |

***

## Set Bidding

The endpoint replaces the submitted Standard page-type bids. It updates only the strategy settings supplied in the request — omitted settings are preserved.

POST

```http theme={null}
https://api.criteo.com/experimental/retail-media/line-items/{line-item-id}/set-bidding
```

### Path parameter

| Parameter | Type | Required | Description |
| - | - | - | - |
| `line-item-id` | string | Yes | The unique identifier of the line item to retrieve. |

The authenticated user must have permission to edit the requested line item.

### Request attributes

All attributes below are nested under `data.attributes` in the request envelope.

| Attribute | Type | Description |
| - | - | - |
| `maxBid` | number or null | The ceiling on how much the auction may bid for the line item, in the line item's currency. |

### Sample request

```bash theme={null}
curl -X POST "https://api.criteo.com/experimental/retail-media/line-items/123456789012345678/set-bidding" \
  -H "Authorization: Bearer <MY_ACCESS_TOKEN>" \
  -H "Accept: application/json" \
  -H "Content-Type: application/json" \
  --data-raw '{
    "data": {
      "type": "LineItemBiddingRequest",
      "attributes": {
        "maxBid": 4.2
      }
    }
  }'
```

### Response attributes

All attributes below are nested under `data.attributes` in the response envelope.

| Attribute | Type | Description |
| - | - | - |
| `maxBid` | number or null | The ceiling on how much the auction may bid for the line item, in the line item's currency. |

### Sample response

```json theme={null}
{
  "data": {
    "type": "LineItemBiddingResponse",
    "attributes": {
      "maxBid": 4.2
    }
  },
  "warnings": [],
  "errors": []
}
```

### Responses

| Status | Code | Description |
| - | - | - |
| `200 OK` | | Returns the saved bidding configuration for the line item. Inspect `errors` and `warnings` before treating the response as complete. |
| `400 Bad Request` | `unsupported-line-item-type` | The bidding configuration is available only for Onsite Display Auction and Sponsored Product Auction line items. |
| `400 Bad Request` | `unsupported-bid-strategy` | The bidding configuration is available only for line items that use Adaptive bidding. |
| `401 Unauthorized` | `unauthorized` | The caller is not authenticated. |
| `403 Forbidden` | `forbidden` | The caller does not have access to the requested line item. |
| `500 Internal Server Error` | `internal-error` | The bidding configuration could not be set, usually because a dependent service failed. Retry the request. If the failure persists, contact support. |
