export type GetApiAktaProV1CompanyPostsArgs = {company: string, limit?: number | undefined, offset?: number | undefined}; export type GetApiAktaProV1CompanyPostsOptions = {baseUrl?: string | undefined, fetch?: typeof fetch | undefined}; /** * Company social posts by domain or akta UUID, including post text, date, URL, content type, paid and repost flags, AI-classified theme, mentioned companies and engagement metrics such as reactions, comments and reposts. Use it to catch first-party announcements, product and hiring signals, compare posting cadence and content mix, and track engagement trends. Paginate with limit and offset. Optimized for AI agents with compact, structured output for reliable routing. * * GET /akta-pro/v1/company/posts */ export const getApiAktaProV1CompanyPosts = async (args: GetApiAktaProV1CompanyPostsArgs, options?: GetApiAktaProV1CompanyPostsOptions) => { const {baseUrl = "https://api.orthogonal.com/mpp", fetch: fetchFn = fetch} = options ?? {} const query = new URLSearchParams() const headers = new Headers() if (args.company != null) query.append("company", String(args.company)) if (args.limit != null) query.append("limit", String(args.limit)) if (args.offset != null) query.append("offset", String(args.offset)) const url = `${baseUrl.replace(/\/+$/, '')}/akta-pro/v1/company/posts${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 };