Skip to content

List all protected resources

Request

Lists all protected resources for a specific application in Access Gateway

Path
applicationIdstring, (uuid)required

Identifier of the application

curl -i -X GET \
  'https://oag.domain.tld/api/v2/apps/{applicationId}/resources'

Responses

Success

Bodyapplication/json
Array [
activeboolean

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

Default:true
assignedWeightinteger, [ 0 .. 100 ]

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.

Default:1
calculatedWeightnumber, (float)read-only

The calculated weight percentage that's based on the assigned weight distribution of all resources in the application. Values are represented as decimals. For example, 1.0 equals 100% distribution and 0.5 equals 50% distribution.

hostnamestring, (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.

idstring, (uuid)read-only

Unique identifier of the protected resource

]
Response
[ { "id": "c4cadb66-68fc-49cc-8dc4-719e97bd42e1", "hostname": "http://app1.internal.domain.tld", "assignedWeight": 1, "active": true, "calculatedWeight": 1 } ]