create method

Future<Response> create(
  1. {@required String email,
  2. @required String password,
  3. String name = ''}
)

Create User

Create a new user.

Implementation

Future<Response> create({@required String email, @required String password, String name = ''}) {
   final String path = '/users';

   final Map<String, dynamic> params = {
       'email': email,
       'password': password,
       'name': name,
   };

   final Map<String, String> headers = {
       'content-type': 'application/json',
   };

   return client.call(HttpMethod.post, path: path, params: params, headers: headers);
    }