HTTP mechanics

This page outlines the HTTP-level behavior of the standard adapter integration with The Trade Desk. Specifically, it indicates which headers The Trade Desk evaluates in incoming bid requests, and how to interpret the response codes it returns. For the payload reference, see Standard Adapter.

HTTP header requirements

To maintain accurate user identification and request routing across its marketplace, The Trade Desk acts on a small number of HTTP headers. Most standard headers, including x-openrtb-version and Content-Type, are not evaluated during bidding. The Content-Length header is used to enforce a maximum request size (see also HTTP response codes).

IMPORTANT: For in-app traffic rendered via WebView environments, we strongly recommend passing the X-Requested-With (XRW) header when supported by the client.

HTTP response codes

The Trade Desk returns the following HTTP response codes in response to bid requests. See also No-bid reason codes.

Code Name Description
200 OK The Trade Desk is bidding. The response body contains at least one bid as a JSON payload. This code is also returned when The Trade Desk sends a no-bid reason (nbr field) for suppliers configured to receive it.
204 No Content The Trade Desk is not bidding. This code is returned when no eligible bids are available. It is also returned when The Trade Desk would otherwise include a no-bid reason (nbr field), but the supplier is not configured to receive it.
400 Bad Request The bid request is malformed or invalid. For example, it contains invalid JSON or a schema violation. Correct the issue before resubmitting.
413 Request Entity Too Large The bid request exceeds the maximum permitted size. Reduce the request size before resubmitting.
500 Internal Server Error An unexpected error occurred on The Trade Desk side.