Returns all targeting rules configured for the specified site as a JSON array.
Reference
GET https://YOUR-NETWORK-DOMAIN/rest-api/site/{siteId}/targetings.do
Returns all targeting rules configured for the specified site as a JSON array. Each element contains the targeting rule type, value, rule (INCLUDE/EXCLUDE), and status. Requires UPDATE permission on the site and MANAGE_SUPPLY_PRE_TARGETING user permission.
using var client = new HttpClient();
var request = new HttpRequestMessage(new HttpMethod("GET"), "https://YOUR-NETWORK-DOMAIN/rest-api/site/3001/targetings.do");
request.Headers.Add("X-Api-Key", "YOUR_API_KEY");
var response = await client.SendAsync(request);
Console.WriteLine(await response.Content.ReadAsStringAsync());