/** * This file was auto-generated by Fern from our API Definition. */ import * as environments from "../../../../environments"; import * as core from "../../../../core"; import * as Vellum from "../../../index"; export declare namespace Events { interface Options { environment?: core.Supplier; /** Specify a custom URL to connect the client to. */ baseUrl?: core.Supplier; apiKey: core.Supplier; /** Override the X-API-Version header */ apiVersion?: core.Supplier; } interface RequestOptions { /** The maximum time to wait for a response in seconds. */ timeoutInSeconds?: number; /** The number of times to retry the request. Defaults to 2. */ maxRetries?: number; /** A hook to abort the request. */ abortSignal?: AbortSignal; /** Override the X-API-Version header */ apiVersion?: Vellum.ApiVersionEnum | undefined; /** Additional headers to include in the request. */ headers?: Record; } } export declare class Events { protected readonly _options: Events.Options; constructor(_options: Events.Options); /** * Accept an event or list of events and publish them to ClickHouse for analytics processing. * * @param {Vellum.CreateWorkflowEventRequest} request * @param {Events.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Vellum.BadRequestError} * @throws {@link Vellum.UnauthorizedError} * @throws {@link Vellum.ForbiddenError} * @throws {@link Vellum.TooManyRequestsError} * * @example * await client.events.create([{ * name: "node.execution.initiated", * body: { * nodeDefinition: { * name: "name", * module: ["module", "module"], * id: "id" * }, * inputs: { * "inputs": { * "key": "value" * } * } * }, * id: "id", * timestamp: "2024-01-15T09:30:00Z", * traceId: "trace_id", * spanId: "span_id" * }, { * name: "node.execution.initiated", * body: { * nodeDefinition: { * name: "name", * module: ["module", "module"], * id: "id" * }, * inputs: { * "inputs": { * "key": "value" * } * } * }, * id: "id", * timestamp: "2024-01-15T09:30:00Z", * traceId: "trace_id", * spanId: "span_id" * }]) */ create(request: Vellum.CreateWorkflowEventRequest, requestOptions?: Events.RequestOptions): core.HttpResponsePromise; private __create; protected _getCustomAuthorizationHeaders(): Promise<{ "X-API-KEY": string; }>; }