For the complete documentation index, see llms.txt. This page is also available as Markdown.

Goals

Operations related to Goals, the conversion events and objectives tracked for campaign optimization and measurement. Goals can be triggered:

  • Via tracking pixels (for one-time conversions on confirmation pages)

  • Via OTQL query rules (for complex, recurring conversion logic)

Goals are associated with attribution models for campaign attribution.

Relevant documentation:

Get goal

get
/goals/{id}
Path parameters
idinteger · int64Required
Responses
200

Success !

application/json
statusstring · enumRequiredPossible values:
get/goals/{id}
GET /v1/goals/{id} HTTP/1.1
Host: api.mediarithmics.local
Accept: */*
{
  "status": "ok",
  "data": {
    "new_query_id": "text",
    "archived": false,
    "organisation_id": "text",
    "technical_name": "text",
    "goal_value_currency": "text",
    "id": "text",
    "query_id": "text",
    "status": "PAUSED",
    "datamart_id": "text",
    "default_goal_value": 0,
    "name": "text"
  }
}

Update goal

put
/goals/{id}
Path parameters
idinteger · int64Required
Body
new_query_idstringOptional
archivedbooleanRequiredDefault: false
organisation_idstringRequired
technical_namestringOptional
goal_value_currencystringOptional
idstringRead-onlyRequired
query_idstringOptional
statusstring · enumRequiredPossible values:
datamart_idstringRequired
default_goal_valuenumber · floatOptionalDefault: 0
namestringOptional
Responses
200

Success !

application/json
statusstring · enumRequiredPossible values:
put/goals/{id}
PUT /v1/goals/{id} HTTP/1.1
Host: api.mediarithmics.local
Content-Type: application/json
Accept: */*
Content-Length: 212

{
  "new_query_id": "text",
  "archived": false,
  "organisation_id": "text",
  "technical_name": "text",
  "goal_value_currency": "text",
  "query_id": "text",
  "status": "PAUSED",
  "datamart_id": "text",
  "default_goal_value": 0,
  "name": "text"
}
{
  "status": "ok",
  "data": {
    "new_query_id": "text",
    "archived": false,
    "organisation_id": "text",
    "technical_name": "text",
    "goal_value_currency": "text",
    "id": "text",
    "query_id": "text",
    "status": "PAUSED",
    "datamart_id": "text",
    "default_goal_value": 0,
    "name": "text"
  }
}

Delete a goal

delete
/goals/{id}
Path parameters
idinteger · int64Required
Responses
200

Success response

application/json
statusstring · enumRequiredPossible values:
delete/goals/{id}
DELETE /v1/goals/{id} HTTP/1.1
Host: api.mediarithmics.local
Accept: */*
{
  "status": "ok"
}

Search every goal for an organisation

get
/goals
Query parameters
organisation_idinteger · int64Required

The organisation id to search into

datamart_idinteger · int64Optional

The Datamart id to search into

keywordsstringOptional

The keywords to match with goal name

archivedbooleanOptional

Whether to filter with archived or not

order_bystring[]Optional

Fields used to order the result

label_idinteger · int64[]Optional

Label id

first_resultinteger · int32Optional

Offset from which the search must be performed

max_resultsinteger · int32Optional

Number of maximum items that shall be return by this search

statusstring · enumOptional

Goal's status ACTIVE or PAUSED

Possible values:
Responses
200

Success !

application/json
statusstring · enumRequiredPossible values:
countintegerRequired
first_resultintegerRequired
totalintegerRequired
max_resultsintegerRequired
get/goals
GET /v1/goals?organisation_id=1 HTTP/1.1
Host: api.mediarithmics.local
Accept: */*
{
  "status": "ok",
  "count": 1,
  "data": [
    {
      "new_query_id": "text",
      "archived": false,
      "organisation_id": "text",
      "technical_name": "text",
      "goal_value_currency": "text",
      "id": "text",
      "query_id": "text",
      "status": "PAUSED",
      "datamart_id": "text",
      "default_goal_value": 0,
      "name": "text"
    }
  ],
  "first_result": 1,
  "total": 1,
  "max_results": 1
}

Creates a new goal feed for the specified organisation

post
/goals
Query parameters
organisation_idinteger · int64Required

The organisation to create the new goal into

Body
new_query_idstringOptional
archivedbooleanRequiredDefault: false
organisation_idstringRequired
technical_namestringOptional
goal_value_currencystringOptional
idstringRead-onlyRequired
query_idstringOptional
statusstring · enumRequiredPossible values:
datamart_idstringRequired
default_goal_valuenumber · floatOptionalDefault: 0
namestringOptional
Responses
200

Success !

application/json
statusstring · enumRequiredPossible values:
post/goals
POST /v1/goals?organisation_id=1 HTTP/1.1
Host: api.mediarithmics.local
Content-Type: application/json
Accept: */*
Content-Length: 212

{
  "new_query_id": "text",
  "archived": false,
  "organisation_id": "text",
  "technical_name": "text",
  "goal_value_currency": "text",
  "query_id": "text",
  "status": "PAUSED",
  "datamart_id": "text",
  "default_goal_value": 0,
  "name": "text"
}
{
  "status": "ok",
  "data": {
    "new_query_id": "text",
    "archived": false,
    "organisation_id": "text",
    "technical_name": "text",
    "goal_value_currency": "text",
    "id": "text",
    "query_id": "text",
    "status": "PAUSED",
    "datamart_id": "text",
    "default_goal_value": 0,
    "name": "text"
  }
}

Last updated

Was this helpful?