after_cursorstring
Opaque cursor token from a previous response's next_cursor
https://api.sandbase.ai/v1/api/polymarket/events-keysetList events with cursor based keyset pagination. Use next_cursor as after_cursor to fetch the next page. The offset parameter is rejected.
出力はここに表示されます
入力を完了してから[実行]をクリックしてください。
Returns a page of Polymarket events, each with its markets, series and tags. All inputs are optional filters, and you page through results with a cursor instead of an offset.
volume_min or liquidity_min.title_search to track markets on a topic.curl -X POST "https://api.sandbase.ai/v1/api/polymarket/events-keyset" \
-H "Authorization: Bearer $SANDBASE_API_KEY" \
-H "Content-Type: application/json" \
-d '{"limit": 2}'
The result is returned in outputs[0].data.
| Name | Type | Required | Description |
|---|---|---|---|
after_cursor | string | No | Opaque cursor token from a previous response's next_cursor |
ascending | boolean | No | Sort direction. Only used when order is set. |
closed | boolean | No | Filter by closed state. Omitted includes open and closed events. Use true for closed events, false for open events, or any (case-insensitive) for both states. Unlike markets, any does not require an identifier filter. In |
created_by | array | No | created_by |
cyom | boolean | No | cyom |
end_date_max | string | No | end_date_max |
end_date_min | string | No | end_date_min |
event_date | string | No | event_date |
event_week | integer | No | event_week |
exclude_tag_id | array | No | Tag IDs to exclude. Cannot overlap with tag_id. |
featured | boolean | No | featured |
featured_order | boolean | No | featured_order |
game_id | array | No | game_id |
id | array | No | id |
include_best_lines | boolean | No | When true, includes BestLines relation |
include_chat | boolean | No | When true, includes Chats and Series.Chats relations |
include_children | boolean | No | include_children |
include_template | boolean | No | When true, includes Templates relation |
limit | integer | No | Maximum number of results to return (max 100) |
liquidity_max | number | No | liquidity_max |
liquidity_min | number | No | liquidity_min |
live | boolean | No | live |
locale | string | No | locale |
offset | integer | No | Not allowed. Returns 422 if provided. |
order | string | No | Comma-separated list of JSON field names to order by |
parent_event_id | integer | No | parent_event_id |
partner_slug | string | No | When set, external_partners are attached to matching events |
recurrence | string | No | recurrence |
related_tags | boolean | No | related_tags |
series_id | array | No | series_id |
slug | array | No | slug |
start_date_max | string | No | start_date_max |
start_date_min | string | No | start_date_min |
start_time_max | string | No | start_time_max |
start_time_min | string | No | start_time_min |
tag_id | array | No | tag_id |
tag_match | string | No | tag_match |
tag_slug | string | No | tag_slug |
title_search | string | No | title_search |
volume_max | number | No | volume_max |
volume_min | number | No | volume_min |
Real response for the request above, trimmed: lists keep their first item and long strings are cut.
{
"$schema": "https://gamma-api.polymarket.com/schemas/EventsKeysetListResponse.json",
"events": [
{
"active": true,
"archived": false,
"category": "Sports",
"closed": true,
"closedTime": "2022-07-27T14:40:02.074Z",
"commentCount": 8128,
"competitive": 0,
"createdAt": "2022-07-27T14:40:02.074Z",
"creationDate": "2021-12-04T00:00:00Z",
"cyom": false,
"deploying": false,
"description": "In the upcoming NBA game, scheduled for December 4:\n\nIf the Dallas Mavericks win…"
}
],
"next_cursor": "baQCMe2wl4-1BqJJ87F6fVlbWuykHjYlEXNrqgeisfJ7InYiOjEsImsiOiJldmVudHMiLCJvaCI6IjRm…"
}
| Field | Meaning |
|---|---|
events[].id / events[].slug / events[].ticker | Identifiers for the event. id is a numeric string, and slug and ticker are readable keys that match the event URL name. |
events[].title / events[].description | The event question and the text that explains how its markets resolve. |
events[].active / events[].closed / events[].archived | Flags for the event state. closedTime gives the time the event was closed. |
events[].startDate / events[].endDate / events[].createdAt | ISO 8601 timestamps for when the event starts, ends and was created. |
events[].liquidity / events[].openInterest / events[].commentCount | Liquidity, open interest and comment count for the event. |
events[].resolutionSource | URL of the source used to settle the event. |
events[].markets[].bestBid / events[].markets[].bestAsk | Best bid and best ask price for a market inside the event. |
events[].markets[].clobTokenIds | Token IDs for the market outcomes, returned as a JSON-encoded string. Parse it before use. |
events[].tags[].id / events[].tags[].label / events[].tags[].slug | Tags attached to the event. Use the id values with tag_id or exclude_tag_id to filter. |
events[].series[] / events[].seriesSlug | The series the event belongs to, such as nba or nfl. |
next_cursor from the response into after_cursor to get the next page. Do not send offset, which returns a 422 error.limit accepts 1 to 100 and defaults to 20.$0.00044 per successful call. Failed calls are not charged. It is included in the daily free quota of each organization.
開発を始める
統一認証と使用状況の追跡を備えたプラットフォームAPIエンドポイントです。
curl -X POST "https://api.sandbase.ai/v1/api/polymarket/events-keyset" \
-H "Authorization: Bearer $SANDBASE_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"limit": 2,
"ascending": true
}'SandBaseのAPIキーをサーバー環境に設定してください。リクエストはBearer認証を使用します。
export SANDBASE_API_KEY="YOUR_API_KEY"キーはサーバー側で管理してください。ブラウザコードに公開しないでください。
after_cursorstringOpaque cursor token from a previous response's next_cursor
ascendingbooleanSort direction. Only used when order is set.
デフォルト: true
closedbooleanFilter by closed state. Omitted includes open and closed events. Use true for closed events, false for open events, or any (case-insensitive) for both states. Unlike markets, any does not require an identifier filter. Invalid closed values return 422.
指定可能な値: any
created_byarraycreated_by
cyombooleancyom
end_date_maxstringend_date_max
end_date_minstringend_date_min
event_datestringevent_date
event_weekintegerevent_week
exclude_tag_idarrayTag IDs to exclude. Cannot overlap with tag_id.
featuredbooleanfeatured
featured_orderbooleanfeatured_order
game_idarraygame_id
idarrayid
include_best_linesbooleanWhen true, includes BestLines relation
include_chatbooleanWhen true, includes Chats and Series.Chats relations
include_childrenbooleaninclude_children
include_templatebooleanWhen true, includes Templates relation
limitintegerMaximum number of results to return (max 100)
デフォルト: 20
liquidity_maxnumberliquidity_max
liquidity_minnumberliquidity_min
livebooleanlive
localestringlocale
offsetintegerNot allowed. Returns 422 if provided.
orderstringComma-separated list of JSON field names to order by
parent_event_idintegerparent_event_id
partner_slugstringWhen set, external_partners are attached to matching events
recurrencestringrecurrence
related_tagsbooleanrelated_tags
series_idarrayseries_id
slugarrayslug
start_date_maxstringstart_date_max
start_date_minstringstart_date_min
start_time_maxstringstart_time_max
start_time_minstringstart_time_min
tag_idarraytag_id
tag_matchstringtag_match
tag_slugstringtag_slug
title_searchstringtitle_search
volume_maxnumbervolume_max
volume_minnumbervolume_min
このAPIの保存済みサンプルレスポンスです。表示時にライブリクエストは行われません。
保存済みレスポンスはまだ公開されていません。PlaygroundでAPIを実行し、レスポンスを確認してください。
さらに探索
| API | 価格 | レスポンス |
|---|---|---|
Polymarket | $0.00044 / 回 | JSON |
Polymarket | $0.012 / 回 | JSON |
Polymarket | $0.012 / 回 | JSON |
Polymarket | $0.012 / 回 | JSON |
Polymarket | $0.012 / 回 | JSON |
Polymarket | $0.012 / 回 | JSON |
質問
Authorization ヘッダー(Bearer)に SandBase API key を指定し、パラメータを JSON ボディで送信して https://api.sandbase.ai/v1/api/polymarket/events-keyset に POST リクエストを送ります。このページの Playground で、コードを書かずに試すこともできます。
1回あたり $0.00044。各組織には UTC 日ごとに 100 回の無料呼び出しが付与され、この API を含む対象の SandBase API 全体で共有されます。それ以降は、各呼び出しが SandBase 残高からこの料金で課金されます。サブスクリプションはありません。
必須パラメータはありません。 任意: after_cursor (string), ascending (boolean), closed(any のいずれか), created_by (array), cyom (boolean) と end_date_max (string) と他 35 件。 このページの Parameters テーブルと Playground に、すべてのフィールドが一覧表示されています。
同じ HTTP リクエスト内で返される JSON レスポンスです(同期)。 このページの README にサンプルレスポンスがあります。
いいえ。Polymarket List events (keyset pagination) は SandBase 経由で動作するため、SandBase の API key 1つでこのエンドポイントと、カタログ内の他のすべての API とモデルを利用できます。Polymarket の API アクセスを別途申請する必要はありません。