0% found this document useful (0 votes)
141 views22 pages

Policy API Manual v2.1 - Asego

Uploaded by

bholejaiswal
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
141 views22 pages

Policy API Manual v2.1 - Asego

Uploaded by

bholejaiswal
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 22

Policy API – Manual

Version: 2.1
Revision: 01/Apr/2013

POLICY API - CALLS MANUAL

Page 1 of 22
Policy API – Manual
Version: 2.1
Revision: 01/Apr/2013

Revision History
Date Paragraph Description of the revision
09-Jan-2012 2.1 Request Parameter
15-Feb-2012 2.1 Request Parameter
The datatypes for the PlanCode, RiderCode, Category code is
17-Feb-2012 2.1 Change in response
changed to String.
18-Feb-2012 Annexure #1 Annexure added for data strutures
27-Mar-2012 2.1 Response Parameter New fields for Reference No & Claim Code added
28-Mar-2012 2.1 API Call Updated the URL call & added webservice call details
3-Apr-2012 2.1 API Call Added new field “policycomment” in the “otherdetails” tag.
3-Apr-2012 2.1 API Call Use Ref as IV for the encryption
1-Apr-2013 New url for the modified API calls
Added new field Passengerreference in Create Policy &
1-Apr-2013
Endorse Policy Calls

Page 2 of 22
Policy API – Manual
Version: 2.1
Revision: 01/Apr/2013

1. Variable conventions

String
X: number of integer digits. Y:
number of decimal digits.
Numeric(X.Y)
Decimal separator: DOT No
thousand separator.
0 : False
Boolean 1 : True
Date DDMMYYYY

Time HHMMSS

String Characters including special characters

Page 3 of 22
Policy API – Manual
Version: 2.1
Revision: 01/Apr/2013

2. API call
2.1. Create Policy
Descriptio n This call will be made to create a policy. Use “POST” method to send data to the api call.

Live URL https://travel.asego.in/API/v2/CreatePolicy.aspx

Test URL https://asegotravel.in/trawelltag/v2/CreatePolicy.aspx


Live URL https://travel.asego.in/API/v2/AgentAPIV2.asmx?WSDL
WebServic e Web CreatePolicy
Method
Test URL https://asegotravel.in/trawelltag/v2/AgentAPIV2.asmx?WSDL
WebServic e Web CreatePolicy
Method
Method POST
Parameter Data type Remarks
This will be a Base64 encoded string.
The steps for generating this will be as
follows:
➢ Create XML as per the below
template.
➢ The “signature” / “sign” shared
with you should be used as
public key.
➢ Encrypt the XML using the
Data String
public key assigned to you.
Use Rijndael Encryption
Algorithm with 256 Keybits
for encrypting XML. The
public key shared with you
should be used as “key” for
encrypting the XML.
➢ Encode the encrypted data
Request into Base64 string
parameter This will be the reference id of the API
s caller. The Reference ID will be provided
Ref String by Asego Group. This has to be used as
an Initialization Vector
for the Encryption / Decryption.

Page 4 of 22
Policy API – Manual
Version: 2.1
Revision: 01/Apr/2013

Example:
Data=YTM0NZomIzI2OTsmIzM0NTueYQ==&Ref=c976b23c-646e-4765-9357-
38a28f7bac42

XML structure as follows:

<policy>
<identity>
<sign>String</sign>
<branchsign>String</branchsign>
<username>String</username>
<reference>String</reference>
</identity>
<plan>
<categorycode>String</categorycode>

Page 5 of 22
Policy API – Manual
Version: 2.1
Revision: 01/Apr/2013

<plancode>String</plancode>
<basecharges>Numeric(18,2)</basecharges>
<riders>
<ridercodepercent="Numeric(18,2)">String</ridercode>
<ridercodepercent="Numeric(18,2)">String</ridercode>
<ridercodepercent="Numeric(18,2)">String</ridercode>
</riders>
<totalbasecharges>Numeric(18,2)</totalbasecharges>
<servicetax>Numeric(18,2)</servicetax>
<totalcharges>Numeric(18,2)</totalcharges>
</plan>
<traveldetails>
<departuredate>Date</departuredate>
<days>Numeric(18,0)</days>
<arrivaldate>Date</arrivaldate>
</traveldetails>
<passengerreference>varchar(300)</ passengerreference>
<insured>
<passport>String</passport>
<contactdetails>
<address1>String</address1>
<address2>String</address2>
<city>String</city>
<district>String</district>
<state>String</state>
<pincode>String</pincode>
<country>String</country>
<phoneno>String</phoneno>
<mobileno>String</mobileno>
<emailaddress>String</emailaddress>
</contactdetails>
<name>String</name>
<dateofbirth>Date(dd-mmm-yyyy)</dateofbirth>
<age>Numeric(18,0)</age>
<trawelltagnumber>Numeric(18,0)</trawelltagnumber>
<nominee>String</nominee>
<relation>String</relation>
<pastillness>String</pastillness>
</insured>
<otherdetails>
<policycomment>String</policycomment>
<universityname>String</universityname>
<universityaddress>String</universityaddress>
<documents>
<documentcodeavailable="boolean">Numeric(18,0)</documentcode>
<documentcodeavailable="boolean">Numeric(18,0)</documentcode>
<documentcodeavailable="boolean">Numeric(18,0)</documentcode>
</documents>
</otherdetails>
</policy>

DataTyp Require
Element e Size d Remark
Sign String 100 Yes Agent Signature,
this will be shared
by Asego as part of
the test credentials
api kit

Page 6 of 22
Policy API – Manual
Version: 2.1
Revision: 01/Apr/2013
BranchSign String 100 Yes Branch Signature,
this will be shared
by Asego as part of
the test credentials
api kit
User Name of the Agent
UserName String 100 Yes Employee, this will be shared
by Asego as part of the test
credentials api kit

Page 7 of 22
Policy API – Manual
Version: 2.1
Revision: 01/Apr/2013

Reference String 100 Yes Your reference no., the local


system consuming the api will
be generating a unique
alphanumeric or numeric
reference number
PassportNumber String 20 No Passport Number, the field is
mandatory for international
travel and optional for Nepal
CategoryCode String 50 Yes Insurance Category, this will
be shared by Asego as part
of the api kit. The local
system shall store the
category in the database or
any storage format
PlanCode String 50 Yes Policy Plan Code, this will be
shared by Asego as part of
the api kit. The local system
shall store the plans in the
database or any storage
format. Based on the age,
travel days and plans
configured for the
partner/agent, the plans
shall be displayed for the
traveller(s). Based on the
applicant type, the plans will
be displayed from the local
system and two separate api
calls shall be initiated for
different applicant type.(E.g.
Student and/or others)
Datetim
DepartureDate e Yes Departure Date
Days Numeric Yes No of Travel Days
Datetim
ArrivalDate e Yes Arrival Date
Passenger Reference
Passengerreference Varchar 300 No
Address1 String 500 Yes Address Line 1
Address2 String 500 No Address Line 2
City String 50 Yes City
District String 50 Yes District
State String 50 Yes State
PinCode String 10 Yes Pin Code
Country String 100 Yes Country
PhoneNo String 50 No Phone No
MobileNo String 50 Yes Mobile No
100
PolicyComment String 0 No Policy Comment

Page 8 of 22
Policy API – Manual
Version: 2.1
Revision: 01/Apr/2013
100
UniversityAddress String 0 No University Address
Name String 50 Yes Insured Name
Datetim
DateofBirth e Yes Insured Date of Birth
Age Numeric Yes Insured Age
TrawellTagNumber Numeric No Trawell Tag Number
Nominee String 50 Yes Nominee Name, if not
captured “LEGAL HEIR” will
be set by the local system
Relation String 50 Yes Nominee Relation, if not
captured “LEGAL HEIR” will
be set by the local system
100
PastIllness String 0 No Past Illness
EmailAddress String 50 Yes Insured Email Address
Base Charges Numeric Yes Base Charges
Total Base Charges
Total Base Charges Numeric Yes including Riders
Service Tax Numeric Yes Service Tax
TotalCharges Numeric Yes Total / Net Charges
RiderCode String 50 No Rider Code
DocumentCode Numeric No Document Code
Available Boolean Yes If Document Code is
available and set then
this variable will identify
whether the document is
available? The value will be
set as “True” else “False”.

Page 9 of 22
Policy API – Manual
Version: 2.1
Revision: 01/Apr/2013

XML structure as follows:

<data>
<status>String</status>
<policy>String</policy>
<document>String</document>
<reference>String</reference>
<claimcode>String</claimcode>
<errorcode>String</errorcode>
<message>String</message>
</data>

Where:

Parameter Data type Remarks


This could be any of the following
value:
• Ok
• Error
• Retry

If the status is “Ok” then the policy is


generated and the policy number is
assigned in the “Policy” element.
The document element will contain the
Response Status String Policy PDF document file URL.

If the status is “Error” then the policy


could not be generated and the reason
will be in the “Message” element and
the error code will be in the “ErrorCode”
element.

If the status is “retry” then the policy is


not generated and the request can be
re-sent for policy creation.
Policy String Policy Number
This will be URL to the Policy PDF
Document String document that is generated on the
server.
This is the “Your Reference No”
Reference String which is sent within the XML in the
request.
ClaimCode String This is the claim code number.

ErrorCode String Error Code


In case of error, the user friendly
Message String
message will be sent here

Page 10 of
22
Policy API – Manual
Version: 2.1
Revision: 01/Apr/2013

2.2. EndorsePolicy
This call will be made to start the endorsement. The call to this API call will return the
Description
policy details.
URL https://travel.asego.in/API/v2/EndorsePolicy.aspx
URL https://travel.asego.in/API/v2/AgentAPIV2.asmx?WSDL
WebService Web EndorsePolicy
Method
Method POST
Parameter Data type Remarks
This will be a Base64 encoded string.
The steps for generating this will be as
follows:
➢ Create XML as per the below
template.
➢ The “signature” / “sign” shared
with you should be used as
public key.
➢ Encrypt the XML using the
Data String
public key assigned to you.
Use Rijndael Encryption
Algorithm with 256 Keybits
for encrypting XML. The
public key shared with you
should be used as “key” for
encrypting the XML.
➢ Encode the encrypted data
into Base64 string
This will be the reference id of the API
caller. The Reference ID will be provided
Ref String by Asego Group. This has
to be used as an Initialization Vector for
Request the Encryption / Decryption.
parameters
Example:
Data=YTM0NZomIzI2OTsmIzM0NTueYQ==&Ref=c976b23c-646e-4765- 9357-
38a28f7bac42

XML structure as follows:

<policy>
<identity>
<sign>String</sign>
<branchsign>String</branchsign>
<username>String</username>
<policynumber>String</policynumber>
</identity>
</policy>

Element DataType Size Required Remark


Sign String 100 Yes Agent Signature
BranchSign String 100 Yes Branch Signature

Page 11 of
22
Policy API – Manual
Version: 2.1
Revision: 01/Apr/2013
User Name of the
UserName String 100 Yes Agent Employee

Page 12 of
22
Policy API – Manual
Version: 2.1
Revision: 01/Apr/2013

Policy number that


PolicyNumber String 100 Yes has to be endorsed

Page 13 of
22
Policy API – Manual
Version: 2.1
Revision: 01/Apr/2013

XML structure as follows:

<?xml version="1.0" encoding="utf-8" ?>


<data>
<status>String</status>
<policynumber>String</policynumber>
<reference>String</reference>
<errorcode>String</errorcode>
<message>String</message>
<key>String</key>
<policy>
<plan>
<categorycode>String</categorycode>
<plancode>String</plancode>
<riders>
<ridercode>String</ridercode>
<ridercode>String</ridercode>
<ridercode>String</ridercode>
</riders>
<restricted>Boolean</restricted>
</plan>
<traveldetails>
<departuredate>Date</departuredate>
<days>Numeric(18,0)</days>
<arrivaldate>Date</arrivaldate>
</traveldetails>
<insured>
<passport>String</passport>
<contactdetails>
<address1>String</address1>
<address2>String</address2>
Response
<city>String</city>
<district>String</district>
<state>String</state>
<pincode>String</pincode>
<country>String</country>
<phoneno>String</phoneno>
<mobileno>String</mobileno>
<emailaddress>String</emailaddress>
</contactdetails>
<name>String</name>
<dateofbirth>Date</dateofbirth>
<age>Numeric(18,0)</age>
<trawelltagnumber>Numeric(18,0)</trawelltagnumber>
<nominee>String</nominee>
<relation>String</relation>
<pastillness>String</pastillness>
<passengerreference>varchar(300)</passengerreference>
</insured>
<otherdetails>
<policycomment>String</policycomment>
<universityname>String</universityname>
<universityaddress>String</universityaddress>
</otherdetails>
</policy>
</data>

Where:

Page 14 of 22
Policy API – Manual
Version: 2.1
Revision: 01/Apr/2013

Parameter Data type Remarks


This could be any of the following
value:
• Ok
• Error
• Retry

If the status is “Ok” then the


policy is generated and the policy
number is assigned in the “Policy”
element. The document element
will contain the Policy PDF
document file URL.
Status String
If the status is “Error” then the
policy could not be generated and
the reason will be in the
“Message” element and the error
code will be in the “ErrorCode”
element.

If the status is “retry” then the


policy is not generated and the
request can be re-sent for policy
creation.
PolicyNumber String Policy Number
This is the “Your Reference No”
Reference String which is sent within the XML in
the request.
ErrorCode String Error Code
In case of error, the user
Message String friendly message will be sent here

This will be Key which have to be


sent alongwith the next call
Key String
i.e. when calling the
EndorsementRequest API call.
CategoryCode String Insurance Category
PlanCode String Policy Plan Code
RiderCode String Rider Code
Restricted Boolean Restricted Coverage
DepartureDate Datetime Departure Date
Days Numeric No of Travel Days
ArrivalDate Datetime Arrival Date
PassportNumber String Passport Number
Address1 String Address Line 1
Address2 String Address Line 2
City String City
District String District
State String State
PinCode String Pin Code
Page 15 of 22
Policy API – Manual
Version: 2.1
Revision: 01/Apr/2013

Country String Country


PhoneNo String Phone No
MobileNo String Mobile No
EmailAddress String Insured Email Address
Name String Insured Name
DateofBirth Datetime Insured Date of Birth
Age Numeric Insured Age
TrawellTagNumber Numeric Trawell Tag Number
Nominee String Nominee Name
Relation String Nominee Relation
passengerreference varchar Passenger Reference
PastIllness String Past Illness
PolicyComment String Policy Comment
UniverstiryName String University Name
UniversityAddress String University Address

Page 16 of 22
Policy API – Manual
Version: 2.1
Revision: 01/Apr/2013

2.3. EndorsePolicyDetails
This call will be made to start the endorsement. The call to this API call will return the
Description
policy details.
https://travel.asego.in/API/v2/EndorsePolicyDetails.asp x
URL
URL https://travel.asego.in/API/v2/AgentAPIV2.asmx?WSDL
WebServic e
Web EndorsePolicyDetails
Method
Method POST
Parameter Data type Remarks
This will be a Base64 encoded string.
The steps for generating this will be as
follows:
➢ Create XML as per the below
template.
➢ The “signature” / “sign” shared
with you should be used as
public key.
➢ Encrypt the XML using the
Data String
public key assigned to you.
Use Rijndael Encryption
Algorithm with 256 Keybits
for encrypting XML. The
public key shared with you
should be used as “key” for
encrypting the XML.
➢ Encode the encrypted data
into Base64 string
This will be the reference id of the API
caller. The Reference ID will be provided
Ref String by Asego Group. This has
Request to be used as an Initialization Vector for
parameters the Encryption / Decryption.

Example:
Data=YTM0NZomIzI2OTsmIzM0NTueYQ==&Ref=c976b23c-646e-4765-9357-
38a28f7bac42

XML structure as follows:

<?xml version="1.0" encoding="utf-8"?>


<policy>
<identity>
<sign>String</sign>
<branchsign>String</branchsign>
<username>String</username>
<reference>String</reference>
<key>String</key>
<policynumber>String</policynumber>
</identity>
<plan>
<categorycode>String</categorycode>
<plancode>String</plancode>
<riders>
<ridercode percent="Numeric(18,2)">String</ridercode>

Page 17 of 22
Policy API – Manual
Version: 2.1
Revision: 01/Apr/2013
<ridercode percent="Numeric(18,2)">String</ridercode>

Page 18 of 22
Policy API – Manual
Version: 2.1
Revision: 01/Apr/2013

<ridercode percent="Numeric(18,2)">String</ridercode>
</riders>
<restricted>Boolean</restricted>
</plan>
<traveldetails>
<departuredate>Date</departuredate>
<days>Numeric(18,0)</days>
<arrivaldate>Date</arrivaldate>
</traveldetails>
<insured>
<passport>String</passport>
<contactdetails>
<address1>String</address1>
<address2>String</address2>
<city>String</city>
<district>String</district>
<state>String</state>
<pincode>String</pincode>
<country>String</country>
<phoneno>String</phoneno>
<mobileno>String</mobileno>
<emailaddress>String</emailaddress>
</contactdetails>
<name>String</name>
<dateofbirth>Date(dd-mmm-yyyy)</dateofbirth>
<age>Numeric(18,0)</age>
<trawelltagnumber>Numeric(18,0)</trawelltagnumber>
<nominee>String</nominee>
<relation>String</relation>
<pastillness>String</pastillness>
<passengerreference>varchar</passengerreference>
</insured>
<otherdetails>
<policycomment>String</policycomment>
<universityname>String</universityname>
<universityaddress>String</universityaddress>
<documents>
<documentcode>Numeric(18,0)</documentcode>
<documentcode>Numeric(18,0)</documentcode>
<documentcode>Numeric(18,0)</documentcode>
</documents>
</otherdetails>
</policy>

DataTyp
Element e Size Required Remark
Sign String 100 Yes Agent Signature
BranchSign String 100 Yes Branch Signature
User Name of the
UserName String 100 Yes Agent Employee
Reference String 100 Yes Your reference no.
Key that was sent in
the response XML for
the EndorsePolicy API
Key String 100 Yes call
PolicyNumber String 100 Yes Policy Number

Page 19 of 22
Policy API – Manual
Version: 2.1
Revision: 01/Apr/2013

PassportNumber String 20 No Passport Number


CategoryCode String 50 Yes Insurance Category
PlanCode String 50 Yes Policy Plan Code
DepartureDate Datetime Yes Departure Date
Days Numeric Yes No of Travel Days
ArrivalDate Datetime Yes Arrival Date
Address1 String 500 Yes Address Line 1
Address2 String 500 No Address Line 2
City String 50 Yes City
District String 50 Yes District
State String 50 Yes State
PinCode String 10 Yes Pin Code
Country String 100 Yes Country
PhoneNo String 50 No Phone No
MobileNo String 50 Yes Mobile No
100
PolicyComment String 0 No Policy Comment
100
UniversityAddress String 0 No University Address
Name String 50 Yes Insured Name
DateofBirth Datetime Yes Insured Date of Birth
Age Numeric Yes Insured Age
TrawellTagNumber Numeric No Trawell Tag Number
Nominee String 50 Yes Nominee Name
Relation String 50 Yes Nominee Relation
100
PastIllness String 0 No Past Illness

passengerreference varchar 300 No Passenger Reference


EmailAddress String 50 Yes Insured Email Address
Restricted coverage for
Restricted Boolean Yes the policy ?
RiderCode String 50 No Rider Code
DocumentCode Numeric No Document Code

Page 20 of 22
Policy API – Manual
Version: 2.1
Revision: 01/Apr/2013

XML structure as follows:

<data>
<status>String</status>
<policy>String</policy>
<document>String</document>
<reference>String</reference>
<requestnumber>String</requestnumber>
<errorcode>String</errorcode>
<message>String</message>
</data>

Where:

Parameter Data type Remarks


This could be any of the following
value:
• Ok
• Error
• Retry

If the status is “Ok” then the policy is


generated and the policy number is
assigned in the “Policy” element.
The document element will contain the
Status String Policy PDF document file URL.

If the status is “Error” then the policy


could not be generated and the reason
Response will be in the “Message” element and
the error code will be in the “ErrorCode”
element.

If the status is “retry” then the policy is


not generated and the request can be
re-sent for policy creation.
Policy String Policy Number
This will be URL to the Policy PDF
Document String document that is generated on the
server.
In case the endorsement is not auto
approved i.e. it needs approval by the
underwriter, a request number will be
returned. This is the Endorsement
RequestNumber String
Request Number and an email will
be sent to the
authorised email id when the
endorsement is approved / rejected.
This is the “Your Reference No”
Reference String which is sent within the XML in the
request.
ClaimCode String This is the claim code number.

ErrorCode String Error Code


In case of error, the user friendly
Message String
message will be sent here
Page 21 of 22
Policy API – Manual
Version: 2.1
Revision: 01/Apr/2013

Annexure # 1
Following data structures shall be sent as part of the test credentials:

• API Caller Identification


• API Caller Branches
• API Caller Users
• Category
• Plans
• Premium Chart
• Plan Riders

Page 22 of 22

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy