Difference between revisions of "Active User Web Service"
Jump to navigation
Jump to search
m (Glenn moved page Active User REST API - FMR to Active User Web Service without leaving a redirect) |
(→Example) |
||
(4 intermediate revisions by one other user not shown) | |||
Line 1: | Line 1: | ||
[[Category:FMR_REST_API_Reference]] | [[Category:FMR_REST_API_Reference]] | ||
+ | = Overview = | ||
+ | The Active User web service can be used by an authenticated user to return details of their account. | ||
− | + | Returns JSON describing: | |
+ | * Root user permissions (if any) | ||
+ | * Admin permissions (if any) | ||
+ | * User name | ||
+ | * Registered email address | ||
+ | * Modify permissions | ||
+ | * SDMX Data Consumer organisation membership | ||
+ | * SDMX Data Provider organisation membership | ||
+ | * SDMX Agency membership | ||
+ | |||
+ | {| class="wikitable" | ||
+ | |- | ||
+ | |style="background-color:#eaecf0"|<b>Entry Point</b> || style="min-width:500px;" | <b> /ws/public/currentuser/user</b> | ||
+ | |- | ||
+ | |style="background-color:#eaecf0"|<b>Access</b> || Public </span> | ||
+ | |- | ||
+ | |style="background-color:#eaecf0"|<b>Http Method</b> || GET | ||
+ | |- | ||
+ | |style="background-color:#eaecf0"|<b>Response Format</b> || application/json (array of objects) | ||
+ | |- | ||
+ | |style="background-color:#eaecf0"|<b>Response Statuses</b> || <p><b>200</b> - Query Ok<p> | ||
+ | |} | ||
+ | |||
+ | =Example= | ||
+ | |||
+ | This is the response for the root user: | ||
+ | |||
+ | <pre> | ||
+ | { | ||
+ | "isRoot": true, | ||
+ | "isAdmin": true, | ||
+ | "name": "Root", | ||
+ | "username": "root", | ||
+ | "auth": [ | ||
+ | "ROLE_ROOT" | ||
+ | ], | ||
+ | "modifyStatus": "loggedInWithModifyPermissions", | ||
+ | "providers": [], | ||
+ | "agencies": [] | ||
+ | } | ||
+ | </pre> | ||
+ | |||
+ | An example response for a user with modify permissions for the agencies BIS and ECB: | ||
+ | |||
+ | <pre> | ||
+ | { | ||
+ | "isRoot": false, | ||
+ | "isAdmin": false, | ||
+ | "name": "User 1", | ||
+ | "username": "user1", | ||
+ | "auth": [ | ||
+ | "ROLE_USER", | ||
+ | "ROLE_AGENCY" | ||
+ | ], | ||
+ | "roles": [ | ||
+ | "PUBLIC", | ||
+ | "bisusers", | ||
+ | "ecbusers" | ||
+ | ], | ||
+ | "email": "user1@examplecom", | ||
+ | "modifyStatus": "loggedInWithModifyPermissions", | ||
+ | "providers": [], | ||
+ | "agencies": [ | ||
+ | "urn:sdmx:org.sdmx.infomodel.base.Agency=SDMX:AGENCIES(1.0).BIS", | ||
+ | "urn:sdmx:org.sdmx.infomodel.base.Agency=SDMX:AGENCIES(1.0).ECB" | ||
+ | ] | ||
+ | } | ||
+ | </pre> |
Latest revision as of 07:53, 5 November 2024
Overview
The Active User web service can be used by an authenticated user to return details of their account.
Returns JSON describing:
- Root user permissions (if any)
- Admin permissions (if any)
- User name
- Registered email address
- Modify permissions
- SDMX Data Consumer organisation membership
- SDMX Data Provider organisation membership
- SDMX Agency membership
Entry Point | /ws/public/currentuser/user |
Access | Public |
Http Method | GET |
Response Format | application/json (array of objects) |
Response Statuses | 200 - Query Ok
|
Example
This is the response for the root user:
{ "isRoot": true, "isAdmin": true, "name": "Root", "username": "root", "auth": [ "ROLE_ROOT" ], "modifyStatus": "loggedInWithModifyPermissions", "providers": [], "agencies": [] }
An example response for a user with modify permissions for the agencies BIS and ECB:
{ "isRoot": false, "isAdmin": false, "name": "User 1", "username": "user1", "auth": [ "ROLE_USER", "ROLE_AGENCY" ], "roles": [ "PUBLIC", "bisusers", "ecbusers" ], "email": "user1@examplecom", "modifyStatus": "loggedInWithModifyPermissions", "providers": [], "agencies": [ "urn:sdmx:org.sdmx.infomodel.base.Agency=SDMX:AGENCIES(1.0).BIS", "urn:sdmx:org.sdmx.infomodel.base.Agency=SDMX:AGENCIES(1.0).ECB" ] }