1import type * as forecast from "@distilled.cloud/aws/forecast";
2import type * as Effect from "effect/Effect";
3import * as Binding from "../../Binding.ts";
4
5/**
6 * Runtime binding for `forecast:CreateForecastExportJob` — export a complete
7 * forecast to S3 as CSV/Parquet, the bulk-consumption path that complements
8 * per-item lookups via {@link QueryForecast}.
9 *
10 * Export job ARNs are created at runtime, so the binding takes no arguments
11 * and grants `forecast:CreateForecastExportJob` on `*`, plus `iam:PassRole`
12 * (conditioned to `forecast.amazonaws.com`) for the export destination role.
13 * Provide the implementation with
14 * `Effect.provide(AWS.Forecast.CreateForecastExportJobHttp)`.
15 *
16 * ### Exporting Forecasts
17 * **Example:** Export the Forecast to S3
18 * ```typescript
19 * // init
20 * const createForecastExportJob = yield* AWS.Forecast.CreateForecastExportJob();
21 *
22 * // runtime
23 * const job = yield* createForecastExportJob({
24 * ForecastExportJobName: "demand_2026_07_14_export",
25 * ForecastArn: forecastArn,
26 * Destination: {
27 * S3Config: { Path: "s3://my-bucket/forecasts/", RoleArn: exportRoleArn },
28 * },
29 * });
30 * ```
31 *
32 * @binding
33 */
34export interface CreateForecastExportJob extends Binding.Service<
35 CreateForecastExportJob,
36 "AWS.Forecast.CreateForecastExportJob",
37 () => Effect.Effect<
38 (
39 request: forecast.CreateForecastExportJobRequest,
40 ) => Effect.Effect<
41 forecast.CreateForecastExportJobResponse,
42 forecast.CreateForecastExportJobError
43 >
44 >
45> {}
46export const CreateForecastExportJob = Binding.Service<CreateForecastExportJob>(
47 "AWS.Forecast.CreateForecastExportJob",
48);