Create API Proxy from URL
Endpoint
POST /apiops/projects/{projectName}/apiProxies/url/
Authentication
Requires a Personal API Access Token.
Header
Authorization: Bearer YOUR_TOKEN
Request
Headers
| Header | Value | Required |
|---|---|---|
| Authorization | Bearer {token} | Yes |
| Content-Type | application/json | Yes |
Path Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| projectName | string | Yes | Project name |
Request Body
Full JSON Body Example
{
"apiProxyName": "petstore-api",
"apiProxyDescription": "Petstore API Proxy",
"apiProxyCreationType": "OPEN_API",
"specUrl": "https://petstore.swagger.io/v2/swagger.json",
"clientRoute": {
"relativePathList": ["/api/v1"],
"hostList": ["api.example.com"]
},
"routingInfo": {
"routingAddressList": [
{
"address": "https://backend.example.com",
"weight": 100,
"healthMonitoringEnabled": true
}
],
"loadBalanceAlgorithm": "ROUND_ROBIN",
"retryCount": 1
},
"deploy": false,
"deployTargetEnvironmentNameList": ["production"],
"reParse": false,
"soapToRest": false,
"enableWSA": false,
"enableWSRM": false,
"backendApiVersion": "v1",
"skipSslVerification": false,
"connectionTimeout": 30,
"maintenanceModeSetting": {
"enabled": false,
"httpStatusCode": 503,
"contentType": "application/json",
"message": "Service is under maintenance"
},
"specAuthorizationValueList": [
{
"keyName": "Authorization",
"value": "Bearer token123",
"type": "header"
}
]
}
Request Body Fields
| Field | Type | Required | Default | Description |
|---|---|---|---|---|
| apiProxyName | string | Yes | - | API Proxy name (must be unique within project) |
| apiProxyDescription | string | No | - | API Proxy description |
| apiProxyCreationType | string | Yes | - | API creation type |
| specUrl | string | Yes* | - | Specification URL (required if not reverse proxy) |
| clientRoute | object | No | - | Client route configuration |
| routingInfo | object | No | - | Routing configuration |
| deploy | boolean | No | false | Whether to deploy after creation |
| deployTargetEnvironmentNameList | array | No | [] | List of environment names to deploy to |
| reParse | boolean | No | false | Whether to reparse existing API proxy |
| soapToRest | boolean | No | false | Enable SOAP to REST transformation |
| enableWSA | boolean | No | false | Enable WS-Addressing (SOAP only) |
| enableWSRM | boolean | No | false | Enable WS-ReliableMessaging (SOAP only) |
| backendApiVersion | string | No | - | Backend API version |
| maintenanceModeSetting | object | No | - | Maintenance mode settings |
| specAuthorizationValueList | array | No | [] | Authorization headers for spec URL access |
| apiProxyGroupName | string | No | - | Name of the API Proxy Group to add the new API proxy to |
| skipSslVerification | boolean | No | true | Skip TLS certificate verification when fetching the specification from specUrl. Set it to false to verify the server certificate. Applies only when no truststore or certificate is given; an uploaded truststore, trustStoreName or certificateName takes precedence |
| connectionTimeout | integer | No | 30 | Timeout in seconds for fetching the specification |
| useSpecAuthorization | boolean | No | false | Use basic authentication when fetching the specification |
| specAuthUsername | string | No | - | Username for spec URL basic authentication (useSpecAuthorization=true) |
| specAuthPassword | string | No | - | Password for spec URL basic authentication (useSpecAuthorization=true) |
| trustStoreName | string | No | - | Name of an existing truststore used to verify the spec server certificate |
| uploadedTrustStoreContent | string | No | - | Truststore content (Base64) uploaded with the request, used instead of trustStoreName |
| uploadedTrustStorePassword | string | No | - | Password of the uploaded truststore |
| uploadedTrustStoreType | string | No | PKCS12 | Type of the uploaded truststore (JKS or PKCS12) |
| certificateName | string | No | - | Name of an existing certificate used for the spec server connection |
EnumApiProxySpecType
OPEN_API- OpenAPI 3.0 specificationSWAGGER- Swagger 2.0 specificationWSDL- WSDL specification (SOAP)REVERSE_PROXY- Reverse proxy (no spec file)EMPTY_API- No-Spec API (no spec file; endpoints are defined manually, see below)
Note: For REVERSE_PROXY and EMPTY_API, specUrl is not required.
No-Spec API (EMPTY_API)
Use apiProxyCreationType: "EMPTY_API" to create an API proxy without any specification file.
Unlike REVERSE_PROXY, endpoints are not inferred from a backend spec — after creation the
proxy is an empty REST proxy and each endpoint (API method) must be added individually via
Create Endpoint.
1. Create the proxy (no specUrl):
{
"apiProxyName": "nospec-api",
"apiProxyCreationType": "EMPTY_API",
"clientRoute": {
"relativePathList": ["/nospec"]
},
"routingInfo": {
"routingAddressList": [
{"address": "http://backend-host:port"}
]
}
}
2. Add endpoints (repeat per endpoint):
POST /apiops/projects/{projectName}/apiProxies/nospec-api/endpoints/
{
"name": "/login",
"httpMethod": "GET",
"backendResourceUrl": "/api/sonuc/login",
"backendHttpMethod": "GET"
}
3. Deploy using the standard Deploy API Proxy endpoint, or set deploy: true in step 1.
Critical rule: final URL = routingAddress + backendResourceUrl
The worker builds the backend request URL by concatenating routingInfo.routingAddressList[].address
(host only, no path) with the endpoint's backendResourceUrl (path only, no host). Putting a path
in both (e.g. address http://host:port/api/sonuc and backendResourceUrl: "/api/sonuc/login")
produces a broken duplicated path (http://host:port/api/sonuc/api/sonuc/login).
routingAddress:http://backend-host:port— host onlybackendResourceUrl:/api/sonuc/login— path only- Final backend URL:
http://backend-host:port+/api/sonuc/login
Unsupported for EMPTY_API:
PUT(reparse,reParse: true) — rejected, since there is no spec to reparse; update endpoints individually with Update Endpoint instead.- Create API Proxy from File /
its update variant — rejected, since those endpoints require a
specFile.
clientRoute
| Field | Type | Required | Description |
|---|---|---|---|
| relativePathList | array | No | List of relative paths (e.g., ["/api/v1"]) |
| hostList | array | No | List of virtual hosts (e.g., ["api.example.com"]) |
routingInfo
| Field | Type | Required | Default | Description |
|---|---|---|---|---|
| routingAddressList | array | No | - | List of backend addresses |
| loadBalanceAlgorithm | string | No | - | ROUND_ROBIN, LRU, WEIGHTED, RANDOM, PICK_FIRST |
| connectionSettingsEnabled | boolean | No | - | Enable custom connection settings (overrides system defaults) |
| connectTimeout | integer | No | - | Connection timeout in seconds |
| readTimeout | integer | No | - | Read timeout in seconds |
| connectionRequestTimeout | integer | No | - | Connection request timeout in seconds |
| validateAfterInactivity | integer | No | 2000 | Stale connection check interval (milliseconds) |
| idleConnectionTimeout | integer | No | 30 | Idle connection cleanup timeout (seconds) |
| redirectsEnabled | boolean | No | - | Follow HTTP redirects |
| maxRedirects | integer | No | - | Maximum number of redirects to follow |
| relativeRedirectsAllowed | boolean | No | - | Allow relative redirects |
| preserveHttpMethodOnRedirect | boolean | No | false | Preserve the HTTP method and body on 301/302/303/307/308 redirects |
| enableStreaming | boolean | No | - | Enable streaming for large responses |
| connectionPoolManagementType | string | No | - | GENERAL, CUSTOM, NONE |
| customConnectionPoolSize | integer | No | - | Pool size when connectionPoolManagementType=CUSTOM |
| retryCount | integer | No | 0 | Number of retries for failed requests |
| failoverRetryCount | integer | No | 0 | Number of retries during failover |
| retryDelayType | string | No | - | NO_DELAY, FIXED, EXPONENTIAL |
| retryFixedDelayMs | integer | No | - | Fixed delay between retries (milliseconds) |
| retryInitialDelayMs | integer | No | - | Initial delay for exponential backoff (milliseconds) |
| retryMaxDelayMs | integer | No | - | Maximum delay for exponential backoff (milliseconds) |
| retryBackoffMultiplier | number | No | - | Backoff multiplier for exponential delay |
| ignoreRoutingError | boolean | No | - | Pass backend error responses through without the error response template |
| stickySessionEnabled | boolean | No | - | Enable sticky sessions (session affinity) |
| stickyType | string | No | - | COOKIE_ONLY, IP_HASH, HYBRID |
| stickyCookieName | string | No | - | Cookie name for sticky sessions |
| stickyCookieTtl | integer | No | - | Cookie TTL in seconds |
| stickyCookieSecure | boolean | No | - | Set the Secure flag on the sticky session cookie |
| stickyCookieHttpOnly | boolean | No | - | Set the HttpOnly flag on the sticky session cookie |
| stickyHashSecret | string | No | - | Secret for IP-hash cookie signing |
| healthMonitoringCustomizationEnabled | boolean | No | - | Enable custom health check settings |
| healthCheckIntervalSeconds | integer | No | - | Health check interval in seconds |
| healthCheckTimeoutSeconds | integer | No | - | Health check timeout in seconds |
| healthCheckFailThreshold | integer | No | - | Consecutive failures before a backend is marked unhealthy |
| healthCheckPassThreshold | integer | No | - | Consecutive successes before a backend is marked healthy |
| trafficMirrorEnabled | boolean | No | - | Enable traffic mirroring to MIRROR-type addresses |
| mirrorPercentage | integer | No | - | Percentage of traffic to mirror (0-100) |
| mirrorIgnoreCircuitBreaker | boolean | No | - | Send mirrored requests even if the circuit breaker is open |
| mirrorRespectCircuitBreaker | boolean | No | - | Mirrored requests respect the circuit breaker state |
| canarySettings | object | No | - | Canary release settings |
| failoverOnlyEnabled | boolean | No | - | Enable failover-only mode for FAILOVER_ONLY-type addresses |
| queryEncodingMode | string | No | STANDARD | STANDARD, RFC3986, PASSTHROUGH — see Update Connection Settings |
routingAddressList Item
| Field | Type | Required | Default | Description |
|---|---|---|---|---|
| address | string | Yes | - | Backend address URL |
| weight | integer | No | 100 | Load balancing weight |
| healthMonitoringEnabled | boolean | No | false | Enable per-address health monitoring (HTTP type only) |
maintenanceModeSetting
| Field | Type | Required | Default | Description |
|---|---|---|---|---|
| enabled | boolean | No | false | Enable maintenance mode |
| httpStatusCode | integer | No | 503 | HTTP status code for maintenance |
| contentType | string | No | application/json | Content type for maintenance response |
| message | string | No | - | Maintenance message |
If the project has a default Global Settings Group that itself defines maintenance mode, the values sent here are immediately overwritten by that group's values once the proxy is created — the proxy is attached to the default group at creation time, and a group's values always take precedence over the proxy's own.
specAuthorizationValueList Item
| Field | Type | Required | Description |
|---|---|---|---|
| keyName | string | Yes | Header or query parameter name (e.g., "Authorization") |
| value | string | Yes | Value (e.g., "Bearer token123") |
| type | string | Yes | Value type: header or query |
Response
Success Response (200 OK)
{
"status": "SUCCESS",
"resultList": null,
"resultCount": null,
"deploymentResult": {
"envName": "production",
"podName": "",
"podIp": "",
"success": true,
"detail": "",
"responseTime": 123,
"detailList": []
}
}
When deploy: false or deployment targets are empty, deploymentResult is null.
Response Fields
| Field | Type | Description |
|---|---|---|
| status | string | SUCCESS if the request was successful |
| deploymentResult | object | Deployment result (present only if deploy=true and environments are specified) |
| deploymentResult.success | boolean | Overall deployment success |
| deploymentResult.detailList | array | Per-pod deployment results |
| deploymentResult.detailList[].envName | string | Environment name |
| deploymentResult.detailList[].success | boolean | Pod-level deployment success |
| deploymentResult.detailList[].detail | string | Detail message (on failure) |
Error Response (400 Bad Request)
{
"status": "FAILURE",
"resultMessage": "ApiProxy (name: petstore-api) is already exist!"
}
Common Causes
- API Proxy name already exists
- Invalid specification URL
- Invalid API creation type
- Invalid specification format
- Project not found or no permission
Error Response (401 Unauthorized)
{
"status": "FAILURE",
"resultMessage": "Token is not valid!"
}
cURL Example
curl -X POST \
"https://demo.apinizer.com/apiops/projects/MyProject/apiProxies/url/" \
-H "Authorization: Bearer YOUR_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"apiProxyName": "petstore-api",
"apiProxyDescription": "Petstore API Proxy",
"apiProxyCreationType": "OPEN_API",
"specUrl": "https://petstore.swagger.io/v2/swagger.json",
"clientRoute": {
"relativePathList": ["/api/v1"]
},
"deploy": false,
"reParse": false,
"soapToRest": false
}'
Permissions
User must have API_MANAGEMENT + MANAGE permission in the project. For deployment operations (when deploy: true is set), user must also have API_MANAGEMENT + DEPLOY_UNDEPLOY permission.
Notes and Warnings
- Unique Names: API Proxy names must be unique within a project
- Specification Access: Ensure the specification URL is accessible. Use
specAuthorizationValueListif authentication is required - Reparse: Set
reParse: trueto update an existing API proxy from a new specification - Deployment: If
deploy: true, ensure environments exist and user has deployment permissions. Environment names are validated before the API Proxy is created or re-parsed; an unknown name fails the request with400 Bad Requestand leaves the API Proxy untouched. When re-parsing an existing API Proxy, environments it is already deployed to are preserved and flagged as requiring a redeploy - SOAP Features:
enableWSAandenableWSRMare only applicable for SOAP APIs - Reverse Proxy: For reverse proxy,
specUrlis not required - License Limits: Creating API proxies may be subject to license limits
Related Documentation
- List API Proxies - List all API proxies
- Get API Proxy - Get API proxy details
- Update API Proxy - Update API proxy
- Deploy API Proxy - Deploy API proxy