list-campaigns
curl --request GET \
--url https://api.notifly.tech/v1/projects/{projectId}/campaigns \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.notifly.tech/v1/projects/{projectId}/campaigns"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.notifly.tech/v1/projects/{projectId}/campaigns', 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.notifly.tech/v1/projects/{projectId}/campaigns",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.notifly.tech/v1/projects/{projectId}/campaigns"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.notifly.tech/v1/projects/{projectId}/campaigns")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.notifly.tech/v1/projects/{projectId}/campaigns")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"data": {
"campaigns": [
{
"id": "a1B2c3",
"name": "会員登録ウェルカムプッシュ",
"description": "会員登録の1時間後に配信",
"status": "active",
"type": "standard",
"channel": "push-notification",
"segment_type": "condition",
"timing": {
"timing_type": "event-based",
"interval": null,
"starts": [
1796050800
],
"delay": 3600,
"end": 1803826800
},
"created_at": "2026-11-28T02:15:30.000Z",
"updated_at": "2026-11-30T08:40:12.000Z"
},
{
"id": "Xy9Zk2",
"name": "12月プロモーションのアリムトーク",
"description": null,
"status": "draft",
"type": "standard",
"channel": "kakao-alimtalk",
"segment_type": "csv",
"timing": {
"timing_type": "scheduled",
"interval": null,
"starts": [
1796432400
],
"delay": null,
"end": null
},
"created_at": "2026-11-25T06:00:00.000Z",
"updated_at": "2026-11-25T06:10:45.000Z"
}
],
"next_cursor": "eyJjcmVhdGVkX2F0IjoiMjAyNi0xMS0yNVQwNjowMDowMC4wMDBaIiwiaWQiOiJYeTlaazIifQ"
},
"error": null
}{
"data": null,
"error": {
"code": "INVALID_ARGUMENT",
"message": "Invalid campaign list query: page_size: Number must be less than or equal to 100"
}
}{
"data": null,
"error": {
"code": "UNAUTHENTICATED",
"message": "Invalid Authorization Token."
}
}{
"data": null,
"error": {
"code": "PERMISSION_DENIED",
"message": "Invalid Access."
}
}{
"data": null,
"error": {
"code": "UNAUTHORIZED",
"message": "Invalid Authorization Token"
}
}キャンペーンとジャーニー
キャンペーンを一覧取得する
プロジェクトのキャンペーンを、ステータス、チャネル、配信タイミングの種類で絞り込んで一覧取得します。
GET
/
v1
/
projects
/
{projectId}
/
campaigns
list-campaigns
curl --request GET \
--url https://api.notifly.tech/v1/projects/{projectId}/campaigns \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.notifly.tech/v1/projects/{projectId}/campaigns"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.notifly.tech/v1/projects/{projectId}/campaigns', 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.notifly.tech/v1/projects/{projectId}/campaigns",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.notifly.tech/v1/projects/{projectId}/campaigns"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.notifly.tech/v1/projects/{projectId}/campaigns")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.notifly.tech/v1/projects/{projectId}/campaigns")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"data": {
"campaigns": [
{
"id": "a1B2c3",
"name": "会員登録ウェルカムプッシュ",
"description": "会員登録の1時間後に配信",
"status": "active",
"type": "standard",
"channel": "push-notification",
"segment_type": "condition",
"timing": {
"timing_type": "event-based",
"interval": null,
"starts": [
1796050800
],
"delay": 3600,
"end": 1803826800
},
"created_at": "2026-11-28T02:15:30.000Z",
"updated_at": "2026-11-30T08:40:12.000Z"
},
{
"id": "Xy9Zk2",
"name": "12月プロモーションのアリムトーク",
"description": null,
"status": "draft",
"type": "standard",
"channel": "kakao-alimtalk",
"segment_type": "csv",
"timing": {
"timing_type": "scheduled",
"interval": null,
"starts": [
1796432400
],
"delay": null,
"end": null
},
"created_at": "2026-11-25T06:00:00.000Z",
"updated_at": "2026-11-25T06:10:45.000Z"
}
],
"next_cursor": "eyJjcmVhdGVkX2F0IjoiMjAyNi0xMS0yNVQwNjowMDowMC4wMDBaIiwiaWQiOiJYeTlaazIifQ"
},
"error": null
}{
"data": null,
"error": {
"code": "INVALID_ARGUMENT",
"message": "Invalid campaign list query: page_size: Number must be less than or equal to 100"
}
}{
"data": null,
"error": {
"code": "UNAUTHENTICATED",
"message": "Invalid Authorization Token."
}
}{
"data": null,
"error": {
"code": "PERMISSION_DENIED",
"message": "Invalid Access."
}
}{
"data": null,
"error": {
"code": "UNAUTHORIZED",
"message": "Invalid Authorization Token"
}
}Notifly MCPの
list_campaignsツールと同じ取得ロジックを使います。MCPを使わずに、サーバーや社内ツールからキャンペーンを一覧取得し、ステータス、チャネル、配信タイミングの種類で絞り込めます。- キャンペーンは作成日時が新しい順に返されます。
statusを省略すると、削除済みを除くすべてのキャンペーンを返します。削除済みのキャンペーンはstatus=deletedを指定した場合にのみ返されます。- 複数のフィルターを指定すると、すべての条件に一致するキャンペーンのみを返します(AND)。
- レスポンスにはキャンペーンの基本情報と配信タイミングの概要のみが含まれます。メッセージ本文、ターゲティング条件、配信統計は含まれません。
- 定義されていないクエリパラメーター(例:
limit)を送ると400を返します。ページサイズはpage_sizeで指定します。
data.next_cursorの値がある場合は、次のリクエストのnext_cursorクエリパラメーターにそのまま渡します。next_cursorがnullの場合は最後のページです。次のページをリクエストするときは、最初のリクエストと同じフィルターを指定してください。
# 1) 有効なアプリプッシュキャンペーンの最初のページ
curl -G "https://api.notifly.tech/v1/projects/{projectId}/campaigns" \
-H "Authorization: Bearer {token}" \
--data-urlencode "status=active" \
--data-urlencode "channel=push-notification" \
--data-urlencode "page_size=50"
# 2) 次のページ: 同じフィルター + 前のレスポンスのnext_cursor
curl -G "https://api.notifly.tech/v1/projects/{projectId}/campaigns" \
-H "Authorization: Bearer {token}" \
--data-urlencode "status=active" \
--data-urlencode "channel=push-notification" \
--data-urlencode "page_size=50" \
--data-urlencode "next_cursor={next_cursor}"
取得したキャンペーンの
idを使って、キャンペーンをトリガーするやキャンペーンの詳細統計を取得するを呼び出せます。APIで配信するキャンペーンのみを探す場合は、timing_type=apiで絞り込んでください。