> For the complete documentation index, see [llms.txt](https://docs.mburger.cloud/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.mburger.cloud/flutter-sdk/auth/register-a-user.md).

# Register a user

To register a user, call **`MBAuth.registerUser()`**.

{% hint style="info" %}
The fields, name , surname , email and password are required, while the other are optional.&#x20;

The field data is an arbitrary object (array or dictionary) representing additional data that you want to pass when registering the user. It will be returned when retrieving the profile.
{% endhint %}

```dart
await MBAuth.registerUser(
      'name',
      'surname',
      'email',
      'password',
      phone: '1234567890',
      image: null,
      data: null,
    );
```
