Is there a way to deploy a workflow via Alteryx Server API?
For example if some one provides .yxmd file can we have an api deploy it to gallery and schedule it via api calls?
Hi @rj24by7
Currently there's no support for what you're looking for using the Alteryx Gallery API.
You can queue jobs from workflows that already exist in the Gallery using the POST call. But other than that, there's no functionality to upload workflows.
Cheers,
While using the Gallery API I am getting the following error despite getting key/shared secret: Unauthorized Exception
From this post on Migrating Workflows it appears that there is some functionality for admins to publish a workflow via sending a POST to the the api/admin/v1/workflows/ endpoint:
[HTTP POST]
[api/admin/v1/workflows/]
3. The third endpoint is a publish endpoint. This allows you to take the workflow obtained in the second endpoint and publish to the target environment. This post uses a multipart form-data request. The form sections and properties can be found in the code example.
Is that the case?
@johnru
Yes, we were able to use the Server API to download a canvas from Development environment and publish the canvas to Production environment.
[Download canvas from Source Environment]
[HTTP GET]
[api/admin/v1/{appID}/package/]
[Publish canvas to Target Environment]
[HTTP POST]
[api/admin/v1/workflows/]
Providing the right parameters are key to publishing canvases to Server through API.
1.Target Gallery Base address
2. Target Consumer Key
3. Target Consumer Secret
4. Source ID (Each canvas should be provided a source ID. If the same source ID is used for the publication of a canvas for the second time, it will replace the canvas which was published earlier with the same source ID. Source ID canvas mapping is the key to perform publication and republication of a canvas)
5. Canvas Name
6. File Path where the canvas is stored/canvas package
7. Owner
8. WorkerTag
9. isPublic
10. canDownload
11. validate
Good luck!