시스템에서 요청을 처리하려면 API 키가 필요합니다. 사용자가 가입하면 해당 사용자에 대한 API 키가 자동으로 생성됩니다. API 키는 각 요청과 함께 전송되어야 합니다(아래 전체 예시 참조). API 키가 전송되지 않거나 만료된 경우 오류가 발생합니다. 남용을 방지하려면 API 키를 비밀로 유지하시기 바랍니다.
API 시스템으로 인증하려면 각 요청마다 API 키를 인증 토큰으로 보내야 합니다. 아래에서 샘플 코드를 볼 수 있습니다.
curl --location --request POST 'https://zed.kr/api/account' \
--header 'Authorization: Bearer YOURAPIKEY' \
--header 'Content-Type: application/json' \
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => "https://zed.kr/api/account",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_MAXREDIRS => 2,
CURLOPT_TIMEOUT => 10,
CURLOPT_FOLLOWLOCATION => true,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer YOURAPIKEY",
"Content-Type: application/json",
],
));
$response = curl_exec($curl);
var request = require('request');
var options = {
'method': 'POST',
'url': 'https://zed.kr/api/account',
'headers': {
'Authorization': 'Bearer YOURAPIKEY',
'Content-Type': 'application/json'
},
body: ''
};
request(options, function (error, response) {
if (error) throw new Error(error);
console.log(response.body);
});
우리 API에는 안정성을 극대화하기 위해 요청 급증을 방지하는 속도 제한기가 있습니다. 우리의 비율 제한은 현재 1분당 30개의 요청으로 제한됩니다. 가입하신 요금제에 따라 요금이 변경될 수 있으니 참고하세요.
여러 헤더가 응답과 함께 전송되며 이를 검사하여 요청에 대한 다양한 정보를 확인할 수 있습니다.
X-RateLimit-Limit: 30
X-RateLimit-Remaining: 29
X-RateLimit-Reset: TIMESTAMP
모든 API 응답은 기본적으로 JSON 형식으로 반환됩니다. 이를 사용 가능한 데이터로 변환하려면 언어에 따라 적절한 기능을 사용해야 합니다. PHP에서는 json_decode() 함수를 사용하여 데이터를 객체(기본값) 또는 배열(두 번째 매개변수를 true로 설정)로 변환할 수 있습니다. 오류 키는 오류가 발생했는지 여부에 대한 정보를 제공하므로 확인하는 것이 매우 중요합니다. 헤더 코드도 확인할 수 있습니다.
{
"error": 1,
"message": "An error occurred"
}
https://zed.kr/api/overlay?limit=2&page=1
API를 통해 CTA 오버레이를 얻으려면 이 엔드포인트를 사용할 수 있습니다. 데이터를 필터링할 수도 있습니다(자세한 내용은 표 참조).
매개변수 | 설명 |
---|---|
limit | (선택) 페이지별 데이터 결과 |
page | (선택) 현재 페이지 요청 |
curl --location --request GET 'https://zed.kr/api/overlay?limit=2&page=1' \
--header 'Authorization: Bearer YOURAPIKEY' \
--header 'Content-Type: application/json' \
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => "https://zed.kr/api/overlay?limit=2&page=1",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_MAXREDIRS => 2,
CURLOPT_TIMEOUT => 10,
CURLOPT_FOLLOWLOCATION => true,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer YOURAPIKEY",
"Content-Type: application/json",
],
));
$response = curl_exec($curl);
curl_close($curl);
echo $response;
var request = require('request');
var options = {
'method': 'GET',
'url': 'https://zed.kr/api/overlay?limit=2&page=1',
'headers': {
'Authorization': 'Bearer YOURAPIKEY',
'Content-Type': 'application/json'
},
};
request(options, function (error, response) {
if (error) throw new Error(error);
console.log(response.body);
});
{
"error": "0",
"data": {
"result": 2,
"perpage": 2,
"currentpage": 1,
"nextpage": 1,
"maxpage": 1,
"cta": [
{
"id": 1,
"type": "message",
"name": "Product 1 Promo",
"date": "2020-11-10 18:00:00"
},
{
"id": 2,
"type": "contact",
"name": "Contact Page",
"date": "2020-11-10 18:10:00"
}
]
}
}
https://zed.kr/api/qr?limit=2&page=1
API를 통해 QR 코드를 얻으려면 이 엔드포인트를 사용할 수 있습니다. 데이터를 필터링할 수도 있습니다(자세한 내용은 표 참조).
매개변수 | 설명 |
---|---|
limit | (선택) 페이지별 데이터 결과 |
page | (선택) 현재 페이지 요청 |
curl --location --request GET 'https://zed.kr/api/qr?limit=2&page=1' \
--header 'Authorization: Bearer YOURAPIKEY' \
--header 'Content-Type: application/json' \
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => "https://zed.kr/api/qr?limit=2&page=1",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_MAXREDIRS => 2,
CURLOPT_TIMEOUT => 10,
CURLOPT_FOLLOWLOCATION => true,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer YOURAPIKEY",
"Content-Type: application/json",
],
));
$response = curl_exec($curl);
curl_close($curl);
echo $response;
var request = require('request');
var options = {
'method': 'GET',
'url': 'https://zed.kr/api/qr?limit=2&page=1',
'headers': {
'Authorization': 'Bearer YOURAPIKEY',
'Content-Type': 'application/json'
},
};
request(options, function (error, response) {
if (error) throw new Error(error);
console.log(response.body);
});
{
"error": "0",
"data": {
"result": 2,
"perpage": 2,
"currentpage": 1,
"nextpage": 1,
"maxpage": 1,
"qrs": [
{
"id": 2,
"link": "https:\/\/zed.kr\/qr\/a2d5e",
"scans": 0,
"name": "Google",
"date": "2020-11-10 18:01:43"
},
{
"id": 1,
"link": "https:\/\/zed.kr\/qr\/b9edfe",
"scans": 5,
"name": "Google Canada",
"date": "2020-11-10 18:00:25"
}
]
}
}
https://zed.kr/api/qr/:id
API를 통해 단일 QR 코드에 대한 세부 정보를 얻으려면 이 엔드포인트를 사용할 수 있습니다.
curl --location --request GET 'https://zed.kr/api/qr/:id' \
--header 'Authorization: Bearer YOURAPIKEY' \
--header 'Content-Type: application/json' \
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => "https://zed.kr/api/qr/:id",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_MAXREDIRS => 2,
CURLOPT_TIMEOUT => 10,
CURLOPT_FOLLOWLOCATION => true,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer YOURAPIKEY",
"Content-Type: application/json",
],
));
$response = curl_exec($curl);
curl_close($curl);
echo $response;
var request = require('request');
var options = {
'method': 'GET',
'url': 'https://zed.kr/api/qr/:id',
'headers': {
'Authorization': 'Bearer YOURAPIKEY',
'Content-Type': 'application/json'
},
};
request(options, function (error, response) {
if (error) throw new Error(error);
console.log(response.body);
});
{
"error": 0,
"details": {
"id": 1,
"link": "https:\/\/zed.kr\/qr\/b9edfe",
"scans": 5,
"name": "Google Canada",
"date": "2020-11-10 18:00:25"
},
"data": {
"clicks": 1,
"uniqueClicks": 1,
"topCountries": {
"Unknown": "1"
},
"topReferrers": {
"Direct, email and other": "1"
},
"topBrowsers": {
"Chrome": "1"
},
"topOs": {
"Windows 10": "1"
},
"socialCount": {
"facebook": 0,
"twitter": 0,
"instagram": 0
}
}
}
https://zed.kr/api/qr/add
QR 코드를 생성하려면 POST 요청을 통해 JSON 형식의 유효한 데이터를 보내야 합니다. 데이터는 아래와 같이 요청의 원시 본문으로 전송되어야 합니다. 아래 예는 보낼 수 있는 모든 매개변수를 보여 주지만 모두 보낼 필요는 없습니다(자세한 내용은 표 참조).
매개변수 | 설명 |
---|---|
type | (필수) text | vcard | link | email | phone | sms | wifi |
data | (필수) QR코드 내부에 삽입할 데이터입니다. 데이터는 유형에 따라 문자열 또는 배열이 될 수 있습니다. |
background | (선택) RGB 색상 예: RGB(255,255,255) |
foreground | (선택) RGB 색상 예: RGB(0,0,0) |
logo | (선택) png 또는 jpg 로고 경로 |
curl --location --request POST 'https://zed.kr/api/qr/add' \
--header 'Authorization: Bearer YOURAPIKEY' \
--header 'Content-Type: application/json' \
--data-raw '{
"type": "link",
"data": "https:\/\/google.com",
"background": "rgb(255,255,255)",
"foreground": "rgb(0,0,0)",
"logo": "https:\/\/site.com\/logo.png"
}'
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => "https://zed.kr/api/qr/add",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_MAXREDIRS => 2,
CURLOPT_TIMEOUT => 10,
CURLOPT_FOLLOWLOCATION => true,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer YOURAPIKEY",
"Content-Type: application/json",
],
CURLOPT_POSTFIELDS =>
'{
"type": "link",
"data": "https:\/\/google.com",
"background": "rgb(255,255,255)",
"foreground": "rgb(0,0,0)",
"logo": "https:\/\/site.com\/logo.png"
}',
));
$response = curl_exec($curl);
curl_close($curl);
echo $response;
var request = require('request');
var options = {
'method': 'POST',
'url': 'https://zed.kr/api/qr/add',
'headers': {
'Authorization': 'Bearer YOURAPIKEY',
'Content-Type': 'application/json'
},
body: JSON.stringify({
"type": "link",
"data": "https:\/\/google.com",
"background": "rgb(255,255,255)",
"foreground": "rgb(0,0,0)",
"logo": "https:\/\/site.com\/logo.png"
}),
};
request(options, function (error, response) {
if (error) throw new Error(error);
console.log(response.body);
});
{
"error": 0,
"id": 3,
"link": "https:\/\/zed.kr\/qr\/a58f79"
}
https://zed.kr/api/qr/:id/update
QR 코드를 업데이트하려면 PUT 요청을 통해 JSON으로 유효한 데이터를 보내야 합니다. 데이터는 아래와 같이 요청의 원시 본문으로 전송되어야 합니다. 아래 예는 보낼 수 있는 모든 매개변수를 보여 주지만 모두 보낼 필요는 없습니다(자세한 내용은 표 참조).
매개변수 | 설명 |
---|---|
data | (필수) QR코드 내부에 삽입할 데이터입니다. 데이터는 유형에 따라 문자열 또는 배열이 될 수 있습니다. |
background | (선택) RGB 색상 예: RGB(255,255,255) |
foreground | (선택) RGB 색상 예: RGB(0,0,0) |
logo | (선택) png 또는 jpg 로고 경로 |
curl --location --request PUT 'https://zed.kr/api/qr/:id/update' \
--header 'Authorization: Bearer YOURAPIKEY' \
--header 'Content-Type: application/json' \
--data-raw '{
"type": "link",
"data": "https:\/\/google.com",
"background": "rgb(255,255,255)",
"foreground": "rgb(0,0,0)",
"logo": "https:\/\/site.com\/logo.png"
}'
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => "https://zed.kr/api/qr/:id/update",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_MAXREDIRS => 2,
CURLOPT_TIMEOUT => 10,
CURLOPT_FOLLOWLOCATION => true,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer YOURAPIKEY",
"Content-Type: application/json",
],
CURLOPT_POSTFIELDS =>
'{
"type": "link",
"data": "https:\/\/google.com",
"background": "rgb(255,255,255)",
"foreground": "rgb(0,0,0)",
"logo": "https:\/\/site.com\/logo.png"
}',
));
$response = curl_exec($curl);
curl_close($curl);
echo $response;
var request = require('request');
var options = {
'method': 'PUT',
'url': 'https://zed.kr/api/qr/:id/update',
'headers': {
'Authorization': 'Bearer YOURAPIKEY',
'Content-Type': 'application/json'
},
body: JSON.stringify({
"type": "link",
"data": "https:\/\/google.com",
"background": "rgb(255,255,255)",
"foreground": "rgb(0,0,0)",
"logo": "https:\/\/site.com\/logo.png"
}),
};
request(options, function (error, response) {
if (error) throw new Error(error);
console.log(response.body);
});
{
"error": 0,
"message": "QR has been updated successfully."
}
https://zed.kr/api/qr/:id/delete
QR 코드를 삭제하려면 DELETE 요청을 보내야 합니다.
curl --location --request DELETE 'https://zed.kr/api/qr/:id/delete' \
--header 'Authorization: Bearer YOURAPIKEY' \
--header 'Content-Type: application/json' \
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => "https://zed.kr/api/qr/:id/delete",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_MAXREDIRS => 2,
CURLOPT_TIMEOUT => 10,
CURLOPT_FOLLOWLOCATION => true,
CURLOPT_CUSTOMREQUEST => "DELETE",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer YOURAPIKEY",
"Content-Type: application/json",
],
));
$response = curl_exec($curl);
curl_close($curl);
echo $response;
var request = require('request');
var options = {
'method': 'DELETE',
'url': 'https://zed.kr/api/qr/:id/delete',
'headers': {
'Authorization': 'Bearer YOURAPIKEY',
'Content-Type': 'application/json'
},
};
request(options, function (error, response) {
if (error) throw new Error(error);
console.log(response.body);
});
{
"error": 0,
"message": "QR Code has been deleted successfully."
}
https://zed.kr/api/account
계정에 대한 정보를 얻으려면 이 엔드포인트에 요청을 보내면 계정에 대한 데이터가 반환됩니다.
curl --location --request GET 'https://zed.kr/api/account' \
--header 'Authorization: Bearer YOURAPIKEY' \
--header 'Content-Type: application/json' \
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => "https://zed.kr/api/account",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_MAXREDIRS => 2,
CURLOPT_TIMEOUT => 10,
CURLOPT_FOLLOWLOCATION => true,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer YOURAPIKEY",
"Content-Type: application/json",
],
));
$response = curl_exec($curl);
curl_close($curl);
echo $response;
var request = require('request');
var options = {
'method': 'GET',
'url': 'https://zed.kr/api/account',
'headers': {
'Authorization': 'Bearer YOURAPIKEY',
'Content-Type': 'application/json'
},
};
request(options, function (error, response) {
if (error) throw new Error(error);
console.log(response.body);
});
{
"error": 0,
"data": {
"id": 1,
"email": "[email protected]",
"username": "sampleuser",
"avatar": "https:\/\/domain.com\/content\/avatar.png",
"status": "pro",
"expires": "2022-11-15 15:00:00",
"registered": "2020-11-10 18:01:43"
}
}
https://zed.kr/api/account/update
계정의 정보를 업데이트하려면 이 엔드포인트에 요청을 보내면 계정의 데이터가 업데이트됩니다.
curl --location --request PUT 'https://zed.kr/api/account/update' \
--header 'Authorization: Bearer YOURAPIKEY' \
--header 'Content-Type: application/json' \
--data-raw '{
"email": "[email protected]",
"password": "newpassword"
}'
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => "https://zed.kr/api/account/update",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_MAXREDIRS => 2,
CURLOPT_TIMEOUT => 10,
CURLOPT_FOLLOWLOCATION => true,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer YOURAPIKEY",
"Content-Type: application/json",
],
CURLOPT_POSTFIELDS =>
'{
"email": "[email protected]",
"password": "newpassword"
}',
));
$response = curl_exec($curl);
curl_close($curl);
echo $response;
var request = require('request');
var options = {
'method': 'PUT',
'url': 'https://zed.kr/api/account/update',
'headers': {
'Authorization': 'Bearer YOURAPIKEY',
'Content-Type': 'application/json'
},
body: JSON.stringify({
"email": "[email protected]",
"password": "newpassword"
}),
};
request(options, function (error, response) {
if (error) throw new Error(error);
console.log(response.body);
});
{
"error": 0,
"message": "Account has been successfully updated."
}
https://zed.kr/api/urls?limit=2&page=1&order=date
API를 통해 링크를 얻으려면 이 엔드포인트를 사용할 수 있습니다. 데이터를 필터링할 수도 있습니다(자세한 내용은 표 참조).
매개변수 | 설명 |
---|---|
limit | (선택) 페이지별 데이터 결과 |
page | (선택) 현재 페이지 요청 |
order | (선택) 날짜별 데이터 정렬 또는 클릭 |
short | (선택) 1개의 단축URL을 정보를 얻을 수 있습니다. 이 옵션은 다른 링크는 무시되고 일치한 단일 링크 응답이 반환됩니다. (예: &short=zed.kr/google) |
curl --location --request GET 'https://zed.kr/api/urls?limit=2&page=1&order=date' \
--header 'Authorization: Bearer YOURAPIKEY' \
--header 'Content-Type: application/json' \
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => "https://zed.kr/api/urls?limit=2&page=1&order=date",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_MAXREDIRS => 2,
CURLOPT_TIMEOUT => 10,
CURLOPT_FOLLOWLOCATION => true,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer YOURAPIKEY",
"Content-Type: application/json",
],
));
$response = curl_exec($curl);
curl_close($curl);
echo $response;
var request = require('request');
var options = {
'method': 'GET',
'url': 'https://zed.kr/api/urls?limit=2&page=1&order=date',
'headers': {
'Authorization': 'Bearer YOURAPIKEY',
'Content-Type': 'application/json'
},
};
request(options, function (error, response) {
if (error) throw new Error(error);
console.log(response.body);
});
{
"error": "0",
"data": {
"result": 2,
"perpage": 2,
"currentpage": 1,
"nextpage": 1,
"maxpage": 1,
"urls": [
{
"id": 2,
"alias": "google",
"shorturl": "https:\/\/zed.kr\/google",
"longurl": "https:\/\/google.com",
"clicks": 0,
"title": "Google",
"description": "",
"date": "2020-11-10 18:01:43"
},
{
"id": 1,
"alias": "googlecanada",
"shorturl": "https:\/\/zed.kr\/googlecanada",
"longurl": "https:\/\/google.ca",
"clicks": 0,
"title": "Google Canada",
"description": "",
"date": "2020-11-10 18:00:25"
}
]
}
}
https://zed.kr/api/url/:id
API를 통해 단일 링크에 대한 세부 정보를 얻으려면 이 엔드포인트를 사용할 수 있습니다.
curl --location --request GET 'https://zed.kr/api/url/:id' \
--header 'Authorization: Bearer YOURAPIKEY' \
--header 'Content-Type: application/json' \
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => "https://zed.kr/api/url/:id",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_MAXREDIRS => 2,
CURLOPT_TIMEOUT => 10,
CURLOPT_FOLLOWLOCATION => true,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer YOURAPIKEY",
"Content-Type: application/json",
],
));
$response = curl_exec($curl);
curl_close($curl);
echo $response;
var request = require('request');
var options = {
'method': 'GET',
'url': 'https://zed.kr/api/url/:id',
'headers': {
'Authorization': 'Bearer YOURAPIKEY',
'Content-Type': 'application/json'
},
};
request(options, function (error, response) {
if (error) throw new Error(error);
console.log(response.body);
});
{
"error": 0,
"id": 1,
"details": {
"id": 1,
"shorturl": "https:\/\/zed.kr\/googlecanada",
"longurl": "https:\/\/google.com",
"title": "Google",
"description": "",
"location": {
"canada": "https:\/\/google.ca",
"united states": "https:\/\/google.us"
},
"device": {
"iphone": "https:\/\/google.com",
"android": "https:\/\/google.com"
},
"expiry": null,
"date": "2020-11-10 18:01:43"
},
"data": {
"clicks": 0,
"uniqueClicks": 0,
"topCountries": 0,
"topReferrers": 0,
"topBrowsers": 0,
"topOs": 0,
"socialCount": {
"facebook": 0,
"twitter": 0,
"google": 0
}
}
}
https://zed.kr/api/url/add
링크를 단축하려면 POST 요청을 통해 JSON으로 유효한 데이터를 보내야 합니다. 데이터는 아래와 같이 요청의 원시 본문으로 전송되어야 합니다. 아래 예는 보낼 수 있는 모든 매개변수를 보여 주지만 모두 보낼 필요는 없습니다(자세한 내용은 표 참조).
매개변수 | 설명 |
---|---|
url | (필수) 단축할 긴 URL입니다. |
custom | (선택) 임의의 별칭 대신 사용자 정의 별칭입니다. |
type | (optional) Redirection type [direct, frame, splash], only id for custom splash page or overlay-id for cta pages |
password | (선택) 비밀번호 보호 |
domain | (선택) 사용자 정의 도메인 |
expiry | (선택) 링크 예시 2021-09-28 23:11:16의 만료 |
geotarget | (선택) 지역 타겟팅 데이터 |
devicetarget | (선택) 디바이스 타겟팅 데이터 |
languagetarget | (선택) 언어 타겟팅 데이터 |
metatitle | (선택) 메타 제목 |
metadescription | (선택) 메타 설명 |
metaimage | (선택) jpg 또는 png 이미지에 대한 링크 |
description | (optional) Note or description |
pixels | (선택) 픽셀 ID 정렬 |
channel | (선택) 채널 ID |
deeplink | (선택) 앱 스토어 링크가 포함된 개체입니다. 이를 사용할 때 기기 타겟팅도 설정하는 것이 중요합니다. |
status | (optional) public or private (default) |
curl --location --request POST 'https://zed.kr/api/url/add' \
--header 'Authorization: Bearer YOURAPIKEY' \
--header 'Content-Type: application/json' \
--data-raw '{
"url": "https:\/\/google.com",
"status": "private",
"custom": "google",
"password": "mypass",
"expiry": "2020-11-11 12:00:00",
"type": "splash",
"metatitle": "Not Google",
"metadescription": "Not Google description",
"metaimage": "https:\/\/www.mozilla.org\/media\/protocol\/img\/logos\/firefox\/browser\/og.4ad05d4125a5.png",
"description": "For facebook",
"pixels": [
1,
2,
3,
4
],
"channel": 1,
"deeplink": {
"apple": "https:\/\/apps.apple.com\/us\/app\/google\/id284815942",
"google": "https:\/\/play.google.com\/store\/apps\/details?id=com.google.android.googlequicksearchbox&hl=en_CA&gl=US"
},
"geotarget": [
{
"location": "Canada",
"link": "https:\/\/google.ca"
},
{
"location": "United States",
"link": "https:\/\/google.us"
}
],
"devicetarget": [
{
"device": "iPhone",
"link": "https:\/\/google.com"
},
{
"device": "Android",
"link": "https:\/\/google.com"
}
],
"languagetarget": [
{
"language": "en",
"link": "https:\/\/google.com"
},
{
"language": "fr",
"link": "https:\/\/google.ca"
}
],
"parameters": [
{
"name": "aff",
"value": "3"
},
{
"device": "gtm_source",
"link": "api"
}
]
}'
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => "https://zed.kr/api/url/add",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_MAXREDIRS => 2,
CURLOPT_TIMEOUT => 10,
CURLOPT_FOLLOWLOCATION => true,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer YOURAPIKEY",
"Content-Type: application/json",
],
CURLOPT_POSTFIELDS =>
'{
"url": "https:\/\/google.com",
"status": "private",
"custom": "google",
"password": "mypass",
"expiry": "2020-11-11 12:00:00",
"type": "splash",
"metatitle": "Not Google",
"metadescription": "Not Google description",
"metaimage": "https:\/\/www.mozilla.org\/media\/protocol\/img\/logos\/firefox\/browser\/og.4ad05d4125a5.png",
"description": "For facebook",
"pixels": [
1,
2,
3,
4
],
"channel": 1,
"deeplink": {
"apple": "https:\/\/apps.apple.com\/us\/app\/google\/id284815942",
"google": "https:\/\/play.google.com\/store\/apps\/details?id=com.google.android.googlequicksearchbox&hl=en_CA&gl=US"
},
"geotarget": [
{
"location": "Canada",
"link": "https:\/\/google.ca"
},
{
"location": "United States",
"link": "https:\/\/google.us"
}
],
"devicetarget": [
{
"device": "iPhone",
"link": "https:\/\/google.com"
},
{
"device": "Android",
"link": "https:\/\/google.com"
}
],
"languagetarget": [
{
"language": "en",
"link": "https:\/\/google.com"
},
{
"language": "fr",
"link": "https:\/\/google.ca"
}
],
"parameters": [
{
"name": "aff",
"value": "3"
},
{
"device": "gtm_source",
"link": "api"
}
]
}',
));
$response = curl_exec($curl);
curl_close($curl);
echo $response;
var request = require('request');
var options = {
'method': 'POST',
'url': 'https://zed.kr/api/url/add',
'headers': {
'Authorization': 'Bearer YOURAPIKEY',
'Content-Type': 'application/json'
},
body: JSON.stringify({
"url": "https:\/\/google.com",
"status": "private",
"custom": "google",
"password": "mypass",
"expiry": "2020-11-11 12:00:00",
"type": "splash",
"metatitle": "Not Google",
"metadescription": "Not Google description",
"metaimage": "https:\/\/www.mozilla.org\/media\/protocol\/img\/logos\/firefox\/browser\/og.4ad05d4125a5.png",
"description": "For facebook",
"pixels": [
1,
2,
3,
4
],
"channel": 1,
"deeplink": {
"apple": "https:\/\/apps.apple.com\/us\/app\/google\/id284815942",
"google": "https:\/\/play.google.com\/store\/apps\/details?id=com.google.android.googlequicksearchbox&hl=en_CA&gl=US"
},
"geotarget": [
{
"location": "Canada",
"link": "https:\/\/google.ca"
},
{
"location": "United States",
"link": "https:\/\/google.us"
}
],
"devicetarget": [
{
"device": "iPhone",
"link": "https:\/\/google.com"
},
{
"device": "Android",
"link": "https:\/\/google.com"
}
],
"languagetarget": [
{
"language": "en",
"link": "https:\/\/google.com"
},
{
"language": "fr",
"link": "https:\/\/google.ca"
}
],
"parameters": [
{
"name": "aff",
"value": "3"
},
{
"device": "gtm_source",
"link": "api"
}
]
}),
};
request(options, function (error, response) {
if (error) throw new Error(error);
console.log(response.body);
});
{
"error": 0,
"id": 3,
"shorturl": "https:\/\/zed.kr\/google"
}
https://zed.kr/api/url/:id/update
링크를 업데이트하려면 PUT 요청을 통해 JSON으로 유효한 데이터를 보내야 합니다. 데이터는 아래와 같이 요청의 원시 본문으로 전송되어야 합니다. 아래 예는 보낼 수 있는 모든 매개변수를 보여 주지만 모두 보낼 필요는 없습니다(자세한 내용은 표 참조).
매개변수 | 설명 |
---|---|
url | (필수) 단축할 긴 URL입니다. |
custom | (선택) 임의의 별칭 대신 사용자 정의 별칭입니다. |
type | (선택) 리디렉션 유형 [직접, 프레임, 미리보기] |
password | (선택) 비밀번호 보호 |
domain | (선택) 사용자 정의 도메인 |
expiry | (선택) 링크 예시 2021-09-28 23:11:16의 만료 |
geotarget | (선택) 지역 타겟팅 데이터 |
devicetarget | (선택) 디바이스 타겟팅 데이터 |
languagetarget | (선택) 언어 타겟팅 데이터 |
metatitle | (선택) 메타 제목 |
metadescription | (선택) 메타 설명 |
metaimage | (선택) jpg 또는 png 이미지에 대한 링크 |
pixels | (선택) 픽셀 ID 정렬 |
channel | (선택) 채널 ID |
deeplink | (선택) 앱 스토어 링크가 포함된 개체입니다. 이를 사용할 때 기기 타겟팅도 설정하는 것이 중요합니다. |
curl --location --request PUT 'https://zed.kr/api/url/:id/update' \
--header 'Authorization: Bearer YOURAPIKEY' \
--header 'Content-Type: application/json' \
--data-raw '{
"url": "https:\/\/google.com",
"custom": "google",
"password": "mypass",
"expiry": "2020-11-11 12:00:00",
"type": "splash",
"pixels": [
1,
2,
3,
4
],
"channel": 1,
"deeplink": {
"apple": "https:\/\/apps.apple.com\/us\/app\/google\/id284815942",
"google": "https:\/\/play.google.com\/store\/apps\/details?id=com.google.android.googlequicksearchbox&hl=en_CA&gl=US"
},
"geotarget": [
{
"location": "Canada",
"link": "https:\/\/google.ca"
},
{
"location": "United States",
"link": "https:\/\/google.us"
}
],
"devicetarget": [
{
"device": "iPhone",
"link": "https:\/\/google.com"
},
{
"device": "Android",
"link": "https:\/\/google.com"
}
],
"parameters": [
{
"name": "aff",
"value": "3"
},
{
"device": "gtm_source",
"link": "api"
}
]
}'
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => "https://zed.kr/api/url/:id/update",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_MAXREDIRS => 2,
CURLOPT_TIMEOUT => 10,
CURLOPT_FOLLOWLOCATION => true,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer YOURAPIKEY",
"Content-Type: application/json",
],
CURLOPT_POSTFIELDS =>
'{
"url": "https:\/\/google.com",
"custom": "google",
"password": "mypass",
"expiry": "2020-11-11 12:00:00",
"type": "splash",
"pixels": [
1,
2,
3,
4
],
"channel": 1,
"deeplink": {
"apple": "https:\/\/apps.apple.com\/us\/app\/google\/id284815942",
"google": "https:\/\/play.google.com\/store\/apps\/details?id=com.google.android.googlequicksearchbox&hl=en_CA&gl=US"
},
"geotarget": [
{
"location": "Canada",
"link": "https:\/\/google.ca"
},
{
"location": "United States",
"link": "https:\/\/google.us"
}
],
"devicetarget": [
{
"device": "iPhone",
"link": "https:\/\/google.com"
},
{
"device": "Android",
"link": "https:\/\/google.com"
}
],
"parameters": [
{
"name": "aff",
"value": "3"
},
{
"device": "gtm_source",
"link": "api"
}
]
}',
));
$response = curl_exec($curl);
curl_close($curl);
echo $response;
var request = require('request');
var options = {
'method': 'PUT',
'url': 'https://zed.kr/api/url/:id/update',
'headers': {
'Authorization': 'Bearer YOURAPIKEY',
'Content-Type': 'application/json'
},
body: JSON.stringify({
"url": "https:\/\/google.com",
"custom": "google",
"password": "mypass",
"expiry": "2020-11-11 12:00:00",
"type": "splash",
"pixels": [
1,
2,
3,
4
],
"channel": 1,
"deeplink": {
"apple": "https:\/\/apps.apple.com\/us\/app\/google\/id284815942",
"google": "https:\/\/play.google.com\/store\/apps\/details?id=com.google.android.googlequicksearchbox&hl=en_CA&gl=US"
},
"geotarget": [
{
"location": "Canada",
"link": "https:\/\/google.ca"
},
{
"location": "United States",
"link": "https:\/\/google.us"
}
],
"devicetarget": [
{
"device": "iPhone",
"link": "https:\/\/google.com"
},
{
"device": "Android",
"link": "https:\/\/google.com"
}
],
"parameters": [
{
"name": "aff",
"value": "3"
},
{
"device": "gtm_source",
"link": "api"
}
]
}),
};
request(options, function (error, response) {
if (error) throw new Error(error);
console.log(response.body);
});
{
"error": 0,
"id": 3,
"short": "https:\/\/zed.kr\/google"
}
https://zed.kr/api/url/:id/delete
링크를 삭제하려면 DELETE 요청을 보내야 합니다.
curl --location --request DELETE 'https://zed.kr/api/url/:id/delete' \
--header 'Authorization: Bearer YOURAPIKEY' \
--header 'Content-Type: application/json' \
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => "https://zed.kr/api/url/:id/delete",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_MAXREDIRS => 2,
CURLOPT_TIMEOUT => 10,
CURLOPT_FOLLOWLOCATION => true,
CURLOPT_CUSTOMREQUEST => "DELETE",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer YOURAPIKEY",
"Content-Type: application/json",
],
));
$response = curl_exec($curl);
curl_close($curl);
echo $response;
var request = require('request');
var options = {
'method': 'DELETE',
'url': 'https://zed.kr/api/url/:id/delete',
'headers': {
'Authorization': 'Bearer YOURAPIKEY',
'Content-Type': 'application/json'
},
};
request(options, function (error, response) {
if (error) throw new Error(error);
console.log(response.body);
});
{
"error": 0,
"message": "Link has been deleted successfully"
}
https://zed.kr/api/domains?limit=2&page=1
API를 통해 브랜드 도메인을 얻으려면 이 엔드포인트를 사용할 수 있습니다. 데이터를 필터링할 수도 있습니다(자세한 내용은 표 참조).
매개변수 | 설명 |
---|---|
limit | (선택) 페이지별 데이터 결과 |
page | (선택) 현재 페이지 요청 |
curl --location --request GET 'https://zed.kr/api/domains?limit=2&page=1' \
--header 'Authorization: Bearer YOURAPIKEY' \
--header 'Content-Type: application/json' \
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => "https://zed.kr/api/domains?limit=2&page=1",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_MAXREDIRS => 2,
CURLOPT_TIMEOUT => 10,
CURLOPT_FOLLOWLOCATION => true,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer YOURAPIKEY",
"Content-Type: application/json",
],
));
$response = curl_exec($curl);
curl_close($curl);
echo $response;
var request = require('request');
var options = {
'method': 'GET',
'url': 'https://zed.kr/api/domains?limit=2&page=1',
'headers': {
'Authorization': 'Bearer YOURAPIKEY',
'Content-Type': 'application/json'
},
};
request(options, function (error, response) {
if (error) throw new Error(error);
console.log(response.body);
});
{
"error": "0",
"data": {
"result": 2,
"perpage": 2,
"currentpage": 1,
"nextpage": 1,
"maxpage": 1,
"domains": [
{
"id": 1,
"domain": "https:\/\/domain1.com",
"redirectroot": "https:\/\/rootdomain.com",
"redirect404": "https:\/\/rootdomain.com\/404"
},
{
"id": 2,
"domain": "https:\/\/domain2.com",
"redirectroot": "https:\/\/rootdomain2.com",
"redirect404": "https:\/\/rootdomain2.com\/404"
}
]
}
}
https://zed.kr/api/domain/add
이 엔드포인트를 사용하여 도메인을 추가할 수 있습니다. 도메인이 당사 서버를 올바르게 가리키는지 확인하십시오.
매개변수 | 설명 |
---|---|
domain | (필수) http 또는 https를 포함한 브랜드 도메인 |
redirectroot | (선택) 회원님의 도메인을 방문하면 루트 리디렉션 |
redirect404 | (선택) 커스텀 404 리디렉션 |
curl --location --request POST 'https://zed.kr/api/domain/add' \
--header 'Authorization: Bearer YOURAPIKEY' \
--header 'Content-Type: application/json' \
--data-raw '{
"domain": "https:\/\/domain1.com",
"redirectroot": "https:\/\/rootdomain.com",
"redirect404": "https:\/\/rootdomain.com\/404"
}'
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => "https://zed.kr/api/domain/add",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_MAXREDIRS => 2,
CURLOPT_TIMEOUT => 10,
CURLOPT_FOLLOWLOCATION => true,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer YOURAPIKEY",
"Content-Type: application/json",
],
CURLOPT_POSTFIELDS =>
'{
"domain": "https:\/\/domain1.com",
"redirectroot": "https:\/\/rootdomain.com",
"redirect404": "https:\/\/rootdomain.com\/404"
}',
));
$response = curl_exec($curl);
curl_close($curl);
echo $response;
var request = require('request');
var options = {
'method': 'POST',
'url': 'https://zed.kr/api/domain/add',
'headers': {
'Authorization': 'Bearer YOURAPIKEY',
'Content-Type': 'application/json'
},
body: JSON.stringify({
"domain": "https:\/\/domain1.com",
"redirectroot": "https:\/\/rootdomain.com",
"redirect404": "https:\/\/rootdomain.com\/404"
}),
};
request(options, function (error, response) {
if (error) throw new Error(error);
console.log(response.body);
});
{
"error": 0,
"id": 1
}
https://zed.kr/api/domain/:id/update
브랜드 도메인을 업데이트하려면 PUT 요청을 통해 JSON으로 유효한 데이터를 보내야 합니다. 데이터는 아래와 같이 요청의 원시 본문으로 전송되어야 합니다. 아래 예는 보낼 수 있는 모든 매개변수를 보여 주지만 모두 보낼 필요는 없습니다(자세한 내용은 표 참조).
매개변수 | 설명 |
---|---|
redirectroot | (선택) 회원님의 도메인을 방문하면 루트 리디렉션 |
redirect404 | (선택) 커스텀 404 리디렉션 |
curl --location --request PUT 'https://zed.kr/api/domain/:id/update' \
--header 'Authorization: Bearer YOURAPIKEY' \
--header 'Content-Type: application/json' \
--data-raw '{
"redirectroot": "https:\/\/rootdomain-new.com",
"redirect404": "https:\/\/rootdomain-new.com\/404"
}'
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => "https://zed.kr/api/domain/:id/update",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_MAXREDIRS => 2,
CURLOPT_TIMEOUT => 10,
CURLOPT_FOLLOWLOCATION => true,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer YOURAPIKEY",
"Content-Type: application/json",
],
CURLOPT_POSTFIELDS =>
'{
"redirectroot": "https:\/\/rootdomain-new.com",
"redirect404": "https:\/\/rootdomain-new.com\/404"
}',
));
$response = curl_exec($curl);
curl_close($curl);
echo $response;
var request = require('request');
var options = {
'method': 'PUT',
'url': 'https://zed.kr/api/domain/:id/update',
'headers': {
'Authorization': 'Bearer YOURAPIKEY',
'Content-Type': 'application/json'
},
body: JSON.stringify({
"redirectroot": "https:\/\/rootdomain-new.com",
"redirect404": "https:\/\/rootdomain-new.com\/404"
}),
};
request(options, function (error, response) {
if (error) throw new Error(error);
console.log(response.body);
});
{
"error": 0,
"message": "Domain has been updated successfully."
}
https://zed.kr/api/domain/:id/delete
도메인을 삭제하려면 DELETE 요청을 보내야 합니다.
curl --location --request DELETE 'https://zed.kr/api/domain/:id/delete' \
--header 'Authorization: Bearer YOURAPIKEY' \
--header 'Content-Type: application/json' \
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => "https://zed.kr/api/domain/:id/delete",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_MAXREDIRS => 2,
CURLOPT_TIMEOUT => 10,
CURLOPT_FOLLOWLOCATION => true,
CURLOPT_CUSTOMREQUEST => "DELETE",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer YOURAPIKEY",
"Content-Type: application/json",
],
));
$response = curl_exec($curl);
curl_close($curl);
echo $response;
var request = require('request');
var options = {
'method': 'DELETE',
'url': 'https://zed.kr/api/domain/:id/delete',
'headers': {
'Authorization': 'Bearer YOURAPIKEY',
'Content-Type': 'application/json'
},
};
request(options, function (error, response) {
if (error) throw new Error(error);
console.log(response.body);
});
{
"error": 0,
"message": "Domain has been deleted successfully."
}
https://zed.kr/api/channels?limit=2&page=1
To get your channels via the API, you can use this endpoint. You can also filter data (See table for more info).
매개변수 | 설명 |
---|---|
limit | (선택) 페이지별 데이터 결과 |
page | (선택) 현재 페이지 요청 |
curl --location --request GET 'https://zed.kr/api/channels?limit=2&page=1' \
--header 'Authorization: Bearer YOURAPIKEY' \
--header 'Content-Type: application/json' \
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => "https://zed.kr/api/channels?limit=2&page=1",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_MAXREDIRS => 2,
CURLOPT_TIMEOUT => 10,
CURLOPT_FOLLOWLOCATION => true,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer YOURAPIKEY",
"Content-Type: application/json",
],
));
$response = curl_exec($curl);
curl_close($curl);
echo $response;
var request = require('request');
var options = {
'method': 'GET',
'url': 'https://zed.kr/api/channels?limit=2&page=1',
'headers': {
'Authorization': 'Bearer YOURAPIKEY',
'Content-Type': 'application/json'
},
};
request(options, function (error, response) {
if (error) throw new Error(error);
console.log(response.body);
});
{
"error": "0",
"data": {
"result": 2,
"perpage": 2,
"currentpage": 1,
"nextpage": 1,
"maxpage": 1,
"channels": [
{
"id": 1,
"name": "Channel 1",
"description": "Description of channel 1",
"color": "#000000",
"starred": true
},
{
"id": 2,
"name": "Channel 2",
"description": "Description of channel 2",
"color": "#FF0000",
"starred": false
}
]
}
}
https://zed.kr/api/channel/:id?limit=1&page=1
To get items in a select channels via the API, you can use this endpoint. You can also filter data (See table for more info).
매개변수 | 설명 |
---|---|
limit | (선택) 페이지별 데이터 결과 |
page | (선택) 현재 페이지 요청 |
curl --location --request GET 'https://zed.kr/api/channel/:id?limit=1&page=1' \
--header 'Authorization: Bearer YOURAPIKEY' \
--header 'Content-Type: application/json' \
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => "https://zed.kr/api/channel/:id?limit=1&page=1",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_MAXREDIRS => 2,
CURLOPT_TIMEOUT => 10,
CURLOPT_FOLLOWLOCATION => true,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer YOURAPIKEY",
"Content-Type: application/json",
],
));
$response = curl_exec($curl);
curl_close($curl);
echo $response;
var request = require('request');
var options = {
'method': 'GET',
'url': 'https://zed.kr/api/channel/:id?limit=1&page=1',
'headers': {
'Authorization': 'Bearer YOURAPIKEY',
'Content-Type': 'application/json'
},
};
request(options, function (error, response) {
if (error) throw new Error(error);
console.log(response.body);
});
{
"error": "0",
"data": {
"result": 2,
"perpage": 2,
"currentpage": 1,
"nextpage": 1,
"maxpage": 1,
"items": [
{
"type": "links",
"id": 1,
"title": "My Sample Link",
"preview": "https:\/\/google.com",
"link": "https:\/\/zed.kr\/google",
"date": "2022-05-12"
},
{
"type": "bio",
"id": 1,
"title": "My Sample Bio",
"preview": "https:\/\/zed.kr\/mybio",
"link": "https:\/\/zed.kr\/mybio",
"date": "2022-06-01"
}
]
}
}
https://zed.kr/api/channel/add
A channel can be added using this endpoint.
매개변수 | 설명 |
---|---|
name | (required) Channel name |
description | (optional) Channel description |
color | (optional) Channel badge color (HEX) |
starred | (optional) Star the channel or not (true or false) |
curl --location --request POST 'https://zed.kr/api/channel/add' \
--header 'Authorization: Bearer YOURAPIKEY' \
--header 'Content-Type: application/json' \
--data-raw '{
"name": "New Channel",
"description": "my new channel",
"color": "#000000",
"starred": true
}'
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => "https://zed.kr/api/channel/add",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_MAXREDIRS => 2,
CURLOPT_TIMEOUT => 10,
CURLOPT_FOLLOWLOCATION => true,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer YOURAPIKEY",
"Content-Type: application/json",
],
CURLOPT_POSTFIELDS =>
'{
"name": "New Channel",
"description": "my new channel",
"color": "#000000",
"starred": true
}',
));
$response = curl_exec($curl);
curl_close($curl);
echo $response;
var request = require('request');
var options = {
'method': 'POST',
'url': 'https://zed.kr/api/channel/add',
'headers': {
'Authorization': 'Bearer YOURAPIKEY',
'Content-Type': 'application/json'
},
body: JSON.stringify({
"name": "New Channel",
"description": "my new channel",
"color": "#000000",
"starred": true
}),
};
request(options, function (error, response) {
if (error) throw new Error(error);
console.log(response.body);
});
{
"error": 0,
"id": 3,
"name": "New Channel",
"description": "my new channel",
"color": "#000000",
"starred": true
}
https://zed.kr/api/channel/:channelid/assign/:type/:itemid
An item can be assigned to any channel by sending a request with the channel id, item type (links, bio or qr) and item id.
매개변수 | 설명 |
---|---|
:channelid | (required) Channel ID |
:type | (required) links or bio or qr |
:itemid | (required) Item ID |
curl --location --request POST 'https://zed.kr/api/channel/:channelid/assign/:type/:itemid' \
--header 'Authorization: Bearer YOURAPIKEY' \
--header 'Content-Type: application/json' \
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => "https://zed.kr/api/channel/:channelid/assign/:type/:itemid",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_MAXREDIRS => 2,
CURLOPT_TIMEOUT => 10,
CURLOPT_FOLLOWLOCATION => true,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer YOURAPIKEY",
"Content-Type: application/json",
],
));
$response = curl_exec($curl);
curl_close($curl);
echo $response;
var request = require('request');
var options = {
'method': 'POST',
'url': 'https://zed.kr/api/channel/:channelid/assign/:type/:itemid',
'headers': {
'Authorization': 'Bearer YOURAPIKEY',
'Content-Type': 'application/json'
},
};
request(options, function (error, response) {
if (error) throw new Error(error);
console.log(response.body);
});
{
"error": 0,
"message": "Item successfully added to the channel."
}
https://zed.kr/api/channel/:id/update
To update a channel, you need to send a valid data in JSON via a PUT request. The data must be sent as the raw body of your request as shown below. The example below shows all the parameters you can send but you are not required to send all (See table for more info).
매개변수 | 설명 |
---|---|
name | (optional) Channel name |
description | (optional) Channel description |
color | (optional) Channel badge color (HEX) |
starred | (optional) Star the channel or not (true or false) |
curl --location --request PUT 'https://zed.kr/api/channel/:id/update' \
--header 'Authorization: Bearer YOURAPIKEY' \
--header 'Content-Type: application/json' \
--data-raw '{
"name": "Acme Corp",
"description": "channel for items for Acme Corp",
"color": "#FFFFFF",
"starred": false
}'
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => "https://zed.kr/api/channel/:id/update",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_MAXREDIRS => 2,
CURLOPT_TIMEOUT => 10,
CURLOPT_FOLLOWLOCATION => true,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer YOURAPIKEY",
"Content-Type: application/json",
],
CURLOPT_POSTFIELDS =>
'{
"name": "Acme Corp",
"description": "channel for items for Acme Corp",
"color": "#FFFFFF",
"starred": false
}',
));
$response = curl_exec($curl);
curl_close($curl);
echo $response;
var request = require('request');
var options = {
'method': 'PUT',
'url': 'https://zed.kr/api/channel/:id/update',
'headers': {
'Authorization': 'Bearer YOURAPIKEY',
'Content-Type': 'application/json'
},
body: JSON.stringify({
"name": "Acme Corp",
"description": "channel for items for Acme Corp",
"color": "#FFFFFF",
"starred": false
}),
};
request(options, function (error, response) {
if (error) throw new Error(error);
console.log(response.body);
});
{
"error": 0,
"message": "Channel has been updated successfully."
}
https://zed.kr/api/channel/:id/delete
To delete a channel, you need to send a DELETE request. All items will be unassigned as well.
curl --location --request DELETE 'https://zed.kr/api/channel/:id/delete' \
--header 'Authorization: Bearer YOURAPIKEY' \
--header 'Content-Type: application/json' \
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => "https://zed.kr/api/channel/:id/delete",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_MAXREDIRS => 2,
CURLOPT_TIMEOUT => 10,
CURLOPT_FOLLOWLOCATION => true,
CURLOPT_CUSTOMREQUEST => "DELETE",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer YOURAPIKEY",
"Content-Type: application/json",
],
));
$response = curl_exec($curl);
curl_close($curl);
echo $response;
var request = require('request');
var options = {
'method': 'DELETE',
'url': 'https://zed.kr/api/channel/:id/delete',
'headers': {
'Authorization': 'Bearer YOURAPIKEY',
'Content-Type': 'application/json'
},
};
request(options, function (error, response) {
if (error) throw new Error(error);
console.log(response.body);
});
{
"error": 0,
"message": "Channel has been deleted successfully."
}
https://zed.kr/api/campaigns?limit=2&page=1
To get your campaigns via the API, you can use this endpoint. You can also filter data (See table for more info).
매개변수 | 설명 |
---|---|
limit | (선택) 페이지별 데이터 결과 |
page | (선택) 현재 페이지 요청 |
curl --location --request GET 'https://zed.kr/api/campaigns?limit=2&page=1' \
--header 'Authorization: Bearer YOURAPIKEY' \
--header 'Content-Type: application/json' \
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => "https://zed.kr/api/campaigns?limit=2&page=1",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_MAXREDIRS => 2,
CURLOPT_TIMEOUT => 10,
CURLOPT_FOLLOWLOCATION => true,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer YOURAPIKEY",
"Content-Type: application/json",
],
));
$response = curl_exec($curl);
curl_close($curl);
echo $response;
var request = require('request');
var options = {
'method': 'GET',
'url': 'https://zed.kr/api/campaigns?limit=2&page=1',
'headers': {
'Authorization': 'Bearer YOURAPIKEY',
'Content-Type': 'application/json'
},
};
request(options, function (error, response) {
if (error) throw new Error(error);
console.log(response.body);
});
{
"error": "0",
"data": {
"result": 2,
"perpage": 2,
"currentpage": 1,
"nextpage": 1,
"maxpage": 1,
"campaigns": [
{
"id": 1,
"name": "Sample Campaign",
"public": false,
"rotator": false,
"list": "https:\/\/domain.com\/u\/admin\/list-1"
},
{
"id": 2,
"domain": "Facebook Campaign",
"public": true,
"rotator": "https:\/\/domain.com\/r\/test",
"list": "https:\/\/domain.com\/u\/admin\/test-2"
}
]
}
}
https://zed.kr/api/campaign/add
A campaign can be added using this endpoint.
매개변수 | 설명 |
---|---|
name | (optional) Campaign name |
slug | (optional) Rotator Slug |
public | (optional) Access |
curl --location --request POST 'https://zed.kr/api/campaign/add' \
--header 'Authorization: Bearer YOURAPIKEY' \
--header 'Content-Type: application/json' \
--data-raw '{
"name": "New Campaign",
"slug": "new-campaign",
"public": true
}'
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => "https://zed.kr/api/campaign/add",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_MAXREDIRS => 2,
CURLOPT_TIMEOUT => 10,
CURLOPT_FOLLOWLOCATION => true,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer YOURAPIKEY",
"Content-Type: application/json",
],
CURLOPT_POSTFIELDS =>
'{
"name": "New Campaign",
"slug": "new-campaign",
"public": true
}',
));
$response = curl_exec($curl);
curl_close($curl);
echo $response;
var request = require('request');
var options = {
'method': 'POST',
'url': 'https://zed.kr/api/campaign/add',
'headers': {
'Authorization': 'Bearer YOURAPIKEY',
'Content-Type': 'application/json'
},
body: JSON.stringify({
"name": "New Campaign",
"slug": "new-campaign",
"public": true
}),
};
request(options, function (error, response) {
if (error) throw new Error(error);
console.log(response.body);
});
{
"error": 0,
"id": 3,
"domain": "New Campaign",
"public": true,
"rotator": "https:\/\/domain.com\/r\/new-campaign",
"list": "https:\/\/domain.com\/u\/admin\/new-campaign-3"
}
https://zed.kr/api/campaign/:campaignid/assign/:linkid
A short link can be assigned to a campaign using this endpoint. The endpoint requires the campaign ID and the short link ID.
curl --location --request POST 'https://zed.kr/api/campaign/:campaignid/assign/:linkid' \
--header 'Authorization: Bearer YOURAPIKEY' \
--header 'Content-Type: application/json' \
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => "https://zed.kr/api/campaign/:campaignid/assign/:linkid",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_MAXREDIRS => 2,
CURLOPT_TIMEOUT => 10,
CURLOPT_FOLLOWLOCATION => true,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer YOURAPIKEY",
"Content-Type: application/json",
],
));
$response = curl_exec($curl);
curl_close($curl);
echo $response;
var request = require('request');
var options = {
'method': 'POST',
'url': 'https://zed.kr/api/campaign/:campaignid/assign/:linkid',
'headers': {
'Authorization': 'Bearer YOURAPIKEY',
'Content-Type': 'application/json'
},
};
request(options, function (error, response) {
if (error) throw new Error(error);
console.log(response.body);
});
{
"error": 0,
"message": "Link successfully added to the campaign."
}
https://zed.kr/api/campaign/:id/update
To update a campaign, you need to send a valid data in JSON via a PUT request. The data must be sent as the raw body of your request as shown below. The example below shows all the parameters you can send but you are not required to send all (See table for more info).
매개변수 | 설명 |
---|---|
name | (required) Campaign name |
slug | (optional) Rotator Slug |
public | (optional) Access |
curl --location --request PUT 'https://zed.kr/api/campaign/:id/update' \
--header 'Authorization: Bearer YOURAPIKEY' \
--header 'Content-Type: application/json' \
--data-raw '{
"name": "Twitter Campaign",
"slug": "twitter-campaign",
"public": true
}'
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => "https://zed.kr/api/campaign/:id/update",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_MAXREDIRS => 2,
CURLOPT_TIMEOUT => 10,
CURLOPT_FOLLOWLOCATION => true,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer YOURAPIKEY",
"Content-Type: application/json",
],
CURLOPT_POSTFIELDS =>
'{
"name": "Twitter Campaign",
"slug": "twitter-campaign",
"public": true
}',
));
$response = curl_exec($curl);
curl_close($curl);
echo $response;
var request = require('request');
var options = {
'method': 'PUT',
'url': 'https://zed.kr/api/campaign/:id/update',
'headers': {
'Authorization': 'Bearer YOURAPIKEY',
'Content-Type': 'application/json'
},
body: JSON.stringify({
"name": "Twitter Campaign",
"slug": "twitter-campaign",
"public": true
}),
};
request(options, function (error, response) {
if (error) throw new Error(error);
console.log(response.body);
});
{
"error": 0,
"id": 3,
"domain": "Twitter Campaign",
"public": true,
"rotator": "https:\/\/domain.com\/r\/twitter-campaign",
"list": "https:\/\/domain.com\/u\/admin\/twitter-campaign-3"
}
https://zed.kr/api/campaign/:id/delete
To delete a campaign, you need to send a DELETE request.
curl --location --request DELETE 'https://zed.kr/api/campaign/:id/delete' \
--header 'Authorization: Bearer YOURAPIKEY' \
--header 'Content-Type: application/json' \
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => "https://zed.kr/api/campaign/:id/delete",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_MAXREDIRS => 2,
CURLOPT_TIMEOUT => 10,
CURLOPT_FOLLOWLOCATION => true,
CURLOPT_CUSTOMREQUEST => "DELETE",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer YOURAPIKEY",
"Content-Type: application/json",
],
));
$response = curl_exec($curl);
curl_close($curl);
echo $response;
var request = require('request');
var options = {
'method': 'DELETE',
'url': 'https://zed.kr/api/campaign/:id/delete',
'headers': {
'Authorization': 'Bearer YOURAPIKEY',
'Content-Type': 'application/json'
},
};
request(options, function (error, response) {
if (error) throw new Error(error);
console.log(response.body);
});
{
"error": 0,
"message": "Campaign has been deleted successfully."
}
https://zed.kr/api/splash?limit=2&page=1
To get custom splash pages via the API, you can use this endpoint. You can also filter data (See table for more info).
매개변수 | 설명 |
---|---|
limit | (선택) 페이지별 데이터 결과 |
page | (선택) 현재 페이지 요청 |
curl --location --request GET 'https://zed.kr/api/splash?limit=2&page=1' \
--header 'Authorization: Bearer YOURAPIKEY' \
--header 'Content-Type: application/json' \
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => "https://zed.kr/api/splash?limit=2&page=1",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_MAXREDIRS => 2,
CURLOPT_TIMEOUT => 10,
CURLOPT_FOLLOWLOCATION => true,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer YOURAPIKEY",
"Content-Type: application/json",
],
));
$response = curl_exec($curl);
curl_close($curl);
echo $response;
var request = require('request');
var options = {
'method': 'GET',
'url': 'https://zed.kr/api/splash?limit=2&page=1',
'headers': {
'Authorization': 'Bearer YOURAPIKEY',
'Content-Type': 'application/json'
},
};
request(options, function (error, response) {
if (error) throw new Error(error);
console.log(response.body);
});
{
"error": "0",
"data": {
"result": 2,
"perpage": 2,
"currentpage": 1,
"nextpage": 1,
"maxpage": 1,
"splash": [
{
"id": 1,
"name": "Product 1 Promo",
"date": "2020-11-10 18:00:00"
},
{
"id": 2,
"name": "Product 2 Promo",
"date": "2020-11-10 18:10:00"
}
]
}
}
https://zed.kr/api/pixels?limit=2&page=1
To get your pixels codes via the API, you can use this endpoint. You can also filter data (See table for more info).
매개변수 | 설명 |
---|---|
limit | (선택) 페이지별 데이터 결과 |
page | (선택) 현재 페이지 요청 |
curl --location --request GET 'https://zed.kr/api/pixels?limit=2&page=1' \
--header 'Authorization: Bearer YOURAPIKEY' \
--header 'Content-Type: application/json' \
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => "https://zed.kr/api/pixels?limit=2&page=1",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_MAXREDIRS => 2,
CURLOPT_TIMEOUT => 10,
CURLOPT_FOLLOWLOCATION => true,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer YOURAPIKEY",
"Content-Type: application/json",
],
));
$response = curl_exec($curl);
curl_close($curl);
echo $response;
var request = require('request');
var options = {
'method': 'GET',
'url': 'https://zed.kr/api/pixels?limit=2&page=1',
'headers': {
'Authorization': 'Bearer YOURAPIKEY',
'Content-Type': 'application/json'
},
};
request(options, function (error, response) {
if (error) throw new Error(error);
console.log(response.body);
});
{
"error": "0",
"data": {
"result": 2,
"perpage": 2,
"currentpage": 1,
"nextpage": 1,
"maxpage": 1,
"pixels": [
{
"id": 1,
"type": "gtmpixel",
"name": "GTM Pixel",
"tag": "GA-123456789",
"date": "2020-11-10 18:00:00"
},
{
"id": 2,
"type": "twitterpixel",
"name": "Twitter Pixel",
"tag": "1234567",
"date": "2020-11-10 18:10:00"
}
]
}
}
https://zed.kr/api/pixel/add
A pixel can be created using this endpoint. You need to send the pixel type and the tag.
매개변수 | 설명 |
---|---|
type | (required) gtmpixel | gapixel | fbpixel | adwordspixel | linkedinpixel | twitterpixel | adrollpixel | quorapixel | pinterest | bing | snapchat | reddit | tiktok |
name | (required) Custom name for your pixel |
tag | (required) The tag for the pixel |
curl --location --request POST 'https://zed.kr/api/pixel/add' \
--header 'Authorization: Bearer YOURAPIKEY' \
--header 'Content-Type: application/json' \
--data-raw '{
"type": "gtmpixel",
"name": "My GTM",
"tag": "GTM-ABCDE"
}'
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => "https://zed.kr/api/pixel/add",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_MAXREDIRS => 2,
CURLOPT_TIMEOUT => 10,
CURLOPT_FOLLOWLOCATION => true,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer YOURAPIKEY",
"Content-Type: application/json",
],
CURLOPT_POSTFIELDS =>
'{
"type": "gtmpixel",
"name": "My GTM",
"tag": "GTM-ABCDE"
}',
));
$response = curl_exec($curl);
curl_close($curl);
echo $response;
var request = require('request');
var options = {
'method': 'POST',
'url': 'https://zed.kr/api/pixel/add',
'headers': {
'Authorization': 'Bearer YOURAPIKEY',
'Content-Type': 'application/json'
},
body: JSON.stringify({
"type": "gtmpixel",
"name": "My GTM",
"tag": "GTM-ABCDE"
}),
};
request(options, function (error, response) {
if (error) throw new Error(error);
console.log(response.body);
});
{
"error": 0,
"id": 1
}
https://zed.kr/api/pixel/:id/update
To update a pixel, you need to send a valid data in JSON via a PUT request. The data must be sent as the raw body of your request as shown below. The example below shows all the parameters you can send but you are not required to send all (See table for more info).
매개변수 | 설명 |
---|---|
name | (optional) Custom name for your pixel |
tag | (required) The tag for the pixel |
curl --location --request PUT 'https://zed.kr/api/pixel/:id/update' \
--header 'Authorization: Bearer YOURAPIKEY' \
--header 'Content-Type: application/json' \
--data-raw '{
"name": "My GTM",
"tag": "GTM-ABCDE"
}'
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => "https://zed.kr/api/pixel/:id/update",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_MAXREDIRS => 2,
CURLOPT_TIMEOUT => 10,
CURLOPT_FOLLOWLOCATION => true,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer YOURAPIKEY",
"Content-Type: application/json",
],
CURLOPT_POSTFIELDS =>
'{
"name": "My GTM",
"tag": "GTM-ABCDE"
}',
));
$response = curl_exec($curl);
curl_close($curl);
echo $response;
var request = require('request');
var options = {
'method': 'PUT',
'url': 'https://zed.kr/api/pixel/:id/update',
'headers': {
'Authorization': 'Bearer YOURAPIKEY',
'Content-Type': 'application/json'
},
body: JSON.stringify({
"name": "My GTM",
"tag": "GTM-ABCDE"
}),
};
request(options, function (error, response) {
if (error) throw new Error(error);
console.log(response.body);
});
{
"error": 0,
"message": "Pixel has been updated successfully."
}
https://zed.kr/api/pixel/:id/delete
To delete a pixel, you need to send a DELETE request.
curl --location --request DELETE 'https://zed.kr/api/pixel/:id/delete' \
--header 'Authorization: Bearer YOURAPIKEY' \
--header 'Content-Type: application/json' \
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => "https://zed.kr/api/pixel/:id/delete",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_MAXREDIRS => 2,
CURLOPT_TIMEOUT => 10,
CURLOPT_FOLLOWLOCATION => true,
CURLOPT_CUSTOMREQUEST => "DELETE",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer YOURAPIKEY",
"Content-Type: application/json",
],
));
$response = curl_exec($curl);
curl_close($curl);
echo $response;
var request = require('request');
var options = {
'method': 'DELETE',
'url': 'https://zed.kr/api/pixel/:id/delete',
'headers': {
'Authorization': 'Bearer YOURAPIKEY',
'Content-Type': 'application/json'
},
};
request(options, function (error, response) {
if (error) throw new Error(error);
console.log(response.body);
});
{
"error": 0,
"message": "Pixel has been deleted successfully."
}