export type GetApiFinancialDatasetsActivistOwnershipArgs = {ticker?: string | undefined, filer_cik?: string | undefined, history?: boolean | undefined, filing_date?: string | undefined, filing_date_gte?: string | undefined, filing_date_lte?: string | undefined, filing_date_gt?: string | undefined, filing_date_lt?: string | undefined, limit?: number | undefined, cursor?: string | undefined}; export type GetApiFinancialDatasetsActivistOwnershipOptions = {baseUrl?: string | undefined, fetch?: typeof fetch | undefined}; /** * Get activist stakes (SEC Schedule 13D: holders of more than 5% of a class of shares with intent to influence control), one row per reporting person. Query by ticker (who holds activist stakes in this company) or by filer_cik (what stakes does this activist hold); provide exactly one of the two. By default each stake's current state is returned; set history=true for the full amendment chain. This endpoint is the activist-only view of /beneficial-ownership. * * GET /financial-datasets/activist-ownership */ export const getApiFinancialDatasetsActivistOwnership = async (args: GetApiFinancialDatasetsActivistOwnershipArgs, options?: GetApiFinancialDatasetsActivistOwnershipOptions) => { const {baseUrl = "https://api.orthogonal.com/mpp", fetch: fetchFn = fetch} = options ?? {} const query = new URLSearchParams() const headers = new Headers() if (args.ticker != null) query.append("ticker", String(args.ticker)) if (args.filer_cik != null) query.append("filer_cik", String(args.filer_cik)) if (args.history != null) query.append("history", String(args.history)) if (args.filing_date != null) query.append("filing_date", String(args.filing_date)) if (args.filing_date_gte != null) query.append("filing_date_gte", String(args.filing_date_gte)) if (args.filing_date_lte != null) query.append("filing_date_lte", String(args.filing_date_lte)) if (args.filing_date_gt != null) query.append("filing_date_gt", String(args.filing_date_gt)) if (args.filing_date_lt != null) query.append("filing_date_lt", String(args.filing_date_lt)) if (args.limit != null) query.append("limit", String(args.limit)) if (args.cursor != null) query.append("cursor", String(args.cursor)) const url = `${baseUrl.replace(/\/+$/, '')}/financial-datasets/activist-ownership${query.size > 0 ? `?${query}` : ''}` const res = await fetchFn(url, {method: "GET", headers}) if (!res.ok) throw new Error(`Request failed with status ${res.status}`, {cause: {status: res.status, body: await res.text()}}) return undefined };