tradytics 0.0.0-stage → 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +16 -0
- package/README.md +57 -2
- package/base.d.ts +10 -0
- package/base.js +49 -0
- package/index.d.ts +39 -0
- package/index.js +43 -0
- package/package.json +35 -4
- package/resources.d.ts +199 -0
- package/resources.js +112 -0
- package/version.js +1 -0
package/LICENSE
ADDED
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 Tradytics
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated
|
|
6
|
+
documentation files (the "Software"), to deal in the Software without restriction, including without limitation the
|
|
7
|
+
rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit
|
|
8
|
+
persons to whom the Software is furnished to do so, subject to the following conditions:
|
|
9
|
+
|
|
10
|
+
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the
|
|
11
|
+
Software.
|
|
12
|
+
|
|
13
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE
|
|
14
|
+
WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
|
|
15
|
+
COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
|
|
16
|
+
OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
package/README.md
CHANGED
|
@@ -1,3 +1,58 @@
|
|
|
1
|
-
#
|
|
1
|
+
# Tradytics for JavaScript
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
The official JavaScript and TypeScript client for the [Tradytics API](https://tradytics.com/docs): live and historical options flow, dark pool prints ranked against a year, dealer gamma, delta, vanna and charm, the options market, research on every symbol, the scanner, Signals, Kalshi and Polymarket, and the AI Fund. One method per endpoint, typed, no dependencies. Node 18+, Bun, Deno and edge runtimes.
|
|
4
|
+
|
|
5
|
+
```bash
|
|
6
|
+
npm install tradytics
|
|
7
|
+
```
|
|
8
|
+
|
|
9
|
+
The API is part of Tradytics Pro. Make a key at [tradytics.com/developer/keys](https://tradytics.com/developer/keys) and export it:
|
|
10
|
+
|
|
11
|
+
```bash
|
|
12
|
+
export TRADYTICS_API_KEY="tdy_..."
|
|
13
|
+
```
|
|
14
|
+
|
|
15
|
+
## Quickstart
|
|
16
|
+
|
|
17
|
+
```js
|
|
18
|
+
import Tradytics from 'tradytics'
|
|
19
|
+
|
|
20
|
+
const client = new Tradytics() // reads TRADYTICS_API_KEY
|
|
21
|
+
|
|
22
|
+
const flow = await client.options.flow({ symbol: 'NVDA', min_premium: 1_000_000, opening: true })
|
|
23
|
+
for (const p of flow.data) console.log(p.time, p.symbol, p.type, p.strike, p.expiry, p.premium)
|
|
24
|
+
|
|
25
|
+
const bars = await client.symbols.bars('SPY', { timeframe: '5m', limit: 500 })
|
|
26
|
+
const gamma = await client.options.exposure('SPY', { greek: 'gamma' })
|
|
27
|
+
const prints = await client.darkpool.prints({ symbol: 'AAPL', min_value: 5_000_000 })
|
|
28
|
+
```
|
|
29
|
+
|
|
30
|
+
Objects come back as `{ data, as_of }`, lists as `{ data, count, next_cursor }`, the same JSON the API returns.
|
|
31
|
+
|
|
32
|
+
## Resources
|
|
33
|
+
|
|
34
|
+
`client.symbols`, `client.market`, `client.options`, `client.darkpool`, `client.research`, `client.scanner`, `client.signals`, `client.probabilities`, `client.fund` and `client.account`, one method per endpoint, with every parameter typed and described. [The docs](https://tradytics.com/docs) have every field.
|
|
35
|
+
|
|
36
|
+
## Every page
|
|
37
|
+
|
|
38
|
+
```js
|
|
39
|
+
for await (const p of client.paginate(client.options.flow_history, { symbol: 'TSLA', min_premium: 500_000 })) {
|
|
40
|
+
// ...
|
|
41
|
+
}
|
|
42
|
+
```
|
|
43
|
+
|
|
44
|
+
## New prints as they happen
|
|
45
|
+
|
|
46
|
+
```js
|
|
47
|
+
for await (const p of client.stream(client.options.flow, { min_premium: 250_000 })) {
|
|
48
|
+
console.log(p.symbol, p.type, p.strike, p.premium)
|
|
49
|
+
}
|
|
50
|
+
```
|
|
51
|
+
|
|
52
|
+
`client.stream` works with `client.options.flow` and `client.darkpool.prints`, and yields each print once.
|
|
53
|
+
|
|
54
|
+
## Errors and limits
|
|
55
|
+
|
|
56
|
+
Calls that fail throw `TradyticsError` with `status`, `code` (e.g. `missing_scope`, `invalid_parameter`), `message` and `requestId`. Rate limits (300 calls a minute, 50,000 a day per key) and brief outages are retried for you, honoring `Retry-After`. `new Tradytics({ apiKey, timeout: 30_000, maxRetries: 3 })` changes the defaults. Keep the key on a server: anyone holding it uses your quota.
|
|
57
|
+
|
|
58
|
+
Docs: [tradytics.com/docs](https://tradytics.com/docs). MCP server for Claude, ChatGPT and Cursor: [tradytics.com/docs/mcp](https://tradytics.com/docs/mcp).
|
package/base.d.ts
ADDED
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
/** An object answer: the record in `data`, when it was computed in `as_of`. */
|
|
2
|
+
export interface Item<T = any> { data: T; as_of?: string; [key: string]: unknown }
|
|
3
|
+
/** A list answer: rows in `data`; pass `next_cursor` back as `cursor` for the next page (null on the last). */
|
|
4
|
+
export interface List<T = any> { data: T[]; count: number; next_cursor: string | null; [key: string]: unknown }
|
|
5
|
+
export declare class Resource { protected constructor(transport: unknown) }
|
|
6
|
+
export declare class TradyticsError extends Error {
|
|
7
|
+
status: number
|
|
8
|
+
code: string
|
|
9
|
+
requestId?: string
|
|
10
|
+
}
|
package/base.js
ADDED
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
// The HTTP layer: one GET with the key in the header, retries on rate limits and blips, and one error type that
|
|
2
|
+
// carries the API's code, message and request id.
|
|
3
|
+
const RETRY = new Set([429, 500, 502, 503, 504])
|
|
4
|
+
const sleep = (ms) => new Promise((r) => setTimeout(r, ms))
|
|
5
|
+
|
|
6
|
+
export const enc = (v) => encodeURIComponent(String(v))
|
|
7
|
+
|
|
8
|
+
export class TradyticsError extends Error {
|
|
9
|
+
constructor(status, code, message, requestId) {
|
|
10
|
+
super(`${status} ${code}: ${message}${requestId ? ` (request ${requestId})` : ''}`)
|
|
11
|
+
Object.assign(this, { name: 'TradyticsError', status, code, requestId })
|
|
12
|
+
}
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
export class Transport {
|
|
16
|
+
constructor({ apiKey, baseUrl, timeout, maxRetries, userAgent }) {
|
|
17
|
+
Object.assign(this, { apiKey, baseUrl: baseUrl.replace(/\/$/, ''), timeout, maxRetries, userAgent })
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
async get(path, params = {}) {
|
|
21
|
+
const query = new URLSearchParams(Object.entries(params).filter(([, v]) => v !== undefined && v !== null).map(([k, v]) => [k, String(v)])).toString()
|
|
22
|
+
const url = this.baseUrl + path + (query ? `?${query}` : '')
|
|
23
|
+
const headers = { Authorization: `Bearer ${this.apiKey}`, Accept: 'application/json', ...(typeof window === 'undefined' ? { 'User-Agent': this.userAgent } : {}) }
|
|
24
|
+
for (let attempt = 0; ; attempt++) {
|
|
25
|
+
let res
|
|
26
|
+
try {
|
|
27
|
+
res = await fetch(url, { headers, signal: AbortSignal.timeout(this.timeout) })
|
|
28
|
+
} catch (e) {
|
|
29
|
+
if (attempt < this.maxRetries) { await sleep(1000 * 2 ** attempt); continue }
|
|
30
|
+
throw new TradyticsError(0, 'network_error', String(e?.message ?? e))
|
|
31
|
+
}
|
|
32
|
+
if (res.ok) return res.json()
|
|
33
|
+
const wait = Number(res.headers.get('retry-after') ?? 2 ** attempt)
|
|
34
|
+
if (RETRY.has(res.status) && attempt < this.maxRetries && wait <= 60) { await sleep(wait * 1000); continue }
|
|
35
|
+
const body = await res.json().catch(() => ({}))
|
|
36
|
+
throw new TradyticsError(res.status, body.error?.code ?? 'error', body.error?.message ?? res.statusText, body.request_id)
|
|
37
|
+
}
|
|
38
|
+
}
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
// A resource's methods come bound, so client.options.flow can be handed to paginate and stream.
|
|
42
|
+
export class Resource {
|
|
43
|
+
constructor(transport) {
|
|
44
|
+
this._t = transport
|
|
45
|
+
for (const k of Object.getOwnPropertyNames(Object.getPrototypeOf(this))) if (k !== 'constructor') this[k] = this[k].bind(this)
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
_get(path, params) { return this._t.get(path, params) }
|
|
49
|
+
}
|
package/index.d.ts
ADDED
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import type { Item, List } from './base.js'
|
|
2
|
+
import { TradyticsError } from './base.js'
|
|
3
|
+
import type { Account, Darkpool, Fund, Market, Options, Probabilities, Research, Scanner, Signals, Symbols } from './resources.js'
|
|
4
|
+
|
|
5
|
+
export type { Item, List }
|
|
6
|
+
export { TradyticsError }
|
|
7
|
+
export declare const BASE_URL: string
|
|
8
|
+
export declare const VERSION: string
|
|
9
|
+
|
|
10
|
+
export interface ClientOptions {
|
|
11
|
+
/** Defaults to the TRADYTICS_API_KEY environment variable. Make one at https://tradytics.com/developer/keys. */
|
|
12
|
+
apiKey?: string
|
|
13
|
+
baseUrl?: string
|
|
14
|
+
/** Milliseconds. Default 30000. */
|
|
15
|
+
timeout?: number
|
|
16
|
+
/** Retries on 429 and 5xx. Default 3. */
|
|
17
|
+
maxRetries?: number
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
export declare class Tradytics {
|
|
21
|
+
constructor(options?: ClientOptions)
|
|
22
|
+
symbols: Symbols
|
|
23
|
+
market: Market
|
|
24
|
+
options: Options
|
|
25
|
+
darkpool: Darkpool
|
|
26
|
+
research: Research
|
|
27
|
+
scanner: Scanner
|
|
28
|
+
signals: Signals
|
|
29
|
+
probabilities: Probabilities
|
|
30
|
+
fund: Fund
|
|
31
|
+
account: Account
|
|
32
|
+
/** Any endpoint by its path: client.get('/options/flow', { symbol: 'NVDA' }). */
|
|
33
|
+
get(path: string, params?: Record<string, unknown>): Promise<Item | List>
|
|
34
|
+
/** Every row of a list endpoint, page after page: for await (const row of client.paginate(client.options.flow, { symbol: 'SPY' })). */
|
|
35
|
+
paginate(method: (...args: any[]) => Promise<List>, ...args: any[]): AsyncGenerator<any>
|
|
36
|
+
/** New prints as they happen, each once, from client.options.flow or client.darkpool.prints. */
|
|
37
|
+
stream(method: (params?: any) => Promise<List>, filters?: Record<string, unknown>, options?: { interval?: number }): AsyncGenerator<any>
|
|
38
|
+
}
|
|
39
|
+
export default Tradytics
|
package/index.js
ADDED
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
// The client: one property per resource (client.options.flow({...}), client.symbols.bars('SPY')), and helpers to walk
|
|
2
|
+
// every page of a list and to stream new prints.
|
|
3
|
+
import { Transport, TradyticsError } from './base.js'
|
|
4
|
+
import { RESOURCES } from './resources.js'
|
|
5
|
+
import { VERSION } from './version.js'
|
|
6
|
+
|
|
7
|
+
export const BASE_URL = 'https://tradytics.com/api/public/v1'
|
|
8
|
+
export { TradyticsError, VERSION }
|
|
9
|
+
|
|
10
|
+
export class Tradytics {
|
|
11
|
+
constructor({ apiKey = globalThis.process?.env?.TRADYTICS_API_KEY, baseUrl = BASE_URL, timeout = 30_000, maxRetries = 3 } = {}) {
|
|
12
|
+
if (!apiKey) throw new TradyticsError(401, 'missing_key', 'Pass apiKey or set TRADYTICS_API_KEY. Make a key at https://tradytics.com/developer/keys.')
|
|
13
|
+
this._t = new Transport({ apiKey, baseUrl, timeout, maxRetries, userAgent: `tradytics-node/${VERSION}` })
|
|
14
|
+
for (const [name, Resource] of Object.entries(RESOURCES)) this[name] = new Resource(this._t)
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
get(path, params = {}) { return this._t.get(path, params) }
|
|
18
|
+
|
|
19
|
+
async *paginate(method, ...args) {
|
|
20
|
+
const params = { ...(typeof args.at(-1) === 'object' ? args.pop() : {}) }
|
|
21
|
+
const cursor = method.name.endsWith('bars') ? 'before' : 'cursor'
|
|
22
|
+
for (;;) {
|
|
23
|
+
const page = await method(...args, params)
|
|
24
|
+
yield* page.data ?? []
|
|
25
|
+
if (!page.next_cursor) return
|
|
26
|
+
params[cursor] = page.next_cursor
|
|
27
|
+
}
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
async *stream(method, filters = {}, { interval = 2000 } = {}) {
|
|
31
|
+
const latest = (await method({ ...filters, limit: 1 })).data ?? []
|
|
32
|
+
let last = latest[0]?.id ?? 0
|
|
33
|
+
for (;;) {
|
|
34
|
+
for (const row of (await method({ ...filters, since: last })).data ?? []) {
|
|
35
|
+
last = Math.max(last, row.id)
|
|
36
|
+
yield row
|
|
37
|
+
}
|
|
38
|
+
await new Promise((r) => setTimeout(r, interval))
|
|
39
|
+
}
|
|
40
|
+
}
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
export default Tradytics
|
package/package.json
CHANGED
|
@@ -1,6 +1,37 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "tradytics",
|
|
3
|
-
"version": "0.
|
|
4
|
-
"
|
|
5
|
-
"
|
|
6
|
-
|
|
3
|
+
"version": "0.1.0",
|
|
4
|
+
"description": "JavaScript and TypeScript client for the Tradytics API: options flow, dark pool prints, dealer exposure and market data.",
|
|
5
|
+
"type": "module",
|
|
6
|
+
"main": "./index.js",
|
|
7
|
+
"types": "./index.d.ts",
|
|
8
|
+
"exports": {
|
|
9
|
+
".": {
|
|
10
|
+
"types": "./index.d.ts",
|
|
11
|
+
"import": "./index.js"
|
|
12
|
+
}
|
|
13
|
+
},
|
|
14
|
+
"files": [
|
|
15
|
+
"*.js",
|
|
16
|
+
"*.d.ts",
|
|
17
|
+
"README.md",
|
|
18
|
+
"LICENSE"
|
|
19
|
+
],
|
|
20
|
+
"engines": {
|
|
21
|
+
"node": ">=18"
|
|
22
|
+
},
|
|
23
|
+
"sideEffects": false,
|
|
24
|
+
"license": "MIT",
|
|
25
|
+
"author": "Tradytics <hello@tradytics.com>",
|
|
26
|
+
"homepage": "https://tradytics.com/docs",
|
|
27
|
+
"keywords": [
|
|
28
|
+
"options flow",
|
|
29
|
+
"dark pool",
|
|
30
|
+
"gamma exposure",
|
|
31
|
+
"market data",
|
|
32
|
+
"stocks",
|
|
33
|
+
"trading",
|
|
34
|
+
"api",
|
|
35
|
+
"tradytics"
|
|
36
|
+
]
|
|
37
|
+
}
|
package/resources.d.ts
ADDED
|
@@ -0,0 +1,199 @@
|
|
|
1
|
+
// Generated by web/scripts/sdk.mjs from the docs content. Do not edit.
|
|
2
|
+
import type { Item, List } from './base.js'
|
|
3
|
+
import { Resource } from './base.js'
|
|
4
|
+
|
|
5
|
+
/** Symbols, quotes, bars and each symbol's news. */
|
|
6
|
+
export declare class Symbols extends Resource {
|
|
7
|
+
/** The ~6,000 symbols Tradytics tracks, most traded first. Search by ticker or name with q. GET /symbols */
|
|
8
|
+
list(params?: { /** Matches the start of a ticker or any part of a name. */ q?: string; /** stock, etf or adr. */ kind?: string; /** Rows per page, up to 1000. */ limit?: number; /** next_cursor from the previous page. */ cursor?: string }): Promise<List>
|
|
9
|
+
/** One symbol: its name, kind, sector, industry, market cap and live quote. GET /symbols/{symbol} */
|
|
10
|
+
get(symbol: string, params?: { }): Promise<Item>
|
|
11
|
+
/** Live quotes for up to 100 symbols, or for every tracked symbol (most traded first) when symbols is left out. Refreshed every 30 seconds. GET /quotes */
|
|
12
|
+
quotes(params?: { /** Comma-separated tickers, up to 100. */ symbols?: string; /** Rows per page, up to 1000. */ limit?: number; /** next_cursor from the previous page. */ cursor?: string }): Promise<List>
|
|
13
|
+
/** OHLCV bars, oldest first, with today's forming bar. Daily, weekly and monthly bars go back to 2004 for every US stock; intraday bars cover two years of the ~3,000 most traded symbols, 1-second bars the last 7 days. Intraday buckets are aligned to New York time and include extended hours. GET /symbols/{symbol}/bars */
|
|
14
|
+
bars(symbol: string, params?: { /** 1s, 1m, 5m, 15m, 30m, 1h, 4h, 1d, 1w or 1M. */ timeframe?: string; /** Only bars starting before this time, epoch seconds. Pass next_cursor here to page back. */ before?: number; /** Rows per page, up to 5000. */ limit?: number }): Promise<List>
|
|
15
|
+
/** A symbol's latest 8 stories from the last 60 days. data is a list. GET /symbols/{symbol}/news */
|
|
16
|
+
news(symbol: string, params?: { }): Promise<Item>
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
/** The market overview, news and calendars. */
|
|
20
|
+
export declare class Market extends Resource {
|
|
21
|
+
/** Fifteen benchmarks in a fixed order: S&P 500, Nasdaq 100, Russell 2000, Dow, VIX, 20Y and 10Y Treasuries, high yield, gold, silver, oil, natural gas, the dollar, Bitcoin and Ethereum (through their ETFs). GET /market/assets */
|
|
22
|
+
assets(params?: { }): Promise<Item>
|
|
23
|
+
/** How many liquid names ($20M+ traded today) are up and down, and how today's moves are spread. GET /market/breadth */
|
|
24
|
+
breadth(params?: { }): Promise<Item>
|
|
25
|
+
/** The 11 sector ETFs with returns over six periods, their best and worst large caps today and how many members are up. GET /market/sectors */
|
|
26
|
+
sectors(params?: { }): Promise<Item>
|
|
27
|
+
/** The 300 largest US stocks by sector and industry with their size and move. GET /market/heatmap */
|
|
28
|
+
heatmap(params?: { }): Promise<Item>
|
|
29
|
+
/** Two dozen investing themes (AI chips, nuclear, crypto miners …) as equal-weight baskets. GET /market/themes */
|
|
30
|
+
themes(params?: { }): Promise<Item>
|
|
31
|
+
/** Today's top 10 gainers, losers, most active and most unusual volume among stocks worth $2B+ trading $20M+. GET /market/movers */
|
|
32
|
+
movers(params?: { }): Promise<Item>
|
|
33
|
+
/** The crypto market and its top 100 coins, with the day's biggest gainers and losers. GET /market/crypto */
|
|
34
|
+
crypto(params?: { }): Promise<Item>
|
|
35
|
+
/** Up to 16 crypto categories by market cap. data is a list. GET /market/crypto/sectors */
|
|
36
|
+
crypto_sectors(params?: { }): Promise<Item>
|
|
37
|
+
/** An AI-written read of the market: what moved and why, and the week's events ahead. Rewritten every 30 minutes in the session. GET /market/digest */
|
|
38
|
+
digest(params?: { }): Promise<Item>
|
|
39
|
+
/** The day's most important stories, newest first. data is a list. GET /news */
|
|
40
|
+
news(params?: { }): Promise<Item>
|
|
41
|
+
/** Companies worth $10B+ reporting in the next 7 days, by date then size, with today's reported EPS as it comes in. GET /calendar/earnings */
|
|
42
|
+
earnings_calendar(params?: { }): Promise<Item>
|
|
43
|
+
/** The latest large open-market insider buys and sells (Form 4), and 20 days of insider money flow. GET /insiders */
|
|
44
|
+
insiders(params?: { }): Promise<Item>
|
|
45
|
+
/** The latest stock trades disclosed by members of Congress, newest disclosure first. GET /congress */
|
|
46
|
+
congress(params?: { }): Promise<Item>
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
/** Options flow, the options market and each symbol's options. */
|
|
50
|
+
export declare class Options extends Resource {
|
|
51
|
+
/** The latest session's prints as they happen, newest first, and any of the last 7 sessions with date. Pass since to poll for new prints. The response also lists the sessions held in dates. GET /options/flow */
|
|
52
|
+
flow(params?: { /** One underlying. */ symbol?: string; /** A session in the last 7, YYYY-MM-DD. Default the latest. */ date?: string; /** call or put. */ type?: string; /** sweep, block, split or single. */ kind?: string; /** bought (at or above the ask side) or sold. */ side?: string; /** Only prints of at least this premium, $. */ min_premium?: number; /** One expiration, YYYY-MM-DD. */ expiry?: string; /** Only prints larger than the open interest: new positions. */ opening?: boolean; /** Only prints after this id, oldest first (polling). */ since?: number; /** Rows per page, up to 1000. */ limit?: number; /** next_cursor from the previous page. */ cursor?: string }): Promise<List>
|
|
53
|
+
/** One symbol's prints from the archive, every session since 2025-03-31, newest first. GET /options/flow/history */
|
|
54
|
+
flow_history(params?: { /** Underlying. */ symbol: string; /** First day, YYYY-MM-DD. Default 30 days before to. */ from?: string; /** Last day. Default today. */ to?: string; /** call or put. */ type?: string; /** sweep, block, split or single. */ kind?: string; /** bought (at or above the ask side) or sold. */ side?: string; /** Only prints of at least this premium, $. */ min_premium?: number; /** One expiration, YYYY-MM-DD. */ expiry?: string; /** Only prints larger than the open interest: new positions. */ opening?: boolean; /** Rows per page, up to 1000. */ limit?: number; /** next_cursor from the previous page. */ cursor?: string }): Promise<List>
|
|
55
|
+
/** Net premium through the day: calls bought minus sold against puts bought minus sold. market is single stocks (indices left out) over 1, 3 or 5 sessions; or one of SPY, QQQ, IWM. GET /market/options/sentiment */
|
|
56
|
+
sentiment(params?: { /** market, market-3d, market-5d, SPY, QQQ or IWM. */ scope?: string }): Promise<Item>
|
|
57
|
+
/** Each session's net delta of options flow in stock-equivalent dollars, over 60 sessions, with SPY. GET /market/options/pressure */
|
|
58
|
+
pressure(params?: { }): Promise<Item>
|
|
59
|
+
/** Dealer gamma exposure by strike near spot, with the call wall, put wall and gamma flip. GET /market/options/gamma */
|
|
60
|
+
index_gamma(params?: { /** SPX, SPY or QQQ. */ symbol?: string }): Promise<Item>
|
|
61
|
+
/** Today's call and put premium, split between index products and single stocks. GET /market/options/put-call */
|
|
62
|
+
put_call(params?: { }): Promise<Item>
|
|
63
|
+
/** The 10 single stocks with the most bullish and the most bearish net premium today. GET /market/options/leaders */
|
|
64
|
+
leaders(params?: { }): Promise<Item>
|
|
65
|
+
/** Bullish and bearish premium today by sector, most bullish first. GET /market/options/sectors */
|
|
66
|
+
sectors(params?: { }): Promise<Item>
|
|
67
|
+
/** Today's 12 largest prints by premium. GET /market/options/top-prints */
|
|
68
|
+
top_prints(params?: { }): Promise<Item>
|
|
69
|
+
/** The 15 contracts with the most volume today. GET /market/options/contracts */
|
|
70
|
+
contracts(params?: { }): Promise<Item>
|
|
71
|
+
/** Liquid stocks with the highest implied volatility and the biggest IV rises and drops since the last session. GET /market/options/iv */
|
|
72
|
+
iv(params?: { }): Promise<Item>
|
|
73
|
+
/** Same-day expiring premium through the day, bought minus sold. GET /market/options/zero-dte */
|
|
74
|
+
zero_dte(params?: { /** SPY, QQQ, SPX or IWM. */ symbol?: string }): Promise<Item>
|
|
75
|
+
/** Dealer gamma from today's same-day expiring prints by strike, updated every 30 seconds. GET /market/options/zero-dte/gamma */
|
|
76
|
+
zero_dte_gamma(params?: { /** SPX, SPY or QQQ. */ symbol?: string }): Promise<Item>
|
|
77
|
+
/** The Options page's read of the day: the lean against the last 20 sessions at the same minute, notes, SPY's expected move, dealer gamma and hedging. GET /market/options/read */
|
|
78
|
+
read(params?: { }): Promise<Item>
|
|
79
|
+
/** Single stocks with today's largest net premium against their own usual day, and the same by sector. GET /market/options/bets */
|
|
80
|
+
bets(params?: { }): Promise<Item>
|
|
81
|
+
/** Today's biggest single-stock prints that opened new positions ($250K+, size above open interest, no spreads). GET /market/options/unusual */
|
|
82
|
+
unusual(params?: { }): Promise<Item>
|
|
83
|
+
/** Today's contracts in four lists: most active, cheap (under $1), LEAPs (a year+) and far out of the money. GET /market/options/chains */
|
|
84
|
+
chains(params?: { }): Promise<Item>
|
|
85
|
+
/** What the flow lab proved, computed live every 5 minutes: likely ranges for SPY and QQQ, the gamma regime, IV against realized, the 0DTE share and big-move odds. GET /market/options/evidence */
|
|
86
|
+
evidence(params?: { }): Promise<Item>
|
|
87
|
+
/** Today at a glance from prints of $25K+. GET /symbols/{symbol}/options */
|
|
88
|
+
overview(symbol: string, params?: { }): Promise<Item>
|
|
89
|
+
/** Bullish and bearish premium through today against the price. GET /symbols/{symbol}/options/flow */
|
|
90
|
+
net_flow(symbol: string, params?: { }): Promise<Item>
|
|
91
|
+
/** Dealer gamma by strike near spot with the call wall, put wall and gamma flip. 404 for symbols without dealer data. GET /symbols/{symbol}/options/gamma */
|
|
92
|
+
gamma(symbol: string, params?: { }): Promise<Item>
|
|
93
|
+
/** The at-the-money term structure and the front expiry's smile. GET /symbols/{symbol}/options/volatility */
|
|
94
|
+
volatility(symbol: string, params?: { }): Promise<Item>
|
|
95
|
+
/** Call and put open interest by strike near spot, for all expiries or one. GET /symbols/{symbol}/options/open-interest */
|
|
96
|
+
open_interest(symbol: string, params?: { /** One expiry, YYYY-MM-DD (from expiries). Default all. */ expiry?: string }): Promise<Item>
|
|
97
|
+
/** Net premium on the 6 busiest strikes by the 6 busiest expiries, today and over the last 5 sessions. GET /symbols/{symbol}/options/expiries */
|
|
98
|
+
expiries(symbol: string, params?: { }): Promise<Item>
|
|
99
|
+
/** Today's 12 largest orders and 12 most unusual contracts (volume far above open interest). GET /symbols/{symbol}/options/orders */
|
|
100
|
+
orders(symbol: string, params?: { }): Promise<Item>
|
|
101
|
+
/** The last 30 sessions of premium, oldest first. GET /symbols/{symbol}/options/history */
|
|
102
|
+
history(symbol: string, params?: { }): Promise<Item>
|
|
103
|
+
/** Dealer gamma, delta, vanna or charm by strike for about 2,500 stocks and ETFs, recomputed every five minutes, with each strike's change since the session before, a week and two weeks back. GET /symbols/{symbol}/options/exposure */
|
|
104
|
+
exposure(symbol: string, params?: { /** gamma, delta, vanna or charm. */ greek?: string; /** One expiry, YYYY-MM-DD. Default all. */ expiry?: string }): Promise<Item>
|
|
105
|
+
/** About 18 months of daily dealer net delta and net gamma against the close, oldest first. GET /symbols/{symbol}/options/exposure/history */
|
|
106
|
+
exposure_history(symbol: string, params?: { /** First day, YYYY-MM-DD. */ from?: string; /** Last day, YYYY-MM-DD. */ to?: string }): Promise<Item>
|
|
107
|
+
}
|
|
108
|
+
|
|
109
|
+
/** Dark pool prints, history, levels and ranks. */
|
|
110
|
+
export declare class Darkpool extends Resource {
|
|
111
|
+
/** The latest session's prints as they happen, newest first, and any of the last 10 sessions with date. Pass since to poll. GET /darkpool/prints */
|
|
112
|
+
prints(params?: { /** One ticker. */ symbol?: string; /** A session in the last 10, YYYY-MM-DD. */ date?: string; /** dark (off-exchange) or lit (exchange blocks). */ venue?: string; /** Only prints worth at least this, $. */ min_value?: number; /** Only prints after this id, oldest first. */ since?: number; /** Rows per page, up to 1000. */ limit?: number; /** next_cursor from the previous page. */ cursor?: string }): Promise<List>
|
|
113
|
+
/** One symbol's prints from the archive, every session since 2025-06-09, newest first. GET /darkpool/history */
|
|
114
|
+
history(params?: { /** Ticker. */ symbol: string; /** First day. Default 30 days before to. */ from?: string; /** Last day. Default today. */ to?: string; /** dark or lit. */ venue?: string; /** Minimum value, $. */ min_value?: number; /** Rows per page, up to 1000. */ limit?: number; /** next_cursor from the previous page. */ cursor?: string }): Promise<List>
|
|
115
|
+
/** The price levels with the most dark pool money over the last 10 sessions, and 30 sessions of daily totals. GET /symbols/{symbol}/darkpool */
|
|
116
|
+
levels(symbol: string, params?: { }): Promise<Item>
|
|
117
|
+
/** A year of one stock's prints, each ranked against every print of the same kind in its last 12 months (1 is the largest in a year). Prints are reported after they happen. GET /symbols/{symbol}/darkpool/ranked */
|
|
118
|
+
ranked(symbol: string, params?: { /** trade (block trades), close or open (the auctions). */ kind?: string; /** big (largest first) or new. */ sort?: string; /** Rows per page, up to 200. */ limit?: number; /** next_cursor from the previous page. */ cursor?: string }): Promise<List>
|
|
119
|
+
}
|
|
120
|
+
|
|
121
|
+
/** Each symbol's fundamentals, analysts and technicals. */
|
|
122
|
+
export declare class Research extends Resource {
|
|
123
|
+
/** Quote, returns, valuation, margins, short interest and the company profile. GET /symbols/{symbol}/summary */
|
|
124
|
+
summary(symbol: string, params?: { }): Promise<Item>
|
|
125
|
+
/** Ratings from each firm's latest call in the last year, price targets from the last six months, and recent actions. GET /symbols/{symbol}/analysts */
|
|
126
|
+
analysts(symbol: string, params?: { }): Promise<Item>
|
|
127
|
+
/** The last 8 quarters against estimates, the beat record and the next report. GET /symbols/{symbol}/earnings */
|
|
128
|
+
earnings(symbol: string, params?: { }): Promise<Item>
|
|
129
|
+
/** Twelve quarters and six fiscal years of the income statement, with cash flow. GET /symbols/{symbol}/financials */
|
|
130
|
+
financials(symbol: string, params?: { }): Promise<Item>
|
|
131
|
+
/** An overall technical rating with the signals, moving averages and oscillators behind it, and monthly seasonality. GET /symbols/{symbol}/technicals */
|
|
132
|
+
technicals(symbol: string, params?: { }): Promise<Item>
|
|
133
|
+
/** Recent insider buys and sells, short interest history, float and institutional ownership. GET /symbols/{symbol}/ownership */
|
|
134
|
+
ownership(symbol: string, params?: { }): Promise<Item>
|
|
135
|
+
/** An ETF's sector weights, top 10 holdings and facts. GET /symbols/{symbol}/holdings */
|
|
136
|
+
holdings(symbol: string, params?: { }): Promise<Item>
|
|
137
|
+
}
|
|
138
|
+
|
|
139
|
+
/** The full-market scanner. */
|
|
140
|
+
export declare class Scanner extends Resource {
|
|
141
|
+
/** Filter on any numeric field with min_<field> and max_<field> (e.g. min_rvol=2&max_rsi=30), require labels, and sort by any field. GET /scanner */
|
|
142
|
+
scan(params?: { /** Comma-separated fields to return. Default a compact set. */ fields?: string; /** Comma-separated label ids; a row must carry all of them. */ labels?: string; /** One sector, e.g. Technology. */ sector?: string; /** stock, etf or adr. */ kind?: string; /** Field to sort by. */ sort?: string; /** asc or desc. */ order?: string; /** Rows per page, up to 1000. */ limit?: number; /** next_cursor from the previous page. */ cursor?: string; [filter: string]: string | number | boolean | undefined }): Promise<List>
|
|
143
|
+
/** Every field name, and every label with its group and lean. GET /scanner/fields */
|
|
144
|
+
fields(params?: { }): Promise<Item>
|
|
145
|
+
/** One symbol's full scanner row. GET /symbols/{symbol}/scan */
|
|
146
|
+
symbol(symbol: string, params?: { }): Promise<Item>
|
|
147
|
+
}
|
|
148
|
+
|
|
149
|
+
/** Live orders matching tested flow patterns. */
|
|
150
|
+
export declare class Signals extends Resource {
|
|
151
|
+
/** Signals newest first, today's live. GET /signals */
|
|
152
|
+
list(params?: { /** One pattern: repeat-flow, opening-calls, heavy-calls, etf-repeat-calls, itm-puts, burst-calls, index-tide-calls. */ source?: string; /** One ticker. */ symbol?: string; /** open or settled. */ status?: string; /** Fired on this day, YYYY-MM-DD. */ date?: string; /** Rows per page, up to 100. */ limit?: number; /** next_cursor from the previous page. */ cursor?: string }): Promise<List>
|
|
153
|
+
/** One signal with the prints behind it and every mark. GET /signals/{id} */
|
|
154
|
+
get(id: number, params?: { }): Promise<Item>
|
|
155
|
+
}
|
|
156
|
+
|
|
157
|
+
/** Kalshi and Polymarket finance questions. */
|
|
158
|
+
export declare class Probabilities extends Resource {
|
|
159
|
+
/** Every live question the board shows (books no wider than 10 cents, active in the last day), with its leading outcomes. GET /probabilities */
|
|
160
|
+
list(params?: { /** close, range, hit or earnings. */ group?: string; /** One underlying, e.g. SPX, NDX, NVDA. */ symbol?: string }): Promise<List>
|
|
161
|
+
/** One question with every outcome, and for earnings questions the stock's past report-day moves. GET /probabilities/{id} */
|
|
162
|
+
get(id: string, params?: { }): Promise<Item>
|
|
163
|
+
/** One outcome's chance through time, live or settled: the last trade's price in each hour or day. GET /probabilities/markets/{market}/history */
|
|
164
|
+
history(market: string, params?: { /** hour or day. */ interval?: string; /** First day, YYYY-MM-DD. */ from?: string; /** Last day, YYYY-MM-DD. */ to?: string }): Promise<Item>
|
|
165
|
+
/** Where Kalshi and Polymarket put the S&P 500 at each date they price, from the next close to year end. GET /probabilities/outlook */
|
|
166
|
+
outlook(params?: { }): Promise<Item>
|
|
167
|
+
/** The S&P 500's and Nasdaq-100's last 30 sessions: where the crowd put the close at 10 AM against where it closed. GET /probabilities/track */
|
|
168
|
+
track(params?: { }): Promise<Item>
|
|
169
|
+
/** Every finance market Kalshi has settled since June 2021, and Polymarket's, the latest to close first. GET /probabilities/settled */
|
|
170
|
+
settled(params?: { /** kalshi or polymarket. */ source?: string; /** Kalshi series (e.g. KXINXU, the S&P 500 close) or Polymarket event id. */ series?: string; /** Kalshi category (Financials, Economics, Crypto) or Polymarket tag (stocks, economy, fed). */ category?: string; /** Closed on or after, YYYY-MM-DD. Default 30 days back unless series is set. */ from?: string; /** Closed on or before, YYYY-MM-DD. */ to?: string; /** Rows per page, up to 1000. */ limit?: number; /** next_cursor from the previous page. */ cursor?: string }): Promise<List>
|
|
171
|
+
}
|
|
172
|
+
|
|
173
|
+
/** The Tradytics AI Fund. */
|
|
174
|
+
export declare class Fund extends Resource {
|
|
175
|
+
/** Exposure, open positions and the latest posts. GET /fund */
|
|
176
|
+
summary(params?: { }): Promise<Item>
|
|
177
|
+
/** Every trade, open and closed, newest first. GET /fund/trades */
|
|
178
|
+
trades(params?: { /** open or closed. */ status?: string; /** One ticker. */ symbol?: string; /** Rows per page, up to 200. */ limit?: number; /** next_cursor from the previous page. */ cursor?: string }): Promise<List>
|
|
179
|
+
/** The portfolio manager's posts (one per trade, add, trim or close) and weekly letters, newest first. GET /fund/posts */
|
|
180
|
+
posts(params?: { /** post or letter. */ kind?: string; /** Rows per page, up to 100. */ limit?: number; /** next_cursor from the previous page. */ cursor?: string }): Promise<List>
|
|
181
|
+
}
|
|
182
|
+
|
|
183
|
+
/** Your own backtests, portfolio and dashboards. */
|
|
184
|
+
export declare class Account extends Resource {
|
|
185
|
+
/** Your backtests, the latest first. GET /backtests */
|
|
186
|
+
backtests(params?: { /** Only backtests whose title or messages mention this. */ q?: string; /** Rows per page, up to 200. */ limit?: number }): Promise<List>
|
|
187
|
+
/** One backtest: the conversation and every run it made. GET /backtests/{id} */
|
|
188
|
+
backtest(id: number, params?: { }): Promise<Item>
|
|
189
|
+
/** Your linked brokerage accounts, read-only: holdings, options and recent orders. GET /portfolio */
|
|
190
|
+
portfolio(params?: { }): Promise<Item>
|
|
191
|
+
/** A year of closed round trips, newest first, with dividends and fees. GET /portfolio/trades */
|
|
192
|
+
portfolio_trades(params?: { }): Promise<Item>
|
|
193
|
+
/** Risk by source, beta, value at risk and tracking error, and returns split into market, sectors, styles and stock picking. 404 not_connected before a brokerage is linked. GET /portfolio/factors */
|
|
194
|
+
portfolio_factors(params?: { }): Promise<Item>
|
|
195
|
+
/** Your dashboards. GET /dashboards */
|
|
196
|
+
dashboards(params?: { }): Promise<List>
|
|
197
|
+
/** One dashboard's layout. GET /dashboards/{id} */
|
|
198
|
+
dashboard(id: number, params?: { }): Promise<Item>
|
|
199
|
+
}
|
package/resources.js
ADDED
|
@@ -0,0 +1,112 @@
|
|
|
1
|
+
// Generated by web/scripts/sdk.mjs from the docs content. Do not edit.
|
|
2
|
+
import { Resource, enc } from './base.js'
|
|
3
|
+
|
|
4
|
+
export class Symbols extends Resource {
|
|
5
|
+
list(params = {}) { return this._get('/symbols', params) }
|
|
6
|
+
get(symbol, params = {}) { return this._get(`/symbols/${enc(symbol)}`, params) }
|
|
7
|
+
quotes(params = {}) { return this._get('/quotes', params) }
|
|
8
|
+
bars(symbol, params = {}) { return this._get(`/symbols/${enc(symbol)}/bars`, params) }
|
|
9
|
+
news(symbol, params = {}) { return this._get(`/symbols/${enc(symbol)}/news`, params) }
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
export class Market extends Resource {
|
|
13
|
+
assets(params = {}) { return this._get('/market/assets', params) }
|
|
14
|
+
breadth(params = {}) { return this._get('/market/breadth', params) }
|
|
15
|
+
sectors(params = {}) { return this._get('/market/sectors', params) }
|
|
16
|
+
heatmap(params = {}) { return this._get('/market/heatmap', params) }
|
|
17
|
+
themes(params = {}) { return this._get('/market/themes', params) }
|
|
18
|
+
movers(params = {}) { return this._get('/market/movers', params) }
|
|
19
|
+
crypto(params = {}) { return this._get('/market/crypto', params) }
|
|
20
|
+
crypto_sectors(params = {}) { return this._get('/market/crypto/sectors', params) }
|
|
21
|
+
digest(params = {}) { return this._get('/market/digest', params) }
|
|
22
|
+
news(params = {}) { return this._get('/news', params) }
|
|
23
|
+
earnings_calendar(params = {}) { return this._get('/calendar/earnings', params) }
|
|
24
|
+
insiders(params = {}) { return this._get('/insiders', params) }
|
|
25
|
+
congress(params = {}) { return this._get('/congress', params) }
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
export class Options extends Resource {
|
|
29
|
+
flow(params = {}) { return this._get('/options/flow', params) }
|
|
30
|
+
flow_history(params = {}) { return this._get('/options/flow/history', params) }
|
|
31
|
+
sentiment(params = {}) { return this._get('/market/options/sentiment', params) }
|
|
32
|
+
pressure(params = {}) { return this._get('/market/options/pressure', params) }
|
|
33
|
+
index_gamma(params = {}) { return this._get('/market/options/gamma', params) }
|
|
34
|
+
put_call(params = {}) { return this._get('/market/options/put-call', params) }
|
|
35
|
+
leaders(params = {}) { return this._get('/market/options/leaders', params) }
|
|
36
|
+
sectors(params = {}) { return this._get('/market/options/sectors', params) }
|
|
37
|
+
top_prints(params = {}) { return this._get('/market/options/top-prints', params) }
|
|
38
|
+
contracts(params = {}) { return this._get('/market/options/contracts', params) }
|
|
39
|
+
iv(params = {}) { return this._get('/market/options/iv', params) }
|
|
40
|
+
zero_dte(params = {}) { return this._get('/market/options/zero-dte', params) }
|
|
41
|
+
zero_dte_gamma(params = {}) { return this._get('/market/options/zero-dte/gamma', params) }
|
|
42
|
+
read(params = {}) { return this._get('/market/options/read', params) }
|
|
43
|
+
bets(params = {}) { return this._get('/market/options/bets', params) }
|
|
44
|
+
unusual(params = {}) { return this._get('/market/options/unusual', params) }
|
|
45
|
+
chains(params = {}) { return this._get('/market/options/chains', params) }
|
|
46
|
+
evidence(params = {}) { return this._get('/market/options/evidence', params) }
|
|
47
|
+
overview(symbol, params = {}) { return this._get(`/symbols/${enc(symbol)}/options`, params) }
|
|
48
|
+
net_flow(symbol, params = {}) { return this._get(`/symbols/${enc(symbol)}/options/flow`, params) }
|
|
49
|
+
gamma(symbol, params = {}) { return this._get(`/symbols/${enc(symbol)}/options/gamma`, params) }
|
|
50
|
+
volatility(symbol, params = {}) { return this._get(`/symbols/${enc(symbol)}/options/volatility`, params) }
|
|
51
|
+
open_interest(symbol, params = {}) { return this._get(`/symbols/${enc(symbol)}/options/open-interest`, params) }
|
|
52
|
+
expiries(symbol, params = {}) { return this._get(`/symbols/${enc(symbol)}/options/expiries`, params) }
|
|
53
|
+
orders(symbol, params = {}) { return this._get(`/symbols/${enc(symbol)}/options/orders`, params) }
|
|
54
|
+
history(symbol, params = {}) { return this._get(`/symbols/${enc(symbol)}/options/history`, params) }
|
|
55
|
+
exposure(symbol, params = {}) { return this._get(`/symbols/${enc(symbol)}/options/exposure`, params) }
|
|
56
|
+
exposure_history(symbol, params = {}) { return this._get(`/symbols/${enc(symbol)}/options/exposure/history`, params) }
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
export class Darkpool extends Resource {
|
|
60
|
+
prints(params = {}) { return this._get('/darkpool/prints', params) }
|
|
61
|
+
history(params = {}) { return this._get('/darkpool/history', params) }
|
|
62
|
+
levels(symbol, params = {}) { return this._get(`/symbols/${enc(symbol)}/darkpool`, params) }
|
|
63
|
+
ranked(symbol, params = {}) { return this._get(`/symbols/${enc(symbol)}/darkpool/ranked`, params) }
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
export class Research extends Resource {
|
|
67
|
+
summary(symbol, params = {}) { return this._get(`/symbols/${enc(symbol)}/summary`, params) }
|
|
68
|
+
analysts(symbol, params = {}) { return this._get(`/symbols/${enc(symbol)}/analysts`, params) }
|
|
69
|
+
earnings(symbol, params = {}) { return this._get(`/symbols/${enc(symbol)}/earnings`, params) }
|
|
70
|
+
financials(symbol, params = {}) { return this._get(`/symbols/${enc(symbol)}/financials`, params) }
|
|
71
|
+
technicals(symbol, params = {}) { return this._get(`/symbols/${enc(symbol)}/technicals`, params) }
|
|
72
|
+
ownership(symbol, params = {}) { return this._get(`/symbols/${enc(symbol)}/ownership`, params) }
|
|
73
|
+
holdings(symbol, params = {}) { return this._get(`/symbols/${enc(symbol)}/holdings`, params) }
|
|
74
|
+
}
|
|
75
|
+
|
|
76
|
+
export class Scanner extends Resource {
|
|
77
|
+
scan(params = {}) { return this._get('/scanner', params) }
|
|
78
|
+
fields(params = {}) { return this._get('/scanner/fields', params) }
|
|
79
|
+
symbol(symbol, params = {}) { return this._get(`/symbols/${enc(symbol)}/scan`, params) }
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
export class Signals extends Resource {
|
|
83
|
+
list(params = {}) { return this._get('/signals', params) }
|
|
84
|
+
get(id, params = {}) { return this._get(`/signals/${enc(id)}`, params) }
|
|
85
|
+
}
|
|
86
|
+
|
|
87
|
+
export class Probabilities extends Resource {
|
|
88
|
+
list(params = {}) { return this._get('/probabilities', params) }
|
|
89
|
+
get(id, params = {}) { return this._get(`/probabilities/${enc(id)}`, params) }
|
|
90
|
+
history(market, params = {}) { return this._get(`/probabilities/markets/${enc(market)}/history`, params) }
|
|
91
|
+
outlook(params = {}) { return this._get('/probabilities/outlook', params) }
|
|
92
|
+
track(params = {}) { return this._get('/probabilities/track', params) }
|
|
93
|
+
settled(params = {}) { return this._get('/probabilities/settled', params) }
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
export class Fund extends Resource {
|
|
97
|
+
summary(params = {}) { return this._get('/fund', params) }
|
|
98
|
+
trades(params = {}) { return this._get('/fund/trades', params) }
|
|
99
|
+
posts(params = {}) { return this._get('/fund/posts', params) }
|
|
100
|
+
}
|
|
101
|
+
|
|
102
|
+
export class Account extends Resource {
|
|
103
|
+
backtests(params = {}) { return this._get('/backtests', params) }
|
|
104
|
+
backtest(id, params = {}) { return this._get(`/backtests/${enc(id)}`, params) }
|
|
105
|
+
portfolio(params = {}) { return this._get('/portfolio', params) }
|
|
106
|
+
portfolio_trades(params = {}) { return this._get('/portfolio/trades', params) }
|
|
107
|
+
portfolio_factors(params = {}) { return this._get('/portfolio/factors', params) }
|
|
108
|
+
dashboards(params = {}) { return this._get('/dashboards', params) }
|
|
109
|
+
dashboard(id, params = {}) { return this._get(`/dashboards/${enc(id)}`, params) }
|
|
110
|
+
}
|
|
111
|
+
|
|
112
|
+
export const RESOURCES = { symbols: Symbols, market: Market, options: Options, darkpool: Darkpool, research: Research, scanner: Scanner, signals: Signals, probabilities: Probabilities, fund: Fund, account: Account }
|
package/version.js
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export const VERSION = '0.1.0'
|