2 - Create an Api From Exchange
POST {{anypoint_host}}/apimanager/api/v1/organizations/:organizationId/environments/:environmentId/apis/
This request:
- creates an API in Api Manager from an existing Exchange API (check body of the request)
        spec
: {
        assetId
: {{exchangeAssetId}}
,
        groupId
: {{org_id}}
,
        version
: 1.0.0
        }
- sets the apiId Qodex environment variable (this is the id of the api in api manager)
Request Body
{"endpoint"=>{"deploymentType"=>"CH", "isCloudHub"=>true, "muleVersion4OrAbove"=>true, "proxyUri"=>"http://0.0.0.0:8081/", "proxyTemplate"=>{"assetVersion"=>"2.1.0"}, "referencesUserDomain"=>false, "responseTimeout"=>nil, "type"=>"rest", "uri"=>"https://petstore.swagger.io/v2", "validation"=>"ENABLED"}, "providerId"=>nil, "tags"=>["internal", "test"], "instanceLabel"=>"Sandbox {{exchangeAssetId}}", "spec"=>{"assetId"=>"{{exchangeAssetId}}", "groupId"=>"{{org_id}}", "version"=>"1.0.0"}}
HEADERS
| Key | Datatype | Required | Description | 
|---|---|---|---|
| Authorization | string | ||
| Content-Type | string |