From 4faf04b1ca229e37a67bdf28e7d7a4e7d58cb2cf Mon Sep 17 00:00:00 2001 From: Harry Hough Date: Thu, 5 Sep 2024 14:30:22 -0500 Subject: [PATCH] Added interface type for Cloudflare pipelines binding (#2654) * Added interface type for cloudflare pipelines binding * Adding pipelines binding types --------- Co-authored-by: Oli Yu --- types/defines/pipelines.d.ts | 13 +++++++++++++ 1 file changed, 13 insertions(+) create mode 100644 types/defines/pipelines.d.ts diff --git a/types/defines/pipelines.d.ts b/types/defines/pipelines.d.ts new file mode 100644 index 00000000000..7ed2d312c21 --- /dev/null +++ b/types/defines/pipelines.d.ts @@ -0,0 +1,13 @@ +// Copyright (c) 2022-2023 Cloudflare, Inc. +// Licensed under the Apache 2.0 license found in the LICENSE file or at: +// https://opensource.org/licenses/Apache-2.0 + +export interface Pipeline { + /** + * send takes an array of javascript objects which are + * then received by the pipeline for processing + * + * @param data The data to be sent + */ + send(data: object[]): Promise +}