Application Protected Resources

The Protected Resources API allows you to retrieve and manage protected resources of your applications.

List all protected resources

Lists all protected resources for a specific application in Access Gateway

Request
path Parameters
applicationId
required
string <uuid>

Identifier of the application

Responses
200

Success

400

Bad Request

401

Unauthorized

403

Forbidden

429

Too Many Requests

get/api/v2/apps/{applicationId}/resources
Request samples
Response samples
application/json
[]

Create a protected resource

Creates a protected resource for an application in Access Gateway

Protected resources are resources that require authentication and authorization.

Request
path Parameters
applicationId
required
string <uuid>

Identifier of the application

Request Body schema: application/json
required
hostname
required
string <uri> ^https?://[a-zA-Z0-9.-]+(:[0-9]{1,5})?/?$

The hostname of the protected web resource URL

The URL must include the protocol, host, and port.

active
boolean
Default: true

Indicates whether the protected resource is active or not. If set to true, the resource is considered active and is used for routing requests.

assignedWeight
integer [ 0 .. 100 ]
Default: 1

The associated weight assigned to the protected resource. This weight is used to determine how requests are distributed among multiple protected resources.

You can assign a value from 0 to 100. 0 (zero) means that a host isn't in use.

For example, a weight value of 1 routes an equal number of requests to each protected web resource. A weight value of 2 routes twice as many requests to protected web resources with this weight than those with a weight of 1. If one protected web resource has a weight of 1 and the other has a weight of 2, 66% of the total requests are routed to the resource with a weight of 2.

Responses
200

Protected resource created successfully

400

Bad Request

401

Unauthorized

403

Forbidden

429

Too Many Requests

post/api/v2/apps/{applicationId}/resources
Request samples
application/json
Response samples
application/json
{}

Retrieve a protected resource

Retrieves details of a specific protected resource by applicationId and protectedResourceId

Request
path Parameters
applicationId
required
string <uuid>

Identifier of the application

protectedResourceId
required
string <uuid>

Identifier of the protected resource

Responses
200

Success

400

Bad Request

401

Unauthorized

403

Forbidden

404

Not Found

429

Too Many Requests

get/api/v2/apps/{applicationId}/resources/{protectedResourceId}
Request samples
Response samples
application/json
{}

Replace a protected resource

Replaces an existing protected resource configuration for an application

Request
path Parameters
applicationId
required
string <uuid>

Identifier of the application

protectedResourceId
required
string <uuid>

Identifier of the protected resource

Request Body schema: application/json
required
active
boolean
Default: true

Indicates whether the protected resource is active or not. If set to true, the resource is considered active and is used for routing requests.

assignedWeight
integer [ 0 .. 100 ]
Default: 1

The associated weight assigned to the protected resource. This weight is used to determine how requests are distributed among multiple protected resources.

You can assign a value from 0 to 100. 0 (zero) means that a host isn't in use.

For example, a weight value of 1 routes an equal number of requests to each protected web resource. A weight value of 2 routes twice as many requests to protected web resources with this weight than those with a weight of 1. If one protected web resource has a weight of 1 and the other has a weight of 2, 66% of the total requests are routed to the resource with a weight of 2.

hostname
string <uri> ^https?://[a-zA-Z0-9.-]+(:[0-9]{1,5})?/?$

The hostname of the protected web resource URL

The URL must include the protocol, host, and port.

Responses
200

Protected resource updated successfully

400

Bad Request

401

Unauthorized

403

Forbidden

404

Not Found

429

Too Many Requests

put/api/v2/apps/{applicationId}/resources/{protectedResourceId}
Request samples
application/json
Response samples
application/json
{}

Delete a protected resource

Deletes a protected resource for an application by applicationId and protectedResourceId

Request
path Parameters
applicationId
required
string <uuid>

Identifier of the application

protectedResourceId
required
string <uuid>

Identifier of the protected resource

Responses
204

Protected resource deleted successfully

400

Bad Request

401

Unauthorized

403

Forbidden

404

Not Found

429

Too Many Requests

delete/api/v2/apps/{applicationId}/resources/{protectedResourceId}
Request samples
Response samples
application/json
{
  • "details": { },
  • "errorCode": "BAD_REQUEST",
  • "message": "Request validation failed"
}