Nexta Developer Portal

Nexta Developer Portal

  • Guides
  • API

›Guides

Introduction

  • Overview
  • Getting started
  • Authentication and authorization
  • API health
  • Error handling

Guides

  • Client onboarding
  • Campaign creation
  • Banner upload
  • Goals API
  • Campaign Set Status
  • Facebook Special Ad Categories

Goals API

This document describes how to set up a campaign and campaign set Goals using Nexta API.

Motivation

What is the purpose of running an algorithm on a digital marketing setup? In most cases it is to achieve certain business goals. Examples could be:

  • Deliver 1000 clicks across 3 campaigns, while spending no more than 500 EUR.
  • Deliver 200 clicks on Facebook Traffic and 400 clicks on Adform Traffic if possible, else deliver 600 clicks on any campaign, and spend no more than 300 EUR.

We created Goals as an easy way of specifying business goals in a formalized way, that can be consumed by our algorithms and backend.

How to set up Goals using Nexta API

Goals have their own API and can be set on both campaign and set level.

A single goal is uniquely defined by its properties, that are as follows:

Property nameTypeAllowed valuesDescription
ValuenumberThis is the target value of the desired Metric
MetricstringCost, Impressions, Clicks, Leads, ReachRefers to the quantity you want to specify the Goal for
ComparerstringEqual, LessThanOrEqual, GreaterThanOrEqualDetermines if a Goal is a target (Equal) or upper/lower (LessThanOrEqual/GreaterThanOrEqual) limits
TimeRangestringLifetime, DailyTime range where Goal should apply. Should the Goal refer to the whole campaign (Lifetime) or daily level (Daily)
ValueDefinitionstringAbsolute, RelativeThis specifies whether the Value is the absolute value to be used, or if it is a relative value.
Examples
Absolute: This campaign needs to deliver 100 clicks.
Relative: This campaign needs to deliver 0.3 of the set Goal. Set Goal might be 1000 clicks, hence campaign Goal becomes 0.3 * 1000 = 300 clicks.

Example: Adding and changing campaign set budget and click goal using Goals

To add Goals to a campaign set, you would have to

  • Create an empty campaign set
  • Create campaign (drafts) with initial budgets. E.g. create
    1. An Adform campaign with a budget of 600 EUR
    2. A Facebook Traffic campaign with a budget of 600 EUR
    3. A Facebook Leads campaign with a budget of 800 EUR

Now, create Nexta Goals specifying the maximum campaign set budget and the campaign set click goal, e.g.

[
  {
    "Value": 4000,
    "Metric": "Clicks",
    "Comparer": "Equal",
    "TimeRange": "Lifetime",
    "ValueDefinition": "Absolute"
  },
  {
    "Value": 2000,
    "Metric": "Cost",
    "Comparer": "LessThanOrEqual",
    "TimeRange": "Lifetime",
    "ValueDefinition": "Absolute"
  }
]

Whenever you want to change the budget or click goal, you can PUT Goals with the new desired values. The changes will come into effect the following morning. E.g. if you put

[
  {
    "Value": 4000,
    "Metric": "Clicks",
    "Comparer": "Equal",
    "TimeRange": "Lifetime",
    "ValueDefinition": "Absolute"
  },
  {
    "Value": 4000,
    "Metric": "Cost",
    "Comparer": "LessThanOrEqual",
    "TimeRange": "Lifetime",
    "ValueDefinition": "Absolute"
  }
]

Then the next morning the algorithm will be allowed to assign campaign budgets summing to at most 4000 EUR, from the previous 2000 EUR.

← Banner uploadCampaign Set Status →
  • How to set up Goals using Nexta API
  • Example: Adding and changing campaign set budget and click goal using Goals
Copyright © 2024 Nexta ApS