Canvas-Datenreihen-Analytics exportieren
/canvas/data_series
Verwenden Sie diesen Endpunkt, um Zeitreihendaten für ein Canvas zu exportieren.

Die Zählwerte dieses Endpunkts stimmen nicht immer exakt mit den Canvas-Analytics im Dashboard oder mit Aggregaten überein, die Sie aus Currents erstellen. Dashboard-Metriken und API-Zeitreihen verwenden andere Aggregationsfenster und Definitionen als unverarbeitete Currents-Ereignisse. Allgemeine Hinweise zum Abgleich finden Sie in den Currents-FAQ.
Voraussetzungen
Um diesen Endpunkt zu verwenden, benötigen Sie einen API-Schlüssel mit der Berechtigung canvas.data_series.
Rate-Limit
Wir wenden auf diesen Endpunkt das standardmäßige Braze-Rate-Limit von 250.000 Anfragen pro Stunde an, wie in API-Rate-Limits dokumentiert.
Anfrageparameter
| Parameter | Erforderlich | Datentyp | Beschreibung |
|---|---|---|---|
canvas_id |
Erforderlich | String | Siehe Canvas-API-Bezeichner. |
ending_at |
Erforderlich | Datetime (ISO-8601-String) |
Datum, an dem der Datenexport enden soll. Standardmäßig wird der Zeitpunkt der Anfrage verwendet. |
starting_at |
Optional* | Datetime (ISO-8601-String) |
Datum, an dem der Datenexport beginnen soll. * Entweder length oder starting_at ist erforderlich. |
length |
Optional* | String | Maximale Anzahl der Tage vor ending_at, die in der zurückgegebenen Reihe enthalten sein sollen. Muss zwischen 1 und 14 (einschließlich) liegen. * Entweder length oder starting_at ist erforderlich. |
include_variant_breakdown |
Optional | Boolescher Wert | Ob Varianten-Statistiken einbezogen werden sollen oder nicht (Standard ist false). |
include_step_breakdown |
Optional | Boolescher Wert | Ob Schritt-Statistiken einbezogen werden sollen oder nicht (Standard ist false). |
include_deleted_step_data |
Optional | Boolescher Wert | Ob Schritt-Statistiken für gelöschte Schritte einbezogen werden sollen oder nicht (Standard ist false). |
Beispielanfrage
1
2
curl --location -g --request GET 'https://rest.iad-01.braze.com/canvas/data_series?canvas_id={{canvas_id}}&ending_at=2018-05-30T23:59:59-5:00&starting_at=2018-05-28T23:59:59-5:00&include_variant_breakdown=true&include_step_breakdown=true&include_deleted_step_data=true' \
--header 'Authorization: Bearer YOUR-REST-API-KEY'
Antwort
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
{
"data": {
"name": (string) the Canvas name,
"stats": [
{
"time": (string) the date as ISO 8601 date,
"total_stats": {
"revenue": (float) the number of dollars of revenue (USD),
"conversions": (int) the number of conversions,
"conversions_by_entry_time": (int) the number of conversions for the conversion event by entry time,
"entries": (int) the number of entries
},
"variant_stats": (optional) {
"00000000-0000-0000-0000-0000000000000": (string) the API identifier for the variant {
"name": (string) the name of variant,
"revenue": (float) the number of dollars of revenue (USD),
"conversions": (int) the number of conversions,
"conversions_by_entry_time": (int) the number of conversions for the conversion event by entry time,
"entries": (int) the number of entries
},
... (more variants)
},
"step_stats": (optional) {
"00000000-0000-0000-0000-0000000000000": (string) the API identifier for the step {
"name": (string) the name of step,
"revenue": (float) the number of dollars of revenue (USD),
"conversions": (int) the number of conversions,
"conversions_by_entry_time": (int) the number of conversions for the conversion event by entry time,
"messages": {
"email": [
{
"sent": (int) the number of sends,
"opens": (int) the number of opens,
"unique_opens": (int) the number of unique opens,
"clicks": (int) the number of clicks
... (more stats)
}
],
"sms" : [
{
"sent": (int) the number of sends,
"sent_to_carrier" : (int) the number of messages sent to the carrier,
"delivered": (int)the number of delivered messages,
"rejected": (int) the number of rejected messages,
"delivery_failed": (int) the number of failed deliveries,
"clicks": (int) the number of clicks on shortened links,
"opt_out" : (int) the number of opt outs,
"help" : (int) the number of help messages received
}
],
... (more channels)
}
},
... (more steps)
}
},
... (more stats by time)
]
},
"message": (required, string) the status of the export, returns 'success' when completed without errors
}

Hilfe zu CSV- und API-Exporten finden Sie unter Fehlerbehebung bei Exporten.