import 'package:traderscircuit/Utils/api_urls.dart';
import 'package:traderscircuit/Utils/base_manager.dart';
import 'package:traderscircuit/data/network/network_api_services.dart';

class AddDetailsAPI {
  AddDetailsAPI(this.data);
  var data;
  Future<ResponseData<dynamic>> adddetailsApi() async {
    final response = await NetworkApiServices().postApi(
      // optionalpar: true,
      data,
      ApiUrls.AddDetails,
    );

    if (response.status == ResponseStatus.SUCCESS) {
      Map<String, dynamic> responseData =
          Map<String, dynamic>.from(response.data);
      if (responseData['status'] == "success") {
        print("token is $response");
      } else {
        return ResponseData<dynamic>(
            responseData['message'], ResponseStatus.FAILED);
      }
    }
    return response;
  }
}
