authPost method

Future<Response> authPost(
  1. dynamic path,
  2. dynamic body, [
  3. dynamic params
])

Implementation

Future<Response> authPost(path, body, [params]) async {
  try {
    await this.setHeaderToken();
    var response = await Dio().post(this.baseUrl + path,
        data: body, queryParameters: params, options: this.getOption());
    this.logger.d(response);
    return response;
  } catch (e) {
    this.logger.e(e);
    return Response(statusCode: 500, requestOptions: RequestOptions(path: path), statusMessage: e.toString());
  }
}