Skip to content

kmelodi/EasyBimehLanding_NodeJs

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Getting started

EasyBimehConnect

یک ساب برند از ایزی بیمه است که وظیفه ارائه خدمات

B2B و B2B2C

را برپایه وب سرویس و وایت لیبل بر عهده دارد. اگر اپلیکیشن و یا سایت غیر بیمه‌ای دارید و تمایل به فروش بیمه نامه دارید از امروز میتوانید با کمترین هزینه و کمترین زمان به زنجیره نوآوری در صنعت بیمه متصل شوید و تجارت جدیدی بسازید

به دلیل گستردگی پروژه و برای دسترسی بهتر، این پروژه به بخش های مختلف تقسیم شده است

و هر بخش در 10 پلتفرم مختلف، ارایه شده است

در این بخش، به وب سرویس های مربوط به صفحه ی لندینگ مرکز بیمه، دسترسی خواهید داشت که

اطلاعات هر پلتفرم را میتوانید بصورت تجمیعی در آدرس زیر مشاهده نمایید

https://www.apimatic.io/apidocs/easybimehlanding

و یا بصورت مجزا در آدرس های زیر قابل درسترس می باشند

1- Android: https://github.com/kmelodi/EasyBimehLanding_Android

2- .Net: https://github.com/kmelodi/EasyBimehLanding_.NET

3- Ios: https://github.com/kmelodi/EasyBimehLanding_IOS

4- Java: https://github.com/kmelodi/EasyBimehLanding_JAVA

5- Php: https://github.com/kmelodi/EasyBimehLanding_PHP

6- Python: https://github.com/kmelodi/EasyBimehLanding_Python

7- Ruby: https://github.com/kmelodi/EasyBimehLanding_Ruby

8- Angular: https://github.com/kmelodi/EasyBimehLanding_Angular

9- NodeJs: https://github.com/kmelodi/EasyBimehLanding_NodeJs

10- Go: https://github.com/kmelodi/EasyBimehLanding_Go

برای اطلاعات بیشتر به آدرس زیر مراجعه نمایید

https://easybimeh.com/ebconnect

How to Build

The generated SDK relies on Node Package Manager (NPM) being available to resolve dependencies. If you don't already have NPM installed, please go ahead and follow instructions to install NPM from here. The SDK also requires Node to be installed. If Node isn't already installed, please install it from here

NPM is installed by default when Node is installed

To check if node and npm have been successfully installed, write the following commands in command prompt:

  • node --version
  • npm -version

Version Check

Now use npm to resolve all dependencies by running the following command in the root directory (of the SDK folder):

npm install

Resolve Dependencies

Resolve Dependencies

This will install all dependencies in the node_modules folder.

Once dependencies are resolved, you will need to move the folder EasyBimehLandingLib in to your node_modules folder.

How to Use

The following section explains how to use the library in a new project.

1. Open Project Folder

Open an IDE/Text Editor for JavaScript like Sublime Text. The basic workflow presented here is also applicable if you prefer using a different editor or IDE.

Click on File and select Open Folder.

Open Folder

Select the folder of your SDK and click on Select Folder to open it up in Sublime Text. The folder will become visible in the bar on the left.

Open Project

2. Creating a Test File

Now right click on the folder name and select the New File option to create a new test file. Save it as index.js Now import the generated NodeJS library using the following lines of code:

var lib = require('lib');

Save changes.

Create new file

Save new file

3. Running The Test File

To run the index.js file, open up the command prompt and navigate to the Path where the SDK folder resides. Type the following command to run the file:

node index.js

Run file

How to Test

These tests use Mocha framework for testing, coupled with Chai for assertions. These dependencies need to be installed for tests to run. Tests can be run in a number of ways:

Method 1 (Run all tests)

  1. Navigate to the root directory of the SDK folder from command prompt.
  2. Type mocha --recursive to run all the tests.

Method 2 (Run all tests)

  1. Navigate to the ../test/Controllers/ directory from command prompt.
  2. Type mocha * to run all the tests.

Method 3 (Run specific controller's tests)

  1. Navigate to the ../test/Controllers/ directory from command prompt.
  2. Type mocha Easy Bimeh LandingController to run all the tests in that controller file.

To increase mocha's default timeout, you can change the TEST_TIMEOUT parameter's value in TestBootstrap.js.

Run Tests

Initialization

API client can be initialized as following:

const lib = require('lib');

Class Reference

List of Controllers

Class: FileManagerController

Get singleton instance

The singleton instance of the FileManagerController class can be accessed from the API Client.

var controller = lib.FileManagerController;

Method: upload

آپلود فایل در ایزی بیمه بعد از آپلود، ادرس فایل باید در api های بعدی ارسال شود.

function upload(subDomain, xApiKey, file, callback)

Parameters

Parameter Tags Description
subDomain Required دامنه یا زیر دامنه ی مرکز بیمه
xApiKey Required کلید اختصاصی ارتباط با سرور
file Required فایل ارسالی

Example Usage

    var subDomain = 'hfz1';
    var xApiKey = 'd6dfd932-75d8-e911-811a-000c294ecf01';
    var file = '';

    controller.upload(subDomain, xApiKey, file, function(error, response, context) {

    
    });

Back to List of Controllers

Class: LiabilityDoctorInsuranceController

Get singleton instance

The singleton instance of the LiabilityDoctorInsuranceController class can be accessed from the API Client.

var controller = lib.LiabilityDoctorInsuranceController;

Method: getLiabilityDoctorInsurance

در یافت اطلاعات اولیه برای استعلام بیمه مسئولیت پزشکان

function getLiabilityDoctorInsurance(subDomain, xApiKey, callback)

Parameters

Parameter Tags Description
subDomain Required دامنه یا زیر دامنه ی مرکز بیمه
xApiKey Required کلید اختصاصی ارتباط با سرور

Example Usage

    var subDomain = 'hfz1';
    var xApiKey = 'd6dfd932-75d8-e911-811a-000c294ecf01';

    controller.getLiabilityDoctorInsurance(subDomain, xApiKey, function(error, response, context) {

    
    });

Method: getMedicalSpecialties

دریافت لیست تخصص های پزشکی

function getMedicalSpecialties(id, xApiKey, callback)

Parameters

Parameter Tags Description
id Required نوع تخصص => ParamedicalExpertise => پیراپزشکی MedicalExpertise => پزشکی
xApiKey Required کلید اختصاصی ارتباط با سرور

Example Usage

    var id = 'ParamedicalExpertise';
    var xApiKey = 'd6dfd932-75d8-e911-811a-000c294ecf01';

    controller.getMedicalSpecialties(id, xApiKey, function(error, response, context) {

    
    });

Back to List of Controllers

Class: CarBodyController

Get singleton instance

The singleton instance of the CarBodyController class can be accessed from the API Client.

var controller = lib.CarBodyController;

Method: getCarBrand

دریافت برند خودرو

function getCarBrand(xApiKey, callback)

Parameters

Parameter Tags Description
xApiKey Required شناسه ی اختصاصی ارتباط با سرور

Example Usage

    var xApiKey = 'd6dfd932-75d8-e911-811a-000c294ecf01';

    controller.getCarBrand(xApiKey, function(error, response, context) {

    
    });

Method: getCarBrandTips

دریافت لیست تیپ خودرو

function getCarBrandTips(carBrandId, xApiKey, callback)

Parameters

Parameter Tags Description
carBrandId Required شناسه ی برند خودرو
xApiKey Required کلید اختصاصی ارتباط با سرور

Example Usage

    var carBrandId = 190;
    var xApiKey = 'd6dfd932-75d8-e911-811a-000c294ecf01';

    controller.getCarBrandTips(carBrandId, xApiKey, function(error, response, context) {

    
    });

Method: getHasPlan

آیا این نوع بیمه نامه، طرح بیمه ای دارد؟

function getHasPlan(subDomain, insurancePolicyType, xApiKey, callback)

Parameters

Parameter Tags Description
subDomain Required دامنه یا زیر دامنه ی مرکز بیمه
insurancePolicyType Required شناسه ی نوع بیمه نامه => بیمه بدنه=2
xApiKey Required کلید اختصاصی ارتباط با سرور

Example Usage

    var subDomain = 'hfz1';
    var insurancePolicyType = 2;
    var xApiKey = 'd6dfd932-75d8-e911-811a-000c294ecf01';

    controller.getHasPlan(subDomain, insurancePolicyType, xApiKey, function(error, response, context) {

    
    });

Back to List of Controllers

Class: ElectronicEquipmentInsuranceController

Get singleton instance

The singleton instance of the ElectronicEquipmentInsuranceController class can be accessed from the API Client.

var controller = lib.ElectronicEquipmentInsuranceController;

Method: getElectronicEquipmentInsurance

دریافت اطلاعات اولیه استعلام بیمه نامه ی تجهیزات الکترونیک

function getElectronicEquipmentInsurance(subDomain, xApiKey, callback)

Parameters

Parameter Tags Description
subDomain Required دامنه یا زیر دامنه ی مرکز بیمه
xApiKey Required کلید اختصاصی ارتباط با سرور

Example Usage

    var subDomain = 'subDomain';
    var xApiKey = 'x-api-key';

    controller.getElectronicEquipmentInsurance(subDomain, xApiKey, function(error, response, context) {

    
    });

Method: getDeviceBrandTypes

دریافت لیست نوع برند دستگاه

function getDeviceBrandTypes(deviceGroup, deviceTypeId, xApiKey, callback)

Parameters

Parameter Tags Description
deviceGroup Required شناسه ی گروه دستگاه
deviceTypeId Required شناسه ی نوع دستگاه
xApiKey Required کلید اختصاصی ارتباط با سرور

Example Usage

    var deviceGroup = 1;
    var deviceTypeId = 1;
    var xApiKey = 'd6dfd932-75d8-e911-811a-000c294ecf01';

    controller.getDeviceBrandTypes(deviceGroup, deviceTypeId, xApiKey, function(error, response, context) {

    
    });

Method: getDiviceFranchisee

دریافت لیست فرانشیر استعلام بیمه نامه ی تجهیزات الکترونیک

function getDiviceFranchisee(deviceModelId, xApiKey, callback)

Parameters

Parameter Tags Description
deviceModelId Required شناسه ی مدل دستگاه
xApiKey Required کلید اختصاصی ارتباط با سرور

Example Usage

    var deviceModelId = 1340;
    var xApiKey = 'd6dfd932-75d8-e911-811a-000c294ecf01';

    controller.getDiviceFranchisee(deviceModelId, xApiKey, function(error, response, context) {

    
    });

Back to List of Controllers

Class: OtherInsuranceTypesController

Get singleton instance

The singleton instance of the OtherInsuranceTypesController class can be accessed from the API Client.

var controller = lib.OtherInsuranceTypesController;

Method: getOtherInsuranceTypes

دریافت لیست سایر بیمه نامه ها

function getOtherInsuranceTypes(subDomain, xApiKey, callback)

Parameters

Parameter Tags Description
subDomain Required دامنه یا زیر دامنه ی مرکز بیمه
xApiKey Required کلید اختصاصی ارتباط با سرور

Example Usage

    var subDomain = 'hfz1';
    var xApiKey = 'd6dfd932-75d8-e911-811a-000c294ecf01';

    controller.getOtherInsuranceTypes(subDomain, xApiKey, function(error, response, context) {

    
    });

Method: getSendSmsToken

ارسال توکن تایید شماره تماس، برای احراز هویت کاربر

function getSendSmsToken(mobile, insuranceCentreSubDomain, xApiKey, callback)

Parameters

Parameter Tags Description
mobile Required شماره موبایل
insuranceCentreSubDomain Required دامنه یا زیردامنه ی مرکز بیمه
xApiKey Required کلید اختصاصی ارتباط با سرور

Example Usage

    var mobile = '09018318086';
    var insuranceCentreSubDomain = 'hfz1';
    var xApiKey = 'd6dfd932-75d8-e911-811a-000c294ecf01';

    controller.getSendSmsToken(mobile, insuranceCentreSubDomain, xApiKey, function(error, response, context) {

    
    });

Method: getVerifySmsToken

تایید توکن پیامک شده به کاربر، برای احراز هویت

function getVerifySmsToken(mobile, token, insuranceCentreSubDomain, aliasName, resource, xApiKey, callback)

Parameters

Parameter Tags Description
mobile Required شماره موبایل
token Required توکن دریافتی کاربر از پیامک
insuranceCentreSubDomain Required دامنه یا زیر دامنه ی اختصاصی مرکز بیمه
aliasName Required نام و نام خانوادگی کاربر
resource Required دامنه ی درخواست دهنده
xApiKey Required کلید اختصاصی ارتباط با سرور

Example Usage

    var mobile = '09018318086';
    var token = 27763;
    var insuranceCentreSubDomain = 'hfz1';
    var aliasName = 'علی موسوی';
    var resource = 'https://hfz1.easybimeh.com';
    var xApiKey = 'd6dfd932-75d8-e911-811a-000c294ecf01';

    controller.getVerifySmsToken(mobile, token, insuranceCentreSubDomain, aliasName, resource, xApiKey, function(error, response, context) {

    
    });

Errors

Error Code Error Description
400 Bad Request

Back to List of Controllers

Class: ThirdPartyInsuranceController

Get singleton instance

The singleton instance of the ThirdPartyInsuranceController class can be accessed from the API Client.

var controller = lib.ThirdPartyInsuranceController;

Method: getCarBrands

دریافت لیست برند خودرو ها

function getCarBrands(carTypeGroup, xApiKey, callback)

Parameters

Parameter Tags Description
carTypeGroup Required شناسه ی گروه خودرو
xApiKey Required کلید اختصاصی ارتباط با سرور

Example Usage

    var carTypeGroup = 1;
    var xApiKey = 'd6dfd932-75d8-e911-811a-000c294ecf01';

    controller.getCarBrands(carTypeGroup, xApiKey, function(error, response, context) {

    
    });

Method: getRiskLevel

دریافت لیست تخفیف های بیمه

function getRiskLevel(insurancePolicyType, xApiKey, callback)

Parameters

Parameter Tags Description
insurancePolicyType Required شناسه ی نوع بیمه نامه
xApiKey Required کلید اختصاصی ارتباط با سرور

Example Usage

    var insurancePolicyType = 0;
    var xApiKey = 'd6dfd932-75d8-e911-811a-000c294ecf01';

    controller.getRiskLevel(insurancePolicyType, xApiKey, function(error, response, context) {

    
    });

Method: getCarBrandTips

دریافت لیست تیپ خودرو

function getCarBrandTips(carBrandId, xApiKey, callback)

Parameters

Parameter Tags Description
carBrandId Required شناسه ی برند خودرو
xApiKey Required کلید اختصاصی ارتباط با سرور

Example Usage

    var carBrandId = 190;
    var xApiKey = 'd6dfd932-75d8-e911-811a-000c294ecf01';

    controller.getCarBrandTips(carBrandId, xApiKey, function(error, response, context) {

    
    });

Method: getCarUses

دریافت لیست نوع کاربری خودرو

function getCarUses(carTypeId, xApiKey, callback)

Parameters

Parameter Tags Description
carTypeId Required شناسه ی نوع خودرو
xApiKey Required کلید اختصاصی ارتباط با سرور

Example Usage

    var carTypeId = 103;
    var xApiKey = 'd6dfd932-75d8-e911-811a-000c294ecf01';

    controller.getCarUses(carTypeId, xApiKey, function(error, response, context) {

    
    });

Method: getHasPlan

آیا این نوع بیمه نامه، طرح بیمه ای دارد؟

function getHasPlan(subDomain, insurancePolicyType, xApiKey, callback)

Parameters

Parameter Tags Description
subDomain Required دامنه یا زیر دامنه ی مرکز بیمه
insurancePolicyType Required شناسه ی نوع بیمه
xApiKey Required کلید اختصاصی ارتباط با سرور

Example Usage

    var subDomain = 'hfz1';
    var insurancePolicyType = 0;
    var xApiKey = 'd6dfd932-75d8-e911-811a-000c294ecf01';

    controller.getHasPlan(subDomain, insurancePolicyType, xApiKey, function(error, response, context) {

    
    });

Back to List of Controllers

Class: MotorcycleInsuranceController

Get singleton instance

The singleton instance of the MotorcycleInsuranceController class can be accessed from the API Client.

var controller = lib.MotorcycleInsuranceController;

Method: getCarBrands

دریافت لیست برند موتور سیکلت

function getCarBrands(carTypeGroup, xApiKey, callback)

Parameters

Parameter Tags Description
carTypeGroup Required شناسه ی گروه خودرویی، موتور سیکلت =>0
xApiKey Required کلید اختصاصی ارتباط با سرور

Example Usage

    var carTypeGroup = 0;
    var xApiKey = 'd6dfd932-75d8-e911-811a-000c294ecf01';

    controller.getCarBrands(carTypeGroup, xApiKey, function(error, response, context) {

    
    });

Method: getCarBrandTips

دریافت لیست تیپ موتور سیکلت

function getCarBrandTips(carBrandId, xApiKey, callback)

Parameters

Parameter Tags Description
carBrandId Required شناسه ی برند موتور سیکلت
xApiKey Required کلید اختصاصی ارتباط با سرور

Example Usage

    var carBrandId = 472;
    var xApiKey = 'd6dfd932-75d8-e911-811a-000c294ecf01';

    controller.getCarBrandTips(carBrandId, xApiKey, function(error, response, context) {

    
    });

Method: getHasPlan

آیا این نوع بیمه نامه، طرح بیمه ای دارد؟

function getHasPlan(subDomain, insurancePolicyType, xApiKey, callback)

Parameters

Parameter Tags Description
subDomain Required دامنه یا زیر دامنه ی مرکز بیمه
insurancePolicyType Required شناسه ی نوع بیمه نامه
xApiKey Required کلید اختصاصی ارتباط با سرور

Example Usage

    var subDomain = 'hfz1';
    var insurancePolicyType = 7;
    var xApiKey = 'd6dfd932-75d8-e911-811a-000c294ecf01';

    controller.getHasPlan(subDomain, insurancePolicyType, xApiKey, function(error, response, context) {

    
    });

Back to List of Controllers

Class: FireInsuranceController

Get singleton instance

The singleton instance of the FireInsuranceController class can be accessed from the API Client.

var controller = lib.FireInsuranceController;

Method: getFireInsurance

دریافت اطلاعات پایه بیمه ی آتش سوزی

function getFireInsurance(subDomain, insurancePolicyId, xApiKey, callback)

Parameters

Parameter Tags Description
subDomain Required دامنه یا زیر دامنه ی مرکز بیمه
insurancePolicyId Required شناسه ی بیمه نامه
xApiKey Required کلید اختصاصی ارتباط با سرور

Example Usage

    var subDomain = 'hfz1';
    var insurancePolicyId = 0;
    var xApiKey = 'd6dfd932-75d8-e911-811a-000c294ecf01';

    controller.getFireInsurance(subDomain, insurancePolicyId, xApiKey, function(error, response, context) {

    
    });

Back to List of Controllers

Class: EarthquakeInsuranceController

Get singleton instance

The singleton instance of the EarthquakeInsuranceController class can be accessed from the API Client.

var controller = lib.EarthquakeInsuranceController;

Method: getEarthquake

دریافت اطلاعات پایه ی بیمه ی زلزله

function getEarthquake(subDomain, insurancePolicyId, insurancePolicyType, xApiKey, callback)

Parameters

Parameter Tags Description
subDomain Required دامنه یا زیر دامنه ی مرکز بیمه
insurancePolicyId Required شناسه ی بیمه نامه
insurancePolicyType Required شناسه ی نوع بیمه نامه
xApiKey Required کلید اختصاصی ارتباط با سرور

Example Usage

    var subDomain = 'hfz1';
    var insurancePolicyId = 0;
    var insurancePolicyType = 6;
    var xApiKey = 'd6dfd932-75d8-e911-811a-000c294ecf01';

    controller.getEarthquake(subDomain, insurancePolicyId, insurancePolicyType, xApiKey, function(error, response, context) {

    
    });

Back to List of Controllers

Class: TravelInsuranceController

Get singleton instance

The singleton instance of the TravelInsuranceController class can be accessed from the API Client.

var controller = lib.TravelInsuranceController;

Method: getTravelInsurance

TODO: Add Description

function getTravelInsurance(subDomain, insurancePolicyId, xApiKey, callback)

Parameters

Parameter Tags Description
subDomain Required دامنه یا زیر دامنه ی مرکز بیمه
insurancePolicyId Required شناسه ی بیمه نامه
xApiKey Required کلید اختصاصی ارتباط با سرور

Example Usage

    var subDomain = 'hfz1';
    var insurancePolicyId = 0;
    var xApiKey = 'd6dfd932-75d8-e911-811a-000c294ecf01';

    controller.getTravelInsurance(subDomain, insurancePolicyId, xApiKey, function(error, response, context) {

    
    });

Back to List of Controllers

Class: ElevatorInsuranceController

Get singleton instance

The singleton instance of the ElevatorInsuranceController class can be accessed from the API Client.

var controller = lib.ElevatorInsuranceController;

Method: getElevatorInsurance

دریافت اطلاعات پایه ی بیمه نامه ی آسانسور

function getElevatorInsurance(subDomain, insurancePolicyId, xApiKey, callback)

Parameters

Parameter Tags Description
subDomain Required دامنه یا زیر دامنه ی مرکز بیمه
insurancePolicyId Required شناسه ی بیمه نامه
xApiKey Required کلید اختصاصی ارتباط با سرور

Example Usage

    var subDomain = 'hfz1';
    var insurancePolicyId = 0;
    var xApiKey = 'd6dfd932-75d8-e911-811a-000c294ecf01';

    controller.getElevatorInsurance(subDomain, insurancePolicyId, xApiKey, function(error, response, context) {

    
    });

Back to List of Controllers

Class: MainController

Get singleton instance

The singleton instance of the MainController class can be accessed from the API Client.

var controller = lib.MainController;

Method: getPortalLandingPage

در یافت اطلاعات لندینگ مراکز بیمه

function getPortalLandingPage(id, xApiKey, callback)

Parameters

Parameter Tags Description
id Required دامنه یا زیر دامنه ی مرکز بیمه
xApiKey Required کلید اختصاصی ارتباط با سرور

Example Usage

    var id = 'hfz1';
    var xApiKey = 'd6dfd932-75d8-e911-811a-000c294ecf01';

    controller.getPortalLandingPage(id, xApiKey, function(error, response, context) {

    
    });

Method: getInsuranceCentrePolicyTypes

دریافت لیست بیمه ی های ارائه شده توسط مرکز بیمه

function getInsuranceCentrePolicyTypes(subDomain, xApiKey, callback)

Parameters

Parameter Tags Description
subDomain Required دامنه یا زیر دامنه ی مرکز بیمه
xApiKey Required کلید اختصاصی ارتباط با سرور

Example Usage

    var subDomain = 'hfz1';
    var xApiKey = 'd6dfd932-75d8-e911-811a-000c294ecf01';

    controller.getInsuranceCentrePolicyTypes(subDomain, xApiKey, function(error, response, context) {

    
    });

Back to List of Controllers

Class: ComboDataController

Get singleton instance

The singleton instance of the ComboDataController class can be accessed from the API Client.

var controller = lib.ComboDataController;

Method: getDamageType

دریافت لیست نوع خسارت

function getDamageType(xApiKey, callback)

Parameters

Parameter Tags Description
xApiKey Required کلید اختصاصی ارتباط با سرور

Example Usage

    var xApiKey = 'd6dfd932-75d8-e911-811a-000c294ecf01';

    controller.getDamageType(xApiKey, function(error, response, context) {

    
    });

Method: getInsuranceTypes

دریافت لیست نوع بیمه نامه

function getInsuranceTypes(subDomain, issueInsurance, xApiKey, callback)

Parameters

Parameter Tags Description
subDomain Required دامنه یا زیر دامنه ی مرکز بیمه
issueInsurance Required دریافت بیمه نامه های قابل صدور
xApiKey Required کلید اختصاصی ارتباط با سرور

Example Usage

    var subDomain = 'hfz1';
    var issueInsurance = false;
    var xApiKey = 'd6dfd932-75d8-e911-811a-000c294ecf01';

    controller.getInsuranceTypes(subDomain, issueInsurance, xApiKey, function(error, response, context) {

    
    });

Method: getInsuranceCompanies

دریافت لیست شرکت های بیمه

function getInsuranceCompanies(subDomain, insuranceTypeId, xApiKey, callback)

Parameters

Parameter Tags Description
subDomain Required دامنه یا زیر دامنه ی مرکز بیمه
insuranceTypeId Required شناسه ی نوع بیمه نامه
xApiKey Required کلید اختصاصی ارتباط با سرور

Example Usage

    var subDomain = 'hfz1';
    var insuranceTypeId = 1;
    var xApiKey = 'd6dfd932-75d8-e911-811a-000c294ecf01';

    controller.getInsuranceCompanies(subDomain, insuranceTypeId, xApiKey, function(error, response, context) {

    
    });

Back to List of Controllers

Class: TrackingDamageController

Get singleton instance

The singleton instance of the TrackingDamageController class can be accessed from the API Client.

var controller = lib.TrackingDamageController;

Method: getTrackingCode

استعلام وضعیت خسارت

function getTrackingCode(mTrackingCode, xApiKey, callback)

Parameters

Parameter Tags Description
mTrackingCode Required کد پیگیری خسارت
xApiKey Required کلید اختصاصی ارتباط با سرور

Example Usage

    var mTrackingCode = /{TrackingCode};
    var xApiKey = 'd6dfd932-75d8-e911-811a-000c294ecf01';

    controller.getTrackingCode(mTrackingCode, xApiKey, function(error, response, context) {

    
    });

Errors

Error Code Error Description
400 Bad Request

Method: createTrackingDamage

ثبت خسارت بیمه

function createTrackingDamage(body, xApiKey, contentType, callback)

Parameters

Parameter Tags Description
body Required اطلاعات خسارت
xApiKey Required کلید اختصاصی ارتباط با سرور
contentType Required TODO: Add a parameter description

Example Usage

    var body = new TrackingDamageRequest({
  "personalityType": 0,
  "trackingDamageStatus": [
    {
      "trackingDamageFile": [
        {
          "id": 162747,
          "url": "https://media.easybimeh.com//Easybimeh/FileManager/InsuranceCentre/hfz1/637089119345134776.jpeg",
          "title": "کارت شناسایی"
        }
      ]
    }
  ],
  "description": "بدنه ی خودرو خسارت دیده",
  "insuranceTypeId": 1,
  "insuranceCompanyId": 34,
  "insurancePolicyNumber": "123456",
  "damageType": "مالی",
  "name": "کاظم",
  "nationalCode": "3080118383",
  "mobile": "09018318086",
  "insuredProfile": "پژو 405",
  "subDomain": "hfz1"
});
    var xApiKey = 'd6dfd932-75d8-e911-811a-000c294ecf01';
    var contentType = 'application/json';

    controller.createTrackingDamage(body, xApiKey, contentType, function(error, response, context) {

    
    });

Method: getStatusStatusCollections

دریافت لیست وضعیت های خسارت

function getStatusStatusCollections(statusType, xApiKey, callback)

Parameters

Parameter Tags Description
statusType Required نوع وضعیت ها ی خسارت => 0
xApiKey Required کلید اختصاصی ارتباط با سرور

Example Usage

    var statusType = 0;
    var xApiKey = 'd6dfd932-75d8-e911-811a-000c294ecf01';

    controller.getStatusStatusCollections(statusType, xApiKey, function(error, response, context) {

    
    });

Method: getStatus

دریافت اطلاعات وضعیت

function getStatus(entityId, xApiKey, callback)

Parameters

Parameter Tags Description
entityId Required شناسه ی وضعیت
xApiKey Required کلید اختصاصی ارتباط با سرور

Example Usage

    var entityId = 1129;
    var xApiKey = 'd6dfd932-75d8-e911-811a-000c294ecf01';

    controller.getStatus(entityId, xApiKey, function(error, response, context) {

    
    });

Back to List of Controllers

Class: FooterController

Get singleton instance

The singleton instance of the FooterController class can be accessed from the API Client.

var controller = lib.FooterController;

Method: getPortalLandingContactAbout

دریافت اطلاعات درباره ی ما

function getPortalLandingContactAbout(xApiKey, callback)

Parameters

Parameter Tags Description
xApiKey Required TODO: Add a parameter description

Example Usage

    var xApiKey = 'd6dfd932-75d8-e911-811a-000c294ecf01';

    controller.getPortalLandingContactAbout(xApiKey, function(error, response, context) {

    
    });

Method: getFaqInsuranceCentre

دریافت لیست سوالات متداول

function getFaqInsuranceCentre(xApiKey, callback)

Parameters

Parameter Tags Description
xApiKey Required کلید اختصاصی ارتباط با سرور

Example Usage

    var xApiKey = 'd6dfd932-75d8-e911-811a-000c294ecf01';

    controller.getFaqInsuranceCentre(xApiKey, function(error, response, context) {

    
    });

Method: getInsurancePolicyTracking

پیگیری وضعیت بیمه نامه

function getInsurancePolicyTracking(trackingCode, nationalCode, xApiKey, callback)

Parameters

Parameter Tags Description
trackingCode Required شماره ی پیگیری بیمه نامه
nationalCode Required کد ملی کاربر
xApiKey Required کلید اختصاصی ارتباط با سرور

Example Usage

    var trackingCode = 213981083;
    var nationalCode = 3080115309;
    var xApiKey = 'd6dfd932-75d8-e911-811a-000c294ecf01';

    controller.getInsurancePolicyTracking(trackingCode, nationalCode, xApiKey, function(error, response, context) {

    
    });

Errors

Error Code Error Description
500 Internal Server Error

Back to List of Controllers

Class: InsurancePolicyPlanController

Get singleton instance

The singleton instance of the InsurancePolicyPlanController class can be accessed from the API Client.

var controller = lib.InsurancePolicyPlanController;

Method: getSpecialPlan

دریافت لیست طرح های بیمه ای

function getSpecialPlan(subDomain, xApiKey, callback)

Parameters

Parameter Tags Description
subDomain Required دامنه یا زیر دامنه ی مرکز بیمه
xApiKey Required کلید اختصاصی ارتباط با سرور

Example Usage

    var subDomain = 'hfz1';
    var xApiKey = 'd6dfd932-75d8-e911-811a-000c294ecf01';

    controller.getSpecialPlan(subDomain, xApiKey, function(error, response, context) {

    
    });

Back to List of Controllers

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published