Exporting / importing projects
Warn about saving for rollback purposes
Once you have a suitable environment setup in place, you can promote projects from dev to staging, prod etc.
To enable this, Tray has a system whereby you can export and import projects (and individual workflows) as json files.
The basic process
Importing and exporting is the method used to promote projects from one env to another
Create and test the project/workflow(s) in your test/dev environment, using test/sandbox accounts and test data
Once you are ready to publish the first version, export your workflow/project to a local json file and then import it to your production workspace
In the process of your first import, select your production authentications (or create new ones if necessary)
Edit subsequent versions in the test/dev workspace, before importing again to the production workspace
Every time you do a promotion save each export.json in your own storage
- Version
- Add metadata
- Any breaking changes?
Implementation notes
- When importing subsequent versions any workflow step settings will be overwritten by the settings in the new version:
There may be discrepancies between the service accounts you are accessing - e.g. your Google Sheets live account may not have the same sheet as your Google Sheets test account. In this case you should use config variables to set the correct sheet in dev and prod and, if necessary, make this config data available for End Users to set it as per their requirements
You will only need to create production authentications the first time you import
Any new / changed services introduced to your projects will need to be authenticated:
- For example, if the first version of your solution only contained Slack as a third party service, but you introduced Gmail as another service in the next version, then when importing the next version to production you will need to create a new Gmail authentication
If an auth is updated in the source (dev) projects then the auth will need to be updated and reselected in the destination projects
Importing projects manually
Export project from dev
[IMAGE]
Import project to prod
[IMAGE]
Select prod authentications (first import only)
[IMAGE]
Import subsequent versions
You can import subsequent versions of your project from within the project page:
[IMAGE]
Import projects programatically via API
This feature is currently only available to Enterprise customers with the Embedded bundle
It is possible to programatically Import and Export workflows and projects / solutions with our GraphQL APIs.
If you are exporting from e.g. a dev account and importing to a production account you will need to use the correct master token for each account
The first import of a project will have to be done manually (as described above) in order to allow you to create the linked authentications in the target workflow(s).
If new services are added to any subsequent versions then you will need to run another manual import, as new authentications will need to be linked
The exportProject mutation
The exportProject mutation can be used to export a Project.
This requires the projectId of the Project you wish to export (obtained from the url when editing a Project: https://app.tray.io/project/{projectId}/workflow/{workflowId}/edit
)
mutation exportProject {
exportProject (input: {
projectId: "d9b4xxx-xxxx-xxx-xxxxxc9f25e"
exportSolution: true
}) {
exportedProjectJson
}
}
The response to this will contain the exportedProjectJson
(this is the same json output as per a manual export but in stringified format):
{
"data": {
"exportProject": {
"exportedProjectJson": "{\n \"export_type\" : \"project\",\n \"projects\" : [ {\n \"id\" : \"d9b41594-xxxx-xxxx-xxxx-ffff9bc9f25e\",\n \"name\" : \"Webhook demo\",\n \"config\" : {\n \"slack-channel\" : \"CE3KXDFTP\",\n \"slack-message\" : \"The webhook for your solution instance has been triggered\"\n },\n \"workflows\" : [ \"804c5f50-9xxx-xxx-xxx507ff45\", \"ddcxxx-xxx-xxx-xxx-xxx7296cfc2\" ],\n \"dependencies\" : [ ]\n } ],\n \"solution\" : {\n \"id\" : \"91c0fxxx-xxx-xxx-xxx-xx978ea5\",\n \"name\" : \"Webhook demo\",\n \"description\" : \"\",\n \"project_id\" : \"d9b41594-xxxx-xxxx-xxxx-ffff9bc9f25e\",\n \"tags\" : [ ],\n \"custom_fields\" : { },\n \"view_schema\" : {\n \"version\" : 5,\n \"screens\" : [ {\n \"id\" : \"af463xxx-xxx-xxx-xxx-xxx85d65d\",\n \"hidden\" : true,\n \"items\" : [ {\n \"id\" : \"e1655xxx-xxx-xxx-xxxx46b6c0\",\n \"itemType\" : 2,\n \"new\" : true,\n \"title\" : \"instance-trigger Public Url\",\n \"workflowId\" : \"ddcxxx-xxx-xxx-xxx-xxx96cfc2\"\n } ],\n \"new\" : false\n }, {\n \"id\" : \"b717xxx-xxx-xxx-xxx-xxx222f8\",\n \"new\" : false,\n \"items\" : [ {\n \"id\" : \"83aaexxx-xxx-xxx-xxx-xxxf74b888\",\n xxx-xxx-xxx-xxx9a3-xxxx-xxxx-xxxx-ddcfc327555e\",\n \"itemType\" : 4,\n \"content\" : \"Below is the webhook url for your workflow instance\"\n }, {\n \"id\" : \"d330cxxx-xxx-xxx-xxxef81e36\",\n \"itemType\" : 2,\n \"new\" : false,\n \"title\" : \"Webhook demo Public Url\",\n \"workflowId\" : \"804cxxx-xxx-xxx-xxxx07ff45\"\n } ]\n }, {\n \"id\" : \"56a6xxx-xxx-xxx-xxx-xxxc347ba3\",\n \"items\" : [ {\n \"id\" : \"d147bxxx-xxx-xxx-xxx-xxxb9d15\",\n \"itemType\" : 3,\n \"content\" : \"Slack authentication\"\n }, {\n \"id\" : \"c515xxx-xxx-xxx-xxx76a3b30\",\n \"itemType\" : 4,\n \"content\" : \"Please create your Slack authentication and set the alerting channel and message\"\n }, {\n \"id\" : \"e20b5e3c-xxxx-xxxx-xxxx-9fe607ac7daa\",\n \"itemType\" : 0,\n \"new\" : false,\n \"buttonCTA\" : \"New authentication\",\n \"slot\" : {\n \"id\" : \"4eb7b636-xxxx-xxxx-xxxx-8f0227713362\",\n \"authId\" : \"03d1c064-xxxx-xxxx-xxxx-5d0ae56813f5\",\n \"serviceId\" : \"aba1a078-xxxx-xxxx-xxxx-0b703b29e76d\",\n \"authAppId\" : \"70fce61a-xxxx-xxxx-xxxx-c3b26fe1a4c5\",\n \"title\" : \"Slack authentication\",\n \"description\" : \"\",\n \"externalId\" : \"external_slack_authentication\",\n \"hidden\" : false,\n \"useExisting\" : false,\n \"static\" : false,\n \"scopes\" : [ \"users:read\", \"groups:write\", \"users:read.email\", \"channels:read\", \"chat:write:user\", \"files:read\", \"reminders:write\", \"channels:write\", \"groups:read\", \"chat:write:bot\" ],\n \"usage\" : [ {\n \"workflowId\" : \"804c5f50-xxxx-xxxx-xxxx-9338c507ff45\",\n \"versionId\" : \"2e926fa4-xxxx-xxxx-xxxx-5329575c93e1\",\n \"steps\" : [ {\n \"stepName\" : \"slack-1\",\n \"connector\" : {\n \"name\" : \"slack\",\n \"version\" : \"6.0\"\n },\n \"operation\" : \"send_message\",\n \"authId\" : \"03d1c064-xxxx-xxxx-xxxx-5d0ae56813f5\",\n \"properties\" : [ ]\n } ]\n }, {\n \"workflowId\" : \"ddc64647-xxxx-xxxx-xxxx-5abc7296cfc2\",\n \"versionId\" : \"16dc62e2-xxxx-xxxx-xxxx-0f6686532a1f\",\n \"steps\" : [ {\n \"stepName\" : \"slack-1\",\n \"connector\" : {\n \"name\" : \"slack\",\n \"version\" : \"7.0\"\n },\n \"operation\" : \"send_message\",\n \"authId\" : \"03d1c064-xxxx-xxxx-xxxx-5d0ae56813f5\",\n \"properties\" : [ ]\n } ]\n } ]\n }\n }, {\n \"id\" : \"b35abbc0-xxxx-xxxx-xxxx-1a422a821ecc\",\n \"itemType\" : 1,\n \"new\" : false,\n \"slot\" : {\n \"id\" : \"2cc876d6-xxxx-xxxx-xxxx-dc9098bbdb12\",\n \"key\" : \"slack-channel\",\n \"title\" : \"slack-channel\",\n \"description\" : \"\",\n \"externalId\" : \"external_slack-channel\",\n \"hidden\" : false,\n \"type\" : \"string\",\n \"defaultValue\" : \"CE3KXDFTP\",\n \"required\" : true,\n \"useDefaultValue\" : false,\n \"static\" : false,\n \"authSlotId\" : \"4eb7b636-xxxx-xxxx-xxxx-8f0227713362\",\n \"ephemeralMetadata\" : {\n \"connector\" : {\n \"name\" : \"slack\",\n \"version\" : \"6.0\"\n },\n \"operation\" : \"send_message\",\n \"ddlOperation\" : \"list_users_channels_groups_ddl\",\n \"propertyPath\" : \"channel\",\n \"dependencies\" : [ ],\n \"ephemeralMetadataType\" : \"Regular\"\n },\n \"usage\" : [ {\n \"workflowId\" : \"804c5f50-xxxx-xxxx-xxxx-9338c507ff45\",\n \"versionId\" : \"2e926fa4-xxxx-xxxx-xxxx-5329575c93e1\",\n \"steps\" : [ {\n \"stepName\" : \"slack-1\",\n \"connector\" : {\n \"name\" : \"slack\",\n \"version\" : \"6.0\"\n },\n \"operation\" : \"send_message\",\n \"authId\" : \"03d1c064-xxxx-xxxx-xxxx-5d0ae56813f5\",\n \"properties\" : [ {\n \"path\" : \"channel\",\n \"value\" : {\n \"type\" : \"jsonpath\",\n \"value\" : \"$.config.slack-channel\"\n }\n } ]\n } ]\n } ]\n }\n }, {\n \"id\" : \"c5e7205b-xxxx-xxxx-xxxx-03aedeae0162\",\n \"itemType\" : 1,\n \"new\" : false,\n \"slot\" : {\n \"id\" : \"4022a298-xxxx-xxxx-xxxx-50e5f9fc519a\",\n \"key\" : \"slack-message\",\n \"title\" : \"slack-message\",\n \"description\" : \"\",\n \"externalId\" : \"external_slack-message\",\n \"hidden\" : false,\n \"type\" : \"string\",\n \"defaultValue\" : \"The webhook for your solution instance has been triggered\",\n \"required\" : true,\n \"useDefaultValue\" : false,\n \"static\" : false,\n \"authSlotId\" : \"4eb7b636-xxxx-xxxx-xxxx-8f0227713362\",\n \"usage\" : [ {\n \"workflowId\" : \"804c5f50-xxxx-xxxx-xxxx-9338c507ff45\",\n \"versionId\" : \"2e926fa4-xxxx-xxxx-xxxx-5329575c93e1\",\n \"steps\" : [ {\n \"stepName\" : \"slack-1\",\n \"connector\" : {\n \"name\" : \"slack\",\n \"version\" : \"6.0\"\n },\n \"operation\" : \"send_message\",\n \"authId\" : \"03d1c064-xxxx-xxxx-xxxx-5d0ae56813f5\",\n \"properties\" : [ {\n \"path\" : \"text\",\n \"value\" : {\n \"type\" : \"jsonpath\",\n \"value\" : \"$.config.slack-message\"\n }\n } ]\n } ]\n } ]\n }\n } ],\n \"new\" : false\n } ]\n },\n \"auth_slots\" : [ {\n \"id\" : \"4eb7b636-xxxx-xxxx-xxxx-8f0227713362\",\n \"auth_group\" : \"3e268690-xxxx-xxxx-xxxx-41a14d9248b4\",\n \"service_id\" : \"aba1a078-xxxx-xxxx-xxxx-0b703b29e76d\",\n \"auth_app_id\" : \"70fce61a-xxxx-xxxx-xxxx-c3b26fe1a4c5\",\n \"title\" : \"Slack authentication\",\n \"description\" : \"\",\n \"external_id\" : \"external_slack_authentication\",\n \"hidden\" : false,\n \"use_existing\" : false,\n \"static\" : false,\n \"scopes\" : [ \"users:read\", \"groups:write\", \"users:read.email\", \"channels:read\", \"chat:write:user\", \"files:read\", \"reminders:write\", \"channels:write\", \"groups:read\", \"chat:write:bot\" ],\n \"usage\" : [ {\n \"workflow_id\" : \"804c5f50-xxxx-xxxx-xxxx-9338c507ff45\",\n \"version_id\" : \"2e926fa4-xxxx-xxxx-xxxx-5329575c93e1\",\n \"steps\" : [ {\n \"step_name\" : \"slack-1\",\n \"connector\" : {\n \"name\" : \"slack\",\n \"version\" : \"6.0\"\n },\n \"operation\" : \"send_message\",\n \"auth_group\" : \"3e268690-xxxx-xxxx-xxxx-41a14d9248b4\",\n \"properties\" : [ ]\n } ]\n }, {\n \"workflow_id\" : \"ddc64647-xxxx-xxxx-xxxx-5abc7296cfc2\",\n \"version_id\" : \"16dc62e2-xxxx-xxxx-xxxx-0f6686532a1f\",\n \"steps\" : [ {\n \"step_name\" : \"slack-1\",\n \"connector\" : {\n \"name\" : \"slack\",\n \"version\" : \"7.0\"\n },\n \"operation\" : \"send_message\",\n \"auth_group\" : \"3e268690-xxxx-xxxx-xxxx-41a14d9248b4\",\n \"properties\" : [ ]\n } ]\n } ]\n } ],\n \"config_slots\" : [ {\n \"id\" : \"2cc876d6-xxxx-xxxx-xxxx-dc9098bbdb12\",\n \"key\" : \"slack-channel\",\n \"title\" : \"slack-channel\",\n \"description\" : \"\",\n \"external_id\" : \"external_slack-channel\",\n \"hidden\" : false,\n \"type\" : \"string\",\n \"default_value\" : \"CE3KXDFTP\",\n \"required\" : true,\n \"use_default_value\" : false,\n \"static\" : false,\n \"auth_slot_id\" : \"4eb7b636-xxxx-xxxx-xxxx-8f0227713362\",\n \"ephemeral_metadata\" : {\n \"connector\" : {\n \"name\" : \"slack\",\n \"version\" : \"6.0\"\n },\n \"operation\" : \"send_message\",\n \"ddl_operation\" : \"list_users_channels_groups_ddl\",\n \"property_path\" : \"channel\",\n \"dependencies\" : [ ],\n \"ephemeral_metadata_type\" : \"Regular\"\n },\n \"usage\" : [ {\n \"workflow_id\" : \"804c5f50-xxxx-xxxx-xxxx-9338c507ff45\",\n \"version_id\" : \"2e926fa4-xxxx-xxxx-xxxx-5329575c93e1\",\n \"steps\" : [ {\n \"step_name\" : \"slack-1\",\n \"connector\" : {\n \"name\" : \"slack\",\n \"version\" : \"6.0\"\n },\n \"operation\" : \"send_message\",\n \"auth_group\" : \"3e268690-xxxx-xxxx-xxxx-41a14d9248b4\",\n \"properties\" : [ {\n \"path\" : \"channel\",\n \"value\" : {\n \"type\" : \"jsonpath\",\n \"value\" : \"$.config.slack-channel\"\n }\n } ]\n } ]\n } ]\n }, {\n \"id\" : \"4022a298-xxxx-xxxx-xxxx-50e5f9fc519a\",\n \"key\" : \"slack-message\",\n \"title\" : \"slack-message\",\n \"description\" : \"\",\n \"external_id\" : \"external_slack-message\",\n \"hidden\" : false,\n \"type\" : \"string\",\n \"default_value\" : \"The webhook for your solution instance has been triggered\",\n \"required\" : true,\n \"use_default_value\" : false,\n \"static\" : false,\n \"auth_slot_id\" : \"4eb7b636-xxxx-xxxx-xxxx-8f0227713362\",\n \"usage\" : [ {\n \"workflow_id\" : \"804c5f50-xxxx-xxxx-xxxx-9338c507ff45\",\n \"version_id\" : \"2e926fa4-xxxx-xxxx-xxxx-5329575c93e1\",\n \"steps\" : [ {\n \"step_name\" : \"slack-1\",\n \"connector\" : {\n \"name\" : \"slack\",\n \"version\" : \"6.0\"\n },\n \"operation\" : \"send_message\",\n \"auth_group\" : \"3e268690-xxxx-xxxx-xxxx-41a14d9248b4\",\n \"properties\" : [ {\n \"path\" : \"text\",\n \"value\" : {\n \"type\" : \"jsonpath\",\n \"value\" : \"$.config.slack-message\"\n }\n } ]\n } ]\n } ]\n } ]\n },\n \"tray_export_version\" : 3,\n \"workflows\" : [ {\n \"id\" : \"804c5f50-xxxx-xxxx-xxxx-9338c507ff45\",\n \"created\" : \"2020-09-29T18:52:03.437Z\",\n \"workspace_id\" : \"6c595d5b-xxxx-xxxx-xxxx-959ceb938eae\",\n \"project_id\" : \"d9b41594-xxxx-xxxx-xxxx-ffff9bc9f25e\",\n \"group\" : \"6e7e1eac-xxxx-xxxx-xxxx-9b10518391a8\",\n \"creator\" : \"6c595d5b-xxxx-xxxx-xxxx-959ceb938eae\",\n \"version\" : {\n \"id\" : \"2e926fa4-xxxx-xxxx-xxxx-5329575c93e1\",\n \"created\" : \"2020-09-30T10:01:20.315Z\"\n },\n \"title\" : \"Webhook demo\",\n \"enabled\" : true,\n \"tags\" : [ ],\n \"settings\" : {\n \"config\" : {\n \"slack-channel\" : \"CE3KXDFTP\",\n \"slack-message\" : \"The webhook for your solution instance has been triggered\"\n },\n \"input_schema\" : { },\n \"output_schema\" : { }\n },\n \"steps_structure\" : [ {\n \"name\" : \"trigger\",\n \"type\" : \"normal\",\n \"content\" : { }\n }, {\n \"name\" : \"slack-1\",\n \"type\" : \"normal\",\n \"content\" : { }\n } ],\n \"steps\" : {\n \"slack-1\" : {\n \"title\" : \"Alert slack channel\",\n \"connector\" : {\n \"name\" : \"slack\",\n \"version\" : \"6.0\"\n },\n \"operation\" : \"send_message\",\n \"output_schema\" : { },\n \"error_handling\" : { },\n \"authentication\" : {\n \"group\" : \"3e268690-xxxx-xxxx-xxxx-41a14d9248b4\",\n \"title\" : \"Mike Hewitt's Slack account\",\n \"service_icon\" : {\n \"icon_type\" : \"url\",\n \"value\" : \"//s3.amazonaws.com/images.tray.io/artisan/icons/c25033a972715dbbdb7e73ac79261230.png\"\n },\n \"service_id\" : \"aba1a078-xxxx-xxxx-xxxx-0b703b29e76d\",\n \"auth_app_id\" : \"70fce61a-xxxx-xxxx-xxxx-c3b26fe1a4c5\",\n \"scopes\" : [ \"chat:write:bot\", \"chat:write:user\" ]\n },\n \"properties\" : {\n \"link_names\" : {\n \"type\" : \"boolean\",\n \"value\" : false\n },\n \"reply_broadcast\" : {\n \"type\" : \"boolean\",\n \"value\" : false\n },\n \"parse\" : {\n \"type\" : \"string\",\n \"value\" : \"none\"\n },\n \"username\" : {\n \"type\" : \"string\",\n \"value\" : \"Tray.io\"\n },\n \"as_user\" : {\n \"type\" : \"boolean\",\n \"value\" : false\n },\n \"token\" : {\n \"type\" : \"jsonpath\",\n \"value\" : \"$.auth.access_token\"\n },\n \"channel\" : {\n \"type\" : \"jsonpath\",\n \"value\" : \"$.config.slack-channel\"\n },\n \"text\" : {\n \"type\" : \"jsonpath\",\n \"value\" : \"$.config.slack-message\"\n }\n }\n },\n \"trigger\" : {\n \"title\" : \"Webhook\",\n \"connector\" : {\n \"name\" : \"webhook\",\n \"version\" : \"2.2\"\n },\n \"operation\" : \"fire_and_forget\",\n \"output_schema\" : { },\n \"error_handling\" : { },\n \"properties\" : { }\n }\n },\n \"dependencies\" : [ ]\n }, {\n \"id\" : \"ddc64647-xxxx-xxxx-xxxx-5abc7296cfc2\",\n \"created\" : \"2020-11-11T14:34:00.298Z\",\n \"workspace_id\" : \"6c595d5b-xxxx-xxxx-xxxx-959ceb938eae\",\n \"project_id\" : \"d9b41594-xxxx-xxxx-xxxx-ffff9bc9f25e\",\n \"group\" : \"69f86944-xxxx-xxxx-xxxx-0a93d6b178b0\",\n \"creator\" : \"6c595d5b-xxxx-xxxx-xxxx-959ceb938eae\",\n \"version\" : {\n \"id\" : \"16dc62e2-xxxx-xxxx-xxxx-0f6686532a1f\",\n \"created\" : \"2020-11-11T14:37:10.303Z\"\n },\n \"title\" : \"instance-trigger\",\n \"enabled\" : true,\n \"tags\" : [ ],\n \"settings\" : {\n \"config\" : {\n \"slack-channel\" : \"CE3KXDFTP\",\n \"slack-message\" : \"The webhook for your solution instance has been triggered\"\n },\n \"input_schema\" : { },\n \"output_schema\" : { }\n },\n \"steps_structure\" : [ {\n \"name\" : \"trigger\",\n \"type\" : \"normal\",\n \"content\" : { }\n }, {\n \"name\" : \"slack-1\",\n \"type\" : \"normal\",\n \"content\" : { }\n } ],\n \"steps\" : {\n \"slack-1\" : {\n \"title\" : \"Slack\",\n \"connector\" : {\n \"name\" : \"slack\",\n \"version\" : \"7.0\"\n },\n \"operation\" : \"send_message\",\n \"output_schema\" : { },\n \"error_handling\" : { },\n \"authentication\" : {\n \"group\" : \"3e268690-xxxx-xxxx-xxxx-41a14d9248b4\",\n \"title\" : \"Mike Hewitt's Slack account\",\n \"service_icon\" : {\n \"icon_type\" : \"url\",\n \"value\" : \"//s3.amazonaws.com/images.tray.io/artisan/icons/c25033a972715dbbdb7e73ac79261230.png\"\n },\n \"service_id\" : \"aba1a078-xxxx-xxxx-xxxx-0b703b29e76d\",\n \"auth_app_id\" : \"70fce61a-xxxx-xxxx-xxxx-c3b26fe1a4c5\",\n \"scopes\" : [ \"chat:write:bot\", \"chat:write:user\" ]\n },\n \"properties\" : {\n \"link_names\" : {\n \"type\" : \"boolean\",\n \"value\" : false\n },\n \"reply_broadcast\" : {\n \"type\" : \"boolean\",\n \"value\" : false\n },\n \"parse\" : {\n \"type\" : \"string\",\n \"value\" : \"none\"\n },\n \"username\" : {\n \"type\" : \"string\",\n \"value\" : \"Tray.io\"\n },\n \"as_user\" : {\n \"type\" : \"boolean\",\n \"value\" : false\n },\n \"token\" : {\n \"type\" : \"jsonpath\",\n \"value\" : \"$.auth.access_token\"\n },\n \"channel\" : {\n \"type\" : \"string\",\n \"value\" : \"CEAC4886Q\"\n },\n \"text\" : {\n \"type\" : \"string\",\n \"value\" : \"{$.steps.trigger.solutionInstanceId} has been updated!\"\n }\n }\n },\n \"trigger\" : {\n \"title\" : \"Solution instance trigger\",\n \"connector\" : {\n \"name\" : \"solution-instance-trigger\",\n \"version\" : \"1.0\"\n },\n \"operation\" : \"webhook\",\n \"output_schema\" : { },\n \"error_handling\" : { },\n \"properties\" : {\n \"events\" : {\n \"type\" : \"object\",\n \"value\" : {\n \"updated\" : {\n \"type\" : \"boolean\",\n \"value\" : true\n }\n }\n }\n }\n }\n },\n \"dependencies\" : [ ]\n } ]\n}"
}
}
}
The importProject mutation
The importProject mutation can then be used to import the Project to e.g. your 'production' account.
mutation importProject {
importProject (input: {
exportedProjectJson: "{\n \"export_type\" : \"project\",\n \"projects\" : [ {\n \"id\" : \"d9b41594-xxxx-xxxx-xxxx-ffff9bc9f25e\",\n \"name\" : \"Webhook demo\",\n \"config\" : {\n \"slack-channel\" : \"CE3KXDFTP\",\n \"slack-message\" : \"The webhook for your solution instance has been triggered\"\n },\n \"workflows\" : [ \"804c5f50-xxxx-xxxx-xxxx-9338c507ff45\", \"ddc64647-xxxx-xxxx-xxxx-5abc7296cfc2\" ],\n \"dependencies\" : [ ]\n } ],\n \"solution\" : {\n \"id\" : \"91c0f56f-xxxx-xxxx-xxxx-184686978ea5\",\n \"name\" : \"Webhook demo\",\n \"description\" : \"\",\n \"project_id\" : \"d9b41594-xxxx-xxxx-xxxx-ffff9bc9f25e\",\n \"tags\" : [ ],\n \"custom_fields\" : { },\n \"view_schema\" : {\n \"version\" : 6,\n \"screens\" : [ {\n \"id\" : \"af463e6f-xxxx-xxxx-xxxx-21f94285d65d\",\n \"hidden\" : true,\n \"items\" : [ {\n \"id\" : \"e1655697-xxxx-xxxx-xxxx-5aba5646b6c0\",\n \"itemType\" : 2,\n \"new\" : false,\n \"title\" : \"instance-trigger Public Url\",\n \"workflowId\" : \"ddc64647-xxxx-xxxx-xxxx-5abc7296cfc2\"\n } ],\n \"new\" : false\n }, {\n \"id\" : \"b71775ec-xxxx-xxxx-xxxx-9ab038c222f8\",\n \"new\" : false,\n \"items\" : [ {\n \"id\" : \"83aaeac6-xxxx-xxxx-xxxx-eb859f74b888\",\n \"itemType\" : 3,\n \"content\" : \"Workflow URLs\"\n }, {\n \"id\" : \"1f3d99a3-xxxx-xxxx-xxxx-ddcfc327555e\",\n \"itemType\" : 4,\n \"content\" : \"Below is the webhook url for your workflow instance\"\n }, {\n \"id\" : \"7571180d-xxxx-xxxx-xxxx-16064f7917a2\",\n \"itemType\" : \"SPACER\",\n \"unit\" : \"%\",\n \"height\" : 15\n }, {\n \"id\" : \"d330c064-xxxx-xxxx-xxxx-9822def81e36\",\n \"itemType\" : 2,\n \"new\" : false,\n \"title\" : \"Webhook demo Public Url\",\n \"workflowId\" : \"804c5f50-xxxx-xxxx-xxxx-9338c507ff45\"\n } ]\n }, {\n \"id\" : \"56a634da-xxxx-xxxx-xxxx-745bec347ba3\",\n \"items\" : [ {\n \"id\" : \"d147bea2-xxxx-xxxx-xxxx-9716da1b9d15\",\n \"itemType\" : 3,\n \"content\" : \"Slack authentication\"\n }, {\n \"id\" : \"c51528be-xxxx-xxxx-xxxx-a288876a3b30\",\n \"itemType\" : 4,\n \"content\" : \"Please create your Slack authentication and set the alerting channel and message\"\n }, {\n \"id\" : \"e63557cc-xxxx-xxxx-xxxx-143f485b1420\",\n \"itemType\" : \"SPACER\",\n \"unit\" : \"%\",\n \"height\" : 15\n }, {\n \"id\" : \"e20b5e3c-xxxx-xxxx-xxxx-9fe607ac7daa\",\n \"itemType\" : 0,\n \"new\" : false,\n \"buttonCTA\" : \"New authentication\",\n \"slot\" : {\n \"id\" : \"4eb7b636-xxxx-xxxx-xxxx-8f0227713362\",\n \"authId\" : \"03d1c064-xxxx-xxxx-xxxx-5d0ae56813f5\",\n \"serviceId\" : \"aba1a078-xxxx-xxxx-xxxx-0b703b29e76d\",\n \"authAppId\" : \"70fce61a-xxxx-xxxx-xxxx-c3b26fe1a4c5\",\n \"title\" : \"Slack authentication\",\n \"description\" : \"\",\n \"externalId\" : \"external_slack_authentication\",\n \"hidden\" : false,\n \"useExisting\" : false,\n \"static\" : false,\n \"scopes\" : [ \"users:read\", \"groups:write\", \"users:read.email\", \"channels:read\", \"chat:write:user\", \"files:read\", \"reminders:write\", \"channels:write\", \"groups:read\", \"chat:write:bot\" ],\n \"usage\" : [ {\n \"workflowId\" : \"ddc64647-xxxx-xxxx-xxxx-5abc7296cfc2\",\n \"versionId\" : \"16dc62e2-xxxx-xxxx-xxxx-0f6686532a1f\",\n \"steps\" : [ {\n \"stepName\" : \"slack-1\",\n \"connector\" : {\n \"name\" : \"slack\",\n \"version\" : \"7.0\"\n },\n \"operation\" : \"send_message\",\n \"authId\" : \"03d1c064-xxxx-xxxx-xxxx-5d0ae56813f5\",\n \"properties\" : [ ]\n } ]\n }, {\n \"workflowId\" : \"804c5f50-xxxx-xxxx-xxxx-9338c507ff45\",\n \"versionId\" : \"63c9d498-xxxx-xxxx-xxxx-95600f3acc77\",\n \"steps\" : [ {\n \"stepName\" : \"slack-1\",\n \"connector\" : {\n \"name\" : \"slack\",\n \"version\" : \"6.0\"\n },\n \"operation\" : \"send_message\",\n \"authId\" : \"03d1c064-xxxx-xxxx-xxxx-5d0ae56813f5\",\n \"properties\" : [ ]\n } ]\n } ]\n }\n }, {\n \"id\" : \"b35abbc0-xxxx-xxxx-xxxx-1a422a821ecc\",\n \"itemType\" : 1,\n \"new\" : false,\n \"slot\" : {\n \"id\" : \"2cc876d6-xxxx-xxxx-xxxx-dc9098bbdb12\",\n \"key\" : \"slack-channel\",\n \"title\" : \"slack-channel\",\n \"description\" : \"\",\n \"externalId\" : \"external_slack-channel\",\n \"hidden\" : false,\n \"type\" : \"string\",\n \"defaultValue\" : \"CE3KXDFTP\",\n \"required\" : true,\n \"useDefaultValue\" : false,\n \"static\" : false,\n \"authSlotId\" : \"4eb7b636-xxxx-xxxx-xxxx-8f0227713362\",\n \"ephemeralMetadata\" : {\n \"connector\" : {\n \"name\" : \"slack\",\n \"version\" : \"6.0\"\n },\n \"operation\" : \"send_message\",\n \"ddlOperation\" : \"list_users_channels_groups_ddl\",\n \"propertyPath\" : \"channel\",\n \"dependencies\" : [ ],\n \"ephemeralMetadataType\" : \"Regular\"\n },\n \"usage\" : [ {\n \"workflowId\" : \"804c5f50-xxxx-xxxx-xxxx-9338c507ff45\",\n \"versionId\" : \"63c9d498-xxxx-xxxx-xxxx-95600f3acc77\",\n \"steps\" : [ {\n \"stepName\" : \"slack-1\",\n \"connector\" : {\n \"name\" : \"slack\",\n \"version\" : \"6.0\"\n },\n \"operation\" : \"send_message\",\n \"authId\" : \"03d1c064-xxxx-xxxx-xxxx-5d0ae56813f5\",\n \"properties\" : [ {\n \"path\" : \"channel\",\n \"value\" : {\n \"type\" : \"jsonpath\",\n \"value\" : \"$.config.slack-channel\"\n }\n } ]\n } ]\n } ]\n }\n }, {\n \"id\" : \"c5e7205b-xxxx-xxxx-xxxx-03aedeae0162\",\n \"itemType\" : 1,\n \"new\" : false,\n \"slot\" : {\n \"id\" : \"4022a298-xxxx-xxxx-xxxx-50e5f9fc519a\",\n \"key\" : \"slack-message\",\n \"title\" : \"slack-message\",\n \"description\" : \"\",\n \"externalId\" : \"external_slack-message\",\n \"hidden\" : false,\n \"type\" : \"string\",\n \"defaultValue\" : \"The webhook for your solution instance has been triggered\",\n \"required\" : true,\n \"useDefaultValue\" : false,\n \"static\" : false,\n \"authSlotId\" : \"4eb7b636-xxxx-xxxx-xxxx-8f0227713362\",\n \"usage\" : [ {\n \"workflowId\" : \"804c5f50-xxxx-xxxx-xxxx-9338c507ff45\",\n \"versionId\" : \"63c9d498-xxxx-xxxx-xxxx-95600f3acc77\",\n \"steps\" : [ {\n \"stepName\" : \"slack-1\",\n \"connector\" : {\n \"name\" : \"slack\",\n \"version\" : \"6.0\"\n },\n \"operation\" : \"send_message\",\n \"authId\" : \"03d1c064-xxxx-xxxx-xxxx-5d0ae56813f5\",\n \"properties\" : [ {\n \"path\" : \"text\",\n \"value\" : {\n \"type\" : \"jsonpath\",\n \"value\" : \"$.config.slack-message\"\n }\n } ]\n } ]\n } ]\n }\n } ],\n \"new\" : false\n } ]\n },\n \"auth_slots\" : [ {\n \"id\" : \"4eb7b636-xxxx-xxxx-xxxx-8f0227713362\",\n \"auth_group\" : \"3e268690-xxxx-xxxx-xxxx-41a14d9248b4\",\n \"service_id\" : \"aba1a078-xxxx-xxxx-xxxx-0b703b29e76d\",\n \"auth_app_id\" : \"70fce61a-xxxx-xxxx-xxxx-c3b26fe1a4c5\",\n \"title\" : \"Slack authentication\",\n \"description\" : \"\",\n \"external_id\" : \"external_slack_authentication\",\n \"hidden\" : false,\n \"use_existing\" : false,\n \"static\" : false,\n \"scopes\" : [ \"users:read\", \"groups:write\", \"users:read.email\", \"channels:read\", \"chat:write:user\", \"files:read\", \"reminders:write\", \"channels:write\", \"groups:read\", \"chat:write:bot\" ],\n \"usage\" : [ {\n \"workflow_id\" : \"ddc64647-xxxx-xxxx-xxxx-5abc7296cfc2\",\n \"version_id\" : \"16dc62e2-xxxx-xxxx-xxxx-0f6686532a1f\",\n \"steps\" : [ {\n \"step_name\" : \"slack-1\",\n \"connector\" : {\n \"name\" : \"slack\",\n \"version\" : \"7.0\"\n },\n \"operation\" : \"send_message\",\n \"auth_group\" : \"3e268690-xxxx-xxxx-xxxx-41a14d9248b4\",\n \"properties\" : [ ]\n } ]\n }, {\n \"workflow_id\" : \"804c5f50-xxxx-xxxx-xxxx-9338c507ff45\",\n \"version_id\" : \"63c9d498-xxxx-xxxx-xxxx-95600f3acc77\",\n \"steps\" : [ {\n \"step_name\" : \"slack-1\",\n \"connector\" : {\n \"name\" : \"slack\",\n \"version\" : \"6.0\"\n },\n \"operation\" : \"send_message\",\n \"auth_group\" : \"3e268690-xxxx-xxxx-xxxx-41a14d9248b4\",\n \"properties\" : [ ]\n } ]\n } ]\n } ],\n \"config_slots\" : [ {\n \"id\" : \"2cc876d6-xxxx-xxxx-xxxx-dc9098bbdb12\",\n \"key\" : \"slack-channel\",\n \"title\" : \"slack-channel\",\n \"description\" : \"\",\n \"external_id\" : \"external_slack-channel\",\n \"hidden\" : false,\n \"type\" : \"string\",\n \"default_value\" : \"CE3KXDFTP\",\n \"required\" : true,\n \"use_default_value\" : false,\n \"static\" : false,\n \"auth_slot_id\" : \"4eb7b636-xxxx-xxxx-xxxx-8f0227713362\",\n \"ephemeral_metadata\" : {\n \"connector\" : {\n \"name\" : \"slack\",\n \"version\" : \"6.0\"\n },\n \"operation\" : \"send_message\",\n \"ddl_operation\" : \"list_users_channels_groups_ddl\",\n \"property_path\" : \"channel\",\n \"dependencies\" : [ ],\n \"ephemeral_metadata_type\" : \"Regular\"\n },\n \"usage\" : [ {\n \"workflow_id\" : \"804c5f50-xxxx-xxxx-xxxx-9338c507ff45\",\n \"version_id\" : \"63c9d498-xxxx-xxxx-xxxx-95600f3acc77\",\n \"steps\" : [ {\n \"step_name\" : \"slack-1\",\n \"connector\" : {\n \"name\" : \"slack\",\n \"version\" : \"6.0\"\n },\n \"operation\" : \"send_message\",\n \"auth_group\" : \"3e268690-xxxx-xxxx-xxxx-41a14d9248b4\",\n \"properties\" : [ {\n \"path\" : \"channel\",\n \"value\" : {\n \"type\" : \"jsonpath\",\n \"value\" : \"$.config.slack-channel\"\n }\n } ]\n } ]\n } ]\n }, {\n \"id\" : \"4022a298-xxxx-xxxx-xxxx-50e5f9fc519a\",\n \"key\" : \"slack-message\",\n \"title\" : \"slack-message\",\n \"description\" : \"\",\n \"external_id\" : \"external_slack-message\",\n \"hidden\" : false,\n \"type\" : \"string\",\n \"default_value\" : \"The webhook for your solution instance has been triggered\",\n \"required\" : true,\n \"use_default_value\" : false,\n \"static\" : false,\n \"auth_slot_id\" : \"4eb7b636-xxxx-xxxx-xxxx-8f0227713362\",\n \"usage\" : [ {\n \"workflow_id\" : \"804c5f50-xxxx-xxxx-xxxx-9338c507ff45\",\n \"version_id\" : \"63c9d498-xxxx-xxxx-xxxx-95600f3acc77\",\n \"steps\" : [ {\n \"step_name\" : \"slack-1\",\n \"connector\" : {\n \"name\" : \"slack\",\n \"version\" : \"6.0\"\n },\n \"operation\" : \"send_message\",\n \"auth_group\" : \"3e268690-xxxx-xxxx-xxxx-41a14d9248b4\",\n \"properties\" : [ {\n \"path\" : \"text\",\n \"value\" : {\n \"type\" : \"jsonpath\",\n \"value\" : \"$.config.slack-message\"\n }\n } ]\n } ]\n } ]\n } ]\n },\n \"tray_export_version\" : 3,\n \"workflows\" : [ {\n \"id\" : \"804c5f50-xxxx-xxxx-xxxx-9338c507ff45\",\n \"created\" : \"2020-09-29T18:52:03.437Z\",\n \"workspace_id\" : \"6c595d5b-xxxx-xxxx-xxxx-959ceb938eae\",\n \"project_id\" : \"d9b41594-xxxx-xxxx-xxxx-ffff9bc9f25e\",\n \"group\" : \"6e7e1eac-xxxx-xxxx-xxxx-9b10518391a8\",\n \"creator\" : \"6c595d5b-xxxx-xxxx-xxxx-959ceb938eae\",\n \"version\" : {\n \"id\" : \"63c9d498-xxxx-xxxx-xxxx-95600f3acc77\",\n \"created\" : \"2020-11-25T15:00:50.980Z\"\n },\n \"title\" : \"Webhook demo\",\n \"enabled\" : true,\n \"tags\" : [ ],\n \"settings\" : {\n \"config\" : {\n \"slack-channel\" : \"CE3KXDFTP\",\n \"slack-message\" : \"The webhook for your solution instance has been triggered\"\n },\n \"input_schema\" : { },\n \"output_schema\" : { }\n },\n \"steps_structure\" : [ {\n \"name\" : \"trigger\",\n \"type\" : \"normal\",\n \"content\" : { }\n }, {\n \"name\" : \"slack-1\",\n \"type\" : \"normal\",\n \"content\" : { }\n } ],\n \"steps\" : {\n \"trigger\" : {\n \"title\" : \"Webhook\",\n \"connector\" : {\n \"name\" : \"webhook\",\n \"version\" : \"2.2\"\n },\n \"operation\" : \"fire_and_forget\",\n \"output_schema\" : { },\n \"error_handling\" : { },\n \"properties\" : { }\n },\n \"slack-1\" : {\n \"title\" : \"Alert slack channel\",\n \"connector\" : {\n \"name\" : \"slack\",\n \"version\" : \"6.0\"\n },\n \"operation\" : \"send_message\",\n \"output_schema\" : { },\n \"error_handling\" : { },\n \"authentication\" : {\n \"group\" : \"3e268690-xxxx-xxxx-xxxx-41a14d9248b4\",\n \"title\" : \"Mike Hewitt's Slack account\",\n \"service_icon\" : {\n \"icon_type\" : \"url\",\n \"value\" : \"//s3.amazonaws.com/images.tray.io/artisan/icons/c25033a972715dbbdb7e73ac79261230.png\"\n },\n \"service_id\" : \"aba1a078-xxxx-xxxx-xxxx-0b703b29e76d\",\n \"auth_app_id\" : \"70fce61a-xxxx-xxxx-xxxx-c3b26fe1a4c5\",\n \"scopes\" : [ \"chat:write:bot\", \"chat:write:user\" ]\n },\n \"properties\" : {\n \"link_names\" : {\n \"type\" : \"boolean\",\n \"value\" : false\n },\n \"reply_broadcast\" : {\n \"type\" : \"boolean\",\n \"value\" : false\n },\n \"parse\" : {\n \"type\" : \"string\",\n \"value\" : \"none\"\n },\n \"username\" : {\n \"type\" : \"string\",\n \"value\" : \"Tray Embedded\"\n },\n \"as_user\" : {\n \"type\" : \"boolean\",\n \"value\" : false\n },\n \"token\" : {\n \"type\" : \"jsonpath\",\n \"value\" : \"$.auth.access_token\"\n },\n \"channel\" : {\n \"type\" : \"jsonpath\",\n \"value\" : \"$.config.slack-channel\"\n },\n \"text\" : {\n \"type\" : \"jsonpath\",\n \"value\" : \"$.config.slack-message\"\n }\n }\n }\n },\n \"dependencies\" : [ ]\n }, {\n \"id\" : \"ddc64647-xxxx-xxxx-xxxx-5abc7296cfc2\",\n \"created\" : \"2020-11-11T14:34:00.298Z\",\n \"workspace_id\" : \"6c595d5b-xxxx-xxxx-xxxx-959ceb938eae\",\n \"project_id\" : \"d9b41594-xxxx-xxxx-xxxx-ffff9bc9f25e\",\n \"group\" : \"69f86944-xxxx-xxxx-xxxx-0a93d6b178b0\",\n \"creator\" : \"6c595d5b-xxxx-xxxx-xxxx-959ceb938eae\",\n \"version\" : {\n \"id\" : \"16dc62e2-xxxx-xxxx-xxxx-0f6686532a1f\",\n \"created\" : \"2020-11-11T14:37:10.303Z\"\n },\n \"title\" : \"instance-trigger\",\n \"enabled\" : true,\n \"tags\" : [ ],\n \"settings\" : {\n \"config\" : {\n \"slack-channel\" : \"CE3KXDFTP\",\n \"slack-message\" : \"The webhook for your solution instance has been triggered\"\n },\n \"input_schema\" : { },\n \"output_schema\" : { }\n },\n \"steps_structure\" : [ {\n \"name\" : \"trigger\",\n \"type\" : \"normal\",\n \"content\" : { }\n }, {\n \"name\" : \"slack-1\",\n \"type\" : \"normal\",\n \"content\" : { }\n } ],\n \"steps\" : {\n \"slack-1\" : {\n \"title\" : \"Slack\",\n \"connector\" : {\n \"name\" : \"slack\",\n \"version\" : \"7.0\"\n },\n \"operation\" : \"send_message\",\n \"output_schema\" : { },\n \"error_handling\" : { },\n \"authentication\" : {\n \"group\" : \"3e268690-xxxx-xxxx-xxxx-41a14d9248b4\",\n \"title\" : \"Mike Hewitt's Slack account\",\n \"service_icon\" : {\n \"icon_type\" : \"url\",\n \"value\" : \"//s3.amazonaws.com/images.tray.io/artisan/icons/c25033a972715dbbdb7e73ac79261230.png\"\n },\n \"service_id\" : \"aba1a078-xxxx-xxxx-xxxx-0b703b29e76d\",\n \"auth_app_id\" : \"70fce61a-xxxx-xxxx-xxxx-c3b26fe1a4c5\",\n \"scopes\" : [ \"chat:write:bot\", \"chat:write:user\" ]\n },\n \"properties\" : {\n \"link_names\" : {\n \"type\" : \"boolean\",\n \"value\" : false\n },\n \"reply_broadcast\" : {\n \"type\" : \"boolean\",\n \"value\" : false\n },\n \"parse\" : {\n \"type\" : \"string\",\n \"value\" : \"none\"\n },\n \"username\" : {\n \"type\" : \"string\",\n \"value\" : \"Tray.io\"\n },\n \"as_user\" : {\n \"type\" : \"boolean\",\n \"value\" : false\n },\n \"token\" : {\n \"type\" : \"jsonpath\",\n \"value\" : \"$.auth.access_token\"\n },\n \"channel\" : {\n \"type\" : \"string\",\n \"value\" : \"CEAC4886Q\"\n },\n \"text\" : {\n \"type\" : \"string\",\n \"value\" : \"{$.steps.trigger.solutionInstanceId} has been updated!\"\n }\n }\n },\n \"trigger\" : {\n \"title\" : \"Solution instance trigger\",\n \"connector\" : {\n \"name\" : \"solution-instance-trigger\",\n \"version\" : \"1.0\"\n },\n \"operation\" : \"webhook\",\n \"output_schema\" : { },\n \"error_handling\" : { },\n \"properties\" : {\n \"events\" : {\n \"type\" : \"object\",\n \"value\" : {\n \"updated\" : {\n \"type\" : \"boolean\",\n \"value\" : true\n }\n }\n }\n }\n }\n },\n \"dependencies\" : [ ]\n } ]\n}"
targetProjectId: "944da62c-xxxx-xxxx-xxxx-5c8ea222eb99"
}) {
clientMutationId
}
}
A successful import will simply return:
{
"data": {
"importProject": {
"clientMutationId": null
}
}
}