Replaces the sharing configuration of a dynamic report.
Use this endpoint to share a dynamic report, change who it is shared with, or unshare it.
The request replaces the full configuration: users or groups omitted from the lists are unshared.
To unshare completely, send SharedWithEveryone false with empty SharedUserIds and SharedUserGroupIds.
When SharedWithEveryone is true, both lists must be empty. Every supplied user and user group ID must exist, otherwise the request fails with 404.
Only the report’s creator (with Shared Reports Create permission), or a report administrator when the report is already shared, may change sharing.
Recipients gain read and run access and may copy the report via POST /api/v202607/dynamicReporting/{reportId}/copy, but cannot edit or delete it.
Request Headers
| Header | Value | Required | Description |
|---|---|---|---|
| ECI-ApiKey | string | Yes | Your API key. See Authentication. |
| Content-Type | application/json | Yes | All requests must specify JSON content type, including the request body. |
Path Parameters
| Name | Description | Type | Required |
|---|---|---|---|
| reportId | Unique numeric identifier of the dynamic report to share. | integer (int32) | Required |
Request Body
ShareRequest
| Property | Description | Type |
|---|---|---|
| sharedUserGroupIds | The list of user group ids an item should be shared with Should be an empty list [], when SharedWithEveryone is true Required | integer[] |
| sharedUserIds | The list of individual user ids an item should be shared with Should be an empty list [], when SharedWithEveryone is true Required | integer[] |
| sharedWithEveryone | Set to True to share the item everyone When true, SharedUsers and SharedUserGroups should be set to empty lists [] Required | boolean |
Example Request Body
{ "sharedUserGroupIds": [
1
], "sharedUserIds": [
1
], "sharedWithEveryone": false
}
Responses
200
OK
The request succeeded and the response body contains the requested data.
Response Body Parameters
ShareResponse
| Property | Description | Type | ||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| sharedUserGroups | The list of user groups an item has been assigned to be shared with | UserGroupChild[] | ||||||||||||
|
UserGroupChild properties
|
||||||||||||||
| sharedUsers | The list of individual users an item has been assigned to be shared with This does NOT take into account users that are in a shared user group | UserChild[] | ||||||||||||
|
UserChild properties
|
||||||||||||||
| sharedWithEveryone | True if the item is shared with everyone | boolean | ||||||||||||
Example Response
{ "sharedUserGroups": [
{ "userGroupId": 1, "userGroupName": "string"
}
], "sharedUsers": [
{ "fullName": "string", "userCode": "string", "userId": 1
}
], "sharedWithEveryone": false
}
400
Bad Request
The request was malformed or contains invalid parameters. Check the request body and query parameters.
403
Forbidden
You do not have permission to access this resource. Check your user role and permissions.
404
Not Found
The requested resource was not found. Verify the ID or path is correct.