Create an HTTP proxy configuration for an SVM or cluster IPspace
Sets up an HTTP proxy configuration for an SVM or cluster IPspace. This is useful when you need to route HTTP requests through a specific proxy for network management or security purposes.
HTTP method and endpoint
POST /network/http-proxy
Introduced in
ONTAP 9.7
Usage notes
Creates an HTTP proxy configuration for an SVM or a Cluster IPspace. Important notes:
-
IPv6 must be enabled if IPv6 family addresses are specified in the "server" field.
-
The server and the port combination specified using the "server" and "port" fields is validated during this operation. The validation will fail in the following scenarios:
-
The HTTP proxy service is not configured on the server.
-
The HTTP proxy service is not running on the specified port.
-
The server is unreachable.
-
Required properties
-
SVM-scoped HTTP proxy
-
svm.uuidorsvm.name- Existing SVM in which to create the HTTP proxy.
-
-
Cluster-scoped HTTP proxy
-
ipspace.uuidoripspace.name- Exisitng Cluster IPspace in which to create the HTTP proxy.
-
-
server- HTTP proxy server FQDN or IP address. -
port- HTTP proxy server port.
Optional properties
-
authentication_enabled- Specifies if authentication is required for the HTTP proxy server. -
username- Username used to authenticate with the HTTP proxy server. -
password- Password used to authenticate with the HTTP proxy server.
Related ONTAP commands
-
vserver http-proxy create
Parameters
| Name | Type | In | Required | Description |
|---|---|---|---|---|
return_records |
boolean |
query |
False |
The default is false. If set to true, the records are returned.
|
Request Body
| Name | Type | Description |
|---|---|---|
authentication_enabled |
boolean |
Specifies whether or not authentication with the HTTP proxy server is enabled. |
ipspace |
Applies to both SVM and cluster-scoped objects. Either the UUID or name is supplied on input. |
|
password |
string |
Password to authenticate with the HTTP proxy server when authentication_enabled is set to "true". |
port |
integer |
The port number on which the HTTP proxy service is configured on the proxy server. |
scope |
string |
Set to “svm” for HTTP proxy owned by an SVM. Otherwise, set to "cluster". |
server |
string |
Fully qualified domain name (FQDN) or IP address of the HTTP proxy server. |
svm |
||
username |
string |
Username to authenticate with the HTTP proxy server when authentication_enabled is set to "true". |
uuid |
string |
The UUID that uniquely identifies the HTTP proxy. |
Example request
{
"ipspace": {
"name": "exchange",
"uuid": "1cd8a442-86d1-11e0-ae1c-123478563412"
},
"password": "string",
"port": 3128,
"scope": "string",
"server": "string",
"svm": {
"name": "svm1",
"uuid": "02c9e252-41be-11e9-81d5-00a0986138f7"
},
"username": "string",
"uuid": "string"
}
Response
Status: 201, Created
| Name | Type | Description |
|---|---|---|
num_records |
integer |
Number of HTTP proxy records |
records |
array[network_http_proxy] |
Example response
{
"records": [
{
"ipspace": {
"name": "exchange",
"uuid": "1cd8a442-86d1-11e0-ae1c-123478563412"
},
"password": "string",
"port": 3128,
"scope": "string",
"server": "string",
"svm": {
"name": "svm1",
"uuid": "02c9e252-41be-11e9-81d5-00a0986138f7"
},
"username": "string",
"uuid": "string"
}
]
}
Error
Status: Default
ONTAP Error Response Codes
| Error Code | Description |
|---|---|
26214473 |
HTTP proxy configuration is not valid. |
26214476 |
The "IPspace" parameter should not be specified in the SVM context. |
26214477 |
The specified IPspace does not exist. |
23724130 |
Cannot use an IPv6 name server address because there are no IPv6 interfaces. |
26214481 |
Username and password cannot be empty when HTTP proxy authentication is enabled. |
26214482 |
Username and password cannot be specified when HTTP proxy authentication is disabled. |
Definitions
See Definitions
href
| Name | Type | Description |
|---|---|---|
href |
string |
_links
ipspace
Applies to both SVM and cluster-scoped objects. Either the UUID or name is supplied on input.
| Name | Type | Description |
|---|---|---|
name |
string |
IPspace name |
uuid |
string |
IPspace UUID |
svm
| Name | Type | Description |
|---|---|---|
name |
string |
The name of the SVM. |
uuid |
string |
The unique identifier of the SVM. |
network_http_proxy
| Name | Type | Description |
|---|---|---|
authentication_enabled |
boolean |
Specifies whether or not authentication with the HTTP proxy server is enabled. |
ipspace |
Applies to both SVM and cluster-scoped objects. Either the UUID or name is supplied on input. |
|
password |
string |
Password to authenticate with the HTTP proxy server when authentication_enabled is set to "true". |
port |
integer |
The port number on which the HTTP proxy service is configured on the proxy server. |
scope |
string |
Set to “svm” for HTTP proxy owned by an SVM. Otherwise, set to "cluster". |
server |
string |
Fully qualified domain name (FQDN) or IP address of the HTTP proxy server. |
svm |
||
username |
string |
Username to authenticate with the HTTP proxy server when authentication_enabled is set to "true". |
uuid |
string |
The UUID that uniquely identifies the HTTP proxy. |
error_arguments
| Name | Type | Description |
|---|---|---|
code |
string |
Argument code |
message |
string |
Message argument |
error
| Name | Type | Description |
|---|---|---|
arguments |
array[error_arguments] |
Message arguments |
code |
string |
Error code |
message |
string |
Error message |
target |
string |
The target parameter that caused the error. |