If ``access-key`` is specified and refers to an existing key owned by the user
then it will be modified.
+.. versionadded:: Luminous
+
+A ``tenant`` may either be specified as a part of uid or as an additional
+request param.
+
:caps: users=write
Syntax
:Example: False [False]
:Required: No
+.. versionadded:: Jewel
+``tenant``
+
+:Description: the Tenant under which a user is a part of.
+:Type: string
+:Example: tenant1
+:Required: No
+
Response Entities
~~~~~~~~~~~~~~~~~
std::string secret_key;
std::string key_type_str;
std::string caps;
+ std::string tenant_name;
bool gen_key;
bool suspended;
RESTArgs::get_string(s, "secret-key", secret_key, &secret_key);
RESTArgs::get_string(s, "key-type", key_type_str, &key_type_str);
RESTArgs::get_string(s, "user-caps", caps, &caps);
+ RESTArgs::get_string(s, "tenant", tenant_name, &tenant_name);
RESTArgs::get_bool(s, "generate-key", true, &gen_key);
RESTArgs::get_bool(s, "suspended", false, &suspended);
RESTArgs::get_int32(s, "max-buckets", default_max_buckets, &max_buckets);
return;
}
+ if (!tenant_name.empty()) {
+ uid.tenant = tenant_name;
+ }
+
// TODO: validate required args are passed in. (for eg. uid and display_name here)
op_state.set_user_id(uid);
op_state.set_display_name(display_name);