Skip to main content

linked_objects

Creates, updates, deletes, gets or lists a linked_objects resource.

Overview

Namelinked_objects
TypeResource
Idokta.users.linked_objects

Fields

The following fields are returned by SELECT queries:

NameDatatypeDescription
_linksobjectSpecifies link relations (see Web Linking) available using the JSON Hypertext Application Language specification. This object is used for dynamic discovery of related resources and lifecycle operations.

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
list_linked_objects_for_userselectsubdomainLists either the self link for the primary user or all associated users in the relationship specified by relationshipName. If the specified user isn't associated in any relationship, an empty array is returned.

Use me instead of id to specify the current session user.
assign_linked_object_value_for_primaryreplacesubdomainAssigns the first user as the associated and the second user as the primary for the specified relationship.

If the first user is already associated with a different primary for this relationship, the previous link is removed. A linked object relationship can specify only one primary user for an associated user.
delete_linked_object_for_userdeletesubdomainDeletes any existing relationship between the associated and primary user. For the associated user, this is specified by the ID. The primary name specifies the relationship.

The operation is successful if the relationship is deleted. The operation is also successful if the specified user isn't in the associated relationship for any instance of the specified primary and thus, no relationship is found.

Parameters

Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.

NameDatatypeDescription
subdomainstringThe domain of your organization. This can be a provided subdomain of an official okta domain (okta.com, oktapreview.com, etc) or one of your configured custom domains. (default: my-org)

SELECT examples

Lists either the self link for the primary user or all associated users in the relationship specified by relationshipName. If the specified user isn't associated in any relationship, an empty array is returned.

Use me instead of id to specify the current session user.

SELECT
_links
FROM okta.users.linked_objects
WHERE subdomain = '{{ subdomain }}' -- required;

REPLACE examples

Assigns the first user as the associated and the second user as the primary for the specified relationship.

If the first user is already associated with a different primary for this relationship, the previous link is removed. A linked object relationship can specify only one primary user for an associated user.

REPLACE okta.users.linked_objects
SET
-- No updatable properties
WHERE
subdomain = '{{ subdomain }}' --required;

DELETE examples

Deletes any existing relationship between the associated and primary user. For the associated user, this is specified by the ID. The primary name specifies the relationship.

The operation is successful if the relationship is deleted. The operation is also successful if the specified user isn't in the associated relationship for any instance of the specified primary and thus, no relationship is found.

DELETE FROM okta.users.linked_objects
WHERE subdomain = '{{ subdomain }}' --required;