List of mini app notification tokens
curl --request GET \
--url https://api.neynar.com/v2/farcaster/frame/notification_tokens/ \
--header 'x-api-key: <api-key>'import requests
url = "https://api.neynar.com/v2/farcaster/frame/notification_tokens/"
headers = {"x-api-key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'x-api-key': '<api-key>'}};
fetch('https://api.neynar.com/v2/farcaster/frame/notification_tokens/', 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.neynar.com/v2/farcaster/frame/notification_tokens/",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"x-api-key: <api-key>"
],
]);
$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.neynar.com/v2/farcaster/frame/notification_tokens/"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("x-api-key", "<api-key>")
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.neynar.com/v2/farcaster/frame/notification_tokens/")
.header("x-api-key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.neynar.com/v2/farcaster/frame/notification_tokens/")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["x-api-key"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"next": {
"cursor": "<string>"
},
"notification_tokens": [
{
"created_at": "2023-11-07T05:31:56Z",
"fid": 3,
"object": "notification_token",
"status": "enabled",
"token": "<string>",
"updated_at": "2023-11-07T05:31:56Z",
"url": "<string>"
}
]
}{
"message": "<string>",
"code": "<string>",
"property": "<string>",
"status": 123
}Notifications
List of mini app notification tokens
Returns a list of notifications tokens related to a mini app
GET
/
v2
/
farcaster
/
frame
/
notification_tokens
/
List of mini app notification tokens
curl --request GET \
--url https://api.neynar.com/v2/farcaster/frame/notification_tokens/ \
--header 'x-api-key: <api-key>'import requests
url = "https://api.neynar.com/v2/farcaster/frame/notification_tokens/"
headers = {"x-api-key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'x-api-key': '<api-key>'}};
fetch('https://api.neynar.com/v2/farcaster/frame/notification_tokens/', 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.neynar.com/v2/farcaster/frame/notification_tokens/",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"x-api-key: <api-key>"
],
]);
$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.neynar.com/v2/farcaster/frame/notification_tokens/"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("x-api-key", "<api-key>")
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.neynar.com/v2/farcaster/frame/notification_tokens/")
.header("x-api-key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.neynar.com/v2/farcaster/frame/notification_tokens/")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["x-api-key"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"next": {
"cursor": "<string>"
},
"notification_tokens": [
{
"created_at": "2023-11-07T05:31:56Z",
"fid": 3,
"object": "notification_token",
"status": "enabled",
"token": "<string>",
"updated_at": "2023-11-07T05:31:56Z",
"url": "<string>"
}
]
}{
"message": "<string>",
"code": "<string>",
"property": "<string>",
"status": 123
}Related tutorial: Send notifications to Frame users
Node.js SDK
🔗 SDK Method: fetchNotificationTokens Use this API endpoint with the Neynar Node.js SDK for typed responses and better developer experience.Authorizations
API key to authorize requests
Query Parameters
Number of results to fetch
Required range:
1 <= x <= 100Example:
20
Comma separated list of FIDs, up to 100 at a time. If you pass in FIDs, you will get back the notification tokens for those FIDs. If you don't pass in FIDs, you will get back all the notification tokens for the mini app.
Example:
"194, 191, 6131"
Pagination cursor
Related topics
fetchNotificationTokensMini App Hosts NotificationsSend Notifications to Mini App UsersSending NotificationsDebug NotificationsWas this page helpful?