From 274bf30973b3b99cfd01d131ce9a8d4bd70b35c8 Mon Sep 17 00:00:00 2001 From: Philipp Kunz Date: Thu, 22 Feb 2024 15:15:44 +0100 Subject: [PATCH] fix(core): update --- ts/00_commitinfo_data.ts | 2 +- ts/index.ts | 26 ++++++++++++-------------- 2 files changed, 13 insertions(+), 15 deletions(-) diff --git a/ts/00_commitinfo_data.ts b/ts/00_commitinfo_data.ts index f8f394e..e5e5a2e 100644 --- a/ts/00_commitinfo_data.ts +++ b/ts/00_commitinfo_data.ts @@ -3,6 +3,6 @@ */ export const commitinfo = { name: '@api.global/typedrequest-interfaces', - version: '3.0.8', + version: '3.0.9', description: 'interfaces for making typed requests' } diff --git a/ts/index.ts b/ts/index.ts index 793fcbb..ef204d2 100644 --- a/ts/index.ts +++ b/ts/index.ts @@ -76,23 +76,21 @@ export interface ITag { export type implementsTag = {}; +export interface IUnifiedStreamReqResObject { + streamId: string; + cycle: 'request' | 'response'; + cycleId: string; + type: 'start' | 'binaryChunk' | 'object' | 'end' | 'keepAlive'; + streamChunk?: any; + keepAlive?: boolean; + next?: boolean; +} + export interface IStreamRequest extends implementsTR< ITypedRequest, IStreamRequest > { method: '##VirtualStream##'; - request: { - streamId: string; - type: 'start' | 'binaryChunk' | 'object' | 'end' | 'keepAlive'; - streamChunk?: any; - keepAlive?: boolean; - next?: boolean; - }; - response: { - streamId: string; - type: 'start' | 'binaryChunk' | 'object' | 'end' | 'keepAlive'; - streamChunk?: any; - keepAlive?: boolean; - next?: boolean; - }; + request: IUnifiedStreamReqResObject; + response: IUnifiedStreamReqResObject; }