Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@epilot/entity-mapping-client

Package Overview
Dependencies
Maintainers
32
Versions
30
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@epilot/entity-mapping-client - npm Package Compare versions

Comparing version 0.8.4 to 0.8.5

2

dist/definition.js

@@ -1,1 +0,1 @@

(()=>{"use strict";var e={914:function(e,t,r){var i=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var n=i(r(240));t.default=n.default},240:e=>{e.exports=JSON.parse('{"openapi":"3.0.3","info":{"title":"","version":""},"paths":{"/v1/mappings":{"post":{"operationId":"storeConfig","parameters":[{"name":"with_id","in":"query","required":false}],"requestBody":{"content":{"application/json":{}}}}},"/v1/mappings/{id}":{"get":{"operationId":"getConfig","parameters":[{"name":"id","in":"path","required":true}]},"delete":{"operationId":"deleteConfig","parameters":[{"name":"id","in":"path","required":true}]}},"/v1/mappings/{id}/versions":{"get":{"operationId":"getAllVersions","parameters":[{"name":"id","in":"path","required":true}]},"post":{"operationId":"storeNewVersion","parameters":[{"name":"id","in":"path","required":true}],"requestBody":{"content":{"application/json":{}}}}},"/v1/mappings/{id}/versions/{version}":{"get":{"operationId":"getConfigVersion","parameters":[{"name":"id","in":"path","required":true},{"name":"version","in":"path","required":true}]}},"/v1/mappings:execute":{"post":{"operationId":"executeMapping","parameters":[{"name":"preview_mode","in":"query","required":false}],"requestBody":{"content":{"application/json":{}}}}},"/v1/mappings:search":{"post":{"operationId":"searchConfigs","requestBody":{"content":{"application/json":{}}}}},"/v1/mappings/history":{"get":{"operationId":"queryMappingHistory","parameters":[{"in":"query","name":"from","required":false},{"in":"query","name":"to","required":false},{"in":"query","name":"targetEntityId"},{"in":"query","name":"sourceEntityId"}]}},"/v1/relations:execute":{"post":{"operationId":"executeRelations","requestBody":{"content":{"application/json":{}}}}}},"components":{},"servers":[{"url":"https://entity-mapping.sls.epilot.io/"}]}')}},t={},r=function r(i){var n=t[i];if(void 0!==n)return n.exports;var o=t[i]={exports:{}};return e[i].call(o.exports,o,o.exports,r),o.exports}(914),i=exports;for(var n in r)i[n]=r[n];r.__esModule&&Object.defineProperty(i,"__esModule",{value:!0})})();
(()=>{"use strict";var e={914:function(e,t,r){var i=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var n=i(r(240));t.default=n.default},240:e=>{e.exports=JSON.parse('{"openapi":"3.0.3","info":{"title":"","version":""},"paths":{"/v1/mappings":{"post":{"operationId":"storeConfig","parameters":[{"name":"with_id","in":"query","required":false}],"requestBody":{"content":{"application/json":{}}}}},"/v1/mappings/{id}":{"get":{"operationId":"getConfig","parameters":[{"name":"id","in":"path","required":true}]},"delete":{"operationId":"deleteConfig","parameters":[{"name":"id","in":"path","required":true}]}},"/v1/mappings/{id}/versions":{"get":{"operationId":"getAllVersions","parameters":[{"name":"id","in":"path","required":true}]},"post":{"operationId":"storeNewVersion","parameters":[{"name":"id","in":"path","required":true}],"requestBody":{"content":{"application/json":{}}}}},"/v1/mappings/{id}/versions/{version}":{"get":{"operationId":"getConfigVersion","parameters":[{"name":"id","in":"path","required":true},{"name":"version","in":"path","required":true}]}},"/v1/mappings:execute":{"post":{"operationId":"executeMapping","parameters":[{"name":"preview_mode","in":"query","required":false}],"requestBody":{"content":{"application/json":{}}}}},"/v1/mappings:search":{"post":{"operationId":"searchConfigs","requestBody":{"content":{"application/json":{}}}}},"/v1/mappings/history":{"get":{"operationId":"queryMappingHistory","parameters":[{"in":"query","name":"from","required":false},{"in":"query","name":"to","required":false},{"in":"query","name":"targetEntityId"},{"in":"query","name":"sourceEntityId"}]}},"/v1/relations:execute":{"post":{"operationId":"executeRelations","requestBody":{"content":{"application/json":{}}}}},"/v2/mappings/{id}":{"get":{"operationId":"getMappingConfig","parameters":[{"name":"id","in":"path","required":true}]},"put":{"operationId":"putMappingConfig","parameters":[{"name":"id","in":"path","required":true}],"requestBody":{"content":{"application/json":{}}}}}},"components":{}}')}},t={},r=function r(i){var n=t[i];if(void 0!==n)return n.exports;var a=t[i]={exports:{}};return e[i].call(a.exports,a,a.exports,r),a.exports}(914),i=exports;for(var n in r)i[n]=r[n];r.__esModule&&Object.defineProperty(i,"__esModule",{value:!0})})();

@@ -152,10 +152,32 @@ {

}
},
"/v2/mappings/{id}": {
"get": {
"operationId": "getMappingConfig",
"parameters": [
{
"name": "id",
"in": "path",
"required": true
}
]
},
"put": {
"operationId": "putMappingConfig",
"parameters": [
{
"name": "id",
"in": "path",
"required": true
}
],
"requestBody": {
"content": {
"application/json": {}
}
}
}
}
},
"components": {},
"servers": [
{
"url": "https://entity-mapping.sls.epilot.io/"
}
]
"components": {}
}

@@ -182,4 +182,21 @@ /* eslint-disable */

id: string;
source: SourceConfig;
targets: TargetConfig[];
created_at?: string; // date-time
updated_at?: string; // date-time
created_by?: Owner;
last_updated_by?: Owner;
/**
* example:
* 66
*/
org_id: string;
/**
* example:
* 2
*/
version: number;
}
export interface MappingConfigCommonFields {
id: string;
source: SourceConfig;

@@ -208,2 +225,21 @@ targets: TargetConfig[];

}
export interface MappingConfigV2 {
id: string;
source: SourceConfig;
targets: TargetConfig[];
created_at?: string; // date-time
updated_at?: string; // date-time
created_by?: Owner;
last_updated_by?: Owner;
/**
* example:
* 66
*/
org_id?: string;
/**
* example:
* 2
*/
version?: number;
}
export type MappingConfigs = MappingConfig[];

@@ -224,3 +260,3 @@ export interface MappingConfigsResp {

* example:
* uuidv4
* 70542580-2b38-4bfc-af8d-bb90102f9f47
*/

@@ -236,56 +272,2 @@ id: string;

}
export interface MappingSource {
/**
* Key aiming to identify source
*/
key: string;
/**
* Each item describes a property under the main source and a possibly, a default value for its target attribute
*/
sub_properties?: MappingSourceProperty[];
/**
* Data Structure type of source
*/
source_type: string;
/**
* Data Structure Type of the underlaying output value
*/
possible_target_types?: MappingSourceTargetType[];
/**
* Initial value of a relation to be added
*/
initial_relation?: RelationAttribute;
/**
* Human readable name of the Source
*/
title: string;
/**
* Human readable type of the source
*/
sub_title?: string;
target_settings?: {
/**
* Describes which actions the user can perform on each target, if specified. If not specified, all actions are allowed
*/
allowed_ui_actions?: ("schema-select" | "attribute-select" | "target-delete" | "target-add" | "target")[];
/**
* Whether its a read-only ui or not. Can be each target, or only the first. Overwrites uiActions
*/
locked?: "each" | "first" | "system_recommendation";
/**
* Whether all source mappings flow into a single attribute (e.g. address)
*/
isSingleTarget?: boolean;
/**
* Determines whether a mapping target should be shown or not. Use if there are targets which cannot be manipulated by the UI. E.g journey_data
*/
visibility?: {
mode: "hide" | "show" | "message";
if: {
[name: string]: string;
};
message?: string;
};
};
}
export interface MappingSourceProperty {

@@ -463,2 +445,15 @@ value: string;

/**
* contains config in case of running in loop mode
*/
loop_config?: {
/**
* path to the array from the entity payload
*/
source_path?: string;
/**
* a hard limit of how many times the loop is allowed to run.
*/
length?: number;
};
/**
* Mode of how conditions are considered valid

@@ -509,3 +504,3 @@ */

* example:
* uuidv4
* 70542580-2b38-4bfc-af8d-bb90102f9f47
*/

@@ -517,3 +512,3 @@ export type Id = string;

* example:
* uuidv4
* 70542580-2b38-4bfc-af8d-bb90102f9f47
*/

@@ -556,3 +551,3 @@ Parameters.Id;

* example:
* uuidv4
* 70542580-2b38-4bfc-af8d-bb90102f9f47
*/

@@ -564,3 +559,3 @@ export type Id = string;

* example:
* uuidv4
* 70542580-2b38-4bfc-af8d-bb90102f9f47
*/

@@ -577,3 +572,3 @@ Parameters.Id;

* example:
* uuidv4
* 70542580-2b38-4bfc-af8d-bb90102f9f47
*/

@@ -585,3 +580,3 @@ export type Id = string;

* example:
* uuidv4
* 70542580-2b38-4bfc-af8d-bb90102f9f47
*/

@@ -598,3 +593,3 @@ Parameters.Id;

* example:
* uuidv4
* 70542580-2b38-4bfc-af8d-bb90102f9f47
*/

@@ -611,3 +606,3 @@ export type Id = string;

* example:
* uuidv4
* 70542580-2b38-4bfc-af8d-bb90102f9f47
*/

@@ -625,2 +620,41 @@ Parameters.Id;

}
namespace GetMappingConfig {
namespace Parameters {
/**
* example:
* 70542580-2b38-4bfc-af8d-bb90102f9f47
*/
export type Id = string;
}
export interface PathParameters {
id: /**
* example:
* 70542580-2b38-4bfc-af8d-bb90102f9f47
*/
Parameters.Id;
}
namespace Responses {
export type $200 = Components.Schemas.MappingConfigV2;
}
}
namespace PutMappingConfig {
namespace Parameters {
/**
* example:
* 70542580-2b38-4bfc-af8d-bb90102f9f47
*/
export type Id = string;
}
export interface PathParameters {
id: /**
* example:
* 70542580-2b38-4bfc-af8d-bb90102f9f47
*/
Parameters.Id;
}
export type RequestBody = Components.Schemas.MappingConfigV2;
namespace Responses {
export type $200 = Components.Schemas.MappingConfigV2;
}
}
namespace QueryMappingHistory {

@@ -667,3 +701,3 @@ namespace Parameters {

* example:
* uuidv4
* 70542580-2b38-4bfc-af8d-bb90102f9f47
*/

@@ -675,3 +709,3 @@ export type Id = string;

* example:
* uuidv4
* 70542580-2b38-4bfc-af8d-bb90102f9f47
*/

@@ -788,2 +822,22 @@ Parameters.Id;

): OperationResponse<Paths.ExecuteRelations.Responses.$200>
/**
* getMappingConfig - getMappingConfig
*
* Get latest version of a mapping config by id V2
*/
'getMappingConfig'(
parameters?: Parameters<Paths.GetMappingConfig.PathParameters> | null,
data?: any,
config?: AxiosRequestConfig
): OperationResponse<Paths.GetMappingConfig.Responses.$200>
/**
* putMappingConfig - putMappingConfig
*
* Stores new version of entity mapping config
*/
'putMappingConfig'(
parameters?: Parameters<Paths.PutMappingConfig.PathParameters> | null,
data?: Paths.PutMappingConfig.RequestBody,
config?: AxiosRequestConfig
): OperationResponse<Paths.PutMappingConfig.Responses.$200>
}

@@ -908,4 +962,26 @@

}
['/v2/mappings/{id}']: {
/**
* getMappingConfig - getMappingConfig
*
* Get latest version of a mapping config by id V2
*/
'get'(
parameters?: Parameters<Paths.GetMappingConfig.PathParameters> | null,
data?: any,
config?: AxiosRequestConfig
): OperationResponse<Paths.GetMappingConfig.Responses.$200>
/**
* putMappingConfig - putMappingConfig
*
* Stores new version of entity mapping config
*/
'put'(
parameters?: Parameters<Paths.PutMappingConfig.PathParameters> | null,
data?: Paths.PutMappingConfig.RequestBody,
config?: AxiosRequestConfig
): OperationResponse<Paths.PutMappingConfig.Responses.$200>
}
}
export type Client = OpenAPIClient<OperationMethods, PathsDictionary>

@@ -79,3 +79,3 @@ {

"type": "string",
"example": "uuidv4"
"example": "70542580-2b38-4bfc-af8d-bb90102f9f47"
}

@@ -112,3 +112,3 @@ }

"type": "string",
"example": "uuidv4"
"example": "70542580-2b38-4bfc-af8d-bb90102f9f47"
}

@@ -147,3 +147,3 @@ }

"type": "string",
"example": "uuidv4"
"example": "70542580-2b38-4bfc-af8d-bb90102f9f47"
}

@@ -180,3 +180,3 @@ }

"type": "string",
"example": "uuidv4"
"example": "70542580-2b38-4bfc-af8d-bb90102f9f47"
}

@@ -225,3 +225,3 @@ }

"type": "string",
"example": "uuidv4"
"example": "70542580-2b38-4bfc-af8d-bb90102f9f47"
}

@@ -426,2 +426,78 @@ },

}
},
"/v2/mappings/{id}": {
"get": {
"operationId": "getMappingConfig",
"summary": "getMappingConfig",
"description": "Get latest version of a mapping config by id V2",
"tags": [
"mappings"
],
"parameters": [
{
"name": "id",
"in": "path",
"required": true,
"description": "Mapping Config Id",
"schema": {
"type": "string",
"example": "70542580-2b38-4bfc-af8d-bb90102f9f47"
}
}
],
"responses": {
"200": {
"description": "Entity Mapping Config",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/MappingConfigV2"
}
}
}
}
}
},
"put": {
"operationId": "putMappingConfig",
"summary": "putMappingConfig",
"description": "Stores new version of entity mapping config",
"tags": [
"mappings"
],
"parameters": [
{
"name": "id",
"in": "path",
"required": true,
"description": "Mapping Config Id",
"schema": {
"type": "string",
"example": "70542580-2b38-4bfc-af8d-bb90102f9f47"
}
}
],
"requestBody": {
"description": "Mapping Config to store",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/MappingConfigV2"
}
}
}
},
"responses": {
"200": {
"description": "The updated entity mapping config",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/MappingConfigV2"
}
}
}
}
}
}
}

@@ -464,2 +540,48 @@ },

"MappingConfig": {
"allOf": [
{
"$ref": "#/components/schemas/MappingConfigCommonFields"
},
{
"type": "object",
"properties": {
"org_id": {
"type": "string",
"example": "66"
},
"version": {
"type": "integer",
"example": 2
}
}
}
],
"required": [
"org_id",
"version"
]
},
"MappingConfigV2": {
"allOf": [
{
"$ref": "#/components/schemas/MappingConfigCommonFields"
},
{
"type": "object",
"properties": {
"org_id": {
"type": "string",
"example": "66",
"readOnly": true
},
"version": {
"type": "integer",
"example": 2,
"readOnly": true
}
}
}
]
},
"MappingConfigCommonFields": {
"type": "object",

@@ -470,8 +592,2 @@ "properties": {

},
"org_id": {
"type": "string"
},
"version": {
"type": "number"
},
"source": {

@@ -513,4 +629,2 @@ "$ref": "#/components/schemas/SourceConfig"

"id",
"org_id",
"version",
"source",

@@ -851,2 +965,17 @@ "targets"

},
"loop_config": {
"type": "object",
"description": "contains config in case of running in loop mode",
"properties": {
"source_path": {
"type": "string",
"description": "path to the array from the entity payload"
},
"length": {
"type": "number",
"description": "a hard limit of how many times the loop is allowed to run.",
"default": "the length of the array"
}
}
},
"conditionMode": {

@@ -1299,3 +1428,3 @@ "description": "Mode of how conditions are considered valid",

"type": "string",
"example": "uuidv4"
"example": "70542580-2b38-4bfc-af8d-bb90102f9f47"
},

@@ -1330,105 +1459,2 @@ "timestamp": {

},
"MappingSource": {
"type": "object",
"properties": {
"key": {
"type": "string",
"description": "Key aiming to identify source"
},
"sub_properties": {
"description": "Each item describes a property under the main source and a possibly, a default value for its target attribute",
"type": "array",
"items": {
"$ref": "#/components/schemas/MappingSourceProperty"
}
},
"source_type": {
"type": "string",
"description": "Data Structure type of source"
},
"possible_target_types": {
"type": "array",
"items": {
"$ref": "#/components/schemas/MappingSourceTargetType"
},
"description": "Data Structure Type of the underlaying output value"
},
"initial_relation": {
"description": "Initial value of a relation to be added",
"$ref": "#/components/schemas/RelationAttribute"
},
"title": {
"type": "string",
"description": "Human readable name of the Source"
},
"sub_title": {
"type": "string",
"description": "Human readable type of the source"
},
"target_settings": {
"type": "object",
"properties": {
"allowed_ui_actions": {
"type": "array",
"items": {
"type": "string",
"enum": [
"schema-select",
"attribute-select",
"target-delete",
"target-add",
"target"
]
},
"description": "Describes which actions the user can perform on each target, if specified. If not specified, all actions are allowed"
},
"locked": {
"type": "string",
"enum": [
"each",
"first",
"system_recommendation"
],
"description": "Whether its a read-only ui or not. Can be each target, or only the first. Overwrites uiActions"
},
"isSingleTarget": {
"type": "boolean",
"description": "Whether all source mappings flow into a single attribute (e.g. address)"
},
"visibility": {
"description": "Determines whether a mapping target should be shown or not. Use if there are targets which cannot be manipulated by the UI. E.g journey_data",
"type": "object",
"properties": {
"mode": {
"type": "string",
"enum": [
"hide",
"show",
"message"
]
},
"if": {
"type": "object",
"additionalProperties": {
"type": "string"
}
},
"message": {
"type": "string"
}
},
"required": [
"mode",
"if"
]
}
}
}
},
"required": [
"key",
"title",
"source_type"
]
},
"MappingSourceProperty": {

@@ -1481,8 +1507,3 @@ "type": "object",

}
},
"servers": [
{
"url": "https://entity-mapping.sls.epilot.io/"
}
]
}
}
{
"name": "@epilot/entity-mapping-client",
"version": "0.8.4",
"version": "0.8.5",
"description": "JavaScript client library for the ePilot Entity Mapping API",

@@ -5,0 +5,0 @@ "main": "dist/index.js",

SocketSocket SOC 2 Logo

Product

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

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc