Socket
Socket
Sign inDemoInstall

@prismatic-io/spectral

Package Overview
Dependencies
Maintainers
4
Versions
171
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@prismatic-io/spectral - npm Package Compare versions

Comparing version 6.5.2 to 6.6.0

12

dist/serverTypes/index.d.ts

@@ -50,2 +50,14 @@ /// <reference types="node" />

executionId: string;
webhookUrls: Record<string, string>;
webhookApiKeys: Record<string, string[]>;
invokeUrl: string;
customer: {
id: string | null;
externalId: string | null;
name: string | null;
};
instance: {
id: string | null;
name: string | null;
};
}

@@ -52,0 +64,0 @@ declare type TriggerOptionChoice = "invalid" | "valid" | "required";

52

dist/testing.js

@@ -47,3 +47,14 @@ "use strict";

const invoke = ({ perform }, params, context) => __awaiter(void 0, void 0, void 0, function* () {
const realizedContext = Object.assign({ logger: (0, exports.loggerMock)(), instanceState: {}, crossFlowState: {}, executionState: {}, stepId: "mockStepId", executionId: "mockExecutionId" }, context);
const realizedContext = Object.assign({ logger: (0, exports.loggerMock)(), instanceState: {}, crossFlowState: {}, executionState: {}, stepId: "mockStepId", executionId: "mockExecutionId", webhookUrls: {
"Flow 1": "https://example.com",
}, webhookApiKeys: {
"Flow 1": ["example-123", "example-456"],
}, invokeUrl: "https://example.com", customer: {
id: "customerId",
name: "Customer 1",
externalId: "1234",
}, instance: {
id: "instanceId",
name: "Instance 1",
} }, context);
const result = yield perform(realizedContext, params);

@@ -100,3 +111,14 @@ return {

const invokeTrigger = ({ perform }, context, payload, params) => __awaiter(void 0, void 0, void 0, function* () {
const realizedContext = Object.assign({ logger: (0, exports.loggerMock)(), instanceState: {}, crossFlowState: {}, executionState: {}, stepId: "mockStepId", executionId: "mockExecutionId" }, context);
const realizedContext = Object.assign({ logger: (0, exports.loggerMock)(), instanceState: {}, crossFlowState: {}, executionState: {}, stepId: "mockStepId", executionId: "mockExecutionId", webhookUrls: {
"Flow 1": "https://example.com",
}, webhookApiKeys: {
"Flow 1": ["example-123", "example-456"],
}, invokeUrl: "https://example.com", customer: {
id: "customerId",
name: "Customer 1",
externalId: "1234",
}, instance: {
id: "instanceId",
name: "Instance 1",
} }, context);
const realizedPayload = Object.assign(Object.assign({}, (0, exports.defaultTriggerPayload)()), payload);

@@ -125,3 +147,14 @@ const realizedParams = params || {};

return __awaiter(this, void 0, void 0, function* () {
const realizedContext = Object.assign({ logger: (0, exports.loggerMock)(), instanceState: {}, crossFlowState: {}, executionState: {}, stepId: "mockStepId", executionId: "mockExecutionId" }, context);
const realizedContext = Object.assign({ logger: (0, exports.loggerMock)(), instanceState: {}, crossFlowState: {}, executionState: {}, stepId: "mockStepId", executionId: "mockExecutionId", webhookUrls: {
"Flow 1": "https://example.com",
}, webhookApiKeys: {
"Flow 1": ["example-123", "example-456"],
}, invokeUrl: "https://example.com", customer: {
id: "customerId",
name: "Customer 1",
externalId: "1234",
}, instance: {
id: "instanceId",
name: "Instance 1",
} }, context);
const trigger = this.component.triggers[key];

@@ -133,3 +166,14 @@ return trigger.perform(realizedContext, Object.assign(Object.assign({}, (0, exports.defaultTriggerPayload)()), payload), Object.assign({}, params));

return __awaiter(this, void 0, void 0, function* () {
const realizedContext = Object.assign({ logger: (0, exports.loggerMock)(), instanceState: {}, crossFlowState: {}, executionState: {}, stepId: "mockStepId", executionId: "mockExecutionId" }, context);
const realizedContext = Object.assign({ logger: (0, exports.loggerMock)(), instanceState: {}, crossFlowState: {}, executionState: {}, stepId: "mockStepId", executionId: "mockExecutionId", webhookUrls: {
"Flow 1": "https://example.com",
}, webhookApiKeys: {
"Flow 1": ["example-123", "example-456"],
}, invokeUrl: "https://example.com", customer: {
id: "customerId",
name: "Customer 1",
externalId: "1234",
}, instance: {
id: "instanceId",
name: "Instance 1",
} }, context);
const action = this.component.actions[key];

@@ -136,0 +180,0 @@ return action.perform(realizedContext, Object.assign({}, params));

@@ -18,2 +18,19 @@ import { Inputs, ActionPerformReturn, ActionInputParameters, ActionLogger } from ".";

executionId: string;
/** An object containing webhook URLs for all flows of the currently running instance */
webhookUrls: Record<string, string>;
/** An object containing webhook API keys for all flows of the currently running instance */
webhookApiKeys: Record<string, string[]>;
/** The URL used to invoke the current execution */
invokeUrl: string;
/** An object containing the ID, External ID and name of the customer the instance is deployed to */
customer: {
id: string | null;
externalId: string | null;
name: string | null;
};
/** An object containing the ID ad name of the currently running instance */
instance: {
id: string | null;
name: string | null;
};
}

8

dist/util.js

@@ -29,5 +29,5 @@ "use strict";

/**
* Convert truthey (true, "t", "true", "y", "yes") values to boolean `true`,
* and falsey (false, "f", "false", "n", "no") values to boolean `false`.
* Truthy/falsey checks are case-insensitive.
* Convert truthy (true, "t", "true", "y", "yes") values to boolean `true`,
* and falsy (false, "f", "false", "n", "no") values to boolean `false`.
* Truthy/falsy checks are case-insensitive.
*

@@ -39,3 +39,3 @@ * In the event that `value` is undefined or an empty string, a default value can be provided.

* @param defaultValue The value to return if `value` is undefined or an empty string.
* @returns The boolean equivalent of the truthey or falsey `value`.
* @returns The boolean equivalent of the truthy or falsy `value`.
*/

@@ -42,0 +42,0 @@ const toBool = (value, defaultValue) => {

{
"name": "@prismatic-io/spectral",
"version": "6.5.2",
"version": "6.6.0",
"description": "Utility library for building Prismatic components",

@@ -32,3 +32,3 @@ "keywords": [

"lint-fix": "eslint --fix --ext .ts .",
"test": "jest --maxWorkers=4",
"test": "jest",
"tsd": "tsd",

@@ -35,0 +35,0 @@ "docs": "rm -f sidebars.{js,jse} && typedoc"

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc