# 导出 API 网关的定义

导出与 AWS API Gateway 或 Azure API Management 兼容的 API 定义。

1. 打开要导出的 API 版本。
2. 单击导出。
3. 单击 OpenAPI Specification 并选择 AWS API Gateway 或 Azure API Management。

   如果要将 API 导出到其他网关（例如 Apigee），建议选择 Standard OAS。![选择规范菜单。](https://help.qlik.com/zh-CN/cloud-services/Subsystems/Hub/Content/Resources/Images/ApiDesigner/api-definition-specification.png)
4. 选择 OAS 版本和格式。

   由于 API 网关不支持 Talend 扩展，因此默认选择 No extensions 且无法修改。![自定义菜单。](https://help.qlik.com/zh-CN/cloud-services/Subsystems/Hub/Content/Resources/Images/ApiDesigner/designer_export_gateway.png)
5. 如果不想导出整个 API，请单击 Filter export 并选择要导出的操作。

   筛选导出时，无论选择哪些操作，都会导出所有数据类型、组件和资源。

   信息注释注意：

   即使资源不包含任何操作或其操作被筛选掉，也会导出资源。例如，在下图中，/contact/{contactid} 资源中的所有操作都被筛选掉，但该路径仍显示在导出的文件中：
   ```
   "/contacts/{contactid}" : {
         "parameters" : [ {
           "$ref" : "#/components/parameters/contactid"
         } ]
       }
   ```

   导入包含无操作路径的文件时，AWS API Gateway 会显示警告，但这不会阻止导入。

   ![选择操作选项。](https://help.qlik.com/zh-CN/cloud-services/Subsystems/Hub/Content/Resources/Images/ApiDesigner/api-definition-operations.png)
6. 单击导出。