Adds an upstream to the list video placements pick from.
Reference
POST https://YOUR-NETWORK-DOMAIN/rest-api/upstream-macro-presets.do
Adds an upstream to the list video placements pick from. code, name and the macros are needed. Invalid values come back per field in errors (code, name, macros.clientIp, …); fields that were sent but not applied are listed in 'ignoredFields'. Requires the UPSTREAM_MACRO_PRESETS admin permission (Admin → Creatives & tags → Upstream macro presets).
Body
A JSON body. An example, built from the field definitions:
using var client = new HttpClient();
var request = new HttpRequestMessage(new HttpMethod("POST"), "https://YOUR-NETWORK-DOMAIN/rest-api/upstream-macro-presets.do");
request.Headers.Add("X-Api-Key", "YOUR_API_KEY");
request.Content = new StringContent("{\"code\":\"ACME_SSAI\",\"name\":\"Acme SSAI\",\"source\":\"https://docs.acme.tv/ssai/macros\",\"asOf\":\"2026-11-04\"}", Encoding.UTF8, "application/json");
var response = await client.SendAsync(request);
Console.WriteLine(await response.Content.ReadAsStringAsync());