@epilot/automation-client 2.17.0 → 2.17.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/definition.js +1 -1
- package/dist/openapi-runtime.json +1 -1
- package/dist/openapi.d.ts +352 -6
- package/dist/openapi.json +309 -18
- package/package.json +2 -2
package/dist/definition.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(()=>{"use strict";var e={
|
|
1
|
+
(()=>{"use strict";var e={187:function(e,t,o){var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var r=n(o(466));t.default=r.default},466:e=>{e.exports=JSON.parse('{"openapi":"3.0.3","info":{"title":"","version":""},"paths":{"/v1/automation/flows":{"get":{"operationId":"searchFlows","parameters":[{"name":"schema","in":"query"},{"name":"size","in":"query"},{"name":"from","in":"query"},{"name":"trigger_source_id","in":"query"}],"responses":{}},"post":{"operationId":"createFlow","requestBody":{"content":{"application/json":{}}},"responses":{}}},"/v1/automation/flows/{flow_id}":{"get":{"operationId":"getFlow","parameters":[{"name":"flow_id","in":"path","required":true}],"responses":{}},"put":{"operationId":"putFlow","parameters":[{"name":"flow_id","in":"path","required":true}],"requestBody":{"content":{"application/json":{}}},"responses":{}},"delete":{"operationId":"deleteFlow","parameters":[{"name":"flow_id","in":"path","required":true}],"responses":{}}},"/v1/automation/executions":{"get":{"operationId":"getExecutions","parameters":[{"name":"entity_id","in":"query"},{"name":"size","in":"query"},{"name":"from","in":"query"}],"responses":{}},"post":{"operationId":"startExecution","requestBody":{"content":{"application/json":{}}},"responses":{}}},"/v1/automation/executions/bulk-jobs":{"post":{"operationId":"bulkTriggerExecutions","requestBody":{"content":{"application/json":{}}},"responses":{}}},"/v1/automation/executions/bulk-jobs/{job_id}":{"get":{"operationId":"getBulkJob","parameters":[{"name":"job_id","in":"path","required":true}],"responses":{}},"patch":{"operationId":"patchBulkJob","parameters":[{"name":"job_id","in":"path","required":true}],"requestBody":{"content":{"application/json":{}}},"responses":{}}},"/v1/automation/executions/{execution_id}":{"get":{"operationId":"getExecution","parameters":[{"name":"execution_id","in":"path","required":true}],"responses":{}},"delete":{"operationId":"cancelExecution","parameters":[{"name":"execution_id","in":"path","required":true}],"responses":{}}},"/v1/automation/executions/{execution_id}/{action_id}/retrigger":{"post":{"operationId":"retriggerAction","parameters":[{"name":"execution_id","in":"path","required":true},{"name":"action_id","in":"path","required":true}],"requestBody":{"required":false,"content":{"application/json":{}}},"responses":{}}},"/v1/automation/public/executions:resume":{"post":{"operationId":"resumeExecutionWithToken","requestBody":{"content":{"application/json":{}}},"responses":{}}}},"components":{"responses":{"NotFoundError":{"content":{"application/json":{}}},"ForbiddenError":{"content":{"application/json":{}}}}},"servers":[{"url":"https://automation.sls.epilot.io"}]}')}},t={},o=function o(n){var r=t[n];if(void 0!==r)return r.exports;var i=t[n]={exports:{}};return e[n].call(i.exports,i,i.exports,o),i.exports}(187),n=exports;for(var r in o)n[r]=o[r];o.__esModule&&Object.defineProperty(n,"__esModule",{value:!0})})();
|
package/dist/openapi.d.ts
CHANGED
|
@@ -126,7 +126,7 @@ declare namespace Components {
|
|
|
126
126
|
types?: (("CreateMeterReading" | "UpdateMeterReading" | "DocDownloadedFromPortal" | "PortalUserResetPassword" | "PortalUserResetForgotPassword" | "SelfAssignmentFromPortal") | string)[];
|
|
127
127
|
};
|
|
128
128
|
}
|
|
129
|
-
export type AnyAction = MapEntityAction | TriggerWorkflowAction | TriggerShareEntityAction | TriggerWebhookAction | CreateDocumentAction | SendEmailAction | /* Creates an order entity with prices from journey */ CartCheckoutAction | CustomAction | AutomationAction;
|
|
129
|
+
export type AnyAction = MapEntityAction | TriggerWorkflowAction | TriggerShareEntityAction | TriggerWebhookAction | InformERPAction | CreateDocumentAction | SendEmailAction | /* Creates an order entity with prices from journey */ CartCheckoutAction | CustomAction | AutomationAction;
|
|
130
130
|
export type AnyActionConfig = /**
|
|
131
131
|
* example:
|
|
132
132
|
* {
|
|
@@ -297,6 +297,21 @@ declare namespace Components {
|
|
|
297
297
|
* }
|
|
298
298
|
*/
|
|
299
299
|
TriggerWebhookActionConfig | /**
|
|
300
|
+
* example:
|
|
301
|
+
* {
|
|
302
|
+
* "id": "2520gja-2sgmsaga-0asg-822jgal",
|
|
303
|
+
* "name": "Inform ERP",
|
|
304
|
+
* "type": "inform-erp",
|
|
305
|
+
* "config": {
|
|
306
|
+
* "entity_sources": [
|
|
307
|
+
* "contact",
|
|
308
|
+
* "account"
|
|
309
|
+
* ],
|
|
310
|
+
* "target_webhook_id": "25jg9ag2ga"
|
|
311
|
+
* }
|
|
312
|
+
* }
|
|
313
|
+
*/
|
|
314
|
+
InformERPActionConfig | /**
|
|
300
315
|
* example:
|
|
301
316
|
* {
|
|
302
317
|
* "id": "08g988-ojt2jtaga-292h-8978gsaga",
|
|
@@ -945,15 +960,46 @@ declare namespace Components {
|
|
|
945
960
|
*/
|
|
946
961
|
execution_summary: /* Execution item for bulk trigger automation. It maps each entity to its automation execution id & status */ ExecItem[];
|
|
947
962
|
}
|
|
948
|
-
export
|
|
963
|
+
export type BulkTriggerRequest = {
|
|
949
964
|
flow_id: /**
|
|
950
965
|
* example:
|
|
951
966
|
* 7791b04a-16d2-44a2-9af9-2d59c25c512f
|
|
952
967
|
*/
|
|
953
968
|
AutomationFlowId;
|
|
954
|
-
entities_refs
|
|
955
|
-
|
|
956
|
-
|
|
969
|
+
entities_refs: EntityRef[];
|
|
970
|
+
} | {
|
|
971
|
+
flow_id: /**
|
|
972
|
+
* example:
|
|
973
|
+
* 7791b04a-16d2-44a2-9af9-2d59c25c512f
|
|
974
|
+
*/
|
|
975
|
+
AutomationFlowId;
|
|
976
|
+
entities_query: string;
|
|
977
|
+
} | {
|
|
978
|
+
flow_id: /**
|
|
979
|
+
* example:
|
|
980
|
+
* 7791b04a-16d2-44a2-9af9-2d59c25c512f
|
|
981
|
+
*/
|
|
982
|
+
AutomationFlowId;
|
|
983
|
+
entities_filter: /**
|
|
984
|
+
* A subset of simplified Elasticsearch query clauses. The default operator is a logical AND. Use nested $and, $or, $not to combine filters using different logical operators.
|
|
985
|
+
* example:
|
|
986
|
+
* [
|
|
987
|
+
* {
|
|
988
|
+
* "term": {
|
|
989
|
+
* "_schema": "contact"
|
|
990
|
+
* }
|
|
991
|
+
* },
|
|
992
|
+
* {
|
|
993
|
+
* "terms": {
|
|
994
|
+
* "status": [
|
|
995
|
+
* "active"
|
|
996
|
+
* ]
|
|
997
|
+
* }
|
|
998
|
+
* }
|
|
999
|
+
* ]
|
|
1000
|
+
*/
|
|
1001
|
+
EntitySearchFilter;
|
|
1002
|
+
};
|
|
957
1003
|
/**
|
|
958
1004
|
* Creates an order entity with prices from journey
|
|
959
1005
|
*/
|
|
@@ -1418,7 +1464,7 @@ declare namespace Components {
|
|
|
1418
1464
|
schema?: string;
|
|
1419
1465
|
};
|
|
1420
1466
|
}
|
|
1421
|
-
export type EntityOperation = "createEntity" | "updateEntity" | "deleteEntity";
|
|
1467
|
+
export type EntityOperation = "createEntity" | "updateEntity" | "deleteEntity" | "softDeleteEntity" | "restoreEntity";
|
|
1422
1468
|
/**
|
|
1423
1469
|
* - If provides filter_config, executes an automation based on the filtered configuration when an entity event occurs.
|
|
1424
1470
|
* - The conditions on a filter follows the event bridge patterns - `https://docs.aws.amazon.com/eventbridge/latest/userguide/eb-event-patterns.html`
|
|
@@ -1632,6 +1678,166 @@ declare namespace Components {
|
|
|
1632
1678
|
EntityId;
|
|
1633
1679
|
entity_schema: string;
|
|
1634
1680
|
}
|
|
1681
|
+
/**
|
|
1682
|
+
* A subset of simplified Elasticsearch query clauses. The default operator is a logical AND. Use nested $and, $or, $not to combine filters using different logical operators.
|
|
1683
|
+
* example:
|
|
1684
|
+
* [
|
|
1685
|
+
* {
|
|
1686
|
+
* "term": {
|
|
1687
|
+
* "_schema": "contact"
|
|
1688
|
+
* }
|
|
1689
|
+
* },
|
|
1690
|
+
* {
|
|
1691
|
+
* "terms": {
|
|
1692
|
+
* "status": [
|
|
1693
|
+
* "active"
|
|
1694
|
+
* ]
|
|
1695
|
+
* }
|
|
1696
|
+
* }
|
|
1697
|
+
* ]
|
|
1698
|
+
*/
|
|
1699
|
+
export type EntitySearchFilter = {
|
|
1700
|
+
/**
|
|
1701
|
+
* Returns documents that contain an exact term in a provided field.
|
|
1702
|
+
*
|
|
1703
|
+
* To return a document, the query term must exactly match the queried field's value, including whitespace and capitalization.
|
|
1704
|
+
*
|
|
1705
|
+
* You likely DO NOT want to use this filter on text fields and want to target its .keyword instead.
|
|
1706
|
+
*
|
|
1707
|
+
* example:
|
|
1708
|
+
* {
|
|
1709
|
+
* "_schema": "contact"
|
|
1710
|
+
* }
|
|
1711
|
+
*/
|
|
1712
|
+
term?: {
|
|
1713
|
+
[name: string]: /* A filter field value. */ EntitySearchFilterValue;
|
|
1714
|
+
};
|
|
1715
|
+
/**
|
|
1716
|
+
* Returns documents that contain one of the exact terms in a provided field. See term filter for more info.
|
|
1717
|
+
* example:
|
|
1718
|
+
* {
|
|
1719
|
+
* "status": [
|
|
1720
|
+
* "active"
|
|
1721
|
+
* ]
|
|
1722
|
+
* }
|
|
1723
|
+
*/
|
|
1724
|
+
terms?: {
|
|
1725
|
+
[name: string]: /* A filter field value. */ EntitySearchFilterValue[];
|
|
1726
|
+
};
|
|
1727
|
+
/**
|
|
1728
|
+
* Returns documents based on their IDs.
|
|
1729
|
+
* example:
|
|
1730
|
+
* {
|
|
1731
|
+
* "values": [
|
|
1732
|
+
* "550e8400-e29b-41d4-a716-446655440000"
|
|
1733
|
+
* ]
|
|
1734
|
+
* }
|
|
1735
|
+
*/
|
|
1736
|
+
ids?: {
|
|
1737
|
+
values?: string[];
|
|
1738
|
+
};
|
|
1739
|
+
/**
|
|
1740
|
+
* Returns documents with fields that have terms within a certain range.
|
|
1741
|
+
* example:
|
|
1742
|
+
* {
|
|
1743
|
+
* "_created_at": {
|
|
1744
|
+
* "gte": "2021-01-01T00:00:00.000Z",
|
|
1745
|
+
* "lte": "2021-01-31T23:59:59.999Z"
|
|
1746
|
+
* }
|
|
1747
|
+
* }
|
|
1748
|
+
*/
|
|
1749
|
+
range?: {
|
|
1750
|
+
[name: string]: {
|
|
1751
|
+
gt?: /* A filter field value. */ EntitySearchFilterValue;
|
|
1752
|
+
gte?: /* A filter field value. */ EntitySearchFilterValue;
|
|
1753
|
+
lt?: /* A filter field value. */ EntitySearchFilterValue;
|
|
1754
|
+
lte?: /* A filter field value. */ EntitySearchFilterValue;
|
|
1755
|
+
/**
|
|
1756
|
+
* The date format used to parse date values.
|
|
1757
|
+
*/
|
|
1758
|
+
format?: string;
|
|
1759
|
+
/**
|
|
1760
|
+
* Indicates how the range query matches values for range fields.
|
|
1761
|
+
*/
|
|
1762
|
+
relation?: "INTERSECTS" | "CONTAINS" | "WITHIN";
|
|
1763
|
+
/**
|
|
1764
|
+
* Coordinated Universal Time (UTC) offset or IANA time zone used to convert date values in the query to UTC.
|
|
1765
|
+
*/
|
|
1766
|
+
time_zone?: string;
|
|
1767
|
+
};
|
|
1768
|
+
};
|
|
1769
|
+
/**
|
|
1770
|
+
* Returns documents that have a value in the specified field.
|
|
1771
|
+
* example:
|
|
1772
|
+
* {
|
|
1773
|
+
* "field": "_tags"
|
|
1774
|
+
* }
|
|
1775
|
+
*/
|
|
1776
|
+
exists?: {
|
|
1777
|
+
field: string;
|
|
1778
|
+
};
|
|
1779
|
+
$and?: /**
|
|
1780
|
+
* A subset of simplified Elasticsearch query clauses. The default operator is a logical AND. Use nested $and, $or, $not to combine filters using different logical operators.
|
|
1781
|
+
* example:
|
|
1782
|
+
* [
|
|
1783
|
+
* {
|
|
1784
|
+
* "term": {
|
|
1785
|
+
* "_schema": "contact"
|
|
1786
|
+
* }
|
|
1787
|
+
* },
|
|
1788
|
+
* {
|
|
1789
|
+
* "terms": {
|
|
1790
|
+
* "status": [
|
|
1791
|
+
* "active"
|
|
1792
|
+
* ]
|
|
1793
|
+
* }
|
|
1794
|
+
* }
|
|
1795
|
+
* ]
|
|
1796
|
+
*/
|
|
1797
|
+
EntitySearchFilter;
|
|
1798
|
+
$or?: /**
|
|
1799
|
+
* A subset of simplified Elasticsearch query clauses. The default operator is a logical AND. Use nested $and, $or, $not to combine filters using different logical operators.
|
|
1800
|
+
* example:
|
|
1801
|
+
* [
|
|
1802
|
+
* {
|
|
1803
|
+
* "term": {
|
|
1804
|
+
* "_schema": "contact"
|
|
1805
|
+
* }
|
|
1806
|
+
* },
|
|
1807
|
+
* {
|
|
1808
|
+
* "terms": {
|
|
1809
|
+
* "status": [
|
|
1810
|
+
* "active"
|
|
1811
|
+
* ]
|
|
1812
|
+
* }
|
|
1813
|
+
* }
|
|
1814
|
+
* ]
|
|
1815
|
+
*/
|
|
1816
|
+
EntitySearchFilter;
|
|
1817
|
+
$not?: /**
|
|
1818
|
+
* A subset of simplified Elasticsearch query clauses. The default operator is a logical AND. Use nested $and, $or, $not to combine filters using different logical operators.
|
|
1819
|
+
* example:
|
|
1820
|
+
* [
|
|
1821
|
+
* {
|
|
1822
|
+
* "term": {
|
|
1823
|
+
* "_schema": "contact"
|
|
1824
|
+
* }
|
|
1825
|
+
* },
|
|
1826
|
+
* {
|
|
1827
|
+
* "terms": {
|
|
1828
|
+
* "status": [
|
|
1829
|
+
* "active"
|
|
1830
|
+
* ]
|
|
1831
|
+
* }
|
|
1832
|
+
* }
|
|
1833
|
+
* ]
|
|
1834
|
+
*/
|
|
1835
|
+
EntitySearchFilter;
|
|
1836
|
+
}[];
|
|
1837
|
+
/**
|
|
1838
|
+
* A filter field value.
|
|
1839
|
+
*/
|
|
1840
|
+
export type EntitySearchFilterValue = /* A filter field value. */ (string | null) | number | boolean;
|
|
1635
1841
|
export interface EqualsIgnoreCaseCondition {
|
|
1636
1842
|
"equals-ignore-case"?: string;
|
|
1637
1843
|
}
|
|
@@ -1719,6 +1925,139 @@ declare namespace Components {
|
|
|
1719
1925
|
total: number;
|
|
1720
1926
|
results: AutomationExecution[];
|
|
1721
1927
|
}
|
|
1928
|
+
export interface InformERPAction {
|
|
1929
|
+
id?: /**
|
|
1930
|
+
* example:
|
|
1931
|
+
* 9ec3711b-db63-449c-b894-54d5bb622a8f
|
|
1932
|
+
*/
|
|
1933
|
+
AutomationActionId;
|
|
1934
|
+
flow_action_id?: /**
|
|
1935
|
+
* example:
|
|
1936
|
+
* 9ec3711b-db63-449c-b894-54d5bb622a8f
|
|
1937
|
+
*/
|
|
1938
|
+
AutomationActionId;
|
|
1939
|
+
name?: string;
|
|
1940
|
+
type?: "inform-erp";
|
|
1941
|
+
config?: InformERPConfig;
|
|
1942
|
+
/**
|
|
1943
|
+
* Whether to stop execution in a failed state if this action fails
|
|
1944
|
+
*/
|
|
1945
|
+
allow_failure?: boolean;
|
|
1946
|
+
/**
|
|
1947
|
+
* Flag indicating whether the action was created automatically or manually
|
|
1948
|
+
*/
|
|
1949
|
+
created_automatically?: boolean;
|
|
1950
|
+
/**
|
|
1951
|
+
* Flag indicating whether the same action can be in bulk in a single execution. e.g; send-email / map-entity
|
|
1952
|
+
*/
|
|
1953
|
+
is_bulk_action?: boolean;
|
|
1954
|
+
reason?: {
|
|
1955
|
+
/**
|
|
1956
|
+
* Why the action has to be skipped/failed
|
|
1957
|
+
* example:
|
|
1958
|
+
* There are no registered portal users for the given emails, hence skipping the action
|
|
1959
|
+
*/
|
|
1960
|
+
message?: string;
|
|
1961
|
+
/**
|
|
1962
|
+
* Extra metadata about the skipping reason - such as a certain condition not met, etc.
|
|
1963
|
+
*/
|
|
1964
|
+
payload?: {
|
|
1965
|
+
[name: string]: any;
|
|
1966
|
+
};
|
|
1967
|
+
};
|
|
1968
|
+
/**
|
|
1969
|
+
* Condition Id to be checked before executing the action
|
|
1970
|
+
*/
|
|
1971
|
+
condition_id?: string;
|
|
1972
|
+
/**
|
|
1973
|
+
* Schedule Id which indicates the schedule of the action
|
|
1974
|
+
*/
|
|
1975
|
+
schedule_id?: string;
|
|
1976
|
+
execution_status?: ExecutionStatus;
|
|
1977
|
+
started_at?: string;
|
|
1978
|
+
updated_at?: string;
|
|
1979
|
+
/**
|
|
1980
|
+
* example:
|
|
1981
|
+
* {}
|
|
1982
|
+
*/
|
|
1983
|
+
outputs?: {
|
|
1984
|
+
[name: string]: any;
|
|
1985
|
+
};
|
|
1986
|
+
error_output?: ErrorOutput;
|
|
1987
|
+
retry_strategy?: /* different behaviors for retrying failed execution actions. */ RetryStrategy;
|
|
1988
|
+
}
|
|
1989
|
+
/**
|
|
1990
|
+
* example:
|
|
1991
|
+
* {
|
|
1992
|
+
* "id": "2520gja-2sgmsaga-0asg-822jgal",
|
|
1993
|
+
* "name": "Inform ERP",
|
|
1994
|
+
* "type": "inform-erp",
|
|
1995
|
+
* "config": {
|
|
1996
|
+
* "entity_sources": [
|
|
1997
|
+
* "contact",
|
|
1998
|
+
* "account"
|
|
1999
|
+
* ],
|
|
2000
|
+
* "target_webhook_id": "25jg9ag2ga"
|
|
2001
|
+
* }
|
|
2002
|
+
* }
|
|
2003
|
+
*/
|
|
2004
|
+
export interface InformERPActionConfig {
|
|
2005
|
+
id?: /**
|
|
2006
|
+
* example:
|
|
2007
|
+
* 9ec3711b-db63-449c-b894-54d5bb622a8f
|
|
2008
|
+
*/
|
|
2009
|
+
AutomationActionId;
|
|
2010
|
+
flow_action_id?: /**
|
|
2011
|
+
* example:
|
|
2012
|
+
* 9ec3711b-db63-449c-b894-54d5bb622a8f
|
|
2013
|
+
*/
|
|
2014
|
+
AutomationActionId;
|
|
2015
|
+
name?: string;
|
|
2016
|
+
type?: "inform-erp";
|
|
2017
|
+
config?: InformERPConfig;
|
|
2018
|
+
/**
|
|
2019
|
+
* Whether to stop execution in a failed state if this action fails
|
|
2020
|
+
*/
|
|
2021
|
+
allow_failure?: boolean;
|
|
2022
|
+
/**
|
|
2023
|
+
* Flag indicating whether the action was created automatically or manually
|
|
2024
|
+
*/
|
|
2025
|
+
created_automatically?: boolean;
|
|
2026
|
+
/**
|
|
2027
|
+
* Flag indicating whether the same action can be in bulk in a single execution. e.g; send-email / map-entity
|
|
2028
|
+
*/
|
|
2029
|
+
is_bulk_action?: boolean;
|
|
2030
|
+
reason?: {
|
|
2031
|
+
/**
|
|
2032
|
+
* Why the action has to be skipped/failed
|
|
2033
|
+
* example:
|
|
2034
|
+
* There are no registered portal users for the given emails, hence skipping the action
|
|
2035
|
+
*/
|
|
2036
|
+
message?: string;
|
|
2037
|
+
/**
|
|
2038
|
+
* Extra metadata about the skipping reason - such as a certain condition not met, etc.
|
|
2039
|
+
*/
|
|
2040
|
+
payload?: {
|
|
2041
|
+
[name: string]: any;
|
|
2042
|
+
};
|
|
2043
|
+
};
|
|
2044
|
+
/**
|
|
2045
|
+
* Condition Id to be checked before executing the action
|
|
2046
|
+
*/
|
|
2047
|
+
condition_id?: string;
|
|
2048
|
+
/**
|
|
2049
|
+
* Schedule Id which indicates the schedule of the action
|
|
2050
|
+
*/
|
|
2051
|
+
schedule_id?: string;
|
|
2052
|
+
}
|
|
2053
|
+
export interface InformERPConfig {
|
|
2054
|
+
entity_sources?: string[];
|
|
2055
|
+
target_webhook_id?: string;
|
|
2056
|
+
/**
|
|
2057
|
+
* Whether to wait for the request to finish before continuing automation execution
|
|
2058
|
+
*/
|
|
2059
|
+
sync?: boolean;
|
|
2060
|
+
}
|
|
1722
2061
|
/**
|
|
1723
2062
|
* Job ID for tracking the status of bulk trigger automation executions
|
|
1724
2063
|
* example:
|
|
@@ -3304,6 +3643,7 @@ declare namespace Paths {
|
|
|
3304
3643
|
}
|
|
3305
3644
|
}
|
|
3306
3645
|
|
|
3646
|
+
|
|
3307
3647
|
export interface OperationMethods {
|
|
3308
3648
|
/**
|
|
3309
3649
|
* searchFlows - searchFlows
|
|
@@ -3618,6 +3958,7 @@ export interface PathsDictionary {
|
|
|
3618
3958
|
|
|
3619
3959
|
export type Client = OpenAPIClient<OperationMethods, PathsDictionary>
|
|
3620
3960
|
|
|
3961
|
+
|
|
3621
3962
|
export type ActionCondition = Components.Schemas.ActionCondition;
|
|
3622
3963
|
export type ActionSchedule = Components.Schemas.ActionSchedule;
|
|
3623
3964
|
export type ActionScheduleSource = Components.Schemas.ActionScheduleSource;
|
|
@@ -3661,6 +4002,8 @@ export type EntityManualTrigger = Components.Schemas.EntityManualTrigger;
|
|
|
3661
4002
|
export type EntityOperation = Components.Schemas.EntityOperation;
|
|
3662
4003
|
export type EntityOperationTrigger = Components.Schemas.EntityOperationTrigger;
|
|
3663
4004
|
export type EntityRef = Components.Schemas.EntityRef;
|
|
4005
|
+
export type EntitySearchFilter = Components.Schemas.EntitySearchFilter;
|
|
4006
|
+
export type EntitySearchFilterValue = Components.Schemas.EntitySearchFilterValue;
|
|
3664
4007
|
export type EqualsIgnoreCaseCondition = Components.Schemas.EqualsIgnoreCaseCondition;
|
|
3665
4008
|
export type ErrorCode = Components.Schemas.ErrorCode;
|
|
3666
4009
|
export type ErrorDetail = Components.Schemas.ErrorDetail;
|
|
@@ -3673,6 +4016,9 @@ export type FilterConditionOnEvent = Components.Schemas.FilterConditionOnEvent;
|
|
|
3673
4016
|
export type FlowsTrigger = Components.Schemas.FlowsTrigger;
|
|
3674
4017
|
export type FrontendSubmitTrigger = Components.Schemas.FrontendSubmitTrigger;
|
|
3675
4018
|
export type GetExecutionsResp = Components.Schemas.GetExecutionsResp;
|
|
4019
|
+
export type InformERPAction = Components.Schemas.InformERPAction;
|
|
4020
|
+
export type InformERPActionConfig = Components.Schemas.InformERPActionConfig;
|
|
4021
|
+
export type InformERPConfig = Components.Schemas.InformERPConfig;
|
|
3676
4022
|
export type JobId = Components.Schemas.JobId;
|
|
3677
4023
|
export type JourneySubmitTrigger = Components.Schemas.JourneySubmitTrigger;
|
|
3678
4024
|
export type MapEntityAction = Components.Schemas.MapEntityAction;
|
package/dist/openapi.json
CHANGED
|
@@ -330,9 +330,15 @@
|
|
|
330
330
|
},
|
|
331
331
|
"example": {
|
|
332
332
|
"flow_id": "8e2e067e-3c63-4b1a-8e02-6150a3d1fd89",
|
|
333
|
-
"
|
|
334
|
-
|
|
335
|
-
|
|
333
|
+
"entities_refs": [
|
|
334
|
+
{
|
|
335
|
+
"entity_schema": "opportunity",
|
|
336
|
+
"entity_id": "7791b04a-16d2-44a2-9af9-2d59c25c512f"
|
|
337
|
+
},
|
|
338
|
+
{
|
|
339
|
+
"entity_schema": "opportunity",
|
|
340
|
+
"entity_id": "b35a6c51-2a15-4ef1-9623-20db37b0744f"
|
|
341
|
+
}
|
|
336
342
|
]
|
|
337
343
|
}
|
|
338
344
|
}
|
|
@@ -846,6 +852,9 @@
|
|
|
846
852
|
{
|
|
847
853
|
"$ref": "#/components/schemas/TriggerWebhookAction"
|
|
848
854
|
},
|
|
855
|
+
{
|
|
856
|
+
"$ref": "#/components/schemas/InformERPAction"
|
|
857
|
+
},
|
|
849
858
|
{
|
|
850
859
|
"$ref": "#/components/schemas/CreateDocumentAction"
|
|
851
860
|
},
|
|
@@ -877,6 +886,9 @@
|
|
|
877
886
|
{
|
|
878
887
|
"$ref": "#/components/schemas/TriggerWebhookActionConfig"
|
|
879
888
|
},
|
|
889
|
+
{
|
|
890
|
+
"$ref": "#/components/schemas/InformERPActionConfig"
|
|
891
|
+
},
|
|
880
892
|
{
|
|
881
893
|
"$ref": "#/components/schemas/CreateDocumentActionConfig"
|
|
882
894
|
},
|
|
@@ -2183,6 +2195,77 @@
|
|
|
2183
2195
|
}
|
|
2184
2196
|
}
|
|
2185
2197
|
},
|
|
2198
|
+
"InformERPActionConfig": {
|
|
2199
|
+
"allOf": [
|
|
2200
|
+
{
|
|
2201
|
+
"$ref": "#/components/schemas/AutomationActionConfig"
|
|
2202
|
+
},
|
|
2203
|
+
{
|
|
2204
|
+
"type": "object",
|
|
2205
|
+
"properties": {
|
|
2206
|
+
"type": {
|
|
2207
|
+
"enum": [
|
|
2208
|
+
"inform-erp"
|
|
2209
|
+
]
|
|
2210
|
+
},
|
|
2211
|
+
"config": {
|
|
2212
|
+
"$ref": "#/components/schemas/InformERPConfig"
|
|
2213
|
+
}
|
|
2214
|
+
}
|
|
2215
|
+
}
|
|
2216
|
+
],
|
|
2217
|
+
"example": {
|
|
2218
|
+
"id": "2520gja-2sgmsaga-0asg-822jgal",
|
|
2219
|
+
"name": "Inform ERP",
|
|
2220
|
+
"type": "inform-erp",
|
|
2221
|
+
"config": {
|
|
2222
|
+
"entity_sources": [
|
|
2223
|
+
"contact",
|
|
2224
|
+
"account"
|
|
2225
|
+
],
|
|
2226
|
+
"target_webhook_id": "25jg9ag2ga"
|
|
2227
|
+
}
|
|
2228
|
+
}
|
|
2229
|
+
},
|
|
2230
|
+
"InformERPAction": {
|
|
2231
|
+
"allOf": [
|
|
2232
|
+
{
|
|
2233
|
+
"$ref": "#/components/schemas/AutomationAction"
|
|
2234
|
+
},
|
|
2235
|
+
{
|
|
2236
|
+
"type": "object",
|
|
2237
|
+
"properties": {
|
|
2238
|
+
"type": {
|
|
2239
|
+
"enum": [
|
|
2240
|
+
"inform-erp"
|
|
2241
|
+
]
|
|
2242
|
+
},
|
|
2243
|
+
"config": {
|
|
2244
|
+
"$ref": "#/components/schemas/InformERPConfig"
|
|
2245
|
+
}
|
|
2246
|
+
}
|
|
2247
|
+
}
|
|
2248
|
+
]
|
|
2249
|
+
},
|
|
2250
|
+
"InformERPConfig": {
|
|
2251
|
+
"type": "object",
|
|
2252
|
+
"properties": {
|
|
2253
|
+
"entity_sources": {
|
|
2254
|
+
"type": "array",
|
|
2255
|
+
"items": {
|
|
2256
|
+
"type": "string"
|
|
2257
|
+
}
|
|
2258
|
+
},
|
|
2259
|
+
"target_webhook_id": {
|
|
2260
|
+
"type": "string"
|
|
2261
|
+
},
|
|
2262
|
+
"sync": {
|
|
2263
|
+
"type": "boolean",
|
|
2264
|
+
"description": "Whether to wait for the request to finish before continuing automation execution",
|
|
2265
|
+
"default": false
|
|
2266
|
+
}
|
|
2267
|
+
}
|
|
2268
|
+
},
|
|
2186
2269
|
"ConditionStatement": {
|
|
2187
2270
|
"type": "object",
|
|
2188
2271
|
"properties": {
|
|
@@ -2694,23 +2777,58 @@
|
|
|
2694
2777
|
]
|
|
2695
2778
|
},
|
|
2696
2779
|
"BulkTriggerRequest": {
|
|
2697
|
-
"
|
|
2698
|
-
|
|
2699
|
-
|
|
2700
|
-
"
|
|
2780
|
+
"oneOf": [
|
|
2781
|
+
{
|
|
2782
|
+
"type": "object",
|
|
2783
|
+
"properties": {
|
|
2784
|
+
"flow_id": {
|
|
2785
|
+
"$ref": "#/components/schemas/AutomationFlowId"
|
|
2786
|
+
},
|
|
2787
|
+
"entities_refs": {
|
|
2788
|
+
"type": "array",
|
|
2789
|
+
"items": {
|
|
2790
|
+
"$ref": "#/components/schemas/EntityRef"
|
|
2791
|
+
}
|
|
2792
|
+
}
|
|
2793
|
+
},
|
|
2794
|
+
"required": [
|
|
2795
|
+
"flow_id",
|
|
2796
|
+
"entities_refs"
|
|
2797
|
+
],
|
|
2798
|
+
"additionalProperties": false
|
|
2701
2799
|
},
|
|
2702
|
-
|
|
2703
|
-
"type": "
|
|
2704
|
-
"
|
|
2705
|
-
"
|
|
2706
|
-
|
|
2800
|
+
{
|
|
2801
|
+
"type": "object",
|
|
2802
|
+
"properties": {
|
|
2803
|
+
"flow_id": {
|
|
2804
|
+
"$ref": "#/components/schemas/AutomationFlowId"
|
|
2805
|
+
},
|
|
2806
|
+
"entities_query": {
|
|
2807
|
+
"type": "string"
|
|
2808
|
+
}
|
|
2809
|
+
},
|
|
2810
|
+
"required": [
|
|
2811
|
+
"flow_id",
|
|
2812
|
+
"entities_query"
|
|
2813
|
+
],
|
|
2814
|
+
"additionalProperties": false
|
|
2707
2815
|
},
|
|
2708
|
-
|
|
2709
|
-
"type": "
|
|
2816
|
+
{
|
|
2817
|
+
"type": "object",
|
|
2818
|
+
"properties": {
|
|
2819
|
+
"flow_id": {
|
|
2820
|
+
"$ref": "#/components/schemas/AutomationFlowId"
|
|
2821
|
+
},
|
|
2822
|
+
"entities_filter": {
|
|
2823
|
+
"$ref": "#/components/schemas/EntitySearchFilter"
|
|
2824
|
+
}
|
|
2825
|
+
},
|
|
2826
|
+
"required": [
|
|
2827
|
+
"flow_id",
|
|
2828
|
+
"entities_filter"
|
|
2829
|
+
],
|
|
2830
|
+
"additionalProperties": false
|
|
2710
2831
|
}
|
|
2711
|
-
},
|
|
2712
|
-
"required": [
|
|
2713
|
-
"flow_id"
|
|
2714
2832
|
]
|
|
2715
2833
|
},
|
|
2716
2834
|
"EntityRef": {
|
|
@@ -3227,7 +3345,180 @@
|
|
|
3227
3345
|
"enum": [
|
|
3228
3346
|
"createEntity",
|
|
3229
3347
|
"updateEntity",
|
|
3230
|
-
"deleteEntity"
|
|
3348
|
+
"deleteEntity",
|
|
3349
|
+
"softDeleteEntity",
|
|
3350
|
+
"restoreEntity"
|
|
3351
|
+
]
|
|
3352
|
+
},
|
|
3353
|
+
"EntitySearchFilter": {
|
|
3354
|
+
"type": "array",
|
|
3355
|
+
"description": "A subset of simplified Elasticsearch query clauses. The default operator is a logical AND. Use nested $and, $or, $not to combine filters using different logical operators.",
|
|
3356
|
+
"items": {
|
|
3357
|
+
"type": "object",
|
|
3358
|
+
"minProperties": 1,
|
|
3359
|
+
"maxProperties": 1,
|
|
3360
|
+
"properties": {
|
|
3361
|
+
"term": {
|
|
3362
|
+
"description": "Returns documents that contain an exact term in a provided field.\n\nTo return a document, the query term must exactly match the queried field's value, including whitespace and capitalization.\n\nYou likely DO NOT want to use this filter on text fields and want to target its .keyword instead.\n",
|
|
3363
|
+
"externalDocs": {
|
|
3364
|
+
"url": "https://www.elastic.co/guide/en/elasticsearch/reference/current/query-dsl-term-query.html"
|
|
3365
|
+
},
|
|
3366
|
+
"type": "object",
|
|
3367
|
+
"minProperties": 1,
|
|
3368
|
+
"maxProperties": 1,
|
|
3369
|
+
"additionalProperties": {
|
|
3370
|
+
"$ref": "#/components/schemas/EntitySearchFilterValue"
|
|
3371
|
+
},
|
|
3372
|
+
"example": {
|
|
3373
|
+
"_schema": "contact"
|
|
3374
|
+
}
|
|
3375
|
+
},
|
|
3376
|
+
"terms": {
|
|
3377
|
+
"description": "Returns documents that contain one of the exact terms in a provided field. See term filter for more info.",
|
|
3378
|
+
"externalDocs": {
|
|
3379
|
+
"url": "https://www.elastic.co/guide/en/elasticsearch/reference/current/query-dsl-terms-query.html"
|
|
3380
|
+
},
|
|
3381
|
+
"type": "object",
|
|
3382
|
+
"minProperties": 1,
|
|
3383
|
+
"maxProperties": 1,
|
|
3384
|
+
"additionalProperties": {
|
|
3385
|
+
"type": "array",
|
|
3386
|
+
"items": {
|
|
3387
|
+
"$ref": "#/components/schemas/EntitySearchFilterValue"
|
|
3388
|
+
}
|
|
3389
|
+
},
|
|
3390
|
+
"example": {
|
|
3391
|
+
"status": [
|
|
3392
|
+
"active"
|
|
3393
|
+
]
|
|
3394
|
+
}
|
|
3395
|
+
},
|
|
3396
|
+
"ids": {
|
|
3397
|
+
"description": "Returns documents based on their IDs.",
|
|
3398
|
+
"externalDocs": {
|
|
3399
|
+
"url": "https://www.elastic.co/guide/en/elasticsearch/reference/current/query-dsl-ids-query.html"
|
|
3400
|
+
},
|
|
3401
|
+
"type": "object",
|
|
3402
|
+
"properties": {
|
|
3403
|
+
"values": {
|
|
3404
|
+
"type": "array",
|
|
3405
|
+
"items": {
|
|
3406
|
+
"type": "string"
|
|
3407
|
+
}
|
|
3408
|
+
}
|
|
3409
|
+
},
|
|
3410
|
+
"example": {
|
|
3411
|
+
"values": [
|
|
3412
|
+
"550e8400-e29b-41d4-a716-446655440000"
|
|
3413
|
+
]
|
|
3414
|
+
}
|
|
3415
|
+
},
|
|
3416
|
+
"range": {
|
|
3417
|
+
"description": "Returns documents with fields that have terms within a certain range.",
|
|
3418
|
+
"externalDocs": {
|
|
3419
|
+
"url": "https://www.elastic.co/guide/en/elasticsearch/reference/current/query-dsl-range-query.html"
|
|
3420
|
+
},
|
|
3421
|
+
"type": "object",
|
|
3422
|
+
"minProperties": 1,
|
|
3423
|
+
"maxProperties": 1,
|
|
3424
|
+
"additionalProperties": {
|
|
3425
|
+
"type": "object",
|
|
3426
|
+
"properties": {
|
|
3427
|
+
"gt": {
|
|
3428
|
+
"$ref": "#/components/schemas/EntitySearchFilterValue"
|
|
3429
|
+
},
|
|
3430
|
+
"gte": {
|
|
3431
|
+
"$ref": "#/components/schemas/EntitySearchFilterValue"
|
|
3432
|
+
},
|
|
3433
|
+
"lt": {
|
|
3434
|
+
"$ref": "#/components/schemas/EntitySearchFilterValue"
|
|
3435
|
+
},
|
|
3436
|
+
"lte": {
|
|
3437
|
+
"$ref": "#/components/schemas/EntitySearchFilterValue"
|
|
3438
|
+
},
|
|
3439
|
+
"format": {
|
|
3440
|
+
"type": "string",
|
|
3441
|
+
"description": "The date format used to parse date values."
|
|
3442
|
+
},
|
|
3443
|
+
"relation": {
|
|
3444
|
+
"type": "string",
|
|
3445
|
+
"enum": [
|
|
3446
|
+
"INTERSECTS",
|
|
3447
|
+
"CONTAINS",
|
|
3448
|
+
"WITHIN"
|
|
3449
|
+
],
|
|
3450
|
+
"description": "Indicates how the range query matches values for range fields."
|
|
3451
|
+
},
|
|
3452
|
+
"time_zone": {
|
|
3453
|
+
"type": "string",
|
|
3454
|
+
"description": "Coordinated Universal Time (UTC) offset or IANA time zone used to convert date values in the query to UTC."
|
|
3455
|
+
}
|
|
3456
|
+
}
|
|
3457
|
+
},
|
|
3458
|
+
"example": {
|
|
3459
|
+
"_created_at": {
|
|
3460
|
+
"gte": "2021-01-01T00:00:00.000Z",
|
|
3461
|
+
"lte": "2021-01-31T23:59:59.999Z"
|
|
3462
|
+
}
|
|
3463
|
+
}
|
|
3464
|
+
},
|
|
3465
|
+
"exists": {
|
|
3466
|
+
"description": "Returns documents that have a value in the specified field.",
|
|
3467
|
+
"externalDocs": {
|
|
3468
|
+
"url": "https://www.elastic.co/guide/en/elasticsearch/reference/current/query-dsl-exists-query.html"
|
|
3469
|
+
},
|
|
3470
|
+
"type": "object",
|
|
3471
|
+
"properties": {
|
|
3472
|
+
"field": {
|
|
3473
|
+
"type": "string"
|
|
3474
|
+
}
|
|
3475
|
+
},
|
|
3476
|
+
"required": [
|
|
3477
|
+
"field"
|
|
3478
|
+
],
|
|
3479
|
+
"example": {
|
|
3480
|
+
"field": "_tags"
|
|
3481
|
+
}
|
|
3482
|
+
},
|
|
3483
|
+
"$and": {
|
|
3484
|
+
"$ref": "#/components/schemas/EntitySearchFilter"
|
|
3485
|
+
},
|
|
3486
|
+
"$or": {
|
|
3487
|
+
"$ref": "#/components/schemas/EntitySearchFilter"
|
|
3488
|
+
},
|
|
3489
|
+
"$not": {
|
|
3490
|
+
"$ref": "#/components/schemas/EntitySearchFilter"
|
|
3491
|
+
}
|
|
3492
|
+
}
|
|
3493
|
+
},
|
|
3494
|
+
"example": [
|
|
3495
|
+
{
|
|
3496
|
+
"term": {
|
|
3497
|
+
"_schema": "contact"
|
|
3498
|
+
}
|
|
3499
|
+
},
|
|
3500
|
+
{
|
|
3501
|
+
"terms": {
|
|
3502
|
+
"status": [
|
|
3503
|
+
"active"
|
|
3504
|
+
]
|
|
3505
|
+
}
|
|
3506
|
+
}
|
|
3507
|
+
]
|
|
3508
|
+
},
|
|
3509
|
+
"EntitySearchFilterValue": {
|
|
3510
|
+
"description": "A filter field value.",
|
|
3511
|
+
"oneOf": [
|
|
3512
|
+
{
|
|
3513
|
+
"type": "string",
|
|
3514
|
+
"nullable": true
|
|
3515
|
+
},
|
|
3516
|
+
{
|
|
3517
|
+
"type": "number"
|
|
3518
|
+
},
|
|
3519
|
+
{
|
|
3520
|
+
"type": "boolean"
|
|
3521
|
+
}
|
|
3231
3522
|
]
|
|
3232
3523
|
},
|
|
3233
3524
|
"EntityManualTrigger": {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@epilot/automation-client",
|
|
3
|
-
"version": "2.17.
|
|
3
|
+
"version": "2.17.2",
|
|
4
4
|
"description": "Client library for epilot automation API",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"types": "dist/index.d.ts",
|
|
@@ -66,7 +66,7 @@
|
|
|
66
66
|
"json-loader": "^0.5.7",
|
|
67
67
|
"node-fetch": "^3.2.10",
|
|
68
68
|
"openapi-client-axios": "^7.5.1",
|
|
69
|
-
"openapicmd": "^2.6.
|
|
69
|
+
"openapicmd": "^2.6.2",
|
|
70
70
|
"ts-jest": "^26.5.0",
|
|
71
71
|
"ts-loader": "^8.0.14",
|
|
72
72
|
"ts-node": "^10.9.1",
|