Reference
Marketing
GET/api/v1/marketing/ai-visibilityGet ai visibility
Whether AI assistants and search engines read one registered website, and whether people arrive from AI assistants, for a period: crawler totals per bot (kind ai or search, hits), crawler_hits, ai_sessions, ai_inquiries and their conversion, the pages of the latest sitemap no crawler has read (never_crawled, first 50), the busiest crawled pages and the AI sources people came from. Visitors are counted per day: in cookieless mode one person on three days counts 3, in consent mode only visitors who allowed „Statistik“ are counted; in combined mode visitors who allowed „Statistik“ are recognised across days and all others are counted per day without cookies. revenue_cents is the net of issued invoices of the inquiries received in the period (gestellte Rechnungen, netto), so it keeps growing after the period. Inquiries without a matched visit count as „Unbekannt“ (unknown). Figures exclude bots.scope leads:read
Query
| site | stringDomain of the website, like example.com. Optional when exactly one website is registered. |
| period | one of 7d, 28d, 90d, this_month, last_monthPeriod ending today (Europe/Berlin days). Default 28d. Ignored when from and to are given. |
| from | stringFirst day of a free range, YYYY-MM-DD. Needs to as well. |
| to | stringLast day of a free range, YYYY-MM-DD. Needs from as well. |
| compare | booleanAlso return the previous period of the same length. Default true. |
Response 200
| site | string |
| period | object |
| period.from | string |
| period.to | string |
| period.previous | object | null |
| period.previous.from | string |
| period.previous.to | string |
| consent_mode | one of cookieless, consent, combined |
| consent_rateoptional | number | null |
| consent_noteoptional | string |
| totals | object |
| totals.crawler_hits | number |
| totals.bots | number |
| totals.ai_sessions | number |
| totals.ai_inquiries | number |
| totals.ai_conversion | number | null |
| totals.never_crawled | number |
| totals.sitemap_pages | number |
| previousoptional | object |
| previous.crawler_hits | number |
| previous.ai_sessions | number |
| previous.ai_inquiries | number |
| bots[] | object[] |
| bots[].bot | string |
| bots[].kind | string |
| bots[].hits | number |
| top_pages[] | object[] |
| top_pages[].path | string |
| top_pages[].hits | number |
| top_pages[].ai_hits | number |
| top_pages[].last_day | string |
| never_crawled[] | object[] |
| never_crawled[].path | string |
| never_crawled[].first_seen_at | string |
| ai_sources[] | object[] |
| ai_sources[].source | string |
| ai_sources[].sessions | number |
| ai_sources[].inquiries | number |
| ai_sources[].conversion | number | null |
| ai_sources[].top_landing | string | null |
| sitemap_read_at | string | null |
Schema
{
"type": "object",
"properties": {
"site": {
"type": "string"
},
"period": {
"type": "object",
"properties": {
"from": {
"type": "string"
},
"to": {
"type": "string"
},
"previous": {
"anyOf": [
{
"type": "object",
"properties": {
"from": {
"type": "string"
},
"to": {
"type": "string"
}
},
"required": [
"from",
"to"
],
"additionalProperties": false
},
{
"type": "null"
}
]
}
},
"required": [
"from",
"to",
"previous"
],
"additionalProperties": false
},
"consent_mode": {
"type": "string",
"enum": [
"cookieless",
"consent",
"combined"
]
},
"consent_rate": {
"type": [
"number",
"null"
]
},
"consent_note": {
"type": "string"
},
"totals": {
"type": "object",
"properties": {
"crawler_hits": {
"type": "number"
},
"bots": {
"type": "number"
},
"ai_sessions": {
"type": "number"
},
"ai_inquiries": {
"type": "number"
},
"ai_conversion": {
"type": [
"number",
"null"
]
},
"never_crawled": {
"type": "number"
},
"sitemap_pages": {
"type": "number"
}
},
"required": [
"crawler_hits",
"bots",
"ai_sessions",
"ai_inquiries",
"ai_conversion",
"never_crawled",
"sitemap_pages"
],
"additionalProperties": false
},
"previous": {
"type": "object",
"properties": {
"crawler_hits": {
"type": "number"
},
"ai_sessions": {
"type": "number"
},
"ai_inquiries": {
"type": "number"
}
},
"required": [
"crawler_hits",
"ai_sessions",
"ai_inquiries"
],
"additionalProperties": false
},
"bots": {
"type": "array",
"items": {
"type": "object",
"properties": {
"bot": {
"type": "string"
},
"kind": {
"type": "string"
},
"hits": {
"type": "number"
}
},
"required": [
"bot",
"kind",
"hits"
],
"additionalProperties": false
}
},
"top_pages": {
"type": "array",
"items": {
"type": "object",
"properties": {
"path": {
"type": "string"
},
"hits": {
"type": "number"
},
"ai_hits": {
"type": "number"
},
"last_day": {
"type": "string"
}
},
"required": [
"path",
"hits",
"ai_hits",
"last_day"
],
"additionalProperties": false
}
},
"never_crawled": {
"type": "array",
"items": {
"type": "object",
"properties": {
"path": {
"type": "string"
},
"first_seen_at": {
"type": "string"
}
},
"required": [
"path",
"first_seen_at"
],
"additionalProperties": false
}
},
"ai_sources": {
"type": "array",
"items": {
"type": "object",
"properties": {
"source": {
"type": "string"
},
"sessions": {
"type": "number"
},
"inquiries": {
"type": "number"
},
"conversion": {
"type": [
"number",
"null"
]
},
"top_landing": {
"type": [
"string",
"null"
]
}
},
"required": [
"source",
"sessions",
"inquiries",
"conversion",
"top_landing"
],
"additionalProperties": false
}
},
"sitemap_read_at": {
"type": [
"string",
"null"
]
}
},
"required": [
"site",
"period",
"consent_mode",
"totals",
"bots",
"top_pages",
"never_crawled",
"ai_sources",
"sitemap_read_at"
],
"additionalProperties": false
}Refusals are problems with a code — see Errors.
GET/api/v1/marketing/assistant-statsGet assistant stats
Website assistant figures of one registered website for a period: totals (started, qualified, inquiries, quotes, revenue_cents), the previous period of equal length (previous, with compare), the same per assistant profile (version, conversion = inquiries / started), the most frequent answers per question of one profile (profile, default the one with most conversations) and how many conversations ended without contact details, before or after the result. started = conversations with at least one visitor message; qualified = the assistant finished its questions; inquiries = inquiries captured by the assistant, received in the period; revenue = net of issued invoices of those inquiries, so it grows after the period; free-text answers come from inquiries only — conversation text is deleted after 24 hours; test conversations never count.scope leads:read
Query
| site | stringDomain of the website, like example.com. Optional when exactly one website is registered. |
| period | one of 7d, 28d, 90d, this_month, last_monthPeriod ending today (Europe/Berlin days). Default 28d. Ignored when from and to are given. |
| from | stringFirst day of a free range, YYYY-MM-DD. Needs to as well. |
| to | stringLast day of a free range, YYYY-MM-DD. Needs from as well. |
| compare | booleanAlso return the previous period of the same length. Default true. |
| profile | stringProfile id or exact name; selects the profile whose answers are returned. Default: the profile with most conversations. |
Response 200
| site | string |
| period | object |
| period.from | string |
| period.to | string |
| period.previous | object | null |
| period.previous.from | string |
| period.previous.to | string |
| revenue_note | string |
| totals | object |
| totals.started | number |
| totals.qualified | number |
| totals.inquiries | number |
| totals.quotes | number |
| totals.revenue_cents | number |
| previousoptional | object |
| previous.started | number |
| previous.qualified | number |
| previous.inquiries | number |
| previous.quotes | number |
| previous.revenue_cents | number |
| profiles[] | object[] |
| profiles[].id | string |
| profiles[].name | string |
| profiles[].version | number | null |
| profiles[].started | number |
| profiles[].qualified | number |
| profiles[].inquiries | number |
| profiles[].conversion | number | null |
| profiles[].quotes | number |
| profiles[].revenue_cents | number |
| answers[] | object[] |
| answers[].question | string |
| answers[].type | string |
| answers[].source | one of conversations, inquiries |
| answers[].total | number |
| answers[].values[] | object[] |
| answers[].values[].value | string |
| answers[].values[].count | number |
| ended_without_contact | object |
| ended_without_contact.total | number |
| ended_without_contact.before_result | number |
| ended_without_contact.after_result | number |
Schema
{
"type": "object",
"properties": {
"site": {
"type": "string"
},
"period": {
"type": "object",
"properties": {
"from": {
"type": "string"
},
"to": {
"type": "string"
},
"previous": {
"anyOf": [
{
"type": "object",
"properties": {
"from": {
"type": "string"
},
"to": {
"type": "string"
}
},
"required": [
"from",
"to"
],
"additionalProperties": false
},
{
"type": "null"
}
]
}
},
"required": [
"from",
"to",
"previous"
],
"additionalProperties": false
},
"revenue_note": {
"type": "string"
},
"totals": {
"type": "object",
"properties": {
"started": {
"type": "number"
},
"qualified": {
"type": "number"
},
"inquiries": {
"type": "number"
},
"quotes": {
"type": "number"
},
"revenue_cents": {
"type": "number"
}
},
"required": [
"started",
"qualified",
"inquiries",
"quotes",
"revenue_cents"
],
"additionalProperties": false
},
"previous": {
"type": "object",
"properties": {
"started": {
"type": "number"
},
"qualified": {
"type": "number"
},
"inquiries": {
"type": "number"
},
"quotes": {
"type": "number"
},
"revenue_cents": {
"type": "number"
}
},
"required": [
"started",
"qualified",
"inquiries",
"quotes",
"revenue_cents"
],
"additionalProperties": false
},
"profiles": {
"type": "array",
"items": {
"type": "object",
"properties": {
"id": {
"type": "string"
},
"name": {
"type": "string"
},
"version": {
"type": [
"number",
"null"
]
},
"started": {
"type": "number"
},
"qualified": {
"type": "number"
},
"inquiries": {
"type": "number"
},
"conversion": {
"type": [
"number",
"null"
]
},
"quotes": {
"type": "number"
},
"revenue_cents": {
"type": "number"
}
},
"required": [
"id",
"name",
"version",
"started",
"qualified",
"inquiries",
"conversion",
"quotes",
"revenue_cents"
],
"additionalProperties": false
}
},
"answers": {
"type": "array",
"items": {
"type": "object",
"properties": {
"question": {
"type": "string"
},
"type": {
"type": "string"
},
"source": {
"type": "string",
"enum": [
"conversations",
"inquiries"
]
},
"total": {
"type": "number"
},
"values": {
"type": "array",
"items": {
"type": "object",
"properties": {
"value": {
"type": "string"
},
"count": {
"type": "number"
}
},
"required": [
"value",
"count"
],
"additionalProperties": false
}
}
},
"required": [
"question",
"type",
"source",
"total",
"values"
],
"additionalProperties": false
}
},
"ended_without_contact": {
"type": "object",
"properties": {
"total": {
"type": "number"
},
"before_result": {
"type": "number"
},
"after_result": {
"type": "number"
}
},
"required": [
"total",
"before_result",
"after_result"
],
"additionalProperties": false
}
},
"required": [
"site",
"period",
"revenue_note",
"totals",
"profiles",
"answers",
"ended_without_contact"
],
"additionalProperties": false
}Refusals are problems with a code — see Errors.
POST/api/v1/marketing/campaign-linksBuild campaign link
Builds and saves the tracked link of a campaign: target_url on a registered website plus utm_source, utm_medium, utm_campaign (the campaign's slug) and optional utm_content. Use it for every post and mail you draft for a campaign, so the traffic is attributed to it. Give a preset (linkedin, newsletter or ai) or source and medium. The same link asked twice is not duplicated (created false). Returns link_id, url and created; put url into the text.scope leads:write
Body (JSON)
| campaignrequired | stringThe campaign's id or slug. |
| target_urlrequired | stringThe page the link leads to, on a registered website. |
| preset | one of linkedin, newsletter, ai |
| source | stringutm_source, when no preset is given. |
| medium | stringutm_medium, when no preset is given. |
| content | stringutm_content, to tell several posts apart. |
| labelrequired | stringWhat the link is for, like „LinkedIn-Post 12.11.“ |
Response 200
| link_id | string |
| url | string |
| created | boolean |
Schema
{
"type": "object",
"properties": {
"link_id": {
"type": "string"
},
"url": {
"type": "string"
},
"created": {
"type": "boolean"
}
},
"required": [
"link_id",
"url",
"created"
],
"additionalProperties": false
}Refusals are problems with a code — see Errors.
GET/api/v1/marketing/campaignsList campaigns
Marketing campaigns with their results, 50 per page: id, name, slug (the utm_campaign value), goal, channels, status (planned, active, ended), starts_on, ends_on, budget_cents, owner, link_count and the results (sessions, inquiries, quotes, won, revenue_cents, cost_cents, cost_per_inquiry_cents, roi). Without status it lists planned and active ones; give status to see ended ones. q searches name, slug and goal. Campaign figures are all-time since the first session (not limited to a period). Revenue = net of issued invoices of the campaign's inquiries. Costs = open incoming invoices assigned to the campaign, net.scope leads:read
Query
| status | one of planned, active, ended[]Default planned and active. |
| q | string |
| page | integer1-based page of 50 rows. Omit for the first page. |
Response 200
| items[] | object[] |
| items[].id | string |
| items[].name | string |
| items[].slug | string |
| items[].goal | string | null |
| items[].channels | one of linkedin, email, search, ai, paid, other[] |
| items[].status | one of planned, active, ended |
| items[].starts_on | string | null |
| items[].ends_on | string | null |
| items[].budget_cents | number | null |
| items[].owner | object | null |
| items[].owner.id | string |
| items[].owner.name | string | null |
| items[].link_count | number |
| items[].results | object |
| items[].results.sessions | number |
| items[].results.sessions_without_link | number |
| items[].results.inquiries | number |
| items[].results.inquiries_with_quotes | number |
| items[].results.quotes | number |
| items[].results.won | number |
| items[].results.revenue_cents | number |
| items[].results.cost_cents | number |
| items[].results.cost_per_inquiry_cents | number | null |
| items[].results.roi | number | null |
| page | integer |
| total | integer |
| has_more | boolean |
| hidden_ended | number |
| note | string |
Schema
{
"type": "object",
"properties": {
"items": {
"type": "array",
"items": {
"type": "object",
"properties": {
"id": {
"type": "string"
},
"name": {
"type": "string"
},
"slug": {
"type": "string"
},
"goal": {
"type": [
"string",
"null"
]
},
"channels": {
"type": "array",
"items": {
"type": "string",
"enum": [
"linkedin",
"email",
"search",
"ai",
"paid",
"other"
]
}
},
"status": {
"type": "string",
"enum": [
"planned",
"active",
"ended"
]
},
"starts_on": {
"type": [
"string",
"null"
]
},
"ends_on": {
"type": [
"string",
"null"
]
},
"budget_cents": {
"type": [
"number",
"null"
]
},
"owner": {
"anyOf": [
{
"type": "object",
"properties": {
"id": {
"type": "string"
},
"name": {
"type": [
"string",
"null"
]
}
},
"required": [
"id",
"name"
],
"additionalProperties": false
},
{
"type": "null"
}
]
},
"link_count": {
"type": "number"
},
"results": {
"type": "object",
"properties": {
"sessions": {
"type": "number"
},
"sessions_without_link": {
"type": "number"
},
"inquiries": {
"type": "number"
},
"inquiries_with_quotes": {
"type": "number"
},
"quotes": {
"type": "number"
},
"won": {
"type": "number"
},
"revenue_cents": {
"type": "number"
},
"cost_cents": {
"type": "number"
},
"cost_per_inquiry_cents": {
"type": [
"number",
"null"
]
},
"roi": {
"type": [
"number",
"null"
]
}
},
"required": [
"sessions",
"sessions_without_link",
"inquiries",
"inquiries_with_quotes",
"quotes",
"won",
"revenue_cents",
"cost_cents",
"cost_per_inquiry_cents",
"roi"
],
"additionalProperties": false
}
},
"required": [
"id",
"name",
"slug",
"goal",
"channels",
"status",
"starts_on",
"ends_on",
"budget_cents",
"owner",
"link_count",
"results"
],
"additionalProperties": false
}
},
"page": {
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
"total": {
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
"has_more": {
"type": "boolean"
},
"hidden_ended": {
"type": "number"
},
"note": {
"type": "string"
}
},
"required": [
"items",
"page",
"total",
"has_more",
"hidden_ended",
"note"
],
"additionalProperties": false
}Refusals are problems with a code — see Errors.
POST/api/v1/marketing/campaignsSave campaign
Creates a campaign, or changes one when id is given (fields left out stay as they are). name is required for a new one. slug is the utm_campaign value (lower case letters, digits, hyphens; default derived from the name); it cannot change once links or sessions exist. status is planned, active or ended (default: planned with a future starts_on, else active). Dates are YYYY-MM-DD, budget_cents is in cents. owner is a user id; a person acting leaves it out to own the campaign, an agent acting as itself must give it. assistant_profile and configurator_profile are the profiles (id or exact name) the landing pages use. Saving a slug adopts earlier sessions and inquiries that already carry it as utm_campaign.scope leads:write
Body (JSON)
| id | stringThe campaign to change; leave out to create one. |
| name | string |
| slug | string |
| goal | string | null |
| channels | one of linkedin, email, search, ai, paid, other[] |
| starts_on | string | null |
| ends_on | string | null |
| budget_cents | integer | null |
| owner | stringUser id of the person responsible. |
| assistant_profile | string | nullAssistant profile id or exact name. |
| configurator_profile | string | nullConfigurator profile id or exact name. |
| status | one of planned, active, ended |
Response 200
| id | string |
| name | string |
| slug | string |
| status | one of planned, active, ended |
| created | boolean |
| url | string |
Schema
{
"type": "object",
"properties": {
"id": {
"type": "string"
},
"name": {
"type": "string"
},
"slug": {
"type": "string"
},
"status": {
"type": "string",
"enum": [
"planned",
"active",
"ended"
]
},
"created": {
"type": "boolean"
},
"url": {
"type": "string"
}
},
"required": [
"id",
"name",
"slug",
"status",
"created",
"url"
],
"additionalProperties": false
}Refusals are problems with a code — see Errors.
GET/api/v1/marketing/campaigns/{id}Get campaign
One campaign: its fields, results, saved tracking links with their sessions, inquiries and ready-to-use urls, the costs booked on it (open incoming invoices) and its newest 10 inquiries, plus the assistant and configurator profile of its landing pages (id, name, site_key). Campaign figures are all-time since the first session (not limited to a period). Revenue = net of issued invoices of the campaign's inquiries. Costs = open incoming invoices assigned to the campaign, net. Link sessions cover raw retention only. costs.total_cents is for everyone; costs.invoices (supplier, date, amount per invoice) only with finance.manage, else null.scope leads:read
Path
| idrequired | stringThe campaign's id or slug. |
Response 200
| id | string |
| name | string |
| slug | string |
| goal | string | null |
| channels | one of linkedin, email, search, ai, paid, other[] |
| status | one of planned, active, ended |
| starts_on | string | null |
| ends_on | string | null |
| budget_cents | number | null |
| owner | object | null |
| owner.id | string |
| owner.name | string |
| assistant_profile | object | null |
| assistant_profile.id | string |
| assistant_profile.name | string |
| assistant_profile.site_key | string |
| configurator_profile | object | null |
| configurator_profile.id | string |
| configurator_profile.name | string |
| configurator_profile.site_key | string |
| results | object |
| results.sessions | number |
| results.sessions_without_link | number |
| results.inquiries | number |
| results.inquiries_with_quotes | number |
| results.quotes | number |
| results.won | number |
| results.revenue_cents | number |
| results.cost_cents | number |
| results.cost_per_inquiry_cents | number | null |
| results.roi | number | null |
| links[] | object[] |
| links[].id | string |
| links[].label | string |
| links[].site | string |
| links[].target_url | string |
| links[].utm_source | string |
| links[].utm_medium | string |
| links[].utm_content | string | null |
| links[].url | string |
| links[].sessions | number |
| links[].inquiries | number |
| costs | object |
| costs.total_cents | number |
| costs.invoices[] | object[] |
| costs.invoices[].id | string |
| costs.invoices[].supplier | string |
| costs.invoices[].invoice_date | string |
| costs.invoices[].net_cents | number |
| costs.invoices[].gross_fallback | boolean |
| inquiries | object |
| inquiries.total | number |
| inquiries.latest[] | object[] |
| inquiries.latest[].lead_id | string |
| inquiries.latest[].name | string |
| inquiries.latest[].company | string | null |
| inquiries.latest[].captured_by | string |
| inquiries.latest[].created_at | string |
| inquiries.latest[].status | string |
| note | string |
Schema
{
"type": "object",
"properties": {
"id": {
"type": "string"
},
"name": {
"type": "string"
},
"slug": {
"type": "string"
},
"goal": {
"type": [
"string",
"null"
]
},
"channels": {
"type": "array",
"items": {
"type": "string",
"enum": [
"linkedin",
"email",
"search",
"ai",
"paid",
"other"
]
}
},
"status": {
"type": "string",
"enum": [
"planned",
"active",
"ended"
]
},
"starts_on": {
"type": [
"string",
"null"
]
},
"ends_on": {
"type": [
"string",
"null"
]
},
"budget_cents": {
"type": [
"number",
"null"
]
},
"owner": {
"anyOf": [
{
"type": "object",
"properties": {
"id": {
"type": "string"
},
"name": {
"type": "string"
}
},
"required": [
"id",
"name"
],
"additionalProperties": false
},
{
"type": "null"
}
]
},
"assistant_profile": {
"anyOf": [
{
"type": "object",
"properties": {
"id": {
"type": "string"
},
"name": {
"type": "string"
},
"site_key": {
"type": "string"
}
},
"required": [
"id",
"name",
"site_key"
],
"additionalProperties": false
},
{
"type": "null"
}
]
},
"configurator_profile": {
"anyOf": [
{
"type": "object",
"properties": {
"id": {
"type": "string"
},
"name": {
"type": "string"
},
"site_key": {
"type": "string"
}
},
"required": [
"id",
"name",
"site_key"
],
"additionalProperties": false
},
{
"type": "null"
}
]
},
"results": {
"type": "object",
"properties": {
"sessions": {
"type": "number"
},
"sessions_without_link": {
"type": "number"
},
"inquiries": {
"type": "number"
},
"inquiries_with_quotes": {
"type": "number"
},
"quotes": {
"type": "number"
},
"won": {
"type": "number"
},
"revenue_cents": {
"type": "number"
},
"cost_cents": {
"type": "number"
},
"cost_per_inquiry_cents": {
"type": [
"number",
"null"
]
},
"roi": {
"type": [
"number",
"null"
]
}
},
"required": [
"sessions",
"sessions_without_link",
"inquiries",
"inquiries_with_quotes",
"quotes",
"won",
"revenue_cents",
"cost_cents",
"cost_per_inquiry_cents",
"roi"
],
"additionalProperties": false
},
"links": {
"type": "array",
"items": {
"type": "object",
"properties": {
"id": {
"type": "string"
},
"label": {
"type": "string"
},
"site": {
"type": "string"
},
"target_url": {
"type": "string"
},
"utm_source": {
"type": "string"
},
"utm_medium": {
"type": "string"
},
"utm_content": {
"type": [
"string",
"null"
]
},
"url": {
"type": "string"
},
"sessions": {
"type": "number"
},
"inquiries": {
"type": "number"
}
},
"required": [
"id",
"label",
"site",
"target_url",
"utm_source",
"utm_medium",
"utm_content",
"url",
"sessions",
"inquiries"
],
"additionalProperties": false
}
},
"costs": {
"type": "object",
"properties": {
"total_cents": {
"type": "number"
},
"invoices": {
"anyOf": [
{
"type": "array",
"items": {
"type": "object",
"properties": {
"id": {
"type": "string"
},
"supplier": {
"type": "string"
},
"invoice_date": {
"type": "string"
},
"net_cents": {
"type": "number"
},
"gross_fallback": {
"type": "boolean"
}
},
"required": [
"id",
"supplier",
"invoice_date",
"net_cents",
"gross_fallback"
],
"additionalProperties": false
}
},
{
"type": "null"
}
]
}
},
"required": [
"total_cents",
"invoices"
],
"additionalProperties": false
},
"inquiries": {
"type": "object",
"properties": {
"total": {
"type": "number"
},
"latest": {
"type": "array",
"items": {
"type": "object",
"properties": {
"lead_id": {
"type": "string"
},
"name": {
"type": "string"
},
"company": {
"type": [
"string",
"null"
]
},
"captured_by": {
"type": "string"
},
"created_at": {
"type": "string"
},
"status": {
"type": "string"
}
},
"required": [
"lead_id",
"name",
"company",
"captured_by",
"created_at",
"status"
],
"additionalProperties": false
}
}
},
"required": [
"total",
"latest"
],
"additionalProperties": false
},
"note": {
"type": "string"
}
},
"required": [
"id",
"name",
"slug",
"goal",
"channels",
"status",
"starts_on",
"ends_on",
"budget_cents",
"owner",
"assistant_profile",
"configurator_profile",
"results",
"links",
"costs",
"inquiries",
"note"
],
"additionalProperties": false
}Refusals are problems with a code — see Errors.
GET/api/v1/marketing/configurator-statsGet configurator stats
Configurator figures of one registered website for a period: totals (views, started, started_share, requests, quotes_sent, orders, revenue_cents, orders_monthly_net_cents), the previous period of equal length (previous, with compare), the chosen positions per group (in_runs = configurations, in_requests, in_quotes, in_orders; none = no position of an optional group), term and number of users, the ticked needs and the funnel of one profile (profile, default the first). views = widget loads on allowed domains; started = configurations with a first change; requests = inquiries received in the period; revenue = net of issued invoices of those inquiries, so it grows after the period; no visitor is identified.scope leads:read
Query
| site | stringDomain of the website, like example.com. Optional when exactly one website is registered. |
| period | one of 7d, 28d, 90d, this_month, last_monthPeriod ending today (Europe/Berlin days). Default 28d. Ignored when from and to are given. |
| from | stringFirst day of a free range, YYYY-MM-DD. Needs to as well. |
| to | stringLast day of a free range, YYYY-MM-DD. Needs from as well. |
| compare | booleanAlso return the previous period of the same length. Default true. |
| profile | stringConfigurator profile id or exact name. Default: the first profile of the website. |
Response 200
| site | string |
| period | object |
| period.from | string |
| period.to | string |
| period.previous | object | null |
| period.previous.from | string |
| period.previous.to | string |
| revenue_note | string |
| profileoptional | object |
| profile.id | string |
| profile.name | string |
| profiles[] | object[] |
| profiles[].id | string |
| profiles[].name | string |
| totals | object |
| totals.views | number |
| totals.started | number |
| totals.started_share | number | null |
| totals.requests | number |
| totals.quotes_sent | number |
| totals.orders | number |
| totals.revenue_cents | number |
| totals.orders_monthly_net_cents | number |
| previousoptional | object |
| previous.views | number |
| previous.started | number |
| previous.started_share | number | null |
| previous.requests | number |
| previous.quotes_sent | number |
| previous.orders | number |
| previous.revenue_cents | number |
| previous.orders_monthly_net_cents | number |
| groups[] | object[] |
| groups[].key | string |
| groups[].label | string |
| groups[].rule | string |
| groups[].rows[] | object[] |
| groups[].rows[].slot | string |
| groups[].rows[].label | string |
| groups[].rows[].in_runs | number |
| groups[].rows[].run_share | number |
| groups[].rows[].in_requests | number |
| groups[].rows[].in_quotes | number |
| groups[].rows[].in_orders | number |
| term | object | null |
| term.annual | number[] |
| term.monthly | number[] |
| users | object | null |
| users.runs | object | null |
| users.runs.median | number |
| users.runs.min | number |
| users.runs.max | number |
| users.requests | object | null |
| users.requests.median | number |
| users.requests.min | number |
| users.requests.max | number |
| users.quotes | object | null |
| users.quotes.median | number |
| users.quotes.min | number |
| users.quotes.max | number |
| users.orders | object | null |
| users.orders.median | number |
| users.orders.min | number |
| users.orders.max | number |
| needs[] | object[] |
| needs[].key | string |
| needs[].label | string |
| needs[].share | number |
| needs[].in_requests | number |
| funnel[] | object[] |
| funnel[].step | one of views, started, requests, quotes, orders |
| funnel[].count | number |
| funnel[].of_previous | number | null |
Schema
{
"type": "object",
"properties": {
"site": {
"type": "string"
},
"period": {
"type": "object",
"properties": {
"from": {
"type": "string"
},
"to": {
"type": "string"
},
"previous": {
"anyOf": [
{
"type": "object",
"properties": {
"from": {
"type": "string"
},
"to": {
"type": "string"
}
},
"required": [
"from",
"to"
],
"additionalProperties": false
},
{
"type": "null"
}
]
}
},
"required": [
"from",
"to",
"previous"
],
"additionalProperties": false
},
"revenue_note": {
"type": "string"
},
"profile": {
"type": "object",
"properties": {
"id": {
"type": "string"
},
"name": {
"type": "string"
}
},
"required": [
"id",
"name"
],
"additionalProperties": false
},
"profiles": {
"type": "array",
"items": {
"type": "object",
"properties": {
"id": {
"type": "string"
},
"name": {
"type": "string"
}
},
"required": [
"id",
"name"
],
"additionalProperties": false
}
},
"totals": {
"type": "object",
"properties": {
"views": {
"type": "number"
},
"started": {
"type": "number"
},
"started_share": {
"type": [
"number",
"null"
]
},
"requests": {
"type": "number"
},
"quotes_sent": {
"type": "number"
},
"orders": {
"type": "number"
},
"revenue_cents": {
"type": "number"
},
"orders_monthly_net_cents": {
"type": "number"
}
},
"required": [
"views",
"started",
"started_share",
"requests",
"quotes_sent",
"orders",
"revenue_cents",
"orders_monthly_net_cents"
],
"additionalProperties": false
},
"previous": {
"type": "object",
"properties": {
"views": {
"type": "number"
},
"started": {
"type": "number"
},
"started_share": {
"type": [
"number",
"null"
]
},
"requests": {
"type": "number"
},
"quotes_sent": {
"type": "number"
},
"orders": {
"type": "number"
},
"revenue_cents": {
"type": "number"
},
"orders_monthly_net_cents": {
"type": "number"
}
},
"required": [
"views",
"started",
"started_share",
"requests",
"quotes_sent",
"orders",
"revenue_cents",
"orders_monthly_net_cents"
],
"additionalProperties": false
},
"groups": {
"type": "array",
"items": {
"type": "object",
"properties": {
"key": {
"type": "string"
},
"label": {
"type": "string"
},
"rule": {
"type": "string"
},
"rows": {
"type": "array",
"items": {
"type": "object",
"properties": {
"slot": {
"type": "string"
},
"label": {
"type": "string"
},
"in_runs": {
"type": "number"
},
"run_share": {
"type": "number"
},
"in_requests": {
"type": "number"
},
"in_quotes": {
"type": "number"
},
"in_orders": {
"type": "number"
}
},
"required": [
"slot",
"label",
"in_runs",
"run_share",
"in_requests",
"in_quotes",
"in_orders"
],
"additionalProperties": false
}
}
},
"required": [
"key",
"label",
"rule",
"rows"
],
"additionalProperties": false
}
},
"term": {
"anyOf": [
{
"type": "object",
"properties": {
"annual": {
"type": "array",
"items": {
"type": "number"
}
},
"monthly": {
"type": "array",
"items": {
"type": "number"
}
}
},
"required": [
"annual",
"monthly"
],
"additionalProperties": false
},
{
"type": "null"
}
]
},
"users": {
"anyOf": [
{
"type": "object",
"properties": {
"runs": {
"anyOf": [
{
"type": "object",
"properties": {
"median": {
"type": "number"
},
"min": {
"type": "number"
},
"max": {
"type": "number"
}
},
"required": [
"median",
"min",
"max"
],
"additionalProperties": false
},
{
"type": "null"
}
]
},
"requests": {
"anyOf": [
{
"type": "object",
"properties": {
"median": {
"type": "number"
},
"min": {
"type": "number"
},
"max": {
"type": "number"
}
},
"required": [
"median",
"min",
"max"
],
"additionalProperties": false
},
{
"type": "null"
}
]
},
"quotes": {
"anyOf": [
{
"type": "object",
"properties": {
"median": {
"type": "number"
},
"min": {
"type": "number"
},
"max": {
"type": "number"
}
},
"required": [
"median",
"min",
"max"
],
"additionalProperties": false
},
{
"type": "null"
}
]
},
"orders": {
"anyOf": [
{
"type": "object",
"properties": {
"median": {
"type": "number"
},
"min": {
"type": "number"
},
"max": {
"type": "number"
}
},
"required": [
"median",
"min",
"max"
],
"additionalProperties": false
},
{
"type": "null"
}
]
}
},
"required": [
"runs",
"requests",
"quotes",
"orders"
],
"additionalProperties": false
},
{
"type": "null"
}
]
},
"needs": {
"type": "array",
"items": {
"type": "object",
"properties": {
"key": {
"type": "string"
},
"label": {
"type": "string"
},
"share": {
"type": "number"
},
"in_requests": {
"type": "number"
}
},
"required": [
"key",
"label",
"share",
"in_requests"
],
"additionalProperties": false
}
},
"funnel": {
"type": "array",
"items": {
"type": "object",
"properties": {
"step": {
"type": "string",
"enum": [
"views",
"started",
"requests",
"quotes",
"orders"
]
},
"count": {
"type": "number"
},
"of_previous": {
"type": [
"number",
"null"
]
}
},
"required": [
"step",
"count",
"of_previous"
],
"additionalProperties": false
}
}
},
"required": [
"site",
"period",
"revenue_note",
"profiles",
"totals",
"groups",
"term",
"users",
"needs",
"funnel"
],
"additionalProperties": false
}Refusals are problems with a code — see Errors.
GET/api/v1/marketing/inquiry-originGet inquiry origin
Where one inquiry (lead) came from: the snapshot of the website visit it was created from (channel, referrer, UTM fields, landing page, pages read with marks) as origin, null when the origin is unknown (such an inquiry counts as „Unbekannt“ in the figures). manual is true when the channel was set by hand (then origin has no site, landing page or pages), heard_about is what the sender answered to „Wie haben Sie von uns erfahren?“.scope leads:read
Query
| leadrequired | stringThe inquiry's (lead's) id. |
Response 200
| lead_id | string |
| origin | object | null |
| origin.site_id | string | null |
| origin.channel | string |
| origin.referrer_host | string | null |
| origin.utm_source | string | null |
| origin.utm_medium | string | null |
| origin.utm_campaign | string | null |
| origin.utm_content | string | null |
| origin.utm_term | string | null |
| origin.partner_token | string | null |
| origin.landing_path | string | null |
| origin.campaign_id | string | null |
| origin.from_ref | boolean |
| origin.pageviews | number |
| origin.events | number |
| origin.pages_read[] | object[] |
| origin.pages_read[].path | string |
| origin.pages_read[].marks | string[] |
| origin.at | string |
| origin.ended_at | string | null |
| origin.set_by_nameoptional | string |
| heard_about | string | null |
| manual | boolean |
Schema
{
"type": "object",
"properties": {
"lead_id": {
"type": "string"
},
"origin": {
"anyOf": [
{
"type": "object",
"properties": {
"site_id": {
"type": [
"string",
"null"
]
},
"channel": {
"type": "string"
},
"referrer_host": {
"type": [
"string",
"null"
]
},
"utm_source": {
"type": [
"string",
"null"
]
},
"utm_medium": {
"type": [
"string",
"null"
]
},
"utm_campaign": {
"type": [
"string",
"null"
]
},
"utm_content": {
"type": [
"string",
"null"
]
},
"utm_term": {
"type": [
"string",
"null"
]
},
"partner_token": {
"type": [
"string",
"null"
]
},
"landing_path": {
"type": [
"string",
"null"
]
},
"campaign_id": {
"type": [
"string",
"null"
]
},
"from_ref": {
"type": "boolean"
},
"pageviews": {
"type": "number"
},
"events": {
"type": "number"
},
"pages_read": {
"type": "array",
"items": {
"type": "object",
"properties": {
"path": {
"type": "string"
},
"marks": {
"type": "array",
"items": {
"type": "string"
}
}
},
"required": [
"path",
"marks"
],
"additionalProperties": false
}
},
"at": {
"type": "string"
},
"ended_at": {
"type": [
"string",
"null"
]
},
"set_by_name": {
"type": "string"
}
},
"required": [
"site_id",
"channel",
"referrer_host",
"utm_source",
"utm_medium",
"utm_campaign",
"utm_content",
"utm_term",
"partner_token",
"landing_path",
"campaign_id",
"from_ref",
"pageviews",
"events",
"pages_read",
"at",
"ended_at"
],
"additionalProperties": false
},
{
"type": "null"
}
]
},
"heard_about": {
"type": [
"string",
"null"
]
},
"manual": {
"type": "boolean"
}
},
"required": [
"lead_id",
"origin",
"heard_about",
"manual"
],
"additionalProperties": false
}Refusals are problems with a code — see Errors.
GET/api/v1/marketing/landing-pagesList landing pages
Landing pages of one registered website for a period, busiest first, 50 per page: sessions, bounce_rate, inquiries that started there, conversion, quotes, won orders and revenue_cents. Visitors are counted per day: in cookieless mode one person on three days counts 3, in consent mode only visitors who allowed „Statistik“ are counted; in combined mode visitors who allowed „Statistik“ are recognised across days and all others are counted per day without cookies. revenue_cents is the net of issued invoices of the inquiries received in the period (gestellte Rechnungen, netto), so it keeps growing after the period. Inquiries without a matched visit count as „Unbekannt“ (unknown). Figures exclude bots.scope leads:read
Query
| site | stringDomain of the website, like example.com. Optional when exactly one website is registered. |
| period | one of 7d, 28d, 90d, this_month, last_monthPeriod ending today (Europe/Berlin days). Default 28d. Ignored when from and to are given. |
| from | stringFirst day of a free range, YYYY-MM-DD. Needs to as well. |
| to | stringLast day of a free range, YYYY-MM-DD. Needs from as well. |
| page | integer1-based page of 50 rows. Omit for the first page. |
Response 200
| items[] | object[] |
| items[].path | string |
| items[].sessions | number |
| items[].bounce_rate | number | null |
| items[].inquiries | number |
| items[].conversion | number | null |
| items[].quotes | number |
| items[].won | number |
| items[].revenue_cents | number |
| page | integer |
| total | integer |
| has_more | boolean |
| site | string |
| period | object |
| period.from | string |
| period.to | string |
| period.previous | object | null |
| period.previous.from | string |
| period.previous.to | string |
| consent_mode | one of cookieless, consent, combined |
| consent_rateoptional | number | null |
| consent_noteoptional | string |
| revenue_note | string |
Schema
{
"type": "object",
"properties": {
"items": {
"type": "array",
"items": {
"type": "object",
"properties": {
"path": {
"type": "string"
},
"sessions": {
"type": "number"
},
"bounce_rate": {
"type": [
"number",
"null"
]
},
"inquiries": {
"type": "number"
},
"conversion": {
"type": [
"number",
"null"
]
},
"quotes": {
"type": "number"
},
"won": {
"type": "number"
},
"revenue_cents": {
"type": "number"
}
},
"required": [
"path",
"sessions",
"bounce_rate",
"inquiries",
"conversion",
"quotes",
"won",
"revenue_cents"
],
"additionalProperties": false
}
},
"page": {
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
"total": {
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
"has_more": {
"type": "boolean"
},
"site": {
"type": "string"
},
"period": {
"type": "object",
"properties": {
"from": {
"type": "string"
},
"to": {
"type": "string"
},
"previous": {
"anyOf": [
{
"type": "object",
"properties": {
"from": {
"type": "string"
},
"to": {
"type": "string"
}
},
"required": [
"from",
"to"
],
"additionalProperties": false
},
{
"type": "null"
}
]
}
},
"required": [
"from",
"to",
"previous"
],
"additionalProperties": false
},
"consent_mode": {
"type": "string",
"enum": [
"cookieless",
"consent",
"combined"
]
},
"consent_rate": {
"type": [
"number",
"null"
]
},
"consent_note": {
"type": "string"
},
"revenue_note": {
"type": "string"
}
},
"required": [
"items",
"page",
"total",
"has_more",
"site",
"period",
"consent_mode",
"revenue_note"
],
"additionalProperties": false
}Refusals are problems with a code — see Errors.
GET/api/v1/marketing/partner-statsGet partner stats
One referral partner for a period: partner (code, name, status, rule: the version valid now with kind percent, fixed or both, rate_percent, duration_months, fixed_cents), link_sessions (visits through the partner's link; null without a named website or before raw data retention), inquiries (of the named website, or of all websites when none is named: then site is null and site_note says so), by_via (link, manual), new_customers (referrals starting in the period), revenue_cents, commission_cents and statements (month, state, commission_cents; all months). partner is the display code. state: draft (not released), released (released, not paid), paid, credit_note_cancelled (the credit note was cancelled). Revenue = net of the issued invoices of the referred Firmen (cancellations subtracted, items excluded from the commission still included). Commission = the lines of the commission statements for invoices dated in the period, drafts included. Link sessions only count visitors who allowed „Statistik“ on a website in consent mode. Statements cannot be created or released here. Payout and tax data of partners are not available to agents.scope leads:read
Query
| partnerrequired | stringThe partner's display code. |
| site | stringDomain of the website, like example.com. Optional when exactly one website is registered. |
| period | one of 7d, 28d, 90d, this_month, last_monthPeriod ending today (Europe/Berlin days). Default 28d. Ignored when from and to are given. |
| from | stringFirst day of a free range, YYYY-MM-DD. Needs to as well. |
| to | stringLast day of a free range, YYYY-MM-DD. Needs from as well. |
| compare | booleanAlso return the previous period of the same length. Default true. |
Response 200
| partner | object |
| partner.code | string |
| partner.name | string |
| partner.status | string |
| partner.rule | object | null |
| partner.rule.version | number |
| partner.rule.kind | string |
| partner.rule.rate_percent | number | null |
| partner.rule.duration_months | number | null |
| partner.rule.fixed_cents | number | null |
| period | object |
| period.from | string |
| period.to | string |
| period.previous | object | null |
| period.previous.from | string |
| period.previous.to | string |
| site | string | null |
| site_noteoptional | string |
| consent_modeoptional | one of cookieless, consent, combined |
| consent_rateoptional | number | null |
| consent_noteoptional | string |
| link_sessions | number | null |
| inquiries | number |
| by_via | object |
| by_via.link | number |
| by_via.manual | number |
| new_customers | number |
| revenue_cents | number |
| commission_cents | number |
| statements[] | object[] |
| statements[].month | string |
| statements[].state | string |
| statements[].commission_cents | number |
Schema
{
"type": "object",
"properties": {
"partner": {
"type": "object",
"properties": {
"code": {
"type": "string"
},
"name": {
"type": "string"
},
"status": {
"type": "string"
},
"rule": {
"anyOf": [
{
"type": "object",
"properties": {
"version": {
"type": "number"
},
"kind": {
"type": "string"
},
"rate_percent": {
"type": [
"number",
"null"
]
},
"duration_months": {
"type": [
"number",
"null"
]
},
"fixed_cents": {
"type": [
"number",
"null"
]
}
},
"required": [
"version",
"kind",
"rate_percent",
"duration_months",
"fixed_cents"
],
"additionalProperties": false
},
{
"type": "null"
}
]
}
},
"required": [
"code",
"name",
"status",
"rule"
],
"additionalProperties": false
},
"period": {
"type": "object",
"properties": {
"from": {
"type": "string"
},
"to": {
"type": "string"
},
"previous": {
"anyOf": [
{
"type": "object",
"properties": {
"from": {
"type": "string"
},
"to": {
"type": "string"
}
},
"required": [
"from",
"to"
],
"additionalProperties": false
},
{
"type": "null"
}
]
}
},
"required": [
"from",
"to",
"previous"
],
"additionalProperties": false
},
"site": {
"type": [
"string",
"null"
]
},
"site_note": {
"type": "string"
},
"consent_mode": {
"type": "string",
"enum": [
"cookieless",
"consent",
"combined"
]
},
"consent_rate": {
"type": [
"number",
"null"
]
},
"consent_note": {
"type": "string"
},
"link_sessions": {
"type": [
"number",
"null"
]
},
"inquiries": {
"type": "number"
},
"by_via": {
"type": "object",
"properties": {
"link": {
"type": "number"
},
"manual": {
"type": "number"
}
},
"required": [
"link",
"manual"
],
"additionalProperties": false
},
"new_customers": {
"type": "number"
},
"revenue_cents": {
"type": "number"
},
"commission_cents": {
"type": "number"
},
"statements": {
"type": "array",
"items": {
"type": "object",
"properties": {
"month": {
"type": "string"
},
"state": {
"type": "string"
},
"commission_cents": {
"type": "number"
}
},
"required": [
"month",
"state",
"commission_cents"
],
"additionalProperties": false
}
}
},
"required": [
"partner",
"period",
"site",
"link_sessions",
"inquiries",
"by_via",
"new_customers",
"revenue_cents",
"commission_cents",
"statements"
],
"additionalProperties": false
}Refusals are problems with a code — see Errors.
GET/api/v1/marketing/partnersList partners
Referral partners with their all-time figures: code, name, status (active, paused, ended), since, inquiries (discarded ones excluded), customers (referred Firmen), revenue_cents, commission_open_cents (commission of all statements not yet paid, drafts included) and open_statement (the earliest unpaid statement: month, state, commission_cents; null when none). state: draft (not released), released (released, not paid), paid, credit_note_cancelled (the credit note was cancelled). Without status it lists active and paused partners; status all lists every one. Revenue = net of the issued invoices of the referred Firmen (cancellations subtracted, items excluded from the commission still included). Commission = the lines of the commission statements for invoices dated in the period, drafts included. Link sessions only count visitors who allowed „Statistik“ on a website in consent mode. Statements cannot be created or released here. Payout and tax data of partners are not available to agents.scope leads:read
Query
| status | one of active, paused, ended, allDefault active and paused. |
Response 200
| partners[] | object[] |
| partners[].code | string |
| partners[].name | string |
| partners[].status | string |
| partners[].since | string |
| partners[].inquiries | number |
| partners[].customers | number |
| partners[].revenue_cents | number |
| partners[].commission_open_cents | number |
| partners[].open_statement | object | null |
| partners[].open_statement.month | string |
| partners[].open_statement.state | string |
| partners[].open_statement.commission_cents | number |
| note | string |
Schema
{
"type": "object",
"properties": {
"partners": {
"type": "array",
"items": {
"type": "object",
"properties": {
"code": {
"type": "string"
},
"name": {
"type": "string"
},
"status": {
"type": "string"
},
"since": {
"type": "string"
},
"inquiries": {
"type": "number"
},
"customers": {
"type": "number"
},
"revenue_cents": {
"type": "number"
},
"commission_open_cents": {
"type": "number"
},
"open_statement": {
"anyOf": [
{
"type": "object",
"properties": {
"month": {
"type": "string"
},
"state": {
"type": "string"
},
"commission_cents": {
"type": "number"
}
},
"required": [
"month",
"state",
"commission_cents"
],
"additionalProperties": false
},
{
"type": "null"
}
]
}
},
"required": [
"code",
"name",
"status",
"since",
"inquiries",
"customers",
"revenue_cents",
"commission_open_cents",
"open_statement"
],
"additionalProperties": false
}
},
"note": {
"type": "string"
}
},
"required": [
"partners",
"note"
],
"additionalProperties": false
}Refusals are problems with a code — see Errors.
GET/api/v1/marketing/search-queriesList search queries
Google Search Console figures per search query of one registered website for a period, 50 per page: query, top_page (the page with most clicks for it), clicks, impressions, ctr, position and opportunity ({ kind, reason } or null). The result also names connected, error, data_until, range (the period clipped to the last day with data), median_ctr and totals over every matching query. Google lags 2 to 3 days, so the newest days are missing. position is the average weighted by impressions. Google leaves out anonymised queries, so the totals are below the Search Console UI. „Chance“ rules: rule 1 (kind position) = average position 4 to 15 with at least 100 impressions; rule 2 (kind ctr) = position 5 or better, at least 100 impressions and a CTR below half the website median CTR (the median over the queries at position 5 or better with at least 100 impressions; none with fewer than 3 such queries); rule 1 wins. Filter with page (a path) and opportunities_only; sort by clicks (default), impressions, ctr or position.scope leads:read
Query
| site | stringDomain of the website, like example.com. Optional when exactly one website is registered. |
| period | one of 7d, 28d, 90d, this_month, last_monthPeriod ending today (Europe/Berlin days). Default 28d. Ignored when from and to are given. |
| from | stringFirst day of a free range, YYYY-MM-DD. Needs to as well. |
| to | stringLast day of a free range, YYYY-MM-DD. Needs from as well. |
| page | stringOnly the figures of this page, a path like /preise. |
| opportunities_only | booleanOnly queries marked as „Chance“. |
| sort | one of clicks, impressions, ctr, positionDefault clicks. |
| page_number | integer1-based page of 50 rows. Omit for the first page. |
Response 200
| site | string |
| connected | boolean |
| error | string | null |
| data_until | string | null |
| range | object | null |
| range.from | string |
| range.to | string |
| median_ctr | number | null |
| totals | object |
| totals.queries | number |
| totals.clicks | number |
| totals.impressions | number |
| totals.ctr | number | null |
| totals.position | number | null |
| rows[] | object[] |
| rows[].query | string |
| rows[].top_page | string |
| rows[].clicks | number |
| rows[].impressions | number |
| rows[].ctr | number |
| rows[].position | number |
| rows[].opportunity | object | null |
| rows[].opportunity.kind | one of position, ctr |
| rows[].opportunity.reason | string |
| page | integer |
| total | integer |
| has_more | boolean |
| truncated | boolean |
Schema
{
"type": "object",
"properties": {
"site": {
"type": "string"
},
"connected": {
"type": "boolean"
},
"error": {
"type": [
"string",
"null"
]
},
"data_until": {
"type": [
"string",
"null"
]
},
"range": {
"anyOf": [
{
"type": "object",
"properties": {
"from": {
"type": "string"
},
"to": {
"type": "string"
}
},
"required": [
"from",
"to"
],
"additionalProperties": false
},
{
"type": "null"
}
]
},
"median_ctr": {
"type": [
"number",
"null"
]
},
"totals": {
"type": "object",
"properties": {
"queries": {
"type": "number"
},
"clicks": {
"type": "number"
},
"impressions": {
"type": "number"
},
"ctr": {
"type": [
"number",
"null"
]
},
"position": {
"type": [
"number",
"null"
]
}
},
"required": [
"queries",
"clicks",
"impressions",
"ctr",
"position"
],
"additionalProperties": false
},
"rows": {
"type": "array",
"items": {
"type": "object",
"properties": {
"query": {
"type": "string"
},
"top_page": {
"type": "string"
},
"clicks": {
"type": "number"
},
"impressions": {
"type": "number"
},
"ctr": {
"type": "number"
},
"position": {
"type": "number"
},
"opportunity": {
"anyOf": [
{
"type": "object",
"properties": {
"kind": {
"type": "string",
"enum": [
"position",
"ctr"
]
},
"reason": {
"type": "string"
}
},
"required": [
"kind",
"reason"
],
"additionalProperties": false
},
{
"type": "null"
}
]
}
},
"required": [
"query",
"top_page",
"clicks",
"impressions",
"ctr",
"position",
"opportunity"
],
"additionalProperties": false
}
},
"page": {
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
"total": {
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
"has_more": {
"type": "boolean"
},
"truncated": {
"type": "boolean"
}
},
"required": [
"site",
"connected",
"error",
"data_until",
"range",
"median_ctr",
"totals",
"rows",
"page",
"total",
"has_more",
"truncated"
],
"additionalProperties": false
}Refusals are problems with a code — see Errors.
GET/api/v1/marketing/web-statsGet web stats
Website figures of one registered website for a period: totals (visitors, sessions, pageviews, bounce_rate, inquiries, revenue_cents), the same for the previous period of equal length (previous, with compare), and groups by group_by: channel (default; sessions, share, inquiries, conversion, revenue per channel, unknown last), landing_page (top 50), event (non-pageview events such as tool use or form submits, needs raw data) or day (the daily trend) or captured_by (inquiries, share, quotes, won, revenue_cents per capture source) or campaign (sessions, inquiries, quotes, won, revenue_cents per nxva.base campaign as campaign_id, name, slug; campaign_id null = no campaign). captured_by = how the inquiry was taken (Formular, Assistent …), next to the traffic channel; website inquiries only. Visitors are counted per day: in cookieless mode one person on three days counts 3, in consent mode only visitors who allowed „Statistik“ are counted; in combined mode visitors who allowed „Statistik“ are recognised across days and all others are counted per day without cookies. revenue_cents is the net of issued invoices of the inquiries received in the period (gestellte Rechnungen, netto), so it keeps growing after the period. Inquiries without a matched visit count as „Unbekannt“ (unknown). Figures exclude bots. The result names consent_mode and, in consent mode, consent_rate.scope leads:read
Query
| site | stringDomain of the website, like example.com. Optional when exactly one website is registered. |
| period | one of 7d, 28d, 90d, this_month, last_monthPeriod ending today (Europe/Berlin days). Default 28d. Ignored when from and to are given. |
| from | stringFirst day of a free range, YYYY-MM-DD. Needs to as well. |
| to | stringLast day of a free range, YYYY-MM-DD. Needs from as well. |
| compare | booleanAlso return the previous period of the same length. Default true. |
| group_by | one of channel, landing_page, event, day, captured_by, campaignHow to break the figures down. Default channel. |
Response 200
| site | string |
| period | object |
| period.from | string |
| period.to | string |
| period.previous | object | null |
| period.previous.from | string |
| period.previous.to | string |
| consent_mode | one of cookieless, consent, combined |
| consent_rateoptional | number | null |
| consent_noteoptional | string |
| totals | object |
| totals.visitors | number |
| totals.sessions | number |
| totals.pageviews | number |
| totals.bounce_rate | number | null |
| totals.inquiries | number |
| totals.revenue_cents | number |
| previousoptional | object |
| previous.visitors | number |
| previous.sessions | number |
| previous.pageviews | number |
| previous.bounce_rate | number | null |
| previous.inquiries | number |
| previous.revenue_cents | number |
| revenue_note | string |
| group_by | one of channel, landing_page, event, day, captured_by, campaign |
| groups[] | object[] |
| groups[].channel | string |
| groups[].sessions | number |
| groups[].share | number |
| groups[].inquiries | number |
| groups[].conversion | number | null |
| groups[].revenue_cents | number |
| groups_totaloptional | number |
| limited_fromoptional | string | null |
Schema
{
"type": "object",
"properties": {
"site": {
"type": "string"
},
"period": {
"type": "object",
"properties": {
"from": {
"type": "string"
},
"to": {
"type": "string"
},
"previous": {
"anyOf": [
{
"type": "object",
"properties": {
"from": {
"type": "string"
},
"to": {
"type": "string"
}
},
"required": [
"from",
"to"
],
"additionalProperties": false
},
{
"type": "null"
}
]
}
},
"required": [
"from",
"to",
"previous"
],
"additionalProperties": false
},
"consent_mode": {
"type": "string",
"enum": [
"cookieless",
"consent",
"combined"
]
},
"consent_rate": {
"type": [
"number",
"null"
]
},
"consent_note": {
"type": "string"
},
"totals": {
"type": "object",
"properties": {
"visitors": {
"type": "number"
},
"sessions": {
"type": "number"
},
"pageviews": {
"type": "number"
},
"bounce_rate": {
"type": [
"number",
"null"
]
},
"inquiries": {
"type": "number"
},
"revenue_cents": {
"type": "number"
}
},
"required": [
"visitors",
"sessions",
"pageviews",
"bounce_rate",
"inquiries",
"revenue_cents"
],
"additionalProperties": false
},
"previous": {
"type": "object",
"properties": {
"visitors": {
"type": "number"
},
"sessions": {
"type": "number"
},
"pageviews": {
"type": "number"
},
"bounce_rate": {
"type": [
"number",
"null"
]
},
"inquiries": {
"type": "number"
},
"revenue_cents": {
"type": "number"
}
},
"required": [
"visitors",
"sessions",
"pageviews",
"bounce_rate",
"inquiries",
"revenue_cents"
],
"additionalProperties": false
},
"revenue_note": {
"type": "string"
},
"group_by": {
"type": "string",
"enum": [
"channel",
"landing_page",
"event",
"day",
"captured_by",
"campaign"
]
},
"groups": {
"type": "array",
"items": {
"anyOf": [
{
"type": "object",
"properties": {
"channel": {
"type": "string"
},
"sessions": {
"type": "number"
},
"share": {
"type": "number"
},
"inquiries": {
"type": "number"
},
"conversion": {
"type": [
"number",
"null"
]
},
"revenue_cents": {
"type": "number"
}
},
"required": [
"channel",
"sessions",
"share",
"inquiries",
"conversion",
"revenue_cents"
],
"additionalProperties": false
},
{
"type": "object",
"properties": {
"day": {
"type": "string"
},
"sessions": {
"type": "number"
},
"previous_sessions": {
"type": [
"number",
"null"
]
},
"inquiries": {
"type": "number"
}
},
"required": [
"day",
"sessions",
"previous_sessions",
"inquiries"
],
"additionalProperties": false
},
{
"type": "object",
"properties": {
"captured_by": {
"type": "string"
},
"label": {
"type": "string"
},
"inquiries": {
"type": "number"
},
"share": {
"type": "number"
},
"quotes": {
"type": "number"
},
"won": {
"type": "number"
},
"revenue_cents": {
"type": "number"
}
},
"required": [
"captured_by",
"label",
"inquiries",
"share",
"quotes",
"won",
"revenue_cents"
],
"additionalProperties": false
},
{
"type": "object",
"properties": {
"campaign_id": {
"type": [
"string",
"null"
]
},
"name": {
"type": [
"string",
"null"
]
},
"slug": {
"type": [
"string",
"null"
]
},
"sessions": {
"type": "number"
},
"inquiries": {
"type": "number"
},
"quotes": {
"type": "number"
},
"won": {
"type": "number"
},
"revenue_cents": {
"type": "number"
}
},
"required": [
"campaign_id",
"name",
"slug",
"sessions",
"inquiries",
"quotes",
"won",
"revenue_cents"
],
"additionalProperties": false
},
{
"type": "object",
"properties": {
"path": {
"type": "string"
},
"sessions": {
"type": "number"
},
"bounce_rate": {
"type": [
"number",
"null"
]
},
"inquiries": {
"type": "number"
},
"conversion": {
"type": [
"number",
"null"
]
},
"quotes": {
"type": "number"
},
"won": {
"type": "number"
},
"revenue_cents": {
"type": "number"
}
},
"required": [
"path",
"sessions",
"bounce_rate",
"inquiries",
"conversion",
"quotes",
"won",
"revenue_cents"
],
"additionalProperties": false
},
{
"type": "object",
"properties": {
"type": {
"type": "string"
},
"name": {
"type": [
"string",
"null"
]
},
"count": {
"type": "number"
},
"sessions": {
"type": "number"
},
"with_inquiry": {
"type": "number"
},
"conversion": {
"type": [
"number",
"null"
]
}
},
"required": [
"type",
"name",
"count",
"sessions",
"with_inquiry",
"conversion"
],
"additionalProperties": false
}
]
}
},
"groups_total": {
"type": "number"
},
"limited_from": {
"type": [
"string",
"null"
]
}
},
"required": [
"site",
"period",
"consent_mode",
"totals",
"revenue_note",
"group_by",
"groups"
],
"additionalProperties": false
}Refusals are problems with a code — see Errors.