Create an import
curl --request POST \
--url https://api.buzzkit.dev/v1/imports \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"rows": [
{
"externalId": "<string>",
"token": "<string>",
"address": "jsmith@example.com",
"attributes": {},
"timezone": "<string>",
"language": "<string>",
"country": "<string>",
"device": {
"appVersion": "<string>",
"osVersion": "<string>",
"model": "<string>"
},
"lastSeenAt": "2023-11-07T05:31:56Z",
"enabled": true,
"subscribe": {
"email": true
}
}
]
}
'import requests
url = "https://api.buzzkit.dev/v1/imports"
payload = { "rows": [
{
"externalId": "<string>",
"token": "<string>",
"address": "jsmith@example.com",
"attributes": {},
"timezone": "<string>",
"language": "<string>",
"country": "<string>",
"device": {
"appVersion": "<string>",
"osVersion": "<string>",
"model": "<string>"
},
"lastSeenAt": "2023-11-07T05:31:56Z",
"enabled": True,
"subscribe": { "email": True }
}
] }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
rows: [
{
externalId: '<string>',
token: '<string>',
address: 'jsmith@example.com',
attributes: {},
timezone: '<string>',
language: '<string>',
country: '<string>',
device: {appVersion: '<string>', osVersion: '<string>', model: '<string>'},
lastSeenAt: '2023-11-07T05:31:56Z',
enabled: true,
subscribe: {email: true}
}
]
})
};
fetch('https://api.buzzkit.dev/v1/imports', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.buzzkit.dev/v1/imports",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'rows' => [
[
'externalId' => '<string>',
'token' => '<string>',
'address' => 'jsmith@example.com',
'attributes' => [
],
'timezone' => '<string>',
'language' => '<string>',
'country' => '<string>',
'device' => [
'appVersion' => '<string>',
'osVersion' => '<string>',
'model' => '<string>'
],
'lastSeenAt' => '2023-11-07T05:31:56Z',
'enabled' => true,
'subscribe' => [
'email' => true
]
]
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.buzzkit.dev/v1/imports"
payload := strings.NewReader("{\n \"rows\": [\n {\n \"externalId\": \"<string>\",\n \"token\": \"<string>\",\n \"address\": \"jsmith@example.com\",\n \"attributes\": {},\n \"timezone\": \"<string>\",\n \"language\": \"<string>\",\n \"country\": \"<string>\",\n \"device\": {\n \"appVersion\": \"<string>\",\n \"osVersion\": \"<string>\",\n \"model\": \"<string>\"\n },\n \"lastSeenAt\": \"2023-11-07T05:31:56Z\",\n \"enabled\": true,\n \"subscribe\": {\n \"email\": true\n }\n }\n ]\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.buzzkit.dev/v1/imports")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"rows\": [\n {\n \"externalId\": \"<string>\",\n \"token\": \"<string>\",\n \"address\": \"jsmith@example.com\",\n \"attributes\": {},\n \"timezone\": \"<string>\",\n \"language\": \"<string>\",\n \"country\": \"<string>\",\n \"device\": {\n \"appVersion\": \"<string>\",\n \"osVersion\": \"<string>\",\n \"model\": \"<string>\"\n },\n \"lastSeenAt\": \"2023-11-07T05:31:56Z\",\n \"enabled\": true,\n \"subscribe\": {\n \"email\": true\n }\n }\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.buzzkit.dev/v1/imports")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"rows\": [\n {\n \"externalId\": \"<string>\",\n \"token\": \"<string>\",\n \"address\": \"jsmith@example.com\",\n \"attributes\": {},\n \"timezone\": \"<string>\",\n \"language\": \"<string>\",\n \"country\": \"<string>\",\n \"device\": {\n \"appVersion\": \"<string>\",\n \"osVersion\": \"<string>\",\n \"model\": \"<string>\"\n },\n \"lastSeenAt\": \"2023-11-07T05:31:56Z\",\n \"enabled\": true,\n \"subscribe\": {\n \"email\": true\n }\n }\n ]\n}"
response = http.request(request)
puts response.read_body{
"success": true,
"data": {},
"error": {
"code": "<string>",
"message": "<string>",
"param": "<string>",
"details": {}
},
"metadata": {
"timestamp": "<string>",
"requestId": "<string>"
}
}{
"success": false,
"data": {},
"error": {
"code": "invalid_api_key",
"message": "<string>",
"param": "<string>",
"details": [
{
"param": "<string>",
"message": "<string>"
}
]
},
"metadata": {
"timestamp": "2023-11-07T05:31:56Z",
"requestId": "<string>"
}
}{
"success": false,
"data": {},
"error": {
"code": "invalid_api_key",
"message": "<string>",
"param": "<string>",
"details": [
{
"param": "<string>",
"message": "<string>"
}
]
},
"metadata": {
"timestamp": "2023-11-07T05:31:56Z",
"requestId": "<string>"
}
}{
"success": false,
"data": {},
"error": {
"code": "invalid_api_key",
"message": "<string>",
"param": "<string>",
"details": [
{
"param": "<string>",
"message": "<string>"
}
]
},
"metadata": {
"timestamp": "2023-11-07T05:31:56Z",
"requestId": "<string>"
}
}{
"success": false,
"data": {},
"error": {
"code": "invalid_api_key",
"message": "<string>",
"param": "<string>",
"details": [
{
"param": "<string>",
"message": "<string>"
}
]
},
"metadata": {
"timestamp": "2023-11-07T05:31:56Z",
"requestId": "<string>"
}
}{
"success": false,
"data": {},
"error": {
"code": "invalid_api_key",
"message": "<string>",
"param": "<string>",
"details": [
{
"param": "<string>",
"message": "<string>"
}
]
},
"metadata": {
"timestamp": "2023-11-07T05:31:56Z",
"requestId": "<string>"
}
}Subscribers
Create an import
POST
/
v1
/
imports
Create an import
curl --request POST \
--url https://api.buzzkit.dev/v1/imports \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"rows": [
{
"externalId": "<string>",
"token": "<string>",
"address": "jsmith@example.com",
"attributes": {},
"timezone": "<string>",
"language": "<string>",
"country": "<string>",
"device": {
"appVersion": "<string>",
"osVersion": "<string>",
"model": "<string>"
},
"lastSeenAt": "2023-11-07T05:31:56Z",
"enabled": true,
"subscribe": {
"email": true
}
}
]
}
'import requests
url = "https://api.buzzkit.dev/v1/imports"
payload = { "rows": [
{
"externalId": "<string>",
"token": "<string>",
"address": "jsmith@example.com",
"attributes": {},
"timezone": "<string>",
"language": "<string>",
"country": "<string>",
"device": {
"appVersion": "<string>",
"osVersion": "<string>",
"model": "<string>"
},
"lastSeenAt": "2023-11-07T05:31:56Z",
"enabled": True,
"subscribe": { "email": True }
}
] }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
rows: [
{
externalId: '<string>',
token: '<string>',
address: 'jsmith@example.com',
attributes: {},
timezone: '<string>',
language: '<string>',
country: '<string>',
device: {appVersion: '<string>', osVersion: '<string>', model: '<string>'},
lastSeenAt: '2023-11-07T05:31:56Z',
enabled: true,
subscribe: {email: true}
}
]
})
};
fetch('https://api.buzzkit.dev/v1/imports', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.buzzkit.dev/v1/imports",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'rows' => [
[
'externalId' => '<string>',
'token' => '<string>',
'address' => 'jsmith@example.com',
'attributes' => [
],
'timezone' => '<string>',
'language' => '<string>',
'country' => '<string>',
'device' => [
'appVersion' => '<string>',
'osVersion' => '<string>',
'model' => '<string>'
],
'lastSeenAt' => '2023-11-07T05:31:56Z',
'enabled' => true,
'subscribe' => [
'email' => true
]
]
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.buzzkit.dev/v1/imports"
payload := strings.NewReader("{\n \"rows\": [\n {\n \"externalId\": \"<string>\",\n \"token\": \"<string>\",\n \"address\": \"jsmith@example.com\",\n \"attributes\": {},\n \"timezone\": \"<string>\",\n \"language\": \"<string>\",\n \"country\": \"<string>\",\n \"device\": {\n \"appVersion\": \"<string>\",\n \"osVersion\": \"<string>\",\n \"model\": \"<string>\"\n },\n \"lastSeenAt\": \"2023-11-07T05:31:56Z\",\n \"enabled\": true,\n \"subscribe\": {\n \"email\": true\n }\n }\n ]\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.buzzkit.dev/v1/imports")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"rows\": [\n {\n \"externalId\": \"<string>\",\n \"token\": \"<string>\",\n \"address\": \"jsmith@example.com\",\n \"attributes\": {},\n \"timezone\": \"<string>\",\n \"language\": \"<string>\",\n \"country\": \"<string>\",\n \"device\": {\n \"appVersion\": \"<string>\",\n \"osVersion\": \"<string>\",\n \"model\": \"<string>\"\n },\n \"lastSeenAt\": \"2023-11-07T05:31:56Z\",\n \"enabled\": true,\n \"subscribe\": {\n \"email\": true\n }\n }\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.buzzkit.dev/v1/imports")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"rows\": [\n {\n \"externalId\": \"<string>\",\n \"token\": \"<string>\",\n \"address\": \"jsmith@example.com\",\n \"attributes\": {},\n \"timezone\": \"<string>\",\n \"language\": \"<string>\",\n \"country\": \"<string>\",\n \"device\": {\n \"appVersion\": \"<string>\",\n \"osVersion\": \"<string>\",\n \"model\": \"<string>\"\n },\n \"lastSeenAt\": \"2023-11-07T05:31:56Z\",\n \"enabled\": true,\n \"subscribe\": {\n \"email\": true\n }\n }\n ]\n}"
response = http.request(request)
puts response.read_body{
"success": true,
"data": {},
"error": {
"code": "<string>",
"message": "<string>",
"param": "<string>",
"details": {}
},
"metadata": {
"timestamp": "<string>",
"requestId": "<string>"
}
}{
"success": false,
"data": {},
"error": {
"code": "invalid_api_key",
"message": "<string>",
"param": "<string>",
"details": [
{
"param": "<string>",
"message": "<string>"
}
]
},
"metadata": {
"timestamp": "2023-11-07T05:31:56Z",
"requestId": "<string>"
}
}{
"success": false,
"data": {},
"error": {
"code": "invalid_api_key",
"message": "<string>",
"param": "<string>",
"details": [
{
"param": "<string>",
"message": "<string>"
}
]
},
"metadata": {
"timestamp": "2023-11-07T05:31:56Z",
"requestId": "<string>"
}
}{
"success": false,
"data": {},
"error": {
"code": "invalid_api_key",
"message": "<string>",
"param": "<string>",
"details": [
{
"param": "<string>",
"message": "<string>"
}
]
},
"metadata": {
"timestamp": "2023-11-07T05:31:56Z",
"requestId": "<string>"
}
}{
"success": false,
"data": {},
"error": {
"code": "invalid_api_key",
"message": "<string>",
"param": "<string>",
"details": [
{
"param": "<string>",
"message": "<string>"
}
]
},
"metadata": {
"timestamp": "2023-11-07T05:31:56Z",
"requestId": "<string>"
}
}{
"success": false,
"data": {},
"error": {
"code": "invalid_api_key",
"message": "<string>",
"param": "<string>",
"details": [
{
"param": "<string>",
"message": "<string>"
}
]
},
"metadata": {
"timestamp": "2023-11-07T05:31:56Z",
"requestId": "<string>"
}
}Authorizations
An API key from the dashboard. The scopes listed on each operation are the resource:action grants a key needs (messages:send, subscribers:read, topics:*, *); account:* scopes and key management are session-only. Workspace keys (bk_ws_) are what a backend uses: they resolve to the default tenant on their own, so an integration that does not use tenants sends no extra header, and add buzzkit-tenant only to address a different tenant. Tenant keys (bk_tn_) are locked to one tenant and need no header either; client keys (bk_pk_) ship inside an app and only work on /v1/client/*.
Body
application/jsonapplication/x-www-form-urlencodedmultipart/form-data
Required array length:
1 - 1000 elementsShow child attributes
Show child attributes