Archive
SWS UpdateInsurance Method
Changes the existing insurance coverage to a different insurance coverage. This will not add insurance if the customer doesn’t currently have existing coverage.
Parameters
Name | Data Type | Required |
---|---|---|
SiteID | Long | Required |
Description | The site’s ID number. This can be found using the GetSiteList method. | |
RentalID | Long | Required |
Description | The rental item’s ID number. This is returned when using the MakeReservation method or can be searched for using the SearchBy method. | |
NewInsuranceOptionID | Long | Required |
Description | The id for the specific insurance option to which you are chaning the rental. Use the INS_OPTION_ID from the GetInsuranceProviders method. |
Returned Parameters
Name | Data Type |
---|---|
CreditsReturned | Decimal |
Description | The amount of funds returned to the customer due to the change of insurance. |
AmountDueAfterUpdate | Decimal |
Description | The amount of funds owed on the account due to the change of insurance. |
TransactionID | Long |
Description | The transaction’s ID number. Transaction IDs are system generated for each transaction that occurs in the system. A null or “0” response indicates the transaction failed. |
InsuranceRentalID | Long |
Description | The RentalID applicable to the new insurance assessment. |
Example
As with every method we need to pass in credentials. We do this with the LookupUser request object.
As with every method we need to pass in credentials. We do this with the LookupUser request object.
We will assume you have a web reference, let us name it SWS, in your Visual Studio project. At this point we need to define our objects. We will need the standard service object, an UpdateInsurance request object, and an UpdateInsurance response object. We can define and create those like this:
// Create a request and response objects
SWS.WSSoapClient service = new SWS.WSSoapClient();
SWS.UpdateInsurance_Request request = new SWS.UpdateInsurance_Request();
SWS.UpdateInsurance_Response response;
Here is a sample code of the request object:
// UpdateInsurance Request
request.SiteID = 123456;
request.RentalID = 126456;
request.NewInsuranceOptionID = 123456;
Finally we can call the method and pass across the login object and the request object to retrieve our requested information. It’s a good idea to do this in a Try Catch block.
// Call the method that will load the response object
try
{
response = service.UpdateInsurance(user_request, request);
}
catch (Exception ex)
{
MessageBox.Show(ex.Message);
}
Note that if something goes wrong the service will respond with an exception. You will want to capture the message in the exception so it can be debugged.
For a full list of methods see SWS Methods.
SWS GetInsuranceInfo Method
Retrieves a collection of insurance data for the specified site, date and all or part of the account or contact name.
Parameters
Name | DataType | Is Required |
---|---|---|
AccountOrContactName | String | Required |
Description | The first and last name of the rental contact or the account name. Max string length of 101. | |
ClaimDate | DateTime | Required |
Description | The date for which you wish to retrieve the insurance details. | |
SiteID | Long | Required |
Description | The site’s ID number. This can be found using the GetSiteList method. |
Returned Parameters
Name | DataType |
---|---|
ACCOUNT_CONTACT_NAME | String |
Description | The first and last name of the rental contact. |
ACCOUNT_NAME | String |
Description | The name on the account. This may differ from the primary contact’s name in some instances, such as a business account or a guardianship account. |
ADDRESS | String |
Description | The full address for the contact. This will include all applicable address lines. |
CITY | String |
Description | The city for the address. |
DIMENSIONS | String |
Description | The dimensions for the rental item. |
INS_COVERAGE_AMT | Decimal |
Description | The insurance coverage amount on the rental item. |
INS_COVERAGE_PERC | Decimal |
Description | The insurance coverage percentage on the rental item. |
INS_END_DATE | DateTime |
Description | The date that insurance was cancelled from the rental. |
INS_EVENT | String |
Description | The value of whether the rental item was covered by insurance on the date specified. |
INS_RATE | Decimal |
Description | The monthly insurance coverage rate for the rental item. |
INS_START_DATE | DateTime |
Description | The date that insurance was first added to the rental. |
LEASE_START | DateTime |
Description | The date the customer initiated the rental. |
PAID_THRU_DATE | DateTime |
Description | The date through which a customer has paid for their rental. |
PHONE_NUMBER | String |
Description | The primary contact’s phone number. |
POSTAL_CODE | String |
Description | The postal/ZIP code for the address. |
RECORD_DATE | DateTime |
Description | The date and time the insurance details were retrieved. |
RECORD_TYPE | String |
Description | The type of record. |
RENTAL_ID | Long |
Description | The rental item’s ID number. |
SITE_ID | Long |
Description | The site’s ID number. |
SITE_NAME | String |
Description | The site’s name. |
SS_DATE | DateTime |
Description | The date and time the insurance details were retrieved. |
STATE | String |
Description | The state/province for the address. |
UNIT_ID | Long |
Description | The units ID number. This is maintained through rentals. |
UNIT_NUMBER | String |
Description | The unit’s number as assigned by the organization. This is not the UnitID. |
UNIT_TYPE | String |
Description | The type of object being rented. |
Example
We’ll assume you’ve got a web reference, let’s name it SWS, in your Visual Studio project. At this point we need to our objects. We’ll need the standard service object, a GetInsuranceInfo request object and a GetInsuranceInfo response object. We can define and create those like this:
// Create a request and response objects
SWS.WSSoapClient service = new SWS.WSSoapClient();
SWS.GetInsuranceInfo_Request request = new SWS.GetInsuranceInfo_Request();
SWS.GetInsuranceInfo_Response response;
Here’s my sample code of the Request object.
// GetInsuranceInfo Request
request.SiteID = 123456;
request.AccountOrContactName = "Doe, John";
request.ClaimDate = new DateTime(2016, 01, 01);
Finally we can call the method and pass across the login object and the request object to get our insurance info. It’s a good idea to do this in a Try Catch block.
// Call the method that will load the response object
try
{
response = service.GetInsuranceInfo(request);
}
catch (Exception ex)
{
MessageBox.Show(ex.Message);
}
Note that if something goes wrong the service will respond with an exception. You’ll want to take a look at that message returned in that exception so it can be debugged.
For a full list of methods see SWS Methods.
SWS GetInsuranceProviders Method
Retrieves insurance/protection plan providers available to the site.
Parameters
Name | DataType | Is Required |
---|---|---|
OrgID | Long | Required |
Description | The organization’s ID number. | |
SiteID | Long | Required |
Description | The site’s ID number. This can be found using the GetSiteList method. |
Returned Parameters
Name | DataType |
---|---|
CANCEL_AFTER | Integer |
Description | The number of days delinquent the rental can be before the policy is automatically cancelled. |
COMMENTS | String |
Description | The comments on the insurance/protection plan. |
COVERAGE_AMOUNT | Integer |
Description | The dollar amount of coverage that the insurance/protection plan offers. |
COVERAGE_PERC | Integer |
Description | The percentage of coverage that the insurance/protection plan covers. |
DEFAULT_OPTION | String |
Description | Indicates if the insurance/protection plan group is the default for the organization (“Y”) or not (“N”). |
DESC1 | String |
Description | The full description of the insurance/protection plan coverage. |
DESC2 | String |
Description | A shortened version of insurance/protection plan coverage description. |
DISP_ACTIVE | String |
Description | Indicates if the insurance/protection plan is active at the site (“Y”) or not (“N”). |
GROUP_ACTIVE | String |
Description | Indicates if the insurance/protection plan coverage group is active at the site (“Y”) or not (“N”). |
GROUP_NAME | String |
Description | The name of the insurance/protection plan’s group as assigned by the organization. |
INS_OPTION_ID | Long |
Description | The insurance/protection plan’s ID number. |
INS_PROVIDER_ID | Long |
Description | The insurance/protection plan provider’s ID number. |
OPTION_ACTIVE | String |
Description | Within each coverage group there are different levels of coverage. This indicates if the specific level of coverage is available at the organization (“Y”) or not (“N”). |
ORG_ID | Long |
Description | The organization’s ID number. |
PROVIDER_ACTIVE | String |
Description | Indicates if the provider of the insurance/protection plan is active at the organization (“Y”) or not (“N”). |
PROVIDER_NAME | String |
Description | The insurance/protection plan provider’s name. |
PROVIDER_NOTES | String |
Description | The notes on the insurance/protection plan’s coverage provider. |
RATE | Decimal |
Description | The insurance/protection plan’s premium amount for the service. |
SITE_ACTIVE | String |
Description | Indicates if the insurance/protection plan is active at the site (“Y”) or not (“N”). |
SITE_ID | Long |
Description | The site’s ID number. |
SITE_INS_ID | Long |
Description | The insurance/protection plan provider’s site ID number. |
SITE_REF_ID | String |
Description | The site specific provider ID number, if it exists. |
Example
As with every method we need to pass in credentials. We do this with the LookupUser request object.
We’ll assume you’ve got a web reference, let’s name it SWS, in your Visual Studio project. At this point we need to our objects. We’ll need the standard service object, a GetInsuranceProviders request object and a GetInsuranceProviders response object. We can define and create those like this:
// Create a request and response objects
SWS.WSSoapClient service = new SWS.WSSoapClient();
SWS.GetInsuranceProviders_Request request = new SWS.GetInsuranceProviders_Request();
SWS.GetInsuranceProviders_Response response;
Here’s my sample code of the Request object.
// GetInsuranceProviders Request
request.OrgID = 123456;
request.SiteID = 123456;
Finally we can call the method and pass across the login object and the request object to get our insurance/protection plan providers. It’s a good idea to do this in a Try Catch block.
// Call the method that will load the response object
try
{
response = service.GetInsuranceProviders(user_request,request);
}
catch (Exception ex)
{
MessageBox.Show(ex.Message);
}
Note that if something goes wrong the service will respond with an exception. You’ll want to take a look at that message returned in that exception so it can be debugged.
For a full list of methods see SWS Methods.
SWS GetAppliedInsurance Method
Retrieves the insurance rental details for a unit that has insurance. If ‘Null’ is returned, then the rental item does not have insurance applied to it. This will retrieve the insurance rental id which can then be used to cancel the insurance if needed.
Parameters
Name | DataType | Is Required |
---|---|---|
RentalID | Long | Required |
Description | The rental item’s ID number. This is returned when using the MakeReservation method or can be searched for using the SearchBy method. | |
SiteID | Long | Required |
Description | The site’s ID number. This can be found using the GetSiteList method. | |
SendLetter | Boolean | Not used in this method. |
Description | Not used in this method. |
Returned Parameters
Name | DataType |
---|---|
TRAN_RENTALS | TRAN_RENTALS |
Description | The object that contains all the data for the rental. |
Example
As with every method we need to pass in credentials. We do this with the LookupUser request object.
We’ll assume you’ve got a web reference, let’s name it SWS, in your Visual Studio project. At this point we need to our objects. We’ll need the standard service object, a GetAppliedInsurance request object and a GetAppliedInsurance response object. We can define and create those like this:
// Create a request and response objects
SWS.WSSoapClient service = new SWS.WSSoapClient();
SWS.GetAppliedInsurance_Request request = new SWS.GetAppliedInsurance_Request();
SWS.GetAppliedInsurance_Response response;
Here’s my sample code of the Request object.
// GetAppliedInsurance Request
request.SiteID = 123456;
request.RentalID = 123456;
Finally we can call the method and pass across the login object and the request object to get our applied insurance. It’s a good idea to do this in a Try Catch block.
// Call the method that will load the response object
try
{
response = service.GetAppliedInsurance(user_request,request);
}
catch (Exception ex)
{
MessageBox.Show(ex.Message);
}
Note that if something goes wrong the service will respond with an exception. You’ll want to take a look at that message returned in that exception so it can be debugged.
For a full list of methods see SWS Methods.