Difference between revisions of "REST API: delegation Resource"
From AgileApps Support Wiki
imported>Aeric (Created page with "Performs actions related to delegating your own profile and those of your direct reports to a proxy user. A proxy user should be able to perform the same activities as his or her...") |
imported>Aeric |
||
(11 intermediate revisions by the same user not shown) | |||
Line 4: | Line 4: | ||
{{Note| Users should have the Manage Delegations permissions.}} | {{Note| Users should have the Manage Delegations permissions.}} | ||
=== | ===Add a User for Delegation=== | ||
Allows you to add users to the Delegated users list. | |||
;Method:POST | ;Method:POST | ||
;URI:<tt>{ | ;URI:<tt>https://{yourDomain}/networking/rest/delegation/</tt> | ||
;Request: | ;Request: | ||
:<syntaxhighlight lang="html4strict" enclose="div"> | :<syntaxhighlight lang="html4strict" enclose="div"> | ||
<platform> | <platform> | ||
<delegation> | |||
<active>false</active> | |||
<applicationId>08455b174ee14b26859c44c60f2ceb7b</applicationId> | |||
<createdId> | |||
<content>b2c6fb3b59ba4f9a9c212f20be284df5</content> | |||
<displayValue>Fix Fix2</displayValue> | |||
<type>USER</type> | |||
<uri>https://localhost/networking/rest/user/b2c6fb3b59ba4f9a9c212f20be284df5</uri> | |||
</createdId> | |||
<dateCreated>2018-07-26T00:46:41.000Z</dateCreated> | |||
<dateModified>2018-07-26T06:09:09.000Z</dateModified> | |||
<delegateAccessProfile>false</delegateAccessProfile> | |||
<delegatee> | |||
<content>b2c6fb3b59ba4f9a9c212f20be284df5</content> | |||
<displayValue>Fix Fix2</displayValue> | |||
<type>USER</type> | |||
<uri>https://localhost/networking/rest/user/b2c6fb3b59ba4f9a9c212f20be284df5</uri> | |||
</delegatee> | |||
<id>ee35804e4c2942b999d8b5521e786fd7</id> | |||
<modifiedId> | |||
<content>b2c6fb3b59ba4f9a9c212f20be284df5</content> | |||
<displayValue>Fix Fix2</displayValue> | |||
<type>USER</type> | |||
<uri>https://localhost/networking/rest/user/b2c6fb3b59ba4f9a9c212f20be284df5</uri> | |||
</modifiedId> | |||
<prinicpalUser> | |||
<content>792a8e8725104cb58e5d337ea730f59b</content> | |||
<displayValue>Fit fit</displayValue> | |||
<type>USER</type> | |||
<uri>https://localhost/networking/rest/user/792a8e8725104cb58e5d337ea730f59b</uri> | |||
</platform> | </prinicpalUser> | ||
<roleId> | |||
<content>18d2099643e64deab4a174dc113a5174</content> | |||
<displayValue>Agent</displayValue> | |||
<type>ROLE</type> | |||
<uri>https://localhost/networking/rest/role/18d2099643e64deab4a174dc113a5174</uri> | |||
</roleId> | |||
<roleId> | |||
<content>c7b03526a90c44cdbbfdaa4e5564c6a9</content> | |||
<displayValue>Manager</displayValue> | |||
<type>ROLE</type> | |||
<uri>https://localhost/networking/rest/role/c7b03526a90c44cdbbfdaa4e5564c6a9</uri> | |||
</roleId> | |||
</delegation> | |||
</platform> | |||
</syntaxhighlight> | </syntaxhighlight> | ||
;Response: | ;Response: | ||
:<syntaxhighlight lang="html4strict" enclose="div"> | :<syntaxhighlight lang="html4strict" enclose="div"> | ||
<platform> | <platform> | ||
<message> | |||
<code>0</code> | |||
<description>Success</description> | |||
<id><delegationId></id> | |||
</message> | |||
</platform> | </platform> | ||
</syntaxhighlight> | </syntaxhighlight> | ||
:See also: [[REST API:Error Codes]] | :See also: [[REST API:Error Codes]] | ||
=== | ===Retrieve the Delegated Users list=== | ||
Retrieves the list of delegated users. | |||
;Method: | ;Method:GET | ||
;URI:<tt> | ;URI:<tt>https://{yourDomain}/networking/rest/delegation/<delegationId></tt> | ||
;Response: | ;Response: | ||
:<syntaxhighlight lang="html4strict" enclose="div"> | :<syntaxhighlight lang="html4strict" enclose="div"> | ||
<platform> | <platform> | ||
<delegation> | |||
<active>false</active> | |||
<applicationId>08455b174ee14b26859c44c60f2ceb7b</applicationId> | |||
<createdId> | |||
<content>b2c6fb3b59ba4f9a9c212f20be284df5</content> | |||
</platform> | <displayValue>Fix Fix2</displayValue> | ||
<type>USER</type> | |||
<uri>https://localhost/networking/rest/user/b2c6fb3b59ba4f9a9c212f20be284df5</uri> | |||
</createdId> | |||
<dateCreated>2018-07-26T00:46:41.000Z</dateCreated> | |||
<dateModified>2018-07-26T06:09:09.000Z</dateModified> | |||
<delegateAccessProfile>false</delegateAccessProfile> | |||
<delegatee> | |||
<content>b2c6fb3b59ba4f9a9c212f20be284df5</content> | |||
<displayValue>Fix Fix2</displayValue> | |||
<type>USER</type> | |||
<uri>https://localhost/networking/rest/user/b2c6fb3b59ba4f9a9c212f20be284df5</uri> | |||
</delegatee> | |||
<id>ee35804e4c2942b999d8b5521e786fd7</id> | |||
<modifiedId> | |||
<content>b2c6fb3b59ba4f9a9c212f20be284df5</content> | |||
<displayValue>Fix Fix2</displayValue> | |||
<type>USER</type> | |||
<uri>https://localhost/networking/rest/user/b2c6fb3b59ba4f9a9c212f20be284df5</uri> | |||
</modifiedId> | |||
<prinicpalUser> | |||
<content>792a8e8725104cb58e5d337ea730f59b</content> | |||
<displayValue>Fit fit</displayValue> | |||
<type>USER</type> | |||
<uri>https://localhost/networking/rest/user/792a8e8725104cb58e5d337ea730f59b</uri> | |||
</prinicpalUser> | |||
<roleId> | |||
<content>18d2099643e64deab4a174dc113a5174</content> | |||
<displayValue>Agent</displayValue> | |||
<type>ROLE</type> | |||
<uri>https://localhost/networking/rest/role/18d2099643e64deab4a174dc113a5174</uri> | |||
</roleId> | |||
<roleId> | |||
<content>c7b03526a90c44cdbbfdaa4e5564c6a9</content> | |||
<displayValue>Manager</displayValue> | |||
<type>ROLE</type> | |||
<uri>https://localhost/networking/rest/role/c7b03526a90c44cdbbfdaa4e5564c6a9</uri> | |||
</roleId> | |||
</delegation> | |||
<message> | |||
<code>0</code> | |||
<description>Success</description> | |||
</message> | |||
</platform> | |||
</syntaxhighlight> | </syntaxhighlight> | ||
:See also: [[REST API:Error Codes]] | :See also: [[REST API:Error Codes]] | ||
===Update | ===Update the List of Delegated Users=== | ||
Allows you to update the list of delegated users. | |||
;Method:PUT | |||
;URI:<tt>https://{yourDomain}/networking/rest/delegation/<delegationId></tt> | |||
;Response | ;Response | ||
:<syntaxhighlight lang="html4strict" enclose="div"> | :<syntaxhighlight lang="html4strict" enclose="div"> | ||
<platform> | <platform> | ||
<message> | |||
<code>0</code> | |||
<description>Success</description> | |||
<id><delegationId></id> | |||
</message> | |||
</platform> | |||
; | |||
; | |||
</platform> | |||
</syntaxhighlight> | </syntaxhighlight> | ||
:See also: [[REST API:Error Codes]] | :See also: [[REST API:Error Codes]] | ||
===Delete a Delegated User=== | |||
Allows you to delete a delegated user. | |||
===Delete a User | |||
;Method:DELETE | ;Method:DELETE | ||
;URI:<tt>{ | ;URI:<tt>https://{yourDomain}/networking/rest/delegation/<delegationId></tt> | ||
;Response: | ;Response: | ||
:<syntaxhighlight lang="html4strict" enclose="div"> | :<syntaxhighlight lang="html4strict" enclose="div"> | ||
<platform> | <platform> | ||
<message> | |||
<code>0</code> | |||
<description>Success</description> | |||
</message> | |||
</platform> | </platform> | ||
</syntaxhighlight> | </syntaxhighlight> | ||
Line 394: | Line 167: | ||
:* In this object, Boolean fields accept either 1/0 or TRUE/FALSE | :* In this object, Boolean fields accept either 1/0 or TRUE/FALSE | ||
:* Because there are so many fields, and so many of them can be empty, empty fields generally are ''not returned'' as part of user data. However, they can still be specified for an update. | :* Because there are so many fields, and so many of them can be empty, empty fields generally are ''not returned'' as part of user data. However, they can still be specified for an update. | ||
:*Role list appears in the API output or considered as input only when the Switch Roles permission is enabled in company information. | |||
:*Role ID value "-1" means ALL Roles. | |||
:{| border="1" cellpadding="5" cellspacing="0" | :{| border="1" cellpadding="5" cellspacing="0" | ||
! Name!!Type | ! Name !! Type !! Description !! Additional Information | ||
|- | |- | ||
| | | Active || Boolean|| Indicates if a delegation is active or inactive. || TRUE means a delegation is active and FALSE means the delegatee is not shown in the list of delegatees during the run time Become Delegate action. | ||
|- | |- | ||
| | | applicationId || String|| The ID of an application || | ||
|- | |- | ||
| | | createdID || Lookup || This is the user ID bean || User ID | ||
|- | |- | ||
| | | dateCreated || Date || Date of delegation creation or resource creation || | ||
|- | |- | ||
| | | dateModified || Date || Date the delegation role is applied || [[UTC Format]] | ||
|- | |- | ||
| | | delegateAccessProfile || Boolean || Allows you to manage the delegation when set to TRUE. || | ||
|| | |||
|- | |- | ||
| | | delegatee || String || User receiving the delegation from a Principal User. || | ||
| | |||
|- | |- | ||
| | | id|| String ||The ID for this record|| | ||
|- | |- | ||
| | | modifiedId|| Lookup ||The ID of the record used for updating the resource|| User ID | ||
|- | |- | ||
| | | principalUser|| String || The user delegating the profile to a Delegate User || | ||
|- | |- | ||
| | | roleId|| String || The particular role of the principal user which is delegated to the delegatee|| | ||
|} | |||
| | |||
| | |||
<noinclude> | <noinclude> | ||
[[Category:REST API| | [[Category:REST API|Session Management Resources]] | ||
</noinclude> | </noinclude> |
Latest revision as of 12:11, 14 August 2018
Performs actions related to delegating your own profile and those of your direct reports to a proxy user. A proxy user should be able to perform the same activities as his or her supervisor depending on the role(s) delegated to him or her.
Access Permissions
Add a User for Delegation
Allows you to add users to the Delegated users list.
- Method
- POST
- URI
- https://{yourDomain}/networking/rest/delegation/
- Request
<platform> <delegation> <active>false</active> <applicationId>08455b174ee14b26859c44c60f2ceb7b</applicationId> <createdId> <content>b2c6fb3b59ba4f9a9c212f20be284df5</content> <displayValue>Fix Fix2</displayValue> <type>USER</type> <uri>https://localhost/networking/rest/user/b2c6fb3b59ba4f9a9c212f20be284df5</uri> </createdId> <dateCreated>2018-07-26T00:46:41.000Z</dateCreated> <dateModified>2018-07-26T06:09:09.000Z</dateModified> <delegateAccessProfile>false</delegateAccessProfile> <delegatee> <content>b2c6fb3b59ba4f9a9c212f20be284df5</content> <displayValue>Fix Fix2</displayValue> <type>USER</type> <uri>https://localhost/networking/rest/user/b2c6fb3b59ba4f9a9c212f20be284df5</uri> </delegatee> <id>ee35804e4c2942b999d8b5521e786fd7</id> <modifiedId> <content>b2c6fb3b59ba4f9a9c212f20be284df5</content> <displayValue>Fix Fix2</displayValue> <type>USER</type> <uri>https://localhost/networking/rest/user/b2c6fb3b59ba4f9a9c212f20be284df5</uri> </modifiedId> <prinicpalUser> <content>792a8e8725104cb58e5d337ea730f59b</content> <displayValue>Fit fit</displayValue> <type>USER</type> <uri>https://localhost/networking/rest/user/792a8e8725104cb58e5d337ea730f59b</uri> </prinicpalUser> <roleId> <content>18d2099643e64deab4a174dc113a5174</content> <displayValue>Agent</displayValue> <type>ROLE</type> <uri>https://localhost/networking/rest/role/18d2099643e64deab4a174dc113a5174</uri> </roleId> <roleId> <content>c7b03526a90c44cdbbfdaa4e5564c6a9</content> <displayValue>Manager</displayValue> <type>ROLE</type> <uri>https://localhost/networking/rest/role/c7b03526a90c44cdbbfdaa4e5564c6a9</uri> </roleId> </delegation> </platform>
- Response
<platform> <message> <code>0</code> <description>Success</description> <id><delegationId></id> </message> </platform>
- See also: REST API:Error Codes
Retrieve the Delegated Users list
Retrieves the list of delegated users.
- Method
- GET
- URI
- https://{yourDomain}/networking/rest/delegation/<delegationId>
- Response
<platform> <delegation> <active>false</active> <applicationId>08455b174ee14b26859c44c60f2ceb7b</applicationId> <createdId> <content>b2c6fb3b59ba4f9a9c212f20be284df5</content> <displayValue>Fix Fix2</displayValue> <type>USER</type> <uri>https://localhost/networking/rest/user/b2c6fb3b59ba4f9a9c212f20be284df5</uri> </createdId> <dateCreated>2018-07-26T00:46:41.000Z</dateCreated> <dateModified>2018-07-26T06:09:09.000Z</dateModified> <delegateAccessProfile>false</delegateAccessProfile> <delegatee> <content>b2c6fb3b59ba4f9a9c212f20be284df5</content> <displayValue>Fix Fix2</displayValue> <type>USER</type> <uri>https://localhost/networking/rest/user/b2c6fb3b59ba4f9a9c212f20be284df5</uri> </delegatee> <id>ee35804e4c2942b999d8b5521e786fd7</id> <modifiedId> <content>b2c6fb3b59ba4f9a9c212f20be284df5</content> <displayValue>Fix Fix2</displayValue> <type>USER</type> <uri>https://localhost/networking/rest/user/b2c6fb3b59ba4f9a9c212f20be284df5</uri> </modifiedId> <prinicpalUser> <content>792a8e8725104cb58e5d337ea730f59b</content> <displayValue>Fit fit</displayValue> <type>USER</type> <uri>https://localhost/networking/rest/user/792a8e8725104cb58e5d337ea730f59b</uri> </prinicpalUser> <roleId> <content>18d2099643e64deab4a174dc113a5174</content> <displayValue>Agent</displayValue> <type>ROLE</type> <uri>https://localhost/networking/rest/role/18d2099643e64deab4a174dc113a5174</uri> </roleId> <roleId> <content>c7b03526a90c44cdbbfdaa4e5564c6a9</content> <displayValue>Manager</displayValue> <type>ROLE</type> <uri>https://localhost/networking/rest/role/c7b03526a90c44cdbbfdaa4e5564c6a9</uri> </roleId> </delegation> <message> <code>0</code> <description>Success</description> </message> </platform>
- See also: REST API:Error Codes
Update the List of Delegated Users
Allows you to update the list of delegated users.
- Method
- PUT
- URI
- https://{yourDomain}/networking/rest/delegation/<delegationId>
- Response
<platform> <message> <code>0</code> <description>Success</description> <id><delegationId></id> </message> </platform>
- See also: REST API:Error Codes
Delete a Delegated User
Allows you to delete a delegated user.
- Method
- DELETE
- URI
- https://{yourDomain}/networking/rest/delegation/<delegationId>
- Response
<platform> <message> <code>0</code> <description>Success</description> </message> </platform>
- See also: REST API:Error Codes
Fields
- Notes:
- In this object, Boolean fields accept either 1/0 or TRUE/FALSE
- Because there are so many fields, and so many of them can be empty, empty fields generally are not returned as part of user data. However, they can still be specified for an update.
- Role list appears in the API output or considered as input only when the Switch Roles permission is enabled in company information.
- Role ID value "-1" means ALL Roles.
Name Type Description Additional Information Active Boolean Indicates if a delegation is active or inactive. TRUE means a delegation is active and FALSE means the delegatee is not shown in the list of delegatees during the run time Become Delegate action. applicationId String The ID of an application createdID Lookup This is the user ID bean User ID dateCreated Date Date of delegation creation or resource creation dateModified Date Date the delegation role is applied UTC Format delegateAccessProfile Boolean Allows you to manage the delegation when set to TRUE. delegatee String User receiving the delegation from a Principal User. id String The ID for this record modifiedId Lookup The ID of the record used for updating the resource User ID principalUser String The user delegating the profile to a Delegate User roleId String The particular role of the principal user which is delegated to the delegatee