JavaScript
import Whop from '@whop/sdk';
const client = new Whop({
apiKey: process.env['WHOP_API_KEY'], // This is the default and can be omitted
});
// Automatically fetches more pages as needed.
for await (const notificationTopic of client.notifications.topics.list()) {
console.log(notificationTopic.id);
}curl --request GET \
--url https://api.whop.com/api/v1/notifications/topics \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.whop.com/api/v1/notifications/topics"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.whop.com/api/v1/notifications/topics",
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.whop.com/api/v1/notifications/topics"
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.whop.com/api/v1/notifications/topics")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.whop.com/api/v1/notifications/topics")
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": [
{
"default_preference_value": false,
"description": "A customer books and pays for a detail",
"id": "topic_xxxxxxxxxxxxxx",
"identifier": "notification_topic1_xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
"is_mention": true,
"name": "New sales",
"topic_type": "account_team"
}
],
"page_info": {
"end_cursor": "WyJjdXJzb3IiLDFd",
"has_next_page": false,
"has_previous_page": false,
"start_cursor": "WyJjdXJzb3IiLDFd"
}
}{
"error": {
"message": "account_id is required",
"type": "bad_request",
"code": "<string>"
}
}{
"error": {
"message": "account_id is required",
"type": "bad_request",
"code": "<string>"
}
}Notifications
List Notification Topics
Lists the platform’s visible notification topics — the categories users can set notification preferences on. App-created topics are internal and not returned.
GET
/
notifications
/
topics
JavaScript
import Whop from '@whop/sdk';
const client = new Whop({
apiKey: process.env['WHOP_API_KEY'], // This is the default and can be omitted
});
// Automatically fetches more pages as needed.
for await (const notificationTopic of client.notifications.topics.list()) {
console.log(notificationTopic.id);
}curl --request GET \
--url https://api.whop.com/api/v1/notifications/topics \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.whop.com/api/v1/notifications/topics"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.whop.com/api/v1/notifications/topics",
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.whop.com/api/v1/notifications/topics"
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.whop.com/api/v1/notifications/topics")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.whop.com/api/v1/notifications/topics")
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": [
{
"default_preference_value": false,
"description": "A customer books and pays for a detail",
"id": "topic_xxxxxxxxxxxxxx",
"identifier": "notification_topic1_xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
"is_mention": true,
"name": "New sales",
"topic_type": "account_team"
}
],
"page_info": {
"end_cursor": "WyJjdXJzb3IiLDFd",
"has_next_page": false,
"has_previous_page": false,
"start_cursor": "WyJjdXJzb3IiLDFd"
}
}{
"error": {
"message": "account_id is required",
"type": "bad_request",
"code": "<string>"
}
}{
"error": {
"message": "account_id is required",
"type": "bad_request",
"code": "<string>"
}
}Authorizations
An Account API key, account-scoped JWT, App API key, or user OAuth token. Prepend the key or token with Bearer, for example Bearer ***************************.
Headers
Pins the request to a dated API version.
Example:
"2026-08-13"
Query Parameters
Only return topics of this scope: user (member notifications) or account_team (team notifications).
Available options:
user, account_team The number of topics to return (default 20, max 100).
A cursor; returns topics after this position.
⌘I

