Importing Exported Files
You can import already exported archives of APIs, global policies, and other related assets and re-create them in
API Gateway. For more information about exporting APIs, see
Exporting APIs. For information about exporting global policies, see
Exporting Global Policies.
Each artifact in an archive is associated with a universally unique identifier (UUID) across all API Gateway installations. When importing an archive, the UUID helps in determining whether the corresponding artifact is already available in API Gateway. In such a situation, you can specify whether to overwrite an already existing artifact during the import process.
You must have the API Gateway's import assets functional privilege assigned to import an archive.
Considerations while importing assets:
The APIs, applications, policies, and aliases you import become visible in API Gateway immediately.
Active APIs are replaced during import with the updated API and the API level policies.
The updated APIs and updated API level policies do not become effective for ongoing requests.
Active APIs are replaced during deployment with zero downtime without breaking ongoing requests.
Applications that you import become effective immediately; even the ongoing requests are affected.
Aliases and global policies that you import do not affect ongoing requests.
Note:
During export or import of assets, ensure that the master password is identical across stages and on different instances of API Gateway.
To import the exported files
Note:
You must import the authorization servers before you import the assets (such as applications) that depend on these authorization servers.
1. Expand the menu options icon , in the title bar, and select Import. 2. Provide the following information:
Parameter | Description |
Select archive file | Click Browse to select a file or ZIP format file. |
Advanced options | Select this option to overwrite either or all the following with the imported content: API Policy Applications Alias |
API version history | Select the option Fix missing versions to fix the API version history. On selecting this option, the API versions are newly linked according to the system version of the APIs. |
Note:
API Gateway supports backward compatibility for API Gateway 10.1 version or higher when importing the archives of APIs. If you want to use the archives of API Gateway 10.2 in versions 10.3 and higher, you must export them from API Gateway 10.2 fix 3 or higher.
3. Click Import.
The Import report displays the following information:
Parameter | Description |
Type | The artifact type. The available values are: API Policy Policy Actions Applications Alias |
Successful | The number of successful imports for each artifact type. |
Unsuccessful | The number of unsuccessful imports for each artifact type. |
Replaced | The number of instances replaced for each artifact type. |
Warning | The number of warnings displayed during the import of each artifact type. API Gateway displays warning messages when the import is successful but some additional information is required. |
4. Click Download the detail report here > to download the detail report.
The detail report displays the following information about the imported artifact:
Parameter | Description |
Name | The name of the artifact imported. |
Type | The artifact type. The available values are: API Policy Policy Actions Application Alias |
Status | The status of the imported artifact. The available values are: Success Replaced Warning Failure |
Explanation | The reason if the import fails or if a warning occurs. |
If you want to take a backup of an API that you want to overwrite during import, you can set the parameter
enableImportBackup as
true under
Administration >
General >
Extended Settings section. For more information about this extended setting, see
Configuring Extended Settings.
If an API import fails, one of the reasons might be that a configuration that is required by the API is not set up correctly on API Gateway. If something happens unexpectedly while the import is in progress, API Gateway discontinues the import and restores the existing API. This is necessary as parts of the existing API such as policies may already have been overwritten.