Realiza o cadastro de um novo usuário.

POST {{baseUrl}}/api/v1/usuario

🇧🇷


O teste realizado tem como objetivo validar os campos que sempre irão retornar no json de resposta no cadastro de um novo usuário.

O schema utilizado para comparar com o JSON de resposta é pego através da variável schemaUsuario definido em pre-script request da collection porque terão mais endpoints em que ela será necessária.

Observação: O email e a senha usados no cadastro são utilizados para realizar o login.
Eles estão sendo declarados em variáveis de ambiente na aba Test.

us


The test performed aims to validate the fields that will always return in the response json in the registration of a new user.

The schema used to compare with the response JSON is taken through the schemaUsuario variable defined in the pre-script request of the collection because there will be more endpoints where it will be needed.

Note: The email and password used for registration are used to login.
They are being declared in environment variables in the Test tab.

Request Body

{"usuario"=>{"nome"=>"{{$randomTransactionType}}", "email"=>"{{$randomEmail}}", "senha"=>"{{$randomPassword}}", "dataNascimento"=>"19980320", "profissao"=>"{{$randomJobTitle}}", "telefone"=>2126235978}}

HEADERS

KeyDatatypeRequiredDescription
Content-Typestring

RESPONSES

status: OK

{"usuario":{"nome":"Ana Valadares","email":"usuario@teste.com","senha":"password","id":12,"dataNascimento":"YYYYMMDD","profissao":"Analista de qualidade","telefone":2126235978},"mensagem":"Cadastro realizado com sucesso."}