This endpoint executes a deployment on an Appian environment. You can specify the name and description of the deployment, as well as upload a deployment package, import customization file, plug-in file, and/or database scripts.
A deployment package is a single ZIP file that can contain a package, an application, multiple applications, or multiple packages.
POST
/deployments
When performing a POST
request, you must define a request body using the multipart/form-data
content type. Form data allows you to send key-value pairs and upload files, such as your deployment package.
Each POST
request’s body must include a JSON object (application/json
content type) and form parameters (uploaded files). The JSON object is a list of key-value pairs, as listed below.
Key | Value | Required |
---|---|---|
name | Name of the deployment. This name will appear in the Deploy view in Appian Designer. | Yes |
description | Description of the deployment. This description will appear in the Deploy view in Appian Designer. | No |
packageFileName | File name of the deployment package (.zip). | No* |
customizationFileName | File name of the import customization file (.properties). | No* |
pluginsFileName | File name of the plug-ins file (.zip). | No* |
dataSource | Name or UUID of the data source. If the data source is connected through the Admin Console, use the value in the Name field. If the data source is connected through a data source connected system, use the UUID of the connected system. | No* |
databaseScripts | Array of data. Each element of the array consists of an object with a file name and an order ID used for execution order of the scripts (see below). | No* |
databaseScripts.fileName | File name of each database script to be executed (.sql or .ddl). | No |
dataScripts.orderId | The order in which each database script will be executed, starting at 1. | No |
In addition to the JSON object below, the request should have the referenced files attached.
Request
1
POST /deployments
JSON object example
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
{
"name": "Fraud Investigation Management Release 1.0",
"description": "Base functionality to input and manage fraud cases",
"packageFileName": "Fraud Investigation Management.zip",
"customizationFileName": "Fraud Investigation Management.properties",
"pluginsFileName": "DEV Fraud Investigation Management Plug-ins.zip",
"dataSource": “jdbc/AppianAnywhere”,
"databaseScripts": [
{
"fileName": "Create Tables.sql", "orderId": "1"
},
{
"fileName": "Update Reference Data.sql", "orderId": "2"
}
]
}
cURL example
If you’re calling the API from a command line interface, you can use cURL to make a request. The cURL command with the above JSON object and its corresponding files looks like:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
curl --location --request
POST 'https://mysite.appiancloud.com/suite/deployment-management/v1/deployments' \
--header 'Appian-API-Key: <API key>' \
--form 'json="{
\"name\": \"Fraud Investigation Management Release 1.0\",
\"description\": \"Base functionality to input and manage fraud cases\",
\"packageFileName\": \"Fraud Investigation Management.zip\",
\"customizationFileName\": \"Fraud Investigation Management.properties\",
\"pluginsFileName": "DEV Fraud Investigation Management Plug-ins.zip\",
\"dataSource\": \"jdbc/AppianAnywhere\",
\"databaseScripts\": [
{
\"fileName\": \"Create Tables.sql\", \"orderId\": \"1\"
},
{
\"fileName\": \"Update Reference Data.sql\", \"orderId\": \"2\"
}
]
}"' \
--form 'randomKey1=@"Fraud Investigation Management Release 1.0.zip"' \
--form 'randomKey2=@"Fraud Investigation Management Release 1.0.properties"' \
--form 'randomKey3=@"Create Tables.sql"' \
--form 'randomKey4=@"Update Reference Data.sql"'
Each form parameter requires a key name, as indicated by randomKey1
, but these can be arbitrarily named and do not need to match anything in the JSON object.
Attribute | Value |
---|---|
uuid | UUID of the deployment. This can be used to retrieve details of the deployment. |
url | The URL to use to retrieve the details of the deployment. |
status | Status of the deployment. These correspond to the statuses that appear on the Deploy view in Appian Designer. Possible statuses: IN_PROGRESS, COMPLETED, COMPLETED_WITH_ERRORS, FAILED, PENDING_REVIEW, or REJECTED. |
1
2
3
4
5
{
"uuid": "d243b14c-3ba5-41c3-9f51-76da51beb8f5",
"url": "https://mysite.appiancloud.com/suite/deployment-management/v1/deployments/d243b14c-3ba5-41c3-9f51-76da51beb8f5/",
"status": "IN_PROGRESS"
}
Deployment API - Deploy Package