@epilot/automation-client 0.1.1 → 0.2.0

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.
@@ -1 +1 @@
1
- !function(e,t){for(var n in t)e[n]=t[n];t.__esModule&&Object.defineProperty(e,"__esModule",{value:!0})}(exports,(()=>{"use strict";var e={914:function(e,t,n){var i=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var a=i(n(279));t.default=a.default},279:e=>{e.exports=JSON.parse('{"openapi":"3.0.3","info":{"title":"Automation API","description":"API Backend for epilot Automation Workflows feature","version":"1.0.0"},"tags":[{"name":"definitions","description":"Automation definitions"},{"name":"executions","description":"Automation executions"}],"security":[{"EpilotAuth":[]},{"AsOrganization":[]}],"paths":{"/v1/automation/definitions":{"get":{"operationId":"searchAutomations","summary":"searchAutomations","description":"Search available automation definitions","tags":["definitions"],"parameters":[{"name":"schema","in":"query","description":"Entity Schema","schema":{"type":"string","example":"submission"}},{"name":"size","in":"query","description":"Pagination: max number of results to return","schema":{"type":"integer","default":25}},{"name":"from","in":"query","description":"Pagination: starting for results","schema":{"type":"integer","default":0}}],"responses":{"200":{"description":"List of automation definitions","content":{"application/json":{"schema":{"type":"object","properties":{"total":{"type":"integer","example":1},"results":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","example":"7791b04a-16d2-44a2-9af9-2d59c25c512f"},"definition_name":{"type":"string","example":"Handle contact form"},"triggers":{"type":"array","items":{"type":"object","properties":{"on":{"type":"string","enum":["entity_create","entity_update","entity_delete","journey_submit","frontend_submit"]},"config":{"type":"object","additionalProperties":true,"example":{"entity_schema":"contact"}}},"required":["on","config"],"example":{"on":"journey_submit","config":{"journey_id":"53c5d0bb-4ee7-4ed6-b3e0-0262383fd4b9"}}}},"schemas":{"type":"array","description":"schemas this automation is available for","items":{"type":"string","example":"submission"}},"actions":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","example":"9ec3711b-db63-449c-b894-54d5bb622a8f"},"name":{"type":"string","example":"Create Contact"},"type":{"type":"string","example":"entity_mapping"},"config":{"type":"object","additionalProperties":true,"example":{"mapping_attributes":[{"target":"email","mode":"upsert_match","source":"billing_contact.email"},{"target":"first_name","mode":"copy_if_exists","source":"billing_contact.first_name"},{"target":"last_name","mode":"copy_if_exists","source":"billing_contact.last_name"},{"target":"addresses","mode":"append_if_exists","source":"billing_contact","value_json":"{\\n \\"street_name\\": \\"{{billing_contact.street_name}}\\",\\n \\"street_number\\": \\"{{billing_contact.street_number}}\\",\\n \\"city\\": \\"{{billing_contact.city}}\\",\\n \\"postal_code\\": \\"{{billing_contact.postal_code}}\\",\\n \\"country\\": \\"{{billing_contact.country}}\\",\\n}"},{"target":"addresses","mode":"append_if_exists","source":"delivery_contact","value_json":"{\\n \\"street_name\\": \\"{{delivery_contact.street_name}}\\",\\n \\"street_number\\": \\"{{delivery_contact.street_number}}\\",\\n \\"city\\": \\"{{delivery_contact.city}}\\",\\n \\"postal_code\\": \\"{{delivery_contact.postal_code}}\\",\\n \\"country\\": \\"{{delivery_contact.country}}\\",\\n}"}]}}}}},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"}}}}}}}}}}},"post":{"operationId":"createAutomation","summary":"createAutomation","description":"Create new automation definition","tags":["definitions"],"requestBody":{"description":"Automation definition to create","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string","example":"7791b04a-16d2-44a2-9af9-2d59c25c512f"},"definition_name":{"type":"string","example":"Handle contact form"},"triggers":{"type":"array","items":{"type":"object","properties":{"on":{"type":"string","enum":["entity_create","entity_update","entity_delete","journey_submit","frontend_submit"]},"config":{"type":"object","additionalProperties":true,"example":{"entity_schema":"contact"}}},"required":["on","config"],"example":{"on":"journey_submit","config":{"journey_id":"53c5d0bb-4ee7-4ed6-b3e0-0262383fd4b9"}}}},"schemas":{"type":"array","description":"schemas this automation is available for","items":{"type":"string","example":"submission"}},"actions":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","example":"9ec3711b-db63-449c-b894-54d5bb622a8f"},"name":{"type":"string","example":"Create Contact"},"type":{"type":"string","example":"entity_mapping"},"config":{"type":"object","additionalProperties":true,"example":{"mapping_attributes":[{"target":"email","mode":"upsert_match","source":"billing_contact.email"},{"target":"first_name","mode":"copy_if_exists","source":"billing_contact.first_name"},{"target":"last_name","mode":"copy_if_exists","source":"billing_contact.last_name"},{"target":"addresses","mode":"append_if_exists","source":"billing_contact","value_json":"{\\n \\"street_name\\": \\"{{billing_contact.street_name}}\\",\\n \\"street_number\\": \\"{{billing_contact.street_number}}\\",\\n \\"city\\": \\"{{billing_contact.city}}\\",\\n \\"postal_code\\": \\"{{billing_contact.postal_code}}\\",\\n \\"country\\": \\"{{billing_contact.country}}\\",\\n}"},{"target":"addresses","mode":"append_if_exists","source":"delivery_contact","value_json":"{\\n \\"street_name\\": \\"{{delivery_contact.street_name}}\\",\\n \\"street_number\\": \\"{{delivery_contact.street_number}}\\",\\n \\"city\\": \\"{{delivery_contact.city}}\\",\\n \\"postal_code\\": \\"{{delivery_contact.postal_code}}\\",\\n \\"country\\": \\"{{delivery_contact.country}}\\",\\n}"}]}}}}},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"}}}}}},"responses":{"201":{"description":"The created automation definition","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string","example":"7791b04a-16d2-44a2-9af9-2d59c25c512f"},"definition_name":{"type":"string","example":"Handle contact form"},"triggers":{"type":"array","items":{"type":"object","properties":{"on":{"type":"string","enum":["entity_create","entity_update","entity_delete","journey_submit","frontend_submit"]},"config":{"type":"object","additionalProperties":true,"example":{"entity_schema":"contact"}}},"required":["on","config"],"example":{"on":"journey_submit","config":{"journey_id":"53c5d0bb-4ee7-4ed6-b3e0-0262383fd4b9"}}}},"schemas":{"type":"array","description":"schemas this automation is available for","items":{"type":"string","example":"submission"}},"actions":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","example":"9ec3711b-db63-449c-b894-54d5bb622a8f"},"name":{"type":"string","example":"Create Contact"},"type":{"type":"string","example":"entity_mapping"},"config":{"type":"object","additionalProperties":true,"example":{"mapping_attributes":[{"target":"email","mode":"upsert_match","source":"billing_contact.email"},{"target":"first_name","mode":"copy_if_exists","source":"billing_contact.first_name"},{"target":"last_name","mode":"copy_if_exists","source":"billing_contact.last_name"},{"target":"addresses","mode":"append_if_exists","source":"billing_contact","value_json":"{\\n \\"street_name\\": \\"{{billing_contact.street_name}}\\",\\n \\"street_number\\": \\"{{billing_contact.street_number}}\\",\\n \\"city\\": \\"{{billing_contact.city}}\\",\\n \\"postal_code\\": \\"{{billing_contact.postal_code}}\\",\\n \\"country\\": \\"{{billing_contact.country}}\\",\\n}"},{"target":"addresses","mode":"append_if_exists","source":"delivery_contact","value_json":"{\\n \\"street_name\\": \\"{{delivery_contact.street_name}}\\",\\n \\"street_number\\": \\"{{delivery_contact.street_number}}\\",\\n \\"city\\": \\"{{delivery_contact.city}}\\",\\n \\"postal_code\\": \\"{{delivery_contact.postal_code}}\\",\\n \\"country\\": \\"{{delivery_contact.country}}\\",\\n}"}]}}}}},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"}}}}}}}}},"/v1/automation/definitions/{definition_id}":{"get":{"operationId":"getAutomation","summary":"getAutomation","description":"List available automation definitions","tags":["definitions"],"parameters":[{"name":"definition_id","in":"path","required":true,"description":"Automation Workflow ID","schema":{"type":"string","example":"7791b04a-16d2-44a2-9af9-2d59c25c512f"}}],"responses":{"200":{"description":"The returned automation definition","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string","example":"7791b04a-16d2-44a2-9af9-2d59c25c512f"},"definition_name":{"type":"string","example":"Handle contact form"},"triggers":{"type":"array","items":{"type":"object","properties":{"on":{"type":"string","enum":["entity_create","entity_update","entity_delete","journey_submit","frontend_submit"]},"config":{"type":"object","additionalProperties":true,"example":{"entity_schema":"contact"}}},"required":["on","config"],"example":{"on":"journey_submit","config":{"journey_id":"53c5d0bb-4ee7-4ed6-b3e0-0262383fd4b9"}}}},"schemas":{"type":"array","description":"schemas this automation is available for","items":{"type":"string","example":"submission"}},"actions":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","example":"9ec3711b-db63-449c-b894-54d5bb622a8f"},"name":{"type":"string","example":"Create Contact"},"type":{"type":"string","example":"entity_mapping"},"config":{"type":"object","additionalProperties":true,"example":{"mapping_attributes":[{"target":"email","mode":"upsert_match","source":"billing_contact.email"},{"target":"first_name","mode":"copy_if_exists","source":"billing_contact.first_name"},{"target":"last_name","mode":"copy_if_exists","source":"billing_contact.last_name"},{"target":"addresses","mode":"append_if_exists","source":"billing_contact","value_json":"{\\n \\"street_name\\": \\"{{billing_contact.street_name}}\\",\\n \\"street_number\\": \\"{{billing_contact.street_number}}\\",\\n \\"city\\": \\"{{billing_contact.city}}\\",\\n \\"postal_code\\": \\"{{billing_contact.postal_code}}\\",\\n \\"country\\": \\"{{billing_contact.country}}\\",\\n}"},{"target":"addresses","mode":"append_if_exists","source":"delivery_contact","value_json":"{\\n \\"street_name\\": \\"{{delivery_contact.street_name}}\\",\\n \\"street_number\\": \\"{{delivery_contact.street_number}}\\",\\n \\"city\\": \\"{{delivery_contact.city}}\\",\\n \\"postal_code\\": \\"{{delivery_contact.postal_code}}\\",\\n \\"country\\": \\"{{delivery_contact.country}}\\",\\n}"}]}}}}},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"}}}}}}}},"put":{"operationId":"putAutomation","summary":"putAutomation","description":"Update automation definition by id","tags":["definitions"],"parameters":[{"name":"definition_id","in":"path","required":true,"description":"Automation Workflow ID","schema":{"type":"string","example":"7791b04a-16d2-44a2-9af9-2d59c25c512f"}}],"requestBody":{"description":"Automation definition to create","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string","example":"7791b04a-16d2-44a2-9af9-2d59c25c512f"},"definition_name":{"type":"string","example":"Handle contact form"},"triggers":{"type":"array","items":{"type":"object","properties":{"on":{"type":"string","enum":["entity_create","entity_update","entity_delete","journey_submit","frontend_submit"]},"config":{"type":"object","additionalProperties":true,"example":{"entity_schema":"contact"}}},"required":["on","config"],"example":{"on":"journey_submit","config":{"journey_id":"53c5d0bb-4ee7-4ed6-b3e0-0262383fd4b9"}}}},"schemas":{"type":"array","description":"schemas this automation is available for","items":{"type":"string","example":"submission"}},"actions":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","example":"9ec3711b-db63-449c-b894-54d5bb622a8f"},"name":{"type":"string","example":"Create Contact"},"type":{"type":"string","example":"entity_mapping"},"config":{"type":"object","additionalProperties":true,"example":{"mapping_attributes":[{"target":"email","mode":"upsert_match","source":"billing_contact.email"},{"target":"first_name","mode":"copy_if_exists","source":"billing_contact.first_name"},{"target":"last_name","mode":"copy_if_exists","source":"billing_contact.last_name"},{"target":"addresses","mode":"append_if_exists","source":"billing_contact","value_json":"{\\n \\"street_name\\": \\"{{billing_contact.street_name}}\\",\\n \\"street_number\\": \\"{{billing_contact.street_number}}\\",\\n \\"city\\": \\"{{billing_contact.city}}\\",\\n \\"postal_code\\": \\"{{billing_contact.postal_code}}\\",\\n \\"country\\": \\"{{billing_contact.country}}\\",\\n}"},{"target":"addresses","mode":"append_if_exists","source":"delivery_contact","value_json":"{\\n \\"street_name\\": \\"{{delivery_contact.street_name}}\\",\\n \\"street_number\\": \\"{{delivery_contact.street_number}}\\",\\n \\"city\\": \\"{{delivery_contact.city}}\\",\\n \\"postal_code\\": \\"{{delivery_contact.postal_code}}\\",\\n \\"country\\": \\"{{delivery_contact.country}}\\",\\n}"}]}}}}},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"}}}}}},"responses":{"201":{"description":"The updated automation definition","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string","example":"7791b04a-16d2-44a2-9af9-2d59c25c512f"},"definition_name":{"type":"string","example":"Handle contact form"},"triggers":{"type":"array","items":{"type":"object","properties":{"on":{"type":"string","enum":["entity_create","entity_update","entity_delete","journey_submit","frontend_submit"]},"config":{"type":"object","additionalProperties":true,"example":{"entity_schema":"contact"}}},"required":["on","config"],"example":{"on":"journey_submit","config":{"journey_id":"53c5d0bb-4ee7-4ed6-b3e0-0262383fd4b9"}}}},"schemas":{"type":"array","description":"schemas this automation is available for","items":{"type":"string","example":"submission"}},"actions":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","example":"9ec3711b-db63-449c-b894-54d5bb622a8f"},"name":{"type":"string","example":"Create Contact"},"type":{"type":"string","example":"entity_mapping"},"config":{"type":"object","additionalProperties":true,"example":{"mapping_attributes":[{"target":"email","mode":"upsert_match","source":"billing_contact.email"},{"target":"first_name","mode":"copy_if_exists","source":"billing_contact.first_name"},{"target":"last_name","mode":"copy_if_exists","source":"billing_contact.last_name"},{"target":"addresses","mode":"append_if_exists","source":"billing_contact","value_json":"{\\n \\"street_name\\": \\"{{billing_contact.street_name}}\\",\\n \\"street_number\\": \\"{{billing_contact.street_number}}\\",\\n \\"city\\": \\"{{billing_contact.city}}\\",\\n \\"postal_code\\": \\"{{billing_contact.postal_code}}\\",\\n \\"country\\": \\"{{billing_contact.country}}\\",\\n}"},{"target":"addresses","mode":"append_if_exists","source":"delivery_contact","value_json":"{\\n \\"street_name\\": \\"{{delivery_contact.street_name}}\\",\\n \\"street_number\\": \\"{{delivery_contact.street_number}}\\",\\n \\"city\\": \\"{{delivery_contact.city}}\\",\\n \\"postal_code\\": \\"{{delivery_contact.postal_code}}\\",\\n \\"country\\": \\"{{delivery_contact.country}}\\",\\n}"}]}}}}},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"}}}}}}}},"delete":{"operationId":"deleteAutomation","summary":"deleteAutomation","description":"Update automation definition by id","tags":["definitions"],"parameters":[{"name":"definition_id","in":"path","required":true,"description":"Automation Workflow ID","schema":{"type":"string","example":"7791b04a-16d2-44a2-9af9-2d59c25c512f"}}],"responses":{"200":{"description":"The deleted automation definition","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string","example":"7791b04a-16d2-44a2-9af9-2d59c25c512f"},"definition_name":{"type":"string","example":"Handle contact form"},"triggers":{"type":"array","items":{"type":"object","properties":{"on":{"type":"string","enum":["entity_create","entity_update","entity_delete","journey_submit","frontend_submit"]},"config":{"type":"object","additionalProperties":true,"example":{"entity_schema":"contact"}}},"required":["on","config"],"example":{"on":"journey_submit","config":{"journey_id":"53c5d0bb-4ee7-4ed6-b3e0-0262383fd4b9"}}}},"schemas":{"type":"array","description":"schemas this automation is available for","items":{"type":"string","example":"submission"}},"actions":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","example":"9ec3711b-db63-449c-b894-54d5bb622a8f"},"name":{"type":"string","example":"Create Contact"},"type":{"type":"string","example":"entity_mapping"},"config":{"type":"object","additionalProperties":true,"example":{"mapping_attributes":[{"target":"email","mode":"upsert_match","source":"billing_contact.email"},{"target":"first_name","mode":"copy_if_exists","source":"billing_contact.first_name"},{"target":"last_name","mode":"copy_if_exists","source":"billing_contact.last_name"},{"target":"addresses","mode":"append_if_exists","source":"billing_contact","value_json":"{\\n \\"street_name\\": \\"{{billing_contact.street_name}}\\",\\n \\"street_number\\": \\"{{billing_contact.street_number}}\\",\\n \\"city\\": \\"{{billing_contact.city}}\\",\\n \\"postal_code\\": \\"{{billing_contact.postal_code}}\\",\\n \\"country\\": \\"{{billing_contact.country}}\\",\\n}"},{"target":"addresses","mode":"append_if_exists","source":"delivery_contact","value_json":"{\\n \\"street_name\\": \\"{{delivery_contact.street_name}}\\",\\n \\"street_number\\": \\"{{delivery_contact.street_number}}\\",\\n \\"city\\": \\"{{delivery_contact.city}}\\",\\n \\"postal_code\\": \\"{{delivery_contact.postal_code}}\\",\\n \\"country\\": \\"{{delivery_contact.country}}\\",\\n}"}]}}}}},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"}}}}}}}}},"/v1/automation/executions":{"get":{"operationId":"getExecutions","summary":"getExecutions","description":"List automation executions","parameters":[{"name":"entity_id","in":"query","schema":{"type":"string","example":"e3d3ebac-baab-4395-abf4-50b5bf1f8b74"}},{"name":"size","in":"query","description":"Pagination: max number of results to return","schema":{"type":"integer","default":25}},{"name":"from","in":"query","description":"Pagination: starting for results","schema":{"type":"integer","default":0}}],"tags":["executions"],"responses":{"200":{"description":"List of automation executions","content":{"application/json":{"schema":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","example":"9baf184f-bc81-4128-bca3-d974c90a12c4"},"status":{"type":"string","enum":["pending","in_progress","success","failed","cancelled"],"example":"success"},"entity_id":{"type":"string","example":"e3d3ebac-baab-4395-abf4-50b5bf1f8b74"},"definition_id":{"type":"string","example":"7791b04a-16d2-44a2-9af9-2d59c25c512f"},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"current_action":{"type":"string","example":"9ec3711b-db63-449c-b894-54d5bb622a8f"},"actions":{"type":"array","items":{"allOf":[{"type":"object","properties":{"status":{"type":"string","enum":["pending","in_progress","success","failed"]}}},{"type":"object","properties":{"id":{"type":"string","example":"9ec3711b-db63-449c-b894-54d5bb622a8f"},"name":{"type":"string","example":"Create Contact"},"type":{"type":"string","example":"entity_mapping"},"config":{"type":"object","additionalProperties":true,"example":{"mapping_attributes":[{"target":"email","mode":"upsert_match","source":"billing_contact.email"},{"target":"first_name","mode":"copy_if_exists","source":"billing_contact.first_name"},{"target":"last_name","mode":"copy_if_exists","source":"billing_contact.last_name"},{"target":"addresses","mode":"append_if_exists","source":"billing_contact","value_json":"{\\n \\"street_name\\": \\"{{billing_contact.street_name}}\\",\\n \\"street_number\\": \\"{{billing_contact.street_number}}\\",\\n \\"city\\": \\"{{billing_contact.city}}\\",\\n \\"postal_code\\": \\"{{billing_contact.postal_code}}\\",\\n \\"country\\": \\"{{billing_contact.country}}\\",\\n}"},{"target":"addresses","mode":"append_if_exists","source":"delivery_contact","value_json":"{\\n \\"street_name\\": \\"{{delivery_contact.street_name}}\\",\\n \\"street_number\\": \\"{{delivery_contact.street_number}}\\",\\n \\"city\\": \\"{{delivery_contact.city}}\\",\\n \\"postal_code\\": \\"{{delivery_contact.postal_code}}\\",\\n \\"country\\": \\"{{delivery_contact.country}}\\",\\n}"}]}}}}]}}}}}}}}}},"post":{"operationId":"startExecution","summary":"startExecution","description":"Start new automation execution","requestBody":{"description":"Execution parameters","content":{"application/json":{"schema":{"type":"object","properties":{"entity_id":{"type":"string","example":"e3d3ebac-baab-4395-abf4-50b5bf1f8b74"},"definition_id":{"type":"string","example":"7791b04a-16d2-44a2-9af9-2d59c25c512f"}}}}}},"tags":["executions"],"responses":{"201":{"description":"The created execution","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string","example":"9baf184f-bc81-4128-bca3-d974c90a12c4"},"status":{"type":"string","enum":["pending","in_progress","success","failed","cancelled"],"example":"success"},"entity_id":{"type":"string","example":"e3d3ebac-baab-4395-abf4-50b5bf1f8b74"},"definition_id":{"type":"string","example":"7791b04a-16d2-44a2-9af9-2d59c25c512f"},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"current_action":{"type":"string","example":"9ec3711b-db63-449c-b894-54d5bb622a8f"},"actions":{"type":"array","items":{"allOf":[{"type":"object","properties":{"status":{"type":"string","enum":["pending","in_progress","success","failed"]}}},{"type":"object","properties":{"id":{"type":"string","example":"9ec3711b-db63-449c-b894-54d5bb622a8f"},"name":{"type":"string","example":"Create Contact"},"type":{"type":"string","example":"entity_mapping"},"config":{"type":"object","additionalProperties":true,"example":{"mapping_attributes":[{"target":"email","mode":"upsert_match","source":"billing_contact.email"},{"target":"first_name","mode":"copy_if_exists","source":"billing_contact.first_name"},{"target":"last_name","mode":"copy_if_exists","source":"billing_contact.last_name"},{"target":"addresses","mode":"append_if_exists","source":"billing_contact","value_json":"{\\n \\"street_name\\": \\"{{billing_contact.street_name}}\\",\\n \\"street_number\\": \\"{{billing_contact.street_number}}\\",\\n \\"city\\": \\"{{billing_contact.city}}\\",\\n \\"postal_code\\": \\"{{billing_contact.postal_code}}\\",\\n \\"country\\": \\"{{billing_contact.country}}\\",\\n}"},{"target":"addresses","mode":"append_if_exists","source":"delivery_contact","value_json":"{\\n \\"street_name\\": \\"{{delivery_contact.street_name}}\\",\\n \\"street_number\\": \\"{{delivery_contact.street_number}}\\",\\n \\"city\\": \\"{{delivery_contact.city}}\\",\\n \\"postal_code\\": \\"{{delivery_contact.postal_code}}\\",\\n \\"country\\": \\"{{delivery_contact.country}}\\",\\n}"}]}}}}]}}}}}}}}}},"/v1/automation/executions/{execution_id}":{"get":{"operationId":"getExecution","summary":"getExecution","description":"Get automation execution","parameters":[{"name":"execution_id","in":"path","schema":{"type":"string","example":"9baf184f-bc81-4128-bca3-d974c90a12c4"},"required":true}],"tags":["executions"],"responses":{"200":{"description":"The returned execution","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string","example":"9baf184f-bc81-4128-bca3-d974c90a12c4"},"status":{"type":"string","enum":["pending","in_progress","success","failed","cancelled"],"example":"success"},"entity_id":{"type":"string","example":"e3d3ebac-baab-4395-abf4-50b5bf1f8b74"},"definition_id":{"type":"string","example":"7791b04a-16d2-44a2-9af9-2d59c25c512f"},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"current_action":{"type":"string","example":"9ec3711b-db63-449c-b894-54d5bb622a8f"},"actions":{"type":"array","items":{"allOf":[{"type":"object","properties":{"status":{"type":"string","enum":["pending","in_progress","success","failed"]}}},{"type":"object","properties":{"id":{"type":"string","example":"9ec3711b-db63-449c-b894-54d5bb622a8f"},"name":{"type":"string","example":"Create Contact"},"type":{"type":"string","example":"entity_mapping"},"config":{"type":"object","additionalProperties":true,"example":{"mapping_attributes":[{"target":"email","mode":"upsert_match","source":"billing_contact.email"},{"target":"first_name","mode":"copy_if_exists","source":"billing_contact.first_name"},{"target":"last_name","mode":"copy_if_exists","source":"billing_contact.last_name"},{"target":"addresses","mode":"append_if_exists","source":"billing_contact","value_json":"{\\n \\"street_name\\": \\"{{billing_contact.street_name}}\\",\\n \\"street_number\\": \\"{{billing_contact.street_number}}\\",\\n \\"city\\": \\"{{billing_contact.city}}\\",\\n \\"postal_code\\": \\"{{billing_contact.postal_code}}\\",\\n \\"country\\": \\"{{billing_contact.country}}\\",\\n}"},{"target":"addresses","mode":"append_if_exists","source":"delivery_contact","value_json":"{\\n \\"street_name\\": \\"{{delivery_contact.street_name}}\\",\\n \\"street_number\\": \\"{{delivery_contact.street_number}}\\",\\n \\"city\\": \\"{{delivery_contact.city}}\\",\\n \\"postal_code\\": \\"{{delivery_contact.postal_code}}\\",\\n \\"country\\": \\"{{delivery_contact.country}}\\",\\n}"}]}}}}]}}}}}}}}},"delete":{"operationId":"cancelExecution","summary":"cancelExecution","description":"Cancel automation execution","parameters":[{"name":"execution_id","in":"path","schema":{"type":"string","example":"9baf184f-bc81-4128-bca3-d974c90a12c4"},"required":true}],"tags":["executions"],"responses":{"200":{"description":"The cancelled execution","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string","example":"9baf184f-bc81-4128-bca3-d974c90a12c4"},"status":{"type":"string","enum":["pending","in_progress","success","failed","cancelled"],"example":"success"},"entity_id":{"type":"string","example":"e3d3ebac-baab-4395-abf4-50b5bf1f8b74"},"definition_id":{"type":"string","example":"7791b04a-16d2-44a2-9af9-2d59c25c512f"},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"current_action":{"type":"string","example":"9ec3711b-db63-449c-b894-54d5bb622a8f"},"actions":{"type":"array","items":{"allOf":[{"type":"object","properties":{"status":{"type":"string","enum":["pending","in_progress","success","failed"]}}},{"type":"object","properties":{"id":{"type":"string","example":"9ec3711b-db63-449c-b894-54d5bb622a8f"},"name":{"type":"string","example":"Create Contact"},"type":{"type":"string","example":"entity_mapping"},"config":{"type":"object","additionalProperties":true,"example":{"mapping_attributes":[{"target":"email","mode":"upsert_match","source":"billing_contact.email"},{"target":"first_name","mode":"copy_if_exists","source":"billing_contact.first_name"},{"target":"last_name","mode":"copy_if_exists","source":"billing_contact.last_name"},{"target":"addresses","mode":"append_if_exists","source":"billing_contact","value_json":"{\\n \\"street_name\\": \\"{{billing_contact.street_name}}\\",\\n \\"street_number\\": \\"{{billing_contact.street_number}}\\",\\n \\"city\\": \\"{{billing_contact.city}}\\",\\n \\"postal_code\\": \\"{{billing_contact.postal_code}}\\",\\n \\"country\\": \\"{{billing_contact.country}}\\",\\n}"},{"target":"addresses","mode":"append_if_exists","source":"delivery_contact","value_json":"{\\n \\"street_name\\": \\"{{delivery_contact.street_name}}\\",\\n \\"street_number\\": \\"{{delivery_contact.street_number}}\\",\\n \\"city\\": \\"{{delivery_contact.city}}\\",\\n \\"postal_code\\": \\"{{delivery_contact.postal_code}}\\",\\n \\"country\\": \\"{{delivery_contact.country}}\\",\\n}"}]}}}}]}}}}}}}}}}},"components":{"securitySchemes":{"EpilotAuth":{"type":"http","scheme":"bearer","description":"Epilot Bearer Token"},"AsOrganization":{"type":"apiKey","in":"header","name":"x-ivy-org-id","description":"Set organization id when using internal auth"}},"schemas":{"AutomationWorkflowId":{"type":"string","example":"7791b04a-16d2-44a2-9af9-2d59c25c512f"},"AutomationActionId":{"type":"string","example":"9ec3711b-db63-449c-b894-54d5bb622a8f"},"AutomationWorkflow":{"type":"object","properties":{"id":{"type":"string","example":"7791b04a-16d2-44a2-9af9-2d59c25c512f"},"definition_name":{"type":"string","example":"Handle contact form"},"triggers":{"type":"array","items":{"type":"object","properties":{"on":{"type":"string","enum":["entity_create","entity_update","entity_delete","journey_submit","frontend_submit"]},"config":{"type":"object","additionalProperties":true,"example":{"entity_schema":"contact"}}},"required":["on","config"],"example":{"on":"journey_submit","config":{"journey_id":"53c5d0bb-4ee7-4ed6-b3e0-0262383fd4b9"}}}},"schemas":{"type":"array","description":"schemas this automation is available for","items":{"type":"string","example":"submission"}},"actions":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","example":"9ec3711b-db63-449c-b894-54d5bb622a8f"},"name":{"type":"string","example":"Create Contact"},"type":{"type":"string","example":"entity_mapping"},"config":{"type":"object","additionalProperties":true,"example":{"mapping_attributes":[{"target":"email","mode":"upsert_match","source":"billing_contact.email"},{"target":"first_name","mode":"copy_if_exists","source":"billing_contact.first_name"},{"target":"last_name","mode":"copy_if_exists","source":"billing_contact.last_name"},{"target":"addresses","mode":"append_if_exists","source":"billing_contact","value_json":"{\\n \\"street_name\\": \\"{{billing_contact.street_name}}\\",\\n \\"street_number\\": \\"{{billing_contact.street_number}}\\",\\n \\"city\\": \\"{{billing_contact.city}}\\",\\n \\"postal_code\\": \\"{{billing_contact.postal_code}}\\",\\n \\"country\\": \\"{{billing_contact.country}}\\",\\n}"},{"target":"addresses","mode":"append_if_exists","source":"delivery_contact","value_json":"{\\n \\"street_name\\": \\"{{delivery_contact.street_name}}\\",\\n \\"street_number\\": \\"{{delivery_contact.street_number}}\\",\\n \\"city\\": \\"{{delivery_contact.city}}\\",\\n \\"postal_code\\": \\"{{delivery_contact.postal_code}}\\",\\n \\"country\\": \\"{{delivery_contact.country}}\\",\\n}"}]}}}}},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"}}},"AutomationAction":{"type":"object","properties":{"id":{"type":"string","example":"9ec3711b-db63-449c-b894-54d5bb622a8f"},"name":{"type":"string","example":"Create Contact"},"type":{"type":"string","example":"entity_mapping"},"config":{"type":"object","additionalProperties":true,"example":{"mapping_attributes":[{"target":"email","mode":"upsert_match","source":"billing_contact.email"},{"target":"first_name","mode":"copy_if_exists","source":"billing_contact.first_name"},{"target":"last_name","mode":"copy_if_exists","source":"billing_contact.last_name"},{"target":"addresses","mode":"append_if_exists","source":"billing_contact","value_json":"{\\n \\"street_name\\": \\"{{billing_contact.street_name}}\\",\\n \\"street_number\\": \\"{{billing_contact.street_number}}\\",\\n \\"city\\": \\"{{billing_contact.city}}\\",\\n \\"postal_code\\": \\"{{billing_contact.postal_code}}\\",\\n \\"country\\": \\"{{billing_contact.country}}\\",\\n}"},{"target":"addresses","mode":"append_if_exists","source":"delivery_contact","value_json":"{\\n \\"street_name\\": \\"{{delivery_contact.street_name}}\\",\\n \\"street_number\\": \\"{{delivery_contact.street_number}}\\",\\n \\"city\\": \\"{{delivery_contact.city}}\\",\\n \\"postal_code\\": \\"{{delivery_contact.postal_code}}\\",\\n \\"country\\": \\"{{delivery_contact.country}}\\",\\n}"}]}}}},"AutomationExecutionId":{"type":"string","example":"9baf184f-bc81-4128-bca3-d974c90a12c4"},"AutomationExecution":{"type":"object","properties":{"id":{"type":"string","example":"9baf184f-bc81-4128-bca3-d974c90a12c4"},"status":{"type":"string","enum":["pending","in_progress","success","failed","cancelled"],"example":"success"},"entity_id":{"type":"string","example":"e3d3ebac-baab-4395-abf4-50b5bf1f8b74"},"definition_id":{"type":"string","example":"7791b04a-16d2-44a2-9af9-2d59c25c512f"},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"current_action":{"type":"string","example":"9ec3711b-db63-449c-b894-54d5bb622a8f"},"actions":{"type":"array","items":{"allOf":[{"type":"object","properties":{"status":{"type":"string","enum":["pending","in_progress","success","failed"]}}},{"type":"object","properties":{"id":{"type":"string","example":"9ec3711b-db63-449c-b894-54d5bb622a8f"},"name":{"type":"string","example":"Create Contact"},"type":{"type":"string","example":"entity_mapping"},"config":{"type":"object","additionalProperties":true,"example":{"mapping_attributes":[{"target":"email","mode":"upsert_match","source":"billing_contact.email"},{"target":"first_name","mode":"copy_if_exists","source":"billing_contact.first_name"},{"target":"last_name","mode":"copy_if_exists","source":"billing_contact.last_name"},{"target":"addresses","mode":"append_if_exists","source":"billing_contact","value_json":"{\\n \\"street_name\\": \\"{{billing_contact.street_name}}\\",\\n \\"street_number\\": \\"{{billing_contact.street_number}}\\",\\n \\"city\\": \\"{{billing_contact.city}}\\",\\n \\"postal_code\\": \\"{{billing_contact.postal_code}}\\",\\n \\"country\\": \\"{{billing_contact.country}}\\",\\n}"},{"target":"addresses","mode":"append_if_exists","source":"delivery_contact","value_json":"{\\n \\"street_name\\": \\"{{delivery_contact.street_name}}\\",\\n \\"street_number\\": \\"{{delivery_contact.street_number}}\\",\\n \\"city\\": \\"{{delivery_contact.city}}\\",\\n \\"postal_code\\": \\"{{delivery_contact.postal_code}}\\",\\n \\"country\\": \\"{{delivery_contact.country}}\\",\\n}"}]}}}}]}}}},"EntityId":{"type":"string","example":"e3d3ebac-baab-4395-abf4-50b5bf1f8b74"}}}}')}},t={};return function n(i){if(t[i])return t[i].exports;var a=t[i]={exports:{}};return e[i].call(a.exports,a,a.exports,n),a.exports}(914)})());
1
+ !function(e,t){for(var n in t)e[n]=t[n];t.__esModule&&Object.defineProperty(e,"__esModule",{value:!0})}(exports,(()=>{"use strict";var e={914:function(e,t,n){var a=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var i=a(n(279));t.default=i.default},279:e=>{e.exports=JSON.parse('{"openapi":"3.0.3","info":{"title":"Automation API","description":"API Backend for epilot Automation Workflows feature","version":"1.0.0"},"tags":[{"name":"definitions","description":"Automation definitions"},{"name":"executions","description":"Automation executions"}],"security":[{"EpilotAuth":[]},{"AsOrganization":[]}],"paths":{"/v1/automation/definitions":{"get":{"operationId":"searchAutomations","summary":"searchAutomations","description":"Search available automation definitions","tags":["definitions"],"parameters":[{"name":"schema","in":"query","description":"Entity Schema","schema":{"type":"string","example":"submission"}},{"name":"size","in":"query","description":"Pagination: max number of results to return","schema":{"type":"integer","default":25}},{"name":"from","in":"query","description":"Pagination: starting for results","schema":{"type":"integer","default":0}}],"responses":{"200":{"description":"List of automation definitions","content":{"application/json":{"schema":{"type":"object","properties":{"total":{"type":"integer","example":1},"results":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","example":"7791b04a-16d2-44a2-9af9-2d59c25c512f"},"definition_name":{"type":"string","example":"Handle contact form"},"triggers":{"type":"array","items":{"type":"object","properties":{"on":{"type":"string","enum":["entity_create","entity_update","entity_delete","journey_submit","frontend_submit"]},"config":{"type":"object","additionalProperties":true,"example":{"entity_schema":"contact"}}},"required":["on","config"],"example":{"on":"journey_submit","config":{"journey_id":"53c5d0bb-4ee7-4ed6-b3e0-0262383fd4b9"}}}},"schemas":{"type":"array","description":"schemas this automation is available for","items":{"type":"string","example":"submission"}},"actions":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","example":"9ec3711b-db63-449c-b894-54d5bb622a8f"},"name":{"type":"string","example":"Create Contact"},"type":{"type":"string","example":"entity_mapping"},"config":{"type":"object","additionalProperties":true,"example":{"target_schema":"contact","mapping_attributes":[{"target":"email","mode":"upsert_match","source":"billing_contact.email"},{"target":"first_name","mode":"copy_if_exists","source":"billing_contact.first_name"},{"target":"last_name","mode":"copy_if_exists","source":"billing_contact.last_name"},{"target":"addresses","mode":"append_if_exists","source":"billing_contact","value_json":"{\\n \\"street_name\\": \\"{{billing_contact.street_name}}\\",\\n \\"street_number\\": \\"{{billing_contact.street_number}}\\",\\n \\"city\\": \\"{{billing_contact.city}}\\",\\n \\"postal_code\\": \\"{{billing_contact.postal_code}}\\",\\n \\"country\\": \\"{{billing_contact.country}}\\",\\n}"},{"target":"addresses","mode":"append_if_exists","source":"delivery_contact","value_json":"{\\n \\"street_name\\": \\"{{delivery_contact.street_name}}\\",\\n \\"street_number\\": \\"{{delivery_contact.street_number}}\\",\\n \\"city\\": \\"{{delivery_contact.city}}\\",\\n \\"postal_code\\": \\"{{delivery_contact.postal_code}}\\",\\n \\"country\\": \\"{{delivery_contact.country}}\\",\\n}"}]}}}}},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"}}}}}}}}}}},"post":{"operationId":"createAutomation","summary":"createAutomation","description":"Create new automation definition","tags":["definitions"],"requestBody":{"description":"Automation definition to create","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string","example":"7791b04a-16d2-44a2-9af9-2d59c25c512f"},"definition_name":{"type":"string","example":"Handle contact form"},"triggers":{"type":"array","items":{"type":"object","properties":{"on":{"type":"string","enum":["entity_create","entity_update","entity_delete","journey_submit","frontend_submit"]},"config":{"type":"object","additionalProperties":true,"example":{"entity_schema":"contact"}}},"required":["on","config"],"example":{"on":"journey_submit","config":{"journey_id":"53c5d0bb-4ee7-4ed6-b3e0-0262383fd4b9"}}}},"schemas":{"type":"array","description":"schemas this automation is available for","items":{"type":"string","example":"submission"}},"actions":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","example":"9ec3711b-db63-449c-b894-54d5bb622a8f"},"name":{"type":"string","example":"Create Contact"},"type":{"type":"string","example":"entity_mapping"},"config":{"type":"object","additionalProperties":true,"example":{"target_schema":"contact","mapping_attributes":[{"target":"email","mode":"upsert_match","source":"billing_contact.email"},{"target":"first_name","mode":"copy_if_exists","source":"billing_contact.first_name"},{"target":"last_name","mode":"copy_if_exists","source":"billing_contact.last_name"},{"target":"addresses","mode":"append_if_exists","source":"billing_contact","value_json":"{\\n \\"street_name\\": \\"{{billing_contact.street_name}}\\",\\n \\"street_number\\": \\"{{billing_contact.street_number}}\\",\\n \\"city\\": \\"{{billing_contact.city}}\\",\\n \\"postal_code\\": \\"{{billing_contact.postal_code}}\\",\\n \\"country\\": \\"{{billing_contact.country}}\\",\\n}"},{"target":"addresses","mode":"append_if_exists","source":"delivery_contact","value_json":"{\\n \\"street_name\\": \\"{{delivery_contact.street_name}}\\",\\n \\"street_number\\": \\"{{delivery_contact.street_number}}\\",\\n \\"city\\": \\"{{delivery_contact.city}}\\",\\n \\"postal_code\\": \\"{{delivery_contact.postal_code}}\\",\\n \\"country\\": \\"{{delivery_contact.country}}\\",\\n}"}]}}}}},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"}}}}}},"responses":{"201":{"description":"The created automation definition","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string","example":"7791b04a-16d2-44a2-9af9-2d59c25c512f"},"definition_name":{"type":"string","example":"Handle contact form"},"triggers":{"type":"array","items":{"type":"object","properties":{"on":{"type":"string","enum":["entity_create","entity_update","entity_delete","journey_submit","frontend_submit"]},"config":{"type":"object","additionalProperties":true,"example":{"entity_schema":"contact"}}},"required":["on","config"],"example":{"on":"journey_submit","config":{"journey_id":"53c5d0bb-4ee7-4ed6-b3e0-0262383fd4b9"}}}},"schemas":{"type":"array","description":"schemas this automation is available for","items":{"type":"string","example":"submission"}},"actions":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","example":"9ec3711b-db63-449c-b894-54d5bb622a8f"},"name":{"type":"string","example":"Create Contact"},"type":{"type":"string","example":"entity_mapping"},"config":{"type":"object","additionalProperties":true,"example":{"target_schema":"contact","mapping_attributes":[{"target":"email","mode":"upsert_match","source":"billing_contact.email"},{"target":"first_name","mode":"copy_if_exists","source":"billing_contact.first_name"},{"target":"last_name","mode":"copy_if_exists","source":"billing_contact.last_name"},{"target":"addresses","mode":"append_if_exists","source":"billing_contact","value_json":"{\\n \\"street_name\\": \\"{{billing_contact.street_name}}\\",\\n \\"street_number\\": \\"{{billing_contact.street_number}}\\",\\n \\"city\\": \\"{{billing_contact.city}}\\",\\n \\"postal_code\\": \\"{{billing_contact.postal_code}}\\",\\n \\"country\\": \\"{{billing_contact.country}}\\",\\n}"},{"target":"addresses","mode":"append_if_exists","source":"delivery_contact","value_json":"{\\n \\"street_name\\": \\"{{delivery_contact.street_name}}\\",\\n \\"street_number\\": \\"{{delivery_contact.street_number}}\\",\\n \\"city\\": \\"{{delivery_contact.city}}\\",\\n \\"postal_code\\": \\"{{delivery_contact.postal_code}}\\",\\n \\"country\\": \\"{{delivery_contact.country}}\\",\\n}"}]}}}}},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"}}}}}}}}},"/v1/automation/definitions/{definition_id}":{"get":{"operationId":"getAutomation","summary":"getAutomation","description":"List available automation definitions","tags":["definitions"],"parameters":[{"name":"definition_id","in":"path","required":true,"description":"Automation Workflow ID","schema":{"type":"string","example":"7791b04a-16d2-44a2-9af9-2d59c25c512f"}}],"responses":{"200":{"description":"The returned automation definition","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string","example":"7791b04a-16d2-44a2-9af9-2d59c25c512f"},"definition_name":{"type":"string","example":"Handle contact form"},"triggers":{"type":"array","items":{"type":"object","properties":{"on":{"type":"string","enum":["entity_create","entity_update","entity_delete","journey_submit","frontend_submit"]},"config":{"type":"object","additionalProperties":true,"example":{"entity_schema":"contact"}}},"required":["on","config"],"example":{"on":"journey_submit","config":{"journey_id":"53c5d0bb-4ee7-4ed6-b3e0-0262383fd4b9"}}}},"schemas":{"type":"array","description":"schemas this automation is available for","items":{"type":"string","example":"submission"}},"actions":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","example":"9ec3711b-db63-449c-b894-54d5bb622a8f"},"name":{"type":"string","example":"Create Contact"},"type":{"type":"string","example":"entity_mapping"},"config":{"type":"object","additionalProperties":true,"example":{"target_schema":"contact","mapping_attributes":[{"target":"email","mode":"upsert_match","source":"billing_contact.email"},{"target":"first_name","mode":"copy_if_exists","source":"billing_contact.first_name"},{"target":"last_name","mode":"copy_if_exists","source":"billing_contact.last_name"},{"target":"addresses","mode":"append_if_exists","source":"billing_contact","value_json":"{\\n \\"street_name\\": \\"{{billing_contact.street_name}}\\",\\n \\"street_number\\": \\"{{billing_contact.street_number}}\\",\\n \\"city\\": \\"{{billing_contact.city}}\\",\\n \\"postal_code\\": \\"{{billing_contact.postal_code}}\\",\\n \\"country\\": \\"{{billing_contact.country}}\\",\\n}"},{"target":"addresses","mode":"append_if_exists","source":"delivery_contact","value_json":"{\\n \\"street_name\\": \\"{{delivery_contact.street_name}}\\",\\n \\"street_number\\": \\"{{delivery_contact.street_number}}\\",\\n \\"city\\": \\"{{delivery_contact.city}}\\",\\n \\"postal_code\\": \\"{{delivery_contact.postal_code}}\\",\\n \\"country\\": \\"{{delivery_contact.country}}\\",\\n}"}]}}}}},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"}}}}}}}},"put":{"operationId":"putAutomation","summary":"putAutomation","description":"Update automation definition by id","tags":["definitions"],"parameters":[{"name":"definition_id","in":"path","required":true,"description":"Automation Workflow ID","schema":{"type":"string","example":"7791b04a-16d2-44a2-9af9-2d59c25c512f"}}],"requestBody":{"description":"Automation definition to create","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string","example":"7791b04a-16d2-44a2-9af9-2d59c25c512f"},"definition_name":{"type":"string","example":"Handle contact form"},"triggers":{"type":"array","items":{"type":"object","properties":{"on":{"type":"string","enum":["entity_create","entity_update","entity_delete","journey_submit","frontend_submit"]},"config":{"type":"object","additionalProperties":true,"example":{"entity_schema":"contact"}}},"required":["on","config"],"example":{"on":"journey_submit","config":{"journey_id":"53c5d0bb-4ee7-4ed6-b3e0-0262383fd4b9"}}}},"schemas":{"type":"array","description":"schemas this automation is available for","items":{"type":"string","example":"submission"}},"actions":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","example":"9ec3711b-db63-449c-b894-54d5bb622a8f"},"name":{"type":"string","example":"Create Contact"},"type":{"type":"string","example":"entity_mapping"},"config":{"type":"object","additionalProperties":true,"example":{"target_schema":"contact","mapping_attributes":[{"target":"email","mode":"upsert_match","source":"billing_contact.email"},{"target":"first_name","mode":"copy_if_exists","source":"billing_contact.first_name"},{"target":"last_name","mode":"copy_if_exists","source":"billing_contact.last_name"},{"target":"addresses","mode":"append_if_exists","source":"billing_contact","value_json":"{\\n \\"street_name\\": \\"{{billing_contact.street_name}}\\",\\n \\"street_number\\": \\"{{billing_contact.street_number}}\\",\\n \\"city\\": \\"{{billing_contact.city}}\\",\\n \\"postal_code\\": \\"{{billing_contact.postal_code}}\\",\\n \\"country\\": \\"{{billing_contact.country}}\\",\\n}"},{"target":"addresses","mode":"append_if_exists","source":"delivery_contact","value_json":"{\\n \\"street_name\\": \\"{{delivery_contact.street_name}}\\",\\n \\"street_number\\": \\"{{delivery_contact.street_number}}\\",\\n \\"city\\": \\"{{delivery_contact.city}}\\",\\n \\"postal_code\\": \\"{{delivery_contact.postal_code}}\\",\\n \\"country\\": \\"{{delivery_contact.country}}\\",\\n}"}]}}}}},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"}}}}}},"responses":{"201":{"description":"The updated automation definition","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string","example":"7791b04a-16d2-44a2-9af9-2d59c25c512f"},"definition_name":{"type":"string","example":"Handle contact form"},"triggers":{"type":"array","items":{"type":"object","properties":{"on":{"type":"string","enum":["entity_create","entity_update","entity_delete","journey_submit","frontend_submit"]},"config":{"type":"object","additionalProperties":true,"example":{"entity_schema":"contact"}}},"required":["on","config"],"example":{"on":"journey_submit","config":{"journey_id":"53c5d0bb-4ee7-4ed6-b3e0-0262383fd4b9"}}}},"schemas":{"type":"array","description":"schemas this automation is available for","items":{"type":"string","example":"submission"}},"actions":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","example":"9ec3711b-db63-449c-b894-54d5bb622a8f"},"name":{"type":"string","example":"Create Contact"},"type":{"type":"string","example":"entity_mapping"},"config":{"type":"object","additionalProperties":true,"example":{"target_schema":"contact","mapping_attributes":[{"target":"email","mode":"upsert_match","source":"billing_contact.email"},{"target":"first_name","mode":"copy_if_exists","source":"billing_contact.first_name"},{"target":"last_name","mode":"copy_if_exists","source":"billing_contact.last_name"},{"target":"addresses","mode":"append_if_exists","source":"billing_contact","value_json":"{\\n \\"street_name\\": \\"{{billing_contact.street_name}}\\",\\n \\"street_number\\": \\"{{billing_contact.street_number}}\\",\\n \\"city\\": \\"{{billing_contact.city}}\\",\\n \\"postal_code\\": \\"{{billing_contact.postal_code}}\\",\\n \\"country\\": \\"{{billing_contact.country}}\\",\\n}"},{"target":"addresses","mode":"append_if_exists","source":"delivery_contact","value_json":"{\\n \\"street_name\\": \\"{{delivery_contact.street_name}}\\",\\n \\"street_number\\": \\"{{delivery_contact.street_number}}\\",\\n \\"city\\": \\"{{delivery_contact.city}}\\",\\n \\"postal_code\\": \\"{{delivery_contact.postal_code}}\\",\\n \\"country\\": \\"{{delivery_contact.country}}\\",\\n}"}]}}}}},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"}}}}}}}},"delete":{"operationId":"deleteAutomation","summary":"deleteAutomation","description":"Update automation definition by id","tags":["definitions"],"parameters":[{"name":"definition_id","in":"path","required":true,"description":"Automation Workflow ID","schema":{"type":"string","example":"7791b04a-16d2-44a2-9af9-2d59c25c512f"}}],"responses":{"200":{"description":"The deleted automation definition","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string","example":"7791b04a-16d2-44a2-9af9-2d59c25c512f"},"definition_name":{"type":"string","example":"Handle contact form"},"triggers":{"type":"array","items":{"type":"object","properties":{"on":{"type":"string","enum":["entity_create","entity_update","entity_delete","journey_submit","frontend_submit"]},"config":{"type":"object","additionalProperties":true,"example":{"entity_schema":"contact"}}},"required":["on","config"],"example":{"on":"journey_submit","config":{"journey_id":"53c5d0bb-4ee7-4ed6-b3e0-0262383fd4b9"}}}},"schemas":{"type":"array","description":"schemas this automation is available for","items":{"type":"string","example":"submission"}},"actions":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","example":"9ec3711b-db63-449c-b894-54d5bb622a8f"},"name":{"type":"string","example":"Create Contact"},"type":{"type":"string","example":"entity_mapping"},"config":{"type":"object","additionalProperties":true,"example":{"target_schema":"contact","mapping_attributes":[{"target":"email","mode":"upsert_match","source":"billing_contact.email"},{"target":"first_name","mode":"copy_if_exists","source":"billing_contact.first_name"},{"target":"last_name","mode":"copy_if_exists","source":"billing_contact.last_name"},{"target":"addresses","mode":"append_if_exists","source":"billing_contact","value_json":"{\\n \\"street_name\\": \\"{{billing_contact.street_name}}\\",\\n \\"street_number\\": \\"{{billing_contact.street_number}}\\",\\n \\"city\\": \\"{{billing_contact.city}}\\",\\n \\"postal_code\\": \\"{{billing_contact.postal_code}}\\",\\n \\"country\\": \\"{{billing_contact.country}}\\",\\n}"},{"target":"addresses","mode":"append_if_exists","source":"delivery_contact","value_json":"{\\n \\"street_name\\": \\"{{delivery_contact.street_name}}\\",\\n \\"street_number\\": \\"{{delivery_contact.street_number}}\\",\\n \\"city\\": \\"{{delivery_contact.city}}\\",\\n \\"postal_code\\": \\"{{delivery_contact.postal_code}}\\",\\n \\"country\\": \\"{{delivery_contact.country}}\\",\\n}"}]}}}}},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"}}}}}}}}},"/v1/automation/executions":{"get":{"operationId":"getExecutions","summary":"getExecutions","description":"List automation executions","parameters":[{"name":"entity_id","in":"query","schema":{"type":"string","example":"e3d3ebac-baab-4395-abf4-50b5bf1f8b74"}},{"name":"size","in":"query","description":"Pagination: max number of results to return","schema":{"type":"integer","default":25}},{"name":"from","in":"query","description":"Pagination: starting for results","schema":{"type":"integer","default":0}}],"tags":["executions"],"responses":{"200":{"description":"List of automation executions","content":{"application/json":{"schema":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","example":"9baf184f-bc81-4128-bca3-d974c90a12c4"},"status":{"type":"string","enum":["pending","in_progress","success","failed","cancelled"],"example":"success"},"entity_id":{"type":"string","example":"e3d3ebac-baab-4395-abf4-50b5bf1f8b74"},"definition_id":{"type":"string","example":"7791b04a-16d2-44a2-9af9-2d59c25c512f"},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"current_action":{"type":"string","example":"9ec3711b-db63-449c-b894-54d5bb622a8f"},"actions":{"type":"array","items":{"allOf":[{"type":"object","properties":{"status":{"type":"string","enum":["pending","in_progress","success","failed"]},"outputs":{"type":"object","additionalProperties":true,"example":{"affected_entities":"cbbf0e83-0f37-4a0c-9801-93877ec0b2c2"}}}},{"type":"object","properties":{"id":{"type":"string","example":"9ec3711b-db63-449c-b894-54d5bb622a8f"},"name":{"type":"string","example":"Create Contact"},"type":{"type":"string","example":"entity_mapping"},"config":{"type":"object","additionalProperties":true,"example":{"target_schema":"contact","mapping_attributes":[{"target":"email","mode":"upsert_match","source":"billing_contact.email"},{"target":"first_name","mode":"copy_if_exists","source":"billing_contact.first_name"},{"target":"last_name","mode":"copy_if_exists","source":"billing_contact.last_name"},{"target":"addresses","mode":"append_if_exists","source":"billing_contact","value_json":"{\\n \\"street_name\\": \\"{{billing_contact.street_name}}\\",\\n \\"street_number\\": \\"{{billing_contact.street_number}}\\",\\n \\"city\\": \\"{{billing_contact.city}}\\",\\n \\"postal_code\\": \\"{{billing_contact.postal_code}}\\",\\n \\"country\\": \\"{{billing_contact.country}}\\",\\n}"},{"target":"addresses","mode":"append_if_exists","source":"delivery_contact","value_json":"{\\n \\"street_name\\": \\"{{delivery_contact.street_name}}\\",\\n \\"street_number\\": \\"{{delivery_contact.street_number}}\\",\\n \\"city\\": \\"{{delivery_contact.city}}\\",\\n \\"postal_code\\": \\"{{delivery_contact.postal_code}}\\",\\n \\"country\\": \\"{{delivery_contact.country}}\\",\\n}"}]}}}}]}}}}}}}}}},"post":{"operationId":"startExecution","summary":"startExecution","description":"Start new automation execution","requestBody":{"description":"Execution parameters","content":{"application/json":{"schema":{"type":"object","properties":{"entity_id":{"type":"string","example":"e3d3ebac-baab-4395-abf4-50b5bf1f8b74"},"definition_id":{"type":"string","example":"7791b04a-16d2-44a2-9af9-2d59c25c512f"}}}}}},"tags":["executions"],"responses":{"201":{"description":"The created execution","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string","example":"9baf184f-bc81-4128-bca3-d974c90a12c4"},"status":{"type":"string","enum":["pending","in_progress","success","failed","cancelled"],"example":"success"},"entity_id":{"type":"string","example":"e3d3ebac-baab-4395-abf4-50b5bf1f8b74"},"definition_id":{"type":"string","example":"7791b04a-16d2-44a2-9af9-2d59c25c512f"},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"current_action":{"type":"string","example":"9ec3711b-db63-449c-b894-54d5bb622a8f"},"actions":{"type":"array","items":{"allOf":[{"type":"object","properties":{"status":{"type":"string","enum":["pending","in_progress","success","failed"]},"outputs":{"type":"object","additionalProperties":true,"example":{"affected_entities":"cbbf0e83-0f37-4a0c-9801-93877ec0b2c2"}}}},{"type":"object","properties":{"id":{"type":"string","example":"9ec3711b-db63-449c-b894-54d5bb622a8f"},"name":{"type":"string","example":"Create Contact"},"type":{"type":"string","example":"entity_mapping"},"config":{"type":"object","additionalProperties":true,"example":{"target_schema":"contact","mapping_attributes":[{"target":"email","mode":"upsert_match","source":"billing_contact.email"},{"target":"first_name","mode":"copy_if_exists","source":"billing_contact.first_name"},{"target":"last_name","mode":"copy_if_exists","source":"billing_contact.last_name"},{"target":"addresses","mode":"append_if_exists","source":"billing_contact","value_json":"{\\n \\"street_name\\": \\"{{billing_contact.street_name}}\\",\\n \\"street_number\\": \\"{{billing_contact.street_number}}\\",\\n \\"city\\": \\"{{billing_contact.city}}\\",\\n \\"postal_code\\": \\"{{billing_contact.postal_code}}\\",\\n \\"country\\": \\"{{billing_contact.country}}\\",\\n}"},{"target":"addresses","mode":"append_if_exists","source":"delivery_contact","value_json":"{\\n \\"street_name\\": \\"{{delivery_contact.street_name}}\\",\\n \\"street_number\\": \\"{{delivery_contact.street_number}}\\",\\n \\"city\\": \\"{{delivery_contact.city}}\\",\\n \\"postal_code\\": \\"{{delivery_contact.postal_code}}\\",\\n \\"country\\": \\"{{delivery_contact.country}}\\",\\n}"}]}}}}]}}}}}}}}}},"/v1/automation/executions/{execution_id}":{"get":{"operationId":"getExecution","summary":"getExecution","description":"Get automation execution","parameters":[{"name":"execution_id","in":"path","schema":{"type":"string","example":"9baf184f-bc81-4128-bca3-d974c90a12c4"},"required":true}],"tags":["executions"],"responses":{"200":{"description":"The returned execution","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string","example":"9baf184f-bc81-4128-bca3-d974c90a12c4"},"status":{"type":"string","enum":["pending","in_progress","success","failed","cancelled"],"example":"success"},"entity_id":{"type":"string","example":"e3d3ebac-baab-4395-abf4-50b5bf1f8b74"},"definition_id":{"type":"string","example":"7791b04a-16d2-44a2-9af9-2d59c25c512f"},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"current_action":{"type":"string","example":"9ec3711b-db63-449c-b894-54d5bb622a8f"},"actions":{"type":"array","items":{"allOf":[{"type":"object","properties":{"status":{"type":"string","enum":["pending","in_progress","success","failed"]},"outputs":{"type":"object","additionalProperties":true,"example":{"affected_entities":"cbbf0e83-0f37-4a0c-9801-93877ec0b2c2"}}}},{"type":"object","properties":{"id":{"type":"string","example":"9ec3711b-db63-449c-b894-54d5bb622a8f"},"name":{"type":"string","example":"Create Contact"},"type":{"type":"string","example":"entity_mapping"},"config":{"type":"object","additionalProperties":true,"example":{"target_schema":"contact","mapping_attributes":[{"target":"email","mode":"upsert_match","source":"billing_contact.email"},{"target":"first_name","mode":"copy_if_exists","source":"billing_contact.first_name"},{"target":"last_name","mode":"copy_if_exists","source":"billing_contact.last_name"},{"target":"addresses","mode":"append_if_exists","source":"billing_contact","value_json":"{\\n \\"street_name\\": \\"{{billing_contact.street_name}}\\",\\n \\"street_number\\": \\"{{billing_contact.street_number}}\\",\\n \\"city\\": \\"{{billing_contact.city}}\\",\\n \\"postal_code\\": \\"{{billing_contact.postal_code}}\\",\\n \\"country\\": \\"{{billing_contact.country}}\\",\\n}"},{"target":"addresses","mode":"append_if_exists","source":"delivery_contact","value_json":"{\\n \\"street_name\\": \\"{{delivery_contact.street_name}}\\",\\n \\"street_number\\": \\"{{delivery_contact.street_number}}\\",\\n \\"city\\": \\"{{delivery_contact.city}}\\",\\n \\"postal_code\\": \\"{{delivery_contact.postal_code}}\\",\\n \\"country\\": \\"{{delivery_contact.country}}\\",\\n}"}]}}}}]}}}}}}}}},"delete":{"operationId":"cancelExecution","summary":"cancelExecution","description":"Cancel automation execution","parameters":[{"name":"execution_id","in":"path","schema":{"type":"string","example":"9baf184f-bc81-4128-bca3-d974c90a12c4"},"required":true}],"tags":["executions"],"responses":{"200":{"description":"The cancelled execution","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string","example":"9baf184f-bc81-4128-bca3-d974c90a12c4"},"status":{"type":"string","enum":["pending","in_progress","success","failed","cancelled"],"example":"success"},"entity_id":{"type":"string","example":"e3d3ebac-baab-4395-abf4-50b5bf1f8b74"},"definition_id":{"type":"string","example":"7791b04a-16d2-44a2-9af9-2d59c25c512f"},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"current_action":{"type":"string","example":"9ec3711b-db63-449c-b894-54d5bb622a8f"},"actions":{"type":"array","items":{"allOf":[{"type":"object","properties":{"status":{"type":"string","enum":["pending","in_progress","success","failed"]},"outputs":{"type":"object","additionalProperties":true,"example":{"affected_entities":"cbbf0e83-0f37-4a0c-9801-93877ec0b2c2"}}}},{"type":"object","properties":{"id":{"type":"string","example":"9ec3711b-db63-449c-b894-54d5bb622a8f"},"name":{"type":"string","example":"Create Contact"},"type":{"type":"string","example":"entity_mapping"},"config":{"type":"object","additionalProperties":true,"example":{"target_schema":"contact","mapping_attributes":[{"target":"email","mode":"upsert_match","source":"billing_contact.email"},{"target":"first_name","mode":"copy_if_exists","source":"billing_contact.first_name"},{"target":"last_name","mode":"copy_if_exists","source":"billing_contact.last_name"},{"target":"addresses","mode":"append_if_exists","source":"billing_contact","value_json":"{\\n \\"street_name\\": \\"{{billing_contact.street_name}}\\",\\n \\"street_number\\": \\"{{billing_contact.street_number}}\\",\\n \\"city\\": \\"{{billing_contact.city}}\\",\\n \\"postal_code\\": \\"{{billing_contact.postal_code}}\\",\\n \\"country\\": \\"{{billing_contact.country}}\\",\\n}"},{"target":"addresses","mode":"append_if_exists","source":"delivery_contact","value_json":"{\\n \\"street_name\\": \\"{{delivery_contact.street_name}}\\",\\n \\"street_number\\": \\"{{delivery_contact.street_number}}\\",\\n \\"city\\": \\"{{delivery_contact.city}}\\",\\n \\"postal_code\\": \\"{{delivery_contact.postal_code}}\\",\\n \\"country\\": \\"{{delivery_contact.country}}\\",\\n}"}]}}}}]}}}}}}}}}}},"components":{"securitySchemes":{"EpilotAuth":{"type":"http","scheme":"bearer","description":"Epilot Bearer Token"},"AsOrganization":{"type":"apiKey","in":"header","name":"x-ivy-org-id","description":"Set organization id when using internal auth"}},"schemas":{"AutomationDefinitionId":{"type":"string","example":"7791b04a-16d2-44a2-9af9-2d59c25c512f"},"AutomationActionId":{"type":"string","example":"9ec3711b-db63-449c-b894-54d5bb622a8f"},"AutomationDefinition":{"type":"object","properties":{"id":{"type":"string","example":"7791b04a-16d2-44a2-9af9-2d59c25c512f"},"definition_name":{"type":"string","example":"Handle contact form"},"triggers":{"type":"array","items":{"type":"object","properties":{"on":{"type":"string","enum":["entity_create","entity_update","entity_delete","journey_submit","frontend_submit"]},"config":{"type":"object","additionalProperties":true,"example":{"entity_schema":"contact"}}},"required":["on","config"],"example":{"on":"journey_submit","config":{"journey_id":"53c5d0bb-4ee7-4ed6-b3e0-0262383fd4b9"}}}},"schemas":{"type":"array","description":"schemas this automation is available for","items":{"type":"string","example":"submission"}},"actions":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","example":"9ec3711b-db63-449c-b894-54d5bb622a8f"},"name":{"type":"string","example":"Create Contact"},"type":{"type":"string","example":"entity_mapping"},"config":{"type":"object","additionalProperties":true,"example":{"target_schema":"contact","mapping_attributes":[{"target":"email","mode":"upsert_match","source":"billing_contact.email"},{"target":"first_name","mode":"copy_if_exists","source":"billing_contact.first_name"},{"target":"last_name","mode":"copy_if_exists","source":"billing_contact.last_name"},{"target":"addresses","mode":"append_if_exists","source":"billing_contact","value_json":"{\\n \\"street_name\\": \\"{{billing_contact.street_name}}\\",\\n \\"street_number\\": \\"{{billing_contact.street_number}}\\",\\n \\"city\\": \\"{{billing_contact.city}}\\",\\n \\"postal_code\\": \\"{{billing_contact.postal_code}}\\",\\n \\"country\\": \\"{{billing_contact.country}}\\",\\n}"},{"target":"addresses","mode":"append_if_exists","source":"delivery_contact","value_json":"{\\n \\"street_name\\": \\"{{delivery_contact.street_name}}\\",\\n \\"street_number\\": \\"{{delivery_contact.street_number}}\\",\\n \\"city\\": \\"{{delivery_contact.city}}\\",\\n \\"postal_code\\": \\"{{delivery_contact.postal_code}}\\",\\n \\"country\\": \\"{{delivery_contact.country}}\\",\\n}"}]}}}}},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"}}},"AutomationAction":{"type":"object","properties":{"id":{"type":"string","example":"9ec3711b-db63-449c-b894-54d5bb622a8f"},"name":{"type":"string","example":"Create Contact"},"type":{"type":"string","example":"entity_mapping"},"config":{"type":"object","additionalProperties":true,"example":{"target_schema":"contact","mapping_attributes":[{"target":"email","mode":"upsert_match","source":"billing_contact.email"},{"target":"first_name","mode":"copy_if_exists","source":"billing_contact.first_name"},{"target":"last_name","mode":"copy_if_exists","source":"billing_contact.last_name"},{"target":"addresses","mode":"append_if_exists","source":"billing_contact","value_json":"{\\n \\"street_name\\": \\"{{billing_contact.street_name}}\\",\\n \\"street_number\\": \\"{{billing_contact.street_number}}\\",\\n \\"city\\": \\"{{billing_contact.city}}\\",\\n \\"postal_code\\": \\"{{billing_contact.postal_code}}\\",\\n \\"country\\": \\"{{billing_contact.country}}\\",\\n}"},{"target":"addresses","mode":"append_if_exists","source":"delivery_contact","value_json":"{\\n \\"street_name\\": \\"{{delivery_contact.street_name}}\\",\\n \\"street_number\\": \\"{{delivery_contact.street_number}}\\",\\n \\"city\\": \\"{{delivery_contact.city}}\\",\\n \\"postal_code\\": \\"{{delivery_contact.postal_code}}\\",\\n \\"country\\": \\"{{delivery_contact.country}}\\",\\n}"}]}}}},"AutomationExecutionId":{"type":"string","example":"9baf184f-bc81-4128-bca3-d974c90a12c4"},"AutomationExecution":{"type":"object","properties":{"id":{"type":"string","example":"9baf184f-bc81-4128-bca3-d974c90a12c4"},"status":{"type":"string","enum":["pending","in_progress","success","failed","cancelled"],"example":"success"},"entity_id":{"type":"string","example":"e3d3ebac-baab-4395-abf4-50b5bf1f8b74"},"definition_id":{"type":"string","example":"7791b04a-16d2-44a2-9af9-2d59c25c512f"},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"current_action":{"type":"string","example":"9ec3711b-db63-449c-b894-54d5bb622a8f"},"actions":{"type":"array","items":{"allOf":[{"type":"object","properties":{"status":{"type":"string","enum":["pending","in_progress","success","failed"]},"outputs":{"type":"object","additionalProperties":true,"example":{"affected_entities":"cbbf0e83-0f37-4a0c-9801-93877ec0b2c2"}}}},{"type":"object","properties":{"id":{"type":"string","example":"9ec3711b-db63-449c-b894-54d5bb622a8f"},"name":{"type":"string","example":"Create Contact"},"type":{"type":"string","example":"entity_mapping"},"config":{"type":"object","additionalProperties":true,"example":{"target_schema":"contact","mapping_attributes":[{"target":"email","mode":"upsert_match","source":"billing_contact.email"},{"target":"first_name","mode":"copy_if_exists","source":"billing_contact.first_name"},{"target":"last_name","mode":"copy_if_exists","source":"billing_contact.last_name"},{"target":"addresses","mode":"append_if_exists","source":"billing_contact","value_json":"{\\n \\"street_name\\": \\"{{billing_contact.street_name}}\\",\\n \\"street_number\\": \\"{{billing_contact.street_number}}\\",\\n \\"city\\": \\"{{billing_contact.city}}\\",\\n \\"postal_code\\": \\"{{billing_contact.postal_code}}\\",\\n \\"country\\": \\"{{billing_contact.country}}\\",\\n}"},{"target":"addresses","mode":"append_if_exists","source":"delivery_contact","value_json":"{\\n \\"street_name\\": \\"{{delivery_contact.street_name}}\\",\\n \\"street_number\\": \\"{{delivery_contact.street_number}}\\",\\n \\"city\\": \\"{{delivery_contact.city}}\\",\\n \\"postal_code\\": \\"{{delivery_contact.postal_code}}\\",\\n \\"country\\": \\"{{delivery_contact.country}}\\",\\n}"}]}}}}]}}}},"EntityId":{"type":"string","example":"e3d3ebac-baab-4395-abf4-50b5bf1f8b74"}}}}')}},t={};return function n(a){if(t[a])return t[a].exports;var i=t[a]={exports:{}};return e[a].call(i.exports,i,i.exports,n),i.exports}(914)})());
package/dist/openapi.d.ts CHANGED
@@ -24,6 +24,7 @@ declare namespace Components {
24
24
  /**
25
25
  * example:
26
26
  * {
27
+ * "target_schema": "contact",
27
28
  * "mapping_attributes": [
28
29
  * {
29
30
  * "target": "email",
@@ -64,6 +65,38 @@ declare namespace Components {
64
65
  * 9ec3711b-db63-449c-b894-54d5bb622a8f
65
66
  */
66
67
  export type AutomationActionId = string;
68
+ export interface AutomationDefinition {
69
+ id?: AutomationDefinitionId;
70
+ /**
71
+ * example:
72
+ * Handle contact form
73
+ */
74
+ definition_name?: string;
75
+ triggers?: {
76
+ on: "entity_create" | "entity_update" | "entity_delete" | "journey_submit" | "frontend_submit";
77
+ /**
78
+ * example:
79
+ * {
80
+ * "entity_schema": "contact"
81
+ * }
82
+ */
83
+ config: {
84
+ [name: string]: any;
85
+ };
86
+ }[];
87
+ /**
88
+ * schemas this automation is available for
89
+ */
90
+ schemas?: string[];
91
+ actions?: AutomationAction[];
92
+ created_at?: string; // date-time
93
+ updated_at?: string; // date-time
94
+ }
95
+ /**
96
+ * example:
97
+ * 7791b04a-16d2-44a2-9af9-2d59c25c512f
98
+ */
99
+ export type AutomationDefinitionId = string;
67
100
  export interface AutomationExecution {
68
101
  id?: AutomationExecutionId;
69
102
  /**
@@ -72,12 +105,21 @@ declare namespace Components {
72
105
  */
73
106
  status?: "pending" | "in_progress" | "success" | "failed" | "cancelled";
74
107
  entity_id?: EntityId;
75
- definition_id?: AutomationWorkflowId;
108
+ definition_id?: AutomationDefinitionId;
76
109
  created_at?: string; // date-time
77
110
  updated_at?: string; // date-time
78
111
  current_action?: AutomationActionId;
79
112
  actions?: {
80
113
  status?: "pending" | "in_progress" | "success" | "failed";
114
+ /**
115
+ * example:
116
+ * {
117
+ * "affected_entities": "cbbf0e83-0f37-4a0c-9801-93877ec0b2c2"
118
+ * }
119
+ */
120
+ outputs?: {
121
+ [name: string]: any;
122
+ };
81
123
  id?: AutomationActionId;
82
124
  /**
83
125
  * example:
@@ -92,6 +134,7 @@ declare namespace Components {
92
134
  /**
93
135
  * example:
94
136
  * {
137
+ * "target_schema": "contact",
95
138
  * "mapping_attributes": [
96
139
  * {
97
140
  * "target": "email",
@@ -133,38 +176,6 @@ declare namespace Components {
133
176
  * 9baf184f-bc81-4128-bca3-d974c90a12c4
134
177
  */
135
178
  export type AutomationExecutionId = string;
136
- export interface AutomationWorkflow {
137
- id?: AutomationWorkflowId;
138
- /**
139
- * example:
140
- * Handle contact form
141
- */
142
- definition_name?: string;
143
- triggers?: {
144
- on: "entity_create" | "entity_update" | "entity_delete" | "journey_submit" | "frontend_submit";
145
- /**
146
- * example:
147
- * {
148
- * "entity_schema": "contact"
149
- * }
150
- */
151
- config: {
152
- [name: string]: any;
153
- };
154
- }[];
155
- /**
156
- * schemas this automation is available for
157
- */
158
- schemas?: string[];
159
- actions?: AutomationAction[];
160
- created_at?: string; // date-time
161
- updated_at?: string; // date-time
162
- }
163
- /**
164
- * example:
165
- * 7791b04a-16d2-44a2-9af9-2d59c25c512f
166
- */
167
- export type AutomationWorkflowId = string;
168
179
  /**
169
180
  * example:
170
181
  * e3d3ebac-baab-4395-abf4-50b5bf1f8b74
@@ -185,31 +196,31 @@ declare namespace Paths {
185
196
  }
186
197
  }
187
198
  namespace CreateAutomation {
188
- export type RequestBody = Components.Schemas.AutomationWorkflow;
199
+ export type RequestBody = Components.Schemas.AutomationDefinition;
189
200
  namespace Responses {
190
- export type $201 = Components.Schemas.AutomationWorkflow;
201
+ export type $201 = Components.Schemas.AutomationDefinition;
191
202
  }
192
203
  }
193
204
  namespace DeleteAutomation {
194
205
  namespace Parameters {
195
- export type DefinitionId = Components.Schemas.AutomationWorkflowId;
206
+ export type DefinitionId = Components.Schemas.AutomationDefinitionId;
196
207
  }
197
208
  export interface PathParameters {
198
209
  definition_id: Parameters.DefinitionId;
199
210
  }
200
211
  namespace Responses {
201
- export type $200 = Components.Schemas.AutomationWorkflow;
212
+ export type $200 = Components.Schemas.AutomationDefinition;
202
213
  }
203
214
  }
204
215
  namespace GetAutomation {
205
216
  namespace Parameters {
206
- export type DefinitionId = Components.Schemas.AutomationWorkflowId;
217
+ export type DefinitionId = Components.Schemas.AutomationDefinitionId;
207
218
  }
208
219
  export interface PathParameters {
209
220
  definition_id: Parameters.DefinitionId;
210
221
  }
211
222
  namespace Responses {
212
- export type $200 = Components.Schemas.AutomationWorkflow;
223
+ export type $200 = Components.Schemas.AutomationDefinition;
213
224
  }
214
225
  }
215
226
  namespace GetExecution {
@@ -240,14 +251,14 @@ declare namespace Paths {
240
251
  }
241
252
  namespace PutAutomation {
242
253
  namespace Parameters {
243
- export type DefinitionId = Components.Schemas.AutomationWorkflowId;
254
+ export type DefinitionId = Components.Schemas.AutomationDefinitionId;
244
255
  }
245
256
  export interface PathParameters {
246
257
  definition_id: Parameters.DefinitionId;
247
258
  }
248
- export type RequestBody = Components.Schemas.AutomationWorkflow;
259
+ export type RequestBody = Components.Schemas.AutomationDefinition;
249
260
  namespace Responses {
250
- export type $201 = Components.Schemas.AutomationWorkflow;
261
+ export type $201 = Components.Schemas.AutomationDefinition;
251
262
  }
252
263
  }
253
264
  namespace SearchAutomations {
@@ -272,14 +283,14 @@ declare namespace Paths {
272
283
  * 1
273
284
  */
274
285
  total?: number;
275
- results?: Components.Schemas.AutomationWorkflow[];
286
+ results?: Components.Schemas.AutomationDefinition[];
276
287
  }
277
288
  }
278
289
  }
279
290
  namespace StartExecution {
280
291
  export interface RequestBody {
281
292
  entity_id?: Components.Schemas.EntityId;
282
- definition_id?: Components.Schemas.AutomationWorkflowId;
293
+ definition_id?: Components.Schemas.AutomationDefinitionId;
283
294
  }
284
295
  namespace Responses {
285
296
  export type $201 = Components.Schemas.AutomationExecution;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@epilot/automation-client",
3
- "version": "0.1.1",
3
+ "version": "0.2.0",
4
4
  "description": "API Client for epilot automation API",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
package/src/openapi.d.ts DELETED
@@ -1,484 +0,0 @@
1
- /* eslint-disable */
2
- import {
3
- OpenAPIClient,
4
- Parameters,
5
- UnknownParamsObject,
6
- OperationResponse,
7
- AxiosRequestConfig,
8
- } from 'openapi-client-axios';
9
-
10
- declare namespace Components {
11
- namespace Schemas {
12
- export interface AutomationAction {
13
- id?: AutomationActionId;
14
- /**
15
- * example:
16
- * Create Contact
17
- */
18
- name?: string;
19
- /**
20
- * example:
21
- * entity_mapping
22
- */
23
- type?: string;
24
- /**
25
- * example:
26
- * {
27
- * "mapping_attributes": [
28
- * {
29
- * "target": "email",
30
- * "mode": "upsert_match",
31
- * "source": "billing_contact.email"
32
- * },
33
- * {
34
- * "target": "first_name",
35
- * "mode": "copy_if_exists",
36
- * "source": "billing_contact.first_name"
37
- * },
38
- * {
39
- * "target": "last_name",
40
- * "mode": "copy_if_exists",
41
- * "source": "billing_contact.last_name"
42
- * },
43
- * {
44
- * "target": "addresses",
45
- * "mode": "append_if_exists",
46
- * "source": "billing_contact",
47
- * "value_json": "{\n \"street_name\": \"{{billing_contact.street_name}}\",\n \"street_number\": \"{{billing_contact.street_number}}\",\n \"city\": \"{{billing_contact.city}}\",\n \"postal_code\": \"{{billing_contact.postal_code}}\",\n \"country\": \"{{billing_contact.country}}\",\n}"
48
- * },
49
- * {
50
- * "target": "addresses",
51
- * "mode": "append_if_exists",
52
- * "source": "delivery_contact",
53
- * "value_json": "{\n \"street_name\": \"{{delivery_contact.street_name}}\",\n \"street_number\": \"{{delivery_contact.street_number}}\",\n \"city\": \"{{delivery_contact.city}}\",\n \"postal_code\": \"{{delivery_contact.postal_code}}\",\n \"country\": \"{{delivery_contact.country}}\",\n}"
54
- * }
55
- * ]
56
- * }
57
- */
58
- config?: {
59
- [name: string]: any;
60
- };
61
- }
62
- /**
63
- * example:
64
- * 9ec3711b-db63-449c-b894-54d5bb622a8f
65
- */
66
- export type AutomationActionId = string;
67
- export interface AutomationExecution {
68
- id?: AutomationExecutionId;
69
- /**
70
- * example:
71
- * success
72
- */
73
- status?: "pending" | "in_progress" | "success" | "failed" | "cancelled";
74
- entity_id?: EntityId;
75
- definition_id?: AutomationWorkflowId;
76
- created_at?: string; // date-time
77
- updated_at?: string; // date-time
78
- current_action?: AutomationActionId;
79
- actions?: {
80
- status?: "pending" | "in_progress" | "success" | "failed";
81
- id?: AutomationActionId;
82
- /**
83
- * example:
84
- * Create Contact
85
- */
86
- name?: string;
87
- /**
88
- * example:
89
- * entity_mapping
90
- */
91
- type?: string;
92
- /**
93
- * example:
94
- * {
95
- * "mapping_attributes": [
96
- * {
97
- * "target": "email",
98
- * "mode": "upsert_match",
99
- * "source": "billing_contact.email"
100
- * },
101
- * {
102
- * "target": "first_name",
103
- * "mode": "copy_if_exists",
104
- * "source": "billing_contact.first_name"
105
- * },
106
- * {
107
- * "target": "last_name",
108
- * "mode": "copy_if_exists",
109
- * "source": "billing_contact.last_name"
110
- * },
111
- * {
112
- * "target": "addresses",
113
- * "mode": "append_if_exists",
114
- * "source": "billing_contact",
115
- * "value_json": "{\n \"street_name\": \"{{billing_contact.street_name}}\",\n \"street_number\": \"{{billing_contact.street_number}}\",\n \"city\": \"{{billing_contact.city}}\",\n \"postal_code\": \"{{billing_contact.postal_code}}\",\n \"country\": \"{{billing_contact.country}}\",\n}"
116
- * },
117
- * {
118
- * "target": "addresses",
119
- * "mode": "append_if_exists",
120
- * "source": "delivery_contact",
121
- * "value_json": "{\n \"street_name\": \"{{delivery_contact.street_name}}\",\n \"street_number\": \"{{delivery_contact.street_number}}\",\n \"city\": \"{{delivery_contact.city}}\",\n \"postal_code\": \"{{delivery_contact.postal_code}}\",\n \"country\": \"{{delivery_contact.country}}\",\n}"
122
- * }
123
- * ]
124
- * }
125
- */
126
- config?: {
127
- [name: string]: any;
128
- };
129
- }[];
130
- }
131
- /**
132
- * example:
133
- * 9baf184f-bc81-4128-bca3-d974c90a12c4
134
- */
135
- export type AutomationExecutionId = string;
136
- export interface AutomationWorkflow {
137
- id?: AutomationWorkflowId;
138
- /**
139
- * example:
140
- * Handle contact form
141
- */
142
- definition_name?: string;
143
- triggers?: {
144
- on: "entity_create" | "entity_update" | "entity_delete" | "journey_submit" | "frontend_submit";
145
- /**
146
- * example:
147
- * {
148
- * "entity_schema": "contact"
149
- * }
150
- */
151
- config: {
152
- [name: string]: any;
153
- };
154
- }[];
155
- /**
156
- * schemas this automation is available for
157
- */
158
- schemas?: string[];
159
- actions?: AutomationAction[];
160
- created_at?: string; // date-time
161
- updated_at?: string; // date-time
162
- }
163
- /**
164
- * example:
165
- * 7791b04a-16d2-44a2-9af9-2d59c25c512f
166
- */
167
- export type AutomationWorkflowId = string;
168
- /**
169
- * example:
170
- * e3d3ebac-baab-4395-abf4-50b5bf1f8b74
171
- */
172
- export type EntityId = string;
173
- }
174
- }
175
- declare namespace Paths {
176
- namespace CancelExecution {
177
- namespace Parameters {
178
- export type ExecutionId = Components.Schemas.AutomationExecutionId;
179
- }
180
- export interface PathParameters {
181
- execution_id: Parameters.ExecutionId;
182
- }
183
- namespace Responses {
184
- export type $200 = Components.Schemas.AutomationExecution;
185
- }
186
- }
187
- namespace CreateAutomation {
188
- export type RequestBody = Components.Schemas.AutomationWorkflow;
189
- namespace Responses {
190
- export type $201 = Components.Schemas.AutomationWorkflow;
191
- }
192
- }
193
- namespace DeleteAutomation {
194
- namespace Parameters {
195
- export type DefinitionId = Components.Schemas.AutomationWorkflowId;
196
- }
197
- export interface PathParameters {
198
- definition_id: Parameters.DefinitionId;
199
- }
200
- namespace Responses {
201
- export type $200 = Components.Schemas.AutomationWorkflow;
202
- }
203
- }
204
- namespace GetAutomation {
205
- namespace Parameters {
206
- export type DefinitionId = Components.Schemas.AutomationWorkflowId;
207
- }
208
- export interface PathParameters {
209
- definition_id: Parameters.DefinitionId;
210
- }
211
- namespace Responses {
212
- export type $200 = Components.Schemas.AutomationWorkflow;
213
- }
214
- }
215
- namespace GetExecution {
216
- namespace Parameters {
217
- export type ExecutionId = Components.Schemas.AutomationExecutionId;
218
- }
219
- export interface PathParameters {
220
- execution_id: Parameters.ExecutionId;
221
- }
222
- namespace Responses {
223
- export type $200 = Components.Schemas.AutomationExecution;
224
- }
225
- }
226
- namespace GetExecutions {
227
- namespace Parameters {
228
- export type EntityId = Components.Schemas.EntityId;
229
- export type From = number;
230
- export type Size = number;
231
- }
232
- export interface QueryParameters {
233
- entity_id?: Parameters.EntityId;
234
- size?: Parameters.Size;
235
- from?: Parameters.From;
236
- }
237
- namespace Responses {
238
- export type $200 = Components.Schemas.AutomationExecution[];
239
- }
240
- }
241
- namespace PutAutomation {
242
- namespace Parameters {
243
- export type DefinitionId = Components.Schemas.AutomationWorkflowId;
244
- }
245
- export interface PathParameters {
246
- definition_id: Parameters.DefinitionId;
247
- }
248
- export type RequestBody = Components.Schemas.AutomationWorkflow;
249
- namespace Responses {
250
- export type $201 = Components.Schemas.AutomationWorkflow;
251
- }
252
- }
253
- namespace SearchAutomations {
254
- namespace Parameters {
255
- export type From = number;
256
- /**
257
- * example:
258
- * submission
259
- */
260
- export type Schema = string;
261
- export type Size = number;
262
- }
263
- export interface QueryParameters {
264
- schema?: Parameters.Schema;
265
- size?: Parameters.Size;
266
- from?: Parameters.From;
267
- }
268
- namespace Responses {
269
- export interface $200 {
270
- /**
271
- * example:
272
- * 1
273
- */
274
- total?: number;
275
- results?: Components.Schemas.AutomationWorkflow[];
276
- }
277
- }
278
- }
279
- namespace StartExecution {
280
- export interface RequestBody {
281
- entity_id?: Components.Schemas.EntityId;
282
- definition_id?: Components.Schemas.AutomationWorkflowId;
283
- }
284
- namespace Responses {
285
- export type $201 = Components.Schemas.AutomationExecution;
286
- }
287
- }
288
- }
289
-
290
- export interface OperationMethods {
291
- /**
292
- * searchAutomations - searchAutomations
293
- *
294
- * Search available automation definitions
295
- */
296
- 'searchAutomations'(
297
- parameters?: Parameters<Paths.SearchAutomations.QueryParameters> | null,
298
- data?: any,
299
- config?: AxiosRequestConfig
300
- ): OperationResponse<Paths.SearchAutomations.Responses.$200>
301
- /**
302
- * createAutomation - createAutomation
303
- *
304
- * Create new automation definition
305
- */
306
- 'createAutomation'(
307
- parameters?: Parameters<UnknownParamsObject> | null,
308
- data?: Paths.CreateAutomation.RequestBody,
309
- config?: AxiosRequestConfig
310
- ): OperationResponse<Paths.CreateAutomation.Responses.$201>
311
- /**
312
- * getAutomation - getAutomation
313
- *
314
- * List available automation definitions
315
- */
316
- 'getAutomation'(
317
- parameters?: Parameters<Paths.GetAutomation.PathParameters> | null,
318
- data?: any,
319
- config?: AxiosRequestConfig
320
- ): OperationResponse<Paths.GetAutomation.Responses.$200>
321
- /**
322
- * putAutomation - putAutomation
323
- *
324
- * Update automation definition by id
325
- */
326
- 'putAutomation'(
327
- parameters?: Parameters<Paths.PutAutomation.PathParameters> | null,
328
- data?: Paths.PutAutomation.RequestBody,
329
- config?: AxiosRequestConfig
330
- ): OperationResponse<Paths.PutAutomation.Responses.$201>
331
- /**
332
- * deleteAutomation - deleteAutomation
333
- *
334
- * Update automation definition by id
335
- */
336
- 'deleteAutomation'(
337
- parameters?: Parameters<Paths.DeleteAutomation.PathParameters> | null,
338
- data?: any,
339
- config?: AxiosRequestConfig
340
- ): OperationResponse<Paths.DeleteAutomation.Responses.$200>
341
- /**
342
- * getExecutions - getExecutions
343
- *
344
- * List automation executions
345
- */
346
- 'getExecutions'(
347
- parameters?: Parameters<Paths.GetExecutions.QueryParameters> | null,
348
- data?: any,
349
- config?: AxiosRequestConfig
350
- ): OperationResponse<Paths.GetExecutions.Responses.$200>
351
- /**
352
- * startExecution - startExecution
353
- *
354
- * Start new automation execution
355
- */
356
- 'startExecution'(
357
- parameters?: Parameters<UnknownParamsObject> | null,
358
- data?: Paths.StartExecution.RequestBody,
359
- config?: AxiosRequestConfig
360
- ): OperationResponse<Paths.StartExecution.Responses.$201>
361
- /**
362
- * getExecution - getExecution
363
- *
364
- * Get automation execution
365
- */
366
- 'getExecution'(
367
- parameters?: Parameters<Paths.GetExecution.PathParameters> | null,
368
- data?: any,
369
- config?: AxiosRequestConfig
370
- ): OperationResponse<Paths.GetExecution.Responses.$200>
371
- /**
372
- * cancelExecution - cancelExecution
373
- *
374
- * Cancel automation execution
375
- */
376
- 'cancelExecution'(
377
- parameters?: Parameters<Paths.CancelExecution.PathParameters> | null,
378
- data?: any,
379
- config?: AxiosRequestConfig
380
- ): OperationResponse<Paths.CancelExecution.Responses.$200>
381
- }
382
-
383
- export interface PathsDictionary {
384
- ['/v1/automation/definitions']: {
385
- /**
386
- * searchAutomations - searchAutomations
387
- *
388
- * Search available automation definitions
389
- */
390
- 'get'(
391
- parameters?: Parameters<Paths.SearchAutomations.QueryParameters> | null,
392
- data?: any,
393
- config?: AxiosRequestConfig
394
- ): OperationResponse<Paths.SearchAutomations.Responses.$200>
395
- /**
396
- * createAutomation - createAutomation
397
- *
398
- * Create new automation definition
399
- */
400
- 'post'(
401
- parameters?: Parameters<UnknownParamsObject> | null,
402
- data?: Paths.CreateAutomation.RequestBody,
403
- config?: AxiosRequestConfig
404
- ): OperationResponse<Paths.CreateAutomation.Responses.$201>
405
- }
406
- ['/v1/automation/definitions/{definition_id}']: {
407
- /**
408
- * getAutomation - getAutomation
409
- *
410
- * List available automation definitions
411
- */
412
- 'get'(
413
- parameters?: Parameters<Paths.GetAutomation.PathParameters> | null,
414
- data?: any,
415
- config?: AxiosRequestConfig
416
- ): OperationResponse<Paths.GetAutomation.Responses.$200>
417
- /**
418
- * putAutomation - putAutomation
419
- *
420
- * Update automation definition by id
421
- */
422
- 'put'(
423
- parameters?: Parameters<Paths.PutAutomation.PathParameters> | null,
424
- data?: Paths.PutAutomation.RequestBody,
425
- config?: AxiosRequestConfig
426
- ): OperationResponse<Paths.PutAutomation.Responses.$201>
427
- /**
428
- * deleteAutomation - deleteAutomation
429
- *
430
- * Update automation definition by id
431
- */
432
- 'delete'(
433
- parameters?: Parameters<Paths.DeleteAutomation.PathParameters> | null,
434
- data?: any,
435
- config?: AxiosRequestConfig
436
- ): OperationResponse<Paths.DeleteAutomation.Responses.$200>
437
- }
438
- ['/v1/automation/executions']: {
439
- /**
440
- * getExecutions - getExecutions
441
- *
442
- * List automation executions
443
- */
444
- 'get'(
445
- parameters?: Parameters<Paths.GetExecutions.QueryParameters> | null,
446
- data?: any,
447
- config?: AxiosRequestConfig
448
- ): OperationResponse<Paths.GetExecutions.Responses.$200>
449
- /**
450
- * startExecution - startExecution
451
- *
452
- * Start new automation execution
453
- */
454
- 'post'(
455
- parameters?: Parameters<UnknownParamsObject> | null,
456
- data?: Paths.StartExecution.RequestBody,
457
- config?: AxiosRequestConfig
458
- ): OperationResponse<Paths.StartExecution.Responses.$201>
459
- }
460
- ['/v1/automation/executions/{execution_id}']: {
461
- /**
462
- * getExecution - getExecution
463
- *
464
- * Get automation execution
465
- */
466
- 'get'(
467
- parameters?: Parameters<Paths.GetExecution.PathParameters> | null,
468
- data?: any,
469
- config?: AxiosRequestConfig
470
- ): OperationResponse<Paths.GetExecution.Responses.$200>
471
- /**
472
- * cancelExecution - cancelExecution
473
- *
474
- * Cancel automation execution
475
- */
476
- 'delete'(
477
- parameters?: Parameters<Paths.CancelExecution.PathParameters> | null,
478
- data?: any,
479
- config?: AxiosRequestConfig
480
- ): OperationResponse<Paths.CancelExecution.Responses.$200>
481
- }
482
- }
483
-
484
- export type Client = OpenAPIClient<OperationMethods, PathsDictionary>