Skip to content

Built for people who want to own their automations. Join the waitlist for an invite.

Package listing

@kody/morning-briefing

src/build-report.ts

15 lines · 635 B · TypeScript
import { buildAndStoreReport } from './report.ts'
import type { BriefingInput } from './types.ts'

/**
 * Build and store a morning briefing report without sending email or notify.
 *
 * @param input.date - Date (`YYYY-MM-DD`) in `timezone`; defaults to today.
 * @example
 * import buildReport from 'kody:@kody/morning-briefing/build-report'
 * const report = await buildReport({ date: '2026-08-22', location: 'Denver, CO', sources: ['weather'] })
 * // => { date: '2026-08-22', sections: [{ id: 'weather', ... }] }
 */
export default async function buildReport(input: BriefingInput = {}) {
	return await buildAndStoreReport(input)
}