> For the complete documentation index, see [llms.txt](https://docs.bbchain.com.br/bbchain-ebs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.bbchain.com.br/bbchain-ebs/bbchain-ebs-pt/para-desenvolvedores/api-reference/network-management/users/users-api-controller.md).

# Users Api Controller

## Create user

> The user must give his company name, his full name, email and a password.

```json
{"openapi":"3.1.0","info":{"title":"OpenAPI definition","version":"v0"},"servers":[{"url":"https://user-s-bk-api.saas.ebs.bbchain.network","description":"Generated server url"}],"paths":{"/v1/users":{"post":{"tags":["users-api-controller"],"summary":"Create user","description":"The user must give his company name, his full name, email and a password.","operationId":"createUser","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SignUpInfoDTO"}}},"required":true},"responses":{"201":{"description":"Successful request.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserDTO"}}}},"400":{"description":"The message code is an encoded string that must be sent to the support team as a ticket.","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/Error"}}}}},"500":{"description":"The message code is an encoded string that must be sent to the support team as a ticket.","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/Error"}}}}}}}}},"components":{"schemas":{"SignUpInfoDTO":{"type":"object","properties":{"name":{"type":"string","maxLength":254,"minLength":3,"pattern":"^(?![\\d\\W]+$)[a-zà-üA-ZÀ-Ü0-9]+(\\s[a-zà-üA-ZÀ-Ü0-9]+)*$"},"organizationName":{"type":"string","maxLength":254,"minLength":3,"pattern":"^(?![\\d\\W]+$)[a-zà-üA-ZÀ-Ü0-9]+(\\s[a-zà-üA-ZÀ-Ü0-9]+)*$"},"password":{"type":"string","maxLength":254,"minLength":3},"phone":{"type":"string"},"verificationCode":{"type":"string"},"token":{"type":"string"}},"required":["name","organizationName","password","phone","verificationCode"]},"UserDTO":{"type":"object","properties":{"name":{"type":"string","maxLength":254,"minLength":3,"pattern":"^(?![\\d\\W]+$)[a-zà-üA-ZÀ-Ü0-9]+(\\s[a-zà-üA-ZÀ-Ü0-9]+)*$"},"email":{"type":"string","maxLength":254,"minLength":3,"pattern":"^(?!.*[.@]{2})(?!.*\\.{2})^(?!_+)[A-Za-z0-9._%+-]+@[A-Za-z0-9.-]+(?<!\\.)$"},"id":{"type":"integer","format":"int64","readOnly":true},"profiles":{"type":"array","items":{"$ref":"#/components/schemas/UserCustomerProfileDTO"}},"lastAccess":{"type":"string","format":"date-time"},"status":{"type":"string","enum":["ACTIVE","BLOCKED"],"readOnly":true}},"required":["email","name"]},"UserCustomerProfileDTO":{"type":"object","properties":{"jobTitle":{"type":"string","description":"Describes the responsibilities of the job, the level of the job, or both."},"role":{"type":"string","enum":["owner","operator","participant"]},"customer":{"$ref":"#/components/schemas/OrganizationDTO"}}},"OrganizationDTO":{"type":"object","properties":{"name":{"type":"string","maxLength":254,"minLength":3},"primaryEmail":{"type":"string","maxLength":254,"minLength":3,"pattern":"^(?!.*[.@]{2})(?!.*\\.{2})^(?!_+)[A-Za-z0-9._%+-]+@[A-Za-z0-9.-]+(?<!\\.)$"},"id":{"type":"integer","format":"int64","readOnly":true},"iconColor":{"type":"string","description":"Cor do ícone em hexadecimal (aceita com ou sem '#', ex: #1A2B3C)","pattern":"^#?[0-9a-fA-F]{6}$"},"iconUrl":{"type":"string","description":"URL pública do logotipo da organização (armazenamento de recursos)"},"companySize":{"type":"string"},"industry":{"type":"string"},"useCase":{"type":"string"},"role":{"type":"string","enum":["owner","operator","participant"]}},"required":["id","name","primaryEmail"]},"Error":{"type":"object","properties":{"message":{"type":"string","description":"Error status summary for the executed command."},"code":{"type":"string","description":"# `network.{field}.invalid` field is non compliant # `auth.invalid` Invalid credentials sent to the server. # `auth.verifyEmail` User did not verified their email. # `auth.mustChangePassword` User must change password.         # `user.emailAlreadyUsed` Email already exists. # `auth.forbidden` Forbidden access # `internal.unexpected` Unexpected error from server ","enum":["auth.invalid","auth.verifyEmail","auth.unauthorized","auth.forbidden","auth.expired","auth.blocked","auth.emailDomainBlocked","auth.mustChangePassword","auth.invalidPhoneVerificationCode","auth.passwordNotValid","auth.unableToUpdatePassword","user.notFound","user.created","user.notCreated","user.emailAlreadyExists","userHasRoleInClient","notaryNotFound","notaryPublishDateTooEarly","notaryOrganizationNameConflict","notaryIsCreating","network.notFound","network.alias.invalid","network.name.invalid","network.domain.invalid","network.organizationLegalName.invalid","network.city.invalid","network.country.invalid","network.nodeDomain.invalid","network.tenant.invalid","networkUserDoesNotHavePermissionOnNode","networkUserDoesNotHaveOperatorPermissionOnNode","networkUserDoesNotHavePermissionOnNotary","networkUserDoesNotHaveOperatorPermissionOnNotary","node.notFound","nodeOrganizationNameConflict","cordappVersionShouldBeDisabled","cordappShouldNotHaveVersions","shouldWaitPendingFlagday","internal.unexpected","field.required","field.invalid","field.size","field.pattern","illegalStatus","badRequest","timeConstraint","reachedMaxNetworks","reachedSubscriptionLimit","userReachedSubscriptionLimit","subscriptionTenantNotFoundBecauseNetworkNotFound","subscriptionNodeNameConflict","featureDisabled","adminActionNotFound","adminActionExists","adminActionNotCreated","adminActionDuplicated","adminCloudProviderNotFound","adminCloudProviderExists","adminCloudProviderNotCreated","adminProtocolNotFound","adminProtocolExists","adminProtocolNotCreated","adminPipelineServiceNotFound","adminPipelineServiceExists","adminPipelineServiceNotCreated","adminTenantNotFound","adminTenantExists","adminTenantNotCreated","adminPipelineNotFound","adminPipelineExists","adminPipelineNotCreated","adminComponentNotFound","adminComponentExists","adminComponentNotCreated","adminTenantSettingsNotFound","adminTenantSettingsExists","adminTenantSettingsNotCreated","adminTenantProtocolNotFound","adminTenantProtocolExists","adminTenantProtocolNotCreated","adminFeatureToggleNotFound","adminFeatureToggleExists","adminUserNotFound","adminNetworkNotFound","adminNetworkExists","adminNodeNotFound","adminNodeExists","adminNotaryNotFound","adminNotaryExists","adminPipelineActionDuplicated","adminAppNotFound","adminAppVersionNotFound","adminAppInstallationNotFound","adminComponentTypeNotFound","adminComponentTypeExists","adminBaseDltNotFound","adminBaseDltExists","adminBaseDltNotCreated","adminIdentityProviderNotFound","adminIdentityProviderExists","adminIdentityProviderNotCreated","adminNodeFeatureNotFound","adminNodeFeatureExists","adminNodeFeatureNotCreated","adminSpecializedModuleNotFound","adminSpecializedModuleExists"]}}}}}}
```

## Change password

> The server will validate if the current password is correct and change it for the new one passed. The return code will be the same in both cases.

```json
{"openapi":"3.1.0","info":{"title":"OpenAPI definition","version":"v0"},"servers":[{"url":"https://user-s-bk-api.saas.ebs.bbchain.network","description":"Generated server url"}],"paths":{"/v1/users/new-password":{"post":{"tags":["users-api-controller"],"summary":"Change password","description":"The server will validate if the current password is correct and change it for the new one passed. The return code will be the same in both cases.","operationId":"usersNewPasswordPost","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserNewPassword"}}},"required":true},"responses":{"200":{"description":"Password changed.","content":{}},"500":{"description":"The message code is an encoded string that must be sent to the support team as a ticket.","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/Error"}}}}}}}}},"components":{"schemas":{"UserNewPassword":{"type":"object","properties":{"oldPassword":{"type":"string","maxLength":254,"minLength":5},"newPassword":{"type":"string","maxLength":254,"minLength":5},"email":{"type":"string","maxLength":254,"minLength":3,"pattern":"^(?!.*[.@]{2})(?!.*\\.{2})^(?!_+)[A-Za-z0-9._%+-]+@[A-Za-z0-9.-]+(?<!\\.)$"}},"required":["email","newPassword","oldPassword"]},"Error":{"type":"object","properties":{"message":{"type":"string","description":"Error status summary for the executed command."},"code":{"type":"string","description":"# `network.{field}.invalid` field is non compliant # `auth.invalid` Invalid credentials sent to the server. # `auth.verifyEmail` User did not verified their email. # `auth.mustChangePassword` User must change password.         # `user.emailAlreadyUsed` Email already exists. # `auth.forbidden` Forbidden access # `internal.unexpected` Unexpected error from server ","enum":["auth.invalid","auth.verifyEmail","auth.unauthorized","auth.forbidden","auth.expired","auth.blocked","auth.emailDomainBlocked","auth.mustChangePassword","auth.invalidPhoneVerificationCode","auth.passwordNotValid","auth.unableToUpdatePassword","user.notFound","user.created","user.notCreated","user.emailAlreadyExists","userHasRoleInClient","notaryNotFound","notaryPublishDateTooEarly","notaryOrganizationNameConflict","notaryIsCreating","network.notFound","network.alias.invalid","network.name.invalid","network.domain.invalid","network.organizationLegalName.invalid","network.city.invalid","network.country.invalid","network.nodeDomain.invalid","network.tenant.invalid","networkUserDoesNotHavePermissionOnNode","networkUserDoesNotHaveOperatorPermissionOnNode","networkUserDoesNotHavePermissionOnNotary","networkUserDoesNotHaveOperatorPermissionOnNotary","node.notFound","nodeOrganizationNameConflict","cordappVersionShouldBeDisabled","cordappShouldNotHaveVersions","shouldWaitPendingFlagday","internal.unexpected","field.required","field.invalid","field.size","field.pattern","illegalStatus","badRequest","timeConstraint","reachedMaxNetworks","reachedSubscriptionLimit","userReachedSubscriptionLimit","subscriptionTenantNotFoundBecauseNetworkNotFound","subscriptionNodeNameConflict","featureDisabled","adminActionNotFound","adminActionExists","adminActionNotCreated","adminActionDuplicated","adminCloudProviderNotFound","adminCloudProviderExists","adminCloudProviderNotCreated","adminProtocolNotFound","adminProtocolExists","adminProtocolNotCreated","adminPipelineServiceNotFound","adminPipelineServiceExists","adminPipelineServiceNotCreated","adminTenantNotFound","adminTenantExists","adminTenantNotCreated","adminPipelineNotFound","adminPipelineExists","adminPipelineNotCreated","adminComponentNotFound","adminComponentExists","adminComponentNotCreated","adminTenantSettingsNotFound","adminTenantSettingsExists","adminTenantSettingsNotCreated","adminTenantProtocolNotFound","adminTenantProtocolExists","adminTenantProtocolNotCreated","adminFeatureToggleNotFound","adminFeatureToggleExists","adminUserNotFound","adminNetworkNotFound","adminNetworkExists","adminNodeNotFound","adminNodeExists","adminNotaryNotFound","adminNotaryExists","adminPipelineActionDuplicated","adminAppNotFound","adminAppVersionNotFound","adminAppInstallationNotFound","adminComponentTypeNotFound","adminComponentTypeExists","adminBaseDltNotFound","adminBaseDltExists","adminBaseDltNotCreated","adminIdentityProviderNotFound","adminIdentityProviderExists","adminIdentityProviderNotCreated","adminNodeFeatureNotFound","adminNodeFeatureExists","adminNodeFeatureNotCreated","adminSpecializedModuleNotFound","adminSpecializedModuleExists"]}}}}}}
```

## Request password update email

> The server will use this email to check if the user exists or not. It will send an email to the user if it exists and do nothing otherwise. The return code will be the same in both cases.

```json
{"openapi":"3.1.0","info":{"title":"OpenAPI definition","version":"v0"},"servers":[{"url":"https://user-s-bk-api.saas.ebs.bbchain.network","description":"Generated server url"}],"paths":{"/v1/users/forgot-password":{"post":{"tags":["users-api-controller"],"summary":"Request password update email","description":"The server will use this email to check if the user exists or not. It will send an email to the user if it exists and do nothing otherwise. The return code will be the same in both cases.","operationId":"usersForgotPasswordPost","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PasswordRecoveryInfoDTO"}}},"required":true},"responses":{"200":{"description":"Email sent.","content":{}},"500":{"description":"The message code is an encoded string that must be sent to the support team as a ticket.","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/Error"}}}}}}}}},"components":{"schemas":{"PasswordRecoveryInfoDTO":{"type":"object","properties":{"email":{"type":"string","maxLength":254,"minLength":3,"pattern":"^(?!.*[.@]{2})(?!.*\\.{2})^(?!_+)[A-Za-z0-9._%+-]+@[A-Za-z0-9.-]+(?<!\\.)$"}},"required":["email"]},"Error":{"type":"object","properties":{"message":{"type":"string","description":"Error status summary for the executed command."},"code":{"type":"string","description":"# `network.{field}.invalid` field is non compliant # `auth.invalid` Invalid credentials sent to the server. # `auth.verifyEmail` User did not verified their email. # `auth.mustChangePassword` User must change password.         # `user.emailAlreadyUsed` Email already exists. # `auth.forbidden` Forbidden access # `internal.unexpected` Unexpected error from server ","enum":["auth.invalid","auth.verifyEmail","auth.unauthorized","auth.forbidden","auth.expired","auth.blocked","auth.emailDomainBlocked","auth.mustChangePassword","auth.invalidPhoneVerificationCode","auth.passwordNotValid","auth.unableToUpdatePassword","user.notFound","user.created","user.notCreated","user.emailAlreadyExists","userHasRoleInClient","notaryNotFound","notaryPublishDateTooEarly","notaryOrganizationNameConflict","notaryIsCreating","network.notFound","network.alias.invalid","network.name.invalid","network.domain.invalid","network.organizationLegalName.invalid","network.city.invalid","network.country.invalid","network.nodeDomain.invalid","network.tenant.invalid","networkUserDoesNotHavePermissionOnNode","networkUserDoesNotHaveOperatorPermissionOnNode","networkUserDoesNotHavePermissionOnNotary","networkUserDoesNotHaveOperatorPermissionOnNotary","node.notFound","nodeOrganizationNameConflict","cordappVersionShouldBeDisabled","cordappShouldNotHaveVersions","shouldWaitPendingFlagday","internal.unexpected","field.required","field.invalid","field.size","field.pattern","illegalStatus","badRequest","timeConstraint","reachedMaxNetworks","reachedSubscriptionLimit","userReachedSubscriptionLimit","subscriptionTenantNotFoundBecauseNetworkNotFound","subscriptionNodeNameConflict","featureDisabled","adminActionNotFound","adminActionExists","adminActionNotCreated","adminActionDuplicated","adminCloudProviderNotFound","adminCloudProviderExists","adminCloudProviderNotCreated","adminProtocolNotFound","adminProtocolExists","adminProtocolNotCreated","adminPipelineServiceNotFound","adminPipelineServiceExists","adminPipelineServiceNotCreated","adminTenantNotFound","adminTenantExists","adminTenantNotCreated","adminPipelineNotFound","adminPipelineExists","adminPipelineNotCreated","adminComponentNotFound","adminComponentExists","adminComponentNotCreated","adminTenantSettingsNotFound","adminTenantSettingsExists","adminTenantSettingsNotCreated","adminTenantProtocolNotFound","adminTenantProtocolExists","adminTenantProtocolNotCreated","adminFeatureToggleNotFound","adminFeatureToggleExists","adminUserNotFound","adminNetworkNotFound","adminNetworkExists","adminNodeNotFound","adminNodeExists","adminNotaryNotFound","adminNotaryExists","adminPipelineActionDuplicated","adminAppNotFound","adminAppVersionNotFound","adminAppInstallationNotFound","adminComponentTypeNotFound","adminComponentTypeExists","adminBaseDltNotFound","adminBaseDltExists","adminBaseDltNotCreated","adminIdentityProviderNotFound","adminIdentityProviderExists","adminIdentityProviderNotCreated","adminNodeFeatureNotFound","adminNodeFeatureExists","adminNodeFeatureNotCreated","adminSpecializedModuleNotFound","adminSpecializedModuleExists"]}}}}}}
```

## Request password update email

> The server will use this email to check if the user exists or not. It will send an email to the user if it exists and do nothing otherwise. The return code will be the same in both cases.

```json
{"openapi":"3.1.0","info":{"title":"OpenAPI definition","version":"v0"},"servers":[{"url":"https://user-s-bk-api.saas.ebs.bbchain.network","description":"Generated server url"}],"paths":{"/v1/users/forgot-password/new-password":{"post":{"tags":["users-api-controller"],"summary":"Request password update email","description":"The server will use this email to check if the user exists or not. It will send an email to the user if it exists and do nothing otherwise. The return code will be the same in both cases.","operationId":"usersForgotPasswordNewPasswordPost","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserPasswordForgotPassword"}}},"required":true},"responses":{"200":{"description":"Email sent.","content":{}},"500":{"description":"The message code is an encoded string that must be sent to the support team as a ticket.","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/Error"}}}}}}}}},"components":{"schemas":{"UserPasswordForgotPassword":{"type":"object","properties":{"newPassword":{"type":"string","maxLength":254,"minLength":5},"forgotPasswordId":{"type":"string","format":"uuid"}},"required":["forgotPasswordId","newPassword"]},"Error":{"type":"object","properties":{"message":{"type":"string","description":"Error status summary for the executed command."},"code":{"type":"string","description":"# `network.{field}.invalid` field is non compliant # `auth.invalid` Invalid credentials sent to the server. # `auth.verifyEmail` User did not verified their email. # `auth.mustChangePassword` User must change password.         # `user.emailAlreadyUsed` Email already exists. # `auth.forbidden` Forbidden access # `internal.unexpected` Unexpected error from server ","enum":["auth.invalid","auth.verifyEmail","auth.unauthorized","auth.forbidden","auth.expired","auth.blocked","auth.emailDomainBlocked","auth.mustChangePassword","auth.invalidPhoneVerificationCode","auth.passwordNotValid","auth.unableToUpdatePassword","user.notFound","user.created","user.notCreated","user.emailAlreadyExists","userHasRoleInClient","notaryNotFound","notaryPublishDateTooEarly","notaryOrganizationNameConflict","notaryIsCreating","network.notFound","network.alias.invalid","network.name.invalid","network.domain.invalid","network.organizationLegalName.invalid","network.city.invalid","network.country.invalid","network.nodeDomain.invalid","network.tenant.invalid","networkUserDoesNotHavePermissionOnNode","networkUserDoesNotHaveOperatorPermissionOnNode","networkUserDoesNotHavePermissionOnNotary","networkUserDoesNotHaveOperatorPermissionOnNotary","node.notFound","nodeOrganizationNameConflict","cordappVersionShouldBeDisabled","cordappShouldNotHaveVersions","shouldWaitPendingFlagday","internal.unexpected","field.required","field.invalid","field.size","field.pattern","illegalStatus","badRequest","timeConstraint","reachedMaxNetworks","reachedSubscriptionLimit","userReachedSubscriptionLimit","subscriptionTenantNotFoundBecauseNetworkNotFound","subscriptionNodeNameConflict","featureDisabled","adminActionNotFound","adminActionExists","adminActionNotCreated","adminActionDuplicated","adminCloudProviderNotFound","adminCloudProviderExists","adminCloudProviderNotCreated","adminProtocolNotFound","adminProtocolExists","adminProtocolNotCreated","adminPipelineServiceNotFound","adminPipelineServiceExists","adminPipelineServiceNotCreated","adminTenantNotFound","adminTenantExists","adminTenantNotCreated","adminPipelineNotFound","adminPipelineExists","adminPipelineNotCreated","adminComponentNotFound","adminComponentExists","adminComponentNotCreated","adminTenantSettingsNotFound","adminTenantSettingsExists","adminTenantSettingsNotCreated","adminTenantProtocolNotFound","adminTenantProtocolExists","adminTenantProtocolNotCreated","adminFeatureToggleNotFound","adminFeatureToggleExists","adminUserNotFound","adminNetworkNotFound","adminNetworkExists","adminNodeNotFound","adminNodeExists","adminNotaryNotFound","adminNotaryExists","adminPipelineActionDuplicated","adminAppNotFound","adminAppVersionNotFound","adminAppInstallationNotFound","adminComponentTypeNotFound","adminComponentTypeExists","adminBaseDltNotFound","adminBaseDltExists","adminBaseDltNotCreated","adminIdentityProviderNotFound","adminIdentityProviderExists","adminIdentityProviderNotCreated","adminNodeFeatureNotFound","adminNodeFeatureExists","adminNodeFeatureNotCreated","adminSpecializedModuleNotFound","adminSpecializedModuleExists"]}}}}}}
```

## Validates an email

> A code sent by the backend server directly to the user. The user must send it back to the server in order to validate their email.

```json
{"openapi":"3.1.0","info":{"title":"OpenAPI definition","version":"v0"},"servers":[{"url":"https://user-s-bk-api.saas.ebs.bbchain.network","description":"Generated server url"}],"paths":{"/v1/users/email/validation/{requestId}":{"post":{"tags":["users-api-controller"],"summary":"Validates an email","description":"A code sent by the backend server directly to the user. The user must send it back to the server in order to validate their email.","operationId":"usersEmailValidationRequestIdPost","parameters":[{"name":"requestId","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Email validated","content":{}},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/Error"}}}}},"404":{"description":"Resource does not exists.","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/Error"}}}}},"500":{"description":"The message code is an encoded string that must be sent to the support team as a ticket.","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/Error"}}}}}}}}},"components":{"schemas":{"Error":{"type":"object","properties":{"message":{"type":"string","description":"Error status summary for the executed command."},"code":{"type":"string","description":"# `network.{field}.invalid` field is non compliant # `auth.invalid` Invalid credentials sent to the server. # `auth.verifyEmail` User did not verified their email. # `auth.mustChangePassword` User must change password.         # `user.emailAlreadyUsed` Email already exists. # `auth.forbidden` Forbidden access # `internal.unexpected` Unexpected error from server ","enum":["auth.invalid","auth.verifyEmail","auth.unauthorized","auth.forbidden","auth.expired","auth.blocked","auth.emailDomainBlocked","auth.mustChangePassword","auth.invalidPhoneVerificationCode","auth.passwordNotValid","auth.unableToUpdatePassword","user.notFound","user.created","user.notCreated","user.emailAlreadyExists","userHasRoleInClient","notaryNotFound","notaryPublishDateTooEarly","notaryOrganizationNameConflict","notaryIsCreating","network.notFound","network.alias.invalid","network.name.invalid","network.domain.invalid","network.organizationLegalName.invalid","network.city.invalid","network.country.invalid","network.nodeDomain.invalid","network.tenant.invalid","networkUserDoesNotHavePermissionOnNode","networkUserDoesNotHaveOperatorPermissionOnNode","networkUserDoesNotHavePermissionOnNotary","networkUserDoesNotHaveOperatorPermissionOnNotary","node.notFound","nodeOrganizationNameConflict","cordappVersionShouldBeDisabled","cordappShouldNotHaveVersions","shouldWaitPendingFlagday","internal.unexpected","field.required","field.invalid","field.size","field.pattern","illegalStatus","badRequest","timeConstraint","reachedMaxNetworks","reachedSubscriptionLimit","userReachedSubscriptionLimit","subscriptionTenantNotFoundBecauseNetworkNotFound","subscriptionNodeNameConflict","featureDisabled","adminActionNotFound","adminActionExists","adminActionNotCreated","adminActionDuplicated","adminCloudProviderNotFound","adminCloudProviderExists","adminCloudProviderNotCreated","adminProtocolNotFound","adminProtocolExists","adminProtocolNotCreated","adminPipelineServiceNotFound","adminPipelineServiceExists","adminPipelineServiceNotCreated","adminTenantNotFound","adminTenantExists","adminTenantNotCreated","adminPipelineNotFound","adminPipelineExists","adminPipelineNotCreated","adminComponentNotFound","adminComponentExists","adminComponentNotCreated","adminTenantSettingsNotFound","adminTenantSettingsExists","adminTenantSettingsNotCreated","adminTenantProtocolNotFound","adminTenantProtocolExists","adminTenantProtocolNotCreated","adminFeatureToggleNotFound","adminFeatureToggleExists","adminUserNotFound","adminNetworkNotFound","adminNetworkExists","adminNodeNotFound","adminNodeExists","adminNotaryNotFound","adminNotaryExists","adminPipelineActionDuplicated","adminAppNotFound","adminAppVersionNotFound","adminAppInstallationNotFound","adminComponentTypeNotFound","adminComponentTypeExists","adminBaseDltNotFound","adminBaseDltExists","adminBaseDltNotCreated","adminIdentityProviderNotFound","adminIdentityProviderExists","adminIdentityProviderNotCreated","adminNodeFeatureNotFound","adminNodeFeatureExists","adminNodeFeatureNotCreated","adminSpecializedModuleNotFound","adminSpecializedModuleExists"]}}}}}}
```

## Send token to an email

> A code sent by the backend server directly to the user. The user must send it back to the server in order to validate their email.

```json
{"openapi":"3.1.0","info":{"title":"OpenAPI definition","version":"v0"},"servers":[{"url":"https://user-s-bk-api.saas.ebs.bbchain.network","description":"Generated server url"}],"paths":{"/v1/users/email/send-token/{email}":{"post":{"tags":["users-api-controller"],"summary":"Send token to an email","description":"A code sent by the backend server directly to the user. The user must send it back to the server in order to validate their email.","operationId":"usersEmailSendTokenEmailPost","parameters":[{"name":"email","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Token sent","content":{}},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/Error"}}}}},"404":{"description":"Resource does not exists.","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/Error"}}}}},"500":{"description":"The message code is an encoded string that must be sent to the support team as a ticket.","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/Error"}}}}}}}}},"components":{"schemas":{"Error":{"type":"object","properties":{"message":{"type":"string","description":"Error status summary for the executed command."},"code":{"type":"string","description":"# `network.{field}.invalid` field is non compliant # `auth.invalid` Invalid credentials sent to the server. # `auth.verifyEmail` User did not verified their email. # `auth.mustChangePassword` User must change password.         # `user.emailAlreadyUsed` Email already exists. # `auth.forbidden` Forbidden access # `internal.unexpected` Unexpected error from server ","enum":["auth.invalid","auth.verifyEmail","auth.unauthorized","auth.forbidden","auth.expired","auth.blocked","auth.emailDomainBlocked","auth.mustChangePassword","auth.invalidPhoneVerificationCode","auth.passwordNotValid","auth.unableToUpdatePassword","user.notFound","user.created","user.notCreated","user.emailAlreadyExists","userHasRoleInClient","notaryNotFound","notaryPublishDateTooEarly","notaryOrganizationNameConflict","notaryIsCreating","network.notFound","network.alias.invalid","network.name.invalid","network.domain.invalid","network.organizationLegalName.invalid","network.city.invalid","network.country.invalid","network.nodeDomain.invalid","network.tenant.invalid","networkUserDoesNotHavePermissionOnNode","networkUserDoesNotHaveOperatorPermissionOnNode","networkUserDoesNotHavePermissionOnNotary","networkUserDoesNotHaveOperatorPermissionOnNotary","node.notFound","nodeOrganizationNameConflict","cordappVersionShouldBeDisabled","cordappShouldNotHaveVersions","shouldWaitPendingFlagday","internal.unexpected","field.required","field.invalid","field.size","field.pattern","illegalStatus","badRequest","timeConstraint","reachedMaxNetworks","reachedSubscriptionLimit","userReachedSubscriptionLimit","subscriptionTenantNotFoundBecauseNetworkNotFound","subscriptionNodeNameConflict","featureDisabled","adminActionNotFound","adminActionExists","adminActionNotCreated","adminActionDuplicated","adminCloudProviderNotFound","adminCloudProviderExists","adminCloudProviderNotCreated","adminProtocolNotFound","adminProtocolExists","adminProtocolNotCreated","adminPipelineServiceNotFound","adminPipelineServiceExists","adminPipelineServiceNotCreated","adminTenantNotFound","adminTenantExists","adminTenantNotCreated","adminPipelineNotFound","adminPipelineExists","adminPipelineNotCreated","adminComponentNotFound","adminComponentExists","adminComponentNotCreated","adminTenantSettingsNotFound","adminTenantSettingsExists","adminTenantSettingsNotCreated","adminTenantProtocolNotFound","adminTenantProtocolExists","adminTenantProtocolNotCreated","adminFeatureToggleNotFound","adminFeatureToggleExists","adminUserNotFound","adminNetworkNotFound","adminNetworkExists","adminNodeNotFound","adminNodeExists","adminNotaryNotFound","adminNotaryExists","adminPipelineActionDuplicated","adminAppNotFound","adminAppVersionNotFound","adminAppInstallationNotFound","adminComponentTypeNotFound","adminComponentTypeExists","adminBaseDltNotFound","adminBaseDltExists","adminBaseDltNotCreated","adminIdentityProviderNotFound","adminIdentityProviderExists","adminIdentityProviderNotCreated","adminNodeFeatureNotFound","adminNodeFeatureExists","adminNodeFeatureNotCreated","adminSpecializedModuleNotFound","adminSpecializedModuleExists"]}}}}}}
```

## Returns the logged in user

> Returns the information of the logged in user

```json
{"openapi":"3.1.0","info":{"title":"OpenAPI definition","version":"v0"},"servers":[{"url":"https://user-s-bk-api.saas.ebs.bbchain.network","description":"Generated server url"}],"paths":{"/v1/users/current":{"get":{"tags":["users-api-controller"],"summary":"Returns the logged in user","description":"Returns the information of the logged in user","operationId":"usersCurrentGet","responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserDTO"}}}},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/Error"}}}}},"404":{"description":"Resource does not exists.","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/Error"}}}}},"500":{"description":"The message code is an encoded string that must be sent to the support team as a ticket.","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/Error"}}}}}}}}},"components":{"schemas":{"UserDTO":{"type":"object","properties":{"name":{"type":"string","maxLength":254,"minLength":3,"pattern":"^(?![\\d\\W]+$)[a-zà-üA-ZÀ-Ü0-9]+(\\s[a-zà-üA-ZÀ-Ü0-9]+)*$"},"email":{"type":"string","maxLength":254,"minLength":3,"pattern":"^(?!.*[.@]{2})(?!.*\\.{2})^(?!_+)[A-Za-z0-9._%+-]+@[A-Za-z0-9.-]+(?<!\\.)$"},"id":{"type":"integer","format":"int64","readOnly":true},"profiles":{"type":"array","items":{"$ref":"#/components/schemas/UserCustomerProfileDTO"}},"lastAccess":{"type":"string","format":"date-time"},"status":{"type":"string","enum":["ACTIVE","BLOCKED"],"readOnly":true}},"required":["email","name"]},"UserCustomerProfileDTO":{"type":"object","properties":{"jobTitle":{"type":"string","description":"Describes the responsibilities of the job, the level of the job, or both."},"role":{"type":"string","enum":["owner","operator","participant"]},"customer":{"$ref":"#/components/schemas/OrganizationDTO"}}},"OrganizationDTO":{"type":"object","properties":{"name":{"type":"string","maxLength":254,"minLength":3},"primaryEmail":{"type":"string","maxLength":254,"minLength":3,"pattern":"^(?!.*[.@]{2})(?!.*\\.{2})^(?!_+)[A-Za-z0-9._%+-]+@[A-Za-z0-9.-]+(?<!\\.)$"},"id":{"type":"integer","format":"int64","readOnly":true},"iconColor":{"type":"string","description":"Cor do ícone em hexadecimal (aceita com ou sem '#', ex: #1A2B3C)","pattern":"^#?[0-9a-fA-F]{6}$"},"iconUrl":{"type":"string","description":"URL pública do logotipo da organização (armazenamento de recursos)"},"companySize":{"type":"string"},"industry":{"type":"string"},"useCase":{"type":"string"},"role":{"type":"string","enum":["owner","operator","participant"]}},"required":["id","name","primaryEmail"]},"Error":{"type":"object","properties":{"message":{"type":"string","description":"Error status summary for the executed command."},"code":{"type":"string","description":"# `network.{field}.invalid` field is non compliant # `auth.invalid` Invalid credentials sent to the server. # `auth.verifyEmail` User did not verified their email. # `auth.mustChangePassword` User must change password.         # `user.emailAlreadyUsed` Email already exists. # `auth.forbidden` Forbidden access # `internal.unexpected` Unexpected error from server ","enum":["auth.invalid","auth.verifyEmail","auth.unauthorized","auth.forbidden","auth.expired","auth.blocked","auth.emailDomainBlocked","auth.mustChangePassword","auth.invalidPhoneVerificationCode","auth.passwordNotValid","auth.unableToUpdatePassword","user.notFound","user.created","user.notCreated","user.emailAlreadyExists","userHasRoleInClient","notaryNotFound","notaryPublishDateTooEarly","notaryOrganizationNameConflict","notaryIsCreating","network.notFound","network.alias.invalid","network.name.invalid","network.domain.invalid","network.organizationLegalName.invalid","network.city.invalid","network.country.invalid","network.nodeDomain.invalid","network.tenant.invalid","networkUserDoesNotHavePermissionOnNode","networkUserDoesNotHaveOperatorPermissionOnNode","networkUserDoesNotHavePermissionOnNotary","networkUserDoesNotHaveOperatorPermissionOnNotary","node.notFound","nodeOrganizationNameConflict","cordappVersionShouldBeDisabled","cordappShouldNotHaveVersions","shouldWaitPendingFlagday","internal.unexpected","field.required","field.invalid","field.size","field.pattern","illegalStatus","badRequest","timeConstraint","reachedMaxNetworks","reachedSubscriptionLimit","userReachedSubscriptionLimit","subscriptionTenantNotFoundBecauseNetworkNotFound","subscriptionNodeNameConflict","featureDisabled","adminActionNotFound","adminActionExists","adminActionNotCreated","adminActionDuplicated","adminCloudProviderNotFound","adminCloudProviderExists","adminCloudProviderNotCreated","adminProtocolNotFound","adminProtocolExists","adminProtocolNotCreated","adminPipelineServiceNotFound","adminPipelineServiceExists","adminPipelineServiceNotCreated","adminTenantNotFound","adminTenantExists","adminTenantNotCreated","adminPipelineNotFound","adminPipelineExists","adminPipelineNotCreated","adminComponentNotFound","adminComponentExists","adminComponentNotCreated","adminTenantSettingsNotFound","adminTenantSettingsExists","adminTenantSettingsNotCreated","adminTenantProtocolNotFound","adminTenantProtocolExists","adminTenantProtocolNotCreated","adminFeatureToggleNotFound","adminFeatureToggleExists","adminUserNotFound","adminNetworkNotFound","adminNetworkExists","adminNodeNotFound","adminNodeExists","adminNotaryNotFound","adminNotaryExists","adminPipelineActionDuplicated","adminAppNotFound","adminAppVersionNotFound","adminAppInstallationNotFound","adminComponentTypeNotFound","adminComponentTypeExists","adminBaseDltNotFound","adminBaseDltExists","adminBaseDltNotCreated","adminIdentityProviderNotFound","adminIdentityProviderExists","adminIdentityProviderNotCreated","adminNodeFeatureNotFound","adminNodeFeatureExists","adminNodeFeatureNotCreated","adminSpecializedModuleNotFound","adminSpecializedModuleExists"]}}}}}}
```
