@kustomer/apps-common
Advanced tools
Comparing version 0.2.2 to 0.2.3
@@ -6,1 +6,2 @@ export * from './tag'; | ||
export * from './with-id'; | ||
export * from './json-schema'; |
@@ -22,1 +22,2 @@ "use strict"; | ||
__exportStar(require("./with-id"), exports); | ||
__exportStar(require("./json-schema"), exports); |
@@ -0,1 +1,2 @@ | ||
import { JSONSchema } from '../common'; | ||
/** A defined list of supported action types, which coorelate to how the data will be processed */ | ||
@@ -14,9 +15,9 @@ export type ActionType = 'rest_api' | 'kode' | 'internal_api' | 'event' | 'regex_match' | 'schedule' | 'aws_lamda'; | ||
/** A JSON schema used to validate the actions input data */ | ||
inputSchema?: Record<string, any>; | ||
inputSchema?: JSONSchema; | ||
/** A definition for the shape of the data being passed into the action */ | ||
inputTemplate: Record<string, any>; | ||
/** A JSON schema used to validate the actions output data */ | ||
outputSchema?: Record<string, any>; | ||
outputSchema?: JSONSchema; | ||
/** A definition for the shape of the data that will leave the action, to be used in the next step of the workflow */ | ||
outputTemplate: Record<string, any>; | ||
} |
@@ -1,2 +0,2 @@ | ||
import { HttpMethod } from '../common'; | ||
import { HttpMethod, JSONSchema } from '../common'; | ||
export type CommandType = 'external-api'; | ||
@@ -9,2 +9,6 @@ export type CommandCallback = (orgId: string, userId: string, data: any) => any; | ||
description?: string; | ||
/** A JSON schema used to validate the commands input data */ | ||
inputSchema?: JSONSchema; | ||
/** A JSON schema used to validate the commands input data */ | ||
outputSchema?: JSONSchema; | ||
} | ||
@@ -20,2 +24,4 @@ export interface Command { | ||
defaultBody?: any; | ||
inputSchema?: JSONSchema; | ||
outputSchema?: JSONSchema; | ||
} |
{ | ||
"name": "@kustomer/apps-common", | ||
"version": "0.2.2", | ||
"version": "0.2.3", | ||
"license": "MIT", | ||
@@ -12,3 +12,3 @@ "main": "index.js", | ||
"scripts": { | ||
"clean": "npx rimraf bin", | ||
"clean": "npx rimraf bin && npx rimraf coverage", | ||
"build": "npm run clean && tsc -p . --sourceMap false && npm run build:browser && cp README.md bin/README.md && cp package.json bin/package.json", | ||
@@ -15,0 +15,0 @@ "build:browser": "npx esbuild . --outfile=bin/browser.min.js --loader:.ts=ts --bundle --minify", |
Sorry, the diff of this file is not supported yet
184804
92
1983