Associate a user with a study role

put

/ec-auth-svc/rest/v2.0/authusers/{userid}/studies/{StudyID}

Updates the list if user roles are based on the studyRole parameter.

Request

Path Parameters
Supported Media Types
Request Body - application/json ()
Root Schema : schema
Type: object
Request payload to update user study mode roles.
Show Source
Example:
{
    "effectiveStart":"2020-06-17T10:15:30.000Z",
    "effectiveEnd":"2025-06-17T10:15:30.000Z",
    "modes":[
        {
            "modeName":"active",
            "StudyRoleID":"1BC29B36F5D64B1B95F4BDBBCEA481BE",
            "sites":{
                "allSites":false,
                "associatedSites":[
                    "946E7D36031941CCA39CD2B2CFF2899B",
                    "FE8925CFA8A74193A2E8D8326E7FEA88"
                ]
            },
            "depots":{
                "allDepots":false,
                "associatedDepots":[
                    "CEE624A4E7EB43059C6AEC24673A288B"
                ]
            }
        }
    ]
}
Nested Schema : modes
Type: object
Update details for a user mode assignment in request payload.
Show Source
Example:
{
    "modeName":"active",
    "StudyRoleID":"1BC29B36F5D64B1B95F4BDBBCEA481BE",
    "sites":{
        "allSites":false,
        "associatedSites":[
            "946E7D36031941CCA39CD2B2CFF2899B",
            "FE8925CFA8A74193A2E8D8326E7FEA88"
        ]
    },
    "depots":{
        "allDepots":false,
        "associatedDepots":[
            "CEE624A4E7EB43059C6AEC24673A288B"
        ]
    }
}
Nested Schema : DepotsListDto
Type: object
DTO containing the set of depot UUIDs assigned to the user in a study/mode context.
Show Source
Nested Schema : SitesListDto
Type: object
Title: SitesListDto
DTO containing the set of site UUIDs assigned to the user in a study/mode context.
Show Source
Nested Schema : associatedDepots
Type: array
A list of UUIDs identifying depots assigned to the user.
Show Source
Example:
[
    "6E697AEB85A24A22B38C70495A0A5C48",
    "6E697AEB85A24A22B38C70495A0A5C49"
]
Nested Schema : associatedSites
Type: array
A list of UUIDs identifying sites assigned to the user.
Show Source
Example:
[
    "6E697AEB85A24A22B38C70495A0A5C48",
    "4E9523BF795D4FE4AB9BF1EF8A340FAB"
]
Examples

Back to Top

Response

Supported Media Types

200 Response

Success
Body ()
Root Schema : DisplayUserStudyModeRoleListDtoV2
Type: object
Represents a user's study mode roles with effective period and modes.
Show Source
Example:
{
    "effectiveStart":"2020-06-17T10:15:30.000Z",
    "effectiveEnd":"2025-06-17T10:15:30.000Z",
    "modes":[
        {
            "modeName":"active",
            "roles":[
                {
                    "id":"F7A0E5390A1F43A9AF5346EB88AC921A",
                    "roleName":"Rule Designer"
                },
                {
                    "id":"EA0D45A19A6E45CDAAD5F2DB7BD4E104",
                    "roleName":"Site User"
                }
            ],
            "studyRole":{
                "id":"1BC29B36F5D64B1B95F4BDBBCEA481BE",
                "studyRoleName":"LEAD_INVESTIGATOR"
            },
            "sites":{
                "allSites":false,
                "associatedSites":[
                    {
                        "id":"946E7D36031941CCA39CD2B2CFF2899B",
                        "siteName":"SiteA"
                    },
                    {
                        "id":"FE8925CFA8A74193A2E8D8326E7FEA88",
                        "siteName":"SiteB"
                    }
                ]
            },
            "depots":{
                "allDepots":false,
                "associatedDepots":[
                    {
                        "id":"CEE624A4E7EB43059C6AEC24673A288B",
                        "depotName":"DepotA"
                    }
                ]
            }
        }
    ]
}
Nested Schema : modes
Type: object
Represents a user mode assignment with site, role and depot details.
Show Source
Example:
{
    "modeName":"active",
    "roles":[
        {
            "id":"F7A0E5390A1F43A9AF5346EB88AC921A",
            "roleName":"Rule Designer"
        },
        {
            "id":"EA0D45A19A6E45CDAAD5F2DB7BD4E104",
            "roleName":"Site User"
        }
    ],
    "studyRole":{
        "id":"1BC29B36F5D64B1B95F4BDBBCEA481BE",
        "studyRoleName":"LEAD_INVESTIGATOR"
    },
    "sites":{
        "allSites":false,
        "associatedSites":[
            {
                "id":"946E7D36031941CCA39CD2B2CFF2899B",
                "siteName":"SiteA"
            },
            {
                "id":"FE8925CFA8A74193A2E8D8326E7FEA88",
                "siteName":"SiteB"
            }
        ]
    },
    "depots":{
        "allDepots":false,
        "associatedDepots":[
            {
                "id":"CEE624A4E7EB43059C6AEC24673A288B",
                "depotName":"DepotA"
            }
        ]
    }
}
Nested Schema : DisplayDepotsListDto
Type: object
List of depots assigned to a user.
Show Source
Example:
{
    "allDepots":false,
    "associatedDepots":[
        {
            "id":"CEE624A4E7EB43059C6AEC24673A288B",
            "depotName":"DepotA"
        }
    ]
}
Nested Schema : roles
Type: object
Associates a user with a global role.
Show Source
Example:
{
    "id":"A519EF3C2B73455390CFF812AFF61519",
    "roleName":"STUDY_MANAGER"
}
Nested Schema : DisplaySitesListDto
Type: object
List of sites assigned to a user.
Show Source
Example:
{
    "allSites":false,
    "associatedSites":[
        {
            "id":"946E7D36031941CCA39CD2B2CFF2899B",
            "siteName":"SiteA"
        },
        {
            "id":"FE8925CFA8A74193A2E8D8326E7FEA88",
            "siteName":"SiteB"
        }
    ]
}
Nested Schema : DisplayStudyRoleDto
Type: object
Represents a study-level role for a user.
Show Source
Example:
{
    "id":"1BC29B36F5D64B1B95F4BDBBCEA481BE",
    "studyRoleName":"LEAD_INVESTIGATOR"
}
Nested Schema : associatedDepots
Type: object
Represents a clinical depot.
Show Source
Example:
{
    "id":"CEE624A4E7EB43059C6AEC24673A288B",
    "depotName":"DepotA"
}
Nested Schema : associatedSites
Type: object
Represents a clinical trial site.
Show Source
Example:
{
    "id":"946E7D36031941CCA39CD2B2CFF2899B",
    "siteName":"SiteA"
}
Examples

400 Response

Bad request
Body ()
Root Schema : AuthResponse
Type: object
Generic API response wrapper containing result, error data, response version and status.
Show Source
Nested Schema : ErrorResponseData
Type: object
Structure representing an error response from the reporting service. Contains an error code, human-readable message, and details.
Show Source
  • Detailed error context or debugging information such as validation error, stack trace, or field/parameter cause.
    Example: User role is missing required permission REPORTING_VIEW. Field: userId
  • Application or business-specific error code representing the error type.
    Example: REPT_401
  • Human-readable error message describing the failure or issue.
    Example: Unauthorized: User does not have access to the requested resource
Nested Schema : result
Type: object
Result data of the API response; actual type depends on the API
Example:
oracle.doceng.json.BetterJsonNull@3565a0f5
Back to Top