Migrate a proxy
POST https://{controlplane_path}/api/1/rest/public/apim/migrate_proxy
Overview
Migrate a proxy, including all its endpoints, policies, and files.
- The source environment must recognize the destination as a trusted environment.
- The destination environment must have at least the same security level as the source environment.
Prerequisites
- Read access to the source proxy
- Write access to the target Org
Request
POST https://{controlplane_path}/api/1/rest/public/apim/migrate_proxy
Example
This example uses basic authentication. For a JWT example, refer to Authentication.
curl -X 'POST' \
'https://elastic.snaplogic.com/api/1/rest/public/apim/migrate_proxy' \
-H 'Authorization: Basic {base64_encoded email:password}' \
-H 'Content-Type: application/json' \
-d '{
"source_org": "acme",
"source_proxy_name": "BookStore",
"dest_org": "acme-staging",
"dest_proxy_name": "BookStore",
"duplicate_check": true
}'
Path parameters
| Key | Description |
|---|---|
controlplane_path |
Required. The path to the SnapLogic control plane:
elastic.snaplogic.com
For the UAT or EMEA control plane, substitute the name for elastic. For
example:
|
Query parameters
None.
Request header
Use the application/json content type with basic authentication (email
and password) or a JWT. For examples, refer to Authentication.
Request body
{
"source_org" : "...",
"source_proxy_name" : "...",
"dest_org" : "...",
"dest_proxy_name" : "...",
"duplicate_check" : true
}
| Key | Type | Description |
|---|---|---|
source_org |
string | Required. The name of the source Environment/Org. |
source_proxy_name |
string | Required. The name of the source proxy. |
dest_org |
string | Required. The name of the destination Environment/Org. |
dest_proxy_name |
string | The name of the destination proxy. Required if migrating within the same Environment/Org. |
duplicate_check |
Boolean |
If If Default:
|
Response
{
"response_map": {
"source_proxy_path": "...",
"destination_proxy_path": "...",
"proxy_status": {
"deleted_duplicate_proxy": {
"proxy_path": "...",
"snode_id": "..."
},
"status": "...",
"snode_id": "...",
"migrated_policies": [ ... ],
"files": [
{
"status": "...",
"file_name": "...",
"file_path": "...",
"snode_id": "..."
}
]
},
"proxy_endpoint_status": {
"status": "...",
"proxy_endpoints": [
{
"myEndpoint1": {
"proxy_endpoint_path": "...",
"snode_id": "...",
"policies": [ ... ]
}
}
],
"reason": "..."
}
},
"http_status_code": 200
}
| Key | Type | Description |
|---|---|---|
source_proxy_path |
string | The path to the source proxy. Format:
|
destination_proxy_path |
string | The path to the destination proxy. Format:
|
proxy_status |
object | Information about the migration of the proxy and its policies. |
proxy_status » deleted_duplicate_proxy |
object | If duplicate_check was set to false, information about the existing proxy with the same name, if any, in the destination Environment/Org.
|
proxy_status » status |
string | The status of the migration of the proxy.
Possible values:
|
proxy_status » snode_id |
string | The ID of the JCC node that performed the operation. |
proxy_status » migrated_policies |
array | An array of strings containing the friendly names of the policies that were migrated with the proxy. |
proxy_status » files |
array | An array of objects containing information about the migrated files.
Each object contains the following information:
|
proxy_endpoint_status |
object | Information about the migration of the proxy's endpoints. |
proxy_endpoint_status » status |
string | The status of the migration of the proxy endpoints.
Possible values:
|
proxy_endpoint_status » proxy_endpoints |
array | An array of objects containing information about the migrated endpoints.
Each object contains a key-value pair.
|
reason |
string | If the migration failed, the reason for the failure. |
Error handling
| HTTP status codes | Message | Resolution |
|---|---|---|
| 400 | Not migrated | Check the reason in the response for details about the migration failure. |
| 401 | Unauthorized | Verify your credentials and permissions. |
| 409 | Proxy name exists where duplicate proxies are not permitted | Rename the proxy or remove the existing proxy at the destination. |