You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

421 lines
11 KiB

package structure
import "time"
// InTraDay
// @Description:
type InTraDay struct {
Timestamp int `json:"timestamp"`
GmtOffset int `json:"gmtOffset"`
Datetime string `json:"datetime"`
Open float64 `json:"open"`
High float64 `json:"high"`
Low float64 `json:"low"`
Close float64 `json:"close"`
Volume int `json:"volume"`
}
// Eod
// @Description:
type Eod struct {
Date string `json:"date"`
Open float64 `json:"open"`
High float64 `json:"high"`
Low float64 `json:"low"`
Close float64 `json:"close"`
AdjustedClose float64 `json:"adjusted_close"`
Volume int `json:"volume"`
}
// Aggregates
// @Description:
type Aggregates struct {
Ticker string `json:"ticker"`
QueryCount int `json:"queryCount"`
ResultsCount int `json:"resultsCount"`
Adjusted bool `json:"adjusted"`
Results []struct {
V float64 `json:"v"`
Vw float64 `json:"vw"`
O float64 `json:"o"`
C float64 `json:"c"`
H float64 `json:"h"`
L float64 `json:"l"`
T int64 `json:"t"`
N int64 `json:"n"`
} `json:"results"`
Status string `json:"status"`
RequestID string `json:"request_id"`
Count int `json:"count"`
}
// Grouped
// @Description:
type Grouped struct {
QueryCount int `json:"queryCount"`
ResultsCount int `json:"resultsCount"`
Adjusted bool `json:"adjusted"`
Results []struct {
T string `json:"T"`
V int `json:"v"`
Vw float64 `json:"vw,omitempty"`
O float64 `json:"o"`
C float64 `json:"c"`
H float64 `json:"h"`
L float64 `json:"l"`
T0 int64 `json:"t"`
N int `json:"n,omitempty"`
} `json:"results"`
Status string `json:"status"`
RequestID string `json:"request_id"`
Count int `json:"count"`
}
// OpenClose
// @Description:
type OpenClose struct {
Status string `json:"status"`
From string `json:"from"`
Symbol string `json:"symbol"`
Open float64 `json:"open"`
High float64 `json:"high"`
Low float64 `json:"low"`
Close float64 `json:"close"`
Volume int `json:"volume"`
AfterHours float64 `json:"afterHours"`
PreMarket float64 `json:"preMarket"`
}
// PreviousClose
// @Description:
type PreviousClose struct {
Ticker string `json:"ticker"`
QueryCount int `json:"queryCount"`
ResultsCount int `json:"resultsCount"`
Adjusted bool `json:"adjusted"`
Results []struct {
T string `json:"T"`
V int `json:"v"`
Vw float64 `json:"vw"`
O float64 `json:"o"`
C float64 `json:"c"`
H float64 `json:"h"`
L float64 `json:"l"`
T0 int64 `json:"t"`
N int `json:"n"`
} `json:"results"`
Status string `json:"status"`
RequestID string `json:"request_id"`
Count int `json:"count"`
}
// Trades
// @Description:
type Trades struct {
Results []struct {
Conditions []int `json:"conditions"`
Exchange int `json:"exchange"`
ID string `json:"id"`
ParticipantTimestamp int64 `json:"participant_timestamp"`
Price float64 `json:"price"`
SequenceNumber int `json:"sequence_number"`
SipTimestamp int64 `json:"sip_timestamp"`
Size int `json:"size"`
Tape int `json:"tape"`
} `json:"results"`
Status string `json:"status"`
RequestID string `json:"request_id"`
NextURL string `json:"next_url"`
}
// LastTrade
// @Description:
type LastTrade struct {
Results struct {
T string `json:"T"`
C []int `json:"c"`
I string `json:"i"`
P float64 `json:"p"`
Q int `json:"q"`
S int `json:"s"`
T0 int64 `json:"t"`
X int `json:"x"`
Y int64 `json:"y"`
Z int `json:"z"`
} `json:"results"`
Status string `json:"status"`
RequestID string `json:"request_id"`
}
// Quotes
// @Description:
type Quotes struct {
Results []struct {
AskExchange int `json:"ask_exchange"`
AskPrice float64 `json:"ask_price"`
AskSize int `json:"ask_size"`
BidExchange int `json:"bid_exchange"`
BidPrice float64 `json:"bid_price"`
BidSize int `json:"bid_size"`
Indicators []int `json:"indicators"`
ParticipantTimestamp int64 `json:"participant_timestamp"`
SequenceNumber int `json:"sequence_number"`
SipTimestamp int64 `json:"sip_timestamp"`
Tape int `json:"tape"`
} `json:"results"`
Status string `json:"status"`
RequestID string `json:"request_id"`
NextURL string `json:"next_url"`
}
// LastQuote
// @Description:
type LastQuote struct {
Results struct {
P float64 `json:"P"`
S int `json:"S"`
T string `json:"T"`
X int `json:"X"`
I []int `json:"i"`
P0 float64 `json:"p"`
Q int `json:"q"`
S0 int `json:"s"`
T0 int64 `json:"t"`
X0 int `json:"x"`
Y int64 `json:"y"`
Z int `json:"z"`
} `json:"results"`
Status string `json:"status"`
RequestID string `json:"request_id"`
}
// SnapshotAllTickers
// @Description:
type SnapshotAllTickers struct {
Tickers []struct {
Ticker string `json:"ticker"`
TodaysChangePerc float64 `json:"todaysChangePerc"`
TodaysChange float64 `json:"todaysChange"`
Updated int64 `json:"updated"`
Day struct {
O int `json:"o"`
H int `json:"h"`
L int `json:"l"`
C int `json:"c"`
V int `json:"v"`
Vw int `json:"vw"`
} `json:"day"`
LastQuote struct {
P float64 `json:"P"`
S int `json:"S"`
P0 float64 `json:"p"`
S0 int `json:"s"`
T int64 `json:"t"`
} `json:"lastQuote"`
LastTrade struct {
C []int `json:"c"`
I string `json:"i"`
P float64 `json:"p"`
S int `json:"s"`
T int64 `json:"t"`
X int `json:"x"`
} `json:"lastTrade"`
Min struct {
Av int `json:"av"`
T int64 `json:"t"`
N int `json:"n"`
O float64 `json:"o"`
H float64 `json:"h"`
L float64 `json:"l"`
C float64 `json:"c"`
V int `json:"v"`
Vw float64 `json:"vw"`
} `json:"min"`
PrevDay struct {
O float64 `json:"o"`
H float64 `json:"h"`
L float64 `json:"l"`
C float64 `json:"c"`
V int `json:"v"`
Vw float64 `json:"vw"`
} `json:"prevDay"`
} `json:"tickers"`
Status string `json:"status"`
RequestID string `json:"request_id"`
Count int `json:"count"`
}
// SnapshotGainersLosers
// @Description:
type SnapshotGainersLosers struct {
Tickers []struct {
Ticker string `json:"ticker"`
TodaysChangePerc float64 `json:"todaysChangePerc"`
TodaysChange float64 `json:"todaysChange"`
Updated int64 `json:"updated"`
Day struct {
O int `json:"o"`
H int `json:"h"`
L int `json:"l"`
C int `json:"c"`
V int `json:"v"`
Vw int `json:"vw"`
} `json:"day"`
LastQuote struct {
P float64 `json:"P"`
S int `json:"S"`
P0 float64 `json:"p"`
S0 int `json:"s"`
T int64 `json:"t"`
} `json:"lastQuote"`
LastTrade struct {
C []int `json:"c"`
I string `json:"i"`
P float64 `json:"p"`
S int `json:"s"`
T int64 `json:"t"`
X int `json:"x"`
} `json:"lastTrade"`
Min struct {
Av int `json:"av"`
T int64 `json:"t"`
N int `json:"n"`
O float64 `json:"o"`
H float64 `json:"h"`
L float64 `json:"l"`
C float64 `json:"c"`
V int `json:"v"`
Vw float64 `json:"vw"`
} `json:"min"`
PrevDay struct {
O float64 `json:"o"`
H float64 `json:"h"`
L float64 `json:"l"`
C float64 `json:"c"`
V int `json:"v"`
Vw float64 `json:"vw"`
} `json:"prevDay"`
} `json:"tickers"`
Status string `json:"status"`
RequestID string `json:"request_id"`
}
// SnapshotOneTicker
// @Description:
type SnapshotOneTicker struct {
Ticker struct {
Ticker string `json:"ticker"`
TodaysChangePerc float64 `json:"todaysChangePerc"`
TodaysChange float64 `json:"todaysChange"`
Updated int64 `json:"updated"`
Day struct {
O int `json:"o"`
H int `json:"h"`
L int `json:"l"`
C int `json:"c"`
V int `json:"v"`
Vw int `json:"vw"`
} `json:"day"`
LastQuote struct {
P float64 `json:"P"`
S int `json:"S"`
P0 float64 `json:"p"`
S0 int `json:"s"`
T int64 `json:"t"`
} `json:"lastQuote"`
LastTrade struct {
C []int `json:"c"`
I string `json:"i"`
P float64 `json:"p"`
S int `json:"s"`
T int64 `json:"t"`
X int `json:"x"`
} `json:"lastTrade"`
Min struct {
Av int `json:"av"`
T int64 `json:"t"`
N int `json:"n"`
O float64 `json:"o"`
H float64 `json:"h"`
L float64 `json:"l"`
C float64 `json:"c"`
V int `json:"v"`
Vw float64 `json:"vw"`
} `json:"min"`
PrevDay struct {
O float64 `json:"o"`
H float64 `json:"h"`
L float64 `json:"l"`
C float64 `json:"c"`
V int `json:"v"`
Vw float64 `json:"vw"`
} `json:"prevDay"`
} `json:"ticker"`
Status string `json:"status"`
RequestID string `json:"request_id"`
}
// ReferenceTicker
// @Description:
type ReferenceTicker struct {
Results []struct {
Ticker string `json:"ticker"`
Name string `json:"name"`
Market string `json:"market"`
Locale string `json:"locale"`
PrimaryExchange string `json:"primary_exchange,omitempty"`
Type string `json:"type"`
Active bool `json:"active"`
CurrencyName string `json:"currency_name"`
Cik string `json:"cik,omitempty"`
CompositeFigi string `json:"composite_figi,omitempty"`
ShareClassFigi string `json:"share_class_figi,omitempty"`
LastUpdatedUtc time.Time `json:"last_updated_utc"`
} `json:"results"`
Status string `json:"status"`
RequestID string `json:"request_id"`
Count int `json:"count"`
NextURL string `json:"next_url"`
}
// ReferenceTickerDetails
// @Description:
type ReferenceTickerDetails struct {
RequestID string `json:"request_id"`
Results struct {
Ticker string `json:"ticker"`
Name string `json:"name"`
Market string `json:"market"`
Locale string `json:"locale"`
PrimaryExchange string `json:"primary_exchange"`
Type string `json:"type"`
Active bool `json:"active"`
CurrencyName string `json:"currency_name"`
Cik string `json:"cik"`
CompositeFigi string `json:"composite_figi"`
ShareClassFigi string `json:"share_class_figi"`
MarketCap int64 `json:"market_cap"`
PhoneNumber string `json:"phone_number"`
Address struct {
Address1 string `json:"address1"`
City string `json:"city"`
State string `json:"state"`
PostalCode string `json:"postal_code"`
} `json:"address"`
Description string `json:"description"`
SicCode string `json:"sic_code"`
SicDescription string `json:"sic_description"`
TickerRoot string `json:"ticker_root"`
HomepageURL string `json:"homepage_url"`
TotalEmployees int `json:"total_employees"`
ListDate string `json:"list_date"`
Branding struct {
LogoURL string `json:"logo_url"`
IconURL string `json:"icon_url"`
} `json:"branding"`
ShareClassSharesOutstanding int64 `json:"share_class_shares_outstanding"`
WeightedSharesOutstanding int64 `json:"weighted_shares_outstanding"`
RoundLot int `json:"round_lot"`
} `json:"results"`
Status string `json:"status"`
}