List the markets the API key's user can see
GET
/v1/results/accounts/presence/marketsAnswers with each market's marketId, which other Presence queries take to read one market. It does not change, so read it once and keep it.
Someone who can see only some of the account's markets gets only those. Presence says what a market is.
Request
curl "https://api.eu.silktide.com/v1/results/accounts/presence/markets" \
-H "Authorization: silktide token=$SILKTIDE_API_KEY"Response: Every market
{
"result": {
"markets": [
{
"marketId": 3,
"name": "United States",
"created": 1790000000,
"updated": 1793610000
},
{
"marketId": 5,
"name": "France",
"created": 1790000000,
"updated": 1793610000
}
]
},
"selector": "/v1/results/accounts/presence/markets",
"duration": 0.01
}Request
Query parameters
Response
200JSON.
resultobjectrequiredThe answer.
Show 1 fieldsHide fields
marketslist of objectsrequiredThe markets. Empty when the account has not set up Presence, or the user can see none.
Show 4 fieldsHide fields
marketIdintegerrequiredat least 1The market, as other Presence queries take it in
marketId.namestringrequiredIts name.
createdintegerrequiredWhen it was created.
updatedintegerrequiredWhen it was last changed.
selectorstringrequiredThe query that answered, as its path:
/v1/results/scores.durationnumberrequiredSeconds Silktide took to answer.
Errors
| Status | Type | When |
|---|---|---|
| 200 | EditionNotAvailable | The account does not have Silktide 5. Its status is 403. The body is an error despite the status. |
| 401 | NotLoggedIn | No API key was sent, or it is not a key for this region.(any operation) |
| 429 | TooManyRequests | Too many requests to this path in five seconds. Retry after the number of seconds in the Retry-After header, which properties.retryAfter repeats.(any operation) |
| 503 | - | Silktide is busy. Retry after the number of seconds in the Retry-After header.(any operation) |
Every error has the same body. See Errors.
Access
- Permission
- Can see this market
- Plan feature
- None
- Edition
- Silktide 5 only
- Cost
- Free
- Available since
- v1.2.0
Try it
Sends a real request to your account from this browser. Your key stays in this tab and goes only to the Silktide API.