fmp

package module
v1.1.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 29, 2026 License: MIT Imports: 20 Imported by: 0

README

Go SDK

The Go module is a pure Go client for the Financial Modeling Prep API. It mirrors the Rust crate libfmp one-for-one: the same client options, the same authentication modes, the same error categories, and the same transport rules. Endpoint models and methods are generated from the Rust contract by cargo run -p fmp-py-gen --bin gen_go, so the two SDKs decode the same fixtures; the generated files carry a DO NOT EDIT header. It requires Go 1.27 or later and builds with CGO_ENABLED=0; there is no cgo and no native library. The design is recorded in ADR 0030.

Installation

The module path ends in go, so import it with an alias:

import fmp "github.com/bitbrew-dev/libfmp/sdk/go"

The Go module shares the libfmp workspace version: every release tags sdk/go/vX.Y.Z at the release commit (the tag carries the subdirectory prefix that Go requires for a nested module, while the module version stays vX.Y.Z), so install a release with:

go get github.com/bitbrew-dev/libfmp/sdk/go@vX.Y.Z

While this repository is private, the public module proxy cannot serve the module, so tell Go to fetch it directly: set GOPRIVATE=github.com/bitbrew-dev/* (which also disables the checksum database for that path) and give git credentials for github.com: a token over https as below, or ssh with git config --global url."git@github.com:".insteadOf "https://github.com/". With that environment go get clones the repository directly, and go list -m -versions needs the same environment:

export GOPRIVATE='github.com/bitbrew-dev/*'
git config --global url."https://x-access-token:TOKEN@github.com/".insteadOf "https://github.com/"
go get github.com/bitbrew-dev/libfmp/sdk/go@vX.Y.Z

Because the version is shared, a feat(sdk/go) commit minor-bumps the workspace and republishes libfmp and fmp-py with no Rust change; ADR 0030 accepts that consequence. Every release tags sdk/go/vX.Y.Z. Check which versions have been published with:

go list -m -versions github.com/bitbrew-dev/libfmp/sdk/go

Building a client

NewClient validates every option before any request is made. Direct access to the FMP origin requires explicit authentication; the client never reads the environment on its own, so opt in with FMPHeaderFromEnv:

auth, ok := fmp.FMPHeaderFromEnv()
if !ok {
	return errors.New("FMP_API_KEY is not set")
}
client, err := fmp.NewClient(
	fmp.WithAuthentication(auth),
	fmp.WithTimeout(20*time.Second),
)
if err != nil {
	return err
}

Header modes (FMPHeader, Bearer, CustomHeader, CustomHeaderWithPrefix) never place a credential in the URL. Query modes (FMPQuery, CustomQuery) append the secret as the last query pair of every request. WithBaseURL and WithPathPrefix route the client through a proxy; WithHTTPClient injects a caller-owned *http.Client for tests and custom transports.

CustomHeaderWithPrefix(name, prefix, secret) places non-secret text immediately before the secret, byte for byte: no separator is inserted, so a "Bearer " prefix carries its own trailing space. It mirrors the Rust Authentication::custom_header(name, Some(prefix), secret) form; an empty prefix is the same value as CustomHeader. Only the secret is redacted from diagnostics, never the prefix, and formatting the value reports has_prefix without the prefix text. A custom router or proxy that expects X-Proxy-Token: Bearer <token> is configured like this (the same shape as the Rust crate's live proxy test: the path prefix defaults to router/stable and X-Tenant is sent only when FMP_TENANT is set, since an empty default header value is accepted and sent as an empty field):

pathPrefix := os.Getenv("FMP_PROXY_PATH_PREFIX")
if pathPrefix == "" {
	pathPrefix = "router/stable"
}
opts := []fmp.Option{
	fmp.WithBaseURL(os.Getenv("FMP_PROXY_BASE_URL")),
	fmp.WithPathPrefix(pathPrefix),
	fmp.WithAuthentication(fmp.CustomHeaderWithPrefix(
		"X-Proxy-Token", "Bearer ", os.Getenv("FMP_PROXY_TOKEN"),
	)),
}
if tenant := os.Getenv("FMP_TENANT"); tenant != "" {
	opts = append(opts, fmp.WithDefaultHeader("X-Tenant", tenant))
}
client, err := fmp.NewClient(opts...)
if err != nil {
	return err
}

The environment names match the Rust crate's live opt-in tests:

Variable Read by
FMP_API_KEY FMPHeaderFromEnv and APIKeyFromEnv
FMP_LIVE_TESTS live tests (live_test.go), which run only when it is 1
FMP_PROXY_BASE_URL, FMP_PROXY_TOKEN, FMP_PROXY_PATH_PREFIX, FMP_TENANT live tests against a proxy

Names

Endpoint methods, query types, and models are generated from the same registry as the Rust and Python SDKs, so each endpoint has one name in all three (ADR 0032). Go spells initialisms in all caps, generated and hand-written alike:

Group Initialisms
Web and data ID, UID, URL, JSON, API, HTTP
Provider and regulators FMP, SEC, US, COT
Instruments and identifiers ETF, CIK, CUSIP, ISIN, IPO, SP500
Metrics ESG, DCF, EPS, TTM
Form names 8K, 13F

So the Python sec_filings.latest_8k is client.SECFilings.Latest8K, statements.metrics.key_metrics_ttm returns []fmp.KeyMetricsTTM, and the namespaces are TipRanks, DCF, ESG, and SECFilings. Struct tags keep the wire names (json:"cik").

Errors

Every client operation returns a *fmp.Error. Use errors.As rather than a type assertion so wrapped errors still match:

client, err := fmp.NewClient()
var fmpErr *fmp.Error
if errors.As(err, &fmpErr) {
	switch fmpErr.Category {
	case fmp.CategoryConfiguration:
		log.Printf("configuration rejected: %v", fmpErr)
	case fmp.CategoryStatus:
		log.Printf("endpoint %s returned %d: %s", fmpErr.Endpoint, fmpErr.Status, fmpErr.Body)
	default:
		log.Printf("%s: %v", fmpErr.Category, fmpErr)
	}
}

Category is one of Validation, Configuration, Transport, Status, or Decode. Endpoint is a logical endpoint id, never a URL. Body is the provider body, redacted and capped. A Decode error also carries Path, the JSON pointer of the failing member (/37/beta), and DecodeKind, the coarse reason (DecodeKindNull, DecodeKindWrongType, ...); neither ever includes the member value. The client never retries, wraps every transport failure before it escapes, and formats Authentication, Client, and Error without any secret value, so an error is safe to log.

Endpoint metadata

Every endpoint method whose Rust descriptor attaches advisory metadata has an entry in the generated metadata_table.go, keyed by the Go call path without the client (Quote.Full, Statements.Growth.Income):

metadata, ok := fmp.EndpointMetadataFor("TipRanks.SearchRatings")
if ok {
	log.Printf("access %s, plan %s, bounds %s", metadata.Access, metadata.ConditionalPlan, metadata.Bounds)
	if metadata.Bounds.Limit != nil && limit > *metadata.Bounds.Limit {
		limit = *metadata.Bounds.Limit
	}
}

EndpointMetadata mirrors the Rust type one-for-one (Geography, Access, ConditionalPlan, Realtime, Bounds), every zero value means unspecified, and each type has a short String() that is safe to log. The lookup reports false with the zero value for a method without metadata and for an unknown key. The metadata is advisory: the client never validates a request against it, exactly as the Rust crate does not.

Examples

Two runnable programs and the package's godoc examples all run offline against an in-process TLS server with placeholder credentials: examples/quote fetches one detailed quote, examples/proxy routes through a proxy with a path prefix, a tenant header, and a proxy token, and example_client_test.go and example_error_test.go hold the Example* functions shown on pkg.go.dev (cd sdk/go && go test -run Example ./...).

Checks

Run the full gate from the repository root:

bash scripts/check_go_sdk.sh

It pins Go 1.27.1 and golangci-lint v2, then runs gofmt, go vet, golangci-lint run, go test -race -count=1, and every example under sdk/go/examples/, all with CGO_ENABLED=0. The lint set lives in .golangci.yml next to this file. The same script backs the go-sdk-tests pre-commit hook, which is scoped by files: so Rust-only commits do not pay for Go checks, and the go-sdk.yml workflow, which runs on Ubuntu and macOS for changes under sdk/go/. Run the hook by hand with:

prek run go-sdk-tests --all-files
Live tests

The opt-in live tests mirror crates/libfmp/tests/live_opt_in.rs and skip unless FMP_LIVE_TESTS is 1 (after trimming), so the gate above never opens a socket. Run them by hand from sdk/go:

FMP_LIVE_TESTS=1 FMP_API_KEY=... go test -run 'TestLive' -count=1 ./...

The proxy test needs FMP_PROXY_BASE_URL and FMP_PROXY_TOKEN (sent as X-Proxy-Token: Bearer <token>); FMP_PROXY_PATH_PREFIX overrides the router/stable prefix and FMP_TENANT adds an X-Tenant header. A test skips naming the missing variable and never prints a value.

Endpoint coverage across the SDKs is tracked in docs/endpoint-coverage.md.

Documentation

Overview

Package fmp is a pure Go client for the Financial Modeling Prep (FMP) HTTP API. It mirrors the Rust crate libfmp one-for-one: the same client options, the same authentication modes, the same error categories, and the same transport rules.

The module path ends in "go", so import it with an alias:

import fmp "github.com/bitbrew-dev/libfmp/sdk/go"

Building a client

NewClient validates every option before any request is made and returns a *Error of category CategoryConfiguration when the configuration is unsafe or inconsistent. Direct access to the default FMP origin requires explicit authentication:

auth, ok := fmp.FMPHeaderFromEnv()
if !ok {
	return errors.New("FMP_API_KEY is not set")
}
client, err := fmp.NewClient(fmp.WithAuthentication(auth))

Header authentication modes (FMPHeader, Bearer, CustomHeader, CustomHeaderWithPrefix) never place a credential in the URL. Query modes (FMPQuery, CustomQuery) append the secret as the last query pair of every request. CustomHeaderWithPrefix sends the header value as prefix followed by secret with no separator inserted, mirroring the Rust Authentication::custom_header(name, Some(prefix), secret) form; an empty prefix is the same value as CustomHeader. The Example functions of this package and the programs under examples/ show these calls end to end, offline, against an in-process server.

Transport rules

The client is standard-library only and builds with CGO_ENABLED=0. It never retries: every call issues exactly one request per redirect hop, whatever the status. Redirects are followed only to the same origin and at most ten times; RedirectNone returns the redirect as a status error instead. One context deadline (WithTimeout, default 30 seconds) spans the whole call, including redirects and the body read. Response bodies are capped by WithMaxResponseBodyBytes (default 64 MiB).

WithHTTPClient injects a caller-owned *http.Client for proxies and tests. The SDK shallow-copies it to install its redirect policy, so the caller's value is never mutated. WithConnectTimeout applies only to the transport the SDK builds itself; a caller-supplied client keeps its own dialer.

Credential policy

No credential can reach a diagnostic. Authentication, Client, and Redactor implement fmt.Formatter so that %v, %+v, and %#v print a description without secret values. Every transport failure is rebuilt without the request URL before it escapes (Go's *url.Error embeds the URL, which holds the API key in query mode), and its cause text is passed through the Redactor. The cause text also loses the network topology a dial or proxy failure prints (the base URL host, the resolved proxy host, and the addresses a *net.OpError or *net.DNSError names); provider bodies keep such text. Provider bodies retained in an *Error are redacted and capped at MaxSafeBodyBytes.

Environment

FMPHeaderFromEnv reads FMP_API_KEY. NewClient never reads a credential from the environment; it consults the proxy variables (HTTP_PROXY, HTTPS_PROXY, NO_PROXY) once through the transport's proxy function, as the first request would, to register the proxy host for cause redaction. The opt-in live tests (live_test.go) use the same names as the Rust crate's live_opt_in.rs: FMP_LIVE_TESTS=1 switches both tests on, the direct test needs FMP_API_KEY, and the proxy test needs FMP_PROXY_BASE_URL, FMP_PROXY_TOKEN, and optionally FMP_PROXY_PATH_PREFIX (default router/stable) and FMP_TENANT. They skip without the switch; run them from sdk/go with:

FMP_LIVE_TESTS=1 FMP_API_KEY=... go test -run 'TestLive' -count=1 ./...

Endpoint surface

Endpoint methods are generated from the registry that also drives the Python binding (cargo run -p fmp-py-gen --bin gen_go), so the public names follow fixed rules rather than per-endpoint choices. Every generated file starts with "Code generated by fmp-py-gen gen_go. DO NOT EDIT.": one <domain>_models.go and one <domain>.go per domain, queries.go for the query types more than one domain shares, namespaces.go for the Namespaces struct Client embeds, and metadata_table.go for the advisory endpoint metadata. These are the decisions settled by the hand-written quote domain (ADR 0030, phase 0):

  • Namespaces: each registry domain is a struct named <Domain>Namespace, reached as a field of Client through the embedded Namespaces (client.Quote). A domain with nested namespaces nests the structs the same way (client.Statements.Income).
  • Casing: registry names in UpperCamelCase, with one initialism table (ADR 0032) applied to every generated and hand-written identifier: ID, UID, URL, JSON, API, HTTP, FMP, SEC, US, COT, ETF, CIK, CUSIP, ISIN, IPO, SP500, ESG, DCF, EPS, TTM, and the form names 8K and 13F are all caps, and TipRanks keeps its brand casing. So etfs is ETFs, latest_8k is Latest8K, and the Rust KeyMetricsTtm is KeyMetricsTTM. Struct tags keep the wire names.
  • Queries: every endpoint with arguments takes a value type named after the Rust query (QuoteQuery) built by New<Query>(required args...), with one With<Setter>(value) builder method per Rust with_* setter. String kinds such as tickers are plain strings, validated when the request is built; a rejected argument returns a *Error of CategoryValidation whose message is "<argument>: <reason>". Endpoints without a query take only the context.
  • Signatures: func (n *QuoteNamespace) Full(ctx context.Context, q QuoteQuery) ([]Quote, error). The context comes first and bare-array endpoints return a slice of the model.
  • Models: one <domain>_models.go per domain with camelCase struct tags, pointer fields for optional members, and an UnmarshalJSONFrom that decodes through a pointer-field shadow struct and returns a *Error of CategoryDecode naming the first required member that is missing or null, matching serde. Unknown members are ignored. Members whose Rust codec treats "" as absent (empty_date, empty_or_null_date) decode to a nil *Date; re-encoding writes null, not "", since the SDK is read-only. A member serde skips when None (skip_serializing_if = "Option::is_none") carries the omitzero tag option, so a nil member is omitted on re-encoding exactly as the Rust model omits it. A model whose Rust decoder keeps every unclaimed member in one map (FinancialReportJSON) holds them in a jsontext.Value tagged json:",embed": always a JSON object, {} when nothing is left over, re-emitted in place.
  • Nested namespaces: a domain with [[namespace]] sub-groups nests one struct per group as an exported field of the domain struct, so the statements domain is reached as client.Statements.Income.Statement.
  • Accepted response-side differences: a CalendarQuarter member decodes as a plain uint8 with no 1 to 4 range check (Rust validates; the Go parity tests prove the JSON kind only), and a FiscalPeriod member decodes as a plain string rather than the closed FiscalPeriod type the queries use, in the same way IsoTimestamp members stay exact strings.
  • Dynamic rows: an endpoint whose Rust method returns Vec<DynamicObject> (registry response = "dynamic") returns []jsontext.Value, one raw JSON object per row, checked to be an object and otherwise kept verbatim. SECFilings.SearchIndustryClassifications is the only one today; it stays dynamic in Go for as long as the Rust contract does, since a typed row is a Rust model change first.
  • Type aliases: a Rust alias of a model (FundDisclosureDate for Form13fFilingDate) has no Go type of its own; the method returns the aliased model's Go type (Form13FFilingDate), so one Rust model is one Go type.

Endpoint metadata

EndpointMetadataFor returns the advisory metadata the Rust descriptor of an endpoint attaches (geography, plan access, a conditional plan, realtime caveats, request bounds), keyed by the Go call path without the client:

metadata, ok := fmp.EndpointMetadataFor("Quote.Full")
if ok && metadata.Realtime != nil && metadata.Realtime.Delay != nil {
	log.Printf("quotes are delayed %s", metadata.Realtime.Delay)
}

The types in metadata.go mirror the Rust EndpointMetadata one-for-one and every zero value means unspecified; the generated metadata_table.go holds one entry per method whose descriptor attaches metadata, and the lookup reports false with the zero value for the others and for an unknown key. The client never validates a request against the metadata, exactly as the Rust crate does not. The surface is one table rather than a sibling <Method>Metadata per endpoint method because several methods share one endpoint id through helper reuse while carrying different metadata (the id "quote" serves five namespaces), so the id cannot be the key, and a table keyed by call path adds one generated file instead of 271 methods.

EndpointMetadataByID resolves the endpoint id an *Error carries in its Endpoint field. It returns one EndpointMethodMetadata per method that sends the id and attaches metadata, never a merged value: seven ids (the quote, quote-short, and five chart helpers the asset domains share) carry different metadata per method, and the caller picks the entry whose Method it called.

Index

Examples

Constants

View Source
const (
	// DefaultBaseURL is the Financial Modeling Prep API origin.
	DefaultBaseURL = "https://financialmodelingprep.com"
	// DefaultPathPrefix is the path prefix of the stable FMP API.
	DefaultPathPrefix = "stable"
	// DefaultTimeout is the logical deadline for one call, redirects included.
	DefaultTimeout = 30 * time.Second
	// DefaultConnectTimeout bounds connection establishment.
	DefaultConnectTimeout = 10 * time.Second
	// DefaultMaxResponseBodyBytes is the largest body buffered per response (64 MiB).
	DefaultMaxResponseBodyBytes int64 = 64 * 1024 * 1024
)
View Source
const EnvAPIKey = "FMP_API_KEY"

EnvAPIKey is the process environment variable read by FMPHeaderFromEnv.

View Source
const MaxSafeBodyBytes = 4096

MaxSafeBodyBytes is the largest UTF-8 byte length retained from a provider response body inside an *Error.

View Source
const Redacted = "[REDACTED]"

Redacted replaces every secret value removed from a diagnostic.

View Source
const Version = "1.1.0"

Version is the SDK version reported in the default User-Agent header.

It equals the libfmp workspace version ([workspace.package].version in Cargo.toml). scripts/set-version.sh rewrites it at release time and the release workflow tags sdk/go/v<Version> at the release commit, so it must never be edited by hand; version_test.go fails when it drifts.

Variables

View Source
var (
	ErrEmptySecretName   = errors.New("secret name must not be empty")
	ErrInvalidSecretName = errors.New("secret name contains unsupported characters")
)

Errors returned by Redactor when a secret name is rejected.

View Source
var (
	ErrEmptyValue            = errors.New("value must not be empty or whitespace-only")
	ErrControlCharacterValue = errors.New("value must not contain control characters")
	ErrCommaInTicker         = errors.New("ticker must not contain a comma")
)

Reasons a string-like query argument is rejected. They carry the same messages as StringValueError in the Rust crate.

View Source
var (
	ErrEmptyTickerList        = errors.New("ticker list must contain at least one ticker")
	ErrNonFiniteDecimal       = errors.New("decimal value must be finite")
	ErrZeroPeriodLength       = errors.New("period length must be a positive integer")
	ErrInvalidCalendarQuarter = errors.New("calendar quarter must be an integer from 1 through 4")
)

Reasons a non-string query argument is rejected. They carry the same messages as the corresponding constructors in the Rust crate.

View Source
var ErrInvalidNumberOrString = errors.New("value must be a JSON number, numeric string, or percent string")

ErrInvalidNumberOrString reports a JSON value that is neither a number, a numeric string, nor a percent string.

View Source
var ErrUnknownWireValue = errors.New("value is not a documented wire value")

ErrUnknownWireValue is returned when an enumerated argument is not one of its documented wire values. The Rust crate makes this unrepresentable with a closed enum; the Go SDK checks it when the request is built.

Wire enum policy: a query type is closed (RetrievalFrequency, Quarter, ChartTimeframe, FiscalPeriod, StatementPeriod, SegmentationStructure) when its libfmp counterpart is a closed Rust enum, and then any value outside its constants fails with ErrUnknownWireValue before a request is sent. A type is open (EconomicIndicator) only when the libfmp type accepts provider values it does not list; its constants are the documented spellings and any other valid string is forwarded. Widening a closed type follows the Rust enum gaining a variant, never the provider documentation alone.

View Source
var ErrZeroTemporalValue = errors.New("zero temporal value cannot be encoded")

ErrZeroTemporalValue is returned when a zero Date or DateTime is encoded. The zero value has no wire representation, so encoding it would invent one.

Functions

func APIKeyFromEnv added in v0.12.0

func APIKeyFromEnv() (string, bool)

APIKeyFromEnv reads FMP_API_KEY, trims surrounding whitespace, and reports false when the variable is unset, empty, or whitespace-only.

Types

type AccessKind

type AccessKind int

AccessKind is the discriminant of AccessRequirement, the Go spelling of the Rust enum's variants. The zero value is AccessUnspecified.

const (
	// AccessUnspecified: the documentation states no plan requirement.
	AccessUnspecified AccessKind = iota
	// AccessStandard: the endpoint is part of the standard plans.
	AccessStandard
	// AccessNamedAddOn: the endpoint needs the add-on named by
	// AccessRequirement.AddOn.
	AccessNamedAddOn
)

func (AccessKind) String

func (k AccessKind) String() string

String returns a short stable label that is safe to log.

type AccessRequirement

type AccessRequirement struct {
	Kind  AccessKind
	AddOn string
}

AccessRequirement is the plan access documented for an endpoint. It mirrors the Rust AccessRequirement: Kind selects the variant and AddOn carries the add-on name only when Kind is AccessNamedAddOn.

func (AccessRequirement) String

func (a AccessRequirement) String() string

String returns a short label that is safe to log.

type ActivelyTradingSymbol

type ActivelyTradingSymbol struct {
	Symbol string `json:"symbol"`
	Name   string `json:"name"`
}

ActivelyTradingSymbol is one worldwide company or instrument in the actively-trading directory.

func (*ActivelyTradingSymbol) UnmarshalJSONFrom

func (m *ActivelyTradingSymbol) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type AftermarketQuote

type AftermarketQuote struct {
	Symbol    string           `json:"symbol"`
	BidSize   float64          `json:"bidSize"`
	BidPrice  float64          `json:"bidPrice"`
	AskSize   float64          `json:"askSize"`
	AskPrice  float64          `json:"askPrice"`
	Volume    float64          `json:"volume"`
	Timestamp UnixMilliseconds `json:"timestamp"`
}

AftermarketQuote is one bid-and-ask quote observed after regular US market hours.

func (*AftermarketQuote) UnmarshalJSONFrom

func (m *AftermarketQuote) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type AftermarketQuoteQuery

type AftermarketQuoteQuery struct {
	// contains filtered or unexported fields
}

AftermarketQuoteQuery holds the query parameters of the endpoints that take it: NewAftermarketQuoteQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewAftermarketQuoteQuery

func NewAftermarketQuoteQuery(symbol string) AftermarketQuoteQuery

NewAftermarketQuoteQuery creates the query from its required arguments.

func (AftermarketQuoteQuery) Symbol

func (q AftermarketQuoteQuery) Symbol() string

Symbol returns the symbol argument as given.

type AftermarketTrade

type AftermarketTrade struct {
	Symbol    string           `json:"symbol"`
	Price     float64          `json:"price"`
	TradeSize float64          `json:"tradeSize"`
	Timestamp UnixMilliseconds `json:"timestamp"`
}

AftermarketTrade is one trade executed after regular US market hours.

func (*AftermarketTrade) UnmarshalJSONFrom

func (m *AftermarketTrade) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type AftermarketTradeQuery

type AftermarketTradeQuery struct {
	// contains filtered or unexported fields
}

AftermarketTradeQuery holds the query parameters of the endpoints that take it: NewAftermarketTradeQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewAftermarketTradeQuery

func NewAftermarketTradeQuery(symbol string) AftermarketTradeQuery

NewAftermarketTradeQuery creates the query from its required arguments.

func (AftermarketTradeQuery) Symbol

func (q AftermarketTradeQuery) Symbol() string

Symbol returns the symbol argument as given.

type AllExchangeMarketHoursQuery

type AllExchangeMarketHoursQuery struct {
	// contains filtered or unexported fields
}

AllExchangeMarketHoursQuery holds the query parameters of the endpoints that take it: NewAllExchangeMarketHoursQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewAllExchangeMarketHoursQuery

func NewAllExchangeMarketHoursQuery() AllExchangeMarketHoursQuery

NewAllExchangeMarketHoursQuery creates the query from its required arguments.

func (AllExchangeMarketHoursQuery) Timestamp

func (q AllExchangeMarketHoursQuery) Timestamp() *string

Timestamp returns the optional timestamp parameter, or nil when it is unset.

func (AllExchangeMarketHoursQuery) WithTimestamp

WithTimestamp sets the optional timestamp parameter and returns the updated query.

type AllIndustryClassificationsQuery

type AllIndustryClassificationsQuery struct {
	// contains filtered or unexported fields
}

AllIndustryClassificationsQuery holds the query parameters of the endpoints that take it: NewAllIndustryClassificationsQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewAllIndustryClassificationsQuery

func NewAllIndustryClassificationsQuery() AllIndustryClassificationsQuery

NewAllIndustryClassificationsQuery creates the query from its required arguments.

func (AllIndustryClassificationsQuery) Limit

Limit returns the optional limit parameter, or nil when it is unset.

func (AllIndustryClassificationsQuery) Page

Page returns the optional page parameter, or nil when it is unset.

func (AllIndustryClassificationsQuery) WithLimit

WithLimit sets the optional limit parameter and returns the updated query.

func (AllIndustryClassificationsQuery) WithPage

WithPage sets the optional page parameter and returns the updated query.

type AllSharesFloatQuery added in v0.12.0

type AllSharesFloatQuery struct {
	// contains filtered or unexported fields
}

AllSharesFloatQuery holds the query parameters of the endpoints that take it: NewAllSharesFloatQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewAllSharesFloatQuery added in v0.12.0

func NewAllSharesFloatQuery() AllSharesFloatQuery

NewAllSharesFloatQuery creates the query from its required arguments.

func (AllSharesFloatQuery) Limit added in v0.12.0

func (q AllSharesFloatQuery) Limit() *uint32

Limit returns the optional limit parameter, or nil when it is unset.

func (AllSharesFloatQuery) Page added in v0.12.0

func (q AllSharesFloatQuery) Page() *uint32

Page returns the optional page parameter, or nil when it is unset.

func (AllSharesFloatQuery) WithLimit added in v0.12.0

func (q AllSharesFloatQuery) WithLimit(limit uint32) AllSharesFloatQuery

WithLimit sets the optional limit parameter and returns the updated query.

func (AllSharesFloatQuery) WithPage added in v0.12.0

WithPage sets the optional page parameter and returns the updated query.

type AnalystNamespace

type AnalystNamespace struct {
	// contains filtered or unexported fields
}

AnalystNamespace groups the analyst endpoints. It is reached as Client.Analyst and is valid only when obtained from a Client built by NewClient.

func (*AnalystNamespace) FinancialEstimates

FinancialEstimates retrieves worldwide analyst financial estimates for one ticker.

GET analyst-estimates?symbol=&period=&page=&limit=

func (*AnalystNamespace) HistoricalRatings

HistoricalRatings retrieves worldwide historical financial ratings for one ticker.

GET ratings-historical?symbol=&limit=

func (*AnalystNamespace) HistoricalStockGrades

HistoricalStockGrades retrieves worldwide historical stock-grade counts for one ticker.

GET grades-historical?symbol=&limit=

func (*AnalystNamespace) PriceTargetConsensus

PriceTargetConsensus retrieves the US-only price-target consensus for one ticker.

GET price-target-consensus?symbol=

func (*AnalystNamespace) PriceTargetSummary

PriceTargetSummary retrieves the US-only price-target summary for one ticker.

GET price-target-summary?symbol=

func (*AnalystNamespace) RatingsSnapshot

func (n *AnalystNamespace) RatingsSnapshot(ctx context.Context, q RatingsSnapshotQuery) ([]RatingSnapshot, error)

RatingsSnapshot retrieves the worldwide financial-rating snapshot for one ticker.

GET ratings-snapshot?symbol=

func (*AnalystNamespace) StockGrades

func (n *AnalystNamespace) StockGrades(ctx context.Context, q StockGradesQuery) ([]StockGrade, error)

StockGrades retrieves current worldwide stock-grade actions for one ticker.

GET grades?symbol=

func (*AnalystNamespace) StockGradesSummary

StockGradesSummary retrieves the worldwide stock-grades summary for one ticker.

GET grades-consensus?symbol=

type Article added in v0.12.0

type Article struct {
	Title   string   `json:"title"`
	Date    DateTime `json:"date"`
	Content string   `json:"content"`
	Tickers string   `json:"tickers"`
	Image   string   `json:"image"`
	Link    string   `json:"link"`
	Author  string   `json:"author"`
	Site    string   `json:"site"`
}

Article is one Financial Modeling Prep editorial article.

func (*Article) UnmarshalJSONFrom added in v0.12.0

func (m *Article) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type ArticlesQuery added in v0.12.0

type ArticlesQuery struct {
	// contains filtered or unexported fields
}

ArticlesQuery holds the query parameters of the endpoints that take it: NewArticlesQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewArticlesQuery added in v0.12.0

func NewArticlesQuery() ArticlesQuery

NewArticlesQuery creates the query from its required arguments.

func (ArticlesQuery) Limit added in v0.12.0

func (q ArticlesQuery) Limit() *uint32

Limit returns the optional limit parameter, or nil when it is unset.

func (ArticlesQuery) Page added in v0.12.0

func (q ArticlesQuery) Page() *uint32

Page returns the optional page parameter, or nil when it is unset.

func (ArticlesQuery) WithLimit added in v0.12.0

func (q ArticlesQuery) WithLimit(limit uint32) ArticlesQuery

WithLimit sets the optional limit parameter and returns the updated query.

func (ArticlesQuery) WithPage added in v0.12.0

func (q ArticlesQuery) WithPage(page uint32) ArticlesQuery

WithPage sets the optional page parameter and returns the updated query.

type AsReportedFinancialStatement

type AsReportedFinancialStatement struct {
	Symbol           string         `json:"symbol"`
	FiscalYear       uint32         `json:"fiscalYear"`
	Period           string         `json:"period"`
	ReportedCurrency string         `json:"reportedCurrency"`
	Date             Date           `json:"date"`
	Data             jsontext.Value `json:"data"`
}

AsReportedFinancialStatement is one as-reported financial statement with provider-native data keys.

func (*AsReportedFinancialStatement) UnmarshalJSONFrom

func (m *AsReportedFinancialStatement) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type AssetChartQuery

type AssetChartQuery struct {
	// contains filtered or unexported fields
}

AssetChartQuery holds the query parameters of the endpoints that take it: NewAssetChartQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewAssetChartQuery

func NewAssetChartQuery(symbol string) AssetChartQuery

NewAssetChartQuery creates the query from its required arguments.

func (AssetChartQuery) From

func (q AssetChartQuery) From() *Date

From returns the optional from parameter, or nil when it is unset.

func (AssetChartQuery) Symbol

func (q AssetChartQuery) Symbol() string

Symbol returns the symbol argument as given.

func (AssetChartQuery) To

func (q AssetChartQuery) To() *Date

To returns the optional to parameter, or nil when it is unset.

func (AssetChartQuery) WithFrom

func (q AssetChartQuery) WithFrom(from Date) AssetChartQuery

WithFrom sets the optional from parameter and returns the updated query.

func (AssetChartQuery) WithTo

func (q AssetChartQuery) WithTo(to Date) AssetChartQuery

WithTo sets the optional to parameter and returns the updated query.

type Authentication

type Authentication struct {
	// contains filtered or unexported fields
}

Authentication selects how the transport attaches a credential to every request. The zero value sends no credential. Formatting an Authentication with any fmt verb never reveals the secret.

func Bearer

func Bearer(token string) Authentication

Bearer sends an RFC 6750 "Authorization: Bearer ..." header.

func CustomHeader

func CustomHeader(name, secret string) Authentication

CustomHeader sends a secret in a caller-selected header. It is CustomHeaderWithPrefix with an empty prefix.

func CustomHeaderWithPrefix

func CustomHeaderWithPrefix(name, prefix, secret string) Authentication

CustomHeaderWithPrefix sends a secret in a caller-selected header with non-secret text placed immediately before it. The header value is exactly prefix followed by secret; no separator is inserted, so a "Bearer " prefix must carry its own trailing space. It mirrors the Rust Authentication::custom_header(name, Some(prefix), secret) form, and an empty prefix is the same value as CustomHeader(name, secret) (Rust's Some("") differs from None in Debug and equality, not on the wire). The prefix is validated like a header value when the client is built. Formatting the value reports whether a prefix is present, never its text.

func CustomQuery

func CustomQuery(name, secret string) Authentication

CustomQuery sends a secret in a caller-selected query parameter. The name must be non-empty and use only ASCII letters, digits, and "-._~", the characters the Redactor can protect; NewClient rejects any other name with ConfigurationKindInvalidQueryName.

func FMPHeader added in v0.12.0

func FMPHeader(apiKey string) Authentication

FMPHeader sends the FMP API key in the exact "apikey" header.

func FMPHeaderFromEnv added in v0.12.0

func FMPHeaderFromEnv() (Authentication, bool)

FMPHeaderFromEnv builds FMPHeader authentication from FMP_API_KEY using the normalization of APIKeyFromEnv. NewClient never reads a credential from the environment on its own, so callers opt in explicitly.

Example

ExampleFMPHeaderFromEnv reads FMP_API_KEY and sends it in the apikey header. NewClient never reads the environment on its own, so the opt-in is explicit. Formatting the Authentication never reveals the key.

package main

import (
	"context"
	"fmt"
	"net/http"
	"net/http/httptest"
	"os"

	fmp "github.com/bitbrew-dev/libfmp/sdk/go"
)

// exampleKey is the placeholder credential every example sends. It is not a
// real key, and no example prints it.
const exampleKey = "example-key"

// quoteShortFixture is a copy of crates/libfmp/tests/fixtures/quote_short.json,
// the documented provider response the Rust and Go parity tests both decode.
// It is inlined so the examples stay self-contained on pkg.go.dev and when the
// module is tested outside this repository.
const quoteShortFixture = `[
  {
    "change": -6.33498,
    "price": 331.85501,
    "symbol": "AAPL",
    "volume": 28718014
  }
]`

// serveQuoteShort starts an in-process TLS server that answers GET
// <prefix>/quote-short with the quote_short.json fixture, after check has
// accepted the request. Any other path, or a rejected request, is a 404.
func serveQuoteShort(prefix string, check func(*http.Request) bool) *httptest.Server {
	return httptest.NewTLSServer(http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) {
		if r.URL.Path != prefix+"/quote-short" || !check(r) {
			http.NotFound(w, r)
			return
		}
		w.Header().Set("Content-Type", "application/json")
		_, _ = fmt.Fprint(w, quoteShortFixture)
	}))
}

// printQuoteShort prints the first compact quote with fixed formats so the
// output is stable across platforms.
func printQuoteShort(quotes []fmp.QuoteShort) {
	if len(quotes) == 0 {
		fmt.Println("no quotes")
		return
	}
	q := quotes[0]
	fmt.Printf("%s price %.5f change %.5f volume %.0f\n", q.Symbol, q.Price, q.Change, q.Volume)
}

func main() {
	previous, had := os.LookupEnv(fmp.EnvAPIKey)
	if err := os.Setenv(fmp.EnvAPIKey, exampleKey); err != nil {
		fmt.Println("setenv failed:", err)
		return
	}
	defer func() {
		if had {
			_ = os.Setenv(fmp.EnvAPIKey, previous)
		} else {
			_ = os.Unsetenv(fmp.EnvAPIKey)
		}
	}()

	auth, ok := fmp.FMPHeaderFromEnv()
	if !ok {
		fmt.Println(fmp.EnvAPIKey, "is not set")
		return
	}
	fmt.Println("authentication:", auth)

	server := serveQuoteShort("/stable", func(r *http.Request) bool {
		return r.Header.Get("apikey") == exampleKey
	})
	defer server.Close()

	client, err := fmp.NewClient(
		fmp.WithBaseURL(server.URL),
		fmp.WithHTTPClient(server.Client()),
		fmp.WithAuthentication(auth),
	)
	if err != nil {
		fmt.Println("configuration rejected:", err)
		return
	}
	quotes, err := client.Quote.Short(context.Background(), fmp.NewQuoteShortQuery("AAPL"))
	if err != nil {
		fmt.Println("request failed:", err)
		return
	}
	printQuoteShort(quotes)
}
Output:
authentication: FMPHeader([REDACTED])
AAPL price 331.85501 change -6.33498 volume 28718014

func FMPQuery added in v0.12.0

func FMPQuery(apiKey string) Authentication

FMPQuery sends the FMP API key in the "apikey" query parameter.

func (Authentication) Format

func (a Authentication) Format(f fmt.State, _ rune)

Format prints the String description for every verb, including %+v and %#v.

func (Authentication) String

func (a Authentication) String() string

String describes the mode without the secret.

type AvailableCountry

type AvailableCountry struct {
	Country string `json:"country"`
}

AvailableCountry is one country accepted by provider country filters.

func (*AvailableCountry) UnmarshalJSONFrom

func (m *AvailableCountry) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type AvailableExchange

type AvailableExchange struct {
	Exchange     string `json:"exchange"`
	Name         string `json:"name"`
	CountryName  string `json:"countryName"`
	CountryCode  string `json:"countryCode"`
	SymbolSuffix string `json:"symbolSuffix"`
	Delay        string `json:"delay"`
}

AvailableExchange is one stock exchange supported by FMP.

func (*AvailableExchange) UnmarshalJSONFrom

func (m *AvailableExchange) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type AvailableExchangesQuery

type AvailableExchangesQuery struct {
	// contains filtered or unexported fields
}

AvailableExchangesQuery holds the query parameters of the endpoints that take it: NewAvailableExchangesQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewAvailableExchangesQuery

func NewAvailableExchangesQuery() AvailableExchangesQuery

NewAvailableExchangesQuery creates the query from its required arguments.

func (AvailableExchangesQuery) Extended

func (q AvailableExchangesQuery) Extended() *bool

Extended returns the optional extended parameter, or nil when it is unset.

func (AvailableExchangesQuery) WithExtended

func (q AvailableExchangesQuery) WithExtended(extended bool) AvailableExchangesQuery

WithExtended sets the optional extended parameter and returns the updated query.

type AvailableIndustry

type AvailableIndustry struct {
	Industry string `json:"industry"`
}

AvailableIndustry is one industry accepted by provider industry filters.

func (*AvailableIndustry) UnmarshalJSONFrom

func (m *AvailableIndustry) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type AvailableSector

type AvailableSector struct {
	Sector string `json:"sector"`
}

AvailableSector is one sector accepted by provider sector filters.

func (*AvailableSector) UnmarshalJSONFrom

func (m *AvailableSector) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type AverageDirectionalIndexBar

type AverageDirectionalIndexBar struct {
	Date   DateTime `json:"date"`
	Open   float64  `json:"open"`
	High   float64  `json:"high"`
	Low    float64  `json:"low"`
	Close  float64  `json:"close"`
	Volume float64  `json:"volume"`
	Adx    float64  `json:"adx"`
}

AverageDirectionalIndexBar is a response model of the technical_indicators domain.

func (*AverageDirectionalIndexBar) UnmarshalJSONFrom

func (m *AverageDirectionalIndexBar) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type BalanceSheetStatement

type BalanceSheetStatement struct {
	Date                                    Date     `json:"date"`
	Symbol                                  string   `json:"symbol"`
	ReportedCurrency                        string   `json:"reportedCurrency"`
	CIK                                     string   `json:"cik"`
	FilingDate                              Date     `json:"filingDate"`
	AcceptedDate                            DateTime `json:"acceptedDate"`
	FiscalYear                              string   `json:"fiscalYear"`
	Period                                  string   `json:"period"`
	CashAndCashEquivalents                  float64  `json:"cashAndCashEquivalents"`
	ShortTermInvestments                    float64  `json:"shortTermInvestments"`
	CashAndShortTermInvestments             float64  `json:"cashAndShortTermInvestments"`
	NetReceivables                          float64  `json:"netReceivables"`
	AccountsReceivables                     float64  `json:"accountsReceivables"`
	OtherReceivables                        float64  `json:"otherReceivables"`
	Inventory                               float64  `json:"inventory"`
	Prepaids                                float64  `json:"prepaids"`
	OtherCurrentAssets                      float64  `json:"otherCurrentAssets"`
	TotalCurrentAssets                      float64  `json:"totalCurrentAssets"`
	PropertyPlantEquipmentNet               float64  `json:"propertyPlantEquipmentNet"`
	Goodwill                                float64  `json:"goodwill"`
	IntangibleAssets                        float64  `json:"intangibleAssets"`
	GoodwillAndIntangibleAssets             float64  `json:"goodwillAndIntangibleAssets"`
	LongTermInvestments                     float64  `json:"longTermInvestments"`
	TaxAssets                               float64  `json:"taxAssets"`
	OtherNonCurrentAssets                   float64  `json:"otherNonCurrentAssets"`
	TotalNonCurrentAssets                   float64  `json:"totalNonCurrentAssets"`
	OtherAssets                             float64  `json:"otherAssets"`
	TotalAssets                             float64  `json:"totalAssets"`
	TotalPayables                           float64  `json:"totalPayables"`
	AccountPayables                         float64  `json:"accountPayables"`
	OtherPayables                           float64  `json:"otherPayables"`
	AccruedExpenses                         float64  `json:"accruedExpenses"`
	ShortTermDebt                           float64  `json:"shortTermDebt"`
	CapitalLeaseObligationsCurrent          float64  `json:"capitalLeaseObligationsCurrent"`
	TaxPayables                             float64  `json:"taxPayables"`
	DeferredRevenue                         float64  `json:"deferredRevenue"`
	OtherCurrentLiabilities                 float64  `json:"otherCurrentLiabilities"`
	TotalCurrentLiabilities                 float64  `json:"totalCurrentLiabilities"`
	LongTermDebt                            float64  `json:"longTermDebt"`
	CapitalLeaseObligationsNonCurrent       float64  `json:"capitalLeaseObligationsNonCurrent"`
	DeferredRevenueNonCurrent               float64  `json:"deferredRevenueNonCurrent"`
	DeferredTaxLiabilitiesNonCurrent        float64  `json:"deferredTaxLiabilitiesNonCurrent"`
	OtherNonCurrentLiabilities              float64  `json:"otherNonCurrentLiabilities"`
	TotalNonCurrentLiabilities              float64  `json:"totalNonCurrentLiabilities"`
	OtherLiabilities                        float64  `json:"otherLiabilities"`
	CapitalLeaseObligations                 float64  `json:"capitalLeaseObligations"`
	TotalLiabilities                        float64  `json:"totalLiabilities"`
	TreasuryStock                           float64  `json:"treasuryStock"`
	PreferredStock                          float64  `json:"preferredStock"`
	CommonStock                             float64  `json:"commonStock"`
	RetainedEarnings                        float64  `json:"retainedEarnings"`
	AdditionalPaidInCapital                 float64  `json:"additionalPaidInCapital"`
	AccumulatedOtherComprehensiveIncomeLoss float64  `json:"accumulatedOtherComprehensiveIncomeLoss"`
	OtherTotalStockholdersEquity            float64  `json:"otherTotalStockholdersEquity"`
	TotalStockholdersEquity                 float64  `json:"totalStockholdersEquity"`
	TotalEquity                             float64  `json:"totalEquity"`
	MinorityInterest                        float64  `json:"minorityInterest"`
	TotalLiabilitiesAndTotalEquity          float64  `json:"totalLiabilitiesAndTotalEquity"`
	TotalInvestments                        float64  `json:"totalInvestments"`
	TotalDebt                               float64  `json:"totalDebt"`
	NetDebt                                 float64  `json:"netDebt"`
}

BalanceSheetStatement is one historical worldwide balance-sheet statement.

func (*BalanceSheetStatement) UnmarshalJSONFrom

func (m *BalanceSheetStatement) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type BalanceSheetStatementAsReportedQuery

type BalanceSheetStatementAsReportedQuery struct {
	// contains filtered or unexported fields
}

BalanceSheetStatementAsReportedQuery holds the query parameters of the endpoints that take it: NewBalanceSheetStatementAsReportedQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewBalanceSheetStatementAsReportedQuery

func NewBalanceSheetStatementAsReportedQuery(symbol string) BalanceSheetStatementAsReportedQuery

NewBalanceSheetStatementAsReportedQuery creates the query from its required arguments.

func (BalanceSheetStatementAsReportedQuery) Limit

Limit returns the optional limit parameter, or nil when it is unset.

func (BalanceSheetStatementAsReportedQuery) Period

Period returns the optional period parameter, or nil when it is unset.

func (BalanceSheetStatementAsReportedQuery) Symbol

Symbol returns the symbol argument as given.

func (BalanceSheetStatementAsReportedQuery) WithLimit

WithLimit sets the optional limit parameter and returns the updated query.

func (BalanceSheetStatementAsReportedQuery) WithPeriod

WithPeriod sets the optional period parameter and returns the updated query.

type BalanceSheetStatementGrowth

type BalanceSheetStatementGrowth struct {
	Symbol                                        string  `json:"symbol"`
	Date                                          Date    `json:"date"`
	FiscalYear                                    string  `json:"fiscalYear"`
	Period                                        string  `json:"period"`
	ReportedCurrency                              string  `json:"reportedCurrency"`
	GrowthCashAndCashEquivalents                  float64 `json:"growthCashAndCashEquivalents"`
	GrowthShortTermInvestments                    float64 `json:"growthShortTermInvestments"`
	GrowthCashAndShortTermInvestments             float64 `json:"growthCashAndShortTermInvestments"`
	GrowthNetReceivables                          float64 `json:"growthNetReceivables"`
	GrowthInventory                               float64 `json:"growthInventory"`
	GrowthOtherCurrentAssets                      float64 `json:"growthOtherCurrentAssets"`
	GrowthTotalCurrentAssets                      float64 `json:"growthTotalCurrentAssets"`
	GrowthPropertyPlantEquipmentNet               float64 `json:"growthPropertyPlantEquipmentNet"`
	GrowthGoodwill                                float64 `json:"growthGoodwill"`
	GrowthIntangibleAssets                        float64 `json:"growthIntangibleAssets"`
	GrowthGoodwillAndIntangibleAssets             float64 `json:"growthGoodwillAndIntangibleAssets"`
	GrowthLongTermInvestments                     float64 `json:"growthLongTermInvestments"`
	GrowthTaxAssets                               float64 `json:"growthTaxAssets"`
	GrowthOtherNonCurrentAssets                   float64 `json:"growthOtherNonCurrentAssets"`
	GrowthTotalNonCurrentAssets                   float64 `json:"growthTotalNonCurrentAssets"`
	GrowthOtherAssets                             float64 `json:"growthOtherAssets"`
	GrowthTotalAssets                             float64 `json:"growthTotalAssets"`
	GrowthAccountPayables                         float64 `json:"growthAccountPayables"`
	GrowthShortTermDebt                           float64 `json:"growthShortTermDebt"`
	GrowthTaxPayables                             float64 `json:"growthTaxPayables"`
	GrowthDeferredRevenue                         float64 `json:"growthDeferredRevenue"`
	GrowthOtherCurrentLiabilities                 float64 `json:"growthOtherCurrentLiabilities"`
	GrowthTotalCurrentLiabilities                 float64 `json:"growthTotalCurrentLiabilities"`
	GrowthLongTermDebt                            float64 `json:"growthLongTermDebt"`
	GrowthDeferredRevenueNonCurrent               float64 `json:"growthDeferredRevenueNonCurrent"`
	GrowthDeferredTaxLiabilitiesNonCurrent        float64 `json:"growthDeferredTaxLiabilitiesNonCurrent"`
	GrowthOtherNonCurrentLiabilities              float64 `json:"growthOtherNonCurrentLiabilities"`
	GrowthTotalNonCurrentLiabilities              float64 `json:"growthTotalNonCurrentLiabilities"`
	GrowthOtherLiabilities                        float64 `json:"growthOtherLiabilities"`
	GrowthTotalLiabilities                        float64 `json:"growthTotalLiabilities"`
	GrowthPreferredStock                          float64 `json:"growthPreferredStock"`
	GrowthCommonStock                             float64 `json:"growthCommonStock"`
	GrowthRetainedEarnings                        float64 `json:"growthRetainedEarnings"`
	GrowthAccumulatedOtherComprehensiveIncomeLoss float64 `json:"growthAccumulatedOtherComprehensiveIncomeLoss"`
	GrowthOtherTotalStockholdersEquity            float64 `json:"growthOthertotalStockholdersEquity"`
	GrowthTotalStockholdersEquity                 float64 `json:"growthTotalStockholdersEquity"`
	GrowthMinorityInterest                        float64 `json:"growthMinorityInterest"`
	GrowthTotalEquity                             float64 `json:"growthTotalEquity"`
	GrowthTotalLiabilitiesAndStockholdersEquity   float64 `json:"growthTotalLiabilitiesAndStockholdersEquity"`
	GrowthTotalInvestments                        float64 `json:"growthTotalInvestments"`
	GrowthTotalDebt                               float64 `json:"growthTotalDebt"`
	GrowthNetDebt                                 float64 `json:"growthNetDebt"`
	GrowthAccountsReceivables                     float64 `json:"growthAccountsReceivables"`
	GrowthOtherReceivables                        float64 `json:"growthOtherReceivables"`
	GrowthPrepaids                                float64 `json:"growthPrepaids"`
	GrowthTotalPayables                           float64 `json:"growthTotalPayables"`
	GrowthOtherPayables                           float64 `json:"growthOtherPayables"`
	GrowthAccruedExpenses                         float64 `json:"growthAccruedExpenses"`
	GrowthCapitalLeaseObligationsCurrent          float64 `json:"growthCapitalLeaseObligationsCurrent"`
	GrowthAdditionalPaidInCapital                 float64 `json:"growthAdditionalPaidInCapital"`
	GrowthTreasuryStock                           float64 `json:"growthTreasuryStock"`
}

BalanceSheetStatementGrowth is one worldwide balance-sheet-statement-growth row.

func (*BalanceSheetStatementGrowth) UnmarshalJSONFrom

func (m *BalanceSheetStatementGrowth) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type BalanceSheetStatementGrowthQuery

type BalanceSheetStatementGrowthQuery struct {
	// contains filtered or unexported fields
}

BalanceSheetStatementGrowthQuery holds the query parameters of the endpoints that take it: NewBalanceSheetStatementGrowthQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewBalanceSheetStatementGrowthQuery

func NewBalanceSheetStatementGrowthQuery(symbol string) BalanceSheetStatementGrowthQuery

NewBalanceSheetStatementGrowthQuery creates the query from its required arguments.

func (BalanceSheetStatementGrowthQuery) Limit

Limit returns the optional limit parameter, or nil when it is unset.

func (BalanceSheetStatementGrowthQuery) Period

Period returns the optional period parameter, or nil when it is unset.

func (BalanceSheetStatementGrowthQuery) Symbol

Symbol returns the symbol argument as given.

func (BalanceSheetStatementGrowthQuery) WithLimit

WithLimit sets the optional limit parameter and returns the updated query.

func (BalanceSheetStatementGrowthQuery) WithPeriod

WithPeriod sets the optional period parameter and returns the updated query.

type BalanceSheetStatementQuery

type BalanceSheetStatementQuery struct {
	// contains filtered or unexported fields
}

BalanceSheetStatementQuery holds the query parameters of the endpoints that take it: NewBalanceSheetStatementQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewBalanceSheetStatementQuery

func NewBalanceSheetStatementQuery(symbol string) BalanceSheetStatementQuery

NewBalanceSheetStatementQuery creates the query from its required arguments.

func (BalanceSheetStatementQuery) Limit

Limit returns the optional limit parameter, or nil when it is unset.

func (BalanceSheetStatementQuery) Period

Period returns the optional period parameter, or nil when it is unset.

func (BalanceSheetStatementQuery) Symbol

Symbol returns the symbol argument as given.

func (BalanceSheetStatementQuery) WithLimit

WithLimit sets the optional limit parameter and returns the updated query.

func (BalanceSheetStatementQuery) WithPeriod

WithPeriod sets the optional period parameter and returns the updated query.

type BalanceSheetStatementTTM added in v0.12.0

type BalanceSheetStatementTTM struct {
	Date                                    Date     `json:"date"`
	Symbol                                  string   `json:"symbol"`
	ReportedCurrency                        string   `json:"reportedCurrency"`
	CIK                                     string   `json:"cik"`
	FilingDate                              Date     `json:"filingDate"`
	AcceptedDate                            DateTime `json:"acceptedDate"`
	FiscalYear                              string   `json:"fiscalYear"`
	Period                                  string   `json:"period"`
	CashAndCashEquivalents                  float64  `json:"cashAndCashEquivalents"`
	ShortTermInvestments                    float64  `json:"shortTermInvestments"`
	CashAndShortTermInvestments             float64  `json:"cashAndShortTermInvestments"`
	NetReceivables                          float64  `json:"netReceivables"`
	AccountsReceivables                     float64  `json:"accountsReceivables"`
	OtherReceivables                        float64  `json:"otherReceivables"`
	Inventory                               float64  `json:"inventory"`
	Prepaids                                float64  `json:"prepaids"`
	OtherCurrentAssets                      float64  `json:"otherCurrentAssets"`
	TotalCurrentAssets                      float64  `json:"totalCurrentAssets"`
	PropertyPlantEquipmentNet               float64  `json:"propertyPlantEquipmentNet"`
	Goodwill                                float64  `json:"goodwill"`
	IntangibleAssets                        float64  `json:"intangibleAssets"`
	GoodwillAndIntangibleAssets             float64  `json:"goodwillAndIntangibleAssets"`
	LongTermInvestments                     float64  `json:"longTermInvestments"`
	TaxAssets                               float64  `json:"taxAssets"`
	OtherNonCurrentAssets                   float64  `json:"otherNonCurrentAssets"`
	TotalNonCurrentAssets                   float64  `json:"totalNonCurrentAssets"`
	OtherAssets                             float64  `json:"otherAssets"`
	TotalAssets                             float64  `json:"totalAssets"`
	TotalPayables                           float64  `json:"totalPayables"`
	AccountPayables                         float64  `json:"accountPayables"`
	OtherPayables                           float64  `json:"otherPayables"`
	AccruedExpenses                         float64  `json:"accruedExpenses"`
	ShortTermDebt                           float64  `json:"shortTermDebt"`
	CapitalLeaseObligationsCurrent          float64  `json:"capitalLeaseObligationsCurrent"`
	TaxPayables                             float64  `json:"taxPayables"`
	DeferredRevenue                         float64  `json:"deferredRevenue"`
	OtherCurrentLiabilities                 float64  `json:"otherCurrentLiabilities"`
	TotalCurrentLiabilities                 float64  `json:"totalCurrentLiabilities"`
	LongTermDebt                            float64  `json:"longTermDebt"`
	DeferredRevenueNonCurrent               float64  `json:"deferredRevenueNonCurrent"`
	DeferredTaxLiabilitiesNonCurrent        float64  `json:"deferredTaxLiabilitiesNonCurrent"`
	OtherNonCurrentLiabilities              float64  `json:"otherNonCurrentLiabilities"`
	TotalNonCurrentLiabilities              float64  `json:"totalNonCurrentLiabilities"`
	OtherLiabilities                        float64  `json:"otherLiabilities"`
	CapitalLeaseObligations                 float64  `json:"capitalLeaseObligations"`
	TotalLiabilities                        float64  `json:"totalLiabilities"`
	TreasuryStock                           float64  `json:"treasuryStock"`
	PreferredStock                          float64  `json:"preferredStock"`
	CommonStock                             float64  `json:"commonStock"`
	RetainedEarnings                        float64  `json:"retainedEarnings"`
	AdditionalPaidInCapital                 float64  `json:"additionalPaidInCapital"`
	AccumulatedOtherComprehensiveIncomeLoss float64  `json:"accumulatedOtherComprehensiveIncomeLoss"`
	OtherTotalStockholdersEquity            float64  `json:"otherTotalStockholdersEquity"`
	TotalStockholdersEquity                 float64  `json:"totalStockholdersEquity"`
	TotalEquity                             float64  `json:"totalEquity"`
	MinorityInterest                        float64  `json:"minorityInterest"`
	TotalLiabilitiesAndTotalEquity          float64  `json:"totalLiabilitiesAndTotalEquity"`
	TotalInvestments                        float64  `json:"totalInvestments"`
	TotalDebt                               float64  `json:"totalDebt"`
	NetDebt                                 float64  `json:"netDebt"`
}

BalanceSheetStatementTTM is one trailing-twelve-month worldwide balance-sheet statement.

func (*BalanceSheetStatementTTM) UnmarshalJSONFrom added in v0.12.0

func (m *BalanceSheetStatementTTM) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type BalanceSheetStatementTTMQuery added in v0.12.0

type BalanceSheetStatementTTMQuery struct {
	// contains filtered or unexported fields
}

BalanceSheetStatementTTMQuery holds the query parameters of the endpoints that take it: NewBalanceSheetStatementTTMQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewBalanceSheetStatementTTMQuery added in v0.12.0

func NewBalanceSheetStatementTTMQuery(symbol string) BalanceSheetStatementTTMQuery

NewBalanceSheetStatementTTMQuery creates the query from its required arguments.

func (BalanceSheetStatementTTMQuery) Limit added in v0.12.0

Limit returns the optional limit parameter, or nil when it is unset.

func (BalanceSheetStatementTTMQuery) Symbol added in v0.12.0

Symbol returns the symbol argument as given.

func (BalanceSheetStatementTTMQuery) WithLimit added in v0.12.0

WithLimit sets the optional limit parameter and returns the updated query.

type BatchAftermarketQuoteQuery

type BatchAftermarketQuoteQuery struct {
	// contains filtered or unexported fields
}

BatchAftermarketQuoteQuery holds the query parameters of the endpoints that take it: NewBatchAftermarketQuoteQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewBatchAftermarketQuoteQuery

func NewBatchAftermarketQuoteQuery(symbols []string) BatchAftermarketQuoteQuery

NewBatchAftermarketQuoteQuery creates the query from its required arguments.

func (BatchAftermarketQuoteQuery) Symbols

func (q BatchAftermarketQuoteQuery) Symbols() []string

Symbols returns the symbols argument as given.

type BatchAftermarketTradeQuery

type BatchAftermarketTradeQuery struct {
	// contains filtered or unexported fields
}

BatchAftermarketTradeQuery holds the query parameters of the endpoints that take it: NewBatchAftermarketTradeQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewBatchAftermarketTradeQuery

func NewBatchAftermarketTradeQuery(symbols []string) BatchAftermarketTradeQuery

NewBatchAftermarketTradeQuery creates the query from its required arguments.

func (BatchAftermarketTradeQuery) Symbols

func (q BatchAftermarketTradeQuery) Symbols() []string

Symbols returns the symbols argument as given.

type BatchMarketCapitalizationQuery added in v0.12.0

type BatchMarketCapitalizationQuery struct {
	// contains filtered or unexported fields
}

BatchMarketCapitalizationQuery holds the query parameters of the endpoints that take it: NewBatchMarketCapitalizationQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewBatchMarketCapitalizationQuery added in v0.12.0

func NewBatchMarketCapitalizationQuery(symbols []string) BatchMarketCapitalizationQuery

NewBatchMarketCapitalizationQuery creates the query from its required arguments.

func (BatchMarketCapitalizationQuery) Symbols added in v0.12.0

func (q BatchMarketCapitalizationQuery) Symbols() []string

Symbols returns the symbols argument as given.

type BatchQuoteQuery

type BatchQuoteQuery struct {
	// contains filtered or unexported fields
}

BatchQuoteQuery holds the query parameters of the endpoints that take it: NewBatchQuoteQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewBatchQuoteQuery

func NewBatchQuoteQuery(symbols []string) BatchQuoteQuery

NewBatchQuoteQuery creates the query from its required arguments.

func (BatchQuoteQuery) Symbols

func (q BatchQuoteQuery) Symbols() []string

Symbols returns the symbols argument as given.

type BatchQuoteShortQuery

type BatchQuoteShortQuery struct {
	// contains filtered or unexported fields
}

BatchQuoteShortQuery holds the query parameters of the endpoints that take it: NewBatchQuoteShortQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewBatchQuoteShortQuery

func NewBatchQuoteShortQuery(symbols []string) BatchQuoteShortQuery

NewBatchQuoteShortQuery creates the query from its required arguments.

func (BatchQuoteShortQuery) Symbols

func (q BatchQuoteShortQuery) Symbols() []string

Symbols returns the symbols argument as given.

type BeneficialOwnershipAcquisition

type BeneficialOwnershipAcquisition struct {
	CIK                              string `json:"cik"`
	Symbol                           string `json:"symbol"`
	FilingDate                       Date   `json:"filingDate"`
	AcceptedDate                     Date   `json:"acceptedDate"`
	CUSIP                            string `json:"cusip"`
	NameOfReportingPerson            string `json:"nameOfReportingPerson"`
	CitizenshipOrPlaceOfOrganization string `json:"citizenshipOrPlaceOfOrganization"`
	SoleVotingPower                  string `json:"soleVotingPower"`
	SharedVotingPower                string `json:"sharedVotingPower"`
	SoleDispositivePower             string `json:"soleDispositivePower"`
	SharedDispositivePower           string `json:"sharedDispositivePower"`
	AmountBeneficiallyOwned          string `json:"amountBeneficiallyOwned"`
	PercentOfClass                   string `json:"percentOfClass"`
	TypeOfReportingPerson            string `json:"typeOfReportingPerson"`
	URL                              string `json:"url"`
}

BeneficialOwnershipAcquisition is one beneficial-ownership acquisition filing row.

func (*BeneficialOwnershipAcquisition) UnmarshalJSONFrom

func (m *BeneficialOwnershipAcquisition) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type BeneficialOwnershipAcquisitionsQuery

type BeneficialOwnershipAcquisitionsQuery struct {
	// contains filtered or unexported fields
}

BeneficialOwnershipAcquisitionsQuery holds the query parameters of the endpoints that take it: NewBeneficialOwnershipAcquisitionsQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewBeneficialOwnershipAcquisitionsQuery

func NewBeneficialOwnershipAcquisitionsQuery(symbol string) BeneficialOwnershipAcquisitionsQuery

NewBeneficialOwnershipAcquisitionsQuery creates the query from its required arguments.

func (BeneficialOwnershipAcquisitionsQuery) Limit

Limit returns the optional limit parameter, or nil when it is unset.

func (BeneficialOwnershipAcquisitionsQuery) Symbol

Symbol returns the symbol argument as given.

func (BeneficialOwnershipAcquisitionsQuery) WithLimit

WithLimit sets the optional limit parameter and returns the updated query.

type BinaryPayload

type BinaryPayload struct {
	Data               []byte
	ContentType        string
	ContentDisposition string
}

BinaryPayload is an owned binary response with validated media metadata. It mirrors BinaryResponse in the Rust crate.

ContentType is retained exactly as received after the endpoint contract validated its media type. ContentDisposition is retained when the header was present and valid text, and is "" otherwise. Formatting a payload with any fmt verb prints the byte count, the media type, and whether a disposition is present: never the bytes and never the disposition, which can carry an opaque filename or other provider-controlled text.

func (BinaryPayload) Format

func (p BinaryPayload) Format(f fmt.State, _ rune)

Format prints the payload shape without the bytes or the disposition.

func (BinaryPayload) MediaType

func (p BinaryPayload) MediaType() string

MediaType returns ContentType without its parameters.

type BulkBalanceSheetStatement

type BulkBalanceSheetStatement struct {
	Date                                    Date     `json:"date"`
	Symbol                                  string   `json:"symbol"`
	ReportedCurrency                        string   `json:"reportedCurrency"`
	CIK                                     string   `json:"cik"`
	FilingDate                              Date     `json:"filingDate"`
	AcceptedDate                            DateTime `json:"acceptedDate"`
	FiscalYear                              string   `json:"fiscalYear"`
	Period                                  string   `json:"period"`
	CashAndCashEquivalents                  string   `json:"cashAndCashEquivalents"`
	ShortTermInvestments                    string   `json:"shortTermInvestments"`
	CashAndShortTermInvestments             string   `json:"cashAndShortTermInvestments"`
	NetReceivables                          string   `json:"netReceivables"`
	AccountsReceivables                     string   `json:"accountsReceivables"`
	OtherReceivables                        string   `json:"otherReceivables"`
	Inventory                               string   `json:"inventory"`
	Prepaids                                string   `json:"prepaids"`
	OtherCurrentAssets                      string   `json:"otherCurrentAssets"`
	TotalCurrentAssets                      string   `json:"totalCurrentAssets"`
	PropertyPlantEquipmentNet               string   `json:"propertyPlantEquipmentNet"`
	Goodwill                                string   `json:"goodwill"`
	IntangibleAssets                        string   `json:"intangibleAssets"`
	GoodwillAndIntangibleAssets             string   `json:"goodwillAndIntangibleAssets"`
	LongTermInvestments                     string   `json:"longTermInvestments"`
	TaxAssets                               string   `json:"taxAssets"`
	OtherNonCurrentAssets                   string   `json:"otherNonCurrentAssets"`
	TotalNonCurrentAssets                   string   `json:"totalNonCurrentAssets"`
	OtherAssets                             string   `json:"otherAssets"`
	TotalAssets                             string   `json:"totalAssets"`
	TotalPayables                           string   `json:"totalPayables"`
	AccountPayables                         string   `json:"accountPayables"`
	OtherPayables                           string   `json:"otherPayables"`
	AccruedExpenses                         string   `json:"accruedExpenses"`
	ShortTermDebt                           string   `json:"shortTermDebt"`
	CapitalLeaseObligationsCurrent          string   `json:"capitalLeaseObligationsCurrent"`
	TaxPayables                             string   `json:"taxPayables"`
	DeferredRevenue                         string   `json:"deferredRevenue"`
	OtherCurrentLiabilities                 string   `json:"otherCurrentLiabilities"`
	TotalCurrentLiabilities                 string   `json:"totalCurrentLiabilities"`
	LongTermDebt                            string   `json:"longTermDebt"`
	CapitalLeaseObligationsNonCurrent       string   `json:"capitalLeaseObligationsNonCurrent"`
	DeferredRevenueNonCurrent               string   `json:"deferredRevenueNonCurrent"`
	DeferredTaxLiabilitiesNonCurrent        string   `json:"deferredTaxLiabilitiesNonCurrent"`
	OtherNonCurrentLiabilities              string   `json:"otherNonCurrentLiabilities"`
	TotalNonCurrentLiabilities              string   `json:"totalNonCurrentLiabilities"`
	OtherLiabilities                        string   `json:"otherLiabilities"`
	CapitalLeaseObligations                 string   `json:"capitalLeaseObligations"`
	TotalLiabilities                        string   `json:"totalLiabilities"`
	TreasuryStock                           string   `json:"treasuryStock"`
	PreferredStock                          string   `json:"preferredStock"`
	CommonStock                             string   `json:"commonStock"`
	RetainedEarnings                        string   `json:"retainedEarnings"`
	AdditionalPaidInCapital                 string   `json:"additionalPaidInCapital"`
	AccumulatedOtherComprehensiveIncomeLoss string   `json:"accumulatedOtherComprehensiveIncomeLoss"`
	OtherTotalStockholdersEquity            string   `json:"otherTotalStockholdersEquity"`
	TotalStockholdersEquity                 string   `json:"totalStockholdersEquity"`
	TotalEquity                             string   `json:"totalEquity"`
	MinorityInterest                        string   `json:"minorityInterest"`
	TotalLiabilitiesAndTotalEquity          string   `json:"totalLiabilitiesAndTotalEquity"`
	TotalInvestments                        string   `json:"totalInvestments"`
	TotalDebt                               string   `json:"totalDebt"`
	NetDebt                                 string   `json:"netDebt"`
}

BulkBalanceSheetStatement is one worldwide bulk balance-sheet-statement row.

func (*BulkBalanceSheetStatement) UnmarshalJSONFrom

func (m *BulkBalanceSheetStatement) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type BulkBalanceSheetStatementGrowth

type BulkBalanceSheetStatementGrowth struct {
	Symbol                                        string `json:"symbol"`
	Date                                          Date   `json:"date"`
	FiscalYear                                    string `json:"fiscalYear"`
	Period                                        string `json:"period"`
	ReportedCurrency                              string `json:"reportedCurrency"`
	GrowthCashAndCashEquivalents                  string `json:"growthCashAndCashEquivalents"`
	GrowthShortTermInvestments                    string `json:"growthShortTermInvestments"`
	GrowthCashAndShortTermInvestments             string `json:"growthCashAndShortTermInvestments"`
	GrowthNetReceivables                          string `json:"growthNetReceivables"`
	GrowthInventory                               string `json:"growthInventory"`
	GrowthOtherCurrentAssets                      string `json:"growthOtherCurrentAssets"`
	GrowthTotalCurrentAssets                      string `json:"growthTotalCurrentAssets"`
	GrowthPropertyPlantEquipmentNet               string `json:"growthPropertyPlantEquipmentNet"`
	GrowthGoodwill                                string `json:"growthGoodwill"`
	GrowthIntangibleAssets                        string `json:"growthIntangibleAssets"`
	GrowthGoodwillAndIntangibleAssets             string `json:"growthGoodwillAndIntangibleAssets"`
	GrowthLongTermInvestments                     string `json:"growthLongTermInvestments"`
	GrowthTaxAssets                               string `json:"growthTaxAssets"`
	GrowthOtherNonCurrentAssets                   string `json:"growthOtherNonCurrentAssets"`
	GrowthTotalNonCurrentAssets                   string `json:"growthTotalNonCurrentAssets"`
	GrowthOtherAssets                             string `json:"growthOtherAssets"`
	GrowthTotalAssets                             string `json:"growthTotalAssets"`
	GrowthAccountPayables                         string `json:"growthAccountPayables"`
	GrowthShortTermDebt                           string `json:"growthShortTermDebt"`
	GrowthTaxPayables                             string `json:"growthTaxPayables"`
	GrowthDeferredRevenue                         string `json:"growthDeferredRevenue"`
	GrowthOtherCurrentLiabilities                 string `json:"growthOtherCurrentLiabilities"`
	GrowthTotalCurrentLiabilities                 string `json:"growthTotalCurrentLiabilities"`
	GrowthLongTermDebt                            string `json:"growthLongTermDebt"`
	GrowthDeferredRevenueNonCurrent               string `json:"growthDeferredRevenueNonCurrent"`
	GrowthDeferredTaxLiabilitiesNonCurrent        string `json:"growthDeferredTaxLiabilitiesNonCurrent"`
	GrowthOtherNonCurrentLiabilities              string `json:"growthOtherNonCurrentLiabilities"`
	GrowthTotalNonCurrentLiabilities              string `json:"growthTotalNonCurrentLiabilities"`
	GrowthOtherLiabilities                        string `json:"growthOtherLiabilities"`
	GrowthTotalLiabilities                        string `json:"growthTotalLiabilities"`
	GrowthPreferredStock                          string `json:"growthPreferredStock"`
	GrowthCommonStock                             string `json:"growthCommonStock"`
	GrowthRetainedEarnings                        string `json:"growthRetainedEarnings"`
	GrowthAccumulatedOtherComprehensiveIncomeLoss string `json:"growthAccumulatedOtherComprehensiveIncomeLoss"`
	GrowthOtherTotalStockholdersEquity            string `json:"growthOthertotalStockholdersEquity"`
	GrowthTotalStockholdersEquity                 string `json:"growthTotalStockholdersEquity"`
	GrowthMinorityInterest                        string `json:"growthMinorityInterest"`
	GrowthTotalEquity                             string `json:"growthTotalEquity"`
	GrowthTotalLiabilitiesAndStockholdersEquity   string `json:"growthTotalLiabilitiesAndStockholdersEquity"`
	GrowthTotalInvestments                        string `json:"growthTotalInvestments"`
	GrowthTotalDebt                               string `json:"growthTotalDebt"`
	GrowthNetDebt                                 string `json:"growthNetDebt"`
	GrowthAccountsReceivables                     string `json:"growthAccountsReceivables"`
	GrowthOtherReceivables                        string `json:"growthOtherReceivables"`
	GrowthPrepaids                                string `json:"growthPrepaids"`
	GrowthTotalPayables                           string `json:"growthTotalPayables"`
	GrowthOtherPayables                           string `json:"growthOtherPayables"`
	GrowthAccruedExpenses                         string `json:"growthAccruedExpenses"`
	GrowthCapitalLeaseObligationsCurrent          string `json:"growthCapitalLeaseObligationsCurrent"`
	GrowthAdditionalPaidInCapital                 string `json:"growthAdditionalPaidInCapital"`
	GrowthTreasuryStock                           string `json:"growthTreasuryStock"`
}

BulkBalanceSheetStatementGrowth is one worldwide bulk balance-sheet-statement-growth row.

func (*BulkBalanceSheetStatementGrowth) UnmarshalJSONFrom

func (m *BulkBalanceSheetStatementGrowth) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type BulkCashFlowStatement

type BulkCashFlowStatement struct {
	Date                                   Date     `json:"date"`
	Symbol                                 string   `json:"symbol"`
	ReportedCurrency                       string   `json:"reportedCurrency"`
	CIK                                    string   `json:"cik"`
	FilingDate                             Date     `json:"filingDate"`
	AcceptedDate                           DateTime `json:"acceptedDate"`
	FiscalYear                             string   `json:"fiscalYear"`
	Period                                 string   `json:"period"`
	NetIncome                              string   `json:"netIncome"`
	DepreciationAndAmortization            string   `json:"depreciationAndAmortization"`
	DeferredIncomeTax                      string   `json:"deferredIncomeTax"`
	StockBasedCompensation                 string   `json:"stockBasedCompensation"`
	ChangeInWorkingCapital                 string   `json:"changeInWorkingCapital"`
	AccountsReceivables                    string   `json:"accountsReceivables"`
	Inventory                              string   `json:"inventory"`
	AccountsPayables                       string   `json:"accountsPayables"`
	OtherWorkingCapital                    string   `json:"otherWorkingCapital"`
	OtherNonCashItems                      string   `json:"otherNonCashItems"`
	NetCashProvidedByOperatingActivities   string   `json:"netCashProvidedByOperatingActivities"`
	InvestmentsInPropertyPlantAndEquipment string   `json:"investmentsInPropertyPlantAndEquipment"`
	AcquisitionsNet                        string   `json:"acquisitionsNet"`
	PurchasesOfInvestments                 string   `json:"purchasesOfInvestments"`
	SalesMaturitiesOfInvestments           string   `json:"salesMaturitiesOfInvestments"`
	OtherInvestingActivities               string   `json:"otherInvestingActivities"`
	NetCashProvidedByInvestingActivities   string   `json:"netCashProvidedByInvestingActivities"`
	NetDebtIssuance                        string   `json:"netDebtIssuance"`
	LongTermNetDebtIssuance                string   `json:"longTermNetDebtIssuance"`
	ShortTermNetDebtIssuance               string   `json:"shortTermNetDebtIssuance"`
	NetStockIssuance                       string   `json:"netStockIssuance"`
	NetCommonStockIssuance                 string   `json:"netCommonStockIssuance"`
	CommonStockIssuance                    string   `json:"commonStockIssuance"`
	CommonStockRepurchased                 string   `json:"commonStockRepurchased"`
	NetPreferredStockIssuance              string   `json:"netPreferredStockIssuance"`
	NetDividendsPaid                       string   `json:"netDividendsPaid"`
	CommonDividendsPaid                    string   `json:"commonDividendsPaid"`
	PreferredDividendsPaid                 string   `json:"preferredDividendsPaid"`
	OtherFinancingActivities               string   `json:"otherFinancingActivities"`
	NetCashProvidedByFinancingActivities   string   `json:"netCashProvidedByFinancingActivities"`
	EffectOfForexChangesOnCash             string   `json:"effectOfForexChangesOnCash"`
	NetChangeInCash                        string   `json:"netChangeInCash"`
	CashAtEndOfPeriod                      string   `json:"cashAtEndOfPeriod"`
	CashAtBeginningOfPeriod                string   `json:"cashAtBeginningOfPeriod"`
	OperatingCashFlow                      string   `json:"operatingCashFlow"`
	CapitalExpenditure                     string   `json:"capitalExpenditure"`
	FreeCashFlow                           string   `json:"freeCashFlow"`
	IncomeTaxesPaid                        string   `json:"incomeTaxesPaid"`
	InterestPaid                           string   `json:"interestPaid"`
}

BulkCashFlowStatement is one worldwide bulk cash-flow-statement row.

func (*BulkCashFlowStatement) UnmarshalJSONFrom

func (m *BulkCashFlowStatement) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type BulkCashFlowStatementGrowth

type BulkCashFlowStatementGrowth struct {
	Symbol                                         string `json:"symbol"`
	Date                                           Date   `json:"date"`
	FiscalYear                                     string `json:"fiscalYear"`
	Period                                         string `json:"period"`
	ReportedCurrency                               string `json:"reportedCurrency"`
	GrowthNetIncome                                string `json:"growthNetIncome"`
	GrowthDepreciationAndAmortization              string `json:"growthDepreciationAndAmortization"`
	GrowthDeferredIncomeTax                        string `json:"growthDeferredIncomeTax"`
	GrowthStockBasedCompensation                   string `json:"growthStockBasedCompensation"`
	GrowthChangeInWorkingCapital                   string `json:"growthChangeInWorkingCapital"`
	GrowthAccountsReceivables                      string `json:"growthAccountsReceivables"`
	GrowthInventory                                string `json:"growthInventory"`
	GrowthAccountsPayables                         string `json:"growthAccountsPayables"`
	GrowthOtherWorkingCapital                      string `json:"growthOtherWorkingCapital"`
	GrowthOtherNonCashItems                        string `json:"growthOtherNonCashItems"`
	GrowthNetCashProvidedByOperatingActivities     string `json:"growthNetCashProvidedByOperatingActivites"`
	GrowthInvestmentsInPropertyPlantAndEquipment   string `json:"growthInvestmentsInPropertyPlantAndEquipment"`
	GrowthAcquisitionsNet                          string `json:"growthAcquisitionsNet"`
	GrowthPurchasesOfInvestments                   string `json:"growthPurchasesOfInvestments"`
	GrowthSalesMaturitiesOfInvestments             string `json:"growthSalesMaturitiesOfInvestments"`
	GrowthOtherInvestingActivities                 string `json:"growthOtherInvestingActivites"`
	GrowthNetCashUsedForInvestingActivities        string `json:"growthNetCashUsedForInvestingActivites"`
	GrowthDebtRepayment                            string `json:"growthDebtRepayment"`
	GrowthCommonStockIssued                        string `json:"growthCommonStockIssued"`
	GrowthCommonStockRepurchased                   string `json:"growthCommonStockRepurchased"`
	GrowthDividendsPaid                            string `json:"growthDividendsPaid"`
	GrowthOtherFinancingActivities                 string `json:"growthOtherFinancingActivites"`
	GrowthNetCashUsedProvidedByFinancingActivities string `json:"growthNetCashUsedProvidedByFinancingActivities"`
	GrowthEffectOfForexChangesOnCash               string `json:"growthEffectOfForexChangesOnCash"`
	GrowthNetChangeInCash                          string `json:"growthNetChangeInCash"`
	GrowthCashAtEndOfPeriod                        string `json:"growthCashAtEndOfPeriod"`
	GrowthCashAtBeginningOfPeriod                  string `json:"growthCashAtBeginningOfPeriod"`
	GrowthOperatingCashFlow                        string `json:"growthOperatingCashFlow"`
	GrowthCapitalExpenditure                       string `json:"growthCapitalExpenditure"`
	GrowthFreeCashFlow                             string `json:"growthFreeCashFlow"`
	GrowthNetDebtIssuance                          string `json:"growthNetDebtIssuance"`
	GrowthLongTermNetDebtIssuance                  string `json:"growthLongTermNetDebtIssuance"`
	GrowthShortTermNetDebtIssuance                 string `json:"growthShortTermNetDebtIssuance"`
	GrowthNetStockIssuance                         string `json:"growthNetStockIssuance"`
	GrowthPreferredDividendsPaid                   string `json:"growthPreferredDividendsPaid"`
	GrowthIncomeTaxesPaid                          string `json:"growthIncomeTaxesPaid"`
	GrowthInterestPaid                             string `json:"growthInterestPaid"`
}

BulkCashFlowStatementGrowth is one worldwide bulk cash-flow-statement-growth row.

func (*BulkCashFlowStatementGrowth) UnmarshalJSONFrom

func (m *BulkCashFlowStatementGrowth) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type BulkDCFValuation added in v0.12.0

type BulkDCFValuation struct {
	Symbol     string `json:"symbol"`
	Date       Date   `json:"date"`
	DCF        string `json:"dcf"`
	StockPrice string `json:"Stock Price"`
}

BulkDCFValuation is one worldwide discounted-cash-flow bulk row.

func (*BulkDCFValuation) UnmarshalJSONFrom added in v0.12.0

func (m *BulkDCFValuation) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type BulkETFHolding added in v0.12.0

type BulkETFHolding struct {
	Symbol           string `json:"symbol"`
	Name             string `json:"name"`
	SharesNumber     string `json:"sharesNumber"`
	Asset            string `json:"asset"`
	WeightPercentage string `json:"weightPercentage"`
	CUSIP            string `json:"cusip"`
	ISIN             string `json:"isin"`
	MarketValue      string `json:"marketValue"`
	LastUpdatedRaw   string `json:"-"`
}

BulkETFHolding is one worldwide ETF holding bulk row.

func (BulkETFHolding) MarshalJSONTo added in v0.12.0

func (m BulkETFHolding) MarshalJSONTo(enc *jsontext.Encoder) error

MarshalJSONTo encodes the object with every member under its exact wire name, including the names json/v2 cannot spell in a struct tag. The value receiver keeps non-addressable values, such as slice elements, on this path.

func (*BulkETFHolding) UnmarshalJSONFrom added in v0.12.0

func (m *BulkETFHolding) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type BulkEarningsSurprise

type BulkEarningsSurprise struct {
	Symbol       string `json:"symbol"`
	Date         Date   `json:"date"`
	EPSActual    string `json:"epsActual"`
	EPSEstimated string `json:"epsEstimated"`
	LastUpdated  Date   `json:"lastUpdated"`
}

BulkEarningsSurprise is one worldwide annual earnings-surprise bulk row.

func (*BulkEarningsSurprise) UnmarshalJSONFrom

func (m *BulkEarningsSurprise) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type BulkEodBar

type BulkEodBar struct {
	Symbol   string `json:"symbol"`
	Date     Date   `json:"date"`
	Open     string `json:"open"`
	Low      string `json:"low"`
	High     string `json:"high"`
	Close    string `json:"close"`
	AdjClose string `json:"adjClose"`
	Volume   string `json:"volume"`
}

BulkEodBar is one worldwide bulk end-of-day price row.

func (*BulkEodBar) UnmarshalJSONFrom

func (m *BulkEodBar) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type BulkEodQuery

type BulkEodQuery struct {
	// contains filtered or unexported fields
}

BulkEodQuery holds the query parameters of the endpoints that take it: NewBulkEodQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewBulkEodQuery

func NewBulkEodQuery(date Date) BulkEodQuery

NewBulkEodQuery creates the query from its required arguments.

func (BulkEodQuery) Date

func (q BulkEodQuery) Date() Date

Date returns the date argument as given.

type BulkFinancialRatiosTTM added in v0.12.0

type BulkFinancialRatiosTTM struct {
	Symbol                                     string `json:"symbol"`
	GrossProfitMarginTTM                       string `json:"grossProfitMarginTTM"`
	EbitMarginTTM                              string `json:"ebitMarginTTM"`
	EbitdaMarginTTM                            string `json:"ebitdaMarginTTM"`
	OperatingProfitMarginTTM                   string `json:"operatingProfitMarginTTM"`
	PretaxProfitMarginTTM                      string `json:"pretaxProfitMarginTTM"`
	ContinuousOperationsProfitMarginTTM        string `json:"continuousOperationsProfitMarginTTM"`
	NetProfitMarginTTM                         string `json:"netProfitMarginTTM"`
	BottomLineProfitMarginTTM                  string `json:"bottomLineProfitMarginTTM"`
	ReceivablesTurnoverTTM                     string `json:"receivablesTurnoverTTM"`
	PayablesTurnoverTTM                        string `json:"payablesTurnoverTTM"`
	InventoryTurnoverTTM                       string `json:"inventoryTurnoverTTM"`
	FixedAssetTurnoverTTM                      string `json:"fixedAssetTurnoverTTM"`
	AssetTurnoverTTM                           string `json:"assetTurnoverTTM"`
	CurrentRatioTTM                            string `json:"currentRatioTTM"`
	QuickRatioTTM                              string `json:"quickRatioTTM"`
	SolvencyRatioTTM                           string `json:"solvencyRatioTTM"`
	CashRatioTTM                               string `json:"cashRatioTTM"`
	PriceToEarningsRatioTTM                    string `json:"priceToEarningsRatioTTM"`
	PriceToEarningsGrowthRatioTTM              string `json:"priceToEarningsGrowthRatioTTM"`
	ForwardPriceToEarningsGrowthRatioTTM       string `json:"forwardPriceToEarningsGrowthRatioTTM"`
	PriceToBookRatioTTM                        string `json:"priceToBookRatioTTM"`
	PriceToSalesRatioTTM                       string `json:"priceToSalesRatioTTM"`
	PriceToFreeCashFlowRatioTTM                string `json:"priceToFreeCashFlowRatioTTM"`
	PriceToOperatingCashFlowRatioTTM           string `json:"priceToOperatingCashFlowRatioTTM"`
	DebtToAssetsRatioTTM                       string `json:"debtToAssetsRatioTTM"`
	DebtToEquityRatioTTM                       string `json:"debtToEquityRatioTTM"`
	DebtToCapitalRatioTTM                      string `json:"debtToCapitalRatioTTM"`
	LongTermDebtToCapitalRatioTTM              string `json:"longTermDebtToCapitalRatioTTM"`
	FinancialLeverageRatioTTM                  string `json:"financialLeverageRatioTTM"`
	WorkingCapitalTurnoverRatioTTM             string `json:"workingCapitalTurnoverRatioTTM"`
	OperatingCashFlowRatioTTM                  string `json:"operatingCashFlowRatioTTM"`
	OperatingCashFlowSalesRatioTTM             string `json:"operatingCashFlowSalesRatioTTM"`
	FreeCashFlowOperatingCashFlowRatioTTM      string `json:"freeCashFlowOperatingCashFlowRatioTTM"`
	DebtServiceCoverageRatioTTM                string `json:"debtServiceCoverageRatioTTM"`
	InterestCoverageRatioTTM                   string `json:"interestCoverageRatioTTM"`
	ShortTermOperatingCashFlowCoverageRatioTTM string `json:"shortTermOperatingCashFlowCoverageRatioTTM"`
	OperatingCashFlowCoverageRatioTTM          string `json:"operatingCashFlowCoverageRatioTTM"`
	CapitalExpenditureCoverageRatioTTM         string `json:"capitalExpenditureCoverageRatioTTM"`
	DividendPaidAndCapexCoverageRatioTTM       string `json:"dividendPaidAndCapexCoverageRatioTTM"`
	DividendPayoutRatioTTM                     string `json:"dividendPayoutRatioTTM"`
	DividendYieldTTM                           string `json:"dividendYieldTTM"`
	EnterpriseValueTTM                         string `json:"enterpriseValueTTM"`
	RevenuePerShareTTM                         string `json:"revenuePerShareTTM"`
	NetIncomePerShareTTM                       string `json:"netIncomePerShareTTM"`
	InterestDebtPerShareTTM                    string `json:"interestDebtPerShareTTM"`
	CashPerShareTTM                            string `json:"cashPerShareTTM"`
	BookValuePerShareTTM                       string `json:"bookValuePerShareTTM"`
	TangibleBookValuePerShareTTM               string `json:"tangibleBookValuePerShareTTM"`
	ShareholdersEquityPerShareTTM              string `json:"shareholdersEquityPerShareTTM"`
	OperatingCashFlowPerShareTTM               string `json:"operatingCashFlowPerShareTTM"`
	CapexPerShareTTM                           string `json:"capexPerShareTTM"`
	FreeCashFlowPerShareTTM                    string `json:"freeCashFlowPerShareTTM"`
	NetIncomePerEbtTTM                         string `json:"netIncomePerEBTTTM"`
	EbtPerEbitTTM                              string `json:"ebtPerEbitTTM"`
	PriceToFairValueTTM                        string `json:"priceToFairValueTTM"`
	DebtToMarketCapTTM                         string `json:"debtToMarketCapTTM"`
	EffectiveTaxRateTTM                        string `json:"effectiveTaxRateTTM"`
	EnterpriseValueMultipleTTM                 string `json:"enterpriseValueMultipleTTM"`
	DividendPerShareTTM                        string `json:"dividendPerShareTTM"`
}

BulkFinancialRatiosTTM is one worldwide financial-ratios trailing-twelve-month bulk row.

func (*BulkFinancialRatiosTTM) UnmarshalJSONFrom added in v0.12.0

func (m *BulkFinancialRatiosTTM) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type BulkFinancialScore

type BulkFinancialScore struct {
	Symbol           string `json:"symbol"`
	ReportedCurrency string `json:"reportedCurrency"`
	AltmanZScore     string `json:"altmanZScore"`
	PiotroskiScore   string `json:"piotroskiScore"`
	WorkingCapital   string `json:"workingCapital"`
	TotalAssets      string `json:"totalAssets"`
	RetainedEarnings string `json:"retainedEarnings"`
	Ebit             string `json:"ebit"`
	MarketCap        string `json:"marketCap"`
	TotalLiabilities string `json:"totalLiabilities"`
	Revenue          string `json:"revenue"`
}

BulkFinancialScore is one worldwide financial-score bulk row.

func (*BulkFinancialScore) UnmarshalJSONFrom

func (m *BulkFinancialScore) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type BulkIncomeStatement

type BulkIncomeStatement struct {
	Date                                    Date     `json:"date"`
	Symbol                                  string   `json:"symbol"`
	ReportedCurrency                        string   `json:"reportedCurrency"`
	CIK                                     string   `json:"cik"`
	FilingDate                              Date     `json:"filingDate"`
	AcceptedDate                            DateTime `json:"acceptedDate"`
	FiscalYear                              string   `json:"fiscalYear"`
	Period                                  string   `json:"period"`
	Revenue                                 string   `json:"revenue"`
	CostOfRevenue                           string   `json:"costOfRevenue"`
	GrossProfit                             string   `json:"grossProfit"`
	ResearchAndDevelopmentExpenses          string   `json:"researchAndDevelopmentExpenses"`
	GeneralAndAdministrativeExpenses        string   `json:"generalAndAdministrativeExpenses"`
	SellingAndMarketingExpenses             string   `json:"sellingAndMarketingExpenses"`
	SellingGeneralAndAdministrativeExpenses string   `json:"sellingGeneralAndAdministrativeExpenses"`
	OtherExpenses                           string   `json:"otherExpenses"`
	OperatingExpenses                       string   `json:"operatingExpenses"`
	CostAndExpenses                         string   `json:"costAndExpenses"`
	NetInterestIncome                       string   `json:"netInterestIncome"`
	InterestIncome                          string   `json:"interestIncome"`
	InterestExpense                         string   `json:"interestExpense"`
	DepreciationAndAmortization             string   `json:"depreciationAndAmortization"`
	Ebitda                                  string   `json:"ebitda"`
	Ebit                                    string   `json:"ebit"`
	NonOperatingIncomeExcludingInterest     string   `json:"nonOperatingIncomeExcludingInterest"`
	OperatingIncome                         string   `json:"operatingIncome"`
	TotalOtherIncomeExpensesNet             string   `json:"totalOtherIncomeExpensesNet"`
	IncomeBeforeTax                         string   `json:"incomeBeforeTax"`
	IncomeTaxExpense                        string   `json:"incomeTaxExpense"`
	NetIncomeFromContinuingOperations       string   `json:"netIncomeFromContinuingOperations"`
	NetIncomeFromDiscontinuedOperations     string   `json:"netIncomeFromDiscontinuedOperations"`
	OtherAdjustmentsToNetIncome             string   `json:"otherAdjustmentsToNetIncome"`
	NetIncome                               string   `json:"netIncome"`
	NetIncomeDeductions                     string   `json:"netIncomeDeductions"`
	BottomLineNetIncome                     string   `json:"bottomLineNetIncome"`
	EPS                                     string   `json:"eps"`
	EPSDiluted                              string   `json:"epsDiluted"`
	WeightedAverageShsOut                   string   `json:"weightedAverageShsOut"`
	WeightedAverageShsOutDil                string   `json:"weightedAverageShsOutDil"`
}

BulkIncomeStatement is one worldwide bulk income-statement row.

func (*BulkIncomeStatement) UnmarshalJSONFrom

func (m *BulkIncomeStatement) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type BulkIncomeStatementGrowth

type BulkIncomeStatementGrowth struct {
	Symbol                                    string `json:"symbol"`
	Date                                      Date   `json:"date"`
	FiscalYear                                string `json:"fiscalYear"`
	Period                                    string `json:"period"`
	ReportedCurrency                          string `json:"reportedCurrency"`
	GrowthRevenue                             string `json:"growthRevenue"`
	GrowthCostOfRevenue                       string `json:"growthCostOfRevenue"`
	GrowthGrossProfit                         string `json:"growthGrossProfit"`
	GrowthGrossProfitRatio                    string `json:"growthGrossProfitRatio"`
	GrowthResearchAndDevelopmentExpenses      string `json:"growthResearchAndDevelopmentExpenses"`
	GrowthGeneralAndAdministrativeExpenses    string `json:"growthGeneralAndAdministrativeExpenses"`
	GrowthSellingAndMarketingExpenses         string `json:"growthSellingAndMarketingExpenses"`
	GrowthOtherExpenses                       string `json:"growthOtherExpenses"`
	GrowthOperatingExpenses                   string `json:"growthOperatingExpenses"`
	GrowthCostAndExpenses                     string `json:"growthCostAndExpenses"`
	GrowthInterestIncome                      string `json:"growthInterestIncome"`
	GrowthInterestExpense                     string `json:"growthInterestExpense"`
	GrowthDepreciationAndAmortization         string `json:"growthDepreciationAndAmortization"`
	GrowthEbitda                              string `json:"growthEBITDA"`
	GrowthOperatingIncome                     string `json:"growthOperatingIncome"`
	GrowthIncomeBeforeTax                     string `json:"growthIncomeBeforeTax"`
	GrowthIncomeTaxExpense                    string `json:"growthIncomeTaxExpense"`
	GrowthNetIncome                           string `json:"growthNetIncome"`
	GrowthEPS                                 string `json:"growthEPS"`
	GrowthEPSDiluted                          string `json:"growthEPSDiluted"`
	GrowthWeightedAverageShsOut               string `json:"growthWeightedAverageShsOut"`
	GrowthWeightedAverageShsOutDil            string `json:"growthWeightedAverageShsOutDil"`
	GrowthEbit                                string `json:"growthEBIT"`
	GrowthNonOperatingIncomeExcludingInterest string `json:"growthNonOperatingIncomeExcludingInterest"`
	GrowthNetInterestIncome                   string `json:"growthNetInterestIncome"`
	GrowthTotalOtherIncomeExpensesNet         string `json:"growthTotalOtherIncomeExpensesNet"`
	GrowthNetIncomeFromContinuingOperations   string `json:"growthNetIncomeFromContinuingOperations"`
	GrowthOtherAdjustmentsToNetIncome         string `json:"growthOtherAdjustmentsToNetIncome"`
	GrowthNetIncomeDeductions                 string `json:"growthNetIncomeDeductions"`
}

BulkIncomeStatementGrowth is one worldwide bulk income-statement-growth row.

func (*BulkIncomeStatementGrowth) UnmarshalJSONFrom

func (m *BulkIncomeStatementGrowth) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type BulkKeyMetricsTTM added in v0.12.0

type BulkKeyMetricsTTM struct {
	Symbol                                    string `json:"symbol"`
	MarketCap                                 string `json:"marketCap"`
	EnterpriseValueTTM                        string `json:"enterpriseValueTTM"`
	EvToSalesTTM                              string `json:"evToSalesTTM"`
	EvToOperatingCashFlowTTM                  string `json:"evToOperatingCashFlowTTM"`
	EvToFreeCashFlowTTM                       string `json:"evToFreeCashFlowTTM"`
	EvToEbitdaTTM                             string `json:"evToEBITDATTM"`
	NetDebtToEbitdaTTM                        string `json:"netDebtToEBITDATTM"`
	CurrentRatioTTM                           string `json:"currentRatioTTM"`
	IncomeQualityTTM                          string `json:"incomeQualityTTM"`
	GrahamNumberTTM                           string `json:"grahamNumberTTM"`
	GrahamNetNetTTM                           string `json:"grahamNetNetTTM"`
	TaxBurdenTTM                              string `json:"taxBurdenTTM"`
	InterestBurdenTTM                         string `json:"interestBurdenTTM"`
	WorkingCapitalTTM                         string `json:"workingCapitalTTM"`
	InvestedCapitalTTM                        string `json:"investedCapitalTTM"`
	ReturnOnAssetsTTM                         string `json:"returnOnAssetsTTM"`
	OperatingReturnOnAssetsTTM                string `json:"operatingReturnOnAssetsTTM"`
	ReturnOnTangibleAssetsTTM                 string `json:"returnOnTangibleAssetsTTM"`
	ReturnOnEquityTTM                         string `json:"returnOnEquityTTM"`
	ReturnOnInvestedCapitalTTM                string `json:"returnOnInvestedCapitalTTM"`
	ReturnOnCapitalEmployedTTM                string `json:"returnOnCapitalEmployedTTM"`
	EarningsYieldTTM                          string `json:"earningsYieldTTM"`
	FreeCashFlowYieldTTM                      string `json:"freeCashFlowYieldTTM"`
	CapexToOperatingCashFlowTTM               string `json:"capexToOperatingCashFlowTTM"`
	CapexToDepreciationTTM                    string `json:"capexToDepreciationTTM"`
	CapexToRevenueTTM                         string `json:"capexToRevenueTTM"`
	SalesGeneralAndAdministrativeToRevenueTTM string `json:"salesGeneralAndAdministrativeToRevenueTTM"`
	ResearchAndDevelopmentToRevenueTTM        string `json:"researchAndDevelopementToRevenueTTM"`
	StockBasedCompensationToRevenueTTM        string `json:"stockBasedCompensationToRevenueTTM"`
	IntangiblesToTotalAssetsTTM               string `json:"intangiblesToTotalAssetsTTM"`
	AverageReceivablesTTM                     string `json:"averageReceivablesTTM"`
	AveragePayablesTTM                        string `json:"averagePayablesTTM"`
	AverageInventoryTTM                       string `json:"averageInventoryTTM"`
	DaysOfSalesOutstandingTTM                 string `json:"daysOfSalesOutstandingTTM"`
	DaysOfPayablesOutstandingTTM              string `json:"daysOfPayablesOutstandingTTM"`
	DaysOfInventoryOutstandingTTM             string `json:"daysOfInventoryOutstandingTTM"`
	OperatingCycleTTM                         string `json:"operatingCycleTTM"`
	CashConversionCycleTTM                    string `json:"cashConversionCycleTTM"`
	FreeCashFlowToEquityTTM                   string `json:"freeCashFlowToEquityTTM"`
	FreeCashFlowToFirmTTM                     string `json:"freeCashFlowToFirmTTM"`
	TangibleAssetValueTTM                     string `json:"tangibleAssetValueTTM"`
	NetCurrentAssetValueTTM                   string `json:"netCurrentAssetValueTTM"`
}

BulkKeyMetricsTTM is one worldwide key-metrics trailing-twelve-month bulk row.

func (*BulkKeyMetricsTTM) UnmarshalJSONFrom added in v0.12.0

func (m *BulkKeyMetricsTTM) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type BulkNamespace

type BulkNamespace struct {
	// contains filtered or unexported fields
}

BulkNamespace groups the bulk endpoints. It is reached as Client.Bulk and is valid only when obtained from a Client built by NewClient.

func (*BulkNamespace) BalanceSheetStatementGrowth

func (n *BulkNamespace) BalanceSheetStatementGrowth(ctx context.Context, q BulkStatementQuery) ([]BulkBalanceSheetStatementGrowth, error)

BalanceSheetStatementGrowth retrieves worldwide bulk balance-sheet growth for one year and fiscal period.

GET balance-sheet-statement-growth-bulk?year=&period=

func (*BulkNamespace) BalanceSheetStatements

func (n *BulkNamespace) BalanceSheetStatements(ctx context.Context, q BulkStatementQuery) ([]BulkBalanceSheetStatement, error)

BalanceSheetStatements retrieves worldwide bulk balance sheets for one year and fiscal period.

GET balance-sheet-statement-bulk?year=&period=

func (*BulkNamespace) CashFlowStatementGrowth

func (n *BulkNamespace) CashFlowStatementGrowth(ctx context.Context, q BulkStatementQuery) ([]BulkCashFlowStatementGrowth, error)

CashFlowStatementGrowth retrieves worldwide bulk cash-flow growth for one year and fiscal period.

GET cash-flow-statement-growth-bulk?year=&period=

func (*BulkNamespace) CashFlowStatements

func (n *BulkNamespace) CashFlowStatements(ctx context.Context, q BulkStatementQuery) ([]BulkCashFlowStatement, error)

CashFlowStatements retrieves worldwide bulk cash-flow statements for one year and fiscal period.

GET cash-flow-statement-bulk?year=&period=

func (*BulkNamespace) CompanyProfiles

func (n *BulkNamespace) CompanyProfiles(ctx context.Context, q BulkPartQuery) ([]CompanyProfile, error)

CompanyProfiles retrieves one provider partition of worldwide company profiles.

GET profile-bulk?part=

func (*BulkNamespace) DCFValuations added in v0.12.0

func (n *BulkNamespace) DCFValuations(ctx context.Context) ([]BulkDCFValuation, error)

DCFValuations retrieves worldwide discounted-cash-flow valuations in one provider bulk response.

GET dcf-bulk

func (*BulkNamespace) ETFHoldings added in v0.12.0

func (n *BulkNamespace) ETFHoldings(ctx context.Context, q BulkPartQuery) ([]BulkETFHolding, error)

ETFHoldings retrieves one provider partition of worldwide ETF holdings.

GET etf-holder-bulk?part=

func (*BulkNamespace) EarningsSurprises

func (n *BulkNamespace) EarningsSurprises(ctx context.Context, q BulkYearQuery) ([]BulkEarningsSurprise, error)

EarningsSurprises retrieves worldwide annual earnings surprises for one required provider year.

GET earnings-surprises-bulk?year=

func (*BulkNamespace) Eod

Eod retrieves worldwide bulk end-of-day prices for one required date.

GET eod-bulk?date=

func (*BulkNamespace) FinancialRatiosTTM added in v0.12.0

func (n *BulkNamespace) FinancialRatiosTTM(ctx context.Context) ([]BulkFinancialRatiosTTM, error)

FinancialRatiosTTM retrieves worldwide trailing-twelve-month financial ratios in one bulk response.

GET ratios-ttm-bulk

func (*BulkNamespace) FinancialScores

func (n *BulkNamespace) FinancialScores(ctx context.Context) ([]BulkFinancialScore, error)

FinancialScores retrieves worldwide financial scores in one provider bulk response.

GET scores-bulk

func (*BulkNamespace) IncomeStatementGrowth

func (n *BulkNamespace) IncomeStatementGrowth(ctx context.Context, q BulkStatementQuery) ([]BulkIncomeStatementGrowth, error)

IncomeStatementGrowth retrieves worldwide bulk income-statement growth for one year and fiscal period.

GET income-statement-growth-bulk?year=&period=

func (*BulkNamespace) IncomeStatements

func (n *BulkNamespace) IncomeStatements(ctx context.Context, q BulkStatementQuery) ([]BulkIncomeStatement, error)

IncomeStatements retrieves worldwide bulk income statements for one year and fiscal period.

GET income-statement-bulk?year=&period=

func (*BulkNamespace) KeyMetricsTTM added in v0.12.0

func (n *BulkNamespace) KeyMetricsTTM(ctx context.Context) ([]BulkKeyMetricsTTM, error)

KeyMetricsTTM retrieves worldwide trailing-twelve-month key metrics in one bulk response.

GET key-metrics-ttm-bulk

func (*BulkNamespace) PriceTargetSummaries

func (n *BulkNamespace) PriceTargetSummaries(ctx context.Context) ([]BulkPriceTargetSummary, error)

PriceTargetSummaries retrieves US price-target summaries in one provider bulk response.

GET price-target-summary-bulk

func (*BulkNamespace) StockPeers

func (n *BulkNamespace) StockPeers(ctx context.Context) ([]BulkStockPeer, error)

StockPeers retrieves worldwide stock peers in one provider bulk response.

GET peers-bulk

func (*BulkNamespace) StockRatings

func (n *BulkNamespace) StockRatings(ctx context.Context) ([]BulkStockRating, error)

StockRatings retrieves worldwide stock ratings in one provider bulk response.

GET rating-bulk

func (*BulkNamespace) UpgradesDowngradesConsensus

func (n *BulkNamespace) UpgradesDowngradesConsensus(ctx context.Context) ([]BulkUpgradesDowngradesConsensus, error)

UpgradesDowngradesConsensus retrieves worldwide upgrades/downgrades consensus in one provider bulk response.

GET upgrades-downgrades-consensus-bulk

type BulkPartQuery

type BulkPartQuery struct {
	// contains filtered or unexported fields
}

BulkPartQuery holds the query parameters of the endpoints that take it: NewBulkPartQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewBulkPartQuery

func NewBulkPartQuery(part string) BulkPartQuery

NewBulkPartQuery creates the query from its required arguments.

func (BulkPartQuery) Part

func (q BulkPartQuery) Part() string

Part returns the part argument as given.

type BulkPriceTargetSummary

type BulkPriceTargetSummary struct {
	Symbol                    string `json:"symbol"`
	LastMonthCount            string `json:"lastMonthCount"`
	LastMonthAvgPriceTarget   string `json:"lastMonthAvgPriceTarget"`
	LastQuarterCount          string `json:"lastQuarterCount"`
	LastQuarterAvgPriceTarget string `json:"lastQuarterAvgPriceTarget"`
	LastYearCount             string `json:"lastYearCount"`
	LastYearAvgPriceTarget    string `json:"lastYearAvgPriceTarget"`
	AllTimeCount              string `json:"allTimeCount"`
	AllTimeAvgPriceTarget     string `json:"allTimeAvgPriceTarget"`
	Publishers                string `json:"publishers"`
}

BulkPriceTargetSummary is one US price-target-summary bulk row.

func (*BulkPriceTargetSummary) UnmarshalJSONFrom

func (m *BulkPriceTargetSummary) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type BulkStatementQuery

type BulkStatementQuery struct {
	// contains filtered or unexported fields
}

BulkStatementQuery holds the query parameters of the endpoints that take it: NewBulkStatementQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewBulkStatementQuery

func NewBulkStatementQuery(year uint32, period FiscalPeriod) BulkStatementQuery

NewBulkStatementQuery creates the query from its required arguments.

func (BulkStatementQuery) Period

func (q BulkStatementQuery) Period() FiscalPeriod

Period returns the period argument as given.

func (BulkStatementQuery) Year

func (q BulkStatementQuery) Year() uint32

Year returns the year argument as given.

type BulkStockPeer added in v0.12.0

type BulkStockPeer struct {
	Symbol string `json:"symbol"`
	Peers  string `json:"peers"`
}

BulkStockPeer is one worldwide stock-peer bulk row.

func (*BulkStockPeer) UnmarshalJSONFrom added in v0.12.0

func (m *BulkStockPeer) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type BulkStockRating

type BulkStockRating struct {
	Symbol                  string `json:"symbol"`
	Date                    Date   `json:"date"`
	Rating                  string `json:"rating"`
	DiscountedCashFlowScore string `json:"discountedCashFlowScore"`
	ReturnOnEquityScore     string `json:"returnOnEquityScore"`
	ReturnOnAssetsScore     string `json:"returnOnAssetsScore"`
	DebtToEquityScore       string `json:"debtToEquityScore"`
	PriceToEarningsScore    string `json:"priceToEarningsScore"`
	PriceToBookScore        string `json:"priceToBookScore"`
}

BulkStockRating is one worldwide stock-rating bulk row.

func (*BulkStockRating) UnmarshalJSONFrom

func (m *BulkStockRating) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type BulkUpgradesDowngradesConsensus

type BulkUpgradesDowngradesConsensus struct {
	Symbol     string `json:"symbol"`
	StrongBuy  string `json:"strongBuy"`
	Buy        string `json:"buy"`
	Hold       string `json:"hold"`
	Sell       string `json:"sell"`
	StrongSell string `json:"strongSell"`
	Consensus  string `json:"consensus"`
}

BulkUpgradesDowngradesConsensus is one worldwide upgrades/downgrades-consensus bulk row.

func (*BulkUpgradesDowngradesConsensus) UnmarshalJSONFrom

func (m *BulkUpgradesDowngradesConsensus) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type BulkYearQuery

type BulkYearQuery struct {
	// contains filtered or unexported fields
}

BulkYearQuery holds the query parameters of the endpoints that take it: NewBulkYearQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewBulkYearQuery

func NewBulkYearQuery(year uint32) BulkYearQuery

NewBulkYearQuery creates the query from its required arguments.

func (BulkYearQuery) Year

func (q BulkYearQuery) Year() uint32

Year returns the year argument as given.

type CIKListQuery added in v0.12.0

type CIKListQuery struct {
	// contains filtered or unexported fields
}

CIKListQuery holds the query parameters of the endpoints that take it: NewCIKListQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewCIKListQuery added in v0.12.0

func NewCIKListQuery() CIKListQuery

NewCIKListQuery creates the query from its required arguments.

func (CIKListQuery) Limit added in v0.12.0

func (q CIKListQuery) Limit() *uint32

Limit returns the optional limit parameter, or nil when it is unset.

func (CIKListQuery) Page added in v0.12.0

func (q CIKListQuery) Page() *uint32

Page returns the optional page parameter, or nil when it is unset.

func (CIKListQuery) WithLimit added in v0.12.0

func (q CIKListQuery) WithLimit(limit uint32) CIKListQuery

WithLimit sets the optional limit parameter and returns the updated query.

func (CIKListQuery) WithPage added in v0.12.0

func (q CIKListQuery) WithPage(page uint32) CIKListQuery

WithPage sets the optional page parameter and returns the updated query.

type CIKListing added in v0.12.0

type CIKListing struct {
	CIK         string `json:"cik"`
	CompanyName string `json:"companyName"`
}

CIKListing is one US SEC entity in the CIK directory.

func (*CIKListing) UnmarshalJSONFrom added in v0.12.0

func (m *CIKListing) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type CIKSearchQuery added in v0.12.0

type CIKSearchQuery struct {
	// contains filtered or unexported fields
}

CIKSearchQuery holds the query parameters of the endpoints that take it: NewCIKSearchQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewCIKSearchQuery added in v0.12.0

func NewCIKSearchQuery(cik string) CIKSearchQuery

NewCIKSearchQuery creates the query from its required arguments.

func (CIKSearchQuery) CIK added in v0.12.0

func (q CIKSearchQuery) CIK() string

CIK returns the cik argument as given.

func (CIKSearchQuery) Limit added in v0.12.0

func (q CIKSearchQuery) Limit() *uint32

Limit returns the optional limit parameter, or nil when it is unset.

func (CIKSearchQuery) WithLimit added in v0.12.0

func (q CIKSearchQuery) WithLimit(limit uint32) CIKSearchQuery

WithLimit sets the optional limit parameter and returns the updated query.

type CIKSearchResult added in v0.12.0

type CIKSearchResult struct {
	Symbol           string `json:"symbol"`
	CompanyName      string `json:"companyName"`
	CIK              string `json:"cik"`
	ExchangeFullName string `json:"exchangeFullName"`
	Exchange         string `json:"exchange"`
	Currency         string `json:"currency"`
}

CIKSearchResult is a US company returned by CIK search.

func (*CIKSearchResult) UnmarshalJSONFrom added in v0.12.0

func (m *CIKSearchResult) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type COTAnalysis added in v0.12.0

type COTAnalysis struct {
	Symbol                       string   `json:"symbol"`
	Date                         DateTime `json:"date"`
	Name                         string   `json:"name"`
	Sector                       string   `json:"sector"`
	Exchange                     string   `json:"exchange"`
	CurrentLongMarketSituation   float64  `json:"currentLongMarketSituation"`
	CurrentShortMarketSituation  float64  `json:"currentShortMarketSituation"`
	MarketSituation              string   `json:"marketSituation"`
	PreviousLongMarketSituation  float64  `json:"previousLongMarketSituation"`
	PreviousShortMarketSituation float64  `json:"previousShortMarketSituation"`
	PreviousMarketSituation      string   `json:"previousMarketSituation"`
	NetPosition                  int64    `json:"netPostion"`
	PreviousNetPosition          int64    `json:"previousNetPosition"`
	ChangeInNetPosition          float64  `json:"changeInNetPosition"`
	MarketSentiment              string   `json:"marketSentiment"`
	ReversalTrend                bool     `json:"reversalTrend"`
}

COTAnalysis is provider-derived market positioning and sentiment for one contract.

func (*COTAnalysis) UnmarshalJSONFrom added in v0.12.0

func (m *COTAnalysis) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type COTQuery added in v0.12.0

type COTQuery struct {
	// contains filtered or unexported fields
}

COTQuery holds the query parameters of the endpoints that take it: NewCOTQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewCOTQuery added in v0.12.0

func NewCOTQuery() COTQuery

NewCOTQuery creates the query from its required arguments.

func (COTQuery) From added in v0.12.0

func (q COTQuery) From() *Date

From returns the optional from parameter, or nil when it is unset.

func (COTQuery) Symbol added in v0.12.0

func (q COTQuery) Symbol() *string

Symbol returns the optional symbol parameter, or nil when it is unset.

func (COTQuery) To added in v0.12.0

func (q COTQuery) To() *Date

To returns the optional to parameter, or nil when it is unset.

func (COTQuery) WithFrom added in v0.12.0

func (q COTQuery) WithFrom(from Date) COTQuery

WithFrom sets the optional from parameter and returns the updated query.

func (COTQuery) WithSymbol added in v0.12.0

func (q COTQuery) WithSymbol(symbol string) COTQuery

WithSymbol sets the optional symbol parameter and returns the updated query.

func (COTQuery) WithTo added in v0.12.0

func (q COTQuery) WithTo(to Date) COTQuery

WithTo sets the optional to parameter and returns the updated query.

type COTReport added in v0.12.0

type COTReport struct {
	Symbol                      string         `json:"symbol"`
	Date                        DateTime       `json:"date"`
	Name                        string         `json:"name"`
	Sector                      string         `json:"sector"`
	MarketAndExchangeNames      string         `json:"marketAndExchangeNames"`
	CftcContractMarketCode      string         `json:"cftcContractMarketCode"`
	CftcMarketCode              string         `json:"cftcMarketCode"`
	CftcRegionCode              string         `json:"cftcRegionCode"`
	CftcCommodityCode           string         `json:"cftcCommodityCode"`
	OpenInterestAll             uint64         `json:"openInterestAll"`
	NoncommPositionsLongAll     uint64         `json:"noncommPositionsLongAll"`
	NoncommPositionsShortAll    uint64         `json:"noncommPositionsShortAll"`
	NoncommPositionsSpreadAll   uint64         `json:"noncommPositionsSpreadAll"`
	CommPositionsLongAll        uint64         `json:"commPositionsLongAll"`
	CommPositionsShortAll       uint64         `json:"commPositionsShortAll"`
	TotReptPositionsLongAll     uint64         `json:"totReptPositionsLongAll"`
	TotReptPositionsShortAll    uint64         `json:"totReptPositionsShortAll"`
	NonreptPositionsLongAll     uint64         `json:"nonreptPositionsLongAll"`
	NonreptPositionsShortAll    uint64         `json:"nonreptPositionsShortAll"`
	OpenInterestOld             uint64         `json:"openInterestOld"`
	NoncommPositionsLongOld     uint64         `json:"noncommPositionsLongOld"`
	NoncommPositionsShortOld    uint64         `json:"noncommPositionsShortOld"`
	NoncommPositionsSpreadOld   uint64         `json:"noncommPositionsSpreadOld"`
	CommPositionsLongOld        uint64         `json:"commPositionsLongOld"`
	CommPositionsShortOld       uint64         `json:"commPositionsShortOld"`
	TotReptPositionsLongOld     uint64         `json:"totReptPositionsLongOld"`
	TotReptPositionsShortOld    uint64         `json:"totReptPositionsShortOld"`
	NonreptPositionsLongOld     uint64         `json:"nonreptPositionsLongOld"`
	NonreptPositionsShortOld    uint64         `json:"nonreptPositionsShortOld"`
	OpenInterestOther           uint64         `json:"openInterestOther"`
	NoncommPositionsLongOther   uint64         `json:"noncommPositionsLongOther"`
	NoncommPositionsShortOther  uint64         `json:"noncommPositionsShortOther"`
	NoncommPositionsSpreadOther uint64         `json:"noncommPositionsSpreadOther"`
	CommPositionsLongOther      uint64         `json:"commPositionsLongOther"`
	CommPositionsShortOther     uint64         `json:"commPositionsShortOther"`
	TotReptPositionsLongOther   uint64         `json:"totReptPositionsLongOther"`
	TotReptPositionsShortOther  uint64         `json:"totReptPositionsShortOther"`
	NonreptPositionsLongOther   uint64         `json:"nonreptPositionsLongOther"`
	NonreptPositionsShortOther  uint64         `json:"nonreptPositionsShortOther"`
	ChangeInOpenInterestAll     int64          `json:"changeInOpenInterestAll"`
	ChangeInNoncommLongAll      int64          `json:"changeInNoncommLongAll"`
	ChangeInNoncommShortAll     int64          `json:"changeInNoncommShortAll"`
	ChangeInNoncommSpreadAll    int64          `json:"changeInNoncommSpeadAll"`
	ChangeInCommLongAll         int64          `json:"changeInCommLongAll"`
	ChangeInCommShortAll        int64          `json:"changeInCommShortAll"`
	ChangeInTotReptLongAll      int64          `json:"changeInTotReptLongAll"`
	ChangeInTotReptShortAll     int64          `json:"changeInTotReptShortAll"`
	ChangeInNonreptLongAll      int64          `json:"changeInNonreptLongAll"`
	ChangeInNonreptShortAll     int64          `json:"changeInNonreptShortAll"`
	PctOfOpenInterestAll        jsontext.Value `json:"pctOfOpenInterestAll"`
	PctOfOiNoncommLongAll       jsontext.Value `json:"pctOfOiNoncommLongAll"`
	PctOfOiNoncommShortAll      jsontext.Value `json:"pctOfOiNoncommShortAll"`
	PctOfOiNoncommSpreadAll     jsontext.Value `json:"pctOfOiNoncommSpreadAll"`
	PctOfOiCommLongAll          jsontext.Value `json:"pctOfOiCommLongAll"`
	PctOfOiCommShortAll         jsontext.Value `json:"pctOfOiCommShortAll"`
	PctOfOiTotReptLongAll       jsontext.Value `json:"pctOfOiTotReptLongAll"`
	PctOfOiTotReptShortAll      jsontext.Value `json:"pctOfOiTotReptShortAll"`
	PctOfOiNonreptLongAll       jsontext.Value `json:"pctOfOiNonreptLongAll"`
	PctOfOiNonreptShortAll      jsontext.Value `json:"pctOfOiNonreptShortAll"`
	PctOfOpenInterestOld        jsontext.Value `json:"pctOfOpenInterestOl"`
	PctOfOiNoncommLongOld       jsontext.Value `json:"pctOfOiNoncommLongOl"`
	PctOfOiNoncommShortOld      jsontext.Value `json:"pctOfOiNoncommShortOl"`
	PctOfOiNoncommSpreadOld     jsontext.Value `json:"pctOfOiNoncommSpreadOl"`
	PctOfOiCommLongOld          jsontext.Value `json:"pctOfOiCommLongOl"`
	PctOfOiCommShortOld         jsontext.Value `json:"pctOfOiCommShortOl"`
	PctOfOiTotReptLongOld       jsontext.Value `json:"pctOfOiTotReptLongOl"`
	PctOfOiTotReptShortOld      jsontext.Value `json:"pctOfOiTotReptShortOl"`
	PctOfOiNonreptLongOld       jsontext.Value `json:"pctOfOiNonreptLongOl"`
	PctOfOiNonreptShortOld      jsontext.Value `json:"pctOfOiNonreptShortOl"`
	PctOfOpenInterestOther      jsontext.Value `json:"pctOfOpenInterestOther"`
	PctOfOiNoncommLongOther     jsontext.Value `json:"pctOfOiNoncommLongOther"`
	PctOfOiNoncommShortOther    jsontext.Value `json:"pctOfOiNoncommShortOther"`
	PctOfOiNoncommSpreadOther   jsontext.Value `json:"pctOfOiNoncommSpreadOther"`
	PctOfOiCommLongOther        jsontext.Value `json:"pctOfOiCommLongOther"`
	PctOfOiCommShortOther       jsontext.Value `json:"pctOfOiCommShortOther"`
	PctOfOiTotReptLongOther     jsontext.Value `json:"pctOfOiTotReptLongOther"`
	PctOfOiTotReptShortOther    jsontext.Value `json:"pctOfOiTotReptShortOther"`
	PctOfOiNonreptLongOther     jsontext.Value `json:"pctOfOiNonreptLongOther"`
	PctOfOiNonreptShortOther    jsontext.Value `json:"pctOfOiNonreptShortOther"`
	TradersTotAll               uint64         `json:"tradersTotAll"`
	TradersNoncommLongAll       uint64         `json:"tradersNoncommLongAll"`
	TradersNoncommShortAll      uint64         `json:"tradersNoncommShortAll"`
	TradersNoncommSpreadAll     uint64         `json:"tradersNoncommSpreadAll"`
	TradersCommLongAll          uint64         `json:"tradersCommLongAll"`
	TradersCommShortAll         uint64         `json:"tradersCommShortAll"`
	TradersTotReptLongAll       uint64         `json:"tradersTotReptLongAll"`
	TradersTotReptShortAll      uint64         `json:"tradersTotReptShortAll"`
	TradersTotOld               uint64         `json:"tradersTotOl"`
	TradersNoncommLongOld       uint64         `json:"tradersNoncommLongOl"`
	TradersNoncommShortOld      uint64         `json:"tradersNoncommShortOl"`
	TradersNoncommSpreadOld     uint64         `json:"tradersNoncommSpeadOl"`
	TradersCommLongOld          uint64         `json:"tradersCommLongOl"`
	TradersCommShortOld         uint64         `json:"tradersCommShortOl"`
	TradersTotReptLongOld       uint64         `json:"tradersTotReptLongOl"`
	TradersTotReptShortOld      uint64         `json:"tradersTotReptShortOl"`
	TradersTotOther             uint64         `json:"tradersTotOther"`
	TradersNoncommLongOther     uint64         `json:"tradersNoncommLongOther"`
	TradersNoncommShortOther    uint64         `json:"tradersNoncommShortOther"`
	TradersNoncommSpreadOther   uint64         `json:"tradersNoncommSpreadOther"`
	TradersCommLongOther        uint64         `json:"tradersCommLongOther"`
	TradersCommShortOther       uint64         `json:"tradersCommShortOther"`
	TradersTotReptLongOther     uint64         `json:"tradersTotReptLongOther"`
	TradersTotReptShortOther    uint64         `json:"tradersTotReptShortOther"`
	ConcGrossLe4TdrLongAll      jsontext.Value `json:"concGrossLe4TdrLongAll"`
	ConcGrossLe4TdrShortAll     jsontext.Value `json:"concGrossLe4TdrShortAll"`
	ConcGrossLe8TdrLongAll      jsontext.Value `json:"concGrossLe8TdrLongAll"`
	ConcGrossLe8TdrShortAll     jsontext.Value `json:"concGrossLe8TdrShortAll"`
	ConcNetLe4TdrLongAll        jsontext.Value `json:"concNetLe4TdrLongAll"`
	ConcNetLe4TdrShortAll       jsontext.Value `json:"concNetLe4TdrShortAll"`
	ConcNetLe8TdrLongAll        jsontext.Value `json:"concNetLe8TdrLongAll"`
	ConcNetLe8TdrShortAll       jsontext.Value `json:"concNetLe8TdrShortAll"`
	ConcGrossLe4TdrLongOld      jsontext.Value `json:"concGrossLe4TdrLongOl"`
	ConcGrossLe4TdrShortOld     jsontext.Value `json:"concGrossLe4TdrShortOl"`
	ConcGrossLe8TdrLongOld      jsontext.Value `json:"concGrossLe8TdrLongOl"`
	ConcGrossLe8TdrShortOld     jsontext.Value `json:"concGrossLe8TdrShortOl"`
	ConcNetLe4TdrLongOld        jsontext.Value `json:"concNetLe4TdrLongOl"`
	ConcNetLe4TdrShortOld       jsontext.Value `json:"concNetLe4TdrShortOl"`
	ConcNetLe8TdrLongOld        jsontext.Value `json:"concNetLe8TdrLongOl"`
	ConcNetLe8TdrShortOld       jsontext.Value `json:"concNetLe8TdrShortOl"`
	ConcGrossLe4TdrLongOther    jsontext.Value `json:"concGrossLe4TdrLongOther"`
	ConcGrossLe4TdrShortOther   jsontext.Value `json:"concGrossLe4TdrShortOther"`
	ConcGrossLe8TdrLongOther    jsontext.Value `json:"concGrossLe8TdrLongOther"`
	ConcGrossLe8TdrShortOther   jsontext.Value `json:"concGrossLe8TdrShortOther"`
	ConcNetLe4TdrLongOther      jsontext.Value `json:"concNetLe4TdrLongOther"`
	ConcNetLe4TdrShortOther     jsontext.Value `json:"concNetLe4TdrShortOther"`
	ConcNetLe8TdrLongOther      jsontext.Value `json:"concNetLe8TdrLongOther"`
	ConcNetLe8TdrShortOther     jsontext.Value `json:"concNetLe8TdrShortOther"`
	ContractUnits               string         `json:"contractUnits"`
}

COTReport is a complete, lossless provider Commitment of Traders report row.

func (*COTReport) UnmarshalJSONFrom added in v0.12.0

func (m *COTReport) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type COTReportListing added in v0.12.0

type COTReportListing struct {
	Symbol string `json:"symbol"`
	Name   string `json:"name"`
}

COTReportListing is one provider-listed Commitment of Traders report.

func (*COTReportListing) UnmarshalJSONFrom added in v0.12.0

func (m *COTReportListing) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type CUSIPSearchQuery added in v0.12.0

type CUSIPSearchQuery struct {
	// contains filtered or unexported fields
}

CUSIPSearchQuery holds the query parameters of the endpoints that take it: NewCUSIPSearchQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewCUSIPSearchQuery added in v0.12.0

func NewCUSIPSearchQuery(cusip string) CUSIPSearchQuery

NewCUSIPSearchQuery creates the query from its required arguments.

func (CUSIPSearchQuery) CUSIP added in v0.12.0

func (q CUSIPSearchQuery) CUSIP() string

CUSIP returns the cusip argument as given.

type CUSIPSearchResult added in v0.12.0

type CUSIPSearchResult struct {
	Symbol      string  `json:"symbol"`
	CompanyName string  `json:"companyName"`
	CUSIP       string  `json:"cusip"`
	MarketCap   float64 `json:"marketCap"`
}

CUSIPSearchResult is a security returned by CUSIP search.

func (*CUSIPSearchResult) UnmarshalJSONFrom added in v0.12.0

func (m *CUSIPSearchResult) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type CalendarNamespace

type CalendarNamespace struct {
	// contains filtered or unexported fields
}

CalendarNamespace groups the calendar endpoints. It is reached as Client.Calendar and is valid only when obtained from a Client built by NewClient.

func (*CalendarNamespace) Dividends

Dividends retrieves worldwide dividend events for one company.

GET dividends?symbol=&limit=

func (*CalendarNamespace) DividendsCalendar

func (n *CalendarNamespace) DividendsCalendar(ctx context.Context, q DividendsCalendarQuery) ([]DividendEvent, error)

DividendsCalendar retrieves the worldwide dividend calendar.

GET dividends-calendar?from=&to=&page=

func (*CalendarNamespace) Earnings

Earnings retrieves worldwide earnings events for one company.

GET earnings?symbol=&limit=&includeReportTimes=

func (*CalendarNamespace) EarningsCalendar

func (n *CalendarNamespace) EarningsCalendar(ctx context.Context, q EarningsCalendarQuery) ([]EarningsEvent, error)

EarningsCalendar retrieves the worldwide earnings calendar.

GET earnings-calendar?from=&to=&page=&includeReportTimes=

func (*CalendarNamespace) IPOCalendar added in v0.12.0

IPOCalendar retrieves the worldwide IPO calendar.

GET ipos-calendar?from=&to=

func (*CalendarNamespace) IPODisclosure added in v0.12.0

IPODisclosure retrieves US IPO disclosure filings.

GET ipos-disclosure?from=&to=

func (*CalendarNamespace) IPOProspectus added in v0.12.0

IPOProspectus retrieves US IPO prospectus filings and documented offering values.

GET ipos-prospectus?from=&to=

func (*CalendarNamespace) StockSplits

StockSplits retrieves worldwide stock-split events for one company.

GET splits?symbol=&limit=

func (*CalendarNamespace) StockSplitsCalendar

func (n *CalendarNamespace) StockSplitsCalendar(ctx context.Context, q StockSplitsCalendarQuery) ([]StockSplitEvent, error)

StockSplitsCalendar retrieves the worldwide stock-splits calendar.

GET splits-calendar?from=&to=&page=

type CashFlowStatement

type CashFlowStatement struct {
	Date                                   Date     `json:"date"`
	Symbol                                 string   `json:"symbol"`
	ReportedCurrency                       string   `json:"reportedCurrency"`
	CIK                                    string   `json:"cik"`
	FilingDate                             Date     `json:"filingDate"`
	AcceptedDate                           DateTime `json:"acceptedDate"`
	FiscalYear                             string   `json:"fiscalYear"`
	Period                                 string   `json:"period"`
	NetIncome                              float64  `json:"netIncome"`
	DepreciationAndAmortization            float64  `json:"depreciationAndAmortization"`
	DeferredIncomeTax                      float64  `json:"deferredIncomeTax"`
	StockBasedCompensation                 float64  `json:"stockBasedCompensation"`
	ChangeInWorkingCapital                 float64  `json:"changeInWorkingCapital"`
	AccountsReceivables                    float64  `json:"accountsReceivables"`
	Inventory                              float64  `json:"inventory"`
	AccountsPayables                       float64  `json:"accountsPayables"`
	OtherWorkingCapital                    float64  `json:"otherWorkingCapital"`
	OtherNonCashItems                      float64  `json:"otherNonCashItems"`
	NetCashProvidedByOperatingActivities   float64  `json:"netCashProvidedByOperatingActivities"`
	InvestmentsInPropertyPlantAndEquipment float64  `json:"investmentsInPropertyPlantAndEquipment"`
	AcquisitionsNet                        float64  `json:"acquisitionsNet"`
	PurchasesOfInvestments                 float64  `json:"purchasesOfInvestments"`
	SalesMaturitiesOfInvestments           float64  `json:"salesMaturitiesOfInvestments"`
	OtherInvestingActivities               float64  `json:"otherInvestingActivities"`
	NetCashProvidedByInvestingActivities   float64  `json:"netCashProvidedByInvestingActivities"`
	NetDebtIssuance                        float64  `json:"netDebtIssuance"`
	LongTermNetDebtIssuance                float64  `json:"longTermNetDebtIssuance"`
	ShortTermNetDebtIssuance               float64  `json:"shortTermNetDebtIssuance"`
	NetStockIssuance                       float64  `json:"netStockIssuance"`
	NetCommonStockIssuance                 float64  `json:"netCommonStockIssuance"`
	CommonStockIssuance                    float64  `json:"commonStockIssuance"`
	CommonStockRepurchased                 float64  `json:"commonStockRepurchased"`
	NetPreferredStockIssuance              float64  `json:"netPreferredStockIssuance"`
	NetDividendsPaid                       float64  `json:"netDividendsPaid"`
	CommonDividendsPaid                    float64  `json:"commonDividendsPaid"`
	PreferredDividendsPaid                 float64  `json:"preferredDividendsPaid"`
	OtherFinancingActivities               float64  `json:"otherFinancingActivities"`
	NetCashProvidedByFinancingActivities   float64  `json:"netCashProvidedByFinancingActivities"`
	EffectOfForexChangesOnCash             float64  `json:"effectOfForexChangesOnCash"`
	NetChangeInCash                        float64  `json:"netChangeInCash"`
	CashAtEndOfPeriod                      float64  `json:"cashAtEndOfPeriod"`
	CashAtBeginningOfPeriod                float64  `json:"cashAtBeginningOfPeriod"`
	OperatingCashFlow                      float64  `json:"operatingCashFlow"`
	CapitalExpenditure                     float64  `json:"capitalExpenditure"`
	FreeCashFlow                           float64  `json:"freeCashFlow"`
	IncomeTaxesPaid                        float64  `json:"incomeTaxesPaid"`
	InterestPaid                           float64  `json:"interestPaid"`
}

CashFlowStatement is one historical or trailing-twelve-month worldwide cash-flow statement.

func (*CashFlowStatement) UnmarshalJSONFrom

func (m *CashFlowStatement) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type CashFlowStatementAsReportedQuery

type CashFlowStatementAsReportedQuery struct {
	// contains filtered or unexported fields
}

CashFlowStatementAsReportedQuery holds the query parameters of the endpoints that take it: NewCashFlowStatementAsReportedQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewCashFlowStatementAsReportedQuery

func NewCashFlowStatementAsReportedQuery(symbol string) CashFlowStatementAsReportedQuery

NewCashFlowStatementAsReportedQuery creates the query from its required arguments.

func (CashFlowStatementAsReportedQuery) Limit

Limit returns the optional limit parameter, or nil when it is unset.

func (CashFlowStatementAsReportedQuery) Period

Period returns the optional period parameter, or nil when it is unset.

func (CashFlowStatementAsReportedQuery) Symbol

Symbol returns the symbol argument as given.

func (CashFlowStatementAsReportedQuery) WithLimit

WithLimit sets the optional limit parameter and returns the updated query.

func (CashFlowStatementAsReportedQuery) WithPeriod

WithPeriod sets the optional period parameter and returns the updated query.

type CashFlowStatementGrowth

type CashFlowStatementGrowth struct {
	Symbol                                         string  `json:"symbol"`
	Date                                           Date    `json:"date"`
	FiscalYear                                     string  `json:"fiscalYear"`
	Period                                         string  `json:"period"`
	ReportedCurrency                               string  `json:"reportedCurrency"`
	GrowthNetIncome                                float64 `json:"growthNetIncome"`
	GrowthDepreciationAndAmortization              float64 `json:"growthDepreciationAndAmortization"`
	GrowthDeferredIncomeTax                        float64 `json:"growthDeferredIncomeTax"`
	GrowthStockBasedCompensation                   float64 `json:"growthStockBasedCompensation"`
	GrowthChangeInWorkingCapital                   float64 `json:"growthChangeInWorkingCapital"`
	GrowthAccountsReceivables                      float64 `json:"growthAccountsReceivables"`
	GrowthInventory                                float64 `json:"growthInventory"`
	GrowthAccountsPayables                         float64 `json:"growthAccountsPayables"`
	GrowthOtherWorkingCapital                      float64 `json:"growthOtherWorkingCapital"`
	GrowthOtherNonCashItems                        float64 `json:"growthOtherNonCashItems"`
	GrowthNetCashProvidedByOperatingActivities     float64 `json:"growthNetCashProvidedByOperatingActivites"`
	GrowthInvestmentsInPropertyPlantAndEquipment   float64 `json:"growthInvestmentsInPropertyPlantAndEquipment"`
	GrowthAcquisitionsNet                          float64 `json:"growthAcquisitionsNet"`
	GrowthPurchasesOfInvestments                   float64 `json:"growthPurchasesOfInvestments"`
	GrowthSalesMaturitiesOfInvestments             float64 `json:"growthSalesMaturitiesOfInvestments"`
	GrowthOtherInvestingActivities                 float64 `json:"growthOtherInvestingActivites"`
	GrowthNetCashUsedForInvestingActivities        float64 `json:"growthNetCashUsedForInvestingActivites"`
	GrowthDebtRepayment                            float64 `json:"growthDebtRepayment"`
	GrowthCommonStockIssued                        float64 `json:"growthCommonStockIssued"`
	GrowthCommonStockRepurchased                   float64 `json:"growthCommonStockRepurchased"`
	GrowthDividendsPaid                            float64 `json:"growthDividendsPaid"`
	GrowthOtherFinancingActivities                 float64 `json:"growthOtherFinancingActivites"`
	GrowthNetCashUsedProvidedByFinancingActivities float64 `json:"growthNetCashUsedProvidedByFinancingActivities"`
	GrowthEffectOfForexChangesOnCash               float64 `json:"growthEffectOfForexChangesOnCash"`
	GrowthNetChangeInCash                          float64 `json:"growthNetChangeInCash"`
	GrowthCashAtEndOfPeriod                        float64 `json:"growthCashAtEndOfPeriod"`
	GrowthCashAtBeginningOfPeriod                  float64 `json:"growthCashAtBeginningOfPeriod"`
	GrowthOperatingCashFlow                        float64 `json:"growthOperatingCashFlow"`
	GrowthCapitalExpenditure                       float64 `json:"growthCapitalExpenditure"`
	GrowthFreeCashFlow                             float64 `json:"growthFreeCashFlow"`
	GrowthNetDebtIssuance                          float64 `json:"growthNetDebtIssuance"`
	GrowthLongTermNetDebtIssuance                  float64 `json:"growthLongTermNetDebtIssuance"`
	GrowthShortTermNetDebtIssuance                 float64 `json:"growthShortTermNetDebtIssuance"`
	GrowthNetStockIssuance                         float64 `json:"growthNetStockIssuance"`
	GrowthPreferredDividendsPaid                   float64 `json:"growthPreferredDividendsPaid"`
	GrowthIncomeTaxesPaid                          float64 `json:"growthIncomeTaxesPaid"`
	GrowthInterestPaid                             float64 `json:"growthInterestPaid"`
}

CashFlowStatementGrowth is one historical cash-flow-statement growth row.

func (*CashFlowStatementGrowth) UnmarshalJSONFrom

func (m *CashFlowStatementGrowth) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type CashFlowStatementGrowthQuery

type CashFlowStatementGrowthQuery struct {
	// contains filtered or unexported fields
}

CashFlowStatementGrowthQuery holds the query parameters of the endpoints that take it: NewCashFlowStatementGrowthQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewCashFlowStatementGrowthQuery

func NewCashFlowStatementGrowthQuery(symbol string) CashFlowStatementGrowthQuery

NewCashFlowStatementGrowthQuery creates the query from its required arguments.

func (CashFlowStatementGrowthQuery) Limit

Limit returns the optional limit parameter, or nil when it is unset.

func (CashFlowStatementGrowthQuery) Period

Period returns the optional period parameter, or nil when it is unset.

func (CashFlowStatementGrowthQuery) Symbol

Symbol returns the symbol argument as given.

func (CashFlowStatementGrowthQuery) WithLimit

WithLimit sets the optional limit parameter and returns the updated query.

func (CashFlowStatementGrowthQuery) WithPeriod

WithPeriod sets the optional period parameter and returns the updated query.

type CashFlowStatementQuery

type CashFlowStatementQuery struct {
	// contains filtered or unexported fields
}

CashFlowStatementQuery holds the query parameters of the endpoints that take it: NewCashFlowStatementQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewCashFlowStatementQuery

func NewCashFlowStatementQuery(symbol string) CashFlowStatementQuery

NewCashFlowStatementQuery creates the query from its required arguments.

func (CashFlowStatementQuery) Limit

func (q CashFlowStatementQuery) Limit() *uint32

Limit returns the optional limit parameter, or nil when it is unset.

func (CashFlowStatementQuery) Period

Period returns the optional period parameter, or nil when it is unset.

func (CashFlowStatementQuery) Symbol

func (q CashFlowStatementQuery) Symbol() string

Symbol returns the symbol argument as given.

func (CashFlowStatementQuery) WithLimit

WithLimit sets the optional limit parameter and returns the updated query.

func (CashFlowStatementQuery) WithPeriod

WithPeriod sets the optional period parameter and returns the updated query.

type CashFlowStatementTTMQuery added in v0.12.0

type CashFlowStatementTTMQuery struct {
	// contains filtered or unexported fields
}

CashFlowStatementTTMQuery holds the query parameters of the endpoints that take it: NewCashFlowStatementTTMQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewCashFlowStatementTTMQuery added in v0.12.0

func NewCashFlowStatementTTMQuery(symbol string) CashFlowStatementTTMQuery

NewCashFlowStatementTTMQuery creates the query from its required arguments.

func (CashFlowStatementTTMQuery) Limit added in v0.12.0

func (q CashFlowStatementTTMQuery) Limit() *uint32

Limit returns the optional limit parameter, or nil when it is unset.

func (CashFlowStatementTTMQuery) Symbol added in v0.12.0

func (q CashFlowStatementTTMQuery) Symbol() string

Symbol returns the symbol argument as given.

func (CashFlowStatementTTMQuery) WithLimit added in v0.12.0

WithLimit sets the optional limit parameter and returns the updated query.

type ChartNamespace

type ChartNamespace struct {
	// contains filtered or unexported fields
}

ChartNamespace groups the chart endpoints. It is reached as Client.Chart and is valid only when obtained from a Client built by NewClient.

func (*ChartNamespace) DividendAdjusted

DividendAdjusted retrieves dividend-adjusted worldwide end-of-day stock chart rows.

GET historical-price-eod/dividend-adjusted?symbol=&from=&to=

func (*ChartNamespace) FifteenMinutes

FifteenMinutes retrieves fifteen-minute worldwide intraday stock chart rows.

GET historical-chart/15min?symbol=&from=&to=&nonadjusted=&extended=

func (*ChartNamespace) FiveMinutes

FiveMinutes retrieves five-minute worldwide intraday stock chart rows.

GET historical-chart/5min?symbol=&from=&to=&nonadjusted=&extended=

func (*ChartNamespace) FourHours

FourHours retrieves four-hour worldwide intraday stock chart rows.

GET historical-chart/4hour?symbol=&from=&to=&nonadjusted=&extended=

func (*ChartNamespace) Full

Full retrieves detailed worldwide end-of-day stock chart rows.

GET historical-price-eod/full?symbol=&from=&to=

func (*ChartNamespace) Light

Light retrieves compact worldwide end-of-day stock chart rows.

GET historical-price-eod/light?symbol=&from=&to=

func (*ChartNamespace) NonSplitAdjusted

NonSplitAdjusted retrieves split-unadjusted worldwide end-of-day stock chart rows.

GET historical-price-eod/non-split-adjusted?symbol=&from=&to=

func (*ChartNamespace) OneHour

OneHour retrieves one-hour worldwide intraday stock chart rows.

GET historical-chart/1hour?symbol=&from=&to=&nonadjusted=&extended=

func (*ChartNamespace) OneMinute

OneMinute retrieves one-minute worldwide intraday stock chart rows.

GET historical-chart/1min?symbol=&from=&to=&nonadjusted=&extended=

func (*ChartNamespace) ThirtyMinutes

ThirtyMinutes retrieves thirty-minute worldwide intraday stock chart rows.

GET historical-chart/30min?symbol=&from=&to=&nonadjusted=&extended=

type ChartTimeframe

type ChartTimeframe string

ChartTimeframe is the bar timeframe taken by the technical-indicator endpoints. The constants carry the exact provider wire spellings of the libfmp ChartTimeframe wire enum, in its order; any other value is rejected when the request is built.

const (
	ChartTimeframeOneMinute      ChartTimeframe = "1min"
	ChartTimeframeFiveMinutes    ChartTimeframe = "5min"
	ChartTimeframeFifteenMinutes ChartTimeframe = "15min"
	ChartTimeframeThirtyMinutes  ChartTimeframe = "30min"
	ChartTimeframeOneHour        ChartTimeframe = "1hour"
	ChartTimeframeFourHours      ChartTimeframe = "4hour"
	ChartTimeframeOneDay         ChartTimeframe = "1day"
)

The documented ChartTimeframe wire values.

type Client

type Client struct {
	Namespaces
	// contains filtered or unexported fields
}

Client is the shared FMP client. It is safe for concurrent use. Formatting it with any fmt verb never reveals a credential or a configured URL. Endpoints are grouped by registry domain into the namespace fields of the embedded Namespaces (client.Quote.Full and so on); see the "Endpoint surface" section of the package documentation.

func NewClient

func NewClient(opts ...Option) (*Client, error)

NewClient validates the options and builds a client with the direct FMP stable API defaults. Every rejection is an *Error of category CategoryConfiguration with a ConfigurationKind.

Example

ExampleNewClient builds a client against an in-process server. Drop WithBaseURL and WithHTTPClient to talk to the FMP origin instead.

package main

import (
	"context"
	"fmt"
	"net/http"
	"net/http/httptest"

	fmp "github.com/bitbrew-dev/libfmp/sdk/go"
)

// exampleKey is the placeholder credential every example sends. It is not a
// real key, and no example prints it.
const exampleKey = "example-key"

// quoteShortFixture is a copy of crates/libfmp/tests/fixtures/quote_short.json,
// the documented provider response the Rust and Go parity tests both decode.
// It is inlined so the examples stay self-contained on pkg.go.dev and when the
// module is tested outside this repository.
const quoteShortFixture = `[
  {
    "change": -6.33498,
    "price": 331.85501,
    "symbol": "AAPL",
    "volume": 28718014
  }
]`

// serveQuoteShort starts an in-process TLS server that answers GET
// <prefix>/quote-short with the quote_short.json fixture, after check has
// accepted the request. Any other path, or a rejected request, is a 404.
func serveQuoteShort(prefix string, check func(*http.Request) bool) *httptest.Server {
	return httptest.NewTLSServer(http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) {
		if r.URL.Path != prefix+"/quote-short" || !check(r) {
			http.NotFound(w, r)
			return
		}
		w.Header().Set("Content-Type", "application/json")
		_, _ = fmt.Fprint(w, quoteShortFixture)
	}))
}

// printQuoteShort prints the first compact quote with fixed formats so the
// output is stable across platforms.
func printQuoteShort(quotes []fmp.QuoteShort) {
	if len(quotes) == 0 {
		fmt.Println("no quotes")
		return
	}
	q := quotes[0]
	fmt.Printf("%s price %.5f change %.5f volume %.0f\n", q.Symbol, q.Price, q.Change, q.Volume)
}

func main() {
	server := serveQuoteShort("/stable", func(r *http.Request) bool {
		return r.Header.Get("apikey") == exampleKey
	})
	defer server.Close()

	client, err := fmp.NewClient(
		fmp.WithBaseURL(server.URL),
		fmp.WithHTTPClient(server.Client()),
		fmp.WithAuthentication(fmp.FMPHeader(exampleKey)),
	)
	if err != nil {
		fmt.Println("configuration rejected:", err)
		return
	}

	quotes, err := client.Quote.Short(context.Background(), fmp.NewQuoteShortQuery("AAPL"))
	if err != nil {
		fmt.Println("request failed:", err)
		return
	}
	printQuoteShort(quotes)
}
Output:
AAPL price 331.85501 change -6.33498 volume 28718014

func (Client) Format

func (c Client) Format(f fmt.State, _ rune)

Format prints the configuration shape without URLs, header values, or secrets.

type CommitmentOfTradersNamespace

type CommitmentOfTradersNamespace struct {
	// contains filtered or unexported fields
}

CommitmentOfTradersNamespace groups the commitment_of_traders endpoints. It is reached as Client.CommitmentOfTraders and is valid only when obtained from a Client built by NewClient.

func (*CommitmentOfTradersNamespace) Analysis

Analysis retrieves derived Commitment of Traders market analysis.

GET commitment-of-traders-analysis?symbol=&from=&to=

func (*CommitmentOfTradersNamespace) Report

Report retrieves detailed Commitment of Traders reports.

GET commitment-of-traders-report?symbol=&from=&to=

func (*CommitmentOfTradersNamespace) ReportList

ReportList lists the Commitment of Traders reports available from the provider.

GET commitment-of-traders-list

type CommoditiesNamespace

type CommoditiesNamespace struct {
	// contains filtered or unexported fields
}

CommoditiesNamespace groups the commodities endpoints. It is reached as Client.Commodities and is valid only when obtained from a Client built by NewClient.

func (*CommoditiesNamespace) ChartFiveMinutes

ChartFiveMinutes retrieves five-minute commodity history.

GET historical-chart/5min?symbol=&from=&to=

func (*CommoditiesNamespace) ChartFull

ChartFull retrieves detailed end-of-day commodity history.

GET historical-price-eod/full?symbol=&from=&to=

func (*CommoditiesNamespace) ChartLight

ChartLight retrieves compact end-of-day commodity history.

GET historical-price-eod/light?symbol=&from=&to=

func (*CommoditiesNamespace) ChartOneHour

ChartOneHour retrieves one-hour commodity history.

GET historical-chart/1hour?symbol=&from=&to=

func (*CommoditiesNamespace) ChartOneMinute

ChartOneMinute retrieves one-minute commodity history.

GET historical-chart/1min?symbol=&from=&to=

func (*CommoditiesNamespace) List

List lists the provider's documented commodity catalog.

GET commodities-list

func (*CommoditiesNamespace) Quote

func (n *CommoditiesNamespace) Quote(ctx context.Context, q QuoteQuery) ([]Quote, error)

Quote retrieves a detailed US-only quote for one commodity.

GET quote?symbol=

func (*CommoditiesNamespace) QuoteShort

QuoteShort retrieves a compact US-only quote for one commodity.

GET quote-short?symbol=

type CommodityListing

type CommodityListing struct {
	Symbol     string  `json:"symbol"`
	Name       string  `json:"name"`
	Exchange   *string `json:"exchange"`
	TradeMonth string  `json:"tradeMonth"`
	Currency   string  `json:"currency"`
}

CommodityListing is one commodity in the provider's documented commodity catalog.

func (*CommodityListing) UnmarshalJSONFrom

func (m *CommodityListing) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type CompanyExecutive

type CompanyExecutive struct {
	Title       string          `json:"title"`
	Name        string          `json:"name"`
	Pay         *jsontext.Value `json:"pay"`
	CurrencyPay string          `json:"currencyPay"`
	Gender      string          `json:"gender"`
	YearBorn    *jsontext.Value `json:"yearBorn"`
	TitleSince  *jsontext.Value `json:"titleSince"`
	Active      bool            `json:"active"`
}

CompanyExecutive is one executive in a worldwide company's current leadership data.

func (*CompanyExecutive) UnmarshalJSONFrom

func (m *CompanyExecutive) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type CompanyMarketCapitalization added in v0.12.0

type CompanyMarketCapitalization struct {
	Symbol    string  `json:"symbol"`
	Date      Date    `json:"date"`
	MarketCap float64 `json:"marketCap"`
}

CompanyMarketCapitalization is one current or historical worldwide market-capitalization observation.

func (*CompanyMarketCapitalization) UnmarshalJSONFrom added in v0.12.0

func (m *CompanyMarketCapitalization) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type CompanyNamespace

type CompanyNamespace struct {
	// contains filtered or unexported fields
}

CompanyNamespace groups the company endpoints. It is reached as Client.Company and is valid only when obtained from a Client built by NewClient.

func (*CompanyNamespace) AllSharesFloat added in v0.12.0

func (n *CompanyNamespace) AllSharesFloat(ctx context.Context, q AllSharesFloatQuery) ([]ShareFloat, error)

AllSharesFloat retrieves paginated worldwide share-float data for all companies.

GET shares-float-all?page=&limit=

func (*CompanyNamespace) BatchMarketCapitalization added in v0.12.0

BatchMarketCapitalization retrieves current worldwide market capitalization for multiple companies.

GET market-capitalization-batch?symbols=

func (*CompanyNamespace) DelistedCompanies

func (n *CompanyNamespace) DelistedCompanies(ctx context.Context, q DelistedCompaniesQuery) ([]DelistedCompany, error)

DelistedCompanies retrieves delisted US companies with optional provider pagination.

GET delisted-companies?page=&limit=

func (*CompanyNamespace) EmployeeCount

func (n *CompanyNamespace) EmployeeCount(ctx context.Context, q EmployeeCountQuery) ([]EmployeeCount, error)

EmployeeCount retrieves current employee-count filings for a US company.

GET employee-count?symbol=&limit=

func (*CompanyNamespace) ExecutiveCompensation

ExecutiveCompensation retrieves executive compensation for a US company.

GET governance-executive-compensation?symbol=

func (*CompanyNamespace) ExecutiveCompensationBenchmark

ExecutiveCompensationBenchmark retrieves US executive-compensation benchmarks with an optional year.

GET executive-compensation-benchmark?year=

func (*CompanyNamespace) HistoricalEmployeeCount

func (n *CompanyNamespace) HistoricalEmployeeCount(ctx context.Context, q HistoricalEmployeeCountQuery) ([]EmployeeCount, error)

HistoricalEmployeeCount retrieves historical employee-count filings for a US company.

GET historical-employee-count?symbol=&limit=

func (*CompanyNamespace) HistoricalMarketCapitalization

HistoricalMarketCapitalization retrieves historical worldwide market capitalization for one company.

GET historical-market-capitalization?symbol=&limit=&from=&to=

func (*CompanyNamespace) KeyExecutives

KeyExecutives retrieves worldwide company executives by provider ticker.

GET key-executives?symbol=

func (*CompanyNamespace) LatestMergersAcquisitions added in v0.12.0

func (n *CompanyNamespace) LatestMergersAcquisitions(ctx context.Context, q LatestMergersAcquisitionsQuery) ([]MergerAcquisition, error)

LatestMergersAcquisitions retrieves the latest US mergers and acquisitions with optional pagination.

GET mergers-acquisitions-latest?page=&limit=

func (*CompanyNamespace) MarketCapitalization

MarketCapitalization retrieves current worldwide market capitalization for one company.

GET market-capitalization?symbol=

func (*CompanyNamespace) Notes

Notes retrieves company-issued notes for a US company.

GET company-notes?symbol=

func (*CompanyNamespace) Profile

Profile retrieves worldwide company profiles by provider ticker.

GET profile?symbol=

func (*CompanyNamespace) ProfileByCIK added in v0.12.0

ProfileByCIK retrieves US company profiles by representation-preserving CIK.

GET profile-cik?cik=

func (*CompanyNamespace) SearchMergersAcquisitions added in v0.12.0

func (n *CompanyNamespace) SearchMergersAcquisitions(ctx context.Context, q SearchMergersAcquisitionsQuery) ([]MergerAcquisition, error)

SearchMergersAcquisitions searches US mergers and acquisitions by representation-preserving company name.

GET mergers-acquisitions-search?name=

func (*CompanyNamespace) SharesFloat

SharesFloat retrieves current worldwide share-float data for one company.

GET shares-float?symbol=

func (*CompanyNamespace) StockPeers

func (n *CompanyNamespace) StockPeers(ctx context.Context, q StockPeersQuery) ([]StockPeer, error)

StockPeers retrieves worldwide stock peers for a company.

GET stock-peers?symbol=

type CompanyNote

type CompanyNote struct {
	CIK      string `json:"cik"`
	Symbol   string `json:"symbol"`
	Title    string `json:"title"`
	Exchange string `json:"exchange"`
}

CompanyNote is one US company-issued note.

func (*CompanyNote) UnmarshalJSONFrom

func (m *CompanyNote) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type CompanyNotesQuery

type CompanyNotesQuery struct {
	// contains filtered or unexported fields
}

CompanyNotesQuery holds the query parameters of the endpoints that take it: NewCompanyNotesQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewCompanyNotesQuery

func NewCompanyNotesQuery(symbol string) CompanyNotesQuery

NewCompanyNotesQuery creates the query from its required arguments.

func (CompanyNotesQuery) Symbol

func (q CompanyNotesQuery) Symbol() string

Symbol returns the symbol argument as given.

type CompanyProfile

type CompanyProfile struct {
	Symbol            string  `json:"symbol"`
	Price             float64 `json:"price"`
	MarketCap         float64 `json:"marketCap"`
	Beta              float64 `json:"beta"`
	LastDividend      float64 `json:"lastDividend"`
	Range             string  `json:"range"`
	Change            float64 `json:"change"`
	ChangePercentage  float64 `json:"changePercentage"`
	Volume            float64 `json:"volume"`
	AverageVolume     float64 `json:"averageVolume"`
	CompanyName       string  `json:"companyName"`
	Currency          string  `json:"currency"`
	CIK               string  `json:"cik"`
	ISIN              string  `json:"isin"`
	CUSIP             string  `json:"cusip"`
	ExchangeFullName  string  `json:"exchangeFullName"`
	Exchange          string  `json:"exchange"`
	Industry          string  `json:"industry"`
	Website           string  `json:"website"`
	Description       string  `json:"description"`
	Ceo               string  `json:"ceo"`
	Sector            string  `json:"sector"`
	Country           string  `json:"country"`
	FullTimeEmployees string  `json:"fullTimeEmployees"`
	Phone             string  `json:"phone"`
	Address           string  `json:"address"`
	City              string  `json:"city"`
	State             string  `json:"state"`
	Zip               string  `json:"zip"`
	Image             string  `json:"image"`
	IPODate           Date    `json:"ipoDate"`
	DefaultImage      bool    `json:"defaultImage"`
	IsETF             bool    `json:"isEtf"`
	IsActivelyTrading bool    `json:"isActivelyTrading"`
	IsAdr             bool    `json:"isAdr"`
	IsFund            bool    `json:"isFund"`
}

CompanyProfile is a detailed worldwide company profile returned by symbol or US CIK lookup.

func (*CompanyProfile) UnmarshalJSONFrom

func (m *CompanyProfile) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type CompanyScreenerQuery

type CompanyScreenerQuery struct {
	// contains filtered or unexported fields
}

CompanyScreenerQuery holds the query parameters of the endpoints that take it: NewCompanyScreenerQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewCompanyScreenerQuery

func NewCompanyScreenerQuery() CompanyScreenerQuery

NewCompanyScreenerQuery creates the query from its required arguments.

func (CompanyScreenerQuery) BetaLowerThan

func (q CompanyScreenerQuery) BetaLowerThan() *float64

BetaLowerThan returns the optional beta_lower_than parameter, or nil when it is unset.

func (CompanyScreenerQuery) BetaMoreThan

func (q CompanyScreenerQuery) BetaMoreThan() *float64

BetaMoreThan returns the optional beta_more_than parameter, or nil when it is unset.

func (CompanyScreenerQuery) Country

func (q CompanyScreenerQuery) Country() *string

Country returns the optional country parameter, or nil when it is unset.

func (CompanyScreenerQuery) DividendLowerThan

func (q CompanyScreenerQuery) DividendLowerThan() *float64

DividendLowerThan returns the optional dividend_lower_than parameter, or nil when it is unset.

func (CompanyScreenerQuery) DividendMoreThan

func (q CompanyScreenerQuery) DividendMoreThan() *float64

DividendMoreThan returns the optional dividend_more_than parameter, or nil when it is unset.

func (CompanyScreenerQuery) Exchange

func (q CompanyScreenerQuery) Exchange() *string

Exchange returns the optional exchange parameter, or nil when it is unset.

func (CompanyScreenerQuery) IncludeAllShareClasses

func (q CompanyScreenerQuery) IncludeAllShareClasses() *bool

IncludeAllShareClasses returns the optional include_all_share_classes parameter, or nil when it is unset.

func (CompanyScreenerQuery) Industry

func (q CompanyScreenerQuery) Industry() *string

Industry returns the optional industry parameter, or nil when it is unset.

func (CompanyScreenerQuery) IsActivelyTrading

func (q CompanyScreenerQuery) IsActivelyTrading() *bool

IsActivelyTrading returns the optional is_actively_trading parameter, or nil when it is unset.

func (CompanyScreenerQuery) IsETF added in v0.12.0

func (q CompanyScreenerQuery) IsETF() *bool

IsETF returns the optional is_etf parameter, or nil when it is unset.

func (CompanyScreenerQuery) IsFund

func (q CompanyScreenerQuery) IsFund() *bool

IsFund returns the optional is_fund parameter, or nil when it is unset.

func (CompanyScreenerQuery) Limit

func (q CompanyScreenerQuery) Limit() *uint32

Limit returns the optional limit parameter, or nil when it is unset.

func (CompanyScreenerQuery) MarketCapLowerThan

func (q CompanyScreenerQuery) MarketCapLowerThan() *uint64

MarketCapLowerThan returns the optional market_cap_lower_than parameter, or nil when it is unset.

func (CompanyScreenerQuery) MarketCapMoreThan

func (q CompanyScreenerQuery) MarketCapMoreThan() *uint64

MarketCapMoreThan returns the optional market_cap_more_than parameter, or nil when it is unset.

func (CompanyScreenerQuery) Page

func (q CompanyScreenerQuery) Page() *uint32

Page returns the optional page parameter, or nil when it is unset.

func (CompanyScreenerQuery) PriceLowerThan

func (q CompanyScreenerQuery) PriceLowerThan() *float64

PriceLowerThan returns the optional price_lower_than parameter, or nil when it is unset.

func (CompanyScreenerQuery) PriceMoreThan

func (q CompanyScreenerQuery) PriceMoreThan() *float64

PriceMoreThan returns the optional price_more_than parameter, or nil when it is unset.

func (CompanyScreenerQuery) Sector

func (q CompanyScreenerQuery) Sector() *string

Sector returns the optional sector parameter, or nil when it is unset.

func (CompanyScreenerQuery) VolumeLowerThan

func (q CompanyScreenerQuery) VolumeLowerThan() *uint64

VolumeLowerThan returns the optional volume_lower_than parameter, or nil when it is unset.

func (CompanyScreenerQuery) VolumeMoreThan

func (q CompanyScreenerQuery) VolumeMoreThan() *uint64

VolumeMoreThan returns the optional volume_more_than parameter, or nil when it is unset.

func (CompanyScreenerQuery) WithBetaLowerThan

func (q CompanyScreenerQuery) WithBetaLowerThan(betaLowerThan float64) CompanyScreenerQuery

WithBetaLowerThan sets the optional beta_lower_than parameter and returns the updated query.

func (CompanyScreenerQuery) WithBetaMoreThan

func (q CompanyScreenerQuery) WithBetaMoreThan(betaMoreThan float64) CompanyScreenerQuery

WithBetaMoreThan sets the optional beta_more_than parameter and returns the updated query.

func (CompanyScreenerQuery) WithCountry

func (q CompanyScreenerQuery) WithCountry(country string) CompanyScreenerQuery

WithCountry sets the optional country parameter and returns the updated query.

func (CompanyScreenerQuery) WithDividendLowerThan

func (q CompanyScreenerQuery) WithDividendLowerThan(dividendLowerThan float64) CompanyScreenerQuery

WithDividendLowerThan sets the optional dividend_lower_than parameter and returns the updated query.

func (CompanyScreenerQuery) WithDividendMoreThan

func (q CompanyScreenerQuery) WithDividendMoreThan(dividendMoreThan float64) CompanyScreenerQuery

WithDividendMoreThan sets the optional dividend_more_than parameter and returns the updated query.

func (CompanyScreenerQuery) WithExchange

func (q CompanyScreenerQuery) WithExchange(exchange string) CompanyScreenerQuery

WithExchange sets the optional exchange parameter and returns the updated query.

func (CompanyScreenerQuery) WithIncludeAllShareClasses

func (q CompanyScreenerQuery) WithIncludeAllShareClasses(includeAllShareClasses bool) CompanyScreenerQuery

WithIncludeAllShareClasses sets the optional include_all_share_classes parameter and returns the updated query.

func (CompanyScreenerQuery) WithIndustry

func (q CompanyScreenerQuery) WithIndustry(industry string) CompanyScreenerQuery

WithIndustry sets the optional industry parameter and returns the updated query.

func (CompanyScreenerQuery) WithIsActivelyTrading

func (q CompanyScreenerQuery) WithIsActivelyTrading(isActivelyTrading bool) CompanyScreenerQuery

WithIsActivelyTrading sets the optional is_actively_trading parameter and returns the updated query.

func (CompanyScreenerQuery) WithIsETF added in v0.12.0

func (q CompanyScreenerQuery) WithIsETF(isETF bool) CompanyScreenerQuery

WithIsETF sets the optional is_etf parameter and returns the updated query.

func (CompanyScreenerQuery) WithIsFund

func (q CompanyScreenerQuery) WithIsFund(isFund bool) CompanyScreenerQuery

WithIsFund sets the optional is_fund parameter and returns the updated query.

func (CompanyScreenerQuery) WithLimit

WithLimit sets the optional limit parameter and returns the updated query.

func (CompanyScreenerQuery) WithMarketCapLowerThan

func (q CompanyScreenerQuery) WithMarketCapLowerThan(marketCapLowerThan uint64) CompanyScreenerQuery

WithMarketCapLowerThan sets the optional market_cap_lower_than parameter and returns the updated query.

func (CompanyScreenerQuery) WithMarketCapMoreThan

func (q CompanyScreenerQuery) WithMarketCapMoreThan(marketCapMoreThan uint64) CompanyScreenerQuery

WithMarketCapMoreThan sets the optional market_cap_more_than parameter and returns the updated query.

func (CompanyScreenerQuery) WithPage

WithPage sets the optional page parameter and returns the updated query.

func (CompanyScreenerQuery) WithPriceLowerThan

func (q CompanyScreenerQuery) WithPriceLowerThan(priceLowerThan float64) CompanyScreenerQuery

WithPriceLowerThan sets the optional price_lower_than parameter and returns the updated query.

func (CompanyScreenerQuery) WithPriceMoreThan

func (q CompanyScreenerQuery) WithPriceMoreThan(priceMoreThan float64) CompanyScreenerQuery

WithPriceMoreThan sets the optional price_more_than parameter and returns the updated query.

func (CompanyScreenerQuery) WithSector

func (q CompanyScreenerQuery) WithSector(sector string) CompanyScreenerQuery

WithSector sets the optional sector parameter and returns the updated query.

func (CompanyScreenerQuery) WithVolumeLowerThan

func (q CompanyScreenerQuery) WithVolumeLowerThan(volumeLowerThan uint64) CompanyScreenerQuery

WithVolumeLowerThan sets the optional volume_lower_than parameter and returns the updated query.

func (CompanyScreenerQuery) WithVolumeMoreThan

func (q CompanyScreenerQuery) WithVolumeMoreThan(volumeMoreThan uint64) CompanyScreenerQuery

WithVolumeMoreThan sets the optional volume_more_than parameter and returns the updated query.

type CompanyScreenerResult added in v0.12.0

type CompanyScreenerResult struct {
	Symbol             string  `json:"symbol"`
	CompanyName        string  `json:"companyName"`
	MarketCap          float64 `json:"marketCap"`
	Sector             string  `json:"sector"`
	Industry           string  `json:"industry"`
	Beta               float64 `json:"beta"`
	Price              float64 `json:"price"`
	LastAnnualDividend float64 `json:"lastAnnualDividend"`
	Volume             float64 `json:"volume"`
	Exchange           string  `json:"exchange"`
	ExchangeShortName  string  `json:"exchangeShortName"`
	Country            string  `json:"country"`
	IsETF              bool    `json:"isEtf"`
	IsFund             bool    `json:"isFund"`
	IsActivelyTrading  bool    `json:"isActivelyTrading"`
}

CompanyScreenerResult is one worldwide company returned by the stock screener.

func (*CompanyScreenerResult) UnmarshalJSONFrom added in v0.12.0

func (m *CompanyScreenerResult) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type CompanyShareFloat

type CompanyShareFloat struct {
	Symbol            string   `json:"symbol"`
	Date              DateTime `json:"date"`
	FreeFloat         float64  `json:"freeFloat"`
	FloatShares       float64  `json:"floatShares"`
	OutstandingShares float64  `json:"outstandingShares"`
	Source            string   `json:"source"`
}

CompanyShareFloat is one worldwide company share-float observation with its filing source.

func (*CompanyShareFloat) UnmarshalJSONFrom

func (m *CompanyShareFloat) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type CompanySymbol

type CompanySymbol struct {
	Symbol      string `json:"symbol"`
	CompanyName string `json:"companyName"`
}

CompanySymbol is one worldwide company or instrument in the company-symbol directory.

func (*CompanySymbol) UnmarshalJSONFrom

func (m *CompanySymbol) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type ConditionalPlanRequirement

type ConditionalPlanRequirement struct {
	Plan      string
	Condition PlanCondition
}

ConditionalPlanRequirement names a plan required only when its condition applies. It mirrors the Rust ConditionalPlanRequirement.

func (ConditionalPlanRequirement) String

String returns a short label that is safe to log.

type ConfigurationKind

type ConfigurationKind int

ConfigurationKind is the machine-readable reason a configuration was rejected. It mirrors ConfigurationErrorKind in the Rust crate.

const (
	// ConfigurationKindNone marks an error that is not a configuration error.
	ConfigurationKindNone ConfigurationKind = iota
	// ConfigurationKindInvalidBaseURL: the base URL is not an absolute HTTP(S) URL.
	ConfigurationKindInvalidBaseURL
	// ConfigurationKindUnsafeBaseURL: the base URL carries user info, a query, or a fragment.
	ConfigurationKindUnsafeBaseURL
	// ConfigurationKindInvalidPath: a path prefix or endpoint path has unsafe segments.
	ConfigurationKindInvalidPath
	// ConfigurationKindInvalidHeaderName: a header name is not a valid HTTP field name.
	ConfigurationKindInvalidHeaderName
	// ConfigurationKindInvalidHeaderValue: a header value is not a valid HTTP field value.
	ConfigurationKindInvalidHeaderValue
	// ConfigurationKindInvalidQueryName: a query name is empty or has control characters.
	ConfigurationKindInvalidQueryName
	// ConfigurationKindEmptyCredential: a credential is empty.
	ConfigurationKindEmptyCredential
	// ConfigurationKindMissingCredential: direct FMP access has no credential.
	ConfigurationKindMissingCredential
	// ConfigurationKindInsecureAuthentication: a credential over plain HTTP to a non-loopback host.
	ConfigurationKindInsecureAuthentication
	// ConfigurationKindConflictingAuthentication: authentication was configured more than once.
	ConfigurationKindConflictingAuthentication
	// ConfigurationKindProtectedFieldCollision: a caller tried to replace a transport-owned field.
	ConfigurationKindProtectedFieldCollision
	// ConfigurationKindHTTPClient: the underlying HTTP client could not be built.
	ConfigurationKindHTTPClient
)

type CongressionalDebtDetails

type CongressionalDebtDetails struct {
	DateIncurred string `json:"dateIncurred"`
}

CongressionalDebtDetails is opaque provider details for a disclosed debt.

func (*CongressionalDebtDetails) UnmarshalJSONFrom

func (m *CongressionalDebtDetails) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type CongressionalMemberNetWorth added in v0.12.0

type CongressionalMemberNetWorth struct {
	MemberID    string                      `json:"senateID"`
	FormType    string                      `json:"formType"`
	Year        uint32                      `json:"year"`
	FilingDate  Date                        `json:"filingDate"`
	Section     string                      `json:"section"`
	Category    string                      `json:"category"`
	Name        string                      `json:"name"`
	AssetType   string                      `json:"assetType"`
	IncomeType  *string                     `json:"incomeType"`
	Owner       string                      `json:"owner"`
	Comment     *string                     `json:"comment"`
	DebtDetails *CongressionalDebtDetails   `json:"debtDetails"`
	ValueRange  *CongressionalNetWorthRange `json:"valueRange"`
	Value       int64                       `json:"value"`
	IncomeRange *CongressionalNetWorthRange `json:"incomeRange"`
	Income      *jsontext.Value             `json:"income"`
	Link        string                      `json:"link"`
}

CongressionalMemberNetWorth is one itemized congressional net-worth disclosure.

func (*CongressionalMemberNetWorth) UnmarshalJSONFrom added in v0.12.0

func (m *CongressionalMemberNetWorth) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type CongressionalMemberNetWorthAggregate

type CongressionalMemberNetWorthAggregate struct {
	MemberID                  string `json:"senateID"`
	Year                      uint32 `json:"year"`
	Total                     int64  `json:"total"`
	RealEstateLiabilities     int64  `json:"realEstateLiabilities"`
	CashAndCashEquivalents    int64  `json:"cashAndCashEquivalents"`
	BusinessAndSelfEmployment int64  `json:"businessAndSelfEmployment"`
	RealEstate                int64  `json:"realEstate"`
	OwnershipInterest         int64  `json:"ownershipInterest"`
	Stock                     int64  `json:"stock"`
	Options                   int64  `json:"options"`
	RevolvingAndCreditLines   int64  `json:"revolvingAndCreditLines"`
	AssetBackedSecurities     int64  `json:"assetBackedSecurities"`
	BusinessLiabilities       int64  `json:"businessLiabilities"`
	MutualFundsAndETFs        int64  `json:"mutualFundsAndETFs"`
}

CongressionalMemberNetWorthAggregate is aggregated congressional net-worth totals for one filing year.

func (*CongressionalMemberNetWorthAggregate) UnmarshalJSONFrom

func (m *CongressionalMemberNetWorthAggregate) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type CongressionalMemberPosition

type CongressionalMemberPosition struct {
	MemberID       string  `json:"senateID"`
	CongressNumber uint32  `json:"congressNumber"`
	StartDate      Date    `json:"startDate"`
	EndDate        *Date   `json:"endDate"`
	Party          string  `json:"party"`
	Position       string  `json:"position"`
	State          string  `json:"state"`
	YearsInTerm    float64 `json:"yearsInTerm"`
}

CongressionalMemberPosition is one congressional position held by a member.

func (*CongressionalMemberPosition) UnmarshalJSONFrom

func (m *CongressionalMemberPosition) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type CongressionalMemberProfile

type CongressionalMemberProfile struct {
	MemberID       string  `json:"senateID"`
	FirstName      string  `json:"firstName"`
	LastName       string  `json:"lastName"`
	BirthDate      Date    `json:"birthDate"`
	LatestParty    string  `json:"latestParty"`
	LatestState    string  `json:"latestState"`
	LatestPosition string  `json:"latestPosition"`
	Image          string  `json:"image"`
	Active         bool    `json:"active"`
	YearsActive    float64 `json:"yearsActive"`
}

CongressionalMemberProfile is one current or historical profile for a member of Congress.

func (*CongressionalMemberProfile) UnmarshalJSONFrom

func (m *CongressionalMemberProfile) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type CongressionalNamespace

type CongressionalNamespace struct {
	// contains filtered or unexported fields
}

CongressionalNamespace groups the congressional endpoints. It is reached as Client.Congressional and is valid only when obtained from a Client built by NewClient.

func (*CongressionalNamespace) HouseTrades

HouseTrades retrieves House trades for one ticker.

GET house-trades?symbol=&page=&limit=

func (*CongressionalNamespace) HouseTradesByMemberID added in v0.12.0

HouseTradesByMemberID looks up House trades by an optional member ID and pagination.

GET house-trades-by-id?page=&limit=&senateID=

func (*CongressionalNamespace) HouseTradesByName

HouseTradesByName searches House trades by member name.

GET house-trades-by-name?name=

func (*CongressionalNamespace) LatestHouseDisclosures

LatestHouseDisclosures retrieves the latest House financial disclosures.

GET house-latest?page=&limit=

func (*CongressionalNamespace) LatestSenateDisclosures

LatestSenateDisclosures retrieves the latest Senate financial disclosures.

GET senate-latest?page=&limit=

func (*CongressionalNamespace) NetWorth

NetWorth retrieves itemized congressional net-worth disclosures.

GET senate-net-worth?senateID=&page=&limit=

func (*CongressionalNamespace) NetWorthAggregated

NetWorthAggregated retrieves aggregated congressional net-worth totals by year.

GET senate-net-worth-aggregated?senateID=&totalsCol=

func (*CongressionalNamespace) Positions

Positions retrieves congressional position history using optional provider filters.

GET senate-positions?senateID=&party=&position=&page=&limit=

func (*CongressionalNamespace) Profiles

Profiles retrieves congressional profiles using optional provider filters.

GET senate-profile?active=&senateID=&latestParty=&latestPosition=&page=&limit=

func (*CongressionalNamespace) SenateTrades

SenateTrades retrieves Senate trades for one ticker.

GET senate-trades?symbol=&page=&limit=

func (*CongressionalNamespace) SenateTradesByMemberID added in v0.12.0

SenateTradesByMemberID looks up Senate trades by an optional member ID and pagination.

GET senate-trades-by-id?page=&limit=&senateID=

func (*CongressionalNamespace) SenateTradesByName

SenateTradesByName searches Senate trades by member name.

GET senate-trades-by-name?name=

type CongressionalNetWorthAggregatedQuery

type CongressionalNetWorthAggregatedQuery struct {
	// contains filtered or unexported fields
}

CongressionalNetWorthAggregatedQuery holds the query parameters of the endpoints that take it: NewCongressionalNetWorthAggregatedQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewCongressionalNetWorthAggregatedQuery

func NewCongressionalNetWorthAggregatedQuery(memberID string) CongressionalNetWorthAggregatedQuery

NewCongressionalNetWorthAggregatedQuery creates the query from its required arguments.

func (CongressionalNetWorthAggregatedQuery) MemberID added in v0.12.0

MemberID returns the member_id argument as given.

func (CongressionalNetWorthAggregatedQuery) TotalsCol

TotalsCol returns the optional totals_col parameter, or nil when it is unset.

func (CongressionalNetWorthAggregatedQuery) WithTotalsCol

WithTotalsCol sets the optional totals_col parameter and returns the updated query.

type CongressionalNetWorthQuery

type CongressionalNetWorthQuery struct {
	// contains filtered or unexported fields
}

CongressionalNetWorthQuery holds the query parameters of the endpoints that take it: NewCongressionalNetWorthQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewCongressionalNetWorthQuery

func NewCongressionalNetWorthQuery(memberID string) CongressionalNetWorthQuery

NewCongressionalNetWorthQuery creates the query from its required arguments.

func (CongressionalNetWorthQuery) Limit

Limit returns the optional limit parameter, or nil when it is unset.

func (CongressionalNetWorthQuery) MemberID added in v0.12.0

func (q CongressionalNetWorthQuery) MemberID() string

MemberID returns the member_id argument as given.

func (CongressionalNetWorthQuery) Page

Page returns the optional page parameter, or nil when it is unset.

func (CongressionalNetWorthQuery) WithLimit

WithLimit sets the optional limit parameter and returns the updated query.

func (CongressionalNetWorthQuery) WithPage

WithPage sets the optional page parameter and returns the updated query.

type CongressionalNetWorthRange

type CongressionalNetWorthRange struct {
	Min int64 `json:"min"`
	Max int64 `json:"max"`
}

CongressionalNetWorthRange is a minimum and maximum value disclosed for a congressional asset or income.

func (*CongressionalNetWorthRange) UnmarshalJSONFrom

func (m *CongressionalNetWorthRange) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type CongressionalPositionsQuery

type CongressionalPositionsQuery struct {
	// contains filtered or unexported fields
}

CongressionalPositionsQuery holds the query parameters of the endpoints that take it: NewCongressionalPositionsQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewCongressionalPositionsQuery

func NewCongressionalPositionsQuery() CongressionalPositionsQuery

NewCongressionalPositionsQuery creates the query from its required arguments.

func (CongressionalPositionsQuery) Limit

Limit returns the optional limit parameter, or nil when it is unset.

func (CongressionalPositionsQuery) MemberID added in v0.12.0

func (q CongressionalPositionsQuery) MemberID() *string

MemberID returns the optional member_id parameter, or nil when it is unset.

func (CongressionalPositionsQuery) Page

Page returns the optional page parameter, or nil when it is unset.

func (CongressionalPositionsQuery) Party

Party returns the optional party parameter, or nil when it is unset.

func (CongressionalPositionsQuery) Position

func (q CongressionalPositionsQuery) Position() *string

Position returns the optional position parameter, or nil when it is unset.

func (CongressionalPositionsQuery) WithLimit

WithLimit sets the optional limit parameter and returns the updated query.

func (CongressionalPositionsQuery) WithMemberID added in v0.12.0

WithMemberID sets the optional member_id parameter and returns the updated query.

func (CongressionalPositionsQuery) WithPage

WithPage sets the optional page parameter and returns the updated query.

func (CongressionalPositionsQuery) WithParty

WithParty sets the optional party parameter and returns the updated query.

func (CongressionalPositionsQuery) WithPosition

WithPosition sets the optional position parameter and returns the updated query.

type CongressionalProfilesQuery

type CongressionalProfilesQuery struct {
	// contains filtered or unexported fields
}

CongressionalProfilesQuery holds the query parameters of the endpoints that take it: NewCongressionalProfilesQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewCongressionalProfilesQuery

func NewCongressionalProfilesQuery() CongressionalProfilesQuery

NewCongressionalProfilesQuery creates the query from its required arguments.

func (CongressionalProfilesQuery) Active

func (q CongressionalProfilesQuery) Active() *bool

Active returns the optional active parameter, or nil when it is unset.

func (CongressionalProfilesQuery) LatestParty

func (q CongressionalProfilesQuery) LatestParty() *string

LatestParty returns the optional latest_party parameter, or nil when it is unset.

func (CongressionalProfilesQuery) LatestPosition

func (q CongressionalProfilesQuery) LatestPosition() *string

LatestPosition returns the optional latest_position parameter, or nil when it is unset.

func (CongressionalProfilesQuery) Limit

Limit returns the optional limit parameter, or nil when it is unset.

func (CongressionalProfilesQuery) MemberID added in v0.12.0

func (q CongressionalProfilesQuery) MemberID() *string

MemberID returns the optional member_id parameter, or nil when it is unset.

func (CongressionalProfilesQuery) Page

Page returns the optional page parameter, or nil when it is unset.

func (CongressionalProfilesQuery) WithActive

WithActive sets the optional active parameter and returns the updated query.

func (CongressionalProfilesQuery) WithLatestParty

func (q CongressionalProfilesQuery) WithLatestParty(latestParty string) CongressionalProfilesQuery

WithLatestParty sets the optional latest_party parameter and returns the updated query.

func (CongressionalProfilesQuery) WithLatestPosition

func (q CongressionalProfilesQuery) WithLatestPosition(latestPosition string) CongressionalProfilesQuery

WithLatestPosition sets the optional latest_position parameter and returns the updated query.

func (CongressionalProfilesQuery) WithLimit

WithLimit sets the optional limit parameter and returns the updated query.

func (CongressionalProfilesQuery) WithMemberID added in v0.12.0

WithMemberID sets the optional member_id parameter and returns the updated query.

func (CongressionalProfilesQuery) WithPage

WithPage sets the optional page parameter and returns the updated query.

type CongressionalTrade

type CongressionalTrade struct {
	Symbol                 string  `json:"symbol"`
	MemberID               string  `json:"senateID"`
	DisclosureDate         Date    `json:"disclosureDate"`
	TransactionDate        Date    `json:"transactionDate"`
	FirstName              string  `json:"firstName"`
	LastName               string  `json:"lastName"`
	Office                 string  `json:"office"`
	District               string  `json:"district"`
	Owner                  string  `json:"owner"`
	AssetDescription       string  `json:"assetDescription"`
	AssetType              string  `json:"assetType"`
	TransactionType        string  `json:"type"`
	Amount                 string  `json:"amount"`
	CapitalGainsOver200Usd *string `json:"capitalGainsOver200USD,omitzero"`
	Comment                string  `json:"comment"`
	Link                   string  `json:"link"`
}

CongressionalTrade is one financial trade disclosed by a member of Congress.

func (*CongressionalTrade) UnmarshalJSONFrom

func (m *CongressionalTrade) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type CongressionalTradesByMemberIDQuery added in v0.12.0

type CongressionalTradesByMemberIDQuery struct {
	// contains filtered or unexported fields
}

CongressionalTradesByMemberIDQuery holds the query parameters of the endpoints that take it: NewCongressionalTradesByMemberIDQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewCongressionalTradesByMemberIDQuery added in v0.12.0

func NewCongressionalTradesByMemberIDQuery() CongressionalTradesByMemberIDQuery

NewCongressionalTradesByMemberIDQuery creates the query from its required arguments.

func (CongressionalTradesByMemberIDQuery) Limit added in v0.12.0

Limit returns the optional limit parameter, or nil when it is unset.

func (CongressionalTradesByMemberIDQuery) MemberID added in v0.12.0

MemberID returns the optional member_id parameter, or nil when it is unset.

func (CongressionalTradesByMemberIDQuery) Page added in v0.12.0

Page returns the optional page parameter, or nil when it is unset.

func (CongressionalTradesByMemberIDQuery) WithLimit added in v0.12.0

WithLimit sets the optional limit parameter and returns the updated query.

func (CongressionalTradesByMemberIDQuery) WithMemberID added in v0.12.0

WithMemberID sets the optional member_id parameter and returns the updated query.

func (CongressionalTradesByMemberIDQuery) WithPage added in v0.12.0

WithPage sets the optional page parameter and returns the updated query.

type CongressionalTradesByNameQuery

type CongressionalTradesByNameQuery struct {
	// contains filtered or unexported fields
}

CongressionalTradesByNameQuery holds the query parameters of the endpoints that take it: NewCongressionalTradesByNameQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewCongressionalTradesByNameQuery

func NewCongressionalTradesByNameQuery(name string) CongressionalTradesByNameQuery

NewCongressionalTradesByNameQuery creates the query from its required arguments.

func (CongressionalTradesByNameQuery) Name

Name returns the name argument as given.

type CongressionalTradesQuery

type CongressionalTradesQuery struct {
	// contains filtered or unexported fields
}

CongressionalTradesQuery holds the query parameters of the endpoints that take it: NewCongressionalTradesQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewCongressionalTradesQuery

func NewCongressionalTradesQuery(symbol string) CongressionalTradesQuery

NewCongressionalTradesQuery creates the query from its required arguments.

func (CongressionalTradesQuery) Limit

func (q CongressionalTradesQuery) Limit() *uint32

Limit returns the optional limit parameter, or nil when it is unset.

func (CongressionalTradesQuery) Page

func (q CongressionalTradesQuery) Page() *uint32

Page returns the optional page parameter, or nil when it is unset.

func (CongressionalTradesQuery) Symbol

func (q CongressionalTradesQuery) Symbol() string

Symbol returns the symbol argument as given.

func (CongressionalTradesQuery) WithLimit

WithLimit sets the optional limit parameter and returns the updated query.

func (CongressionalTradesQuery) WithPage

WithPage sets the optional page parameter and returns the updated query.

type CrowdfundingOffering

type CrowdfundingOffering struct {
	CIK                                       string         `json:"cik"`
	CompanyName                               string         `json:"companyName"`
	Date                                      USDate         `json:"date"`
	FilingDate                                DateTime       `json:"filingDate"`
	AcceptedDate                              DateTime       `json:"acceptedDate"`
	FormType                                  string         `json:"formType"`
	FormSignification                         string         `json:"formSignification"`
	NameOfIssuer                              string         `json:"nameOfIssuer"`
	LegalStatusForm                           string         `json:"legalStatusForm"`
	JurisdictionOrganization                  string         `json:"jurisdictionOrganization"`
	IssuerStreet                              string         `json:"issuerStreet"`
	IssuerCity                                string         `json:"issuerCity"`
	IssuerStateOrCountry                      string         `json:"issuerStateOrCountry"`
	IssuerZipCode                             string         `json:"issuerZipCode"`
	IssuerWebsite                             string         `json:"issuerWebsite"`
	IntermediaryCompanyName                   string         `json:"intermediaryCompanyName"`
	IntermediaryCommissionCIK                 string         `json:"intermediaryCommissionCik"`
	IntermediaryCommissionFileNumber          string         `json:"intermediaryCommissionFileNumber"`
	CompensationAmount                        string         `json:"compensationAmount"`
	FinancialInterest                         string         `json:"financialInterest"`
	SecurityOfferedType                       string         `json:"securityOfferedType"`
	SecurityOfferedOtherDescription           *string        `json:"securityOfferedOtherDescription"`
	NumberOfSecurityOffered                   float64        `json:"numberOfSecurityOffered"`
	OfferingPrice                             jsontext.Value `json:"offeringPrice"`
	OfferingAmount                            float64        `json:"offeringAmount"`
	OverSubscriptionAccepted                  string         `json:"overSubscriptionAccepted"`
	OverSubscriptionAllocationType            string         `json:"overSubscriptionAllocationType"`
	MaximumOfferingAmount                     float64        `json:"maximumOfferingAmount"`
	OfferingDeadlineDate                      USDate         `json:"offeringDeadlineDate"`
	CurrentNumberOfEmployees                  uint64         `json:"currentNumberOfEmployees"`
	TotalAssetMostRecentFiscalYear            float64        `json:"totalAssetMostRecentFiscalYear"`
	TotalAssetPriorFiscalYear                 float64        `json:"totalAssetPriorFiscalYear"`
	CashAndCashEquivalentMostRecentFiscalYear float64        `json:"cashAndCashEquiValentMostRecentFiscalYear"`
	CashAndCashEquivalentPriorFiscalYear      float64        `json:"cashAndCashEquiValentPriorFiscalYear"`
	AccountsReceivableMostRecentFiscalYear    float64        `json:"accountsReceivableMostRecentFiscalYear"`
	AccountsReceivablePriorFiscalYear         float64        `json:"accountsReceivablePriorFiscalYear"`
	ShortTermDebtMostRecentFiscalYear         float64        `json:"shortTermDebtMostRecentFiscalYear"`
	ShortTermDebtPriorFiscalYear              float64        `json:"shortTermDebtPriorFiscalYear"`
	LongTermDebtMostRecentFiscalYear          float64        `json:"longTermDebtMostRecentFiscalYear"`
	LongTermDebtPriorFiscalYear               float64        `json:"longTermDebtPriorFiscalYear"`
	RevenueMostRecentFiscalYear               float64        `json:"revenueMostRecentFiscalYear"`
	RevenuePriorFiscalYear                    float64        `json:"revenuePriorFiscalYear"`
	CostGoodsSoldMostRecentFiscalYear         float64        `json:"costGoodsSoldMostRecentFiscalYear"`
	CostGoodsSoldPriorFiscalYear              float64        `json:"costGoodsSoldPriorFiscalYear"`
	TaxesPaidMostRecentFiscalYear             float64        `json:"taxesPaidMostRecentFiscalYear"`
	TaxesPaidPriorFiscalYear                  float64        `json:"taxesPaidPriorFiscalYear"`
	NetIncomeMostRecentFiscalYear             float64        `json:"netIncomeMostRecentFiscalYear"`
	NetIncomePriorFiscalYear                  float64        `json:"netIncomePriorFiscalYear"`
}

CrowdfundingOffering is one detailed crowdfunding offering.

func (*CrowdfundingOffering) UnmarshalJSONFrom

func (m *CrowdfundingOffering) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type CrowdfundingOfferingSearchResult

type CrowdfundingOfferingSearchResult struct {
	CIK  string          `json:"cik"`
	Name string          `json:"name"`
	Date *jsontext.Value `json:"date"`
}

CrowdfundingOfferingSearchResult is one compact crowdfunding-offering search result.

func (*CrowdfundingOfferingSearchResult) UnmarshalJSONFrom

func (m *CrowdfundingOfferingSearchResult) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type CryptoNamespace

type CryptoNamespace struct {
	// contains filtered or unexported fields
}

CryptoNamespace groups the crypto endpoints. It is reached as Client.Crypto and is valid only when obtained from a Client built by NewClient.

func (*CryptoNamespace) ChartFiveMinutes

func (n *CryptoNamespace) ChartFiveMinutes(ctx context.Context, q AssetChartQuery) ([]StockChartIntradayBar, error)

ChartFiveMinutes retrieves five-minute cryptocurrency history.

GET historical-chart/5min?symbol=&from=&to=

func (*CryptoNamespace) ChartFull

ChartFull retrieves detailed end-of-day cryptocurrency history.

GET historical-price-eod/full?symbol=&from=&to=

func (*CryptoNamespace) ChartLight

ChartLight retrieves compact end-of-day cryptocurrency history.

GET historical-price-eod/light?symbol=&from=&to=

func (*CryptoNamespace) ChartOneHour

ChartOneHour retrieves one-hour cryptocurrency history.

GET historical-chart/1hour?symbol=&from=&to=

func (*CryptoNamespace) ChartOneMinute

ChartOneMinute retrieves one-minute cryptocurrency history.

GET historical-chart/1min?symbol=&from=&to=

func (*CryptoNamespace) List

List lists the provider's documented cryptocurrency catalog.

GET cryptocurrency-list

func (*CryptoNamespace) Quote

func (n *CryptoNamespace) Quote(ctx context.Context, q QuoteQuery) ([]Quote, error)

Quote retrieves a detailed quote for one cryptocurrency.

GET quote?symbol=

func (*CryptoNamespace) QuoteShort

func (n *CryptoNamespace) QuoteShort(ctx context.Context, q QuoteShortQuery) ([]QuoteShort, error)

QuoteShort retrieves a compact quote for one cryptocurrency.

GET quote-short?symbol=

type CryptocurrencyListing

type CryptocurrencyListing struct {
	Symbol            string  `json:"symbol"`
	Name              string  `json:"name"`
	Exchange          string  `json:"exchange"`
	IcoDate           Date    `json:"icoDate"`
	CirculatingSupply float64 `json:"circulatingSupply"`
	TotalSupply       float64 `json:"totalSupply"`
}

CryptocurrencyListing is one cryptocurrency in the provider's documented cryptocurrency catalog.

func (*CryptocurrencyListing) UnmarshalJSONFrom

func (m *CryptocurrencyListing) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type CustomDCFQuery added in v0.12.0

type CustomDCFQuery struct {
	// contains filtered or unexported fields
}

CustomDCFQuery holds the query parameters of the endpoints that take it: NewCustomDCFQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewCustomDCFQuery added in v0.12.0

func NewCustomDCFQuery(symbol string) CustomDCFQuery

NewCustomDCFQuery creates the query from its required arguments.

func (CustomDCFQuery) Beta added in v0.12.0

func (q CustomDCFQuery) Beta() *float64

Beta returns the optional beta parameter, or nil when it is unset.

func (CustomDCFQuery) CapitalExpenditurePct added in v0.12.0

func (q CustomDCFQuery) CapitalExpenditurePct() *float64

CapitalExpenditurePct returns the optional capital_expenditure_pct parameter, or nil when it is unset.

func (CustomDCFQuery) CashAndShortTermInvestmentsPct added in v0.12.0

func (q CustomDCFQuery) CashAndShortTermInvestmentsPct() *float64

CashAndShortTermInvestmentsPct returns the optional cash_and_short_term_investments_pct parameter, or nil when it is unset.

func (CustomDCFQuery) CostOfDebt added in v0.12.0

func (q CustomDCFQuery) CostOfDebt() *float64

CostOfDebt returns the optional cost_of_debt parameter, or nil when it is unset.

func (CustomDCFQuery) CostOfEquity added in v0.12.0

func (q CustomDCFQuery) CostOfEquity() *float64

CostOfEquity returns the optional cost_of_equity parameter, or nil when it is unset.

func (CustomDCFQuery) DepreciationAndAmortizationPct added in v0.12.0

func (q CustomDCFQuery) DepreciationAndAmortizationPct() *float64

DepreciationAndAmortizationPct returns the optional depreciation_and_amortization_pct parameter, or nil when it is unset.

func (CustomDCFQuery) EbitPct added in v0.12.0

func (q CustomDCFQuery) EbitPct() *float64

EbitPct returns the optional ebit_pct parameter, or nil when it is unset.

func (CustomDCFQuery) EbitdaPct added in v0.12.0

func (q CustomDCFQuery) EbitdaPct() *float64

EbitdaPct returns the optional ebitda_pct parameter, or nil when it is unset.

func (CustomDCFQuery) InventoriesPct added in v0.12.0

func (q CustomDCFQuery) InventoriesPct() *float64

InventoriesPct returns the optional inventories_pct parameter, or nil when it is unset.

func (CustomDCFQuery) LongTermGrowthRate added in v0.12.0

func (q CustomDCFQuery) LongTermGrowthRate() *float64

LongTermGrowthRate returns the optional long_term_growth_rate parameter, or nil when it is unset.

func (CustomDCFQuery) MarketRiskPremium added in v0.12.0

func (q CustomDCFQuery) MarketRiskPremium() *float64

MarketRiskPremium returns the optional market_risk_premium parameter, or nil when it is unset.

func (CustomDCFQuery) OperatingCashFlowPct added in v0.12.0

func (q CustomDCFQuery) OperatingCashFlowPct() *float64

OperatingCashFlowPct returns the optional operating_cash_flow_pct parameter, or nil when it is unset.

func (CustomDCFQuery) PayablePct added in v0.12.0

func (q CustomDCFQuery) PayablePct() *float64

PayablePct returns the optional payable_pct parameter, or nil when it is unset.

func (CustomDCFQuery) ReceivablesPct added in v0.12.0

func (q CustomDCFQuery) ReceivablesPct() *float64

ReceivablesPct returns the optional receivables_pct parameter, or nil when it is unset.

func (CustomDCFQuery) RevenueGrowthPct added in v0.12.0

func (q CustomDCFQuery) RevenueGrowthPct() *float64

RevenueGrowthPct returns the optional revenue_growth_pct parameter, or nil when it is unset.

func (CustomDCFQuery) RiskFreeRate added in v0.12.0

func (q CustomDCFQuery) RiskFreeRate() *float64

RiskFreeRate returns the optional risk_free_rate parameter, or nil when it is unset.

func (CustomDCFQuery) SellingGeneralAndAdministrativeExpensesPct added in v0.12.0

func (q CustomDCFQuery) SellingGeneralAndAdministrativeExpensesPct() *float64

SellingGeneralAndAdministrativeExpensesPct returns the optional selling_general_and_administrative_expenses_pct parameter, or nil when it is unset.

func (CustomDCFQuery) Symbol added in v0.12.0

func (q CustomDCFQuery) Symbol() string

Symbol returns the symbol argument as given.

func (CustomDCFQuery) TaxRate added in v0.12.0

func (q CustomDCFQuery) TaxRate() *float64

TaxRate returns the optional tax_rate parameter, or nil when it is unset.

func (CustomDCFQuery) WithBeta added in v0.12.0

func (q CustomDCFQuery) WithBeta(beta float64) CustomDCFQuery

WithBeta sets the optional beta parameter and returns the updated query.

func (CustomDCFQuery) WithCapitalExpenditurePct added in v0.12.0

func (q CustomDCFQuery) WithCapitalExpenditurePct(capitalExpenditurePct float64) CustomDCFQuery

WithCapitalExpenditurePct sets the optional capital_expenditure_pct parameter and returns the updated query.

func (CustomDCFQuery) WithCashAndShortTermInvestmentsPct added in v0.12.0

func (q CustomDCFQuery) WithCashAndShortTermInvestmentsPct(cashAndShortTermInvestmentsPct float64) CustomDCFQuery

WithCashAndShortTermInvestmentsPct sets the optional cash_and_short_term_investments_pct parameter and returns the updated query.

func (CustomDCFQuery) WithCostOfDebt added in v0.12.0

func (q CustomDCFQuery) WithCostOfDebt(costOfDebt float64) CustomDCFQuery

WithCostOfDebt sets the optional cost_of_debt parameter and returns the updated query.

func (CustomDCFQuery) WithCostOfEquity added in v0.12.0

func (q CustomDCFQuery) WithCostOfEquity(costOfEquity float64) CustomDCFQuery

WithCostOfEquity sets the optional cost_of_equity parameter and returns the updated query.

func (CustomDCFQuery) WithDepreciationAndAmortizationPct added in v0.12.0

func (q CustomDCFQuery) WithDepreciationAndAmortizationPct(depreciationAndAmortizationPct float64) CustomDCFQuery

WithDepreciationAndAmortizationPct sets the optional depreciation_and_amortization_pct parameter and returns the updated query.

func (CustomDCFQuery) WithEbitPct added in v0.12.0

func (q CustomDCFQuery) WithEbitPct(ebitPct float64) CustomDCFQuery

WithEbitPct sets the optional ebit_pct parameter and returns the updated query.

func (CustomDCFQuery) WithEbitdaPct added in v0.12.0

func (q CustomDCFQuery) WithEbitdaPct(ebitdaPct float64) CustomDCFQuery

WithEbitdaPct sets the optional ebitda_pct parameter and returns the updated query.

func (CustomDCFQuery) WithInventoriesPct added in v0.12.0

func (q CustomDCFQuery) WithInventoriesPct(inventoriesPct float64) CustomDCFQuery

WithInventoriesPct sets the optional inventories_pct parameter and returns the updated query.

func (CustomDCFQuery) WithLongTermGrowthRate added in v0.12.0

func (q CustomDCFQuery) WithLongTermGrowthRate(longTermGrowthRate float64) CustomDCFQuery

WithLongTermGrowthRate sets the optional long_term_growth_rate parameter and returns the updated query.

func (CustomDCFQuery) WithMarketRiskPremium added in v0.12.0

func (q CustomDCFQuery) WithMarketRiskPremium(marketRiskPremium float64) CustomDCFQuery

WithMarketRiskPremium sets the optional market_risk_premium parameter and returns the updated query.

func (CustomDCFQuery) WithOperatingCashFlowPct added in v0.12.0

func (q CustomDCFQuery) WithOperatingCashFlowPct(operatingCashFlowPct float64) CustomDCFQuery

WithOperatingCashFlowPct sets the optional operating_cash_flow_pct parameter and returns the updated query.

func (CustomDCFQuery) WithPayablePct added in v0.12.0

func (q CustomDCFQuery) WithPayablePct(payablePct float64) CustomDCFQuery

WithPayablePct sets the optional payable_pct parameter and returns the updated query.

func (CustomDCFQuery) WithReceivablesPct added in v0.12.0

func (q CustomDCFQuery) WithReceivablesPct(receivablesPct float64) CustomDCFQuery

WithReceivablesPct sets the optional receivables_pct parameter and returns the updated query.

func (CustomDCFQuery) WithRevenueGrowthPct added in v0.12.0

func (q CustomDCFQuery) WithRevenueGrowthPct(revenueGrowthPct float64) CustomDCFQuery

WithRevenueGrowthPct sets the optional revenue_growth_pct parameter and returns the updated query.

func (CustomDCFQuery) WithRiskFreeRate added in v0.12.0

func (q CustomDCFQuery) WithRiskFreeRate(riskFreeRate float64) CustomDCFQuery

WithRiskFreeRate sets the optional risk_free_rate parameter and returns the updated query.

func (CustomDCFQuery) WithSellingGeneralAndAdministrativeExpensesPct added in v0.12.0

func (q CustomDCFQuery) WithSellingGeneralAndAdministrativeExpensesPct(sellingGeneralAndAdministrativeExpensesPct float64) CustomDCFQuery

WithSellingGeneralAndAdministrativeExpensesPct sets the optional selling_general_and_administrative_expenses_pct parameter and returns the updated query.

func (CustomDCFQuery) WithTaxRate added in v0.12.0

func (q CustomDCFQuery) WithTaxRate(taxRate float64) CustomDCFQuery

WithTaxRate sets the optional tax_rate parameter and returns the updated query.

type CustomDCFValuation added in v0.12.0

type CustomDCFValuation struct {
	Year                         string  `json:"year"`
	Symbol                       string  `json:"symbol"`
	Revenue                      float64 `json:"revenue"`
	RevenuePercentage            float64 `json:"revenuePercentage"`
	Ebitda                       float64 `json:"ebitda"`
	EbitdaPercentage             float64 `json:"ebitdaPercentage"`
	Ebit                         float64 `json:"ebit"`
	EbitPercentage               float64 `json:"ebitPercentage"`
	Depreciation                 float64 `json:"depreciation"`
	DepreciationPercentage       float64 `json:"depreciationPercentage"`
	TotalCash                    float64 `json:"totalCash"`
	TotalCashPercentage          float64 `json:"totalCashPercentage"`
	Receivables                  float64 `json:"receivables"`
	ReceivablesPercentage        float64 `json:"receivablesPercentage"`
	Inventories                  float64 `json:"inventories"`
	InventoriesPercentage        float64 `json:"inventoriesPercentage"`
	Payable                      float64 `json:"payable"`
	PayablePercentage            float64 `json:"payablePercentage"`
	CapitalExpenditure           float64 `json:"capitalExpenditure"`
	CapitalExpenditurePercentage float64 `json:"capitalExpenditurePercentage"`
	Price                        float64 `json:"price"`
	Beta                         float64 `json:"beta"`
	DilutedSharesOutstanding     float64 `json:"dilutedSharesOutstanding"`
	CostOfDebt                   float64 `json:"costofDebt"`
	TaxRate                      float64 `json:"taxRate"`
	AfterTaxCostOfDebt           float64 `json:"afterTaxCostOfDebt"`
	RiskFreeRate                 float64 `json:"riskFreeRate"`
	MarketRiskPremium            float64 `json:"marketRiskPremium"`
	CostOfEquity                 float64 `json:"costOfEquity"`
	TotalDebt                    float64 `json:"totalDebt"`
	TotalEquity                  float64 `json:"totalEquity"`
	TotalCapital                 float64 `json:"totalCapital"`
	DebtWeighting                float64 `json:"debtWeighting"`
	EquityWeighting              float64 `json:"equityWeighting"`
	Wacc                         float64 `json:"wacc"`
	TaxRateCash                  float64 `json:"taxRateCash"`
	Ebiat                        float64 `json:"ebiat"`
	Ufcf                         float64 `json:"ufcf"`
	SumPvUfcf                    float64 `json:"sumPvUfcf"`
	LongTermGrowthRate           float64 `json:"longTermGrowthRate"`
	TerminalValue                float64 `json:"terminalValue"`
	PresentTerminalValue         float64 `json:"presentTerminalValue"`
	EnterpriseValue              float64 `json:"enterpriseValue"`
	NetDebt                      float64 `json:"netDebt"`
	EquityValue                  float64 `json:"equityValue"`
	EquityValuePerShare          float64 `json:"equityValuePerShare"`
	FreeCashFlowT1               float64 `json:"freeCashFlowT1"`
}

CustomDCFValuation is one detailed valuation returned by the custom unlevered DCF route.

func (*CustomDCFValuation) UnmarshalJSONFrom added in v0.12.0

func (m *CustomDCFValuation) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type CustomLeveredDCFValuation added in v0.12.0

type CustomLeveredDCFValuation struct {
	Year                         string  `json:"year"`
	Symbol                       string  `json:"symbol"`
	Revenue                      float64 `json:"revenue"`
	RevenuePercentage            float64 `json:"revenuePercentage"`
	CapitalExpenditure           float64 `json:"capitalExpenditure"`
	CapitalExpenditurePercentage float64 `json:"capitalExpenditurePercentage"`
	Price                        float64 `json:"price"`
	Beta                         float64 `json:"beta"`
	DilutedSharesOutstanding     float64 `json:"dilutedSharesOutstanding"`
	CostOfDebt                   float64 `json:"costofDebt"`
	TaxRate                      float64 `json:"taxRate"`
	AfterTaxCostOfDebt           float64 `json:"afterTaxCostOfDebt"`
	RiskFreeRate                 float64 `json:"riskFreeRate"`
	MarketRiskPremium            float64 `json:"marketRiskPremium"`
	CostOfEquity                 float64 `json:"costOfEquity"`
	TotalDebt                    float64 `json:"totalDebt"`
	TotalEquity                  float64 `json:"totalEquity"`
	TotalCapital                 float64 `json:"totalCapital"`
	DebtWeighting                float64 `json:"debtWeighting"`
	EquityWeighting              float64 `json:"equityWeighting"`
	Wacc                         float64 `json:"wacc"`
	OperatingCashFlow            float64 `json:"operatingCashFlow"`
	PvLfcf                       float64 `json:"pvLfcf"`
	SumPvLfcf                    float64 `json:"sumPvLfcf"`
	LongTermGrowthRate           float64 `json:"longTermGrowthRate"`
	FreeCashFlow                 float64 `json:"freeCashFlow"`
	TerminalValue                float64 `json:"terminalValue"`
	PresentTerminalValue         float64 `json:"presentTerminalValue"`
	EnterpriseValue              float64 `json:"enterpriseValue"`
	NetDebt                      float64 `json:"netDebt"`
	EquityValue                  float64 `json:"equityValue"`
	EquityValuePerShare          float64 `json:"equityValuePerShare"`
	FreeCashFlowT1               float64 `json:"freeCashFlowT1"`
	OperatingCashFlowPercentage  float64 `json:"operatingCashFlowPercentage"`
}

CustomLeveredDCFValuation is one detailed valuation returned by the custom levered DCF route.

func (*CustomLeveredDCFValuation) UnmarshalJSONFrom added in v0.12.0

func (m *CustomLeveredDCFValuation) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type DCFNamespace added in v0.12.0

type DCFNamespace struct {
	// contains filtered or unexported fields
}

DCFNamespace groups the dcf endpoints. It is reached as Client.DCF and is valid only when obtained from a Client built by NewClient.

func (*DCFNamespace) Custom added in v0.12.0

Custom retrieves a custom unlevered discounted-cash-flow valuation.

GET custom-discounted-cash-flow?symbol=&revenueGrowthPct=&ebitdaPct=&depreciationAndAmortizationPct=&cashAndShortTermInvestmentsPct=&receivablesPct=&inventoriesPct=&payablePct=&ebitPct=&capitalExpenditurePct=&operatingCashFlowPct=&sellingGeneralAndAdministrativeExpensesPct=&taxRate=&longTermGrowthRate=&costOfDebt=&costOfEquity=&marketRiskPremium=&beta=&riskFreeRate=

func (*DCFNamespace) CustomLevered added in v0.12.0

CustomLevered retrieves a custom levered discounted-cash-flow valuation.

GET custom-levered-discounted-cash-flow?symbol=&revenueGrowthPct=&ebitdaPct=&depreciationAndAmortizationPct=&cashAndShortTermInvestmentsPct=&receivablesPct=&inventoriesPct=&payablePct=&ebitPct=&capitalExpenditurePct=&operatingCashFlowPct=&sellingGeneralAndAdministrativeExpensesPct=&taxRate=&longTermGrowthRate=&costOfDebt=&costOfEquity=&marketRiskPremium=&beta=&riskFreeRate=

func (*DCFNamespace) Levered added in v0.12.0

func (n *DCFNamespace) Levered(ctx context.Context, q DCFQuery) ([]DCFValuation, error)

Levered retrieves the levered discounted-cash-flow valuation for one company.

GET levered-discounted-cash-flow?symbol=

func (*DCFNamespace) Standard added in v0.12.0

func (n *DCFNamespace) Standard(ctx context.Context, q DCFQuery) ([]DCFValuation, error)

Standard retrieves the standard discounted-cash-flow valuation for one company.

GET discounted-cash-flow?symbol=

type DCFQuery added in v0.12.0

type DCFQuery struct {
	// contains filtered or unexported fields
}

DCFQuery holds the query parameters of the endpoints that take it: NewDCFQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewDCFQuery added in v0.12.0

func NewDCFQuery(symbol string) DCFQuery

NewDCFQuery creates the query from its required arguments.

func (DCFQuery) Symbol added in v0.12.0

func (q DCFQuery) Symbol() string

Symbol returns the symbol argument as given.

type DCFValuation added in v0.12.0

type DCFValuation struct {
	Symbol     string  `json:"symbol"`
	Date       Date    `json:"date"`
	DCF        float64 `json:"dcf"`
	StockPrice float64 `json:"Stock Price"`
}

DCFValuation is one standard or levered discounted-cash-flow valuation.

func (*DCFValuation) UnmarshalJSONFrom added in v0.12.0

func (m *DCFValuation) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type Date

type Date struct {
	// contains filtered or unexported fields
}

Date is a civil calendar date carried on the wire as exactly "YYYY-MM-DD". It has no zone and no time of day. The zero value is not a valid date and cannot be encoded; IsZero reports it.

func DateFromTime

func DateFromTime(t time.Time) (Date, error)

DateFromTime keeps the civil date of t in t's own location and drops the time of day and the zone. It fails when the year has more than four digits.

func NewDate

func NewDate(year int, month time.Month, day int) (Date, error)

NewDate validates a proleptic Gregorian date with a four-digit year.

func ParseDate

func ParseDate(value string) (Date, error)

ParseDate accepts exactly the "YYYY-MM-DD" shape the Rust crate accepts and rejects every other spelling, including trailing whitespace and calendar values that do not exist.

func (Date) Compare

func (d Date) Compare(other Date) int

Compare orders two dates chronologically: -1, 0, or +1.

func (Date) Day

func (d Date) Day() int

Day returns the day of the month.

func (Date) IsZero

func (d Date) IsZero() bool

IsZero reports whether d is the zero value, which is not a valid date.

func (Date) MarshalJSONTo

func (d Date) MarshalJSONTo(enc *jsontext.Encoder) error

MarshalJSONTo writes the date as a JSON string; the zero value is rejected.

func (Date) MarshalText

func (d Date) MarshalText() ([]byte, error)

MarshalText encodes the wire text; the zero value is rejected.

func (Date) Month

func (d Date) Month() time.Month

Month returns the calendar month.

func (Date) String

func (d Date) String() string

String returns the exact wire text "YYYY-MM-DD".

func (Date) Time

func (d Date) Time(loc *time.Location) time.Time

Time interprets the date as midnight in loc. A nil loc means UTC. The result carries a zone the wire value never had.

func (*Date) UnmarshalJSONFrom

func (d *Date) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom reads one JSON string. Any other JSON kind, including null, is rejected, matching the Rust decoder for a required field.

func (*Date) UnmarshalText

func (d *Date) UnmarshalText(text []byte) error

UnmarshalText parses the exact wire text.

func (Date) Year

func (d Date) Year() int

Year returns the four-digit year.

type DateTime

type DateTime struct {
	// contains filtered or unexported fields
}

DateTime is a zone-less provider datetime carried on the wire as exactly "YYYY-MM-DD HH:MM:SS". Seconds may be 60, as the Rust decoder accepts a leap second. The zero value is not a valid datetime and cannot be encoded.

func DateTimeFromTime

func DateTimeFromTime(t time.Time) (DateTime, error)

DateTimeFromTime keeps the wall-clock reading of t in t's own location and drops the zone and any sub-second precision.

func NewDateTime

func NewDateTime(year int, month time.Month, day, hour, minute, second int) (DateTime, error)

NewDateTime validates a civil date and a wall-clock time. The second may be 60 to represent a leap second.

func ParseDateTime

func ParseDateTime(value string) (DateTime, error)

ParseDateTime accepts exactly the "YYYY-MM-DD HH:MM:SS" shape the Rust crate accepts: no "T" separator, no zone suffix, no missing seconds.

func (DateTime) Clock

func (dt DateTime) Clock() (hour, minute, second int)

Clock returns the hour, minute, and second parts.

func (DateTime) Compare

func (dt DateTime) Compare(other DateTime) int

Compare orders two datetimes chronologically: -1, 0, or +1.

func (DateTime) Date

func (dt DateTime) Date() Date

Date returns the civil date part.

func (DateTime) IsZero

func (dt DateTime) IsZero() bool

IsZero reports whether dt is the zero value, which is not a valid datetime.

func (DateTime) MarshalJSONTo

func (dt DateTime) MarshalJSONTo(enc *jsontext.Encoder) error

MarshalJSONTo writes the datetime as a JSON string; the zero value is rejected.

func (DateTime) MarshalText

func (dt DateTime) MarshalText() ([]byte, error)

MarshalText encodes the wire text; the zero value is rejected.

func (DateTime) String

func (dt DateTime) String() string

String returns the exact wire text "YYYY-MM-DD HH:MM:SS".

func (DateTime) Time

func (dt DateTime) Time(loc *time.Location) time.Time

Time interprets the wall-clock reading in loc. A nil loc means UTC. The result carries a zone the wire value never had, and a leap second (second 60) rolls over into the next minute because time.Time cannot hold it.

func (*DateTime) UnmarshalJSONFrom

func (dt *DateTime) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom reads one JSON string. Any other JSON kind, including null, is rejected, matching the Rust decoder for a required field.

func (*DateTime) UnmarshalText

func (dt *DateTime) UnmarshalText(text []byte) error

UnmarshalText parses the exact wire text.

type DecodeKind added in v1.1.0

type DecodeKind int

DecodeKind is the coarse reason a successful JSON response failed to decode. It mirrors DecodeErrorKind in the Rust crate and never carries the offending member value. The values are stable: new kinds are only appended.

const (
	// DecodeKindNone marks an error that carries no decode location.
	DecodeKindNone DecodeKind = iota
	// DecodeKindSyntax: the body is not well-formed JSON.
	DecodeKindSyntax
	// DecodeKindNull: a member that requires a value was JSON null.
	DecodeKindNull
	// DecodeKindMissingMember: a required object member was absent.
	DecodeKindMissingMember
	// DecodeKindWrongType: a member had a JSON type the model does not accept.
	DecodeKindWrongType
	// DecodeKindInvalidValue: a member had the right JSON type but an unacceptable value.
	DecodeKindInvalidValue
)

func (DecodeKind) String added in v1.1.0

func (k DecodeKind) String() string

String returns the stable lowercase value shared with the Rust and Python SDKs, or "" for DecodeKindNone.

type DelayScope

type DelayScope int

DelayScope is the market scope a documented data delay applies to. It mirrors the Rust DelayScope; the zero value is DelayScopeUnspecified.

const (
	// DelayScopeUnspecified: the delay names no market.
	DelayScopeUnspecified DelayScope = iota
	// DelayScopeNasdaq: the delay applies to Nasdaq-listed data.
	DelayScopeNasdaq
)

func (DelayScope) String

func (s DelayScope) String() string

String returns a short stable label that is safe to log.

type DelistedCompaniesQuery

type DelistedCompaniesQuery struct {
	// contains filtered or unexported fields
}

DelistedCompaniesQuery holds the query parameters of the endpoints that take it: NewDelistedCompaniesQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewDelistedCompaniesQuery

func NewDelistedCompaniesQuery() DelistedCompaniesQuery

NewDelistedCompaniesQuery creates the query from its required arguments.

func (DelistedCompaniesQuery) Limit

func (q DelistedCompaniesQuery) Limit() *uint32

Limit returns the optional limit parameter, or nil when it is unset.

func (DelistedCompaniesQuery) Page

func (q DelistedCompaniesQuery) Page() *uint32

Page returns the optional page parameter, or nil when it is unset.

func (DelistedCompaniesQuery) WithLimit

WithLimit sets the optional limit parameter and returns the updated query.

func (DelistedCompaniesQuery) WithPage

WithPage sets the optional page parameter and returns the updated query.

type DelistedCompany

type DelistedCompany struct {
	Symbol       string `json:"symbol"`
	CompanyName  string `json:"companyName"`
	Exchange     string `json:"exchange"`
	IPODate      Date   `json:"ipoDate"`
	DelistedDate Date   `json:"delistedDate"`
}

DelistedCompany is one US company that has been removed from an exchange.

func (*DelistedCompany) UnmarshalJSONFrom

func (m *DelistedCompany) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type DirectoryNamespace

type DirectoryNamespace struct {
	// contains filtered or unexported fields
}

DirectoryNamespace groups the directory endpoints. It is reached as Client.Directory and is valid only when obtained from a Client built by NewClient.

func (*DirectoryNamespace) ActivelyTrading

func (n *DirectoryNamespace) ActivelyTrading(ctx context.Context) ([]ActivelyTradingSymbol, error)

ActivelyTrading lists worldwide actively trading companies and instruments.

GET actively-trading-list

func (*DirectoryNamespace) AvailableCountries

func (n *DirectoryNamespace) AvailableCountries(ctx context.Context) ([]AvailableCountry, error)

AvailableCountries lists the provider's available countries.

GET available-countries

func (*DirectoryNamespace) AvailableExchanges

AvailableExchanges lists supported worldwide stock exchanges.

GET available-exchanges?extended=

func (*DirectoryNamespace) AvailableIndustries

func (n *DirectoryNamespace) AvailableIndustries(ctx context.Context) ([]AvailableIndustry, error)

AvailableIndustries lists the provider's available industries.

GET available-industries

func (*DirectoryNamespace) AvailableSectors

func (n *DirectoryNamespace) AvailableSectors(ctx context.Context) ([]AvailableSector, error)

AvailableSectors lists the provider's available sectors.

GET available-sectors

func (*DirectoryNamespace) CIKList added in v0.12.0

CIKList lists US SEC entities with optional provider pagination.

GET cik-list?page=&limit=

func (*DirectoryNamespace) CompanySymbols

func (n *DirectoryNamespace) CompanySymbols(ctx context.Context) ([]CompanySymbol, error)

CompanySymbols lists worldwide company and instrument symbols.

GET stock-list

func (*DirectoryNamespace) ETFSymbols added in v0.12.0

func (n *DirectoryNamespace) ETFSymbols(ctx context.Context) ([]ETFSymbol, error)

ETFSymbols lists worldwide exchange-traded fund symbols.

GET etf-list

func (*DirectoryNamespace) EarningsTranscriptList

func (n *DirectoryNamespace) EarningsTranscriptList(ctx context.Context) ([]EarningsTranscriptAvailability, error)

EarningsTranscriptList lists US companies with their available earnings-transcript counts.

GET earnings-transcript-list

func (*DirectoryNamespace) FinancialStatementSymbols

func (n *DirectoryNamespace) FinancialStatementSymbols(ctx context.Context) ([]FinancialStatementSymbol, error)

FinancialStatementSymbols lists worldwide companies with financial statements available.

GET financial-statement-symbol-list

func (*DirectoryNamespace) SymbolChanges

SymbolChanges lists US symbol changes without interpreting the provider's `invalid` flag.

GET symbol-change?invalid=&limit=

type DividendEvent

type DividendEvent struct {
	Symbol          string  `json:"symbol"`
	Date            Date    `json:"date"`
	RecordDate      Date    `json:"recordDate"`
	PaymentDate     Date    `json:"paymentDate"`
	DeclarationDate *Date   `json:"declarationDate"`
	AdjDividend     float64 `json:"adjDividend"`
	Dividend        float64 `json:"dividend"`
	Yield           float64 `json:"yield"`
	Frequency       string  `json:"frequency"`
}

DividendEvent is one company or market-wide dividend event.

func (*DividendEvent) UnmarshalJSONFrom

func (m *DividendEvent) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type DividendsCalendarQuery

type DividendsCalendarQuery struct {
	// contains filtered or unexported fields
}

DividendsCalendarQuery holds the query parameters of the endpoints that take it: NewDividendsCalendarQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewDividendsCalendarQuery

func NewDividendsCalendarQuery() DividendsCalendarQuery

NewDividendsCalendarQuery creates the query from its required arguments.

func (DividendsCalendarQuery) From

func (q DividendsCalendarQuery) From() *Date

From returns the optional from parameter, or nil when it is unset.

func (DividendsCalendarQuery) Page

func (q DividendsCalendarQuery) Page() *uint32

Page returns the optional page parameter, or nil when it is unset.

func (DividendsCalendarQuery) To

func (q DividendsCalendarQuery) To() *Date

To returns the optional to parameter, or nil when it is unset.

func (DividendsCalendarQuery) WithFrom

WithFrom sets the optional from parameter and returns the updated query.

func (DividendsCalendarQuery) WithPage

WithPage sets the optional page parameter and returns the updated query.

func (DividendsCalendarQuery) WithTo

WithTo sets the optional to parameter and returns the updated query.

type DividendsQuery

type DividendsQuery struct {
	// contains filtered or unexported fields
}

DividendsQuery holds the query parameters of the endpoints that take it: NewDividendsQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewDividendsQuery

func NewDividendsQuery(symbol string) DividendsQuery

NewDividendsQuery creates the query from its required arguments.

func (DividendsQuery) Limit

func (q DividendsQuery) Limit() *uint32

Limit returns the optional limit parameter, or nil when it is unset.

func (DividendsQuery) Symbol

func (q DividendsQuery) Symbol() string

Symbol returns the symbol argument as given.

func (DividendsQuery) WithLimit

func (q DividendsQuery) WithLimit(limit uint32) DividendsQuery

WithLimit sets the optional limit parameter and returns the updated query.

type DoubleExponentialMovingAverageBar

type DoubleExponentialMovingAverageBar struct {
	Date   DateTime `json:"date"`
	Open   float64  `json:"open"`
	High   float64  `json:"high"`
	Low    float64  `json:"low"`
	Close  float64  `json:"close"`
	Volume float64  `json:"volume"`
	Dema   float64  `json:"dema"`
}

DoubleExponentialMovingAverageBar is a response model of the technical_indicators domain.

func (*DoubleExponentialMovingAverageBar) UnmarshalJSONFrom

func (m *DoubleExponentialMovingAverageBar) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type ESGBenchmark added in v0.12.0

type ESGBenchmark struct {
	FiscalYear         uint32  `json:"fiscalYear"`
	Sector             string  `json:"sector"`
	EnvironmentalScore float64 `json:"environmentalScore"`
	SocialScore        float64 `json:"socialScore"`
	GovernanceScore    float64 `json:"governanceScore"`
	ESGScore           float64 `json:"ESGScore"`
}

ESGBenchmark is one sector ESG benchmark for a fiscal year.

func (*ESGBenchmark) UnmarshalJSONFrom added in v0.12.0

func (m *ESGBenchmark) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type ESGBenchmarkQuery added in v0.12.0

type ESGBenchmarkQuery struct {
	// contains filtered or unexported fields
}

ESGBenchmarkQuery holds the query parameters of the endpoints that take it: NewESGBenchmarkQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewESGBenchmarkQuery added in v0.12.0

func NewESGBenchmarkQuery() ESGBenchmarkQuery

NewESGBenchmarkQuery creates the query from its required arguments.

func (ESGBenchmarkQuery) WithYear added in v0.12.0

func (q ESGBenchmarkQuery) WithYear(year string) ESGBenchmarkQuery

WithYear sets the optional year parameter and returns the updated query.

func (ESGBenchmarkQuery) Year added in v0.12.0

func (q ESGBenchmarkQuery) Year() *string

Year returns the optional year parameter, or nil when it is unset.

type ESGDisclosure added in v0.12.0

type ESGDisclosure struct {
	Date               Date    `json:"date"`
	AcceptedDate       Date    `json:"acceptedDate"`
	Symbol             string  `json:"symbol"`
	CIK                string  `json:"cik"`
	CompanyName        string  `json:"companyName"`
	FormType           string  `json:"formType"`
	EnvironmentalScore float64 `json:"environmentalScore"`
	SocialScore        float64 `json:"socialScore"`
	GovernanceScore    float64 `json:"governanceScore"`
	ESGScore           float64 `json:"ESGScore"`
	URL                string  `json:"url"`
}

ESGDisclosure is one company ESG disclosure filing and its component scores.

func (*ESGDisclosure) UnmarshalJSONFrom added in v0.12.0

func (m *ESGDisclosure) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type ESGNamespace added in v0.12.0

type ESGNamespace struct {
	// contains filtered or unexported fields
}

ESGNamespace groups the esg endpoints. It is reached as Client.ESG and is valid only when obtained from a Client built by NewClient.

func (*ESGNamespace) Benchmark added in v0.12.0

func (n *ESGNamespace) Benchmark(ctx context.Context, q ESGBenchmarkQuery) ([]ESGBenchmark, error)

Benchmark retrieves sector ESG benchmarks, optionally for one provider year string.

GET esg-benchmark?year=

func (*ESGNamespace) Disclosures added in v0.12.0

func (n *ESGNamespace) Disclosures(ctx context.Context, q ESGSymbolQuery) ([]ESGDisclosure, error)

Disclosures retrieves ESG disclosure filings for one company.

GET esg-disclosures?symbol=

func (*ESGNamespace) Ratings added in v0.12.0

func (n *ESGNamespace) Ratings(ctx context.Context, q ESGSymbolQuery) ([]ESGRating, error)

Ratings retrieves ESG ratings for one company.

GET esg-ratings?symbol=

type ESGRating added in v0.12.0

type ESGRating struct {
	Symbol        string `json:"symbol"`
	CIK           string `json:"cik"`
	CompanyName   string `json:"companyName"`
	Industry      string `json:"industry"`
	FiscalYear    uint32 `json:"fiscalYear"`
	ESGRiskRating string `json:"ESGRiskRating"`
	IndustryRank  string `json:"industryRank"`
}

ESGRating is one company's ESG risk rating for a fiscal year.

func (*ESGRating) UnmarshalJSONFrom added in v0.12.0

func (m *ESGRating) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type ESGSymbolQuery added in v0.12.0

type ESGSymbolQuery struct {
	// contains filtered or unexported fields
}

ESGSymbolQuery holds the query parameters of the endpoints that take it: NewESGSymbolQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewESGSymbolQuery added in v0.12.0

func NewESGSymbolQuery(symbol string) ESGSymbolQuery

NewESGSymbolQuery creates the query from its required arguments.

func (ESGSymbolQuery) Symbol added in v0.12.0

func (q ESGSymbolQuery) Symbol() string

Symbol returns the symbol argument as given.

type ETFAssetExposure added in v0.12.0

type ETFAssetExposure struct {
	Symbol           string  `json:"symbol"`
	Asset            string  `json:"asset"`
	SharesNumber     float64 `json:"sharesNumber"`
	WeightPercentage float64 `json:"weightPercentage"`
	MarketValue      float64 `json:"marketValue"`
}

ETFAssetExposure is one ETF's exposure to a requested asset.

func (*ETFAssetExposure) UnmarshalJSONFrom added in v0.12.0

func (m *ETFAssetExposure) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type ETFAssetExposureQuery added in v0.12.0

type ETFAssetExposureQuery struct {
	// contains filtered or unexported fields
}

ETFAssetExposureQuery holds the query parameters of the endpoints that take it: NewETFAssetExposureQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewETFAssetExposureQuery added in v0.12.0

func NewETFAssetExposureQuery(symbol string) ETFAssetExposureQuery

NewETFAssetExposureQuery creates the query from its required arguments.

func (ETFAssetExposureQuery) Symbol added in v0.12.0

func (q ETFAssetExposureQuery) Symbol() string

Symbol returns the symbol argument as given.

type ETFCountryWeighting added in v0.12.0

type ETFCountryWeighting struct {
	Country          string `json:"country"`
	WeightPercentage string `json:"weightPercentage"`
}

ETFCountryWeighting is one country allocation reported as an exact percent-bearing string.

func (*ETFCountryWeighting) UnmarshalJSONFrom added in v0.12.0

func (m *ETFCountryWeighting) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type ETFCountryWeightingsQuery added in v0.12.0

type ETFCountryWeightingsQuery struct {
	// contains filtered or unexported fields
}

ETFCountryWeightingsQuery holds the query parameters of the endpoints that take it: NewETFCountryWeightingsQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewETFCountryWeightingsQuery added in v0.12.0

func NewETFCountryWeightingsQuery(symbol string) ETFCountryWeightingsQuery

NewETFCountryWeightingsQuery creates the query from its required arguments.

func (ETFCountryWeightingsQuery) Symbol added in v0.12.0

func (q ETFCountryWeightingsQuery) Symbol() string

Symbol returns the symbol argument as given.

type ETFFundHolding added in v0.12.0

type ETFFundHolding struct {
	Symbol           string   `json:"symbol"`
	Asset            string   `json:"asset"`
	Name             string   `json:"name"`
	ISIN             string   `json:"isin"`
	SecurityCUSIP    string   `json:"securityCusip"`
	SharesNumber     float64  `json:"sharesNumber"`
	WeightPercentage float64  `json:"weightPercentage"`
	MarketValue      float64  `json:"marketValue"`
	UpdatedAt        DateTime `json:"updatedAt"`
}

ETFFundHolding is one asset held by an ETF or mutual fund.

func (*ETFFundHolding) UnmarshalJSONFrom added in v0.12.0

func (m *ETFFundHolding) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type ETFFundInfo added in v0.12.0

type ETFFundInfo struct {
	Symbol                string              `json:"symbol"`
	Name                  string              `json:"name"`
	Description           string              `json:"description"`
	ISIN                  string              `json:"isin"`
	AssetClass            string              `json:"assetClass"`
	SecurityCUSIP         string              `json:"securityCusip"`
	Domicile              string              `json:"domicile"`
	Website               string              `json:"website"`
	ETFCompany            string              `json:"etfCompany"`
	ExpenseRatio          float64             `json:"expenseRatio"`
	AssetsUnderManagement float64             `json:"assetsUnderManagement"`
	AvgVolume             float64             `json:"avgVolume"`
	InceptionDate         Date                `json:"inceptionDate"`
	Nav                   float64             `json:"nav"`
	NavCurrency           string              `json:"navCurrency"`
	HoldingsCount         uint64              `json:"holdingsCount"`
	IsActivelyTrading     bool                `json:"isActivelyTrading"`
	UpdatedAt             string              `json:"updatedAt"`
	SectorsList           []ETFSectorExposure `json:"sectorsList"`
}

ETFFundInfo is descriptive, structural, and trading information for an ETF or mutual fund.

func (*ETFFundInfo) UnmarshalJSONFrom added in v0.12.0

func (m *ETFFundInfo) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type ETFHoldingsQuery added in v0.12.0

type ETFHoldingsQuery struct {
	// contains filtered or unexported fields
}

ETFHoldingsQuery holds the query parameters of the endpoints that take it: NewETFHoldingsQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewETFHoldingsQuery added in v0.12.0

func NewETFHoldingsQuery(symbol string) ETFHoldingsQuery

NewETFHoldingsQuery creates the query from its required arguments.

func (ETFHoldingsQuery) Symbol added in v0.12.0

func (q ETFHoldingsQuery) Symbol() string

Symbol returns the symbol argument as given.

type ETFInfoQuery added in v0.12.0

type ETFInfoQuery struct {
	// contains filtered or unexported fields
}

ETFInfoQuery holds the query parameters of the endpoints that take it: NewETFInfoQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewETFInfoQuery added in v0.12.0

func NewETFInfoQuery(symbol string) ETFInfoQuery

NewETFInfoQuery creates the query from its required arguments.

func (ETFInfoQuery) Symbol added in v0.12.0

func (q ETFInfoQuery) Symbol() string

Symbol returns the symbol argument as given.

type ETFSectorExposure added in v0.12.0

type ETFSectorExposure struct {
	Industry string  `json:"industry"`
	Exposure float64 `json:"exposure"`
}

ETFSectorExposure is one sector exposure nested within a fund-information row.

func (*ETFSectorExposure) UnmarshalJSONFrom added in v0.12.0

func (m *ETFSectorExposure) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type ETFSectorWeighting added in v0.12.0

type ETFSectorWeighting struct {
	Symbol           string  `json:"symbol"`
	Sector           string  `json:"sector"`
	WeightPercentage float64 `json:"weightPercentage"`
}

ETFSectorWeighting is one numeric sector allocation for an ETF or mutual fund.

func (*ETFSectorWeighting) UnmarshalJSONFrom added in v0.12.0

func (m *ETFSectorWeighting) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type ETFSectorWeightingsQuery added in v0.12.0

type ETFSectorWeightingsQuery struct {
	// contains filtered or unexported fields
}

ETFSectorWeightingsQuery holds the query parameters of the endpoints that take it: NewETFSectorWeightingsQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewETFSectorWeightingsQuery added in v0.12.0

func NewETFSectorWeightingsQuery(symbol string) ETFSectorWeightingsQuery

NewETFSectorWeightingsQuery creates the query from its required arguments.

func (ETFSectorWeightingsQuery) Symbol added in v0.12.0

func (q ETFSectorWeightingsQuery) Symbol() string

Symbol returns the symbol argument as given.

type ETFSymbol added in v0.12.0

type ETFSymbol struct {
	Symbol string `json:"symbol"`
	Name   string `json:"name"`
}

ETFSymbol is one worldwide exchange-traded fund in the ETF symbol directory.

func (*ETFSymbol) UnmarshalJSONFrom added in v0.12.0

func (m *ETFSymbol) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type EarningsCalendarQuery

type EarningsCalendarQuery struct {
	// contains filtered or unexported fields
}

EarningsCalendarQuery holds the query parameters of the endpoints that take it: NewEarningsCalendarQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewEarningsCalendarQuery

func NewEarningsCalendarQuery() EarningsCalendarQuery

NewEarningsCalendarQuery creates the query from its required arguments.

func (EarningsCalendarQuery) From

func (q EarningsCalendarQuery) From() *Date

From returns the optional from parameter, or nil when it is unset.

func (EarningsCalendarQuery) IncludeReportTimes

func (q EarningsCalendarQuery) IncludeReportTimes() *bool

IncludeReportTimes returns the optional include_report_times parameter, or nil when it is unset.

func (EarningsCalendarQuery) Page

func (q EarningsCalendarQuery) Page() *uint32

Page returns the optional page parameter, or nil when it is unset.

func (EarningsCalendarQuery) To

func (q EarningsCalendarQuery) To() *Date

To returns the optional to parameter, or nil when it is unset.

func (EarningsCalendarQuery) WithFrom

WithFrom sets the optional from parameter and returns the updated query.

func (EarningsCalendarQuery) WithIncludeReportTimes

func (q EarningsCalendarQuery) WithIncludeReportTimes(includeReportTimes bool) EarningsCalendarQuery

WithIncludeReportTimes sets the optional include_report_times parameter and returns the updated query.

func (EarningsCalendarQuery) WithPage

WithPage sets the optional page parameter and returns the updated query.

func (EarningsCalendarQuery) WithTo

WithTo sets the optional to parameter and returns the updated query.

type EarningsEvent

type EarningsEvent struct {
	Symbol           string   `json:"symbol"`
	Date             Date     `json:"date"`
	EPSActual        *float64 `json:"epsActual"`
	EPSEstimated     float64  `json:"epsEstimated"`
	RevenueActual    *float64 `json:"revenueActual"`
	RevenueEstimated float64  `json:"revenueEstimated"`
	LastUpdated      Date     `json:"lastUpdated"`
}

EarningsEvent is one company or market-wide earnings event.

func (*EarningsEvent) UnmarshalJSONFrom

func (m *EarningsEvent) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type EarningsQuery

type EarningsQuery struct {
	// contains filtered or unexported fields
}

EarningsQuery holds the query parameters of the endpoints that take it: NewEarningsQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewEarningsQuery

func NewEarningsQuery(symbol string) EarningsQuery

NewEarningsQuery creates the query from its required arguments.

func (EarningsQuery) IncludeReportTimes

func (q EarningsQuery) IncludeReportTimes() *bool

IncludeReportTimes returns the optional include_report_times parameter, or nil when it is unset.

func (EarningsQuery) Limit

func (q EarningsQuery) Limit() *uint32

Limit returns the optional limit parameter, or nil when it is unset.

func (EarningsQuery) Symbol

func (q EarningsQuery) Symbol() string

Symbol returns the symbol argument as given.

func (EarningsQuery) WithIncludeReportTimes

func (q EarningsQuery) WithIncludeReportTimes(includeReportTimes bool) EarningsQuery

WithIncludeReportTimes sets the optional include_report_times parameter and returns the updated query.

func (EarningsQuery) WithLimit

func (q EarningsQuery) WithLimit(limit uint32) EarningsQuery

WithLimit sets the optional limit parameter and returns the updated query.

type EarningsTranscript

type EarningsTranscript struct {
	Symbol  string `json:"symbol"`
	Period  string `json:"period"`
	Year    uint32 `json:"year"`
	Date    Date   `json:"date"`
	Content string `json:"content"`
}

EarningsTranscript is one complete worldwide earnings-call transcript.

func (*EarningsTranscript) UnmarshalJSONFrom

func (m *EarningsTranscript) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type EarningsTranscriptAvailability

type EarningsTranscriptAvailability struct {
	Symbol          string `json:"symbol"`
	CompanyName     string `json:"companyName"`
	NoOfTranscripts string `json:"noOfTranscripts"`
}

EarningsTranscriptAvailability is one US company with the count of available earnings transcripts.

func (*EarningsTranscriptAvailability) UnmarshalJSONFrom

func (m *EarningsTranscriptAvailability) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type EarningsTranscriptDate

type EarningsTranscriptDate struct {
	Quarter    uint8  `json:"quarter"`
	FiscalYear uint32 `json:"fiscalYear"`
	Date       Date   `json:"date"`
}

EarningsTranscriptDate is one available transcript date and its numeric fiscal quarter/year.

func (*EarningsTranscriptDate) UnmarshalJSONFrom

func (m *EarningsTranscriptDate) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type EarningsTranscriptDatesQuery

type EarningsTranscriptDatesQuery struct {
	// contains filtered or unexported fields
}

EarningsTranscriptDatesQuery holds the query parameters of the endpoints that take it: NewEarningsTranscriptDatesQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewEarningsTranscriptDatesQuery

func NewEarningsTranscriptDatesQuery(symbol string) EarningsTranscriptDatesQuery

NewEarningsTranscriptDatesQuery creates the query from its required arguments.

func (EarningsTranscriptDatesQuery) Symbol

Symbol returns the symbol argument as given.

type EarningsTranscriptQuery

type EarningsTranscriptQuery struct {
	// contains filtered or unexported fields
}

EarningsTranscriptQuery holds the query parameters of the endpoints that take it: NewEarningsTranscriptQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewEarningsTranscriptQuery

func NewEarningsTranscriptQuery(symbol string, year uint32, quarter Quarter) EarningsTranscriptQuery

NewEarningsTranscriptQuery creates the query from its required arguments.

func (EarningsTranscriptQuery) Limit

func (q EarningsTranscriptQuery) Limit() *uint32

Limit returns the optional limit parameter, or nil when it is unset.

func (EarningsTranscriptQuery) Quarter

func (q EarningsTranscriptQuery) Quarter() Quarter

Quarter returns the quarter argument as given.

func (EarningsTranscriptQuery) Symbol

func (q EarningsTranscriptQuery) Symbol() string

Symbol returns the symbol argument as given.

func (EarningsTranscriptQuery) WithLimit

WithLimit sets the optional limit parameter and returns the updated query.

func (EarningsTranscriptQuery) Year

Year returns the year argument as given.

type EconomicCalendarEvent

type EconomicCalendarEvent struct {
	Date             DateTime `json:"date"`
	Country          string   `json:"country"`
	Event            string   `json:"event"`
	Currency         string   `json:"currency"`
	Previous         float64  `json:"previous"`
	Estimate         float64  `json:"estimate"`
	Actual           float64  `json:"actual"`
	Change           float64  `json:"change"`
	Impact           string   `json:"impact"`
	ChangePercentage float64  `json:"changePercentage"`
	Unit             string   `json:"unit"`
}

EconomicCalendarEvent is one scheduled economic data release.

func (*EconomicCalendarEvent) UnmarshalJSONFrom

func (m *EconomicCalendarEvent) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type EconomicCalendarQuery

type EconomicCalendarQuery struct {
	// contains filtered or unexported fields
}

EconomicCalendarQuery holds the query parameters of the endpoints that take it: NewEconomicCalendarQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewEconomicCalendarQuery

func NewEconomicCalendarQuery() EconomicCalendarQuery

NewEconomicCalendarQuery creates the query from its required arguments.

func (EconomicCalendarQuery) Country

func (q EconomicCalendarQuery) Country() *string

Country returns the optional country parameter, or nil when it is unset.

func (EconomicCalendarQuery) From

func (q EconomicCalendarQuery) From() *Date

From returns the optional from parameter, or nil when it is unset.

func (EconomicCalendarQuery) To

func (q EconomicCalendarQuery) To() *Date

To returns the optional to parameter, or nil when it is unset.

func (EconomicCalendarQuery) WithCountry

func (q EconomicCalendarQuery) WithCountry(country string) EconomicCalendarQuery

WithCountry sets the optional country parameter and returns the updated query.

func (EconomicCalendarQuery) WithFrom

WithFrom sets the optional from parameter and returns the updated query.

func (EconomicCalendarQuery) WithTo

WithTo sets the optional to parameter and returns the updated query.

type EconomicIndicator

type EconomicIndicator string

EconomicIndicator is the indicator name of the economic-indicators endpoint. The constants carry the 24 documented provider spellings, sent verbatim. Unlike a closed wire enum, the libfmp EconomicIndicator is open: any other non-empty name free of control characters is forwarded as a provider value, so a name the documentation gained later still works.

const (
	EconomicIndicatorGdp                                                      EconomicIndicator = "GDP"
	EconomicIndicatorRealGdp                                                  EconomicIndicator = "realGDP"
	EconomicIndicatorNominalPotentialGdp                                      EconomicIndicator = "nominalPotentialGDP"
	EconomicIndicatorRealGdpPerCapita                                         EconomicIndicator = "realGDPPerCapita"
	EconomicIndicatorFederalFunds                                             EconomicIndicator = "federalFunds"
	EconomicIndicatorCpi                                                      EconomicIndicator = "CPI"
	EconomicIndicatorInflationRate                                            EconomicIndicator = "inflationRate"
	EconomicIndicatorInflation                                                EconomicIndicator = "inflation"
	EconomicIndicatorRetailSales                                              EconomicIndicator = "retailSales"
	EconomicIndicatorConsumerSentiment                                        EconomicIndicator = "consumerSentiment"
	EconomicIndicatorDurableGoods                                             EconomicIndicator = "durableGoods"
	EconomicIndicatorUnemploymentRate                                         EconomicIndicator = "unemploymentRate"
	EconomicIndicatorTotalNonfarmPayroll                                      EconomicIndicator = "totalNonfarmPayroll"
	EconomicIndicatorInitialClaims                                            EconomicIndicator = "initialClaims"
	EconomicIndicatorIndustrialProductionTotalIndex                           EconomicIndicator = "industrialProductionTotalIndex"
	EconomicIndicatorNewPrivatelyOwnedHousingUnitsStartedTotalUnits           EconomicIndicator = "newPrivatelyOwnedHousingUnitsStartedTotalUnits"
	EconomicIndicatorTotalVehicleSales                                        EconomicIndicator = "totalVehicleSales"
	EconomicIndicatorRetailMoneyFunds                                         EconomicIndicator = "retailMoneyFunds"
	EconomicIndicatorSmoothedUSRecessionProbabilities                         EconomicIndicator = "smoothedUSRecessionProbabilities"
	EconomicIndicatorThreeMonthOrNinetyDayRatesAndYieldsCertificatesOfDeposit EconomicIndicator = "3MonthOr90DayRatesAndYieldsCertificatesOfDeposit"
	EconomicIndicatorCommercialBankInterestRateOnCreditCardPlansAllAccounts   EconomicIndicator = "commercialBankInterestRateOnCreditCardPlansAllAccounts"
	EconomicIndicatorThirtyYearFixedRateMortgageAverage                       EconomicIndicator = "30YearFixedRateMortgageAverage"
	EconomicIndicatorFifteenYearFixedRateMortgageAverage                      EconomicIndicator = "15YearFixedRateMortgageAverage"
	EconomicIndicatorTradeBalanceGoodsAndServices                             EconomicIndicator = "tradeBalanceGoodsAndServices"
)

The documented EconomicIndicator wire values, in the order the libfmp EconomicIndicator::DOCUMENTED table lists them.

func DocumentedEconomicIndicators

func DocumentedEconomicIndicators() []EconomicIndicator

DocumentedEconomicIndicators lists the 24 documented indicator names, as the libfmp EconomicIndicator::DOCUMENTED table does. Each call returns a fresh copy, so modifying it never changes a later result.

type EconomicIndicatorObservation

type EconomicIndicatorObservation struct {
	Name  string  `json:"name"`
	Date  Date    `json:"date"`
	Value float64 `json:"value"`
}

EconomicIndicatorObservation is one observation of a documented or validated open economic indicator.

func (*EconomicIndicatorObservation) UnmarshalJSONFrom

func (m *EconomicIndicatorObservation) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type EconomicIndicatorsQuery

type EconomicIndicatorsQuery struct {
	// contains filtered or unexported fields
}

EconomicIndicatorsQuery holds the query parameters of the endpoints that take it: NewEconomicIndicatorsQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewEconomicIndicatorsQuery

func NewEconomicIndicatorsQuery(name EconomicIndicator) EconomicIndicatorsQuery

NewEconomicIndicatorsQuery creates the query from its required arguments.

func (EconomicIndicatorsQuery) From

func (q EconomicIndicatorsQuery) From() *Date

From returns the optional from parameter, or nil when it is unset.

func (EconomicIndicatorsQuery) Name

Name returns the name argument as given.

func (EconomicIndicatorsQuery) To

func (q EconomicIndicatorsQuery) To() *Date

To returns the optional to parameter, or nil when it is unset.

func (EconomicIndicatorsQuery) WithFrom

WithFrom sets the optional from parameter and returns the updated query.

func (EconomicIndicatorsQuery) WithTo

WithTo sets the optional to parameter and returns the updated query.

type EconomicsNamespace

type EconomicsNamespace struct {
	// contains filtered or unexported fields
}

EconomicsNamespace groups the economics endpoints. It is reached as Client.Economics and is valid only when obtained from a Client built by NewClient.

func (*EconomicsNamespace) Calendar

Calendar retrieves economic-calendar events.

GET economic-calendar?country=&from=&to=

func (*EconomicsNamespace) Indicators

Indicators retrieves observations for one economic indicator.

GET economic-indicators?name=&from=&to=

func (*EconomicsNamespace) MarketRiskPremium

func (n *EconomicsNamespace) MarketRiskPremium(ctx context.Context) ([]MarketRiskPremium, error)

MarketRiskPremium retrieves the provider's queryless country risk-premium rows.

GET market-risk-premium

func (*EconomicsNamespace) TreasuryRates

TreasuryRates retrieves Treasury-rate observations.

GET treasury-rates?from=&to=

type EmployeeCount

type EmployeeCount struct {
	Symbol         string   `json:"symbol"`
	CIK            string   `json:"cik"`
	AcceptanceTime DateTime `json:"acceptanceTime"`
	PeriodOfReport Date     `json:"periodOfReport"`
	CompanyName    string   `json:"companyName"`
	FormType       string   `json:"formType"`
	FilingDate     Date     `json:"filingDate"`
	EmployeeCount  uint64   `json:"employeeCount"`
	Source         string   `json:"source"`
}

EmployeeCount is one current or historical US employee-count filing.

func (*EmployeeCount) UnmarshalJSONFrom

func (m *EmployeeCount) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type EmployeeCountQuery

type EmployeeCountQuery struct {
	// contains filtered or unexported fields
}

EmployeeCountQuery holds the query parameters of the endpoints that take it: NewEmployeeCountQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewEmployeeCountQuery

func NewEmployeeCountQuery(symbol string) EmployeeCountQuery

NewEmployeeCountQuery creates the query from its required arguments.

func (EmployeeCountQuery) Limit

func (q EmployeeCountQuery) Limit() *uint32

Limit returns the optional limit parameter, or nil when it is unset.

func (EmployeeCountQuery) Symbol

func (q EmployeeCountQuery) Symbol() string

Symbol returns the symbol argument as given.

func (EmployeeCountQuery) WithLimit

func (q EmployeeCountQuery) WithLimit(limit uint32) EmployeeCountQuery

WithLimit sets the optional limit parameter and returns the updated query.

type EndpointBounds

type EndpointBounds struct {
	Limit         *uint32
	ResponseRows  *uint32
	Page          *uint32
	DateRangeDays *uint32
}

EndpointBounds holds the inclusive maxima documented for one endpoint. It mirrors the Rust EndpointBounds: each member is nil when the documentation states no maximum. The bounds are advisory; the client never enforces them.

func (EndpointBounds) String

func (b EndpointBounds) String() string

String returns a short label that is safe to log.

type EndpointMetadata

type EndpointMetadata struct {
	Geography       GeographicAvailability
	Access          AccessRequirement
	ConditionalPlan *ConditionalPlanRequirement
	Realtime        *RealtimeAccess
	Bounds          EndpointBounds
}

EndpointMetadata is the advisory documentation metadata of one endpoint method, mirroring the Rust EndpointMetadata. The zero value is what EndpointMetadata::new() produces on the Rust side: every member unspecified, no conditional plan, no realtime caveats, no bounds. The client never validates a request against it; callers read it to pick endpoints and size requests. Look one up with EndpointMetadataFor or EndpointMetadataByID.

func EndpointMetadataFor

func EndpointMetadataFor(method string) (EndpointMetadata, bool)

EndpointMetadataFor returns the advisory metadata of one endpoint method, keyed by its Go call path without the client: "Quote.Full", "Statements.Growth.Income". It reports false, with the zero value, for a method whose descriptor attaches no metadata and for an unknown key. The value is a copy: mutating it does not change later lookups. The client never validates a request against it.

func (EndpointMetadata) String

func (m EndpointMetadata) String() string

String returns a one-line summary that is safe to log.

type EndpointMethodMetadata added in v0.12.0

type EndpointMethodMetadata struct {
	Method   string
	Metadata EndpointMetadata
}

EndpointMethodMetadata is the metadata of one method that sends a given endpoint id. Method is the EndpointMetadataFor key of that method.

func EndpointMetadataByID added in v0.12.0

func EndpointMetadataByID(id string) []EndpointMethodMetadata

EndpointMetadataByID returns the metadata of every generated method that sends the endpoint id carried by Error.Endpoint ("quote-short"), one entry per method whose descriptor attaches metadata, sorted by Method. Several methods can share one id through helper reuse and carry different metadata (the id "quote" serves five namespaces with different geography), so the result is never merged: callers that know which method they called pick its entry by Method, and callers that do not must treat a result with more than one distinct Metadata as ambiguous. A method that sends the id but attaches no metadata has no entry. It returns nil for an unknown id and for an id none of whose methods attaches metadata. Every value is a copy.

type EnterpriseValue

type EnterpriseValue struct {
	Symbol                      string  `json:"symbol"`
	Date                        Date    `json:"date"`
	StockPrice                  float64 `json:"stockPrice"`
	NumberOfShares              float64 `json:"numberOfShares"`
	MarketCapitalization        float64 `json:"marketCapitalization"`
	MinusCashAndCashEquivalents float64 `json:"minusCashAndCashEquivalents"`
	AddTotalDebt                float64 `json:"addTotalDebt"`
	EnterpriseValue             float64 `json:"enterpriseValue"`
}

EnterpriseValue is one historical enterprise-value calculation.

func (*EnterpriseValue) UnmarshalJSONFrom

func (m *EnterpriseValue) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type EnterpriseValuesQuery

type EnterpriseValuesQuery struct {
	// contains filtered or unexported fields
}

EnterpriseValuesQuery holds the query parameters of the endpoints that take it: NewEnterpriseValuesQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewEnterpriseValuesQuery

func NewEnterpriseValuesQuery(symbol string) EnterpriseValuesQuery

NewEnterpriseValuesQuery creates the query from its required arguments.

func (EnterpriseValuesQuery) Limit

func (q EnterpriseValuesQuery) Limit() *uint32

Limit returns the optional limit parameter, or nil when it is unset.

func (EnterpriseValuesQuery) Period

Period returns the optional period parameter, or nil when it is unset.

func (EnterpriseValuesQuery) Symbol

func (q EnterpriseValuesQuery) Symbol() string

Symbol returns the symbol argument as given.

func (EnterpriseValuesQuery) WithLimit

WithLimit sets the optional limit parameter and returns the updated query.

func (EnterpriseValuesQuery) WithPeriod

WithPeriod sets the optional period parameter and returns the updated query.

type Error

type Error struct {
	Category          ErrorCategory
	Message           string
	Endpoint          string
	Status            int
	Body              *SafeBody
	ConfigurationKind ConfigurationKind
	Path              string
	DecodeKind        DecodeKind
	// contains filtered or unexported fields
}

Error is the stable error value returned by every client operation.

Endpoint is a logical endpoint id such as "quote-short", never a URL. Status is zero when no provider status applies. Body is nil unless a provider body was retained; it is always redacted and capped.

Path and DecodeKind locate a JSON decode failure. Path is the RFC 6901 JSON pointer of the offending member, such as "/37/beta", and names array indexes and member names only, never a member value. Path is "" for a failure at the document root and on every non-decode error.

Example

ExampleError matches a client failure with errors.As and reads its category, endpoint id, and provider status. The server rejects the request with a 401 whose body echoes the credential it received; the SDK redacts the retained body, so the error text never contains the key.

package main

import (
	"context"
	"errors"
	"fmt"
	"net/http"
	"net/http/httptest"
	"strings"

	fmp "github.com/bitbrew-dev/libfmp/sdk/go"
)

func main() {
	// key is a placeholder credential, never a real one. It is declared here
	// so the example stays self-contained on pkg.go.dev.
	const key = "example-key"

	server := httptest.NewTLSServer(http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) {
		w.Header().Set("Content-Type", "application/json")
		w.WriteHeader(http.StatusUnauthorized)
		_, _ = fmt.Fprintf(w, `{"Error Message":"Invalid API KEY: %s"}`, r.Header.Get("apikey"))
	}))
	defer server.Close()

	client, err := fmp.NewClient(
		fmp.WithBaseURL(server.URL),
		fmp.WithHTTPClient(server.Client()),
		fmp.WithAuthentication(fmp.FMPHeader(key)),
	)
	if err != nil {
		fmt.Println("configuration rejected:", err)
		return
	}

	_, err = client.Quote.Short(context.Background(), fmp.NewQuoteShortQuery("AAPL"))
	var fmpErr *fmp.Error
	if !errors.As(err, &fmpErr) {
		fmt.Println("not an *fmp.Error:", err)
		return
	}
	if strings.Contains(fmpErr.Error(), key) {
		fmt.Println("the error text leaked the credential")
		return
	}

	fmt.Println("category:", fmpErr.Category)
	fmt.Println("endpoint:", fmpErr.Endpoint)
	fmt.Println("status:", fmpErr.Status)
	fmt.Println("error:", fmpErr)
}
Output:
category: status
endpoint: quote-short
status: 401
error: provider returned HTTP status 401 (endpoint: quote-short): {"Error Message":"Invalid API KEY: [REDACTED]"}

func (*Error) Error

func (e *Error) Error() string

Error formats the message, the decode kind and path, the endpoint id, and the safe body, in that order.

func (*Error) Unwrap

func (e *Error) Unwrap() error

Unwrap returns the redacted cause, when one was retained.

type ErrorCategory

type ErrorCategory int

ErrorCategory is the broad, stable classification shared with the Rust and Python SDKs.

const (
	// CategoryValidation reports an input that failed local validation.
	CategoryValidation ErrorCategory = iota
	// CategoryConfiguration reports invalid client or transport configuration.
	CategoryConfiguration
	// CategoryTransport reports a request the transport could not complete.
	CategoryTransport
	// CategoryStatus reports a non-success HTTP status from the provider.
	CategoryStatus
	// CategoryDecode reports a successful response that could not be decoded.
	CategoryDecode
)

func (ErrorCategory) String

func (c ErrorCategory) String() string

String returns the stable lowercase value exposed to language bindings.

type ExchangeHoliday

type ExchangeHoliday struct {
	Exchange     string          `json:"exchange"`
	Date         Date            `json:"date"`
	Name         string          `json:"name"`
	IsClosed     bool            `json:"isClosed"`
	AdjOpenTime  *jsontext.Value `json:"adjOpenTime"`
	AdjCloseTime *jsontext.Value `json:"adjCloseTime"`
}

ExchangeHoliday is one holiday or non-trading day for an exchange.

func (*ExchangeHoliday) UnmarshalJSONFrom

func (m *ExchangeHoliday) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type ExchangeMarketHours

type ExchangeMarketHours struct {
	Exchange     string `json:"exchange"`
	Name         string `json:"name"`
	OpeningHour  string `json:"openingHour"`
	ClosingHour  string `json:"closingHour"`
	Timezone     string `json:"timezone"`
	IsMarketOpen bool   `json:"isMarketOpen"`
}

ExchangeMarketHours is trading hours and current status for one exchange.

func (*ExchangeMarketHours) UnmarshalJSONFrom

func (m *ExchangeMarketHours) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type ExchangeMarketHoursQuery

type ExchangeMarketHoursQuery struct {
	// contains filtered or unexported fields
}

ExchangeMarketHoursQuery holds the query parameters of the endpoints that take it: NewExchangeMarketHoursQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewExchangeMarketHoursQuery

func NewExchangeMarketHoursQuery(exchange string) ExchangeMarketHoursQuery

NewExchangeMarketHoursQuery creates the query from its required arguments.

func (ExchangeMarketHoursQuery) Exchange

func (q ExchangeMarketHoursQuery) Exchange() string

Exchange returns the exchange argument as given.

func (ExchangeMarketHoursQuery) Timestamp

func (q ExchangeMarketHoursQuery) Timestamp() *string

Timestamp returns the optional timestamp parameter, or nil when it is unset.

func (ExchangeMarketHoursQuery) WithTimestamp

func (q ExchangeMarketHoursQuery) WithTimestamp(timestamp string) ExchangeMarketHoursQuery

WithTimestamp sets the optional timestamp parameter and returns the updated query.

type ExchangeQuotesQuery

type ExchangeQuotesQuery struct {
	// contains filtered or unexported fields
}

ExchangeQuotesQuery holds the query parameters of the endpoints that take it: NewExchangeQuotesQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewExchangeQuotesQuery

func NewExchangeQuotesQuery(exchange string) ExchangeQuotesQuery

NewExchangeQuotesQuery creates the query from its required arguments.

func (ExchangeQuotesQuery) Exchange

func (q ExchangeQuotesQuery) Exchange() string

Exchange returns the exchange argument as given.

type ExchangeVariant

type ExchangeVariant struct {
	Symbol            string  `json:"symbol"`
	Price             float64 `json:"price"`
	Beta              float64 `json:"beta"`
	VolAvg            float64 `json:"volAvg"`
	MarketCap         float64 `json:"mktCap"`
	LastDiv           float64 `json:"lastDiv"`
	Range             string  `json:"range"`
	Changes           float64 `json:"changes"`
	CompanyName       string  `json:"companyName"`
	Currency          string  `json:"currency"`
	CIK               string  `json:"cik"`
	ISIN              string  `json:"isin"`
	CUSIP             string  `json:"cusip"`
	Exchange          string  `json:"exchange"`
	ExchangeShortName string  `json:"exchangeShortName"`
	Industry          string  `json:"industry"`
	Website           string  `json:"website"`
	Description       string  `json:"description"`
	Ceo               string  `json:"ceo"`
	Sector            string  `json:"sector"`
	Country           string  `json:"country"`
	FullTimeEmployees string  `json:"fullTimeEmployees"`
	Phone             string  `json:"phone"`
	Address           string  `json:"address"`
	City              string  `json:"city"`
	State             string  `json:"state"`
	Zip               string  `json:"zip"`
	DCFDiff           float64 `json:"dcfDiff"`
	DCF               float64 `json:"dcf"`
	Image             string  `json:"image"`
	IPODate           Date    `json:"ipoDate"`
	DefaultImage      bool    `json:"defaultImage"`
	IsETF             bool    `json:"isEtf"`
	IsActivelyTrading bool    `json:"isActivelyTrading"`
	IsAdr             bool    `json:"isAdr"`
	IsFund            bool    `json:"isFund"`
}

ExchangeVariant is one exchange listing returned by exchange-variants search.

func (*ExchangeVariant) UnmarshalJSONFrom

func (m *ExchangeVariant) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type ExchangeVariantsQuery

type ExchangeVariantsQuery struct {
	// contains filtered or unexported fields
}

ExchangeVariantsQuery holds the query parameters of the endpoints that take it: NewExchangeVariantsQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewExchangeVariantsQuery

func NewExchangeVariantsQuery(symbol string) ExchangeVariantsQuery

NewExchangeVariantsQuery creates the query from its required arguments.

func (ExchangeVariantsQuery) Symbol

func (q ExchangeVariantsQuery) Symbol() string

Symbol returns the symbol argument as given.

type ExecutiveCompensation

type ExecutiveCompensation struct {
	CIK                       string   `json:"cik"`
	Symbol                    string   `json:"symbol"`
	CompanyName               string   `json:"companyName"`
	FilingDate                Date     `json:"filingDate"`
	AcceptedDate              DateTime `json:"acceptedDate"`
	NameAndPosition           string   `json:"nameAndPosition"`
	Year                      int64    `json:"year"`
	Salary                    float64  `json:"salary"`
	Bonus                     float64  `json:"bonus"`
	StockAward                float64  `json:"stockAward"`
	OptionAward               float64  `json:"optionAward"`
	IncentivePlanCompensation float64  `json:"incentivePlanCompensation"`
	AllOtherCompensation      float64  `json:"allOtherCompensation"`
	Total                     float64  `json:"total"`
	Link                      string   `json:"link"`
}

ExecutiveCompensation is one executive-compensation filing row for a US company.

func (*ExecutiveCompensation) UnmarshalJSONFrom

func (m *ExecutiveCompensation) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type ExecutiveCompensationBenchmark

type ExecutiveCompensationBenchmark struct {
	IndustryTitle       string  `json:"industryTitle"`
	Year                int64   `json:"year"`
	AverageCompensation float64 `json:"averageCompensation"`
}

ExecutiveCompensationBenchmark is one US industry executive-compensation benchmark.

func (*ExecutiveCompensationBenchmark) UnmarshalJSONFrom

func (m *ExecutiveCompensationBenchmark) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type ExecutiveCompensationBenchmarkQuery

type ExecutiveCompensationBenchmarkQuery struct {
	// contains filtered or unexported fields
}

ExecutiveCompensationBenchmarkQuery holds the query parameters of the endpoints that take it: NewExecutiveCompensationBenchmarkQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewExecutiveCompensationBenchmarkQuery

func NewExecutiveCompensationBenchmarkQuery() ExecutiveCompensationBenchmarkQuery

NewExecutiveCompensationBenchmarkQuery creates the query from its required arguments.

func (ExecutiveCompensationBenchmarkQuery) WithYear

WithYear sets the optional year parameter and returns the updated query.

func (ExecutiveCompensationBenchmarkQuery) Year

Year returns the optional year parameter, or nil when it is unset.

type ExecutiveCompensationQuery

type ExecutiveCompensationQuery struct {
	// contains filtered or unexported fields
}

ExecutiveCompensationQuery holds the query parameters of the endpoints that take it: NewExecutiveCompensationQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewExecutiveCompensationQuery

func NewExecutiveCompensationQuery(symbol string) ExecutiveCompensationQuery

NewExecutiveCompensationQuery creates the query from its required arguments.

func (ExecutiveCompensationQuery) Symbol

Symbol returns the symbol argument as given.

type ExponentialMovingAverageBar

type ExponentialMovingAverageBar struct {
	Date   DateTime `json:"date"`
	Open   float64  `json:"open"`
	High   float64  `json:"high"`
	Low    float64  `json:"low"`
	Close  float64  `json:"close"`
	Volume float64  `json:"volume"`
	Ema    float64  `json:"ema"`
}

ExponentialMovingAverageBar is a response model of the technical_indicators domain.

func (*ExponentialMovingAverageBar) UnmarshalJSONFrom

func (m *ExponentialMovingAverageBar) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type FinancialEstimate

type FinancialEstimate struct {
	Symbol             string  `json:"symbol"`
	Date               Date    `json:"date"`
	RevenueLow         float64 `json:"revenueLow"`
	RevenueHigh        float64 `json:"revenueHigh"`
	RevenueAvg         float64 `json:"revenueAvg"`
	EbitdaLow          float64 `json:"ebitdaLow"`
	EbitdaHigh         float64 `json:"ebitdaHigh"`
	EbitdaAvg          float64 `json:"ebitdaAvg"`
	EbitLow            float64 `json:"ebitLow"`
	EbitHigh           float64 `json:"ebitHigh"`
	EbitAvg            float64 `json:"ebitAvg"`
	NetIncomeLow       float64 `json:"netIncomeLow"`
	NetIncomeHigh      float64 `json:"netIncomeHigh"`
	NetIncomeAvg       float64 `json:"netIncomeAvg"`
	SgaExpenseLow      float64 `json:"sgaExpenseLow"`
	SgaExpenseHigh     float64 `json:"sgaExpenseHigh"`
	SgaExpenseAvg      float64 `json:"sgaExpenseAvg"`
	EPSAvg             float64 `json:"epsAvg"`
	EPSHigh            float64 `json:"epsHigh"`
	EPSLow             float64 `json:"epsLow"`
	NumAnalystsRevenue uint64  `json:"numAnalystsRevenue"`
	NumAnalystsEPS     uint64  `json:"numAnalystsEps"`
}

FinancialEstimate is one dated set of analyst financial estimates.

func (*FinancialEstimate) UnmarshalJSONFrom

func (m *FinancialEstimate) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type FinancialEstimatesQuery

type FinancialEstimatesQuery struct {
	// contains filtered or unexported fields
}

FinancialEstimatesQuery holds the query parameters of the endpoints that take it: NewFinancialEstimatesQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewFinancialEstimatesQuery

func NewFinancialEstimatesQuery(symbol string, period RetrievalFrequency) FinancialEstimatesQuery

NewFinancialEstimatesQuery creates the query from its required arguments.

func (FinancialEstimatesQuery) Limit

func (q FinancialEstimatesQuery) Limit() *uint32

Limit returns the optional limit parameter, or nil when it is unset.

func (FinancialEstimatesQuery) Page

func (q FinancialEstimatesQuery) Page() *uint32

Page returns the optional page parameter, or nil when it is unset.

func (FinancialEstimatesQuery) Period

Period returns the period argument as given.

func (FinancialEstimatesQuery) Symbol

func (q FinancialEstimatesQuery) Symbol() string

Symbol returns the symbol argument as given.

func (FinancialEstimatesQuery) WithLimit

WithLimit sets the optional limit parameter and returns the updated query.

func (FinancialEstimatesQuery) WithPage

WithPage sets the optional page parameter and returns the updated query.

type FinancialRatios

type FinancialRatios struct {
	Symbol                                  string  `json:"symbol"`
	Date                                    Date    `json:"date"`
	FiscalYear                              string  `json:"fiscalYear"`
	Period                                  string  `json:"period"`
	ReportedCurrency                        string  `json:"reportedCurrency"`
	GrossProfitMargin                       float64 `json:"grossProfitMargin"`
	EbitMargin                              float64 `json:"ebitMargin"`
	EbitdaMargin                            float64 `json:"ebitdaMargin"`
	OperatingProfitMargin                   float64 `json:"operatingProfitMargin"`
	PretaxProfitMargin                      float64 `json:"pretaxProfitMargin"`
	ContinuousOperationsProfitMargin        float64 `json:"continuousOperationsProfitMargin"`
	NetProfitMargin                         float64 `json:"netProfitMargin"`
	BottomLineProfitMargin                  float64 `json:"bottomLineProfitMargin"`
	ReceivablesTurnover                     float64 `json:"receivablesTurnover"`
	PayablesTurnover                        float64 `json:"payablesTurnover"`
	InventoryTurnover                       float64 `json:"inventoryTurnover"`
	FixedAssetTurnover                      float64 `json:"fixedAssetTurnover"`
	AssetTurnover                           float64 `json:"assetTurnover"`
	CurrentRatio                            float64 `json:"currentRatio"`
	QuickRatio                              float64 `json:"quickRatio"`
	SolvencyRatio                           float64 `json:"solvencyRatio"`
	CashRatio                               float64 `json:"cashRatio"`
	PriceToEarningsRatio                    float64 `json:"priceToEarningsRatio"`
	PriceToEarningsGrowthRatio              float64 `json:"priceToEarningsGrowthRatio"`
	ForwardPriceToEarningsGrowthRatio       float64 `json:"forwardPriceToEarningsGrowthRatio"`
	PriceToEarningsDilutedRatio             float64 `json:"priceToEarningsDilutedRatio"`
	PriceToEarningsDilutedGrowthRatio       float64 `json:"priceToEarningsDilutedGrowthRatio"`
	PriceToBookRatio                        float64 `json:"priceToBookRatio"`
	PriceToSalesRatio                       float64 `json:"priceToSalesRatio"`
	PriceToFreeCashFlowRatio                float64 `json:"priceToFreeCashFlowRatio"`
	PriceToOperatingCashFlowRatio           float64 `json:"priceToOperatingCashFlowRatio"`
	DebtToAssetsRatio                       float64 `json:"debtToAssetsRatio"`
	DebtToEquityRatio                       float64 `json:"debtToEquityRatio"`
	DebtToCapitalRatio                      float64 `json:"debtToCapitalRatio"`
	LongTermDebtToCapitalRatio              float64 `json:"longTermDebtToCapitalRatio"`
	FinancialLeverageRatio                  float64 `json:"financialLeverageRatio"`
	WorkingCapitalTurnoverRatio             float64 `json:"workingCapitalTurnoverRatio"`
	OperatingCashFlowRatio                  float64 `json:"operatingCashFlowRatio"`
	OperatingCashFlowSalesRatio             float64 `json:"operatingCashFlowSalesRatio"`
	FreeCashFlowOperatingCashFlowRatio      float64 `json:"freeCashFlowOperatingCashFlowRatio"`
	DebtServiceCoverageRatio                float64 `json:"debtServiceCoverageRatio"`
	InterestCoverageRatio                   float64 `json:"interestCoverageRatio"`
	ShortTermOperatingCashFlowCoverageRatio float64 `json:"shortTermOperatingCashFlowCoverageRatio"`
	OperatingCashFlowCoverageRatio          float64 `json:"operatingCashFlowCoverageRatio"`
	CapitalExpenditureCoverageRatio         float64 `json:"capitalExpenditureCoverageRatio"`
	DividendPaidAndCapexCoverageRatio       float64 `json:"dividendPaidAndCapexCoverageRatio"`
	DividendPayoutRatio                     float64 `json:"dividendPayoutRatio"`
	DividendYield                           float64 `json:"dividendYield"`
	DividendYieldPercentage                 float64 `json:"dividendYieldPercentage"`
	RevenuePerShare                         float64 `json:"revenuePerShare"`
	NetIncomePerShare                       float64 `json:"netIncomePerShare"`
	InterestDebtPerShare                    float64 `json:"interestDebtPerShare"`
	CashPerShare                            float64 `json:"cashPerShare"`
	BookValuePerShare                       float64 `json:"bookValuePerShare"`
	TangibleBookValuePerShare               float64 `json:"tangibleBookValuePerShare"`
	ShareholdersEquityPerShare              float64 `json:"shareholdersEquityPerShare"`
	OperatingCashFlowPerShare               float64 `json:"operatingCashFlowPerShare"`
	CapexPerShare                           float64 `json:"capexPerShare"`
	FreeCashFlowPerShare                    float64 `json:"freeCashFlowPerShare"`
	NetIncomePerEbt                         float64 `json:"netIncomePerEBT"`
	EbtPerEbit                              float64 `json:"ebtPerEbit"`
	PriceToFairValue                        float64 `json:"priceToFairValue"`
	DebtToMarketCap                         float64 `json:"debtToMarketCap"`
	EffectiveTaxRate                        float64 `json:"effectiveTaxRate"`
	EnterpriseValueMultiple                 float64 `json:"enterpriseValueMultiple"`
	DividendPerShare                        float64 `json:"dividendPerShare"`
}

FinancialRatios is one historical worldwide financial-ratios row.

func (*FinancialRatios) UnmarshalJSONFrom

func (m *FinancialRatios) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type FinancialRatiosQuery

type FinancialRatiosQuery struct {
	// contains filtered or unexported fields
}

FinancialRatiosQuery holds the query parameters of the endpoints that take it: NewFinancialRatiosQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewFinancialRatiosQuery

func NewFinancialRatiosQuery(symbol string) FinancialRatiosQuery

NewFinancialRatiosQuery creates the query from its required arguments.

func (FinancialRatiosQuery) Limit

func (q FinancialRatiosQuery) Limit() *uint32

Limit returns the optional limit parameter, or nil when it is unset.

func (FinancialRatiosQuery) Period

Period returns the optional period parameter, or nil when it is unset.

func (FinancialRatiosQuery) Symbol

func (q FinancialRatiosQuery) Symbol() string

Symbol returns the symbol argument as given.

func (FinancialRatiosQuery) WithLimit

WithLimit sets the optional limit parameter and returns the updated query.

func (FinancialRatiosQuery) WithPeriod

WithPeriod sets the optional period parameter and returns the updated query.

type FinancialRatiosTTM added in v0.12.0

type FinancialRatiosTTM struct {
	Symbol                                     string  `json:"symbol"`
	GrossProfitMarginTTM                       float64 `json:"grossProfitMarginTTM"`
	EbitMarginTTM                              float64 `json:"ebitMarginTTM"`
	EbitdaMarginTTM                            float64 `json:"ebitdaMarginTTM"`
	OperatingProfitMarginTTM                   float64 `json:"operatingProfitMarginTTM"`
	PretaxProfitMarginTTM                      float64 `json:"pretaxProfitMarginTTM"`
	ContinuousOperationsProfitMarginTTM        float64 `json:"continuousOperationsProfitMarginTTM"`
	NetProfitMarginTTM                         float64 `json:"netProfitMarginTTM"`
	BottomLineProfitMarginTTM                  float64 `json:"bottomLineProfitMarginTTM"`
	ReceivablesTurnoverTTM                     float64 `json:"receivablesTurnoverTTM"`
	PayablesTurnoverTTM                        float64 `json:"payablesTurnoverTTM"`
	InventoryTurnoverTTM                       float64 `json:"inventoryTurnoverTTM"`
	FixedAssetTurnoverTTM                      float64 `json:"fixedAssetTurnoverTTM"`
	AssetTurnoverTTM                           float64 `json:"assetTurnoverTTM"`
	CurrentRatioTTM                            float64 `json:"currentRatioTTM"`
	QuickRatioTTM                              float64 `json:"quickRatioTTM"`
	SolvencyRatioTTM                           float64 `json:"solvencyRatioTTM"`
	CashRatioTTM                               float64 `json:"cashRatioTTM"`
	PriceToEarningsRatioTTM                    float64 `json:"priceToEarningsRatioTTM"`
	PriceToEarningsGrowthRatioTTM              float64 `json:"priceToEarningsGrowthRatioTTM"`
	ForwardPriceToEarningsGrowthRatioTTM       float64 `json:"forwardPriceToEarningsGrowthRatioTTM"`
	PriceToEarningsDilutedRatioTTM             float64 `json:"priceToEarningsDilutedRatioTTM"`
	PriceToEarningsDilutedGrowthRatioTTM       float64 `json:"priceToEarningsDilutedGrowthRatioTTM"`
	PriceToBookRatioTTM                        float64 `json:"priceToBookRatioTTM"`
	PriceToSalesRatioTTM                       float64 `json:"priceToSalesRatioTTM"`
	PriceToFreeCashFlowRatioTTM                float64 `json:"priceToFreeCashFlowRatioTTM"`
	PriceToOperatingCashFlowRatioTTM           float64 `json:"priceToOperatingCashFlowRatioTTM"`
	DebtToAssetsRatioTTM                       float64 `json:"debtToAssetsRatioTTM"`
	DebtToEquityRatioTTM                       float64 `json:"debtToEquityRatioTTM"`
	DebtToCapitalRatioTTM                      float64 `json:"debtToCapitalRatioTTM"`
	LongTermDebtToCapitalRatioTTM              float64 `json:"longTermDebtToCapitalRatioTTM"`
	FinancialLeverageRatioTTM                  float64 `json:"financialLeverageRatioTTM"`
	WorkingCapitalTurnoverRatioTTM             float64 `json:"workingCapitalTurnoverRatioTTM"`
	OperatingCashFlowRatioTTM                  float64 `json:"operatingCashFlowRatioTTM"`
	OperatingCashFlowSalesRatioTTM             float64 `json:"operatingCashFlowSalesRatioTTM"`
	FreeCashFlowOperatingCashFlowRatioTTM      float64 `json:"freeCashFlowOperatingCashFlowRatioTTM"`
	DebtServiceCoverageRatioTTM                float64 `json:"debtServiceCoverageRatioTTM"`
	InterestCoverageRatioTTM                   float64 `json:"interestCoverageRatioTTM"`
	ShortTermOperatingCashFlowCoverageRatioTTM float64 `json:"shortTermOperatingCashFlowCoverageRatioTTM"`
	OperatingCashFlowCoverageRatioTTM          float64 `json:"operatingCashFlowCoverageRatioTTM"`
	CapitalExpenditureCoverageRatioTTM         float64 `json:"capitalExpenditureCoverageRatioTTM"`
	DividendPaidAndCapexCoverageRatioTTM       float64 `json:"dividendPaidAndCapexCoverageRatioTTM"`
	DividendPayoutRatioTTM                     float64 `json:"dividendPayoutRatioTTM"`
	DividendYieldTTM                           float64 `json:"dividendYieldTTM"`
	EnterpriseValueTTM                         float64 `json:"enterpriseValueTTM"`
	RevenuePerShareTTM                         float64 `json:"revenuePerShareTTM"`
	NetIncomePerShareTTM                       float64 `json:"netIncomePerShareTTM"`
	InterestDebtPerShareTTM                    float64 `json:"interestDebtPerShareTTM"`
	CashPerShareTTM                            float64 `json:"cashPerShareTTM"`
	BookValuePerShareTTM                       float64 `json:"bookValuePerShareTTM"`
	TangibleBookValuePerShareTTM               float64 `json:"tangibleBookValuePerShareTTM"`
	ShareholdersEquityPerShareTTM              float64 `json:"shareholdersEquityPerShareTTM"`
	OperatingCashFlowPerShareTTM               float64 `json:"operatingCashFlowPerShareTTM"`
	CapexPerShareTTM                           float64 `json:"capexPerShareTTM"`
	FreeCashFlowPerShareTTM                    float64 `json:"freeCashFlowPerShareTTM"`
	NetIncomePerEbtTTM                         float64 `json:"netIncomePerEBTTTM"`
	EbtPerEbitTTM                              float64 `json:"ebtPerEbitTTM"`
	PriceToFairValueTTM                        float64 `json:"priceToFairValueTTM"`
	DebtToMarketCapTTM                         float64 `json:"debtToMarketCapTTM"`
	EffectiveTaxRateTTM                        float64 `json:"effectiveTaxRateTTM"`
	EnterpriseValueMultipleTTM                 float64 `json:"enterpriseValueMultipleTTM"`
	DividendPerShareTTM                        float64 `json:"dividendPerShareTTM"`
}

FinancialRatiosTTM is one trailing-twelve-month worldwide financial-ratios row.

func (*FinancialRatiosTTM) UnmarshalJSONFrom added in v0.12.0

func (m *FinancialRatiosTTM) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type FinancialRatiosTTMQuery added in v0.12.0

type FinancialRatiosTTMQuery struct {
	// contains filtered or unexported fields
}

FinancialRatiosTTMQuery holds the query parameters of the endpoints that take it: NewFinancialRatiosTTMQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewFinancialRatiosTTMQuery added in v0.12.0

func NewFinancialRatiosTTMQuery(symbol string) FinancialRatiosTTMQuery

NewFinancialRatiosTTMQuery creates the query from its required arguments.

func (FinancialRatiosTTMQuery) Symbol added in v0.12.0

func (q FinancialRatiosTTMQuery) Symbol() string

Symbol returns the symbol argument as given.

type FinancialReportDate

type FinancialReportDate struct {
	Symbol     string `json:"symbol"`
	FiscalYear uint32 `json:"fiscalYear"`
	Period     string `json:"period"`
	LinkJSON   string `json:"linkJson"`
	LinkXlsx   string `json:"linkXlsx"`
}

FinancialReportDate is one available financial-report period and its protected download links.

func (*FinancialReportDate) UnmarshalJSONFrom

func (m *FinancialReportDate) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type FinancialReportJSON added in v0.12.0

type FinancialReportJSON struct {
	Symbol   string         `json:"symbol"`
	Period   string         `json:"period"`
	Year     string         `json:"year"`
	Sections jsontext.Value `json:",embed"`
}

FinancialReportJSON is one dynamic financial report with strict identifying headers.

func (*FinancialReportJSON) UnmarshalJSONFrom added in v0.12.0

func (m *FinancialReportJSON) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Every member no named field claims is kept in Sections.

type FinancialReportsDatesQuery

type FinancialReportsDatesQuery struct {
	// contains filtered or unexported fields
}

FinancialReportsDatesQuery holds the query parameters of the endpoints that take it: NewFinancialReportsDatesQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewFinancialReportsDatesQuery

func NewFinancialReportsDatesQuery(symbol string) FinancialReportsDatesQuery

NewFinancialReportsDatesQuery creates the query from its required arguments.

func (FinancialReportsDatesQuery) Symbol

Symbol returns the symbol argument as given.

type FinancialReportsJSONQuery added in v0.12.0

type FinancialReportsJSONQuery struct {
	// contains filtered or unexported fields
}

FinancialReportsJSONQuery holds the query parameters of the endpoints that take it: NewFinancialReportsJSONQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewFinancialReportsJSONQuery added in v0.12.0

func NewFinancialReportsJSONQuery(symbol string, year uint32, period FiscalPeriod) FinancialReportsJSONQuery

NewFinancialReportsJSONQuery creates the query from its required arguments.

func (FinancialReportsJSONQuery) Period added in v0.12.0

Period returns the period argument as given.

func (FinancialReportsJSONQuery) Symbol added in v0.12.0

func (q FinancialReportsJSONQuery) Symbol() string

Symbol returns the symbol argument as given.

func (FinancialReportsJSONQuery) Year added in v0.12.0

Year returns the year argument as given.

type FinancialReportsXlsxQuery

type FinancialReportsXlsxQuery struct {
	// contains filtered or unexported fields
}

FinancialReportsXlsxQuery holds the query parameters of the endpoints that take it: NewFinancialReportsXlsxQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewFinancialReportsXlsxQuery

func NewFinancialReportsXlsxQuery(symbol string, year uint32, period FiscalPeriod) FinancialReportsXlsxQuery

NewFinancialReportsXlsxQuery creates the query from its required arguments.

func (FinancialReportsXlsxQuery) Period

Period returns the period argument as given.

func (FinancialReportsXlsxQuery) Symbol

func (q FinancialReportsXlsxQuery) Symbol() string

Symbol returns the symbol argument as given.

func (FinancialReportsXlsxQuery) Year

Year returns the year argument as given.

type FinancialScore

type FinancialScore struct {
	Symbol           string  `json:"symbol"`
	ReportedCurrency string  `json:"reportedCurrency"`
	AltmanZScore     float64 `json:"altmanZScore"`
	PiotroskiScore   uint64  `json:"piotroskiScore"`
	WorkingCapital   float64 `json:"workingCapital"`
	TotalAssets      float64 `json:"totalAssets"`
	RetainedEarnings float64 `json:"retainedEarnings"`
	Ebit             float64 `json:"ebit"`
	MarketCap        float64 `json:"marketCap"`
	TotalLiabilities float64 `json:"totalLiabilities"`
	Revenue          float64 `json:"revenue"`
}

FinancialScore is one company's documented financial-health scores and source values.

func (*FinancialScore) UnmarshalJSONFrom

func (m *FinancialScore) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type FinancialScoresQuery

type FinancialScoresQuery struct {
	// contains filtered or unexported fields
}

FinancialScoresQuery holds the query parameters of the endpoints that take it: NewFinancialScoresQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewFinancialScoresQuery

func NewFinancialScoresQuery(symbol string) FinancialScoresQuery

NewFinancialScoresQuery creates the query from its required arguments.

func (FinancialScoresQuery) Symbol

func (q FinancialScoresQuery) Symbol() string

Symbol returns the symbol argument as given.

type FinancialStatementFullAsReportedQuery

type FinancialStatementFullAsReportedQuery struct {
	// contains filtered or unexported fields
}

FinancialStatementFullAsReportedQuery holds the query parameters of the endpoints that take it: NewFinancialStatementFullAsReportedQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewFinancialStatementFullAsReportedQuery

func NewFinancialStatementFullAsReportedQuery(symbol string) FinancialStatementFullAsReportedQuery

NewFinancialStatementFullAsReportedQuery creates the query from its required arguments.

func (FinancialStatementFullAsReportedQuery) Limit

Limit returns the optional limit parameter, or nil when it is unset.

func (FinancialStatementFullAsReportedQuery) Period

Period returns the optional period parameter, or nil when it is unset.

func (FinancialStatementFullAsReportedQuery) Symbol

Symbol returns the symbol argument as given.

func (FinancialStatementFullAsReportedQuery) WithLimit

WithLimit sets the optional limit parameter and returns the updated query.

func (FinancialStatementFullAsReportedQuery) WithPeriod

WithPeriod sets the optional period parameter and returns the updated query.

type FinancialStatementGrowth

type FinancialStatementGrowth struct {
	Symbol                                  string  `json:"symbol"`
	Date                                    Date    `json:"date"`
	FiscalYear                              string  `json:"fiscalYear"`
	Period                                  string  `json:"period"`
	ReportedCurrency                        string  `json:"reportedCurrency"`
	RevenueGrowth                           float64 `json:"revenueGrowth"`
	GrossProfitGrowth                       float64 `json:"grossProfitGrowth"`
	EbitGrowth                              float64 `json:"ebitgrowth"`
	OperatingIncomeGrowth                   float64 `json:"operatingIncomeGrowth"`
	NetIncomeGrowth                         float64 `json:"netIncomeGrowth"`
	EPSGrowth                               float64 `json:"epsgrowth"`
	EPSDilutedGrowth                        float64 `json:"epsdilutedGrowth"`
	WeightedAverageSharesGrowth             float64 `json:"weightedAverageSharesGrowth"`
	WeightedAverageSharesDilutedGrowth      float64 `json:"weightedAverageSharesDilutedGrowth"`
	DividendsPerShareGrowth                 float64 `json:"dividendsPerShareGrowth"`
	OperatingCashFlowGrowth                 float64 `json:"operatingCashFlowGrowth"`
	ReceivablesGrowth                       float64 `json:"receivablesGrowth"`
	InventoryGrowth                         float64 `json:"inventoryGrowth"`
	AssetGrowth                             float64 `json:"assetGrowth"`
	BookValuePerShareGrowth                 float64 `json:"bookValueperShareGrowth"`
	DebtGrowth                              float64 `json:"debtGrowth"`
	RdExpenseGrowth                         float64 `json:"rdexpenseGrowth"`
	SgaExpensesGrowth                       float64 `json:"sgaexpensesGrowth"`
	FreeCashFlowGrowth                      float64 `json:"freeCashFlowGrowth"`
	TenYRevenueGrowthPerShare               float64 `json:"tenYRevenueGrowthPerShare"`
	FiveYRevenueGrowthPerShare              float64 `json:"fiveYRevenueGrowthPerShare"`
	ThreeYRevenueGrowthPerShare             float64 `json:"threeYRevenueGrowthPerShare"`
	TenYOperatingCfGrowthPerShare           float64 `json:"tenYOperatingCFGrowthPerShare"`
	FiveYOperatingCfGrowthPerShare          float64 `json:"fiveYOperatingCFGrowthPerShare"`
	ThreeYOperatingCfGrowthPerShare         float64 `json:"threeYOperatingCFGrowthPerShare"`
	TenYNetIncomeGrowthPerShare             float64 `json:"tenYNetIncomeGrowthPerShare"`
	FiveYNetIncomeGrowthPerShare            float64 `json:"fiveYNetIncomeGrowthPerShare"`
	ThreeYNetIncomeGrowthPerShare           float64 `json:"threeYNetIncomeGrowthPerShare"`
	TenYShareholdersEquityGrowthPerShare    float64 `json:"tenYShareholdersEquityGrowthPerShare"`
	FiveYShareholdersEquityGrowthPerShare   float64 `json:"fiveYShareholdersEquityGrowthPerShare"`
	ThreeYShareholdersEquityGrowthPerShare  float64 `json:"threeYShareholdersEquityGrowthPerShare"`
	TenYDividendPerShareGrowthPerShare      float64 `json:"tenYDividendperShareGrowthPerShare"`
	FiveYDividendPerShareGrowthPerShare     float64 `json:"fiveYDividendperShareGrowthPerShare"`
	ThreeYDividendPerShareGrowthPerShare    float64 `json:"threeYDividendperShareGrowthPerShare"`
	EbitdaGrowth                            float64 `json:"ebitdaGrowth"`
	GrowthCapitalExpenditure                float64 `json:"growthCapitalExpenditure"`
	TenYBottomLineNetIncomeGrowthPerShare   float64 `json:"tenYBottomLineNetIncomeGrowthPerShare"`
	FiveYBottomLineNetIncomeGrowthPerShare  float64 `json:"fiveYBottomLineNetIncomeGrowthPerShare"`
	ThreeYBottomLineNetIncomeGrowthPerShare float64 `json:"threeYBottomLineNetIncomeGrowthPerShare"`
}

FinancialStatementGrowth is one combined financial-statement growth row.

func (*FinancialStatementGrowth) UnmarshalJSONFrom

func (m *FinancialStatementGrowth) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type FinancialStatementGrowthQuery

type FinancialStatementGrowthQuery struct {
	// contains filtered or unexported fields
}

FinancialStatementGrowthQuery holds the query parameters of the endpoints that take it: NewFinancialStatementGrowthQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewFinancialStatementGrowthQuery

func NewFinancialStatementGrowthQuery(symbol string) FinancialStatementGrowthQuery

NewFinancialStatementGrowthQuery creates the query from its required arguments.

func (FinancialStatementGrowthQuery) Limit

Limit returns the optional limit parameter, or nil when it is unset.

func (FinancialStatementGrowthQuery) Period

Period returns the optional period parameter, or nil when it is unset.

func (FinancialStatementGrowthQuery) Symbol

Symbol returns the symbol argument as given.

func (FinancialStatementGrowthQuery) WithLimit

WithLimit sets the optional limit parameter and returns the updated query.

func (FinancialStatementGrowthQuery) WithPeriod

WithPeriod sets the optional period parameter and returns the updated query.

type FinancialStatementSymbol

type FinancialStatementSymbol struct {
	Symbol            string `json:"symbol"`
	CompanyName       string `json:"companyName"`
	TradingCurrency   string `json:"tradingCurrency"`
	ReportingCurrency string `json:"reportingCurrency"`
}

FinancialStatementSymbol is one worldwide company with financial statements available from FMP.

func (*FinancialStatementSymbol) UnmarshalJSONFrom

func (m *FinancialStatementSymbol) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type FiscalPeriod

type FiscalPeriod string

FiscalPeriod is a fiscal reporting period of the endpoints whose Rust query takes a FiscalPeriod: the four quarters and the full year, without the retrieval-frequency aliases. The constants carry the exact provider wire spellings; any other value is rejected when the request is built.

const (
	FiscalPeriodQ1       FiscalPeriod = "Q1"
	FiscalPeriodQ2       FiscalPeriod = "Q2"
	FiscalPeriodQ3       FiscalPeriod = "Q3"
	FiscalPeriodQ4       FiscalPeriod = "Q4"
	FiscalPeriodFullYear FiscalPeriod = "FY"
)

The documented FiscalPeriod wire values.

type ForexNamespace

type ForexNamespace struct {
	// contains filtered or unexported fields
}

ForexNamespace groups the forex endpoints. It is reached as Client.Forex and is valid only when obtained from a Client built by NewClient.

func (*ForexNamespace) ChartFiveMinutes

func (n *ForexNamespace) ChartFiveMinutes(ctx context.Context, q AssetChartQuery) ([]StockChartIntradayBar, error)

ChartFiveMinutes retrieves five-minute forex history.

GET historical-chart/5min?symbol=&from=&to=

func (*ForexNamespace) ChartFull

ChartFull retrieves detailed end-of-day forex history.

GET historical-price-eod/full?symbol=&from=&to=

func (*ForexNamespace) ChartLight

ChartLight retrieves compact end-of-day forex history.

GET historical-price-eod/light?symbol=&from=&to=

func (*ForexNamespace) ChartOneHour

ChartOneHour retrieves one-hour forex history.

GET historical-chart/1hour?symbol=&from=&to=

func (*ForexNamespace) ChartOneMinute

ChartOneMinute retrieves one-minute forex history.

GET historical-chart/1min?symbol=&from=&to=

func (*ForexNamespace) List

func (n *ForexNamespace) List(ctx context.Context) ([]ForexPair, error)

List lists the provider's documented forex pairs.

GET forex-list

func (*ForexNamespace) Quote

func (n *ForexNamespace) Quote(ctx context.Context, q QuoteQuery) ([]Quote, error)

Quote retrieves a detailed US-only quote for one forex pair.

GET quote?symbol=

func (*ForexNamespace) QuoteShort

func (n *ForexNamespace) QuoteShort(ctx context.Context, q QuoteShortQuery) ([]QuoteShort, error)

QuoteShort retrieves a compact US-only quote for one forex pair.

GET quote-short?symbol=

type ForexPair

type ForexPair struct {
	Symbol       string `json:"symbol"`
	FromCurrency string `json:"fromCurrency"`
	ToCurrency   string `json:"toCurrency"`
	FromName     string `json:"fromName"`
	ToName       string `json:"toName"`
}

ForexPair is one currency pair in the provider's documented forex catalog.

func (*ForexPair) UnmarshalJSONFrom

func (m *ForexPair) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type Form13FFilingDate added in v0.12.0

type Form13FFilingDate struct {
	Date    Date   `json:"date"`
	Year    uint32 `json:"year"`
	Quarter uint8  `json:"quarter"`
}

Form13FFilingDate is one available Form 13F reporting date and its numeric calendar period.

func (*Form13FFilingDate) UnmarshalJSONFrom added in v0.12.0

func (m *Form13FFilingDate) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type Form13FFilingDatesQuery added in v0.12.0

type Form13FFilingDatesQuery struct {
	// contains filtered or unexported fields
}

Form13FFilingDatesQuery holds the query parameters of the endpoints that take it: NewForm13FFilingDatesQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewForm13FFilingDatesQuery added in v0.12.0

func NewForm13FFilingDatesQuery(cik string) Form13FFilingDatesQuery

NewForm13FFilingDatesQuery creates the query from its required arguments.

func (Form13FFilingDatesQuery) CIK added in v0.12.0

CIK returns the cik argument as given.

type FundDisclosure

type FundDisclosure struct {
	CIK                 string   `json:"cik"`
	Date                Date     `json:"date"`
	AcceptedDate        DateTime `json:"acceptedDate"`
	Symbol              string   `json:"symbol"`
	Name                string   `json:"name"`
	Lei                 string   `json:"lei"`
	Title               string   `json:"title"`
	CUSIP               string   `json:"cusip"`
	ISIN                string   `json:"isin"`
	Balance             float64  `json:"balance"`
	Units               string   `json:"units"`
	CurrencyCode        string   `json:"cur_cd"`
	ValUsd              float64  `json:"valUsd"`
	PctVal              float64  `json:"pctVal"`
	PayoffProfile       string   `json:"payoffProfile"`
	AssetCat            string   `json:"assetCat"`
	IssuerCat           string   `json:"issuerCat"`
	InvCountry          string   `json:"invCountry"`
	IsRestrictedSEC     string   `json:"isRestrictedSec"`
	FairValLevel        string   `json:"fairValLevel"`
	IsCashCollateral    string   `json:"isCashCollateral"`
	IsNonCashCollateral string   `json:"isNonCashCollateral"`
	IsLoanByFund        string   `json:"isLoanByFund"`
}

FundDisclosure is one position in a mutual-fund disclosure filing.

func (*FundDisclosure) UnmarshalJSONFrom

func (m *FundDisclosure) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type FundDisclosureDatesQuery

type FundDisclosureDatesQuery struct {
	// contains filtered or unexported fields
}

FundDisclosureDatesQuery holds the query parameters of the endpoints that take it: NewFundDisclosureDatesQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewFundDisclosureDatesQuery

func NewFundDisclosureDatesQuery(symbol string) FundDisclosureDatesQuery

NewFundDisclosureDatesQuery creates the query from its required arguments.

func (FundDisclosureDatesQuery) CIK added in v0.12.0

CIK returns the optional cik parameter, or nil when it is unset.

func (FundDisclosureDatesQuery) Symbol

func (q FundDisclosureDatesQuery) Symbol() string

Symbol returns the symbol argument as given.

func (FundDisclosureDatesQuery) WithCIK added in v0.12.0

WithCIK sets the optional cik parameter and returns the updated query.

type FundDisclosureHolder

type FundDisclosureHolder struct {
	CIK           string  `json:"cik"`
	Holder        string  `json:"holder"`
	SecurityCUSIP string  `json:"securityCusip"`
	Shares        float64 `json:"shares"`
	DateReported  Date    `json:"dateReported"`
	Change        float64 `json:"change"`
	WeightPercent float64 `json:"weightPercent"`
}

FundDisclosureHolder is one fund holder from the latest disclosure for a security.

func (*FundDisclosureHolder) UnmarshalJSONFrom

func (m *FundDisclosureHolder) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type FundDisclosureHolderSearchQuery

type FundDisclosureHolderSearchQuery struct {
	// contains filtered or unexported fields
}

FundDisclosureHolderSearchQuery holds the query parameters of the endpoints that take it: NewFundDisclosureHolderSearchQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewFundDisclosureHolderSearchQuery

func NewFundDisclosureHolderSearchQuery(name string) FundDisclosureHolderSearchQuery

NewFundDisclosureHolderSearchQuery creates the query from its required arguments.

func (FundDisclosureHolderSearchQuery) Name

Name returns the name argument as given.

type FundDisclosureQuery

type FundDisclosureQuery struct {
	// contains filtered or unexported fields
}

FundDisclosureQuery holds the query parameters of the endpoints that take it: NewFundDisclosureQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewFundDisclosureQuery

func NewFundDisclosureQuery(symbol string, year uint32, quarter Quarter) FundDisclosureQuery

NewFundDisclosureQuery creates the query from its required arguments.

func (FundDisclosureQuery) CIK added in v0.12.0

func (q FundDisclosureQuery) CIK() *string

CIK returns the optional cik parameter, or nil when it is unset.

func (FundDisclosureQuery) Quarter

func (q FundDisclosureQuery) Quarter() Quarter

Quarter returns the quarter argument as given.

func (FundDisclosureQuery) Symbol

func (q FundDisclosureQuery) Symbol() string

Symbol returns the symbol argument as given.

func (FundDisclosureQuery) WithCIK added in v0.12.0

WithCIK sets the optional cik parameter and returns the updated query.

func (FundDisclosureQuery) Year

func (q FundDisclosureQuery) Year() uint32

Year returns the year argument as given.

type FundDisclosureSearchResult

type FundDisclosureSearchResult struct {
	Symbol              string `json:"symbol"`
	CIK                 string `json:"cik"`
	ClassID             string `json:"classId"`
	SeriesID            string `json:"seriesId"`
	EntityName          string `json:"entityName"`
	EntityOrgType       string `json:"entityOrgType"`
	SeriesName          string `json:"seriesName"`
	ClassName           string `json:"className"`
	ReportingFileNumber string `json:"reportingFileNumber"`
	Address             string `json:"address"`
	City                string `json:"city"`
	ZipCode             string `json:"zipCode"`
	State               string `json:"state"`
}

FundDisclosureSearchResult is one result from searching disclosure holders by fund or ETF name.

func (*FundDisclosureSearchResult) UnmarshalJSONFrom

func (m *FundDisclosureSearchResult) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type FundraisingNamespace

type FundraisingNamespace struct {
	// contains filtered or unexported fields
}

FundraisingNamespace groups the fundraising endpoints. It is reached as Client.Fundraising and is valid only when obtained from a Client built by NewClient.

func (*FundraisingNamespace) CrowdfundingOfferingsByCIK added in v0.12.0

func (n *FundraisingNamespace) CrowdfundingOfferingsByCIK(ctx context.Context, q OfferingByCIKQuery) ([]CrowdfundingOffering, error)

CrowdfundingOfferingsByCIK retrieves US crowdfunding offerings for one issuer CIK.

GET crowdfunding-offerings?cik=

func (*FundraisingNamespace) LatestCrowdfundingOfferings

LatestCrowdfundingOfferings retrieves the latest US crowdfunding offerings.

GET crowdfunding-offerings-latest?page=&limit=

func (*FundraisingNamespace) LatestRegulationDOfferings

LatestRegulationDOfferings retrieves the latest US Regulation D offerings.

GET fundraising-latest?page=&limit=&cik=

func (*FundraisingNamespace) RegulationDOfferingsByCIK added in v0.12.0

func (n *FundraisingNamespace) RegulationDOfferingsByCIK(ctx context.Context, q OfferingByCIKQuery) ([]RegulationDOffering, error)

RegulationDOfferingsByCIK retrieves US Regulation D offerings for one issuer CIK.

GET fundraising?cik=

func (*FundraisingNamespace) SearchCrowdfundingOfferings

SearchCrowdfundingOfferings searches US crowdfunding offerings by company, campaign, or platform text.

GET crowdfunding-offerings-search?name=

func (*FundraisingNamespace) SearchRegulationDOfferings

SearchRegulationDOfferings searches US Regulation D offerings by company name or stock symbol.

GET fundraising-search?name=

type FundsNamespace

type FundsNamespace struct {
	// contains filtered or unexported fields
}

FundsNamespace groups the funds endpoints. It is reached as Client.Funds and is valid only when obtained from a Client built by NewClient.

func (*FundsNamespace) DisclosureDates added in v0.12.0

DisclosureDates retrieves available US fund-disclosure reporting dates.

GET funds/disclosure-dates?symbol=&cik=

func (*FundsNamespace) Disclosures added in v0.12.0

Disclosures retrieves positions from one US mutual-fund disclosure period.

GET funds/disclosure?symbol=&year=&quarter=&cik=

func (*FundsNamespace) ETFAssetExposure added in v0.12.0

func (n *FundsNamespace) ETFAssetExposure(ctx context.Context, q ETFAssetExposureQuery) ([]ETFAssetExposure, error)

ETFAssetExposure retrieves the worldwide ETF exposure to one requested asset.

GET etf/asset-exposure?symbol=

func (*FundsNamespace) ETFCountryWeightings added in v0.12.0

ETFCountryWeightings retrieves the worldwide country allocation for one ETF or mutual fund.

GET etf/country-weightings?symbol=

func (*FundsNamespace) ETFHoldings added in v0.12.0

func (n *FundsNamespace) ETFHoldings(ctx context.Context, q ETFHoldingsQuery) ([]ETFFundHolding, error)

ETFHoldings retrieves the worldwide holdings of one ETF or mutual fund.

GET etf/holdings?symbol=

func (*FundsNamespace) ETFInfo added in v0.12.0

func (n *FundsNamespace) ETFInfo(ctx context.Context, q ETFInfoQuery) ([]ETFFundInfo, error)

ETFInfo retrieves worldwide descriptive and trading information for one fund.

GET etf/info?symbol=

func (*FundsNamespace) ETFSectorWeightings added in v0.12.0

func (n *FundsNamespace) ETFSectorWeightings(ctx context.Context, q ETFSectorWeightingsQuery) ([]ETFSectorWeighting, error)

ETFSectorWeightings retrieves the worldwide sector allocation for one ETF or mutual fund.

GET etf/sector-weightings?symbol=

func (*FundsNamespace) LatestDisclosureHolders added in v0.12.0

LatestDisclosureHolders retrieves the latest US fund disclosures holding one requested asset.

GET funds/disclosure-holders-latest?symbol=

func (*FundsNamespace) SearchDisclosureHolders added in v0.12.0

SearchDisclosureHolders searches US mutual-fund and ETF disclosure holders by exact name text.

GET funds/disclosure-holders-search?name=

type GeographicAvailability

type GeographicAvailability int

GeographicAvailability is the geographic coverage documented for an endpoint. It mirrors the Rust GeographicAvailability; the zero value is GeographyUnspecified.

const (
	// GeographyUnspecified: the documentation states no coverage.
	GeographyUnspecified GeographicAvailability = iota
	// GeographyWorldwide: the endpoint covers every supported market.
	GeographyWorldwide
	// GeographyUSOnly: the endpoint covers US listings only.
	GeographyUSOnly
)

func (GeographicAvailability) String

func (g GeographicAvailability) String() string

String returns a short stable label that is safe to log.

type HistoricalEmployeeCountQuery

type HistoricalEmployeeCountQuery struct {
	// contains filtered or unexported fields
}

HistoricalEmployeeCountQuery holds the query parameters of the endpoints that take it: NewHistoricalEmployeeCountQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewHistoricalEmployeeCountQuery

func NewHistoricalEmployeeCountQuery(symbol string) HistoricalEmployeeCountQuery

NewHistoricalEmployeeCountQuery creates the query from its required arguments.

func (HistoricalEmployeeCountQuery) Limit

Limit returns the optional limit parameter, or nil when it is unset.

func (HistoricalEmployeeCountQuery) Symbol

Symbol returns the symbol argument as given.

func (HistoricalEmployeeCountQuery) WithLimit

WithLimit sets the optional limit parameter and returns the updated query.

type HistoricalIndexConstituent

type HistoricalIndexConstituent struct {
	DateAdded       string  `json:"dateAdded"`
	AddedSecurity   string  `json:"addedSecurity"`
	RemovedTicker   *string `json:"removedTicker"`
	RemovedSecurity *string `json:"removedSecurity"`
	Date            Date    `json:"date"`
	Symbol          string  `json:"symbol"`
	Reason          string  `json:"reason"`
}

HistoricalIndexConstituent is one documented historical addition to and removal from a major US index.

func (*HistoricalIndexConstituent) UnmarshalJSONFrom

func (m *HistoricalIndexConstituent) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type HistoricalIndustryPeQuery

type HistoricalIndustryPeQuery struct {
	// contains filtered or unexported fields
}

HistoricalIndustryPeQuery holds the query parameters of the endpoints that take it: NewHistoricalIndustryPeQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewHistoricalIndustryPeQuery

func NewHistoricalIndustryPeQuery(industry string) HistoricalIndustryPeQuery

NewHistoricalIndustryPeQuery creates the query from its required arguments.

func (HistoricalIndustryPeQuery) Exchange

func (q HistoricalIndustryPeQuery) Exchange() *string

Exchange returns the optional exchange parameter, or nil when it is unset.

func (HistoricalIndustryPeQuery) From

func (q HistoricalIndustryPeQuery) From() *Date

From returns the optional from parameter, or nil when it is unset.

func (HistoricalIndustryPeQuery) Industry

func (q HistoricalIndustryPeQuery) Industry() string

Industry returns the industry argument as given.

func (HistoricalIndustryPeQuery) To

To returns the optional to parameter, or nil when it is unset.

func (HistoricalIndustryPeQuery) WithExchange

WithExchange sets the optional exchange parameter and returns the updated query.

func (HistoricalIndustryPeQuery) WithFrom

WithFrom sets the optional from parameter and returns the updated query.

func (HistoricalIndustryPeQuery) WithTo

WithTo sets the optional to parameter and returns the updated query.

type HistoricalIndustryPerformanceQuery

type HistoricalIndustryPerformanceQuery struct {
	// contains filtered or unexported fields
}

HistoricalIndustryPerformanceQuery holds the query parameters of the endpoints that take it: NewHistoricalIndustryPerformanceQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewHistoricalIndustryPerformanceQuery

func NewHistoricalIndustryPerformanceQuery(industry string) HistoricalIndustryPerformanceQuery

NewHistoricalIndustryPerformanceQuery creates the query from its required arguments.

func (HistoricalIndustryPerformanceQuery) Exchange

Exchange returns the optional exchange parameter, or nil when it is unset.

func (HistoricalIndustryPerformanceQuery) From

From returns the optional from parameter, or nil when it is unset.

func (HistoricalIndustryPerformanceQuery) Industry

Industry returns the industry argument as given.

func (HistoricalIndustryPerformanceQuery) To

To returns the optional to parameter, or nil when it is unset.

func (HistoricalIndustryPerformanceQuery) WithExchange

WithExchange sets the optional exchange parameter and returns the updated query.

func (HistoricalIndustryPerformanceQuery) WithFrom

WithFrom sets the optional from parameter and returns the updated query.

func (HistoricalIndustryPerformanceQuery) WithTo

WithTo sets the optional to parameter and returns the updated query.

type HistoricalMarketCapitalizationQuery

type HistoricalMarketCapitalizationQuery struct {
	// contains filtered or unexported fields
}

HistoricalMarketCapitalizationQuery holds the query parameters of the endpoints that take it: NewHistoricalMarketCapitalizationQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewHistoricalMarketCapitalizationQuery

func NewHistoricalMarketCapitalizationQuery(symbol string) HistoricalMarketCapitalizationQuery

NewHistoricalMarketCapitalizationQuery creates the query from its required arguments.

func (HistoricalMarketCapitalizationQuery) From

From returns the optional from parameter, or nil when it is unset.

func (HistoricalMarketCapitalizationQuery) Limit

Limit returns the optional limit parameter, or nil when it is unset.

func (HistoricalMarketCapitalizationQuery) Symbol

Symbol returns the symbol argument as given.

func (HistoricalMarketCapitalizationQuery) To

To returns the optional to parameter, or nil when it is unset.

func (HistoricalMarketCapitalizationQuery) WithFrom

WithFrom sets the optional from parameter and returns the updated query.

func (HistoricalMarketCapitalizationQuery) WithLimit

WithLimit sets the optional limit parameter and returns the updated query.

func (HistoricalMarketCapitalizationQuery) WithTo

WithTo sets the optional to parameter and returns the updated query.

type HistoricalRating

type HistoricalRating struct {
	Symbol                  string `json:"symbol"`
	Date                    Date   `json:"date"`
	Rating                  string `json:"rating"`
	OverallScore            uint64 `json:"overallScore"`
	DiscountedCashFlowScore uint64 `json:"discountedCashFlowScore"`
	ReturnOnEquityScore     uint64 `json:"returnOnEquityScore"`
	ReturnOnAssetsScore     uint64 `json:"returnOnAssetsScore"`
	DebtToEquityScore       uint64 `json:"debtToEquityScore"`
	PriceToEarningsScore    uint64 `json:"priceToEarningsScore"`
	PriceToBookScore        uint64 `json:"priceToBookScore"`
}

HistoricalRating is one dated historical financial rating.

func (*HistoricalRating) UnmarshalJSONFrom

func (m *HistoricalRating) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type HistoricalRatingsQuery

type HistoricalRatingsQuery struct {
	// contains filtered or unexported fields
}

HistoricalRatingsQuery holds the query parameters of the endpoints that take it: NewHistoricalRatingsQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewHistoricalRatingsQuery

func NewHistoricalRatingsQuery(symbol string) HistoricalRatingsQuery

NewHistoricalRatingsQuery creates the query from its required arguments.

func (HistoricalRatingsQuery) Limit

func (q HistoricalRatingsQuery) Limit() *uint32

Limit returns the optional limit parameter, or nil when it is unset.

func (HistoricalRatingsQuery) Symbol

func (q HistoricalRatingsQuery) Symbol() string

Symbol returns the symbol argument as given.

func (HistoricalRatingsQuery) WithLimit

WithLimit sets the optional limit parameter and returns the updated query.

type HistoricalSectorPeQuery

type HistoricalSectorPeQuery struct {
	// contains filtered or unexported fields
}

HistoricalSectorPeQuery holds the query parameters of the endpoints that take it: NewHistoricalSectorPeQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewHistoricalSectorPeQuery

func NewHistoricalSectorPeQuery(sector string) HistoricalSectorPeQuery

NewHistoricalSectorPeQuery creates the query from its required arguments.

func (HistoricalSectorPeQuery) Exchange

func (q HistoricalSectorPeQuery) Exchange() *string

Exchange returns the optional exchange parameter, or nil when it is unset.

func (HistoricalSectorPeQuery) From

func (q HistoricalSectorPeQuery) From() *Date

From returns the optional from parameter, or nil when it is unset.

func (HistoricalSectorPeQuery) Sector

func (q HistoricalSectorPeQuery) Sector() string

Sector returns the sector argument as given.

func (HistoricalSectorPeQuery) To

func (q HistoricalSectorPeQuery) To() *Date

To returns the optional to parameter, or nil when it is unset.

func (HistoricalSectorPeQuery) WithExchange

func (q HistoricalSectorPeQuery) WithExchange(exchange string) HistoricalSectorPeQuery

WithExchange sets the optional exchange parameter and returns the updated query.

func (HistoricalSectorPeQuery) WithFrom

WithFrom sets the optional from parameter and returns the updated query.

func (HistoricalSectorPeQuery) WithTo

WithTo sets the optional to parameter and returns the updated query.

type HistoricalSectorPerformanceQuery

type HistoricalSectorPerformanceQuery struct {
	// contains filtered or unexported fields
}

HistoricalSectorPerformanceQuery holds the query parameters of the endpoints that take it: NewHistoricalSectorPerformanceQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewHistoricalSectorPerformanceQuery

func NewHistoricalSectorPerformanceQuery(sector string) HistoricalSectorPerformanceQuery

NewHistoricalSectorPerformanceQuery creates the query from its required arguments.

func (HistoricalSectorPerformanceQuery) Exchange

Exchange returns the optional exchange parameter, or nil when it is unset.

func (HistoricalSectorPerformanceQuery) From

From returns the optional from parameter, or nil when it is unset.

func (HistoricalSectorPerformanceQuery) Sector

Sector returns the sector argument as given.

func (HistoricalSectorPerformanceQuery) To

To returns the optional to parameter, or nil when it is unset.

func (HistoricalSectorPerformanceQuery) WithExchange

WithExchange sets the optional exchange parameter and returns the updated query.

func (HistoricalSectorPerformanceQuery) WithFrom

WithFrom sets the optional from parameter and returns the updated query.

func (HistoricalSectorPerformanceQuery) WithTo

WithTo sets the optional to parameter and returns the updated query.

type HistoricalStockGrade

type HistoricalStockGrade struct {
	Symbol                   string `json:"symbol"`
	Date                     Date   `json:"date"`
	AnalystRatingsStrongBuy  uint64 `json:"analystRatingsStrongBuy"`
	AnalystRatingsBuy        uint64 `json:"analystRatingsBuy"`
	AnalystRatingsHold       uint64 `json:"analystRatingsHold"`
	AnalystRatingsSell       uint64 `json:"analystRatingsSell"`
	AnalystRatingsStrongSell uint64 `json:"analystRatingsStrongSell"`
}

HistoricalStockGrade is one dated historical count of analyst rating buckets.

func (*HistoricalStockGrade) UnmarshalJSONFrom

func (m *HistoricalStockGrade) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type HistoricalStockGradesQuery

type HistoricalStockGradesQuery struct {
	// contains filtered or unexported fields
}

HistoricalStockGradesQuery holds the query parameters of the endpoints that take it: NewHistoricalStockGradesQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewHistoricalStockGradesQuery

func NewHistoricalStockGradesQuery(symbol string) HistoricalStockGradesQuery

NewHistoricalStockGradesQuery creates the query from its required arguments.

func (HistoricalStockGradesQuery) Limit

Limit returns the optional limit parameter, or nil when it is unset.

func (HistoricalStockGradesQuery) Symbol

Symbol returns the symbol argument as given.

func (HistoricalStockGradesQuery) WithLimit

WithLimit sets the optional limit parameter and returns the updated query.

type HolderIndustryBreakdown

type HolderIndustryBreakdown struct {
	Date                     Date    `json:"date"`
	CIK                      string  `json:"cik"`
	InvestorName             string  `json:"investorName"`
	IndustryTitle            string  `json:"industryTitle"`
	Weight                   float64 `json:"weight"`
	LastWeight               float64 `json:"lastWeight"`
	ChangeInWeight           float64 `json:"changeInWeight"`
	ChangeInWeightPercentage float64 `json:"changeInWeightPercentage"`
	Performance              float64 `json:"performance"`
	PerformancePercentage    float64 `json:"performancePercentage"`
	LastPerformance          float64 `json:"lastPerformance"`
	ChangeInPerformance      float64 `json:"changeInPerformance"`
}

HolderIndustryBreakdown is one industry allocation and performance row for an institutional holder.

func (*HolderIndustryBreakdown) UnmarshalJSONFrom

func (m *HolderIndustryBreakdown) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type HolderIndustryBreakdownQuery

type HolderIndustryBreakdownQuery struct {
	// contains filtered or unexported fields
}

HolderIndustryBreakdownQuery holds the query parameters of the endpoints that take it: NewHolderIndustryBreakdownQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewHolderIndustryBreakdownQuery

func NewHolderIndustryBreakdownQuery(cik string, year uint32, quarter Quarter) HolderIndustryBreakdownQuery

NewHolderIndustryBreakdownQuery creates the query from its required arguments.

func (HolderIndustryBreakdownQuery) CIK added in v0.12.0

CIK returns the cik argument as given.

func (HolderIndustryBreakdownQuery) Quarter

Quarter returns the quarter argument as given.

func (HolderIndustryBreakdownQuery) Year

Year returns the year argument as given.

type HolderPerformanceSummary

type HolderPerformanceSummary struct {
	Date                                               Date    `json:"date"`
	CIK                                                string  `json:"cik"`
	InvestorName                                       string  `json:"investorName"`
	PortfolioSize                                      uint64  `json:"portfolioSize"`
	SecuritiesAdded                                    uint64  `json:"securitiesAdded"`
	SecuritiesRemoved                                  uint64  `json:"securitiesRemoved"`
	MarketValue                                        float64 `json:"marketValue"`
	PreviousMarketValue                                float64 `json:"previousMarketValue"`
	ChangeInMarketValue                                float64 `json:"changeInMarketValue"`
	ChangeInMarketValuePercentage                      float64 `json:"changeInMarketValuePercentage"`
	AverageHoldingPeriod                               float64 `json:"averageHoldingPeriod"`
	AverageHoldingPeriodTop10                          float64 `json:"averageHoldingPeriodTop10"`
	AverageHoldingPeriodTop20                          float64 `json:"averageHoldingPeriodTop20"`
	Turnover                                           float64 `json:"turnover"`
	TurnoverAlternateSell                              float64 `json:"turnoverAlternateSell"`
	TurnoverAlternateBuy                               float64 `json:"turnoverAlternateBuy"`
	Performance                                        float64 `json:"performance"`
	PerformancePercentage                              float64 `json:"performancePercentage"`
	LastPerformance                                    float64 `json:"lastPerformance"`
	ChangeInPerformance                                float64 `json:"changeInPerformance"`
	Performance1Year                                   float64 `json:"performance1year"`
	PerformancePercentage1Year                         float64 `json:"performancePercentage1year"`
	Performance3Year                                   float64 `json:"performance3year"`
	PerformancePercentage3Year                         float64 `json:"performancePercentage3year"`
	Performance5Year                                   float64 `json:"performance5year"`
	PerformancePercentage5Year                         float64 `json:"performancePercentage5year"`
	PerformanceSinceInception                          float64 `json:"performanceSinceInception"`
	PerformanceSinceInceptionPercentage                float64 `json:"performanceSinceInceptionPercentage"`
	PerformanceRelativeToSP500Percentage               float64 `json:"performanceRelativeToSP500Percentage"`
	Performance1YearRelativeToSP500Percentage          float64 `json:"performance1yearRelativeToSP500Percentage"`
	Performance3YearRelativeToSP500Percentage          float64 `json:"performance3yearRelativeToSP500Percentage"`
	Performance5YearRelativeToSP500Percentage          float64 `json:"performance5yearRelativeToSP500Percentage"`
	PerformanceSinceInceptionRelativeToSP500Percentage float64 `json:"performanceSinceInceptionRelativeToSP500Percentage"`
}

HolderPerformanceSummary is one institutional holder's portfolio and benchmark performance summary.

func (*HolderPerformanceSummary) UnmarshalJSONFrom

func (m *HolderPerformanceSummary) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type HolderPerformanceSummaryQuery

type HolderPerformanceSummaryQuery struct {
	// contains filtered or unexported fields
}

HolderPerformanceSummaryQuery holds the query parameters of the endpoints that take it: NewHolderPerformanceSummaryQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewHolderPerformanceSummaryQuery

func NewHolderPerformanceSummaryQuery(cik string) HolderPerformanceSummaryQuery

NewHolderPerformanceSummaryQuery creates the query from its required arguments.

func (HolderPerformanceSummaryQuery) CIK added in v0.12.0

CIK returns the cik argument as given.

func (HolderPerformanceSummaryQuery) Page

Page returns the optional page parameter, or nil when it is unset.

func (HolderPerformanceSummaryQuery) WithPage

WithPage sets the optional page parameter and returns the updated query.

type HolidaysByExchangeQuery

type HolidaysByExchangeQuery struct {
	// contains filtered or unexported fields
}

HolidaysByExchangeQuery holds the query parameters of the endpoints that take it: NewHolidaysByExchangeQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewHolidaysByExchangeQuery

func NewHolidaysByExchangeQuery(exchange string) HolidaysByExchangeQuery

NewHolidaysByExchangeQuery creates the query from its required arguments.

func (HolidaysByExchangeQuery) Exchange

func (q HolidaysByExchangeQuery) Exchange() string

Exchange returns the exchange argument as given.

func (HolidaysByExchangeQuery) From

func (q HolidaysByExchangeQuery) From() *Date

From returns the optional from parameter, or nil when it is unset.

func (HolidaysByExchangeQuery) To

func (q HolidaysByExchangeQuery) To() *Date

To returns the optional to parameter, or nil when it is unset.

func (HolidaysByExchangeQuery) WithFrom

WithFrom sets the optional from parameter and returns the updated query.

func (HolidaysByExchangeQuery) WithTo

WithTo sets the optional to parameter and returns the updated query.

type IPOCalendarEvent added in v0.12.0

type IPOCalendarEvent struct {
	Symbol     string          `json:"symbol"`
	Date       Date            `json:"date"`
	Daa        string          `json:"daa"`
	Company    string          `json:"company"`
	Exchange   string          `json:"exchange"`
	Actions    string          `json:"actions"`
	Shares     *jsontext.Value `json:"shares"`
	PriceRange *jsontext.Value `json:"priceRange"`
	MarketCap  *jsontext.Value `json:"marketCap"`
}

IPOCalendarEvent is one worldwide IPO calendar event.

func (*IPOCalendarEvent) UnmarshalJSONFrom added in v0.12.0

func (m *IPOCalendarEvent) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type IPOCalendarQuery added in v0.12.0

type IPOCalendarQuery struct {
	// contains filtered or unexported fields
}

IPOCalendarQuery holds the query parameters of the endpoints that take it: NewIPOCalendarQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewIPOCalendarQuery added in v0.12.0

func NewIPOCalendarQuery() IPOCalendarQuery

NewIPOCalendarQuery creates the query from its required arguments.

func (IPOCalendarQuery) From added in v0.12.0

func (q IPOCalendarQuery) From() *Date

From returns the optional from parameter, or nil when it is unset.

func (IPOCalendarQuery) To added in v0.12.0

func (q IPOCalendarQuery) To() *Date

To returns the optional to parameter, or nil when it is unset.

func (IPOCalendarQuery) WithFrom added in v0.12.0

func (q IPOCalendarQuery) WithFrom(from Date) IPOCalendarQuery

WithFrom sets the optional from parameter and returns the updated query.

func (IPOCalendarQuery) WithTo added in v0.12.0

func (q IPOCalendarQuery) WithTo(to Date) IPOCalendarQuery

WithTo sets the optional to parameter and returns the updated query.

type IPODisclosure added in v0.12.0

type IPODisclosure struct {
	Symbol            string `json:"symbol"`
	FilingDate        Date   `json:"filingDate"`
	AcceptedDate      Date   `json:"acceptedDate"`
	EffectivenessDate Date   `json:"effectivenessDate"`
	CIK               string `json:"cik"`
	Form              string `json:"form"`
	URL               string `json:"url"`
}

IPODisclosure is one US IPO disclosure filing.

func (*IPODisclosure) UnmarshalJSONFrom added in v0.12.0

func (m *IPODisclosure) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type IPODisclosureQuery added in v0.12.0

type IPODisclosureQuery struct {
	// contains filtered or unexported fields
}

IPODisclosureQuery holds the query parameters of the endpoints that take it: NewIPODisclosureQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewIPODisclosureQuery added in v0.12.0

func NewIPODisclosureQuery() IPODisclosureQuery

NewIPODisclosureQuery creates the query from its required arguments.

func (IPODisclosureQuery) From added in v0.12.0

func (q IPODisclosureQuery) From() *Date

From returns the optional from parameter, or nil when it is unset.

func (IPODisclosureQuery) To added in v0.12.0

func (q IPODisclosureQuery) To() *Date

To returns the optional to parameter, or nil when it is unset.

func (IPODisclosureQuery) WithFrom added in v0.12.0

func (q IPODisclosureQuery) WithFrom(from Date) IPODisclosureQuery

WithFrom sets the optional from parameter and returns the updated query.

func (IPODisclosureQuery) WithTo added in v0.12.0

WithTo sets the optional to parameter and returns the updated query.

type IPOProspectus added in v0.12.0

type IPOProspectus struct {
	Symbol                          string  `json:"symbol"`
	AcceptedDate                    Date    `json:"acceptedDate"`
	FilingDate                      Date    `json:"filingDate"`
	IPODate                         Date    `json:"ipoDate"`
	CIK                             string  `json:"cik"`
	PricePublicPerShare             float64 `json:"pricePublicPerShare"`
	PricePublicTotal                float64 `json:"pricePublicTotal"`
	DiscountsAndCommissionsPerShare float64 `json:"discountsAndCommissionsPerShare"`
	DiscountsAndCommissionsTotal    float64 `json:"discountsAndCommissionsTotal"`
	ProceedsBeforeExpensesPerShare  float64 `json:"proceedsBeforeExpensesPerShare"`
	ProceedsBeforeExpensesTotal     float64 `json:"proceedsBeforeExpensesTotal"`
	Form                            string  `json:"form"`
	URL                             string  `json:"url"`
}

IPOProspectus is one US IPO prospectus filing and its documented offering values.

func (*IPOProspectus) UnmarshalJSONFrom added in v0.12.0

func (m *IPOProspectus) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type IPOProspectusQuery added in v0.12.0

type IPOProspectusQuery struct {
	// contains filtered or unexported fields
}

IPOProspectusQuery holds the query parameters of the endpoints that take it: NewIPOProspectusQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewIPOProspectusQuery added in v0.12.0

func NewIPOProspectusQuery() IPOProspectusQuery

NewIPOProspectusQuery creates the query from its required arguments.

func (IPOProspectusQuery) From added in v0.12.0

func (q IPOProspectusQuery) From() *Date

From returns the optional from parameter, or nil when it is unset.

func (IPOProspectusQuery) To added in v0.12.0

func (q IPOProspectusQuery) To() *Date

To returns the optional to parameter, or nil when it is unset.

func (IPOProspectusQuery) WithFrom added in v0.12.0

func (q IPOProspectusQuery) WithFrom(from Date) IPOProspectusQuery

WithFrom sets the optional from parameter and returns the updated query.

func (IPOProspectusQuery) WithTo added in v0.12.0

WithTo sets the optional to parameter and returns the updated query.

type ISINSearchQuery added in v0.12.0

type ISINSearchQuery struct {
	// contains filtered or unexported fields
}

ISINSearchQuery holds the query parameters of the endpoints that take it: NewISINSearchQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewISINSearchQuery added in v0.12.0

func NewISINSearchQuery(isin string) ISINSearchQuery

NewISINSearchQuery creates the query from its required arguments.

func (ISINSearchQuery) ISIN added in v0.12.0

func (q ISINSearchQuery) ISIN() string

ISIN returns the isin argument as given.

type ISINSearchResult added in v0.12.0

type ISINSearchResult struct {
	Symbol    string  `json:"symbol"`
	Name      string  `json:"name"`
	ISIN      string  `json:"isin"`
	MarketCap float64 `json:"marketCap"`
}

ISINSearchResult is a security returned by ISIN search.

func (*ISINSearchResult) UnmarshalJSONFrom added in v0.12.0

func (m *ISINSearchResult) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type IncomeStatement

type IncomeStatement struct {
	Date                                    Date     `json:"date"`
	Symbol                                  string   `json:"symbol"`
	ReportedCurrency                        string   `json:"reportedCurrency"`
	CIK                                     string   `json:"cik"`
	FilingDate                              Date     `json:"filingDate"`
	AcceptedDate                            DateTime `json:"acceptedDate"`
	FiscalYear                              string   `json:"fiscalYear"`
	Period                                  string   `json:"period"`
	Revenue                                 float64  `json:"revenue"`
	CostOfRevenue                           float64  `json:"costOfRevenue"`
	GrossProfit                             float64  `json:"grossProfit"`
	ResearchAndDevelopmentExpenses          float64  `json:"researchAndDevelopmentExpenses"`
	GeneralAndAdministrativeExpenses        float64  `json:"generalAndAdministrativeExpenses"`
	SellingAndMarketingExpenses             float64  `json:"sellingAndMarketingExpenses"`
	SellingGeneralAndAdministrativeExpenses float64  `json:"sellingGeneralAndAdministrativeExpenses"`
	OtherExpenses                           float64  `json:"otherExpenses"`
	OperatingExpenses                       float64  `json:"operatingExpenses"`
	CostAndExpenses                         float64  `json:"costAndExpenses"`
	NetInterestIncome                       float64  `json:"netInterestIncome"`
	InterestIncome                          float64  `json:"interestIncome"`
	InterestExpense                         float64  `json:"interestExpense"`
	DepreciationAndAmortization             float64  `json:"depreciationAndAmortization"`
	Ebitda                                  float64  `json:"ebitda"`
	Ebit                                    float64  `json:"ebit"`
	NonOperatingIncomeExcludingInterest     float64  `json:"nonOperatingIncomeExcludingInterest"`
	OperatingIncome                         float64  `json:"operatingIncome"`
	TotalOtherIncomeExpensesNet             float64  `json:"totalOtherIncomeExpensesNet"`
	IncomeBeforeTax                         float64  `json:"incomeBeforeTax"`
	IncomeTaxExpense                        float64  `json:"incomeTaxExpense"`
	NetIncomeFromContinuingOperations       float64  `json:"netIncomeFromContinuingOperations"`
	NetIncomeFromDiscontinuedOperations     float64  `json:"netIncomeFromDiscontinuedOperations"`
	OtherAdjustmentsToNetIncome             float64  `json:"otherAdjustmentsToNetIncome"`
	NetIncome                               float64  `json:"netIncome"`
	NetIncomeDeductions                     float64  `json:"netIncomeDeductions"`
	BottomLineNetIncome                     float64  `json:"bottomLineNetIncome"`
	EPS                                     float64  `json:"eps"`
	EPSDiluted                              float64  `json:"epsDiluted"`
	WeightedAverageShsOut                   float64  `json:"weightedAverageShsOut"`
	WeightedAverageShsOutDil                float64  `json:"weightedAverageShsOutDil"`
}

IncomeStatement is one historical or trailing-twelve-month worldwide income statement.

func (*IncomeStatement) UnmarshalJSONFrom

func (m *IncomeStatement) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type IncomeStatementAsReportedQuery

type IncomeStatementAsReportedQuery struct {
	// contains filtered or unexported fields
}

IncomeStatementAsReportedQuery holds the query parameters of the endpoints that take it: NewIncomeStatementAsReportedQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewIncomeStatementAsReportedQuery

func NewIncomeStatementAsReportedQuery(symbol string) IncomeStatementAsReportedQuery

NewIncomeStatementAsReportedQuery creates the query from its required arguments.

func (IncomeStatementAsReportedQuery) Limit

Limit returns the optional limit parameter, or nil when it is unset.

func (IncomeStatementAsReportedQuery) Period

Period returns the optional period parameter, or nil when it is unset.

func (IncomeStatementAsReportedQuery) Symbol

Symbol returns the symbol argument as given.

func (IncomeStatementAsReportedQuery) WithLimit

WithLimit sets the optional limit parameter and returns the updated query.

func (IncomeStatementAsReportedQuery) WithPeriod

WithPeriod sets the optional period parameter and returns the updated query.

type IncomeStatementGrowth

type IncomeStatementGrowth struct {
	Symbol                                    string  `json:"symbol"`
	Date                                      Date    `json:"date"`
	FiscalYear                                string  `json:"fiscalYear"`
	Period                                    string  `json:"period"`
	ReportedCurrency                          string  `json:"reportedCurrency"`
	GrowthRevenue                             float64 `json:"growthRevenue"`
	GrowthCostOfRevenue                       float64 `json:"growthCostOfRevenue"`
	GrowthGrossProfit                         float64 `json:"growthGrossProfit"`
	GrowthGrossProfitRatio                    float64 `json:"growthGrossProfitRatio"`
	GrowthResearchAndDevelopmentExpenses      float64 `json:"growthResearchAndDevelopmentExpenses"`
	GrowthGeneralAndAdministrativeExpenses    float64 `json:"growthGeneralAndAdministrativeExpenses"`
	GrowthSellingAndMarketingExpenses         float64 `json:"growthSellingAndMarketingExpenses"`
	GrowthOtherExpenses                       float64 `json:"growthOtherExpenses"`
	GrowthOperatingExpenses                   float64 `json:"growthOperatingExpenses"`
	GrowthCostAndExpenses                     float64 `json:"growthCostAndExpenses"`
	GrowthInterestIncome                      float64 `json:"growthInterestIncome"`
	GrowthInterestExpense                     float64 `json:"growthInterestExpense"`
	GrowthDepreciationAndAmortization         float64 `json:"growthDepreciationAndAmortization"`
	GrowthEbitda                              float64 `json:"growthEBITDA"`
	GrowthOperatingIncome                     float64 `json:"growthOperatingIncome"`
	GrowthIncomeBeforeTax                     float64 `json:"growthIncomeBeforeTax"`
	GrowthIncomeTaxExpense                    float64 `json:"growthIncomeTaxExpense"`
	GrowthNetIncome                           float64 `json:"growthNetIncome"`
	GrowthEPS                                 float64 `json:"growthEPS"`
	GrowthEPSDiluted                          float64 `json:"growthEPSDiluted"`
	GrowthWeightedAverageShsOut               float64 `json:"growthWeightedAverageShsOut"`
	GrowthWeightedAverageShsOutDil            float64 `json:"growthWeightedAverageShsOutDil"`
	GrowthEbit                                float64 `json:"growthEBIT"`
	GrowthNonOperatingIncomeExcludingInterest float64 `json:"growthNonOperatingIncomeExcludingInterest"`
	GrowthNetInterestIncome                   float64 `json:"growthNetInterestIncome"`
	GrowthTotalOtherIncomeExpensesNet         float64 `json:"growthTotalOtherIncomeExpensesNet"`
	GrowthNetIncomeFromContinuingOperations   float64 `json:"growthNetIncomeFromContinuingOperations"`
	GrowthOtherAdjustmentsToNetIncome         float64 `json:"growthOtherAdjustmentsToNetIncome"`
	GrowthNetIncomeDeductions                 float64 `json:"growthNetIncomeDeductions"`
}

IncomeStatementGrowth is one worldwide income-statement-growth row.

func (*IncomeStatementGrowth) UnmarshalJSONFrom

func (m *IncomeStatementGrowth) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type IncomeStatementGrowthQuery

type IncomeStatementGrowthQuery struct {
	// contains filtered or unexported fields
}

IncomeStatementGrowthQuery holds the query parameters of the endpoints that take it: NewIncomeStatementGrowthQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewIncomeStatementGrowthQuery

func NewIncomeStatementGrowthQuery(symbol string) IncomeStatementGrowthQuery

NewIncomeStatementGrowthQuery creates the query from its required arguments.

func (IncomeStatementGrowthQuery) Limit

Limit returns the optional limit parameter, or nil when it is unset.

func (IncomeStatementGrowthQuery) Period

Period returns the optional period parameter, or nil when it is unset.

func (IncomeStatementGrowthQuery) Symbol

Symbol returns the symbol argument as given.

func (IncomeStatementGrowthQuery) WithLimit

WithLimit sets the optional limit parameter and returns the updated query.

func (IncomeStatementGrowthQuery) WithPeriod

WithPeriod sets the optional period parameter and returns the updated query.

type IncomeStatementQuery

type IncomeStatementQuery struct {
	// contains filtered or unexported fields
}

IncomeStatementQuery holds the query parameters of the endpoints that take it: NewIncomeStatementQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewIncomeStatementQuery

func NewIncomeStatementQuery(symbol string) IncomeStatementQuery

NewIncomeStatementQuery creates the query from its required arguments.

func (IncomeStatementQuery) Limit

func (q IncomeStatementQuery) Limit() *uint32

Limit returns the optional limit parameter, or nil when it is unset.

func (IncomeStatementQuery) Period

Period returns the optional period parameter, or nil when it is unset.

func (IncomeStatementQuery) Symbol

func (q IncomeStatementQuery) Symbol() string

Symbol returns the symbol argument as given.

func (IncomeStatementQuery) WithLimit

WithLimit sets the optional limit parameter and returns the updated query.

func (IncomeStatementQuery) WithPeriod

WithPeriod sets the optional period parameter and returns the updated query.

type IncomeStatementTTMQuery added in v0.12.0

type IncomeStatementTTMQuery struct {
	// contains filtered or unexported fields
}

IncomeStatementTTMQuery holds the query parameters of the endpoints that take it: NewIncomeStatementTTMQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewIncomeStatementTTMQuery added in v0.12.0

func NewIncomeStatementTTMQuery(symbol string) IncomeStatementTTMQuery

NewIncomeStatementTTMQuery creates the query from its required arguments.

func (IncomeStatementTTMQuery) Limit added in v0.12.0

func (q IncomeStatementTTMQuery) Limit() *uint32

Limit returns the optional limit parameter, or nil when it is unset.

func (IncomeStatementTTMQuery) Symbol added in v0.12.0

func (q IncomeStatementTTMQuery) Symbol() string

Symbol returns the symbol argument as given.

func (IncomeStatementTTMQuery) WithLimit added in v0.12.0

WithLimit sets the optional limit parameter and returns the updated query.

type IndexChartQuery

type IndexChartQuery struct {
	// contains filtered or unexported fields
}

IndexChartQuery holds the query parameters of the endpoints that take it: NewIndexChartQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewIndexChartQuery

func NewIndexChartQuery(symbol string) IndexChartQuery

NewIndexChartQuery creates the query from its required arguments.

func (IndexChartQuery) From

func (q IndexChartQuery) From() *Date

From returns the optional from parameter, or nil when it is unset.

func (IndexChartQuery) Symbol

func (q IndexChartQuery) Symbol() string

Symbol returns the symbol argument as given.

func (IndexChartQuery) To

func (q IndexChartQuery) To() *Date

To returns the optional to parameter, or nil when it is unset.

func (IndexChartQuery) WithFrom

func (q IndexChartQuery) WithFrom(from Date) IndexChartQuery

WithFrom sets the optional from parameter and returns the updated query.

func (IndexChartQuery) WithTo

func (q IndexChartQuery) WithTo(to Date) IndexChartQuery

WithTo sets the optional to parameter and returns the updated query.

type IndexConstituent

type IndexConstituent struct {
	Symbol         string `json:"symbol"`
	Name           string `json:"name"`
	Sector         string `json:"sector"`
	SubSector      string `json:"subSector"`
	HeadQuarter    string `json:"headQuarter"`
	DateFirstAdded *Date  `json:"dateFirstAdded"`
	CIK            string `json:"cik"`
	Founded        Date   `json:"founded"`
}

IndexConstituent is one company currently included in a major US stock-market index.

func (*IndexConstituent) UnmarshalJSONFrom

func (m *IndexConstituent) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type IndexListing

type IndexListing struct {
	Symbol   string `json:"symbol"`
	Name     string `json:"name"`
	Exchange string `json:"exchange"`
	Currency string `json:"currency"`
}

IndexListing is one stock-market index in the provider's worldwide index directory.

func (*IndexListing) UnmarshalJSONFrom

func (m *IndexListing) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type IndexesNamespace

type IndexesNamespace struct {
	// contains filtered or unexported fields
}

IndexesNamespace groups the indexes endpoints. It is reached as Client.Indexes and is valid only when obtained from a Client built by NewClient.

func (*IndexesNamespace) ChartFiveMinutes

ChartFiveMinutes retrieves five-minute history for one stock-market index.

GET historical-chart/5min?symbol=&from=&to=

func (*IndexesNamespace) ChartFull

ChartFull retrieves detailed end-of-day history for one stock-market index.

GET historical-price-eod/full?symbol=&from=&to=

func (*IndexesNamespace) ChartLight

ChartLight retrieves compact end-of-day history for one stock-market index.

GET historical-price-eod/light?symbol=&from=&to=

func (*IndexesNamespace) ChartOneHour

ChartOneHour retrieves one-hour history for one stock-market index.

GET historical-chart/1hour?symbol=&from=&to=

func (*IndexesNamespace) ChartOneMinute

ChartOneMinute retrieves one-minute history for one stock-market index.

GET historical-chart/1min?symbol=&from=&to=

func (*IndexesNamespace) DowJonesConstituents

func (n *IndexesNamespace) DowJonesConstituents(ctx context.Context) ([]IndexConstituent, error)

DowJonesConstituents lists the current Dow Jones constituents.

GET dowjones-constituent

func (*IndexesNamespace) HistoricalDowJonesConstituents

func (n *IndexesNamespace) HistoricalDowJonesConstituents(ctx context.Context) ([]HistoricalIndexConstituent, error)

HistoricalDowJonesConstituents lists historical Dow Jones constituent changes.

GET historical-dowjones-constituent

func (*IndexesNamespace) HistoricalNasdaqConstituents

func (n *IndexesNamespace) HistoricalNasdaqConstituents(ctx context.Context) ([]HistoricalIndexConstituent, error)

HistoricalNasdaqConstituents lists historical Nasdaq constituent changes.

GET historical-nasdaq-constituent

func (*IndexesNamespace) HistoricalSP500Constituents added in v0.12.0

func (n *IndexesNamespace) HistoricalSP500Constituents(ctx context.Context) ([]HistoricalIndexConstituent, error)

HistoricalSP500Constituents lists historical S&P 500 constituent changes.

GET historical-sp500-constituent

func (*IndexesNamespace) List

List lists worldwide stock-market indexes.

GET index-list

func (*IndexesNamespace) NasdaqConstituents

func (n *IndexesNamespace) NasdaqConstituents(ctx context.Context) ([]IndexConstituent, error)

NasdaqConstituents lists the current Nasdaq constituents.

GET nasdaq-constituent

func (*IndexesNamespace) Quote

func (n *IndexesNamespace) Quote(ctx context.Context, q QuoteQuery) ([]Quote, error)

Quote retrieves a detailed quote for one stock-market index.

GET quote?symbol=

func (*IndexesNamespace) QuoteShort

func (n *IndexesNamespace) QuoteShort(ctx context.Context, q QuoteShortQuery) ([]QuoteShort, error)

QuoteShort retrieves a compact quote for one stock-market index.

GET quote-short?symbol=

func (*IndexesNamespace) SP500Constituents added in v0.12.0

func (n *IndexesNamespace) SP500Constituents(ctx context.Context) ([]IndexConstituent, error)

SP500Constituents lists the current S&P 500 constituents.

GET sp500-constituent

type IndustryClassificationSearchQuery

type IndustryClassificationSearchQuery struct {
	// contains filtered or unexported fields
}

IndustryClassificationSearchQuery holds the query parameters of the endpoints that take it: NewIndustryClassificationSearchQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewIndustryClassificationSearchQuery

func NewIndustryClassificationSearchQuery() IndustryClassificationSearchQuery

NewIndustryClassificationSearchQuery creates the query from its required arguments.

func (IndustryClassificationSearchQuery) CIK added in v0.12.0

CIK returns the optional cik parameter, or nil when it is unset.

func (IndustryClassificationSearchQuery) SicCode

SicCode returns the optional sic_code parameter, or nil when it is unset.

func (IndustryClassificationSearchQuery) Symbol

Symbol returns the optional symbol parameter, or nil when it is unset.

func (IndustryClassificationSearchQuery) WithCIK added in v0.12.0

WithCIK sets the optional cik parameter and returns the updated query.

func (IndustryClassificationSearchQuery) WithSicCode

WithSicCode sets the optional sic_code parameter and returns the updated query.

func (IndustryClassificationSearchQuery) WithSymbol

WithSymbol sets the optional symbol parameter and returns the updated query.

type IndustryClassificationsQuery

type IndustryClassificationsQuery struct {
	// contains filtered or unexported fields
}

IndustryClassificationsQuery holds the query parameters of the endpoints that take it: NewIndustryClassificationsQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewIndustryClassificationsQuery

func NewIndustryClassificationsQuery() IndustryClassificationsQuery

NewIndustryClassificationsQuery creates the query from its required arguments.

func (IndustryClassificationsQuery) IndustryTitle

func (q IndustryClassificationsQuery) IndustryTitle() *string

IndustryTitle returns the optional industry_title parameter, or nil when it is unset.

func (IndustryClassificationsQuery) SicCode

func (q IndustryClassificationsQuery) SicCode() *string

SicCode returns the optional sic_code parameter, or nil when it is unset.

func (IndustryClassificationsQuery) WithIndustryTitle

func (q IndustryClassificationsQuery) WithIndustryTitle(industryTitle string) IndustryClassificationsQuery

WithIndustryTitle sets the optional industry_title parameter and returns the updated query.

func (IndustryClassificationsQuery) WithSicCode

WithSicCode sets the optional sic_code parameter and returns the updated query.

type IndustryPe

type IndustryPe struct {
	Date     Date    `json:"date"`
	Industry string  `json:"industry"`
	Exchange string  `json:"exchange"`
	Pe       float64 `json:"pe"`
}

IndustryPe is one dated industry-level price-to-earnings ratio.

func (*IndustryPe) UnmarshalJSONFrom

func (m *IndustryPe) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type IndustryPeSnapshotQuery

type IndustryPeSnapshotQuery struct {
	// contains filtered or unexported fields
}

IndustryPeSnapshotQuery holds the query parameters of the endpoints that take it: NewIndustryPeSnapshotQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewIndustryPeSnapshotQuery

func NewIndustryPeSnapshotQuery(date Date) IndustryPeSnapshotQuery

NewIndustryPeSnapshotQuery creates the query from its required arguments.

func (IndustryPeSnapshotQuery) Date

func (q IndustryPeSnapshotQuery) Date() Date

Date returns the date argument as given.

func (IndustryPeSnapshotQuery) Exchange

func (q IndustryPeSnapshotQuery) Exchange() *string

Exchange returns the optional exchange parameter, or nil when it is unset.

func (IndustryPeSnapshotQuery) Industry

func (q IndustryPeSnapshotQuery) Industry() *string

Industry returns the optional industry parameter, or nil when it is unset.

func (IndustryPeSnapshotQuery) WithExchange

func (q IndustryPeSnapshotQuery) WithExchange(exchange string) IndustryPeSnapshotQuery

WithExchange sets the optional exchange parameter and returns the updated query.

func (IndustryPeSnapshotQuery) WithIndustry

func (q IndustryPeSnapshotQuery) WithIndustry(industry string) IndustryPeSnapshotQuery

WithIndustry sets the optional industry parameter and returns the updated query.

type IndustryPerformance

type IndustryPerformance struct {
	Date          Date    `json:"date"`
	Industry      string  `json:"industry"`
	Exchange      string  `json:"exchange"`
	AverageChange float64 `json:"averageChange"`
}

IndustryPerformance is one dated industry-level average market change.

func (*IndustryPerformance) UnmarshalJSONFrom

func (m *IndustryPerformance) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type IndustryPerformanceSnapshotQuery

type IndustryPerformanceSnapshotQuery struct {
	// contains filtered or unexported fields
}

IndustryPerformanceSnapshotQuery holds the query parameters of the endpoints that take it: NewIndustryPerformanceSnapshotQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewIndustryPerformanceSnapshotQuery

func NewIndustryPerformanceSnapshotQuery(date Date) IndustryPerformanceSnapshotQuery

NewIndustryPerformanceSnapshotQuery creates the query from its required arguments.

func (IndustryPerformanceSnapshotQuery) Date

Date returns the date argument as given.

func (IndustryPerformanceSnapshotQuery) Exchange

Exchange returns the optional exchange parameter, or nil when it is unset.

func (IndustryPerformanceSnapshotQuery) Industry

Industry returns the optional industry parameter, or nil when it is unset.

func (IndustryPerformanceSnapshotQuery) WithExchange

WithExchange sets the optional exchange parameter and returns the updated query.

func (IndustryPerformanceSnapshotQuery) WithIndustry

WithIndustry sets the optional industry parameter and returns the updated query.

type InsiderReportingName

type InsiderReportingName struct {
	ReportingCIK  string `json:"reportingCik"`
	ReportingName string `json:"reportingName"`
}

InsiderReportingName is one reporting-person identity returned by reporting-name search.

func (*InsiderReportingName) UnmarshalJSONFrom

func (m *InsiderReportingName) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type InsiderReportingNameSearchQuery

type InsiderReportingNameSearchQuery struct {
	// contains filtered or unexported fields
}

InsiderReportingNameSearchQuery holds the query parameters of the endpoints that take it: NewInsiderReportingNameSearchQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewInsiderReportingNameSearchQuery

func NewInsiderReportingNameSearchQuery(name string) InsiderReportingNameSearchQuery

NewInsiderReportingNameSearchQuery creates the query from its required arguments.

func (InsiderReportingNameSearchQuery) Name

Name returns the name argument as given.

type InsiderTrade

type InsiderTrade struct {
	Symbol                   string  `json:"symbol"`
	FilingDate               Date    `json:"filingDate"`
	TransactionDate          Date    `json:"transactionDate"`
	ReportingCIK             string  `json:"reportingCik"`
	CompanyCIK               string  `json:"companyCik"`
	TransactionType          string  `json:"transactionType"`
	SecuritiesOwned          float64 `json:"securitiesOwned"`
	ReportingName            string  `json:"reportingName"`
	TypeOfOwner              string  `json:"typeOfOwner"`
	AcquisitionOrDisposition string  `json:"acquisitionOrDisposition"`
	DirectOrIndirect         string  `json:"directOrIndirect"`
	FormType                 string  `json:"formType"`
	SecuritiesTransacted     float64 `json:"securitiesTransacted"`
	Price                    float64 `json:"price"`
	SecurityName             string  `json:"securityName"`
	URL                      string  `json:"url"`
}

InsiderTrade is one insider trade shared by the latest and search feeds.

func (*InsiderTrade) UnmarshalJSONFrom

func (m *InsiderTrade) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type InsiderTradeStatistics

type InsiderTradeStatistics struct {
	Symbol                string  `json:"symbol"`
	CIK                   string  `json:"cik"`
	Year                  uint32  `json:"year"`
	Quarter               uint8   `json:"quarter"`
	AcquiredTransactions  uint64  `json:"acquiredTransactions"`
	DisposedTransactions  uint64  `json:"disposedTransactions"`
	AcquiredDisposedRatio float64 `json:"acquiredDisposedRatio"`
	TotalAcquired         float64 `json:"totalAcquired"`
	TotalDisposed         float64 `json:"totalDisposed"`
	AverageAcquired       float64 `json:"averageAcquired"`
	AverageDisposed       float64 `json:"averageDisposed"`
	TotalPurchases        uint64  `json:"totalPurchases"`
	TotalSales            uint64  `json:"totalSales"`
}

InsiderTradeStatistics is one quarterly aggregate of insider-trade activity.

func (*InsiderTradeStatistics) UnmarshalJSONFrom

func (m *InsiderTradeStatistics) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type InsiderTradeStatisticsQuery

type InsiderTradeStatisticsQuery struct {
	// contains filtered or unexported fields
}

InsiderTradeStatisticsQuery holds the query parameters of the endpoints that take it: NewInsiderTradeStatisticsQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewInsiderTradeStatisticsQuery

func NewInsiderTradeStatisticsQuery(symbol string) InsiderTradeStatisticsQuery

NewInsiderTradeStatisticsQuery creates the query from its required arguments.

func (InsiderTradeStatisticsQuery) Symbol

Symbol returns the symbol argument as given.

type InsiderTradesSearchQuery

type InsiderTradesSearchQuery struct {
	// contains filtered or unexported fields
}

InsiderTradesSearchQuery holds the query parameters of the endpoints that take it: NewInsiderTradesSearchQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewInsiderTradesSearchQuery

func NewInsiderTradesSearchQuery() InsiderTradesSearchQuery

NewInsiderTradesSearchQuery creates the query from its required arguments.

func (InsiderTradesSearchQuery) CompanyCIK added in v0.12.0

func (q InsiderTradesSearchQuery) CompanyCIK() *string

CompanyCIK returns the optional company_cik parameter, or nil when it is unset.

func (InsiderTradesSearchQuery) Limit

func (q InsiderTradesSearchQuery) Limit() *uint32

Limit returns the optional limit parameter, or nil when it is unset.

func (InsiderTradesSearchQuery) Page

func (q InsiderTradesSearchQuery) Page() *uint32

Page returns the optional page parameter, or nil when it is unset.

func (InsiderTradesSearchQuery) ReportingCIK added in v0.12.0

func (q InsiderTradesSearchQuery) ReportingCIK() *string

ReportingCIK returns the optional reporting_cik parameter, or nil when it is unset.

func (InsiderTradesSearchQuery) Symbol

func (q InsiderTradesSearchQuery) Symbol() *string

Symbol returns the optional symbol parameter, or nil when it is unset.

func (InsiderTradesSearchQuery) TransactionType

func (q InsiderTradesSearchQuery) TransactionType() *string

TransactionType returns the optional transaction_type parameter, or nil when it is unset.

func (InsiderTradesSearchQuery) WithCompanyCIK added in v0.12.0

func (q InsiderTradesSearchQuery) WithCompanyCIK(companyCIK string) InsiderTradesSearchQuery

WithCompanyCIK sets the optional company_cik parameter and returns the updated query.

func (InsiderTradesSearchQuery) WithLimit

WithLimit sets the optional limit parameter and returns the updated query.

func (InsiderTradesSearchQuery) WithPage

WithPage sets the optional page parameter and returns the updated query.

func (InsiderTradesSearchQuery) WithReportingCIK added in v0.12.0

func (q InsiderTradesSearchQuery) WithReportingCIK(reportingCIK string) InsiderTradesSearchQuery

WithReportingCIK sets the optional reporting_cik parameter and returns the updated query.

func (InsiderTradesSearchQuery) WithSymbol

WithSymbol sets the optional symbol parameter and returns the updated query.

func (InsiderTradesSearchQuery) WithTransactionType

func (q InsiderTradesSearchQuery) WithTransactionType(transactionType string) InsiderTradesSearchQuery

WithTransactionType sets the optional transaction_type parameter and returns the updated query.

type InsiderTradingNamespace

type InsiderTradingNamespace struct {
	// contains filtered or unexported fields
}

InsiderTradingNamespace groups the insider_trading endpoints. It is reached as Client.InsiderTrading and is valid only when obtained from a Client built by NewClient.

func (*InsiderTradingNamespace) BeneficialOwnershipAcquisitions

BeneficialOwnershipAcquisitions retrieves US beneficial-ownership acquisition filings for one ticker.

GET acquisition-of-beneficial-ownership?symbol=&limit=

func (*InsiderTradingNamespace) LatestTrades

LatestTrades retrieves the latest US insider trades with optional date and pagination filters.

GET insider-trading/latest?date=&page=&limit=

func (*InsiderTradingNamespace) SearchReportingNames

SearchReportingNames searches US insider-reporting identities by name.

GET insider-trading/reporting-name?name=

func (*InsiderTradingNamespace) SearchTrades

SearchTrades searches US insider trades using independently optional filters.

GET insider-trading/search?symbol=&page=&limit=&reportingCik=&companyCik=&transactionType=

func (*InsiderTradingNamespace) TradeStatistics

TradeStatistics retrieves quarterly US insider-trade statistics for one ticker.

GET insider-trading/statistics?symbol=

func (*InsiderTradingNamespace) TransactionTypes

func (n *InsiderTradingNamespace) TransactionTypes(ctx context.Context) ([]InsiderTransactionType, error)

TransactionTypes retrieves the US insider transaction-type taxonomy.

GET insider-trading-transaction-type

type InsiderTransactionType

type InsiderTransactionType struct {
	TransactionType string `json:"transactionType"`
}

InsiderTransactionType is one open insider transaction-type taxonomy entry.

func (*InsiderTransactionType) UnmarshalJSONFrom

func (m *InsiderTransactionType) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type InstitutionalHolderAnalytics

type InstitutionalHolderAnalytics struct {
	Date                           Date    `json:"date"`
	CIK                            string  `json:"cik"`
	FilingDate                     Date    `json:"filingDate"`
	InvestorName                   string  `json:"investorName"`
	Symbol                         string  `json:"symbol"`
	SecurityName                   string  `json:"securityName"`
	TypeOfSecurity                 string  `json:"typeOfSecurity"`
	SecurityCUSIP                  string  `json:"securityCusip"`
	SharesType                     string  `json:"sharesType"`
	PutCallShare                   string  `json:"putCallShare"`
	InvestmentDiscretion           string  `json:"investmentDiscretion"`
	IndustryTitle                  string  `json:"industryTitle"`
	Weight                         float64 `json:"weight"`
	LastWeight                     float64 `json:"lastWeight"`
	ChangeInWeight                 float64 `json:"changeInWeight"`
	ChangeInWeightPercentage       float64 `json:"changeInWeightPercentage"`
	MarketValue                    float64 `json:"marketValue"`
	LastMarketValue                float64 `json:"lastMarketValue"`
	ChangeInMarketValue            float64 `json:"changeInMarketValue"`
	ChangeInMarketValuePercentage  float64 `json:"changeInMarketValuePercentage"`
	SharesNumber                   float64 `json:"sharesNumber"`
	LastSharesNumber               float64 `json:"lastSharesNumber"`
	ChangeInSharesNumber           float64 `json:"changeInSharesNumber"`
	ChangeInSharesNumberPercentage float64 `json:"changeInSharesNumberPercentage"`
	QuarterEndPrice                float64 `json:"quarterEndPrice"`
	AvgPricePaid                   float64 `json:"avgPricePaid"`
	IsNew                          bool    `json:"isNew"`
	IsSoldOut                      bool    `json:"isSoldOut"`
	Ownership                      float64 `json:"ownership"`
	LastOwnership                  float64 `json:"lastOwnership"`
	ChangeInOwnership              float64 `json:"changeInOwnership"`
	ChangeInOwnershipPercentage    float64 `json:"changeInOwnershipPercentage"`
	HoldingPeriod                  uint64  `json:"holdingPeriod"`
	FirstAdded                     Date    `json:"firstAdded"`
	Performance                    float64 `json:"performance"`
	PerformancePercentage          float64 `json:"performancePercentage"`
	LastPerformance                float64 `json:"lastPerformance"`
	ChangeInPerformance            float64 `json:"changeInPerformance"`
	IsCountedForPerformance        bool    `json:"isCountedForPerformance"`
}

InstitutionalHolderAnalytics is one holder's analytical position in a security for a filing period.

func (*InstitutionalHolderAnalytics) UnmarshalJSONFrom

func (m *InstitutionalHolderAnalytics) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type InstitutionalHolderAnalyticsQuery

type InstitutionalHolderAnalyticsQuery struct {
	// contains filtered or unexported fields
}

InstitutionalHolderAnalyticsQuery holds the query parameters of the endpoints that take it: NewInstitutionalHolderAnalyticsQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewInstitutionalHolderAnalyticsQuery

func NewInstitutionalHolderAnalyticsQuery(symbol string, year uint32, quarter Quarter) InstitutionalHolderAnalyticsQuery

NewInstitutionalHolderAnalyticsQuery creates the query from its required arguments.

func (InstitutionalHolderAnalyticsQuery) Limit

Limit returns the optional limit parameter, or nil when it is unset.

func (InstitutionalHolderAnalyticsQuery) Page

Page returns the optional page parameter, or nil when it is unset.

func (InstitutionalHolderAnalyticsQuery) Quarter

Quarter returns the quarter argument as given.

func (InstitutionalHolderAnalyticsQuery) Symbol

Symbol returns the symbol argument as given.

func (InstitutionalHolderAnalyticsQuery) WithLimit

WithLimit sets the optional limit parameter and returns the updated query.

func (InstitutionalHolderAnalyticsQuery) WithPage

WithPage sets the optional page parameter and returns the updated query.

func (InstitutionalHolderAnalyticsQuery) Year

Year returns the year argument as given.

type InstitutionalHolding

type InstitutionalHolding struct {
	Date          Date    `json:"date"`
	FilingDate    Date    `json:"filingDate"`
	AcceptedDate  Date    `json:"acceptedDate"`
	CIK           string  `json:"cik"`
	SecurityCUSIP string  `json:"securityCusip"`
	Symbol        string  `json:"symbol"`
	NameOfIssuer  string  `json:"nameOfIssuer"`
	Shares        float64 `json:"shares"`
	TitleOfClass  string  `json:"titleOfClass"`
	SharesType    string  `json:"sharesType"`
	PutCallShare  string  `json:"putCallShare"`
	Value         float64 `json:"value"`
	Link          string  `json:"link"`
	FinalLink     string  `json:"finalLink"`
}

InstitutionalHolding is one security position extracted from an institutional-ownership filing.

func (*InstitutionalHolding) UnmarshalJSONFrom

func (m *InstitutionalHolding) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type InstitutionalIndustrySummary

type InstitutionalIndustrySummary struct {
	IndustryTitle string  `json:"industryTitle"`
	IndustryValue float64 `json:"industryValue"`
	Date          Date    `json:"date"`
}

InstitutionalIndustrySummary is aggregate value for one US industry and filing date.

func (*InstitutionalIndustrySummary) UnmarshalJSONFrom

func (m *InstitutionalIndustrySummary) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type InstitutionalIndustrySummaryQuery

type InstitutionalIndustrySummaryQuery struct {
	// contains filtered or unexported fields
}

InstitutionalIndustrySummaryQuery holds the query parameters of the endpoints that take it: NewInstitutionalIndustrySummaryQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewInstitutionalIndustrySummaryQuery

func NewInstitutionalIndustrySummaryQuery(year uint32, quarter Quarter) InstitutionalIndustrySummaryQuery

NewInstitutionalIndustrySummaryQuery creates the query from its required arguments.

func (InstitutionalIndustrySummaryQuery) Quarter

Quarter returns the quarter argument as given.

func (InstitutionalIndustrySummaryQuery) Year

Year returns the year argument as given.

type InstitutionalOwnershipExtractQuery

type InstitutionalOwnershipExtractQuery struct {
	// contains filtered or unexported fields
}

InstitutionalOwnershipExtractQuery holds the query parameters of the endpoints that take it: NewInstitutionalOwnershipExtractQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewInstitutionalOwnershipExtractQuery

func NewInstitutionalOwnershipExtractQuery(cik string, year uint32, quarter Quarter) InstitutionalOwnershipExtractQuery

NewInstitutionalOwnershipExtractQuery creates the query from its required arguments.

func (InstitutionalOwnershipExtractQuery) CIK added in v0.12.0

CIK returns the cik argument as given.

func (InstitutionalOwnershipExtractQuery) Quarter

Quarter returns the quarter argument as given.

func (InstitutionalOwnershipExtractQuery) Year

Year returns the year argument as given.

type InstitutionalOwnershipFiling

type InstitutionalOwnershipFiling struct {
	CIK          string   `json:"cik"`
	Name         string   `json:"name"`
	Date         Date     `json:"date"`
	FilingDate   DateTime `json:"filingDate"`
	AcceptedDate DateTime `json:"acceptedDate"`
	FormType     string   `json:"formType"`
	Link         string   `json:"link"`
	FinalLink    string   `json:"finalLink"`
}

InstitutionalOwnershipFiling is one recent institutional-ownership filing.

func (*InstitutionalOwnershipFiling) UnmarshalJSONFrom

func (m *InstitutionalOwnershipFiling) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type InstitutionalOwnershipNamespace

type InstitutionalOwnershipNamespace struct {
	// contains filtered or unexported fields
}

InstitutionalOwnershipNamespace groups the institutional_ownership endpoints. It is reached as Client.InstitutionalOwnership and is valid only when obtained from a Client built by NewClient.

func (*InstitutionalOwnershipNamespace) Extract

Extract extracts the positions from one US institutional-ownership filing period.

GET institutional-ownership/extract?cik=&year=&quarter=

func (*InstitutionalOwnershipNamespace) Form13FFilingDates added in v0.12.0

Form13FFilingDates retrieves available Form 13F filing dates for one US institutional holder.

GET institutional-ownership/dates?cik=

func (*InstitutionalOwnershipNamespace) HolderAnalytics

HolderAnalytics retrieves holder-level analytics for one US security and filing period.

GET institutional-ownership/extract-analytics/holder?symbol=&year=&quarter=&page=&limit=

func (*InstitutionalOwnershipNamespace) HolderIndustryBreakdown

HolderIndustryBreakdown retrieves a US institutional holder's industry breakdown for one period.

GET institutional-ownership/holder-industry-breakdown?cik=&year=&quarter=

func (*InstitutionalOwnershipNamespace) HolderPerformanceSummary

HolderPerformanceSummary retrieves a US institutional holder's portfolio performance summary.

GET institutional-ownership/holder-performance-summary?cik=&page=

func (*InstitutionalOwnershipNamespace) IndustrySummary

IndustrySummary retrieves US institutional industry values for one reporting period.

GET institutional-ownership/industry-summary?year=&quarter=

func (*InstitutionalOwnershipNamespace) LatestFilings

LatestFilings retrieves the latest US institutional-ownership filings.

GET institutional-ownership/latest?page=&limit=

func (*InstitutionalOwnershipNamespace) PositionsSummary

PositionsSummary retrieves the US institutional position summary for one security and period.

GET institutional-ownership/symbol-positions-summary?symbol=&year=&quarter=

type InstitutionalPositionSummary

type InstitutionalPositionSummary struct {
	Symbol                   string  `json:"symbol"`
	CIK                      string  `json:"cik"`
	Date                     Date    `json:"date"`
	InvestorsHolding         uint64  `json:"investorsHolding"`
	LastInvestorsHolding     uint64  `json:"lastInvestorsHolding"`
	InvestorsHoldingChange   int64   `json:"investorsHoldingChange"`
	NumberOf13FShares        float64 `json:"numberOf13Fshares"`
	LastNumberOf13FShares    float64 `json:"lastNumberOf13Fshares"`
	NumberOf13FSharesChange  float64 `json:"numberOf13FsharesChange"`
	TotalInvested            float64 `json:"totalInvested"`
	LastTotalInvested        float64 `json:"lastTotalInvested"`
	TotalInvestedChange      float64 `json:"totalInvestedChange"`
	OwnershipPercent         float64 `json:"ownershipPercent"`
	LastOwnershipPercent     float64 `json:"lastOwnershipPercent"`
	OwnershipPercentChange   float64 `json:"ownershipPercentChange"`
	NewPositions             uint64  `json:"newPositions"`
	LastNewPositions         uint64  `json:"lastNewPositions"`
	NewPositionsChange       int64   `json:"newPositionsChange"`
	IncreasedPositions       uint64  `json:"increasedPositions"`
	LastIncreasedPositions   uint64  `json:"lastIncreasedPositions"`
	IncreasedPositionsChange int64   `json:"increasedPositionsChange"`
	ClosedPositions          uint64  `json:"closedPositions"`
	LastClosedPositions      uint64  `json:"lastClosedPositions"`
	ClosedPositionsChange    int64   `json:"closedPositionsChange"`
	ReducedPositions         uint64  `json:"reducedPositions"`
	LastReducedPositions     uint64  `json:"lastReducedPositions"`
	ReducedPositionsChange   int64   `json:"reducedPositionsChange"`
	TotalCalls               float64 `json:"totalCalls"`
	LastTotalCalls           float64 `json:"lastTotalCalls"`
	TotalCallsChange         float64 `json:"totalCallsChange"`
	TotalPuts                float64 `json:"totalPuts"`
	LastTotalPuts            float64 `json:"lastTotalPuts"`
	TotalPutsChange          float64 `json:"totalPutsChange"`
	PutCallRatio             float64 `json:"putCallRatio"`
	LastPutCallRatio         float64 `json:"lastPutCallRatio"`
	PutCallRatioChange       float64 `json:"putCallRatioChange"`
}

InstitutionalPositionSummary is cross-holder position totals and changes for one security and filing period.

func (*InstitutionalPositionSummary) UnmarshalJSONFrom

func (m *InstitutionalPositionSummary) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type InstitutionalPositionsSummaryQuery

type InstitutionalPositionsSummaryQuery struct {
	// contains filtered or unexported fields
}

InstitutionalPositionsSummaryQuery holds the query parameters of the endpoints that take it: NewInstitutionalPositionsSummaryQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewInstitutionalPositionsSummaryQuery

func NewInstitutionalPositionsSummaryQuery(symbol string, year uint32, quarter Quarter) InstitutionalPositionsSummaryQuery

NewInstitutionalPositionsSummaryQuery creates the query from its required arguments.

func (InstitutionalPositionsSummaryQuery) Quarter

Quarter returns the quarter argument as given.

func (InstitutionalPositionsSummaryQuery) Symbol

Symbol returns the symbol argument as given.

func (InstitutionalPositionsSummaryQuery) Year

Year returns the year argument as given.

type InvalidTemporalValueError

type InvalidTemporalValueError struct {
	// Expected names the wire shape, for example "YYYY-MM-DD date".
	Expected string
}

InvalidTemporalValueError reports a wire value that does not match the exact temporal format of its field. It mirrors InvalidTemporalValue in the Rust crate and never carries the rejected value.

func (*InvalidTemporalValueError) Error

func (e *InvalidTemporalValueError) Error() string

Error returns the same message the Rust crate produces.

type KeyExecutivesQuery

type KeyExecutivesQuery struct {
	// contains filtered or unexported fields
}

KeyExecutivesQuery holds the query parameters of the endpoints that take it: NewKeyExecutivesQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewKeyExecutivesQuery

func NewKeyExecutivesQuery(symbol string) KeyExecutivesQuery

NewKeyExecutivesQuery creates the query from its required arguments.

func (KeyExecutivesQuery) Symbol

func (q KeyExecutivesQuery) Symbol() string

Symbol returns the symbol argument as given.

type KeyMetrics

type KeyMetrics struct {
	Symbol                                 string  `json:"symbol"`
	Date                                   Date    `json:"date"`
	FiscalYear                             string  `json:"fiscalYear"`
	Period                                 string  `json:"period"`
	ReportedCurrency                       string  `json:"reportedCurrency"`
	MarketCap                              float64 `json:"marketCap"`
	EnterpriseValue                        float64 `json:"enterpriseValue"`
	EvToSales                              float64 `json:"evToSales"`
	EvToOperatingCashFlow                  float64 `json:"evToOperatingCashFlow"`
	EvToFreeCashFlow                       float64 `json:"evToFreeCashFlow"`
	EvToEbitda                             float64 `json:"evToEBITDA"`
	NetDebtToEbitda                        float64 `json:"netDebtToEBITDA"`
	CurrentRatio                           float64 `json:"currentRatio"`
	IncomeQuality                          float64 `json:"incomeQuality"`
	GrahamNumber                           float64 `json:"grahamNumber"`
	GrahamNetNet                           float64 `json:"grahamNetNet"`
	TaxBurden                              float64 `json:"taxBurden"`
	InterestBurden                         float64 `json:"interestBurden"`
	WorkingCapital                         float64 `json:"workingCapital"`
	InvestedCapital                        float64 `json:"investedCapital"`
	ReturnOnAssets                         float64 `json:"returnOnAssets"`
	OperatingReturnOnAssets                float64 `json:"operatingReturnOnAssets"`
	ReturnOnTangibleAssets                 float64 `json:"returnOnTangibleAssets"`
	ReturnOnEquity                         float64 `json:"returnOnEquity"`
	ReturnOnInvestedCapital                float64 `json:"returnOnInvestedCapital"`
	ReturnOnCapitalEmployed                float64 `json:"returnOnCapitalEmployed"`
	EarningsYield                          float64 `json:"earningsYield"`
	FreeCashFlowYield                      float64 `json:"freeCashFlowYield"`
	CapexToOperatingCashFlow               float64 `json:"capexToOperatingCashFlow"`
	CapexToDepreciation                    float64 `json:"capexToDepreciation"`
	CapexToRevenue                         float64 `json:"capexToRevenue"`
	SalesGeneralAndAdministrativeToRevenue float64 `json:"salesGeneralAndAdministrativeToRevenue"`
	ResearchAndDevelopementToRevenue       float64 `json:"researchAndDevelopementToRevenue"`
	StockBasedCompensationToRevenue        float64 `json:"stockBasedCompensationToRevenue"`
	IntangiblesToTotalAssets               float64 `json:"intangiblesToTotalAssets"`
	AverageReceivables                     float64 `json:"averageReceivables"`
	AveragePayables                        float64 `json:"averagePayables"`
	AverageInventory                       float64 `json:"averageInventory"`
	DaysOfSalesOutstanding                 float64 `json:"daysOfSalesOutstanding"`
	DaysOfPayablesOutstanding              float64 `json:"daysOfPayablesOutstanding"`
	DaysOfInventoryOutstanding             float64 `json:"daysOfInventoryOutstanding"`
	OperatingCycle                         float64 `json:"operatingCycle"`
	CashConversionCycle                    float64 `json:"cashConversionCycle"`
	FreeCashFlowToEquity                   float64 `json:"freeCashFlowToEquity"`
	FreeCashFlowToFirm                     float64 `json:"freeCashFlowToFirm"`
	TangibleAssetValue                     float64 `json:"tangibleAssetValue"`
	NetCurrentAssetValue                   float64 `json:"netCurrentAssetValue"`
}

KeyMetrics is one historical worldwide key-metrics row.

func (*KeyMetrics) UnmarshalJSONFrom

func (m *KeyMetrics) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type KeyMetricsQuery

type KeyMetricsQuery struct {
	// contains filtered or unexported fields
}

KeyMetricsQuery holds the query parameters of the endpoints that take it: NewKeyMetricsQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewKeyMetricsQuery

func NewKeyMetricsQuery(symbol string) KeyMetricsQuery

NewKeyMetricsQuery creates the query from its required arguments.

func (KeyMetricsQuery) Limit

func (q KeyMetricsQuery) Limit() *uint32

Limit returns the optional limit parameter, or nil when it is unset.

func (KeyMetricsQuery) Period

func (q KeyMetricsQuery) Period() *StatementPeriod

Period returns the optional period parameter, or nil when it is unset.

func (KeyMetricsQuery) Symbol

func (q KeyMetricsQuery) Symbol() string

Symbol returns the symbol argument as given.

func (KeyMetricsQuery) WithLimit

func (q KeyMetricsQuery) WithLimit(limit uint32) KeyMetricsQuery

WithLimit sets the optional limit parameter and returns the updated query.

func (KeyMetricsQuery) WithPeriod

func (q KeyMetricsQuery) WithPeriod(period StatementPeriod) KeyMetricsQuery

WithPeriod sets the optional period parameter and returns the updated query.

type KeyMetricsTTM added in v0.12.0

type KeyMetricsTTM struct {
	Symbol                                    string  `json:"symbol"`
	MarketCap                                 float64 `json:"marketCap"`
	EnterpriseValueTTM                        float64 `json:"enterpriseValueTTM"`
	EvToSalesTTM                              float64 `json:"evToSalesTTM"`
	EvToOperatingCashFlowTTM                  float64 `json:"evToOperatingCashFlowTTM"`
	EvToFreeCashFlowTTM                       float64 `json:"evToFreeCashFlowTTM"`
	EvToEbitdaTTM                             float64 `json:"evToEBITDATTM"`
	NetDebtToEbitdaTTM                        float64 `json:"netDebtToEBITDATTM"`
	CurrentRatioTTM                           float64 `json:"currentRatioTTM"`
	IncomeQualityTTM                          float64 `json:"incomeQualityTTM"`
	GrahamNumberTTM                           float64 `json:"grahamNumberTTM"`
	GrahamNetNetTTM                           float64 `json:"grahamNetNetTTM"`
	TaxBurdenTTM                              float64 `json:"taxBurdenTTM"`
	InterestBurdenTTM                         float64 `json:"interestBurdenTTM"`
	WorkingCapitalTTM                         float64 `json:"workingCapitalTTM"`
	InvestedCapitalTTM                        float64 `json:"investedCapitalTTM"`
	ReturnOnAssetsTTM                         float64 `json:"returnOnAssetsTTM"`
	OperatingReturnOnAssetsTTM                float64 `json:"operatingReturnOnAssetsTTM"`
	ReturnOnTangibleAssetsTTM                 float64 `json:"returnOnTangibleAssetsTTM"`
	ReturnOnEquityTTM                         float64 `json:"returnOnEquityTTM"`
	ReturnOnInvestedCapitalTTM                float64 `json:"returnOnInvestedCapitalTTM"`
	ReturnOnCapitalEmployedTTM                float64 `json:"returnOnCapitalEmployedTTM"`
	EarningsYieldTTM                          float64 `json:"earningsYieldTTM"`
	FreeCashFlowYieldTTM                      float64 `json:"freeCashFlowYieldTTM"`
	CapexToOperatingCashFlowTTM               float64 `json:"capexToOperatingCashFlowTTM"`
	CapexToDepreciationTTM                    float64 `json:"capexToDepreciationTTM"`
	CapexToRevenueTTM                         float64 `json:"capexToRevenueTTM"`
	SalesGeneralAndAdministrativeToRevenueTTM float64 `json:"salesGeneralAndAdministrativeToRevenueTTM"`
	ResearchAndDevelopementToRevenueTTM       float64 `json:"researchAndDevelopementToRevenueTTM"`
	StockBasedCompensationToRevenueTTM        float64 `json:"stockBasedCompensationToRevenueTTM"`
	IntangiblesToTotalAssetsTTM               float64 `json:"intangiblesToTotalAssetsTTM"`
	AverageReceivablesTTM                     float64 `json:"averageReceivablesTTM"`
	AveragePayablesTTM                        float64 `json:"averagePayablesTTM"`
	AverageInventoryTTM                       float64 `json:"averageInventoryTTM"`
	DaysOfSalesOutstandingTTM                 float64 `json:"daysOfSalesOutstandingTTM"`
	DaysOfPayablesOutstandingTTM              float64 `json:"daysOfPayablesOutstandingTTM"`
	DaysOfInventoryOutstandingTTM             float64 `json:"daysOfInventoryOutstandingTTM"`
	OperatingCycleTTM                         float64 `json:"operatingCycleTTM"`
	CashConversionCycleTTM                    float64 `json:"cashConversionCycleTTM"`
	FreeCashFlowToEquityTTM                   float64 `json:"freeCashFlowToEquityTTM"`
	FreeCashFlowToFirmTTM                     float64 `json:"freeCashFlowToFirmTTM"`
	TangibleAssetValueTTM                     float64 `json:"tangibleAssetValueTTM"`
	NetCurrentAssetValueTTM                   float64 `json:"netCurrentAssetValueTTM"`
}

KeyMetricsTTM is one worldwide trailing-twelve-month key-metrics row.

func (*KeyMetricsTTM) UnmarshalJSONFrom added in v0.12.0

func (m *KeyMetricsTTM) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type KeyMetricsTTMQuery added in v0.12.0

type KeyMetricsTTMQuery struct {
	// contains filtered or unexported fields
}

KeyMetricsTTMQuery holds the query parameters of the endpoints that take it: NewKeyMetricsTTMQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewKeyMetricsTTMQuery added in v0.12.0

func NewKeyMetricsTTMQuery(symbol string) KeyMetricsTTMQuery

NewKeyMetricsTTMQuery creates the query from its required arguments.

func (KeyMetricsTTMQuery) Symbol added in v0.12.0

func (q KeyMetricsTTMQuery) Symbol() string

Symbol returns the symbol argument as given.

type Latest8KSECFilingsQuery added in v0.12.0

type Latest8KSECFilingsQuery struct {
	// contains filtered or unexported fields
}

Latest8KSECFilingsQuery holds the query parameters of the endpoints that take it: NewLatest8KSECFilingsQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewLatest8KSECFilingsQuery added in v0.12.0

func NewLatest8KSECFilingsQuery(from Date, to Date) Latest8KSECFilingsQuery

NewLatest8KSECFilingsQuery creates the query from its required arguments.

func (Latest8KSECFilingsQuery) From added in v0.12.0

func (q Latest8KSECFilingsQuery) From() Date

From returns the from argument as given.

func (Latest8KSECFilingsQuery) Limit added in v0.12.0

func (q Latest8KSECFilingsQuery) Limit() *uint32

Limit returns the optional limit parameter, or nil when it is unset.

func (Latest8KSECFilingsQuery) Page added in v0.12.0

func (q Latest8KSECFilingsQuery) Page() *uint32

Page returns the optional page parameter, or nil when it is unset.

func (Latest8KSECFilingsQuery) To added in v0.12.0

To returns the to argument as given.

func (Latest8KSECFilingsQuery) WithLimit added in v0.12.0

WithLimit sets the optional limit parameter and returns the updated query.

func (Latest8KSECFilingsQuery) WithPage added in v0.12.0

WithPage sets the optional page parameter and returns the updated query.

type LatestCongressionalDisclosuresQuery

type LatestCongressionalDisclosuresQuery struct {
	// contains filtered or unexported fields
}

LatestCongressionalDisclosuresQuery holds the query parameters of the endpoints that take it: NewLatestCongressionalDisclosuresQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewLatestCongressionalDisclosuresQuery

func NewLatestCongressionalDisclosuresQuery() LatestCongressionalDisclosuresQuery

NewLatestCongressionalDisclosuresQuery creates the query from its required arguments.

func (LatestCongressionalDisclosuresQuery) Limit

Limit returns the optional limit parameter, or nil when it is unset.

func (LatestCongressionalDisclosuresQuery) Page

Page returns the optional page parameter, or nil when it is unset.

func (LatestCongressionalDisclosuresQuery) WithLimit

WithLimit sets the optional limit parameter and returns the updated query.

func (LatestCongressionalDisclosuresQuery) WithPage

WithPage sets the optional page parameter and returns the updated query.

type LatestCrowdfundingOfferingsQuery

type LatestCrowdfundingOfferingsQuery struct {
	// contains filtered or unexported fields
}

LatestCrowdfundingOfferingsQuery holds the query parameters of the endpoints that take it: NewLatestCrowdfundingOfferingsQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewLatestCrowdfundingOfferingsQuery

func NewLatestCrowdfundingOfferingsQuery() LatestCrowdfundingOfferingsQuery

NewLatestCrowdfundingOfferingsQuery creates the query from its required arguments.

func (LatestCrowdfundingOfferingsQuery) Limit

Limit returns the optional limit parameter, or nil when it is unset.

func (LatestCrowdfundingOfferingsQuery) Page

Page returns the optional page parameter, or nil when it is unset.

func (LatestCrowdfundingOfferingsQuery) WithLimit

WithLimit sets the optional limit parameter and returns the updated query.

func (LatestCrowdfundingOfferingsQuery) WithPage

WithPage sets the optional page parameter and returns the updated query.

type LatestCryptoNewsQuery

type LatestCryptoNewsQuery struct {
	// contains filtered or unexported fields
}

LatestCryptoNewsQuery holds the query parameters of the endpoints that take it: NewLatestCryptoNewsQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewLatestCryptoNewsQuery

func NewLatestCryptoNewsQuery() LatestCryptoNewsQuery

NewLatestCryptoNewsQuery creates the query from its required arguments.

func (LatestCryptoNewsQuery) From

func (q LatestCryptoNewsQuery) From() *Date

From returns the optional from parameter, or nil when it is unset.

func (LatestCryptoNewsQuery) Limit

func (q LatestCryptoNewsQuery) Limit() *uint32

Limit returns the optional limit parameter, or nil when it is unset.

func (LatestCryptoNewsQuery) Page

func (q LatestCryptoNewsQuery) Page() *uint32

Page returns the optional page parameter, or nil when it is unset.

func (LatestCryptoNewsQuery) To

func (q LatestCryptoNewsQuery) To() *Date

To returns the optional to parameter, or nil when it is unset.

func (LatestCryptoNewsQuery) WithFrom

WithFrom sets the optional from parameter and returns the updated query.

func (LatestCryptoNewsQuery) WithLimit

WithLimit sets the optional limit parameter and returns the updated query.

func (LatestCryptoNewsQuery) WithPage

WithPage sets the optional page parameter and returns the updated query.

func (LatestCryptoNewsQuery) WithTo

WithTo sets the optional to parameter and returns the updated query.

type LatestEarningsTranscript

type LatestEarningsTranscript struct {
	Symbol     string `json:"symbol"`
	Period     string `json:"period"`
	FiscalYear uint32 `json:"fiscalYear"`
	Date       Date   `json:"date"`
}

LatestEarningsTranscript is one latest worldwide earnings-transcript metadata row.

func (*LatestEarningsTranscript) UnmarshalJSONFrom

func (m *LatestEarningsTranscript) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type LatestEarningsTranscriptsQuery

type LatestEarningsTranscriptsQuery struct {
	// contains filtered or unexported fields
}

LatestEarningsTranscriptsQuery holds the query parameters of the endpoints that take it: NewLatestEarningsTranscriptsQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewLatestEarningsTranscriptsQuery

func NewLatestEarningsTranscriptsQuery() LatestEarningsTranscriptsQuery

NewLatestEarningsTranscriptsQuery creates the query from its required arguments.

func (LatestEarningsTranscriptsQuery) Limit

Limit returns the optional limit parameter, or nil when it is unset.

func (LatestEarningsTranscriptsQuery) Page

Page returns the optional page parameter, or nil when it is unset.

func (LatestEarningsTranscriptsQuery) WithLimit

WithLimit sets the optional limit parameter and returns the updated query.

func (LatestEarningsTranscriptsQuery) WithPage

WithPage sets the optional page parameter and returns the updated query.

type LatestFinancialStatement

type LatestFinancialStatement struct {
	Symbol       string   `json:"symbol"`
	CalendarYear uint32   `json:"calendarYear"`
	Period       string   `json:"period"`
	Date         Date     `json:"date"`
	DateAdded    DateTime `json:"dateAdded"`
}

LatestFinancialStatement is one recently added financial-statement filing.

func (*LatestFinancialStatement) UnmarshalJSONFrom

func (m *LatestFinancialStatement) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type LatestFinancialStatementsQuery

type LatestFinancialStatementsQuery struct {
	// contains filtered or unexported fields
}

LatestFinancialStatementsQuery holds the query parameters of the endpoints that take it: NewLatestFinancialStatementsQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewLatestFinancialStatementsQuery

func NewLatestFinancialStatementsQuery() LatestFinancialStatementsQuery

NewLatestFinancialStatementsQuery creates the query from its required arguments.

func (LatestFinancialStatementsQuery) Limit

Limit returns the optional limit parameter, or nil when it is unset.

func (LatestFinancialStatementsQuery) Page

Page returns the optional page parameter, or nil when it is unset.

func (LatestFinancialStatementsQuery) WithLimit

WithLimit sets the optional limit parameter and returns the updated query.

func (LatestFinancialStatementsQuery) WithPage

WithPage sets the optional page parameter and returns the updated query.

type LatestForexNewsQuery

type LatestForexNewsQuery struct {
	// contains filtered or unexported fields
}

LatestForexNewsQuery holds the query parameters of the endpoints that take it: NewLatestForexNewsQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewLatestForexNewsQuery

func NewLatestForexNewsQuery() LatestForexNewsQuery

NewLatestForexNewsQuery creates the query from its required arguments.

func (LatestForexNewsQuery) From

func (q LatestForexNewsQuery) From() *Date

From returns the optional from parameter, or nil when it is unset.

func (LatestForexNewsQuery) Limit

func (q LatestForexNewsQuery) Limit() *uint32

Limit returns the optional limit parameter, or nil when it is unset.

func (LatestForexNewsQuery) Page

func (q LatestForexNewsQuery) Page() *uint32

Page returns the optional page parameter, or nil when it is unset.

func (LatestForexNewsQuery) To

func (q LatestForexNewsQuery) To() *Date

To returns the optional to parameter, or nil when it is unset.

func (LatestForexNewsQuery) WithFrom

WithFrom sets the optional from parameter and returns the updated query.

func (LatestForexNewsQuery) WithLimit

WithLimit sets the optional limit parameter and returns the updated query.

func (LatestForexNewsQuery) WithPage

WithPage sets the optional page parameter and returns the updated query.

func (LatestForexNewsQuery) WithTo

WithTo sets the optional to parameter and returns the updated query.

type LatestFundDisclosureHoldersQuery

type LatestFundDisclosureHoldersQuery struct {
	// contains filtered or unexported fields
}

LatestFundDisclosureHoldersQuery holds the query parameters of the endpoints that take it: NewLatestFundDisclosureHoldersQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewLatestFundDisclosureHoldersQuery

func NewLatestFundDisclosureHoldersQuery(symbol string) LatestFundDisclosureHoldersQuery

NewLatestFundDisclosureHoldersQuery creates the query from its required arguments.

func (LatestFundDisclosureHoldersQuery) Symbol

Symbol returns the symbol argument as given.

type LatestGeneralNewsQuery

type LatestGeneralNewsQuery struct {
	// contains filtered or unexported fields
}

LatestGeneralNewsQuery holds the query parameters of the endpoints that take it: NewLatestGeneralNewsQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewLatestGeneralNewsQuery

func NewLatestGeneralNewsQuery() LatestGeneralNewsQuery

NewLatestGeneralNewsQuery creates the query from its required arguments.

func (LatestGeneralNewsQuery) From

func (q LatestGeneralNewsQuery) From() *Date

From returns the optional from parameter, or nil when it is unset.

func (LatestGeneralNewsQuery) Limit

func (q LatestGeneralNewsQuery) Limit() *uint32

Limit returns the optional limit parameter, or nil when it is unset.

func (LatestGeneralNewsQuery) Page

func (q LatestGeneralNewsQuery) Page() *uint32

Page returns the optional page parameter, or nil when it is unset.

func (LatestGeneralNewsQuery) To

func (q LatestGeneralNewsQuery) To() *Date

To returns the optional to parameter, or nil when it is unset.

func (LatestGeneralNewsQuery) WithFrom

WithFrom sets the optional from parameter and returns the updated query.

func (LatestGeneralNewsQuery) WithLimit

WithLimit sets the optional limit parameter and returns the updated query.

func (LatestGeneralNewsQuery) WithPage

WithPage sets the optional page parameter and returns the updated query.

func (LatestGeneralNewsQuery) WithTo

WithTo sets the optional to parameter and returns the updated query.

type LatestInsiderTradesQuery

type LatestInsiderTradesQuery struct {
	// contains filtered or unexported fields
}

LatestInsiderTradesQuery holds the query parameters of the endpoints that take it: NewLatestInsiderTradesQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewLatestInsiderTradesQuery

func NewLatestInsiderTradesQuery() LatestInsiderTradesQuery

NewLatestInsiderTradesQuery creates the query from its required arguments.

func (LatestInsiderTradesQuery) Date

func (q LatestInsiderTradesQuery) Date() *Date

Date returns the optional date parameter, or nil when it is unset.

func (LatestInsiderTradesQuery) Limit

func (q LatestInsiderTradesQuery) Limit() *uint32

Limit returns the optional limit parameter, or nil when it is unset.

func (LatestInsiderTradesQuery) Page

func (q LatestInsiderTradesQuery) Page() *uint32

Page returns the optional page parameter, or nil when it is unset.

func (LatestInsiderTradesQuery) WithDate

WithDate sets the optional date parameter and returns the updated query.

func (LatestInsiderTradesQuery) WithLimit

WithLimit sets the optional limit parameter and returns the updated query.

func (LatestInsiderTradesQuery) WithPage

WithPage sets the optional page parameter and returns the updated query.

type LatestInstitutionalOwnershipFilingsQuery

type LatestInstitutionalOwnershipFilingsQuery struct {
	// contains filtered or unexported fields
}

LatestInstitutionalOwnershipFilingsQuery holds the query parameters of the endpoints that take it: NewLatestInstitutionalOwnershipFilingsQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewLatestInstitutionalOwnershipFilingsQuery

func NewLatestInstitutionalOwnershipFilingsQuery() LatestInstitutionalOwnershipFilingsQuery

NewLatestInstitutionalOwnershipFilingsQuery creates the query from its required arguments.

func (LatestInstitutionalOwnershipFilingsQuery) Limit

Limit returns the optional limit parameter, or nil when it is unset.

func (LatestInstitutionalOwnershipFilingsQuery) Page

Page returns the optional page parameter, or nil when it is unset.

func (LatestInstitutionalOwnershipFilingsQuery) WithLimit

WithLimit sets the optional limit parameter and returns the updated query.

func (LatestInstitutionalOwnershipFilingsQuery) WithPage

WithPage sets the optional page parameter and returns the updated query.

type LatestMergersAcquisitionsQuery added in v0.12.0

type LatestMergersAcquisitionsQuery struct {
	// contains filtered or unexported fields
}

LatestMergersAcquisitionsQuery holds the query parameters of the endpoints that take it: NewLatestMergersAcquisitionsQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewLatestMergersAcquisitionsQuery added in v0.12.0

func NewLatestMergersAcquisitionsQuery() LatestMergersAcquisitionsQuery

NewLatestMergersAcquisitionsQuery creates the query from its required arguments.

func (LatestMergersAcquisitionsQuery) Limit added in v0.12.0

Limit returns the optional limit parameter, or nil when it is unset.

func (LatestMergersAcquisitionsQuery) Page added in v0.12.0

Page returns the optional page parameter, or nil when it is unset.

func (LatestMergersAcquisitionsQuery) WithLimit added in v0.12.0

WithLimit sets the optional limit parameter and returns the updated query.

func (LatestMergersAcquisitionsQuery) WithPage added in v0.12.0

WithPage sets the optional page parameter and returns the updated query.

type LatestPressReleasesQuery

type LatestPressReleasesQuery struct {
	// contains filtered or unexported fields
}

LatestPressReleasesQuery holds the query parameters of the endpoints that take it: NewLatestPressReleasesQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewLatestPressReleasesQuery

func NewLatestPressReleasesQuery() LatestPressReleasesQuery

NewLatestPressReleasesQuery creates the query from its required arguments.

func (LatestPressReleasesQuery) From

func (q LatestPressReleasesQuery) From() *Date

From returns the optional from parameter, or nil when it is unset.

func (LatestPressReleasesQuery) Limit

func (q LatestPressReleasesQuery) Limit() *uint32

Limit returns the optional limit parameter, or nil when it is unset.

func (LatestPressReleasesQuery) Page

func (q LatestPressReleasesQuery) Page() *uint32

Page returns the optional page parameter, or nil when it is unset.

func (LatestPressReleasesQuery) To

To returns the optional to parameter, or nil when it is unset.

func (LatestPressReleasesQuery) WithFrom

WithFrom sets the optional from parameter and returns the updated query.

func (LatestPressReleasesQuery) WithLimit

WithLimit sets the optional limit parameter and returns the updated query.

func (LatestPressReleasesQuery) WithPage

WithPage sets the optional page parameter and returns the updated query.

func (LatestPressReleasesQuery) WithTo

WithTo sets the optional to parameter and returns the updated query.

type LatestRegulationDOfferingsQuery

type LatestRegulationDOfferingsQuery struct {
	// contains filtered or unexported fields
}

LatestRegulationDOfferingsQuery holds the query parameters of the endpoints that take it: NewLatestRegulationDOfferingsQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewLatestRegulationDOfferingsQuery

func NewLatestRegulationDOfferingsQuery() LatestRegulationDOfferingsQuery

NewLatestRegulationDOfferingsQuery creates the query from its required arguments.

func (LatestRegulationDOfferingsQuery) CIK added in v0.12.0

CIK returns the optional cik parameter, or nil when it is unset.

func (LatestRegulationDOfferingsQuery) Limit

Limit returns the optional limit parameter, or nil when it is unset.

func (LatestRegulationDOfferingsQuery) Page

Page returns the optional page parameter, or nil when it is unset.

func (LatestRegulationDOfferingsQuery) WithCIK added in v0.12.0

WithCIK sets the optional cik parameter and returns the updated query.

func (LatestRegulationDOfferingsQuery) WithLimit

WithLimit sets the optional limit parameter and returns the updated query.

func (LatestRegulationDOfferingsQuery) WithPage

WithPage sets the optional page parameter and returns the updated query.

type LatestSECFilingsQuery added in v0.12.0

type LatestSECFilingsQuery struct {
	// contains filtered or unexported fields
}

LatestSECFilingsQuery holds the query parameters of the endpoints that take it: NewLatestSECFilingsQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewLatestSECFilingsQuery added in v0.12.0

func NewLatestSECFilingsQuery(from Date, to Date) LatestSECFilingsQuery

NewLatestSECFilingsQuery creates the query from its required arguments.

func (LatestSECFilingsQuery) From added in v0.12.0

func (q LatestSECFilingsQuery) From() Date

From returns the from argument as given.

func (LatestSECFilingsQuery) Limit added in v0.12.0

func (q LatestSECFilingsQuery) Limit() *uint32

Limit returns the optional limit parameter, or nil when it is unset.

func (LatestSECFilingsQuery) Page added in v0.12.0

func (q LatestSECFilingsQuery) Page() *uint32

Page returns the optional page parameter, or nil when it is unset.

func (LatestSECFilingsQuery) To added in v0.12.0

func (q LatestSECFilingsQuery) To() Date

To returns the to argument as given.

func (LatestSECFilingsQuery) WithLimit added in v0.12.0

WithLimit sets the optional limit parameter and returns the updated query.

func (LatestSECFilingsQuery) WithPage added in v0.12.0

WithPage sets the optional page parameter and returns the updated query.

type LatestStockNewsQuery

type LatestStockNewsQuery struct {
	// contains filtered or unexported fields
}

LatestStockNewsQuery holds the query parameters of the endpoints that take it: NewLatestStockNewsQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewLatestStockNewsQuery

func NewLatestStockNewsQuery() LatestStockNewsQuery

NewLatestStockNewsQuery creates the query from its required arguments.

func (LatestStockNewsQuery) From

func (q LatestStockNewsQuery) From() *Date

From returns the optional from parameter, or nil when it is unset.

func (LatestStockNewsQuery) Limit

func (q LatestStockNewsQuery) Limit() *uint32

Limit returns the optional limit parameter, or nil when it is unset.

func (LatestStockNewsQuery) Page

func (q LatestStockNewsQuery) Page() *uint32

Page returns the optional page parameter, or nil when it is unset.

func (LatestStockNewsQuery) To

func (q LatestStockNewsQuery) To() *Date

To returns the optional to parameter, or nil when it is unset.

func (LatestStockNewsQuery) WithFrom

WithFrom sets the optional from parameter and returns the updated query.

func (LatestStockNewsQuery) WithLimit

WithLimit sets the optional limit parameter and returns the updated query.

func (LatestStockNewsQuery) WithPage

WithPage sets the optional page parameter and returns the updated query.

func (LatestStockNewsQuery) WithTo

WithTo sets the optional to parameter and returns the updated query.

type MarketCapitalizationQuery

type MarketCapitalizationQuery struct {
	// contains filtered or unexported fields
}

MarketCapitalizationQuery holds the query parameters of the endpoints that take it: NewMarketCapitalizationQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewMarketCapitalizationQuery

func NewMarketCapitalizationQuery(symbol string) MarketCapitalizationQuery

NewMarketCapitalizationQuery creates the query from its required arguments.

func (MarketCapitalizationQuery) Symbol

func (q MarketCapitalizationQuery) Symbol() string

Symbol returns the symbol argument as given.

type MarketDataDelay

type MarketDataDelay struct {
	Minutes uint16
	Scope   DelayScope
}

MarketDataDelay is a documented market-data delay and the scope it applies to. It mirrors the Rust MarketDataDelay.

func (MarketDataDelay) String

func (d MarketDataDelay) String() string

String returns a short label that is safe to log.

type MarketHoursNamespace

type MarketHoursNamespace struct {
	// contains filtered or unexported fields
}

MarketHoursNamespace groups the market_hours endpoints. It is reached as Client.MarketHours and is valid only when obtained from a Client built by NewClient.

func (*MarketHoursNamespace) AllExchanges added in v0.12.0

AllExchanges retrieves trading hours for all exchanges.

GET all-exchange-market-hours?timestamp=

func (*MarketHoursNamespace) Exchange added in v0.12.0

Exchange retrieves trading hours for one exchange.

GET exchange-market-hours?exchange=&timestamp=

func (*MarketHoursNamespace) Holidays added in v0.12.0

Holidays retrieves holidays for one exchange.

GET holidays-by-exchange?exchange=&from=&to=

type MarketMover

type MarketMover struct {
	Symbol            string  `json:"symbol"`
	Price             float64 `json:"price"`
	Name              string  `json:"name"`
	Change            float64 `json:"change"`
	ChangesPercentage float64 `json:"changesPercentage"`
	Exchange          string  `json:"exchange"`
}

MarketMover is one stock in a provider-ranked market-mover list.

func (*MarketMover) UnmarshalJSONFrom

func (m *MarketMover) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type MarketNamespace

type MarketNamespace struct {
	// contains filtered or unexported fields
}

MarketNamespace groups the market endpoints. It is reached as Client.Market and is valid only when obtained from a Client built by NewClient.

func (*MarketNamespace) BiggestGainers

func (n *MarketNamespace) BiggestGainers(ctx context.Context) ([]MarketMover, error)

BiggestGainers retrieves the US-only list of biggest stock gainers.

GET biggest-gainers

func (*MarketNamespace) BiggestLosers

func (n *MarketNamespace) BiggestLosers(ctx context.Context) ([]MarketMover, error)

BiggestLosers retrieves the US-only list of biggest stock losers.

GET biggest-losers

func (*MarketNamespace) HistoricalIndustryPe

func (n *MarketNamespace) HistoricalIndustryPe(ctx context.Context, q HistoricalIndustryPeQuery) ([]IndustryPe, error)

HistoricalIndustryPe retrieves worldwide historical industry P/E ratios.

GET historical-industry-pe?industry=&exchange=&from=&to=

func (*MarketNamespace) HistoricalIndustryPerformance

func (n *MarketNamespace) HistoricalIndustryPerformance(ctx context.Context, q HistoricalIndustryPerformanceQuery) ([]IndustryPerformance, error)

HistoricalIndustryPerformance retrieves worldwide historical industry performance.

GET historical-industry-performance?industry=&exchange=&from=&to=

func (*MarketNamespace) HistoricalSectorPe

func (n *MarketNamespace) HistoricalSectorPe(ctx context.Context, q HistoricalSectorPeQuery) ([]SectorPe, error)

HistoricalSectorPe retrieves worldwide historical sector P/E ratios.

GET historical-sector-pe?from=&exchange=&sector=&to=

func (*MarketNamespace) HistoricalSectorPerformance

func (n *MarketNamespace) HistoricalSectorPerformance(ctx context.Context, q HistoricalSectorPerformanceQuery) ([]SectorPerformance, error)

HistoricalSectorPerformance retrieves worldwide historical sector performance.

GET historical-sector-performance?from=&exchange=&sector=&to=

func (*MarketNamespace) IndustryPeSnapshot

func (n *MarketNamespace) IndustryPeSnapshot(ctx context.Context, q IndustryPeSnapshotQuery) ([]IndustryPe, error)

IndustryPeSnapshot retrieves a worldwide dated industry P/E snapshot.

GET industry-pe-snapshot?date=&exchange=&industry=

func (*MarketNamespace) IndustryPerformanceSnapshot

func (n *MarketNamespace) IndustryPerformanceSnapshot(ctx context.Context, q IndustryPerformanceSnapshotQuery) ([]IndustryPerformance, error)

IndustryPerformanceSnapshot retrieves a worldwide dated industry-performance snapshot.

GET industry-performance-snapshot?date=&exchange=&industry=

func (*MarketNamespace) MostActives

func (n *MarketNamespace) MostActives(ctx context.Context) ([]MarketMover, error)

MostActives retrieves the US-only list of most actively traded stocks.

GET most-actives

func (*MarketNamespace) SectorPeSnapshot

func (n *MarketNamespace) SectorPeSnapshot(ctx context.Context, q SectorPeSnapshotQuery) ([]SectorPe, error)

SectorPeSnapshot retrieves a worldwide dated sector P/E snapshot.

GET sector-pe-snapshot?date=&exchange=&sector=

func (*MarketNamespace) SectorPerformanceSnapshot

func (n *MarketNamespace) SectorPerformanceSnapshot(ctx context.Context, q SectorPerformanceSnapshotQuery) ([]SectorPerformance, error)

SectorPerformanceSnapshot retrieves a worldwide dated sector-performance snapshot.

GET sector-performance-snapshot?date=&exchange=&sector=

type MarketRiskPremium

type MarketRiskPremium struct {
	Country                string  `json:"country"`
	Continent              string  `json:"continent"`
	CountryRiskPremium     float64 `json:"countryRiskPremium"`
	TotalEquityRiskPremium float64 `json:"totalEquityRiskPremium"`
}

MarketRiskPremium is one country's documented market and total-equity risk premiums.

func (*MarketRiskPremium) UnmarshalJSONFrom

func (m *MarketRiskPremium) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type MergerAcquisition

type MergerAcquisition struct {
	Symbol              string   `json:"symbol"`
	CompanyName         string   `json:"companyName"`
	CIK                 string   `json:"cik"`
	TargetedCompanyName string   `json:"targetedCompanyName"`
	TargetedCIK         string   `json:"targetedCik"`
	TargetedSymbol      string   `json:"targetedSymbol"`
	TransactionDate     Date     `json:"transactionDate"`
	AcceptedDate        DateTime `json:"acceptedDate"`
	Link                string   `json:"link"`
}

MergerAcquisition is one US merger or acquisition transaction and its official filing link.

func (*MergerAcquisition) UnmarshalJSONFrom

func (m *MergerAcquisition) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type NameSearchQuery

type NameSearchQuery struct {
	// contains filtered or unexported fields
}

NameSearchQuery holds the query parameters of the endpoints that take it: NewNameSearchQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewNameSearchQuery

func NewNameSearchQuery(query string) NameSearchQuery

NewNameSearchQuery creates the query from its required arguments.

func (NameSearchQuery) Exchange

func (q NameSearchQuery) Exchange() *string

Exchange returns the optional exchange parameter, or nil when it is unset.

func (NameSearchQuery) Limit

func (q NameSearchQuery) Limit() *uint32

Limit returns the optional limit parameter, or nil when it is unset.

func (NameSearchQuery) Query

func (q NameSearchQuery) Query() string

Query returns the query argument as given.

func (NameSearchQuery) WithExchange

func (q NameSearchQuery) WithExchange(exchange string) NameSearchQuery

WithExchange sets the optional exchange parameter and returns the updated query.

func (NameSearchQuery) WithLimit

func (q NameSearchQuery) WithLimit(limit uint32) NameSearchQuery

WithLimit sets the optional limit parameter and returns the updated query.

type NameSearchResult

type NameSearchResult struct {
	Symbol           string `json:"symbol"`
	Name             string `json:"name"`
	Currency         string `json:"currency"`
	ExchangeFullName string `json:"exchangeFullName"`
	Exchange         string `json:"exchange"`
}

NameSearchResult is a company or instrument returned by name search.

func (*NameSearchResult) UnmarshalJSONFrom

func (m *NameSearchResult) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type Namespaces

type Namespaces struct {
	// Analyst holds the analyst endpoints.
	Analyst AnalystNamespace
	// Bulk holds the bulk endpoints.
	Bulk BulkNamespace
	// Calendar holds the calendar endpoints.
	Calendar CalendarNamespace
	// Chart holds the chart endpoints.
	Chart ChartNamespace
	// CommitmentOfTraders holds the commitment_of_traders endpoints.
	CommitmentOfTraders CommitmentOfTradersNamespace
	// Commodities holds the commodities endpoints.
	Commodities CommoditiesNamespace
	// Company holds the company endpoints.
	Company CompanyNamespace
	// Congressional holds the congressional endpoints.
	Congressional CongressionalNamespace
	// Crypto holds the crypto endpoints.
	Crypto CryptoNamespace
	// DCF holds the dcf endpoints.
	DCF DCFNamespace
	// Directory holds the directory endpoints.
	Directory DirectoryNamespace
	// Economics holds the economics endpoints.
	Economics EconomicsNamespace
	// ESG holds the esg endpoints.
	ESG ESGNamespace
	// Forex holds the forex endpoints.
	Forex ForexNamespace
	// Fundraising holds the fundraising endpoints.
	Fundraising FundraisingNamespace
	// Funds holds the funds endpoints.
	Funds FundsNamespace
	// Indexes holds the indexes endpoints.
	Indexes IndexesNamespace
	// InsiderTrading holds the insider_trading endpoints.
	InsiderTrading InsiderTradingNamespace
	// InstitutionalOwnership holds the institutional_ownership endpoints.
	InstitutionalOwnership InstitutionalOwnershipNamespace
	// Market holds the market endpoints.
	Market MarketNamespace
	// MarketHours holds the market_hours endpoints.
	MarketHours MarketHoursNamespace
	// News holds the news endpoints.
	News NewsNamespace
	// Quote holds the quote endpoints.
	Quote QuoteNamespace
	// Screener holds the screener endpoints.
	Screener ScreenerNamespace
	// Search holds the search endpoints.
	Search SearchNamespace
	// SECFilings holds the sec_filings endpoints.
	SECFilings SECFilingsNamespace
	// Statements holds the statements endpoints.
	Statements StatementsNamespace
	// TechnicalIndicators holds the technical_indicators endpoints.
	TechnicalIndicators TechnicalIndicatorsNamespace
	// TipRanks holds the tipranks endpoints.
	TipRanks TipRanksNamespace
	// Transcripts holds the transcripts endpoints.
	Transcripts TranscriptsNamespace
}

Namespaces groups the generated endpoint namespaces, one field per registry domain. Client embeds it, so client.Quote.Full is the call shape; the fields are valid only on a Client built by NewClient.

type NewsArticle

type NewsArticle struct {
	Symbol        *string  `json:"symbol"`
	PublishedDate DateTime `json:"publishedDate"`
	Publisher     string   `json:"publisher"`
	Title         string   `json:"title"`
	Image         string   `json:"image"`
	Site          string   `json:"site"`
	Text          string   `json:"text"`
	URL           string   `json:"url"`
}

NewsArticle is one provider-news article shared across general and market-specific feeds.

func (*NewsArticle) UnmarshalJSONFrom

func (m *NewsArticle) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type NewsNamespace

type NewsNamespace struct {
	// contains filtered or unexported fields
}

NewsNamespace groups the news endpoints. It is reached as Client.News and is valid only when obtained from a Client built by NewClient.

func (*NewsNamespace) Articles added in v0.12.0

func (n *NewsNamespace) Articles(ctx context.Context, q ArticlesQuery) ([]Article, error)

Articles retrieves US-authored Financial Modeling Prep articles.

GET fmp-articles?page=&limit=

func (*NewsNamespace) LatestCryptoNews

func (n *NewsNamespace) LatestCryptoNews(ctx context.Context, q LatestCryptoNewsQuery) ([]NewsArticle, error)

LatestCryptoNews retrieves the latest cryptocurrency-news articles.

GET news/crypto-latest?from=&to=&page=&limit=

func (*NewsNamespace) LatestForexNews

func (n *NewsNamespace) LatestForexNews(ctx context.Context, q LatestForexNewsQuery) ([]NewsArticle, error)

LatestForexNews retrieves the latest foreign-exchange-news articles.

GET news/forex-latest?from=&to=&page=&limit=

func (*NewsNamespace) LatestGeneralNews

func (n *NewsNamespace) LatestGeneralNews(ctx context.Context, q LatestGeneralNewsQuery) ([]NewsArticle, error)

LatestGeneralNews retrieves the latest worldwide general-news articles.

GET news/general-latest?from=&to=&page=&limit=

func (*NewsNamespace) LatestPressReleases

func (n *NewsNamespace) LatestPressReleases(ctx context.Context, q LatestPressReleasesQuery) ([]NewsArticle, error)

LatestPressReleases retrieves the latest US press releases.

GET news/press-releases-latest?from=&to=&page=&limit=

func (*NewsNamespace) LatestStockNews

func (n *NewsNamespace) LatestStockNews(ctx context.Context, q LatestStockNewsQuery) ([]NewsArticle, error)

LatestStockNews retrieves the latest stock-news articles.

GET news/stock-latest?from=&to=&page=&limit=

func (*NewsNamespace) SearchCryptoNews

func (n *NewsNamespace) SearchCryptoNews(ctx context.Context, q SearchCryptoNewsQuery) ([]NewsArticle, error)

SearchCryptoNews searches cryptocurrency news for an ordered non-empty ticker list.

GET news/crypto?symbols=&from=&to=&page=&limit=

func (*NewsNamespace) SearchForexNews

func (n *NewsNamespace) SearchForexNews(ctx context.Context, q SearchForexNewsQuery) ([]NewsArticle, error)

SearchForexNews searches foreign-exchange news for an ordered non-empty ticker list.

GET news/forex?symbols=&from=&to=&page=&limit=

func (*NewsNamespace) SearchPressReleases

func (n *NewsNamespace) SearchPressReleases(ctx context.Context, q SearchPressReleasesQuery) ([]NewsArticle, error)

SearchPressReleases searches US press releases for an ordered non-empty ticker list.

GET news/press-releases?symbols=&from=&to=&page=&limit=

func (*NewsNamespace) SearchStockNews

func (n *NewsNamespace) SearchStockNews(ctx context.Context, q SearchStockNewsQuery) ([]NewsArticle, error)

SearchStockNews searches stock news for an ordered non-empty ticker list.

GET news/stock?symbols=&from=&to=&page=&limit=

type NumberOrString

type NumberOrString struct {
	// contains filtered or unexported fields
}

NumberOrString is a JSON number, a numeric string such as "33644000000", or a percent string such as "97.26%", kept exactly as the provider sent it.

It mirrors NumberOrNumericString and PercentageValue in the Rust crate: no form is scaled or coerced, and the accessors report which form arrived. Numbers re-encode byte for byte; strings re-encode with the same content. The zero value is empty: it marshals as null, reports IsZero, and is omitted by the omitzero struct tag option. A JSON null is rejected for a value-typed field and yields nil for a *NumberOrString field.

func NewNumberOrString

func NewNumberOrString(raw jsontext.Value) (NumberOrString, error)

NewNumberOrString validates raw with the rules UnmarshalJSONFrom applies: a JSON number, a JSON string holding a JSON number with no surrounding whitespace, or such a string followed by exactly one "%".

func (NumberOrString) Float64

func (v NumberOrString) Float64() (float64, bool)

Float64 parses a number or numeric string with 64-bit precision. It reports false for the zero value, for a percent string (which is never scaled; use Text), and when the text does not fit a float64. Digits beyond float64 precision are rounded; Text keeps them exactly.

func (NumberOrString) IsNumber

func (v NumberOrString) IsNumber() bool

IsNumber reports whether the provider sent a JSON number.

func (NumberOrString) IsNumericString

func (v NumberOrString) IsNumericString() bool

IsNumericString reports whether the provider sent a JSON string holding a number, such as "0.10335". It mirrors as_numeric_string in the Rust crate.

func (NumberOrString) IsPercentString

func (v NumberOrString) IsPercentString() bool

IsPercentString reports whether the provider sent a JSON string ending in "%", such as "97.26%". It mirrors as_percent_string in the Rust crate.

func (NumberOrString) IsString

func (v NumberOrString) IsString() bool

IsString reports whether the provider sent a JSON string of either form.

func (NumberOrString) IsZero

func (v NumberOrString) IsZero() bool

IsZero reports whether the value is empty. It backs the omitzero tag option.

func (NumberOrString) MarshalJSONTo

func (v NumberOrString) MarshalJSONTo(enc *jsontext.Encoder) error

MarshalJSONTo writes the retained wire value, or null for the zero value.

func (NumberOrString) Raw

func (v NumberOrString) Raw() jsontext.Value

Raw returns a copy of the wire bytes, including the quotes of a string.

func (NumberOrString) String

func (v NumberOrString) String() string

String returns Text.

func (NumberOrString) Text

func (v NumberOrString) Text() string

Text returns the exact wire text: the number's digits, or the string's content without quotes. A percent string keeps its "%". The zero value returns "".

func (*NumberOrString) UnmarshalJSONFrom

func (v *NumberOrString) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom accepts a JSON number, a numeric string, or a percent string and rejects every other value, including null.

type OfferingByCIKQuery added in v0.12.0

type OfferingByCIKQuery struct {
	// contains filtered or unexported fields
}

OfferingByCIKQuery holds the query parameters of the endpoints that take it: NewOfferingByCIKQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewOfferingByCIKQuery added in v0.12.0

func NewOfferingByCIKQuery(cik string) OfferingByCIKQuery

NewOfferingByCIKQuery creates the query from its required arguments.

func (OfferingByCIKQuery) CIK added in v0.12.0

func (q OfferingByCIKQuery) CIK() string

CIK returns the cik argument as given.

type OfferingSearchQuery

type OfferingSearchQuery struct {
	// contains filtered or unexported fields
}

OfferingSearchQuery holds the query parameters of the endpoints that take it: NewOfferingSearchQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewOfferingSearchQuery

func NewOfferingSearchQuery(name string) OfferingSearchQuery

NewOfferingSearchQuery creates the query from its required arguments.

func (OfferingSearchQuery) Name

func (q OfferingSearchQuery) Name() string

Name returns the name argument as given.

type Option

type Option func(*clientConfig)

Option configures NewClient. Each option mirrors one ClientBuilder method of the Rust crate.

func WithAuthentication

func WithAuthentication(auth Authentication) Option

WithAuthentication selects the transport-owned authentication mode. It may be given only once.

func WithBaseURL

func WithBaseURL(baseURL string) Option

WithBaseURL sets an absolute HTTP(S) base URL. Existing path segments are kept.

func WithConnectTimeout

func WithConnectTimeout(timeout time.Duration) Option

WithConnectTimeout bounds connection establishment. It applies only to the transport the SDK builds; a client given through WithHTTPClient keeps its own dialer.

func WithDangerAllowInsecureAuthentication

func WithDangerAllowInsecureAuthentication() Option

WithDangerAllowInsecureAuthentication allows credentials over plaintext HTTP to a non-loopback host. Leaving it out keeps the refusal, so there is no way to pass it in its disabled form. Literal IPv4 and IPv6 loopback URLs used by local test servers never need it.

func WithDefaultHeader

func WithDefaultHeader(name, value string) Option

WithDefaultHeader adds or replaces a default header. Later calls win case-insensitively. Transport-owned headers cannot be set this way.

func WithHTTPClient

func WithHTTPClient(client *http.Client) Option

WithHTTPClient injects a caller-owned *http.Client for proxies and tests. The SDK shallow-copies it to install its redirect policy and never mutates the caller's value.

func WithMaxResponseBodyBytes

func WithMaxResponseBodyBytes(maxBytes int64) Option

WithMaxResponseBodyBytes sets the largest body buffered for one response.

func WithPathPrefix

func WithPathPrefix(prefix string) Option

WithPathPrefix sets the segments inserted between the base URL and the endpoint path. An empty prefix is valid for proxies that expose endpoints at their root; leading and trailing slashes are ignored.

Example

ExampleWithPathPrefix routes the client through a proxy that mounts the FMP endpoints under its own base path and prefix, identifies the tenant with a default header, and authenticates with a proxy-specific header.

package main

import (
	"context"
	"fmt"
	"net/http"
	"net/http/httptest"

	fmp "github.com/bitbrew-dev/libfmp/sdk/go"
)

// exampleKey is the placeholder credential every example sends. It is not a
// real key, and no example prints it.
const exampleKey = "example-key"

// quoteShortFixture is a copy of crates/libfmp/tests/fixtures/quote_short.json,
// the documented provider response the Rust and Go parity tests both decode.
// It is inlined so the examples stay self-contained on pkg.go.dev and when the
// module is tested outside this repository.
const quoteShortFixture = `[
  {
    "change": -6.33498,
    "price": 331.85501,
    "symbol": "AAPL",
    "volume": 28718014
  }
]`

// serveQuoteShort starts an in-process TLS server that answers GET
// <prefix>/quote-short with the quote_short.json fixture, after check has
// accepted the request. Any other path, or a rejected request, is a 404.
func serveQuoteShort(prefix string, check func(*http.Request) bool) *httptest.Server {
	return httptest.NewTLSServer(http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) {
		if r.URL.Path != prefix+"/quote-short" || !check(r) {
			http.NotFound(w, r)
			return
		}
		w.Header().Set("Content-Type", "application/json")
		_, _ = fmt.Fprint(w, quoteShortFixture)
	}))
}

// printQuoteShort prints the first compact quote with fixed formats so the
// output is stable across platforms.
func printQuoteShort(quotes []fmp.QuoteShort) {
	if len(quotes) == 0 {
		fmt.Println("no quotes")
		return
	}
	q := quotes[0]
	fmt.Printf("%s price %.5f change %.5f volume %.0f\n", q.Symbol, q.Price, q.Change, q.Volume)
}

func main() {
	server := serveQuoteShort("/router/v1", func(r *http.Request) bool {
		return r.Header.Get("X-Tenant") == "acme" && r.Header.Get("X-Proxy-Token") == exampleKey
	})
	defer server.Close()

	client, err := fmp.NewClient(
		fmp.WithBaseURL(server.URL+"/router"),
		fmp.WithPathPrefix("v1"),
		fmp.WithDefaultHeader("X-Tenant", "acme"),
		fmp.WithAuthentication(fmp.CustomHeader("X-Proxy-Token", exampleKey)),
		fmp.WithHTTPClient(server.Client()),
	)
	if err != nil {
		fmt.Println("configuration rejected:", err)
		return
	}

	quotes, err := client.Quote.Short(context.Background(), fmp.NewQuoteShortQuery("AAPL"))
	if err != nil {
		fmt.Println("request failed:", err)
		return
	}
	printQuoteShort(quotes)
}
Output:
AAPL price 331.85501 change -6.33498 volume 28718014

func WithRedirectPolicy

func WithRedirectPolicy(policy RedirectPolicy) Option

WithRedirectPolicy selects RedirectNone or RedirectSameOrigin.

func WithTimeout

func WithTimeout(timeout time.Duration) Option

WithTimeout sets one logical deadline across redirects and the body read.

func WithUserAgent

func WithUserAgent(userAgent string) Option

WithUserAgent sets the transport-owned User-Agent header.

type OwnerEarnings

type OwnerEarnings struct {
	Symbol                 string  `json:"symbol"`
	ReportedCurrency       string  `json:"reportedCurrency"`
	FiscalYear             string  `json:"fiscalYear"`
	Period                 string  `json:"period"`
	Date                   Date    `json:"date"`
	AveragePpe             float64 `json:"averagePPE"`
	MaintenanceCapex       float64 `json:"maintenanceCapex"`
	OwnersEarnings         float64 `json:"ownersEarnings"`
	GrowthCapex            float64 `json:"growthCapex"`
	OwnersEarningsPerShare float64 `json:"ownersEarningsPerShare"`
}

OwnerEarnings is one company's owner-earnings calculation.

func (*OwnerEarnings) UnmarshalJSONFrom

func (m *OwnerEarnings) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type OwnerEarningsQuery

type OwnerEarningsQuery struct {
	// contains filtered or unexported fields
}

OwnerEarningsQuery holds the query parameters of the endpoints that take it: NewOwnerEarningsQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewOwnerEarningsQuery

func NewOwnerEarningsQuery(symbol string) OwnerEarningsQuery

NewOwnerEarningsQuery creates the query from its required arguments.

func (OwnerEarningsQuery) Limit

func (q OwnerEarningsQuery) Limit() *uint32

Limit returns the optional limit parameter, or nil when it is unset.

func (OwnerEarningsQuery) Symbol

func (q OwnerEarningsQuery) Symbol() string

Symbol returns the symbol argument as given.

func (OwnerEarningsQuery) WithLimit

func (q OwnerEarningsQuery) WithLimit(limit uint32) OwnerEarningsQuery

WithLimit sets the optional limit parameter and returns the updated query.

type PlanCondition

type PlanCondition struct {
	Kind  PlanConditionKind
	Years uint16
}

PlanCondition is the condition under which an additional plan is required. It mirrors the Rust PlanCondition: Kind selects the variant and Years carries the threshold of PlanConditionHistoryOlderThanYears.

func (PlanCondition) String

func (c PlanCondition) String() string

String returns a short label that is safe to log.

type PlanConditionKind

type PlanConditionKind int

PlanConditionKind is the discriminant of PlanCondition. The zero value is PlanConditionUnspecified.

const (
	// PlanConditionUnspecified: no condition is documented.
	PlanConditionUnspecified PlanConditionKind = iota
	// PlanConditionHistoryOlderThanYears: requests for history older than
	// PlanCondition.Years require the plan.
	PlanConditionHistoryOlderThanYears
)

type PointInTimeRatingsByAnalystQuery

type PointInTimeRatingsByAnalystQuery struct {
	// contains filtered or unexported fields
}

PointInTimeRatingsByAnalystQuery holds the query parameters of the endpoints that take it: NewPointInTimeRatingsByAnalystQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewPointInTimeRatingsByAnalystQuery

func NewPointInTimeRatingsByAnalystQuery() PointInTimeRatingsByAnalystQuery

NewPointInTimeRatingsByAnalystQuery creates the query from its required arguments.

func (PointInTimeRatingsByAnalystQuery) AnalystName

func (q PointInTimeRatingsByAnalystQuery) AnalystName() *string

AnalystName returns the optional analyst_name parameter, or nil when it is unset.

func (PointInTimeRatingsByAnalystQuery) Date

Date returns the optional date parameter, or nil when it is unset.

func (PointInTimeRatingsByAnalystQuery) ExpertUID added in v0.12.0

ExpertUID returns the optional expert_uid parameter, or nil when it is unset.

func (PointInTimeRatingsByAnalystQuery) Limit

Limit returns the optional limit parameter, or nil when it is unset.

func (PointInTimeRatingsByAnalystQuery) Nonadjusted

func (q PointInTimeRatingsByAnalystQuery) Nonadjusted() *bool

Nonadjusted returns the optional nonadjusted parameter, or nil when it is unset.

func (PointInTimeRatingsByAnalystQuery) Page

Page returns the optional page parameter, or nil when it is unset.

func (PointInTimeRatingsByAnalystQuery) WithAnalystName

WithAnalystName sets the optional analyst_name parameter and returns the updated query.

func (PointInTimeRatingsByAnalystQuery) WithDate

WithDate sets the optional date parameter and returns the updated query.

func (PointInTimeRatingsByAnalystQuery) WithExpertUID added in v0.12.0

WithExpertUID sets the optional expert_uid parameter and returns the updated query.

func (PointInTimeRatingsByAnalystQuery) WithLimit

WithLimit sets the optional limit parameter and returns the updated query.

func (PointInTimeRatingsByAnalystQuery) WithNonadjusted

WithNonadjusted sets the optional nonadjusted parameter and returns the updated query.

func (PointInTimeRatingsByAnalystQuery) WithPage

WithPage sets the optional page parameter and returns the updated query.

type PointInTimeRatingsBySymbolQuery

type PointInTimeRatingsBySymbolQuery struct {
	// contains filtered or unexported fields
}

PointInTimeRatingsBySymbolQuery holds the query parameters of the endpoints that take it: NewPointInTimeRatingsBySymbolQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewPointInTimeRatingsBySymbolQuery

func NewPointInTimeRatingsBySymbolQuery(symbol string) PointInTimeRatingsBySymbolQuery

NewPointInTimeRatingsBySymbolQuery creates the query from its required arguments.

func (PointInTimeRatingsBySymbolQuery) Date

Date returns the optional date parameter, or nil when it is unset.

func (PointInTimeRatingsBySymbolQuery) Limit

Limit returns the optional limit parameter, or nil when it is unset.

func (PointInTimeRatingsBySymbolQuery) Nonadjusted

func (q PointInTimeRatingsBySymbolQuery) Nonadjusted() *bool

Nonadjusted returns the optional nonadjusted parameter, or nil when it is unset.

func (PointInTimeRatingsBySymbolQuery) Page

Page returns the optional page parameter, or nil when it is unset.

func (PointInTimeRatingsBySymbolQuery) Symbol

Symbol returns the symbol argument as given.

func (PointInTimeRatingsBySymbolQuery) WithDate

WithDate sets the optional date parameter and returns the updated query.

func (PointInTimeRatingsBySymbolQuery) WithLimit

WithLimit sets the optional limit parameter and returns the updated query.

func (PointInTimeRatingsBySymbolQuery) WithNonadjusted

WithNonadjusted sets the optional nonadjusted parameter and returns the updated query.

func (PointInTimeRatingsBySymbolQuery) WithPage

WithPage sets the optional page parameter and returns the updated query.

type PriceTargetConsensus

type PriceTargetConsensus struct {
	Symbol          string  `json:"symbol"`
	TargetHigh      float64 `json:"targetHigh"`
	TargetLow       float64 `json:"targetLow"`
	TargetConsensus float64 `json:"targetConsensus"`
	TargetMedian    float64 `json:"targetMedian"`
}

PriceTargetConsensus is aggregated high, low, consensus, and median analyst price targets.

func (*PriceTargetConsensus) UnmarshalJSONFrom

func (m *PriceTargetConsensus) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type PriceTargetConsensusQuery

type PriceTargetConsensusQuery struct {
	// contains filtered or unexported fields
}

PriceTargetConsensusQuery holds the query parameters of the endpoints that take it: NewPriceTargetConsensusQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewPriceTargetConsensusQuery

func NewPriceTargetConsensusQuery(symbol string) PriceTargetConsensusQuery

NewPriceTargetConsensusQuery creates the query from its required arguments.

func (PriceTargetConsensusQuery) Symbol

func (q PriceTargetConsensusQuery) Symbol() string

Symbol returns the symbol argument as given.

type PriceTargetSummary

type PriceTargetSummary struct {
	Symbol                    string  `json:"symbol"`
	LastMonthCount            uint64  `json:"lastMonthCount"`
	LastMonthAvgPriceTarget   float64 `json:"lastMonthAvgPriceTarget"`
	LastQuarterCount          uint64  `json:"lastQuarterCount"`
	LastQuarterAvgPriceTarget float64 `json:"lastQuarterAvgPriceTarget"`
	LastYearCount             uint64  `json:"lastYearCount"`
	LastYearAvgPriceTarget    float64 `json:"lastYearAvgPriceTarget"`
	AllTimeCount              uint64  `json:"allTimeCount"`
	AllTimeAvgPriceTarget     float64 `json:"allTimeAvgPriceTarget"`
	Publishers                string  `json:"publishers"`
}

PriceTargetSummary is price-target averages and publisher text across documented time windows.

func (*PriceTargetSummary) UnmarshalJSONFrom

func (m *PriceTargetSummary) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type PriceTargetSummaryQuery

type PriceTargetSummaryQuery struct {
	// contains filtered or unexported fields
}

PriceTargetSummaryQuery holds the query parameters of the endpoints that take it: NewPriceTargetSummaryQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewPriceTargetSummaryQuery

func NewPriceTargetSummaryQuery(symbol string) PriceTargetSummaryQuery

NewPriceTargetSummaryQuery creates the query from its required arguments.

func (PriceTargetSummaryQuery) Symbol

func (q PriceTargetSummaryQuery) Symbol() string

Symbol returns the symbol argument as given.

type ProfileByCIKQuery added in v0.12.0

type ProfileByCIKQuery struct {
	// contains filtered or unexported fields
}

ProfileByCIKQuery holds the query parameters of the endpoints that take it: NewProfileByCIKQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewProfileByCIKQuery added in v0.12.0

func NewProfileByCIKQuery(cik string) ProfileByCIKQuery

NewProfileByCIKQuery creates the query from its required arguments.

func (ProfileByCIKQuery) CIK added in v0.12.0

func (q ProfileByCIKQuery) CIK() string

CIK returns the cik argument as given.

type ProfileQuery

type ProfileQuery struct {
	// contains filtered or unexported fields
}

ProfileQuery holds the query parameters of the endpoints that take it: NewProfileQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewProfileQuery

func NewProfileQuery(symbol string) ProfileQuery

NewProfileQuery creates the query from its required arguments.

func (ProfileQuery) Symbol

func (q ProfileQuery) Symbol() string

Symbol returns the symbol argument as given.

type Quarter

type Quarter string

Quarter is the textual calendar quarter taken by the endpoints whose Rust query takes a Quarter. The constants carry the exact provider wire spellings "1" through "4"; any other value is rejected when the request is built. It is distinct from the numeric CalendarQuarter of the response models, which is decoded from a JSON integer.

const (
	QuarterQ1 Quarter = "1"
	QuarterQ2 Quarter = "2"
	QuarterQ3 Quarter = "3"
	QuarterQ4 Quarter = "4"
)

The documented Quarter wire values.

type Quote

type Quote struct {
	Symbol           string      `json:"symbol"`
	Name             string      `json:"name"`
	Price            float64     `json:"price"`
	ChangePercentage float64     `json:"changePercentage"`
	Change           float64     `json:"change"`
	Volume           float64     `json:"volume"`
	DayLow           float64     `json:"dayLow"`
	DayHigh          float64     `json:"dayHigh"`
	YearHigh         float64     `json:"yearHigh"`
	YearLow          float64     `json:"yearLow"`
	MarketCap        *float64    `json:"marketCap"`
	PriceAvg50       float64     `json:"priceAvg50"`
	PriceAvg200      float64     `json:"priceAvg200"`
	Exchange         string      `json:"exchange"`
	Open             float64     `json:"open"`
	PreviousClose    float64     `json:"previousClose"`
	Timestamp        UnixSeconds `json:"timestamp"`
}

Quote is a detailed real-time stock quote.

func (*Quote) UnmarshalJSONFrom

func (m *Quote) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type QuoteNamespace

type QuoteNamespace struct {
	// contains filtered or unexported fields
}

QuoteNamespace groups the quote endpoints. It is reached as Client.Quote and is valid only when obtained from a Client built by NewClient.

func (*QuoteNamespace) AftermarketQuote

func (n *QuoteNamespace) AftermarketQuote(ctx context.Context, q AftermarketQuoteQuery) ([]AftermarketQuote, error)

AftermarketQuote retrieves US aftermarket bid-and-ask quotes for one ticker.

GET aftermarket-quote?symbol=

func (*QuoteNamespace) AftermarketTrade

func (n *QuoteNamespace) AftermarketTrade(ctx context.Context, q AftermarketTradeQuery) ([]AftermarketTrade, error)

AftermarketTrade retrieves US aftermarket trades for one ticker.

GET aftermarket-trade?symbol=

func (*QuoteNamespace) Batch added in v0.12.0

func (n *QuoteNamespace) Batch(ctx context.Context, q BatchQuoteQuery) ([]Quote, error)

Batch retrieves detailed worldwide stock quotes for multiple tickers.

GET batch-quote?symbols=

func (*QuoteNamespace) BatchAftermarketQuote

func (n *QuoteNamespace) BatchAftermarketQuote(ctx context.Context, q BatchAftermarketQuoteQuery) ([]AftermarketQuote, error)

BatchAftermarketQuote retrieves US aftermarket bid-and-ask quotes for multiple tickers.

GET batch-aftermarket-quote?symbols=

func (*QuoteNamespace) BatchAftermarketTrade

func (n *QuoteNamespace) BatchAftermarketTrade(ctx context.Context, q BatchAftermarketTradeQuery) ([]AftermarketTrade, error)

BatchAftermarketTrade retrieves US aftermarket trades for multiple tickers.

GET batch-aftermarket-trade?symbols=

func (*QuoteNamespace) BatchShort added in v0.12.0

BatchShort retrieves compact worldwide stock quotes for multiple tickers.

GET batch-quote-short?symbols=

func (*QuoteNamespace) Commodities

func (n *QuoteNamespace) Commodities(ctx context.Context) ([]QuoteShort, error)

Commodities retrieves compact quotes for the documented commodity universe.

GET batch-commodity-quotes?short=true

func (*QuoteNamespace) Cryptocurrencies

func (n *QuoteNamespace) Cryptocurrencies(ctx context.Context) ([]QuoteShort, error)

Cryptocurrencies retrieves compact quotes for the documented cryptocurrency universe.

GET batch-crypto-quotes?short=true

func (*QuoteNamespace) ETFs added in v0.12.0

func (n *QuoteNamespace) ETFs(ctx context.Context) ([]QuoteShort, error)

ETFs retrieves compact quotes for the documented ETF universe.

GET batch-etf-quotes?short=true

func (*QuoteNamespace) Exchange

Exchange retrieves compact quotes for every stock on one exchange.

GET batch-exchange-quote?exchange=&short=true

func (*QuoteNamespace) Forex

func (n *QuoteNamespace) Forex(ctx context.Context) ([]QuoteShort, error)

Forex retrieves compact quotes for the documented forex universe.

GET batch-forex-quotes?short=true

func (*QuoteNamespace) Full

func (n *QuoteNamespace) Full(ctx context.Context, q QuoteQuery) ([]Quote, error)

Full returns the full quote for a symbol.

GET quote?symbol=

func (*QuoteNamespace) Indexes

func (n *QuoteNamespace) Indexes(ctx context.Context) ([]QuoteShort, error)

Indexes retrieves compact quotes for the documented index universe.

GET batch-index-quotes?short=true

func (*QuoteNamespace) MutualFunds

func (n *QuoteNamespace) MutualFunds(ctx context.Context) ([]QuoteShort, error)

MutualFunds returns compact quotes for every mutual fund, without a query.

GET batch-mutualfund-quotes?short=true

func (*QuoteNamespace) Short

Short returns the compact quote array for a symbol.

GET quote-short?symbol=

func (*QuoteNamespace) StockPriceChange

func (n *QuoteNamespace) StockPriceChange(ctx context.Context, q StockPriceChangeQuery) ([]StockPriceChange, error)

StockPriceChange retrieves worldwide percentage price changes for one stock.

GET stock-price-change?symbol=

type QuoteQuery

type QuoteQuery struct {
	// contains filtered or unexported fields
}

QuoteQuery holds the query parameters of the endpoints that take it: NewQuoteQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewQuoteQuery

func NewQuoteQuery(symbol string) QuoteQuery

NewQuoteQuery creates the query from its required arguments.

func (QuoteQuery) Symbol

func (q QuoteQuery) Symbol() string

Symbol returns the symbol argument as given.

type QuoteShort

type QuoteShort struct {
	Symbol string  `json:"symbol"`
	Price  float64 `json:"price"`
	Change float64 `json:"change"`
	Volume float64 `json:"volume"`
}

QuoteShort is the compact response returned by quote-short endpoints across asset classes.

func (*QuoteShort) UnmarshalJSONFrom

func (m *QuoteShort) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type QuoteShortQuery

type QuoteShortQuery struct {
	// contains filtered or unexported fields
}

QuoteShortQuery holds the query parameters of the endpoints that take it: NewQuoteShortQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewQuoteShortQuery

func NewQuoteShortQuery(symbol string) QuoteShortQuery

NewQuoteShortQuery creates the query from its required arguments.

func (QuoteShortQuery) Symbol

func (q QuoteShortQuery) Symbol() string

Symbol returns the symbol argument as given.

type RatingSnapshot

type RatingSnapshot struct {
	Symbol                  string `json:"symbol"`
	Rating                  string `json:"rating"`
	OverallScore            uint64 `json:"overallScore"`
	DiscountedCashFlowScore uint64 `json:"discountedCashFlowScore"`
	ReturnOnEquityScore     uint64 `json:"returnOnEquityScore"`
	ReturnOnAssetsScore     uint64 `json:"returnOnAssetsScore"`
	DebtToEquityScore       uint64 `json:"debtToEquityScore"`
	PriceToEarningsScore    uint64 `json:"priceToEarningsScore"`
	PriceToBookScore        uint64 `json:"priceToBookScore"`
}

RatingSnapshot is one current financial-rating snapshot.

func (*RatingSnapshot) UnmarshalJSONFrom

func (m *RatingSnapshot) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type RatingsSnapshotQuery

type RatingsSnapshotQuery struct {
	// contains filtered or unexported fields
}

RatingsSnapshotQuery holds the query parameters of the endpoints that take it: NewRatingsSnapshotQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewRatingsSnapshotQuery

func NewRatingsSnapshotQuery(symbol string) RatingsSnapshotQuery

NewRatingsSnapshotQuery creates the query from its required arguments.

func (RatingsSnapshotQuery) Symbol

func (q RatingsSnapshotQuery) Symbol() string

Symbol returns the symbol argument as given.

type RealtimeAccess

type RealtimeAccess struct {
	Delay           *MarketDataDelay
	UserDeclaration UserDeclarationRequirement
}

RealtimeAccess holds the real-time access caveats documented for an endpoint. It mirrors the Rust RealtimeAccess: Delay is nil when no delay is documented, and UserDeclaration is UserDeclarationUnspecified when no declaration is documented.

func (RealtimeAccess) String

func (r RealtimeAccess) String() string

String returns a short label that is safe to log.

type Redactor

type Redactor struct {
	// contains filtered or unexported fields
}

Redactor removes registered secrets and the values of known secret query parameters from diagnostic text.

func NewRedactor

func NewRedactor() *Redactor

NewRedactor creates a policy with common authentication and signing names already protected.

func (*Redactor) AddSecret

func (r *Redactor) AddSecret(secret string)

AddSecret registers a value to remove from arbitrary diagnostic text. Empty values are ignored.

func (*Redactor) AddSecretHeaderName

func (r *Redactor) AddSecretHeaderName(name string) error

AddSecretHeaderName marks a header name as secret, compared case-insensitively.

func (*Redactor) AddSecretQueryName

func (r *Redactor) AddSecretQueryName(name string) error

AddSecretQueryName marks a query name as secret, compared case-insensitively.

func (*Redactor) Format

func (r *Redactor) Format(f fmt.State, _ rune)

Format prints counts and names only, never a registered value.

func (*Redactor) Redact

func (r *Redactor) Redact(value string) string

Redact removes registered values and the values of secret query parameters.

func (*Redactor) RedactHeader

func (r *Redactor) RedactHeader(name, value string) string

RedactHeader produces a safe header value for diagnostics.

type RedirectPolicy

type RedirectPolicy int

RedirectPolicy selects how redirect responses are handled.

const (
	// RedirectSameOrigin follows at most ten redirects when every hop keeps
	// the same scheme, host, and port. It is the default.
	RedirectSameOrigin RedirectPolicy = iota
	// RedirectNone returns redirect responses as status errors.
	RedirectNone
)

func (RedirectPolicy) String

func (p RedirectPolicy) String() string

String names the policy.

type RegulationDOffering

type RegulationDOffering struct {
	CIK                                    string   `json:"cik"`
	CompanyName                            string   `json:"companyName"`
	Date                                   Date     `json:"date"`
	FilingDate                             DateTime `json:"filingDate"`
	AcceptedDate                           DateTime `json:"acceptedDate"`
	FormType                               string   `json:"formType"`
	FormSignification                      string   `json:"formSignification"`
	EntityName                             string   `json:"entityName"`
	IssuerStreet                           string   `json:"issuerStreet"`
	IssuerCity                             string   `json:"issuerCity"`
	IssuerStateOrCountry                   string   `json:"issuerStateOrCountry"`
	IssuerStateOrCountryDescription        string   `json:"issuerStateOrCountryDescription"`
	IssuerZipCode                          string   `json:"issuerZipCode"`
	IssuerPhoneNumber                      string   `json:"issuerPhoneNumber"`
	JurisdictionOfIncorporation            string   `json:"jurisdictionOfIncorporation"`
	EntityType                             string   `json:"entityType"`
	IncorporatedWithinFiveYears            *bool    `json:"incorporatedWithinFiveYears"`
	YearOfIncorporation                    string   `json:"yearOfIncorporation"`
	RelatedPersonFirstName                 string   `json:"relatedPersonFirstName"`
	RelatedPersonLastName                  string   `json:"relatedPersonLastName"`
	RelatedPersonStreet                    string   `json:"relatedPersonStreet"`
	RelatedPersonCity                      string   `json:"relatedPersonCity"`
	RelatedPersonStateOrCountry            string   `json:"relatedPersonStateOrCountry"`
	RelatedPersonStateOrCountryDescription string   `json:"relatedPersonStateOrCountryDescription"`
	RelatedPersonZipCode                   string   `json:"relatedPersonZipCode"`
	RelatedPersonRelationship              string   `json:"relatedPersonRelationship"`
	IndustryGroupType                      string   `json:"industryGroupType"`
	RevenueRange                           string   `json:"revenueRange"`
	FederalExemptionsExclusions            string   `json:"federalExemptionsExclusions"`
	IsAmendment                            bool     `json:"isAmendment"`
	DateOfFirstSale                        *Date    `json:"dateOfFirstSale"`
	DurationOfOfferingIsMoreThanYear       bool     `json:"durationOfOfferingIsMoreThanYear"`
	SecuritiesOfferedAreOfEquityType       bool     `json:"securitiesOfferedAreOfEquityType"`
	IsBusinessCombinationTransaction       bool     `json:"isBusinessCombinationTransaction"`
	MinimumInvestmentAccepted              float64  `json:"minimumInvestmentAccepted"`
	TotalOfferingAmount                    float64  `json:"totalOfferingAmount"`
	TotalAmountSold                        float64  `json:"totalAmountSold"`
	TotalAmountRemaining                   float64  `json:"totalAmountRemaining"`
	HasNonAccreditedInvestors              bool     `json:"hasNonAccreditedInvestors"`
	TotalNumberAlreadyInvested             uint64   `json:"totalNumberAlreadyInvested"`
	SalesCommissions                       float64  `json:"salesCommissions"`
	FindersFees                            float64  `json:"findersFees"`
	GrossProceedsUsed                      float64  `json:"grossProceedsUsed"`
}

RegulationDOffering is one detailed Regulation D exempt offering.

func (*RegulationDOffering) UnmarshalJSONFrom

func (m *RegulationDOffering) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type RegulationDOfferingSearchResult

type RegulationDOfferingSearchResult struct {
	CIK  string   `json:"cik"`
	Name string   `json:"name"`
	Date DateTime `json:"date"`
}

RegulationDOfferingSearchResult is one compact Regulation D offering search result.

func (*RegulationDOfferingSearchResult) UnmarshalJSONFrom

func (m *RegulationDOfferingSearchResult) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type RelativeStrengthIndexBar

type RelativeStrengthIndexBar struct {
	Date   DateTime `json:"date"`
	Open   float64  `json:"open"`
	High   float64  `json:"high"`
	Low    float64  `json:"low"`
	Close  float64  `json:"close"`
	Volume float64  `json:"volume"`
	Rsi    float64  `json:"rsi"`
}

RelativeStrengthIndexBar is a response model of the technical_indicators domain.

func (*RelativeStrengthIndexBar) UnmarshalJSONFrom

func (m *RelativeStrengthIndexBar) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type RetrievalFrequency

type RetrievalFrequency string

RetrievalFrequency is the annual or quarterly retrieval frequency of the endpoints whose Rust query takes a RetrievalFrequency. The constants carry the exact provider wire spellings; any other value is rejected when the request is built.

const (
	RetrievalFrequencyAnnual    RetrievalFrequency = "annual"
	RetrievalFrequencyQuarterly RetrievalFrequency = "quarter"
)

The documented RetrievalFrequency wire values.

type RevenueGeographicSegmentationQuery

type RevenueGeographicSegmentationQuery struct {
	// contains filtered or unexported fields
}

RevenueGeographicSegmentationQuery holds the query parameters of the endpoints that take it: NewRevenueGeographicSegmentationQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewRevenueGeographicSegmentationQuery

func NewRevenueGeographicSegmentationQuery(symbol string) RevenueGeographicSegmentationQuery

NewRevenueGeographicSegmentationQuery creates the query from its required arguments.

func (RevenueGeographicSegmentationQuery) Period

Period returns the optional period parameter, or nil when it is unset.

func (RevenueGeographicSegmentationQuery) Structure

Structure returns the optional structure parameter, or nil when it is unset.

func (RevenueGeographicSegmentationQuery) Symbol

Symbol returns the symbol argument as given.

func (RevenueGeographicSegmentationQuery) WithPeriod

WithPeriod sets the optional period parameter and returns the updated query.

func (RevenueGeographicSegmentationQuery) WithStructure

WithStructure sets the optional structure parameter and returns the updated query.

type RevenueProductSegmentationQuery

type RevenueProductSegmentationQuery struct {
	// contains filtered or unexported fields
}

RevenueProductSegmentationQuery holds the query parameters of the endpoints that take it: NewRevenueProductSegmentationQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewRevenueProductSegmentationQuery

func NewRevenueProductSegmentationQuery(symbol string) RevenueProductSegmentationQuery

NewRevenueProductSegmentationQuery creates the query from its required arguments.

func (RevenueProductSegmentationQuery) Period

Period returns the optional period parameter, or nil when it is unset.

func (RevenueProductSegmentationQuery) Structure

Structure returns the optional structure parameter, or nil when it is unset.

func (RevenueProductSegmentationQuery) Symbol

Symbol returns the symbol argument as given.

func (RevenueProductSegmentationQuery) WithPeriod

WithPeriod sets the optional period parameter and returns the updated query.

func (RevenueProductSegmentationQuery) WithStructure

WithStructure sets the optional structure parameter and returns the updated query.

type RevenueSegmentation

type RevenueSegmentation struct {
	Symbol           string         `json:"symbol"`
	FiscalYear       uint32         `json:"fiscalYear"`
	Period           string         `json:"period"`
	ReportedCurrency string         `json:"reportedCurrency"`
	Date             Date           `json:"date"`
	Data             jsontext.Value `json:"data"`
}

RevenueSegmentation is one product or geographic revenue-segmentation row.

func (*RevenueSegmentation) UnmarshalJSONFrom

func (m *RevenueSegmentation) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type SECCompaniesByCIKQuery added in v0.12.0

type SECCompaniesByCIKQuery struct {
	// contains filtered or unexported fields
}

SECCompaniesByCIKQuery holds the query parameters of the endpoints that take it: NewSECCompaniesByCIKQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewSECCompaniesByCIKQuery added in v0.12.0

func NewSECCompaniesByCIKQuery(cik string) SECCompaniesByCIKQuery

NewSECCompaniesByCIKQuery creates the query from its required arguments.

func (SECCompaniesByCIKQuery) CIK added in v0.12.0

CIK returns the cik argument as given.

type SECCompaniesByNameQuery added in v0.12.0

type SECCompaniesByNameQuery struct {
	// contains filtered or unexported fields
}

SECCompaniesByNameQuery holds the query parameters of the endpoints that take it: NewSECCompaniesByNameQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewSECCompaniesByNameQuery added in v0.12.0

func NewSECCompaniesByNameQuery(company string) SECCompaniesByNameQuery

NewSECCompaniesByNameQuery creates the query from its required arguments.

func (SECCompaniesByNameQuery) Company added in v0.12.0

func (q SECCompaniesByNameQuery) Company() string

Company returns the company argument as given.

type SECCompaniesBySymbolQuery added in v0.12.0

type SECCompaniesBySymbolQuery struct {
	// contains filtered or unexported fields
}

SECCompaniesBySymbolQuery holds the query parameters of the endpoints that take it: NewSECCompaniesBySymbolQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewSECCompaniesBySymbolQuery added in v0.12.0

func NewSECCompaniesBySymbolQuery(symbol string) SECCompaniesBySymbolQuery

NewSECCompaniesBySymbolQuery creates the query from its required arguments.

func (SECCompaniesBySymbolQuery) Symbol added in v0.12.0

func (q SECCompaniesBySymbolQuery) Symbol() string

Symbol returns the symbol argument as given.

type SECCompanyProfile added in v0.12.0

type SECCompanyProfile struct {
	Symbol                  string          `json:"symbol"`
	CIK                     string          `json:"cik"`
	RegistrantName          string          `json:"registrantName"`
	SicCode                 string          `json:"sicCode"`
	SicDescription          string          `json:"sicDescription"`
	SicGroup                string          `json:"sicGroup"`
	ISIN                    string          `json:"isin"`
	BusinessAddress         string          `json:"businessAddress"`
	MailingAddress          string          `json:"mailingAddress"`
	PhoneNumber             string          `json:"phoneNumber"`
	PostalCode              string          `json:"postalCode"`
	City                    string          `json:"city"`
	State                   string          `json:"state"`
	Country                 string          `json:"country"`
	Description             string          `json:"description"`
	Ceo                     string          `json:"ceo"`
	Website                 string          `json:"website"`
	Exchange                string          `json:"exchange"`
	StateLocation           string          `json:"stateLocation"`
	StateOfIncorporation    string          `json:"stateOfIncorporation"`
	FiscalYearEnd           string          `json:"fiscalYearEnd"`
	IPODate                 Date            `json:"ipoDate"`
	Employees               string          `json:"employees"`
	SECFilingsURL           string          `json:"secFilingsUrl"`
	TaxIdentificationNumber string          `json:"taxIdentificationNumber"`
	FiftyTwoWeekRange       string          `json:"fiftyTwoWeekRange"`
	IsActive                bool            `json:"isActive"`
	AssetType               string          `json:"assetType"`
	OpenFigiComposite       string          `json:"openFigiComposite"`
	PriceCurrency           string          `json:"priceCurrency"`
	MarketSector            string          `json:"marketSector"`
	SecurityType            *jsontext.Value `json:"securityType"`
	IsETF                   bool            `json:"isEtf"`
	IsAdr                   bool            `json:"isAdr"`
	IsFund                  bool            `json:"isFund"`
}

SECCompanyProfile is one full SEC company profile.

func (*SECCompanyProfile) UnmarshalJSONFrom added in v0.12.0

func (m *SECCompanyProfile) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type SECCompanyProfileQuery added in v0.12.0

type SECCompanyProfileQuery struct {
	// contains filtered or unexported fields
}

SECCompanyProfileQuery holds the query parameters of the endpoints that take it: NewSECCompanyProfileQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewSECCompanyProfileQuery added in v0.12.0

func NewSECCompanyProfileQuery(symbol string) SECCompanyProfileQuery

NewSECCompanyProfileQuery creates the query from its required arguments.

func (SECCompanyProfileQuery) CIKA added in v0.12.0

func (q SECCompanyProfileQuery) CIKA() *string

CIKA returns the optional cik_a parameter, or nil when it is unset.

func (SECCompanyProfileQuery) Symbol added in v0.12.0

func (q SECCompanyProfileQuery) Symbol() string

Symbol returns the symbol argument as given.

func (SECCompanyProfileQuery) WithCIKA added in v0.12.0

WithCIKA sets the optional cik_a parameter and returns the updated query.

type SECCompanySearchResult added in v0.12.0

type SECCompanySearchResult struct {
	Symbol          string `json:"symbol"`
	Name            string `json:"name"`
	CIK             string `json:"cik"`
	SicCode         string `json:"sicCode"`
	IndustryTitle   string `json:"industryTitle"`
	BusinessAddress string `json:"businessAddress"`
	PhoneNumber     string `json:"phoneNumber"`
}

SECCompanySearchResult is one company identity returned by the three SEC company-search routes.

func (*SECCompanySearchResult) UnmarshalJSONFrom added in v0.12.0

func (m *SECCompanySearchResult) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type SECFiling added in v0.12.0

type SECFiling struct {
	Symbol        string   `json:"symbol"`
	CIK           string   `json:"cik"`
	FilingDate    DateTime `json:"filingDate"`
	AcceptedDate  DateTime `json:"acceptedDate"`
	FormType      string   `json:"formType"`
	HasFinancials *bool    `json:"hasFinancials"`
	Link          string   `json:"link"`
	FinalLink     string   `json:"finalLink"`
}

SECFiling is one SEC filing row shared by all five filing feeds and searches.

func (*SECFiling) UnmarshalJSONFrom added in v0.12.0

func (m *SECFiling) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type SECFilingsByCIKQuery added in v0.12.0

type SECFilingsByCIKQuery struct {
	// contains filtered or unexported fields
}

SECFilingsByCIKQuery holds the query parameters of the endpoints that take it: NewSECFilingsByCIKQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewSECFilingsByCIKQuery added in v0.12.0

func NewSECFilingsByCIKQuery(cik string, from Date, to Date) SECFilingsByCIKQuery

NewSECFilingsByCIKQuery creates the query from its required arguments.

func (SECFilingsByCIKQuery) CIK added in v0.12.0

func (q SECFilingsByCIKQuery) CIK() string

CIK returns the cik argument as given.

func (SECFilingsByCIKQuery) From added in v0.12.0

func (q SECFilingsByCIKQuery) From() Date

From returns the from argument as given.

func (SECFilingsByCIKQuery) Limit added in v0.12.0

func (q SECFilingsByCIKQuery) Limit() *uint32

Limit returns the optional limit parameter, or nil when it is unset.

func (SECFilingsByCIKQuery) Page added in v0.12.0

func (q SECFilingsByCIKQuery) Page() *uint32

Page returns the optional page parameter, or nil when it is unset.

func (SECFilingsByCIKQuery) To added in v0.12.0

func (q SECFilingsByCIKQuery) To() Date

To returns the to argument as given.

func (SECFilingsByCIKQuery) WithLimit added in v0.12.0

WithLimit sets the optional limit parameter and returns the updated query.

func (SECFilingsByCIKQuery) WithPage added in v0.12.0

WithPage sets the optional page parameter and returns the updated query.

type SECFilingsByFormTypeQuery added in v0.12.0

type SECFilingsByFormTypeQuery struct {
	// contains filtered or unexported fields
}

SECFilingsByFormTypeQuery holds the query parameters of the endpoints that take it: NewSECFilingsByFormTypeQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewSECFilingsByFormTypeQuery added in v0.12.0

func NewSECFilingsByFormTypeQuery(formType string, from Date, to Date) SECFilingsByFormTypeQuery

NewSECFilingsByFormTypeQuery creates the query from its required arguments.

func (SECFilingsByFormTypeQuery) FormType added in v0.12.0

func (q SECFilingsByFormTypeQuery) FormType() string

FormType returns the form_type argument as given.

func (SECFilingsByFormTypeQuery) From added in v0.12.0

From returns the from argument as given.

func (SECFilingsByFormTypeQuery) Limit added in v0.12.0

func (q SECFilingsByFormTypeQuery) Limit() *uint32

Limit returns the optional limit parameter, or nil when it is unset.

func (SECFilingsByFormTypeQuery) Page added in v0.12.0

Page returns the optional page parameter, or nil when it is unset.

func (SECFilingsByFormTypeQuery) To added in v0.12.0

To returns the to argument as given.

func (SECFilingsByFormTypeQuery) WithLimit added in v0.12.0

WithLimit sets the optional limit parameter and returns the updated query.

func (SECFilingsByFormTypeQuery) WithPage added in v0.12.0

WithPage sets the optional page parameter and returns the updated query.

type SECFilingsBySymbolQuery added in v0.12.0

type SECFilingsBySymbolQuery struct {
	// contains filtered or unexported fields
}

SECFilingsBySymbolQuery holds the query parameters of the endpoints that take it: NewSECFilingsBySymbolQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewSECFilingsBySymbolQuery added in v0.12.0

func NewSECFilingsBySymbolQuery(symbol string, from Date, to Date) SECFilingsBySymbolQuery

NewSECFilingsBySymbolQuery creates the query from its required arguments.

func (SECFilingsBySymbolQuery) From added in v0.12.0

func (q SECFilingsBySymbolQuery) From() Date

From returns the from argument as given.

func (SECFilingsBySymbolQuery) Limit added in v0.12.0

func (q SECFilingsBySymbolQuery) Limit() *uint32

Limit returns the optional limit parameter, or nil when it is unset.

func (SECFilingsBySymbolQuery) Page added in v0.12.0

func (q SECFilingsBySymbolQuery) Page() *uint32

Page returns the optional page parameter, or nil when it is unset.

func (SECFilingsBySymbolQuery) Symbol added in v0.12.0

func (q SECFilingsBySymbolQuery) Symbol() string

Symbol returns the symbol argument as given.

func (SECFilingsBySymbolQuery) To added in v0.12.0

To returns the to argument as given.

func (SECFilingsBySymbolQuery) WithLimit added in v0.12.0

WithLimit sets the optional limit parameter and returns the updated query.

func (SECFilingsBySymbolQuery) WithPage added in v0.12.0

WithPage sets the optional page parameter and returns the updated query.

type SECFilingsNamespace added in v0.12.0

type SECFilingsNamespace struct {
	// contains filtered or unexported fields
}

SECFilingsNamespace groups the sec_filings endpoints. It is reached as Client.SECFilings and is valid only when obtained from a Client built by NewClient.

func (*SECFilingsNamespace) AllIndustryClassifications added in v0.12.0

AllIndustryClassifications retrieves the paginated US company industry-classification feed.

GET all-industry-classification?page=&limit=

func (*SECFilingsNamespace) ByCIK added in v0.12.0

ByCIK retrieves US SEC filings for a string-backed CIK.

GET sec-filings-search/cik?cik=&from=&to=&page=&limit=

func (*SECFilingsNamespace) ByFormType added in v0.12.0

ByFormType retrieves US SEC filings by their open form type.

GET sec-filings-search/form-type?formType=&from=&to=&page=&limit=

func (*SECFilingsNamespace) BySymbol added in v0.12.0

BySymbol retrieves US SEC filings for a ticker.

GET sec-filings-search/symbol?symbol=&from=&to=&page=&limit=

func (*SECFilingsNamespace) CompanyProfile added in v0.12.0

CompanyProfile retrieves the full US SEC company profile for a ticker.

GET sec-profile?symbol=&cik-A=

func (*SECFilingsNamespace) IndustryClassifications added in v0.12.0

IndustryClassifications retrieves the US Standard Industrial Classification directory.

GET standard-industrial-classification-list?industryTitle=&sicCode=

func (*SECFilingsNamespace) Latest added in v0.12.0

Latest retrieves the latest US financial SEC filings within the required date range.

GET sec-filings-financials?from=&to=&page=&limit=

func (*SECFilingsNamespace) Latest8K added in v0.12.0

Latest8K retrieves the latest US 8-K SEC filings within the required date range.

GET sec-filings-8k?from=&to=&page=&limit=

func (*SECFilingsNamespace) SearchCompaniesByCIK added in v0.12.0

SearchCompaniesByCIK searches US SEC companies by string-backed CIK.

GET sec-filings-company-search/cik?cik=

func (*SECFilingsNamespace) SearchCompaniesByName added in v0.12.0

SearchCompaniesByName searches US SEC companies by company-name text.

GET sec-filings-company-search/name?company=

func (*SECFilingsNamespace) SearchCompaniesBySymbol added in v0.12.0

SearchCompaniesBySymbol searches US SEC companies by ticker.

GET sec-filings-company-search/symbol?symbol=

func (*SECFilingsNamespace) SearchIndustryClassifications added in v0.12.0

func (n *SECFilingsNamespace) SearchIndustryClassifications(ctx context.Context, q IndustryClassificationSearchQuery) ([]jsontext.Value, error)

SearchIndustryClassifications searches US industry classifications while preserving raw documented rows.

GET industry-classification-search?symbol=&cik=&sicCode=

type SafeBody

type SafeBody struct {
	Text      string
	Truncated bool
}

SafeBody is a redacted, bounded provider response body.

func NewSafeBody

func NewSafeBody(body string, redactor *Redactor) SafeBody

NewSafeBody redacts and bounds a body before it is retained in an Error.

func (SafeBody) String

func (b SafeBody) String() string

String returns the safe retained text.

type ScreenerNamespace

type ScreenerNamespace struct {
	// contains filtered or unexported fields
}

ScreenerNamespace groups the screener endpoints. It is reached as Client.Screener and is valid only when obtained from a Client built by NewClient.

func (*ScreenerNamespace) Companies

Companies screens worldwide companies using the supplied optional filters.

GET company-screener?marketCapMoreThan=&marketCapLowerThan=&sector=&industry=&betaMoreThan=&betaLowerThan=&priceMoreThan=&priceLowerThan=&dividendMoreThan=&dividendLowerThan=&volumeMoreThan=&volumeLowerThan=&exchange=&country=&isEtf=&isFund=&isActivelyTrading=&page=&limit=&includeAllShareClasses=

type SearchCryptoNewsQuery

type SearchCryptoNewsQuery struct {
	// contains filtered or unexported fields
}

SearchCryptoNewsQuery holds the query parameters of the endpoints that take it: NewSearchCryptoNewsQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewSearchCryptoNewsQuery

func NewSearchCryptoNewsQuery(symbols []string) SearchCryptoNewsQuery

NewSearchCryptoNewsQuery creates the query from its required arguments.

func (SearchCryptoNewsQuery) From

func (q SearchCryptoNewsQuery) From() *Date

From returns the optional from parameter, or nil when it is unset.

func (SearchCryptoNewsQuery) Limit

func (q SearchCryptoNewsQuery) Limit() *uint32

Limit returns the optional limit parameter, or nil when it is unset.

func (SearchCryptoNewsQuery) Page

func (q SearchCryptoNewsQuery) Page() *uint32

Page returns the optional page parameter, or nil when it is unset.

func (SearchCryptoNewsQuery) Symbols

func (q SearchCryptoNewsQuery) Symbols() []string

Symbols returns the symbols argument as given.

func (SearchCryptoNewsQuery) To

func (q SearchCryptoNewsQuery) To() *Date

To returns the optional to parameter, or nil when it is unset.

func (SearchCryptoNewsQuery) WithFrom

WithFrom sets the optional from parameter and returns the updated query.

func (SearchCryptoNewsQuery) WithLimit

WithLimit sets the optional limit parameter and returns the updated query.

func (SearchCryptoNewsQuery) WithPage

WithPage sets the optional page parameter and returns the updated query.

func (SearchCryptoNewsQuery) WithTo

WithTo sets the optional to parameter and returns the updated query.

type SearchForexNewsQuery

type SearchForexNewsQuery struct {
	// contains filtered or unexported fields
}

SearchForexNewsQuery holds the query parameters of the endpoints that take it: NewSearchForexNewsQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewSearchForexNewsQuery

func NewSearchForexNewsQuery(symbols []string) SearchForexNewsQuery

NewSearchForexNewsQuery creates the query from its required arguments.

func (SearchForexNewsQuery) From

func (q SearchForexNewsQuery) From() *Date

From returns the optional from parameter, or nil when it is unset.

func (SearchForexNewsQuery) Limit

func (q SearchForexNewsQuery) Limit() *uint32

Limit returns the optional limit parameter, or nil when it is unset.

func (SearchForexNewsQuery) Page

func (q SearchForexNewsQuery) Page() *uint32

Page returns the optional page parameter, or nil when it is unset.

func (SearchForexNewsQuery) Symbols

func (q SearchForexNewsQuery) Symbols() []string

Symbols returns the symbols argument as given.

func (SearchForexNewsQuery) To

func (q SearchForexNewsQuery) To() *Date

To returns the optional to parameter, or nil when it is unset.

func (SearchForexNewsQuery) WithFrom

WithFrom sets the optional from parameter and returns the updated query.

func (SearchForexNewsQuery) WithLimit

WithLimit sets the optional limit parameter and returns the updated query.

func (SearchForexNewsQuery) WithPage

WithPage sets the optional page parameter and returns the updated query.

func (SearchForexNewsQuery) WithTo

WithTo sets the optional to parameter and returns the updated query.

type SearchMergersAcquisitionsQuery added in v0.12.0

type SearchMergersAcquisitionsQuery struct {
	// contains filtered or unexported fields
}

SearchMergersAcquisitionsQuery holds the query parameters of the endpoints that take it: NewSearchMergersAcquisitionsQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewSearchMergersAcquisitionsQuery added in v0.12.0

func NewSearchMergersAcquisitionsQuery(name string) SearchMergersAcquisitionsQuery

NewSearchMergersAcquisitionsQuery creates the query from its required arguments.

func (SearchMergersAcquisitionsQuery) Name added in v0.12.0

Name returns the name argument as given.

type SearchNamespace

type SearchNamespace struct {
	// contains filtered or unexported fields
}

SearchNamespace groups the search endpoints. It is reached as Client.Search and is valid only when obtained from a Client built by NewClient.

func (*SearchNamespace) CIK added in v0.12.0

CIK searches US companies by Central Index Key.

GET search-cik?cik=&limit=

func (*SearchNamespace) CUSIP added in v0.12.0

CUSIP searches worldwide securities by CUSIP without constraining its length.

GET search-cusip?cusip=

func (*SearchNamespace) ExchangeVariants

func (n *SearchNamespace) ExchangeVariants(ctx context.Context, q ExchangeVariantsQuery) ([]ExchangeVariant, error)

ExchangeVariants finds worldwide exchange listings for a provider ticker.

GET search-exchange-variants?symbol=

func (*SearchNamespace) ISIN added in v0.12.0

ISIN searches worldwide securities by ISIN without constraining its length.

GET search-isin?isin=

func (*SearchNamespace) Name

Name searches worldwide companies and instruments by name.

GET search-name?query=&limit=&exchange=

func (*SearchNamespace) Symbol

Symbol searches worldwide companies and instruments by symbol.

GET search-symbol?query=&limit=&exchange=

type SearchPressReleasesQuery

type SearchPressReleasesQuery struct {
	// contains filtered or unexported fields
}

SearchPressReleasesQuery holds the query parameters of the endpoints that take it: NewSearchPressReleasesQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewSearchPressReleasesQuery

func NewSearchPressReleasesQuery(symbols []string) SearchPressReleasesQuery

NewSearchPressReleasesQuery creates the query from its required arguments.

func (SearchPressReleasesQuery) From

func (q SearchPressReleasesQuery) From() *Date

From returns the optional from parameter, or nil when it is unset.

func (SearchPressReleasesQuery) Limit

func (q SearchPressReleasesQuery) Limit() *uint32

Limit returns the optional limit parameter, or nil when it is unset.

func (SearchPressReleasesQuery) Page

func (q SearchPressReleasesQuery) Page() *uint32

Page returns the optional page parameter, or nil when it is unset.

func (SearchPressReleasesQuery) Symbols

func (q SearchPressReleasesQuery) Symbols() []string

Symbols returns the symbols argument as given.

func (SearchPressReleasesQuery) To

To returns the optional to parameter, or nil when it is unset.

func (SearchPressReleasesQuery) WithFrom

WithFrom sets the optional from parameter and returns the updated query.

func (SearchPressReleasesQuery) WithLimit

WithLimit sets the optional limit parameter and returns the updated query.

func (SearchPressReleasesQuery) WithPage

WithPage sets the optional page parameter and returns the updated query.

func (SearchPressReleasesQuery) WithTo

WithTo sets the optional to parameter and returns the updated query.

type SearchStockNewsQuery

type SearchStockNewsQuery struct {
	// contains filtered or unexported fields
}

SearchStockNewsQuery holds the query parameters of the endpoints that take it: NewSearchStockNewsQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewSearchStockNewsQuery

func NewSearchStockNewsQuery(symbols []string) SearchStockNewsQuery

NewSearchStockNewsQuery creates the query from its required arguments.

func (SearchStockNewsQuery) From

func (q SearchStockNewsQuery) From() *Date

From returns the optional from parameter, or nil when it is unset.

func (SearchStockNewsQuery) Limit

func (q SearchStockNewsQuery) Limit() *uint32

Limit returns the optional limit parameter, or nil when it is unset.

func (SearchStockNewsQuery) Page

func (q SearchStockNewsQuery) Page() *uint32

Page returns the optional page parameter, or nil when it is unset.

func (SearchStockNewsQuery) Symbols

func (q SearchStockNewsQuery) Symbols() []string

Symbols returns the symbols argument as given.

func (SearchStockNewsQuery) To

func (q SearchStockNewsQuery) To() *Date

To returns the optional to parameter, or nil when it is unset.

func (SearchStockNewsQuery) WithFrom

WithFrom sets the optional from parameter and returns the updated query.

func (SearchStockNewsQuery) WithLimit

WithLimit sets the optional limit parameter and returns the updated query.

func (SearchStockNewsQuery) WithPage

WithPage sets the optional page parameter and returns the updated query.

func (SearchStockNewsQuery) WithTo

WithTo sets the optional to parameter and returns the updated query.

type SectorPe

type SectorPe struct {
	Date     Date    `json:"date"`
	Sector   string  `json:"sector"`
	Exchange string  `json:"exchange"`
	Pe       float64 `json:"pe"`
}

SectorPe is one dated sector-level price-to-earnings ratio.

func (*SectorPe) UnmarshalJSONFrom

func (m *SectorPe) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type SectorPeSnapshotQuery

type SectorPeSnapshotQuery struct {
	// contains filtered or unexported fields
}

SectorPeSnapshotQuery holds the query parameters of the endpoints that take it: NewSectorPeSnapshotQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewSectorPeSnapshotQuery

func NewSectorPeSnapshotQuery(date Date) SectorPeSnapshotQuery

NewSectorPeSnapshotQuery creates the query from its required arguments.

func (SectorPeSnapshotQuery) Date

func (q SectorPeSnapshotQuery) Date() Date

Date returns the date argument as given.

func (SectorPeSnapshotQuery) Exchange

func (q SectorPeSnapshotQuery) Exchange() *string

Exchange returns the optional exchange parameter, or nil when it is unset.

func (SectorPeSnapshotQuery) Sector

func (q SectorPeSnapshotQuery) Sector() *string

Sector returns the optional sector parameter, or nil when it is unset.

func (SectorPeSnapshotQuery) WithExchange

func (q SectorPeSnapshotQuery) WithExchange(exchange string) SectorPeSnapshotQuery

WithExchange sets the optional exchange parameter and returns the updated query.

func (SectorPeSnapshotQuery) WithSector

func (q SectorPeSnapshotQuery) WithSector(sector string) SectorPeSnapshotQuery

WithSector sets the optional sector parameter and returns the updated query.

type SectorPerformance

type SectorPerformance struct {
	Date          Date    `json:"date"`
	Sector        string  `json:"sector"`
	Exchange      string  `json:"exchange"`
	AverageChange float64 `json:"averageChange"`
}

SectorPerformance is one dated sector-level average market change.

func (*SectorPerformance) UnmarshalJSONFrom

func (m *SectorPerformance) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type SectorPerformanceSnapshotQuery

type SectorPerformanceSnapshotQuery struct {
	// contains filtered or unexported fields
}

SectorPerformanceSnapshotQuery holds the query parameters of the endpoints that take it: NewSectorPerformanceSnapshotQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewSectorPerformanceSnapshotQuery

func NewSectorPerformanceSnapshotQuery(date Date) SectorPerformanceSnapshotQuery

NewSectorPerformanceSnapshotQuery creates the query from its required arguments.

func (SectorPerformanceSnapshotQuery) Date

Date returns the date argument as given.

func (SectorPerformanceSnapshotQuery) Exchange

func (q SectorPerformanceSnapshotQuery) Exchange() *string

Exchange returns the optional exchange parameter, or nil when it is unset.

func (SectorPerformanceSnapshotQuery) Sector

Sector returns the optional sector parameter, or nil when it is unset.

func (SectorPerformanceSnapshotQuery) WithExchange

WithExchange sets the optional exchange parameter and returns the updated query.

func (SectorPerformanceSnapshotQuery) WithSector

WithSector sets the optional sector parameter and returns the updated query.

type SegmentationStructure

type SegmentationStructure string

SegmentationStructure is the documented response structure of the revenue-segmentation endpoints. The provider documents only "flat"; the libfmp SegmentationStructure is a closed enum with that one variant, so any other value is rejected when the request is built.

const (
	SegmentationStructureFlat SegmentationStructure = "flat"
)

The documented SegmentationStructure wire values.

type ShareFloat added in v0.12.0

type ShareFloat struct {
	Symbol            string   `json:"symbol"`
	Date              DateTime `json:"date"`
	FreeFloat         float64  `json:"freeFloat"`
	FloatShares       float64  `json:"floatShares"`
	OutstandingShares float64  `json:"outstandingShares"`
}

ShareFloat is one all-company share-float observation, whose payload has no source field.

func (*ShareFloat) UnmarshalJSONFrom added in v0.12.0

func (m *ShareFloat) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type SharesFloatQuery

type SharesFloatQuery struct {
	// contains filtered or unexported fields
}

SharesFloatQuery holds the query parameters of the endpoints that take it: NewSharesFloatQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewSharesFloatQuery

func NewSharesFloatQuery(symbol string) SharesFloatQuery

NewSharesFloatQuery creates the query from its required arguments.

func (SharesFloatQuery) Symbol

func (q SharesFloatQuery) Symbol() string

Symbol returns the symbol argument as given.

type SicClassification

type SicClassification struct {
	Office        string `json:"office"`
	SicCode       string `json:"sicCode"`
	IndustryTitle string `json:"industryTitle"`
}

SicClassification is one Standard Industrial Classification directory row.

func (*SicClassification) UnmarshalJSONFrom

func (m *SicClassification) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type SimpleMovingAverageBar

type SimpleMovingAverageBar struct {
	Date   DateTime `json:"date"`
	Open   float64  `json:"open"`
	High   float64  `json:"high"`
	Low    float64  `json:"low"`
	Close  float64  `json:"close"`
	Volume float64  `json:"volume"`
	Sma    float64  `json:"sma"`
}

SimpleMovingAverageBar is a response model of the technical_indicators domain.

func (*SimpleMovingAverageBar) UnmarshalJSONFrom

func (m *SimpleMovingAverageBar) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type StandardDeviationBar

type StandardDeviationBar struct {
	Date              DateTime `json:"date"`
	Open              float64  `json:"open"`
	High              float64  `json:"high"`
	Low               float64  `json:"low"`
	Close             float64  `json:"close"`
	Volume            float64  `json:"volume"`
	StandardDeviation float64  `json:"standardDeviation"`
}

StandardDeviationBar is a response model of the technical_indicators domain.

func (*StandardDeviationBar) UnmarshalJSONFrom

func (m *StandardDeviationBar) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type StatementPeriod

type StatementPeriod string

StatementPeriod is the seven-value period selector of the standard statement endpoints: a FiscalPeriod or a RetrievalFrequency, as the libfmp StatementPeriod union composes them. The constants repeat the wire spellings of both families so a caller can pass either; any other value is rejected when the request is built.

const (
	StatementPeriodQ1        StatementPeriod = "Q1"
	StatementPeriodQ2        StatementPeriod = "Q2"
	StatementPeriodQ3        StatementPeriod = "Q3"
	StatementPeriodQ4        StatementPeriod = "Q4"
	StatementPeriodFullYear  StatementPeriod = "FY"
	StatementPeriodAnnual    StatementPeriod = "annual"
	StatementPeriodQuarterly StatementPeriod = "quarter"
)

The documented StatementPeriod wire values: the FiscalPeriod family first, then the RetrievalFrequency family.

type StatementsAsReportedNamespace

type StatementsAsReportedNamespace struct {
	// contains filtered or unexported fields
}

StatementsAsReportedNamespace groups the statements.as_reported endpoints. It is reached as Client.Statements.AsReported and is valid only when obtained from a Client built by NewClient.

func (*StatementsAsReportedNamespace) BalanceSheet

BalanceSheet retrieves balance sheets as reported by one company.

GET balance-sheet-statement-as-reported?symbol=&limit=&period=

func (*StatementsAsReportedNamespace) CashFlow

CashFlow retrieves cash-flow statements as reported by one company.

GET cash-flow-statement-as-reported?symbol=&limit=&period=

func (*StatementsAsReportedNamespace) Full

Full retrieves complete financial statements as reported by one company.

GET financial-statement-full-as-reported?symbol=&limit=&period=

func (*StatementsAsReportedNamespace) Income

Income retrieves income statements as reported by one company.

GET income-statement-as-reported?symbol=&limit=&period=

type StatementsBalanceNamespace

type StatementsBalanceNamespace struct {
	// contains filtered or unexported fields
}

StatementsBalanceNamespace groups the statements.balance endpoints. It is reached as Client.Statements.Balance and is valid only when obtained from a Client built by NewClient.

func (*StatementsBalanceNamespace) Statement

Statement retrieves historical worldwide balance sheets for one company.

GET balance-sheet-statement?symbol=&limit=&period=

func (*StatementsBalanceNamespace) StatementTTM added in v0.12.0

StatementTTM retrieves trailing-twelve-month worldwide balance sheets for one company.

GET balance-sheet-statement-ttm?symbol=&limit=

type StatementsCashFlowNamespace

type StatementsCashFlowNamespace struct {
	// contains filtered or unexported fields
}

StatementsCashFlowNamespace groups the statements.cash_flow endpoints. It is reached as Client.Statements.CashFlow and is valid only when obtained from a Client built by NewClient.

func (*StatementsCashFlowNamespace) Statement

Statement retrieves historical worldwide cash-flow statements for one company.

GET cash-flow-statement?symbol=&limit=&period=

func (*StatementsCashFlowNamespace) StatementTTM added in v0.12.0

StatementTTM retrieves trailing-twelve-month worldwide cash-flow statements for one company.

GET cash-flow-statement-ttm?symbol=&limit=

type StatementsGrowthNamespace

type StatementsGrowthNamespace struct {
	// contains filtered or unexported fields
}

StatementsGrowthNamespace groups the statements.growth endpoints. It is reached as Client.Statements.Growth and is valid only when obtained from a Client built by NewClient.

func (*StatementsGrowthNamespace) BalanceSheet added in v0.12.0

BalanceSheet retrieves worldwide balance-sheet-statement growth for one company.

GET balance-sheet-statement-growth?symbol=&limit=&period=

func (*StatementsGrowthNamespace) CashFlow added in v0.12.0

CashFlow retrieves worldwide cash-flow-statement growth for one company.

GET cash-flow-statement-growth?symbol=&limit=&period=

func (*StatementsGrowthNamespace) Financial added in v0.12.0

Financial retrieves combined worldwide financial-statement growth for one company.

GET financial-growth?symbol=&limit=&period=

func (*StatementsGrowthNamespace) Income added in v0.12.0

Income retrieves worldwide income-statement growth for one company.

GET income-statement-growth?symbol=&limit=&period=

type StatementsIncomeNamespace

type StatementsIncomeNamespace struct {
	// contains filtered or unexported fields
}

StatementsIncomeNamespace groups the statements.income endpoints. It is reached as Client.Statements.Income and is valid only when obtained from a Client built by NewClient.

func (*StatementsIncomeNamespace) Statement

Statement retrieves historical worldwide income statements for one company.

GET income-statement?symbol=&limit=&period=

func (*StatementsIncomeNamespace) StatementTTM added in v0.12.0

StatementTTM retrieves trailing-twelve-month worldwide income statements for one company.

GET income-statement-ttm?symbol=&limit=

type StatementsMetricsNamespace

type StatementsMetricsNamespace struct {
	// contains filtered or unexported fields
}

StatementsMetricsNamespace groups the statements.metrics endpoints. It is reached as Client.Statements.Metrics and is valid only when obtained from a Client built by NewClient.

func (*StatementsMetricsNamespace) KeyMetrics

KeyMetrics retrieves historical worldwide key metrics for one company.

GET key-metrics?symbol=&limit=&period=

func (*StatementsMetricsNamespace) KeyMetricsTTM added in v0.12.0

KeyMetricsTTM retrieves worldwide trailing-twelve-month key metrics for one company.

GET key-metrics-ttm?symbol=

type StatementsNamespace

type StatementsNamespace struct {

	// AsReported groups the statements.as_reported endpoints of the statements domain.
	AsReported StatementsAsReportedNamespace
	// Balance groups the statements.balance endpoints of the statements domain.
	Balance StatementsBalanceNamespace
	// CashFlow groups the statements.cash_flow endpoints of the statements domain.
	CashFlow StatementsCashFlowNamespace
	// Growth groups the statements.growth endpoints of the statements domain.
	Growth StatementsGrowthNamespace
	// Income groups the statements.income endpoints of the statements domain.
	Income StatementsIncomeNamespace
	// Metrics groups the statements.metrics endpoints of the statements domain.
	Metrics StatementsMetricsNamespace
	// Ratios groups the statements.ratios endpoints of the statements domain.
	Ratios StatementsRatiosNamespace
	// Reports groups the statements.reports endpoints of the statements domain.
	Reports StatementsReportsNamespace
	// Segmentation groups the statements.segmentation endpoints of the statements domain.
	Segmentation StatementsSegmentationNamespace
	// Summaries groups the statements.summaries endpoints of the statements domain.
	Summaries StatementsSummariesNamespace
	// contains filtered or unexported fields
}

StatementsNamespace groups the statements endpoints. It is reached as Client.Statements and is valid only when obtained from a Client built by NewClient.

type StatementsRatiosNamespace

type StatementsRatiosNamespace struct {
	// contains filtered or unexported fields
}

StatementsRatiosNamespace groups the statements.ratios endpoints. It is reached as Client.Statements.Ratios and is valid only when obtained from a Client built by NewClient.

func (*StatementsRatiosNamespace) FinancialRatios

FinancialRatios retrieves historical worldwide financial ratios for one company.

GET ratios?symbol=&limit=&period=

func (*StatementsRatiosNamespace) FinancialRatiosTTM added in v0.12.0

FinancialRatiosTTM retrieves trailing-twelve-month worldwide financial ratios for one company.

GET ratios-ttm?symbol=

type StatementsReportsNamespace

type StatementsReportsNamespace struct {
	// contains filtered or unexported fields
}

StatementsReportsNamespace groups the statements.reports endpoints. It is reached as Client.Statements.Reports and is valid only when obtained from a Client built by NewClient.

func (*StatementsReportsNamespace) Dates

Dates retrieves available financial-report periods and protected download links.

GET financial-reports-dates?symbol=

func (*StatementsReportsNamespace) JSON added in v0.12.0

JSON retrieves one dynamic JSON financial report as a bare array.

GET financial-reports-json?symbol=&year=&period=

func (*StatementsReportsNamespace) Xlsx

Xlsx downloads one financial report using the endpoint's XLSX MIME policy.

GET financial-reports-xlsx?symbol=&year=&period=

type StatementsSegmentationNamespace

type StatementsSegmentationNamespace struct {
	// contains filtered or unexported fields
}

StatementsSegmentationNamespace groups the statements.segmentation endpoints. It is reached as Client.Statements.Segmentation and is valid only when obtained from a Client built by NewClient.

func (*StatementsSegmentationNamespace) RevenueGeographic

RevenueGeographic retrieves geographic revenue segmentation for one company.

GET revenue-geographic-segmentation?symbol=&period=&structure=

func (*StatementsSegmentationNamespace) RevenueProduct

RevenueProduct retrieves product revenue segmentation for one company.

GET revenue-product-segmentation?symbol=&period=&structure=

type StatementsSummariesNamespace

type StatementsSummariesNamespace struct {
	// contains filtered or unexported fields
}

StatementsSummariesNamespace groups the statements.summaries endpoints. It is reached as Client.Statements.Summaries and is valid only when obtained from a Client built by NewClient.

func (*StatementsSummariesNamespace) EnterpriseValues

EnterpriseValues retrieves worldwide enterprise values for one company.

GET enterprise-values?symbol=&limit=&period=

func (*StatementsSummariesNamespace) FinancialScores

FinancialScores retrieves worldwide financial-health scores for one company.

GET financial-scores?symbol=

func (*StatementsSummariesNamespace) LatestFinancialStatements

LatestFinancialStatements retrieves the latest worldwide financial-statement filings.

GET latest-financial-statements?page=&limit=

func (*StatementsSummariesNamespace) OwnerEarnings

OwnerEarnings retrieves worldwide owner earnings for one company.

GET owner-earnings?symbol=&limit=

type StockChartAdjustedBar

type StockChartAdjustedBar struct {
	Symbol   string  `json:"symbol"`
	Date     Date    `json:"date"`
	AdjOpen  float64 `json:"adjOpen"`
	AdjHigh  float64 `json:"adjHigh"`
	AdjLow   float64 `json:"adjLow"`
	AdjClose float64 `json:"adjClose"`
	Volume   float64 `json:"volume"`
}

StockChartAdjustedBar is one split-unadjusted or dividend-adjusted end-of-day stock chart row.

func (*StockChartAdjustedBar) UnmarshalJSONFrom

func (m *StockChartAdjustedBar) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type StockChartEodQuery

type StockChartEodQuery struct {
	// contains filtered or unexported fields
}

StockChartEodQuery holds the query parameters of the endpoints that take it: NewStockChartEodQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewStockChartEodQuery

func NewStockChartEodQuery(symbol string) StockChartEodQuery

NewStockChartEodQuery creates the query from its required arguments.

func (StockChartEodQuery) From

func (q StockChartEodQuery) From() *Date

From returns the optional from parameter, or nil when it is unset.

func (StockChartEodQuery) Symbol

func (q StockChartEodQuery) Symbol() string

Symbol returns the symbol argument as given.

func (StockChartEodQuery) To

func (q StockChartEodQuery) To() *Date

To returns the optional to parameter, or nil when it is unset.

func (StockChartEodQuery) WithFrom

func (q StockChartEodQuery) WithFrom(from Date) StockChartEodQuery

WithFrom sets the optional from parameter and returns the updated query.

func (StockChartEodQuery) WithTo

WithTo sets the optional to parameter and returns the updated query.

type StockChartFullBar

type StockChartFullBar struct {
	Symbol        string  `json:"symbol"`
	Date          Date    `json:"date"`
	Open          float64 `json:"open"`
	High          float64 `json:"high"`
	Low           float64 `json:"low"`
	Close         float64 `json:"close"`
	Volume        float64 `json:"volume"`
	Change        float64 `json:"change"`
	ChangePercent float64 `json:"changePercent"`
	Vwap          float64 `json:"vwap"`
}

StockChartFullBar is one detailed end-of-day stock chart row.

func (*StockChartFullBar) UnmarshalJSONFrom

func (m *StockChartFullBar) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type StockChartIntradayBar

type StockChartIntradayBar struct {
	Date   DateTime `json:"date"`
	Open   float64  `json:"open"`
	Low    float64  `json:"low"`
	High   float64  `json:"high"`
	Close  float64  `json:"close"`
	Volume float64  `json:"volume"`
}

StockChartIntradayBar is one fixed-interval intraday stock chart row.

func (*StockChartIntradayBar) UnmarshalJSONFrom

func (m *StockChartIntradayBar) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type StockChartIntradayQuery

type StockChartIntradayQuery struct {
	// contains filtered or unexported fields
}

StockChartIntradayQuery holds the query parameters of the endpoints that take it: NewStockChartIntradayQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewStockChartIntradayQuery

func NewStockChartIntradayQuery(symbol string) StockChartIntradayQuery

NewStockChartIntradayQuery creates the query from its required arguments.

func (StockChartIntradayQuery) Extended

func (q StockChartIntradayQuery) Extended() *bool

Extended returns the optional extended parameter, or nil when it is unset.

func (StockChartIntradayQuery) From

func (q StockChartIntradayQuery) From() *Date

From returns the optional from parameter, or nil when it is unset.

func (StockChartIntradayQuery) Nonadjusted

func (q StockChartIntradayQuery) Nonadjusted() *bool

Nonadjusted returns the optional nonadjusted parameter, or nil when it is unset.

func (StockChartIntradayQuery) Symbol

func (q StockChartIntradayQuery) Symbol() string

Symbol returns the symbol argument as given.

func (StockChartIntradayQuery) To

func (q StockChartIntradayQuery) To() *Date

To returns the optional to parameter, or nil when it is unset.

func (StockChartIntradayQuery) WithExtended

func (q StockChartIntradayQuery) WithExtended(extended bool) StockChartIntradayQuery

WithExtended sets the optional extended parameter and returns the updated query.

func (StockChartIntradayQuery) WithFrom

WithFrom sets the optional from parameter and returns the updated query.

func (StockChartIntradayQuery) WithNonadjusted

func (q StockChartIntradayQuery) WithNonadjusted(nonadjusted bool) StockChartIntradayQuery

WithNonadjusted sets the optional nonadjusted parameter and returns the updated query.

func (StockChartIntradayQuery) WithTo

WithTo sets the optional to parameter and returns the updated query.

type StockChartLightBar

type StockChartLightBar struct {
	Symbol string  `json:"symbol"`
	Date   Date    `json:"date"`
	Price  float64 `json:"price"`
	Volume float64 `json:"volume"`
}

StockChartLightBar is one compact end-of-day stock chart row.

func (*StockChartLightBar) UnmarshalJSONFrom

func (m *StockChartLightBar) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type StockGrade

type StockGrade struct {
	Symbol         string `json:"symbol"`
	Date           Date   `json:"date"`
	GradingCompany string `json:"gradingCompany"`
	PreviousGrade  string `json:"previousGrade"`
	NewGrade       string `json:"newGrade"`
	Action         string `json:"action"`
}

StockGrade is one dated stock-grade action from an analyst or institution.

func (*StockGrade) UnmarshalJSONFrom

func (m *StockGrade) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type StockGradesQuery

type StockGradesQuery struct {
	// contains filtered or unexported fields
}

StockGradesQuery holds the query parameters of the endpoints that take it: NewStockGradesQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewStockGradesQuery

func NewStockGradesQuery(symbol string) StockGradesQuery

NewStockGradesQuery creates the query from its required arguments.

func (StockGradesQuery) Symbol

func (q StockGradesQuery) Symbol() string

Symbol returns the symbol argument as given.

type StockGradesSummary

type StockGradesSummary struct {
	Symbol     string `json:"symbol"`
	StrongBuy  uint64 `json:"strongBuy"`
	Buy        uint64 `json:"buy"`
	Hold       uint64 `json:"hold"`
	Sell       uint64 `json:"sell"`
	StrongSell uint64 `json:"strongSell"`
	Consensus  string `json:"consensus"`
}

StockGradesSummary is current analyst rating-bucket counts and their consensus label.

func (*StockGradesSummary) UnmarshalJSONFrom

func (m *StockGradesSummary) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type StockGradesSummaryQuery

type StockGradesSummaryQuery struct {
	// contains filtered or unexported fields
}

StockGradesSummaryQuery holds the query parameters of the endpoints that take it: NewStockGradesSummaryQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewStockGradesSummaryQuery

func NewStockGradesSummaryQuery(symbol string) StockGradesSummaryQuery

NewStockGradesSummaryQuery creates the query from its required arguments.

func (StockGradesSummaryQuery) Symbol

func (q StockGradesSummaryQuery) Symbol() string

Symbol returns the symbol argument as given.

type StockPeer

type StockPeer struct {
	Symbol      string  `json:"symbol"`
	CompanyName string  `json:"companyName"`
	Price       float64 `json:"price"`
	MarketCap   float64 `json:"mktCap"`
}

StockPeer is one worldwide stock peer selected by the provider.

func (*StockPeer) UnmarshalJSONFrom

func (m *StockPeer) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type StockPeersQuery

type StockPeersQuery struct {
	// contains filtered or unexported fields
}

StockPeersQuery holds the query parameters of the endpoints that take it: NewStockPeersQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewStockPeersQuery

func NewStockPeersQuery(symbol string) StockPeersQuery

NewStockPeersQuery creates the query from its required arguments.

func (StockPeersQuery) Symbol

func (q StockPeersQuery) Symbol() string

Symbol returns the symbol argument as given.

type StockPriceChange

type StockPriceChange struct {
	Symbol      string  `json:"symbol"`
	OneDay      float64 `json:"1D"`
	FiveDays    float64 `json:"5D"`
	OneMonth    float64 `json:"1M"`
	ThreeMonths float64 `json:"3M"`
	SixMonths   float64 `json:"6M"`
	YearToDate  float64 `json:"ytd"`
	OneYear     float64 `json:"1Y"`
	ThreeYears  float64 `json:"3Y"`
	FiveYears   float64 `json:"5Y"`
	TenYears    float64 `json:"10Y"`
	Max         float64 `json:"max"`
}

StockPriceChange is percentage changes for one stock across the provider's documented periods.

func (*StockPriceChange) UnmarshalJSONFrom

func (m *StockPriceChange) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type StockPriceChangeQuery

type StockPriceChangeQuery struct {
	// contains filtered or unexported fields
}

StockPriceChangeQuery holds the query parameters of the endpoints that take it: NewStockPriceChangeQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewStockPriceChangeQuery

func NewStockPriceChangeQuery(symbol string) StockPriceChangeQuery

NewStockPriceChangeQuery creates the query from its required arguments.

func (StockPriceChangeQuery) Symbol

func (q StockPriceChangeQuery) Symbol() string

Symbol returns the symbol argument as given.

type StockSplitEvent

type StockSplitEvent struct {
	Symbol      string  `json:"symbol"`
	Date        Date    `json:"date"`
	Numerator   float64 `json:"numerator"`
	Denominator float64 `json:"denominator"`
	SplitType   string  `json:"splitType"`
}

StockSplitEvent is one company or market-wide stock-split event.

func (*StockSplitEvent) UnmarshalJSONFrom

func (m *StockSplitEvent) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type StockSplitsCalendarQuery

type StockSplitsCalendarQuery struct {
	// contains filtered or unexported fields
}

StockSplitsCalendarQuery holds the query parameters of the endpoints that take it: NewStockSplitsCalendarQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewStockSplitsCalendarQuery

func NewStockSplitsCalendarQuery() StockSplitsCalendarQuery

NewStockSplitsCalendarQuery creates the query from its required arguments.

func (StockSplitsCalendarQuery) From

func (q StockSplitsCalendarQuery) From() *Date

From returns the optional from parameter, or nil when it is unset.

func (StockSplitsCalendarQuery) Page

func (q StockSplitsCalendarQuery) Page() *uint32

Page returns the optional page parameter, or nil when it is unset.

func (StockSplitsCalendarQuery) To

To returns the optional to parameter, or nil when it is unset.

func (StockSplitsCalendarQuery) WithFrom

WithFrom sets the optional from parameter and returns the updated query.

func (StockSplitsCalendarQuery) WithPage

WithPage sets the optional page parameter and returns the updated query.

func (StockSplitsCalendarQuery) WithTo

WithTo sets the optional to parameter and returns the updated query.

type StockSplitsQuery

type StockSplitsQuery struct {
	// contains filtered or unexported fields
}

StockSplitsQuery holds the query parameters of the endpoints that take it: NewStockSplitsQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewStockSplitsQuery

func NewStockSplitsQuery(symbol string) StockSplitsQuery

NewStockSplitsQuery creates the query from its required arguments.

func (StockSplitsQuery) Limit

func (q StockSplitsQuery) Limit() *uint32

Limit returns the optional limit parameter, or nil when it is unset.

func (StockSplitsQuery) Symbol

func (q StockSplitsQuery) Symbol() string

Symbol returns the symbol argument as given.

func (StockSplitsQuery) WithLimit

func (q StockSplitsQuery) WithLimit(limit uint32) StockSplitsQuery

WithLimit sets the optional limit parameter and returns the updated query.

type SymbolChange

type SymbolChange struct {
	Date        Date   `json:"date"`
	CompanyName string `json:"companyName"`
	OldSymbol   string `json:"oldSymbol"`
	NewSymbol   string `json:"newSymbol"`
}

SymbolChange is one US company symbol change.

func (*SymbolChange) UnmarshalJSONFrom

func (m *SymbolChange) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type SymbolChangesQuery

type SymbolChangesQuery struct {
	// contains filtered or unexported fields
}

SymbolChangesQuery holds the query parameters of the endpoints that take it: NewSymbolChangesQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewSymbolChangesQuery

func NewSymbolChangesQuery() SymbolChangesQuery

NewSymbolChangesQuery creates the query from its required arguments.

func (SymbolChangesQuery) Invalid

func (q SymbolChangesQuery) Invalid() *bool

Invalid returns the optional invalid parameter, or nil when it is unset.

func (SymbolChangesQuery) Limit

func (q SymbolChangesQuery) Limit() *uint32

Limit returns the optional limit parameter, or nil when it is unset.

func (SymbolChangesQuery) WithInvalid

func (q SymbolChangesQuery) WithInvalid(invalid bool) SymbolChangesQuery

WithInvalid sets the optional invalid parameter and returns the updated query.

func (SymbolChangesQuery) WithLimit

func (q SymbolChangesQuery) WithLimit(limit uint32) SymbolChangesQuery

WithLimit sets the optional limit parameter and returns the updated query.

type SymbolSearchQuery

type SymbolSearchQuery struct {
	// contains filtered or unexported fields
}

SymbolSearchQuery holds the query parameters of the endpoints that take it: NewSymbolSearchQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewSymbolSearchQuery

func NewSymbolSearchQuery(query string) SymbolSearchQuery

NewSymbolSearchQuery creates the query from its required arguments.

func (SymbolSearchQuery) Exchange

func (q SymbolSearchQuery) Exchange() *string

Exchange returns the optional exchange parameter, or nil when it is unset.

func (SymbolSearchQuery) Limit

func (q SymbolSearchQuery) Limit() *uint32

Limit returns the optional limit parameter, or nil when it is unset.

func (SymbolSearchQuery) Query

func (q SymbolSearchQuery) Query() string

Query returns the query argument as given.

func (SymbolSearchQuery) WithExchange

func (q SymbolSearchQuery) WithExchange(exchange string) SymbolSearchQuery

WithExchange sets the optional exchange parameter and returns the updated query.

func (SymbolSearchQuery) WithLimit

func (q SymbolSearchQuery) WithLimit(limit uint32) SymbolSearchQuery

WithLimit sets the optional limit parameter and returns the updated query.

type SymbolSearchResult

type SymbolSearchResult struct {
	Symbol           string `json:"symbol"`
	Name             string `json:"name"`
	Currency         string `json:"currency"`
	ExchangeFullName string `json:"exchangeFullName"`
	Exchange         string `json:"exchange"`
}

SymbolSearchResult is a company or instrument returned by symbol search.

func (*SymbolSearchResult) UnmarshalJSONFrom

func (m *SymbolSearchResult) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type TechnicalIndicatorQuery

type TechnicalIndicatorQuery struct {
	// contains filtered or unexported fields
}

TechnicalIndicatorQuery holds the query parameters of the endpoints that take it: NewTechnicalIndicatorQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewTechnicalIndicatorQuery

func NewTechnicalIndicatorQuery(symbol string, periodLength uint32, timeframe ChartTimeframe) TechnicalIndicatorQuery

NewTechnicalIndicatorQuery creates the query from its required arguments.

func (TechnicalIndicatorQuery) From

func (q TechnicalIndicatorQuery) From() *Date

From returns the optional from parameter, or nil when it is unset.

func (TechnicalIndicatorQuery) PeriodLength

func (q TechnicalIndicatorQuery) PeriodLength() uint32

PeriodLength returns the period_length argument as given.

func (TechnicalIndicatorQuery) Symbol

func (q TechnicalIndicatorQuery) Symbol() string

Symbol returns the symbol argument as given.

func (TechnicalIndicatorQuery) Timeframe

Timeframe returns the timeframe argument as given.

func (TechnicalIndicatorQuery) To

func (q TechnicalIndicatorQuery) To() *Date

To returns the optional to parameter, or nil when it is unset.

func (TechnicalIndicatorQuery) WithFrom

WithFrom sets the optional from parameter and returns the updated query.

func (TechnicalIndicatorQuery) WithTo

WithTo sets the optional to parameter and returns the updated query.

type TechnicalIndicatorsNamespace

type TechnicalIndicatorsNamespace struct {
	// contains filtered or unexported fields
}

TechnicalIndicatorsNamespace groups the technical_indicators endpoints. It is reached as Client.TechnicalIndicators and is valid only when obtained from a Client built by NewClient.

func (*TechnicalIndicatorsNamespace) AverageDirectionalIndex

AverageDirectionalIndex retrieves worldwide average-directional-index bars.

GET technical-indicators/adx?symbol=&periodLength=&timeframe=&from=&to=

func (*TechnicalIndicatorsNamespace) DoubleExponentialMovingAverage

DoubleExponentialMovingAverage retrieves worldwide double-exponential-moving-average bars.

GET technical-indicators/dema?symbol=&periodLength=&timeframe=&from=&to=

func (*TechnicalIndicatorsNamespace) ExponentialMovingAverage

ExponentialMovingAverage retrieves worldwide exponential-moving-average bars.

GET technical-indicators/ema?symbol=&periodLength=&timeframe=&from=&to=

func (*TechnicalIndicatorsNamespace) RelativeStrengthIndex

RelativeStrengthIndex retrieves worldwide relative-strength-index bars.

GET technical-indicators/rsi?symbol=&periodLength=&timeframe=&from=&to=

func (*TechnicalIndicatorsNamespace) SimpleMovingAverage

SimpleMovingAverage retrieves worldwide simple-moving-average bars.

GET technical-indicators/sma?symbol=&periodLength=&timeframe=&from=&to=

func (*TechnicalIndicatorsNamespace) StandardDeviation

StandardDeviation retrieves worldwide standard-deviation bars.

GET technical-indicators/standarddeviation?symbol=&periodLength=&timeframe=&from=&to=

func (*TechnicalIndicatorsNamespace) TripleExponentialMovingAverage

TripleExponentialMovingAverage retrieves worldwide triple-exponential-moving-average bars.

GET technical-indicators/tema?symbol=&periodLength=&timeframe=&from=&to=

func (*TechnicalIndicatorsNamespace) WeightedMovingAverage

WeightedMovingAverage retrieves worldwide weighted-moving-average bars.

GET technical-indicators/wma?symbol=&periodLength=&timeframe=&from=&to=

func (*TechnicalIndicatorsNamespace) Williams

Williams retrieves worldwide Williams bars.

GET technical-indicators/williams?symbol=&periodLength=&timeframe=&from=&to=

type TipRanksAnalystActionCounts

type TipRanksAnalystActionCounts struct {
	Initiated  uint64 `json:"initiated"`
	Maintained uint64 `json:"maintained"`
	Upgraded   uint64 `json:"upgraded"`
	Downgraded uint64 `json:"downgraded"`
	Reiterated uint64 `json:"reiterated"`
	Resumed    uint64 `json:"resumed"`
}

TipRanksAnalystActionCounts is analyst-action counts in a TipRanks ratings summary.

func (*TipRanksAnalystActionCounts) UnmarshalJSONFrom

func (m *TipRanksAnalystActionCounts) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type TipRanksAnalystProfile

type TipRanksAnalystProfile struct {
	ExpertUID            string         `json:"expertUID"`
	AnalystName          string         `json:"analystName"`
	FirmName             string         `json:"firmName"`
	SuccessRate          jsontext.Value `json:"successRate"`
	ExcessReturn         jsontext.Value `json:"excessReturn"`
	TotalRecommendations uint64         `json:"totalRecommendations"`
	GoodRecommendations  uint64         `json:"goodRecommendations"`
	AnalystRank          uint64         `json:"analystRank"`
	NumOfStars           uint64         `json:"numOfStars"`
}

TipRanksAnalystProfile is one analyst profile returned by the TipRanks directory.

func (*TipRanksAnalystProfile) UnmarshalJSONFrom

func (m *TipRanksAnalystProfile) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type TipRanksAnalystSummary

type TipRanksAnalystSummary struct {
	ExpertUID            string                       `json:"expertUID"`
	From                 Date                         `json:"from"`
	To                   Date                         `json:"to"`
	TotalRecommendations uint64                       `json:"totalRecommendations"`
	DistinctSymbols      uint64                       `json:"distinctSymbols"`
	DistinctAnalysts     uint64                       `json:"distinctAnalysts"`
	ValidPriceTargets    uint64                       `json:"validPriceTargets"`
	Recommendations      TipRanksRecommendationCounts `json:"recommendations"`
	AnalystAction        TipRanksAnalystActionCounts  `json:"analystAction"`
	ComparedPriceTargets uint64                       `json:"comparedPriceTargets"`
	Beats                uint64                       `json:"beats"`
	Misses               uint64                       `json:"misses"`
	AverageReturn        jsontext.Value               `json:"averageReturn"`
	TopReturn            jsontext.Value               `json:"topReturn"`
	WorstReturn          jsontext.Value               `json:"worstReturn"`
}

TipRanksAnalystSummary is aggregated TipRanks ratings for one analyst over a date window.

func (*TipRanksAnalystSummary) UnmarshalJSONFrom

func (m *TipRanksAnalystSummary) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type TipRanksAnalystSummaryQuery

type TipRanksAnalystSummaryQuery struct {
	// contains filtered or unexported fields
}

TipRanksAnalystSummaryQuery holds the query parameters of the endpoints that take it: NewTipRanksAnalystSummaryQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewTipRanksAnalystSummaryQuery

func NewTipRanksAnalystSummaryQuery(expertUID string) TipRanksAnalystSummaryQuery

NewTipRanksAnalystSummaryQuery creates the query from its required arguments.

func (TipRanksAnalystSummaryQuery) ExpertUID added in v0.12.0

func (q TipRanksAnalystSummaryQuery) ExpertUID() string

ExpertUID returns the expert_uid argument as given.

func (TipRanksAnalystSummaryQuery) From

From returns the optional from parameter, or nil when it is unset.

func (TipRanksAnalystSummaryQuery) To

To returns the optional to parameter, or nil when it is unset.

func (TipRanksAnalystSummaryQuery) WithFrom

WithFrom sets the optional from parameter and returns the updated query.

func (TipRanksAnalystSummaryQuery) WithTo

WithTo sets the optional to parameter and returns the updated query.

type TipRanksAnalystsQuery

type TipRanksAnalystsQuery struct {
	// contains filtered or unexported fields
}

TipRanksAnalystsQuery holds the query parameters of the endpoints that take it: NewTipRanksAnalystsQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewTipRanksAnalystsQuery

func NewTipRanksAnalystsQuery() TipRanksAnalystsQuery

NewTipRanksAnalystsQuery creates the query from its required arguments.

func (TipRanksAnalystsQuery) AnalystName

func (q TipRanksAnalystsQuery) AnalystName() *string

AnalystName returns the optional analyst_name parameter, or nil when it is unset.

func (TipRanksAnalystsQuery) FirmName

func (q TipRanksAnalystsQuery) FirmName() *string

FirmName returns the optional firm_name parameter, or nil when it is unset.

func (TipRanksAnalystsQuery) Limit

func (q TipRanksAnalystsQuery) Limit() *uint32

Limit returns the optional limit parameter, or nil when it is unset.

func (TipRanksAnalystsQuery) Page

func (q TipRanksAnalystsQuery) Page() *uint32

Page returns the optional page parameter, or nil when it is unset.

func (TipRanksAnalystsQuery) WithAnalystName

func (q TipRanksAnalystsQuery) WithAnalystName(analystName string) TipRanksAnalystsQuery

WithAnalystName sets the optional analyst_name parameter and returns the updated query.

func (TipRanksAnalystsQuery) WithFirmName

func (q TipRanksAnalystsQuery) WithFirmName(firmName string) TipRanksAnalystsQuery

WithFirmName sets the optional firm_name parameter and returns the updated query.

func (TipRanksAnalystsQuery) WithLimit

WithLimit sets the optional limit parameter and returns the updated query.

func (TipRanksAnalystsQuery) WithPage

WithPage sets the optional page parameter and returns the updated query.

type TipRanksFirmSummary

type TipRanksFirmSummary struct {
	FirmName             string                       `json:"firmName"`
	From                 Date                         `json:"from"`
	To                   Date                         `json:"to"`
	TotalRecommendations uint64                       `json:"totalRecommendations"`
	DistinctSymbols      uint64                       `json:"distinctSymbols"`
	DistinctAnalysts     uint64                       `json:"distinctAnalysts"`
	ValidPriceTargets    uint64                       `json:"validPriceTargets"`
	Recommendations      TipRanksRecommendationCounts `json:"recommendations"`
	AnalystAction        TipRanksAnalystActionCounts  `json:"analystAction"`
	ComparedPriceTargets uint64                       `json:"comparedPriceTargets"`
	Beats                uint64                       `json:"beats"`
	Misses               uint64                       `json:"misses"`
	AverageReturn        jsontext.Value               `json:"averageReturn"`
	TopReturn            jsontext.Value               `json:"topReturn"`
	WorstReturn          jsontext.Value               `json:"worstReturn"`
}

TipRanksFirmSummary is aggregated TipRanks ratings for one firm over a date window.

func (*TipRanksFirmSummary) UnmarshalJSONFrom

func (m *TipRanksFirmSummary) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type TipRanksFirmSummaryQuery

type TipRanksFirmSummaryQuery struct {
	// contains filtered or unexported fields
}

TipRanksFirmSummaryQuery holds the query parameters of the endpoints that take it: NewTipRanksFirmSummaryQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewTipRanksFirmSummaryQuery

func NewTipRanksFirmSummaryQuery(firmName string) TipRanksFirmSummaryQuery

NewTipRanksFirmSummaryQuery creates the query from its required arguments.

func (TipRanksFirmSummaryQuery) FirmName

func (q TipRanksFirmSummaryQuery) FirmName() string

FirmName returns the firm_name argument as given.

func (TipRanksFirmSummaryQuery) From

func (q TipRanksFirmSummaryQuery) From() *Date

From returns the optional from parameter, or nil when it is unset.

func (TipRanksFirmSummaryQuery) To

To returns the optional to parameter, or nil when it is unset.

func (TipRanksFirmSummaryQuery) WithFrom

WithFrom sets the optional from parameter and returns the updated query.

func (TipRanksFirmSummaryQuery) WithTo

WithTo sets the optional to parameter and returns the updated query.

type TipRanksNamespace added in v0.12.0

type TipRanksNamespace struct {
	// contains filtered or unexported fields
}

TipRanksNamespace groups the tipranks endpoints. It is reached as Client.TipRanks and is valid only when obtained from a Client built by NewClient.

func (*TipRanksNamespace) AnalystSummary added in v0.12.0

AnalystSummary retrieves an analyst's aggregate TipRanks ratings summary.

GET tipranks-analyst-summary?expertUID=&from=&to=

func (*TipRanksNamespace) Analysts added in v0.12.0

Analysts retrieves analyst profiles from the TipRanks directory.

GET tipranks-analysts?page=&limit=&firmName=&analystName=

func (*TipRanksNamespace) FirmSummary added in v0.12.0

FirmSummary retrieves a firm's aggregate TipRanks ratings summary.

GET tipranks-firm-summary?firmName=&from=&to=

func (*TipRanksNamespace) PointInTimeRatingsByAnalyst added in v0.12.0

PointInTimeRatingsByAnalyst retrieves an analyst's active coverage as of an optional snapshot date.

GET tipranks-pit-analyst?expertUID=&analystName=&date=&limit=&page=&nonadjusted=

func (*TipRanksNamespace) PointInTimeRatingsBySymbol added in v0.12.0

PointInTimeRatingsBySymbol retrieves a ticker's analyst ratings as of an optional snapshot date.

GET tipranks-pit-symbol?symbol=&date=&limit=&page=&nonadjusted=

func (*TipRanksNamespace) SearchRatings added in v0.12.0

SearchRatings retrieves individual analyst ratings from the TipRanks add-on.

GET tipranks-search?expertUID=&symbol=&from=&to=&limit=&page=&nonadjusted=

func (*TipRanksNamespace) SymbolSummary added in v0.12.0

SymbolSummary retrieves a ticker's aggregate TipRanks ratings summary.

GET tipranks-symbol-summary?symbol=&from=&to=

type TipRanksPointInTimeRating

type TipRanksPointInTimeRating struct {
	Symbol                 string          `json:"symbol"`
	Date                   string          `json:"date"`
	ExpertUID              string          `json:"expertUID"`
	AnalystName            string          `json:"analystName"`
	StockSuccessRate       jsontext.Value  `json:"stockSuccessRate"`
	FirmName               string          `json:"firmName"`
	LastRecommendation     string          `json:"lastRecommendation"`
	LastRecommendationDate Date            `json:"lastRecommendationDate"`
	ArticleTitle           string          `json:"articleTitle"`
	ArticleSite            string          `json:"articleSite"`
	PriceTarget            *jsontext.Value `json:"priceTarget"`
	PriceTargetCurrency    *string         `json:"priceTargetCurrency"`
	URL                    string          `json:"url"`
	LastAnalystAction      string          `json:"lastAnalystAction"`
	StockReturn            *jsontext.Value `json:"stockReturn"`
	BeatTarget             *bool           `json:"beatTarget"`
}

TipRanksPointInTimeRating is one analyst's active rating in a point-in-time symbol or analyst snapshot.

func (*TipRanksPointInTimeRating) UnmarshalJSONFrom

func (m *TipRanksPointInTimeRating) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type TipRanksRatingSearchResult

type TipRanksRatingSearchResult struct {
	Symbol              string         `json:"symbol"`
	Date                string         `json:"date"`
	RecommendationDate  Date           `json:"recommendationDate"`
	ExpertUID           string         `json:"expertUID"`
	AnalystName         string         `json:"analystName"`
	FirmName            string         `json:"firmName"`
	Recommendation      string         `json:"recommendation"`
	AnalystAction       string         `json:"analystAction"`
	ArticleTitle        string         `json:"articleTitle"`
	ArticleSite         string         `json:"articleSite"`
	PriceTarget         jsontext.Value `json:"priceTarget"`
	PriceTargetCurrency string         `json:"priceTargetCurrency"`
	URL                 string         `json:"url"`
}

TipRanksRatingSearchResult is one individual analyst rating returned by the TipRanks ratings search.

func (*TipRanksRatingSearchResult) UnmarshalJSONFrom

func (m *TipRanksRatingSearchResult) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type TipRanksRecommendationCounts

type TipRanksRecommendationCounts struct {
	Buy  uint64 `json:"buy"`
	Hold uint64 `json:"hold"`
	Sell uint64 `json:"sell"`
}

TipRanksRecommendationCounts is recommendation counts in a TipRanks ratings summary.

func (*TipRanksRecommendationCounts) UnmarshalJSONFrom

func (m *TipRanksRecommendationCounts) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type TipRanksSearchQuery

type TipRanksSearchQuery struct {
	// contains filtered or unexported fields
}

TipRanksSearchQuery holds the query parameters of the endpoints that take it: NewTipRanksSearchQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewTipRanksSearchQuery

func NewTipRanksSearchQuery() TipRanksSearchQuery

NewTipRanksSearchQuery creates the query from its required arguments.

func (TipRanksSearchQuery) ExpertUID added in v0.12.0

func (q TipRanksSearchQuery) ExpertUID() *string

ExpertUID returns the optional expert_uid parameter, or nil when it is unset.

func (TipRanksSearchQuery) From

func (q TipRanksSearchQuery) From() *Date

From returns the optional from parameter, or nil when it is unset.

func (TipRanksSearchQuery) Limit

func (q TipRanksSearchQuery) Limit() *uint32

Limit returns the optional limit parameter, or nil when it is unset.

func (TipRanksSearchQuery) Nonadjusted

func (q TipRanksSearchQuery) Nonadjusted() *bool

Nonadjusted returns the optional nonadjusted parameter, or nil when it is unset.

func (TipRanksSearchQuery) Page

func (q TipRanksSearchQuery) Page() *uint32

Page returns the optional page parameter, or nil when it is unset.

func (TipRanksSearchQuery) Symbol

func (q TipRanksSearchQuery) Symbol() *string

Symbol returns the optional symbol parameter, or nil when it is unset.

func (TipRanksSearchQuery) To

func (q TipRanksSearchQuery) To() *Date

To returns the optional to parameter, or nil when it is unset.

func (TipRanksSearchQuery) WithExpertUID added in v0.12.0

func (q TipRanksSearchQuery) WithExpertUID(expertUID string) TipRanksSearchQuery

WithExpertUID sets the optional expert_uid parameter and returns the updated query.

func (TipRanksSearchQuery) WithFrom

func (q TipRanksSearchQuery) WithFrom(from Date) TipRanksSearchQuery

WithFrom sets the optional from parameter and returns the updated query.

func (TipRanksSearchQuery) WithLimit

func (q TipRanksSearchQuery) WithLimit(limit uint32) TipRanksSearchQuery

WithLimit sets the optional limit parameter and returns the updated query.

func (TipRanksSearchQuery) WithNonadjusted

func (q TipRanksSearchQuery) WithNonadjusted(nonadjusted bool) TipRanksSearchQuery

WithNonadjusted sets the optional nonadjusted parameter and returns the updated query.

func (TipRanksSearchQuery) WithPage

WithPage sets the optional page parameter and returns the updated query.

func (TipRanksSearchQuery) WithSymbol

func (q TipRanksSearchQuery) WithSymbol(symbol string) TipRanksSearchQuery

WithSymbol sets the optional symbol parameter and returns the updated query.

func (TipRanksSearchQuery) WithTo

WithTo sets the optional to parameter and returns the updated query.

type TipRanksSymbolSummary

type TipRanksSymbolSummary struct {
	Symbol               string                       `json:"symbol"`
	From                 Date                         `json:"from"`
	To                   Date                         `json:"to"`
	TotalRecommendations uint64                       `json:"totalRecommendations"`
	DistinctSymbols      uint64                       `json:"distinctSymbols"`
	DistinctAnalysts     uint64                       `json:"distinctAnalysts"`
	ValidPriceTargets    uint64                       `json:"validPriceTargets"`
	Recommendations      TipRanksRecommendationCounts `json:"recommendations"`
	AnalystAction        TipRanksAnalystActionCounts  `json:"analystAction"`
	ComparedPriceTargets uint64                       `json:"comparedPriceTargets"`
	Beats                uint64                       `json:"beats"`
	Misses               uint64                       `json:"misses"`
	AverageReturn        jsontext.Value               `json:"averageReturn"`
	TopReturn            jsontext.Value               `json:"topReturn"`
	WorstReturn          jsontext.Value               `json:"worstReturn"`
}

TipRanksSymbolSummary is aggregated TipRanks ratings for one ticker over a date window.

func (*TipRanksSymbolSummary) UnmarshalJSONFrom

func (m *TipRanksSymbolSummary) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type TipRanksSymbolSummaryQuery

type TipRanksSymbolSummaryQuery struct {
	// contains filtered or unexported fields
}

TipRanksSymbolSummaryQuery holds the query parameters of the endpoints that take it: NewTipRanksSymbolSummaryQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewTipRanksSymbolSummaryQuery

func NewTipRanksSymbolSummaryQuery(symbol string) TipRanksSymbolSummaryQuery

NewTipRanksSymbolSummaryQuery creates the query from its required arguments.

func (TipRanksSymbolSummaryQuery) From

func (q TipRanksSymbolSummaryQuery) From() *Date

From returns the optional from parameter, or nil when it is unset.

func (TipRanksSymbolSummaryQuery) Symbol

Symbol returns the symbol argument as given.

func (TipRanksSymbolSummaryQuery) To

To returns the optional to parameter, or nil when it is unset.

func (TipRanksSymbolSummaryQuery) WithFrom

WithFrom sets the optional from parameter and returns the updated query.

func (TipRanksSymbolSummaryQuery) WithTo

WithTo sets the optional to parameter and returns the updated query.

type TranscriptsNamespace

type TranscriptsNamespace struct {
	// contains filtered or unexported fields
}

TranscriptsNamespace groups the transcripts endpoints. It is reached as Client.Transcripts and is valid only when obtained from a Client built by NewClient.

func (*TranscriptsNamespace) ByQuarter added in v0.12.0

ByQuarter retrieves complete worldwide earnings-call transcripts.

GET earning-call-transcript?symbol=&year=&quarter=&limit=

func (*TranscriptsNamespace) Dates added in v0.12.0

Dates retrieves available worldwide transcript dates for one ticker.

GET earning-call-transcript-dates?symbol=

func (*TranscriptsNamespace) Latest added in v0.12.0

Latest retrieves the latest worldwide earnings-transcript metadata.

GET earning-call-transcript-latest?limit=&page=

type TreasuryRate

type TreasuryRate struct {
	Date   Date    `json:"date"`
	Month1 float64 `json:"month1"`
	Month2 float64 `json:"month2"`
	Month3 float64 `json:"month3"`
	Month6 float64 `json:"month6"`
	Year1  float64 `json:"year1"`
	Year2  float64 `json:"year2"`
	Year3  float64 `json:"year3"`
	Year5  float64 `json:"year5"`
	Year7  float64 `json:"year7"`
	Year10 float64 `json:"year10"`
	Year20 float64 `json:"year20"`
	Year30 float64 `json:"year30"`
}

TreasuryRate is treasury rates across all twelve documented maturities for one date.

func (*TreasuryRate) UnmarshalJSONFrom

func (m *TreasuryRate) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type TreasuryRatesQuery

type TreasuryRatesQuery struct {
	// contains filtered or unexported fields
}

TreasuryRatesQuery holds the query parameters of the endpoints that take it: NewTreasuryRatesQuery takes the required arguments and each With method sets an optional one. Values are validated when the request is built.

func NewTreasuryRatesQuery

func NewTreasuryRatesQuery() TreasuryRatesQuery

NewTreasuryRatesQuery creates the query from its required arguments.

func (TreasuryRatesQuery) From

func (q TreasuryRatesQuery) From() *Date

From returns the optional from parameter, or nil when it is unset.

func (TreasuryRatesQuery) To

func (q TreasuryRatesQuery) To() *Date

To returns the optional to parameter, or nil when it is unset.

func (TreasuryRatesQuery) WithFrom

func (q TreasuryRatesQuery) WithFrom(from Date) TreasuryRatesQuery

WithFrom sets the optional from parameter and returns the updated query.

func (TreasuryRatesQuery) WithTo

WithTo sets the optional to parameter and returns the updated query.

type TripleExponentialMovingAverageBar

type TripleExponentialMovingAverageBar struct {
	Date   DateTime `json:"date"`
	Open   float64  `json:"open"`
	High   float64  `json:"high"`
	Low    float64  `json:"low"`
	Close  float64  `json:"close"`
	Volume float64  `json:"volume"`
	Tema   float64  `json:"tema"`
}

TripleExponentialMovingAverageBar is a response model of the technical_indicators domain.

func (*TripleExponentialMovingAverageBar) UnmarshalJSONFrom

func (m *TripleExponentialMovingAverageBar) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type USDate added in v0.12.0

type USDate struct {
	// contains filtered or unexported fields
}

USDate is a civil calendar date carried on the wire as exactly "MM-DD-YYYY", the US spelling some fundraising endpoints use. It mirrors USDate in the Rust crate: the same date as Date, a different wire text. The zero value is not a valid date and cannot be encoded; IsZero reports it.

func NewUSDate added in v0.12.0

func NewUSDate(year int, month time.Month, day int) (USDate, error)

NewUSDate validates a proleptic Gregorian date with a four-digit year.

func ParseUSDate added in v0.12.0

func ParseUSDate(value string) (USDate, error)

ParseUSDate accepts exactly the "MM-DD-YYYY" shape the Rust crate accepts and rejects every other spelling, including "YYYY-MM-DD".

func (USDate) Date added in v0.12.0

func (d USDate) Date() Date

Date returns the same calendar date as a Date, which is the type every other date member uses.

func (USDate) IsZero added in v0.12.0

func (d USDate) IsZero() bool

IsZero reports whether d is the zero value, which is not a valid date.

func (USDate) MarshalJSONTo added in v0.12.0

func (d USDate) MarshalJSONTo(enc *jsontext.Encoder) error

MarshalJSONTo writes the date as a JSON string; the zero value is rejected.

func (USDate) MarshalText added in v0.12.0

func (d USDate) MarshalText() ([]byte, error)

MarshalText encodes the wire text; the zero value is rejected.

func (USDate) String added in v0.12.0

func (d USDate) String() string

String returns the exact wire text "MM-DD-YYYY".

func (*USDate) UnmarshalJSONFrom added in v0.12.0

func (d *USDate) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom reads one JSON string. Any other JSON kind, including null, is rejected, matching the Rust decoder for a required field.

func (*USDate) UnmarshalText added in v0.12.0

func (d *USDate) UnmarshalText(text []byte) error

UnmarshalText parses the exact wire text.

type UnixMilliseconds

type UnixMilliseconds int64

UnixMilliseconds is a Unix timestamp in whole milliseconds, carried as a JSON integer.

func (UnixMilliseconds) String

func (ms UnixMilliseconds) String() string

String returns the decimal wire text.

func (UnixMilliseconds) Time

func (ms UnixMilliseconds) Time() time.Time

Time converts the timestamp to a UTC time.Time.

func (*UnixMilliseconds) UnmarshalJSONFrom

func (ms *UnixMilliseconds) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom reads one JSON integer. Strings, floats, exponents, and null are rejected, matching serde_json decoding into i64.

type UnixSeconds

type UnixSeconds int64

UnixSeconds is a Unix timestamp in whole seconds, carried as a JSON integer.

func (UnixSeconds) String

func (s UnixSeconds) String() string

String returns the decimal wire text.

func (UnixSeconds) Time

func (s UnixSeconds) Time() time.Time

Time converts the timestamp to a UTC time.Time.

func (*UnixSeconds) UnmarshalJSONFrom

func (s *UnixSeconds) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom reads one JSON integer. Strings, floats, exponents, and null are rejected, matching serde_json decoding into i64.

type UserDeclarationRequirement

type UserDeclarationRequirement int

UserDeclarationRequirement reports whether a user declaration is required for a real-time feed. It mirrors the Rust UserDeclarationRequirement; the zero value is UserDeclarationUnspecified.

const (
	// UserDeclarationUnspecified: no declaration is documented.
	UserDeclarationUnspecified UserDeclarationRequirement = iota
	// UserDeclarationRequiredForRealtime: real-time data needs a declaration.
	UserDeclarationRequiredForRealtime
)

func (UserDeclarationRequirement) String

String returns a short stable label that is safe to log.

type WeightedMovingAverageBar

type WeightedMovingAverageBar struct {
	Date   DateTime `json:"date"`
	Open   float64  `json:"open"`
	High   float64  `json:"high"`
	Low    float64  `json:"low"`
	Close  float64  `json:"close"`
	Volume float64  `json:"volume"`
	Wma    float64  `json:"wma"`
}

WeightedMovingAverageBar is a response model of the technical_indicators domain.

func (*WeightedMovingAverageBar) UnmarshalJSONFrom

func (m *WeightedMovingAverageBar) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

type WilliamsBar

type WilliamsBar struct {
	Date     DateTime `json:"date"`
	Open     float64  `json:"open"`
	High     float64  `json:"high"`
	Low      float64  `json:"low"`
	Close    float64  `json:"close"`
	Volume   float64  `json:"volume"`
	Williams float64  `json:"williams"`
}

WilliamsBar is a response model of the technical_indicators domain.

func (*WilliamsBar) UnmarshalJSONFrom

func (m *WilliamsBar) UnmarshalJSONFrom(dec *jsontext.Decoder) error

UnmarshalJSONFrom decodes one JSON object and rejects it with a Decode error naming the first required member that is missing or null, as the Rust decoder does. Unknown members are ignored.

Directories

Path Synopsis
examples
proxy command
Command proxy fetches one compact quote through a proxy-shaped client: a base URL with its own path, a custom path prefix, a tenant header on every request, and a proxy token in a caller-selected header.
Command proxy fetches one compact quote through a proxy-shaped client: a base URL with its own path, a custom path prefix, a tenant header on every request, and a proxy token in a caller-selected header.
quote command
Command quote fetches one detailed quote through the Go SDK against an in-process TLS server, so it runs offline and prints no credential.
Command quote fetches one detailed quote through the Go SDK against an in-process TLS server, so it runs offline and prints no credential.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL