getUserProperty method

Future<UserProperty> getUserProperty({
  1. required String userId,
  2. required String key,
})

Returns the property corresponding to key for a user. For more information about user properties, see Confluence entity properties. Note, these properties stored against a user are on a Confluence site level and not space/content level.

Permissions required: Permission to access the Confluence site ('Can use' global permission).

Implementation

Future<UserProperty> getUserProperty(
    {required String userId, required String key}) async {
  return UserProperty.fromJson(await _client.send(
    'get',
    'wiki/rest/api/user/{userId}/property/{key}',
    pathParameters: {
      'userId': userId,
      'key': key,
    },
  ));
}