PingAuthorize API Reference

Targets

Targets define the conditions that determine when policies and rules apply to decision requests.

Targets enable the decision service to evaluate whether a policy or rule is relevant to a specific request. If a target’s condition is true, the rule or policy will be evaluated. Otherwise, the rule or policy is not applicable to the decision request. The library makes targeting logic available for easy reuse across policies and rules.

The targets endpoint provides operations for creating, reading, updating, and deleting policy targets. Each operation requires either a branch ID or a statement ID in the request URL.

You can combine targets with conditions comparing requests, attributes, constant values, and regular expressions. For more information, refer to Conditions in the PingAuthorize Policy Administration Guide.

Targets data model

Property Type Required Mutable Description

id

String

N/A

Read-only

Specifies the ID of the target.

version

String

N/A

Read-only

Specifies the version ID of the target to update.

type

String

Optional

Mutable

Specifies the resource type. Always set to target.

name

String

Required

Mutable

Specifies the name of the target.

description

String

Optional

Mutable

Provides a description of the target.

shared

Boolean

Optional

Mutable

A boolean that determines whether the target is shared between policy entities or not.

disabled

Boolean

Optional

Mutable

A boolean that determines whether the target is disabled or not.

targeted

Object{}

Optional

Mutable

Specifies a list of object collections mapping definition types to entity IDs. For example, {"actions": ["b072d76e-0085-4423-99c2-4e16b74e88fa"]}. The allowed definition types are actions, services, domains, and identityClasses.

effectivePermissions

JSON[]

N/A

Read-only

Specifies a list of permissions assigned to the statement. Each permission object contains the following fields:
* permission: The operation for which permission is enabled. For example, READ.
* role: The role to which the permission is assigned.

definedOn

String

N/A

Read-only

Specifies the unique ID of the target to which permissions are assigned.

inherited

Boolean

N/A

Read-only

Specifies whether or not permissions are inherited from a parent entity.

pageHeader.entityId

UUID

N/A

Read-only

Specifies the unique ID of the target for which a version history is being retrieved.

pageHeader.entityType

String

N/A

Read-only

Specifies the type of entity for which a version history is being retrieved.

version

UUID

N/A

Read-only

Specifies the unique ID of a target version.

deltaId

UUID

N/A

Read-only

Specifies the unique ID of a snapshot delta.

snapshotId

UUID

N/A

Read-only

Specifies the unique ID of a snapshot.

timestamp

String

N/A

Read-only

Specifies the date and time at which a delta was generated.

user

String

N/A

Read-only

Specifies the user who was signed in when the delta was generated.

Response codes

Code Message

200

Successful operation.

400

A valid branch or snapshot has not been specified.

400

The target ID is not formatted correctly.

404

The target with the provided ID was not found.

409

The ID in the URL and the ID in the request body do not match.

409

The target with the given ID is referred to elsewhere in the system and cannot be deleted until all such references are removed.