Create a user

POST {{baseUrl}}/api/v2/users?createMode=errorIfExists

Create a user according to the parameters given

Request Params

KeyDatatypeRequiredDescription
createModestringQuery parameter allowing support for different modes of resource creation. Possible values include:
  • errorIfExists: Throws an error if you try to create a resource that already exists.
  • orReplace: Automatically replaces the existing resource with the current one.
  • ifNotExists: Creates a new resource when an alter is requested for a non-existent resource. |

Request Body

{"name"=>"<string>", "password"=>"<string>", "login_name"=>"<string>", "display_name"=>"<string>", "first_name"=>"<string>", "middle_name"=>"<string>", "last_name"=>"<string>", "email"=>"<string>", "must_change_password"=>"<boolean>", "disabled"=>"<boolean>", "days_to_expiry"=>"<integer>", "mins_to_unlock"=>"<integer>", "default_warehouse"=>"<string>", "default_namespace"=>"<string>", "default_role"=>"<string>", "default_secondary_roles"=>"<string>", "mins_to_bypass_mfa"=>"<integer>", "rsa_public_key"=>"<string>", "rsa_public_key_fp"=>"<string>", "rsa_public_key_2"=>"<string>", "rsa_public_key_2_fp"=>"<string>", "comment"=>"<string>", "type"=>"<string>", "created_on"=>"<dateTime>", "last_successful_login"=>"<dateTime>", "expires_at"=>"<dateTime>", "locked_until"=>"<dateTime>", "has_password"=>"<boolean>", "has_rsa_public_key"=>"<boolean>", "ext_authn_duo"=>"<boolean>", "ext_authn_uid"=>"<string>", "owner"=>"<string>", "snowflake_lock"=>false, "snowflake_support"=>false, "mins_to_bypass_network_policy"=>"<integer>", "password_last_set"=>"<dateTime>", "custom_landing_page_url"=>"<string>", "custom_landing_page_url_flush_next_ui_load"=>false}

HEADERS

KeyDatatypeRequiredDescription
Content-Typestring
Acceptstring

RESPONSES

status: OK

{&quot;status&quot;:&quot;\u003cstring\u003e&quot;}