Get Watchlists
WatchlistGetWatchlistsResponse v1().watchlist().getWatchlists(WatchlistGetWatchlistsParamsparams = WatchlistGetWatchlistsParams.none(), RequestOptionsrequestOptions = RequestOptions.none())
GET/v1/watchlists
Get Watchlists
package com.clear_street.api.example;
import com.clear_street.api.client.ClearStreetClient;
import com.clear_street.api.client.okhttp.ClearStreetOkHttpClient;
import com.clear_street.api.models.v1.watchlist.WatchlistGetWatchlistsParams;
import com.clear_street.api.models.v1.watchlist.WatchlistGetWatchlistsResponse;
public final class Main {
private Main() {}
public static void main(String[] args) {
ClearStreetClient client = ClearStreetOkHttpClient.builder()
.fromEnv()
.apiKey("My API Key")
.build();
WatchlistGetWatchlistsResponse response = client.v1().watchlist().getWatchlists();
}
}{
"data": [
{
"created_at": "2025-01-15T10:00:00.000000000Z",
"id": "550e8400-e29b-41d4-a716-446655440000",
"name": "Tech Stocks"
},
{
"created_at": "2025-01-10T14:30:00.000000000Z",
"id": "660e8400-e29b-41d4-a716-446655440001",
"name": "Dividend Portfolio"
}
],
"error": null,
"metadata": {
"next_page_token": null,
"page_number": 1,
"request_id": "a1b2c3d4-e5f6-7890-1234-567890abcdef",
"total_items": 2,
"total_pages": 1
}
}Returns Examples
{
"data": [
{
"created_at": "2025-01-15T10:00:00.000000000Z",
"id": "550e8400-e29b-41d4-a716-446655440000",
"name": "Tech Stocks"
},
{
"created_at": "2025-01-10T14:30:00.000000000Z",
"id": "660e8400-e29b-41d4-a716-446655440001",
"name": "Dividend Portfolio"
}
],
"error": null,
"metadata": {
"next_page_token": null,
"page_number": 1,
"request_id": "a1b2c3d4-e5f6-7890-1234-567890abcdef",
"total_items": 2,
"total_pages": 1
}
}