Archive
SWS2 GetDataView Method – move_out_list_v
This request requires at least one parameter to filter by and returns a list of moved out rentals. Recommended filtering would be on org_id and end_date.
Returned Parameters
Name | Data Type |
---|---|
END_DATE | DateTime |
Description | The date that the rental was terminated. |
RENTAL_ID | Long |
Description | The rental item’s ID number. This is returned when using the MakeReservation method or can be searched for using the SearchBy method. |
ACCT_ID | Long |
Description | The account’s ID number. This is returned when you use the CreateNewAccount method or can be retrieved with the SearchBy method. |
ACCT_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. |
FIRST_NAME | String |
Description | The primary contact’s first name. |
LAST_NAME | String |
Description | The primary contact’s last name. |
String | |
Description | The primary contact’s email. This acts as the username if eStore/eCommerce are supported. |
SITE_ID | Long |
Description | The site’s ID number. This can be found using the GetSiteList method. |
ORG_ID | Long |
Description | The organization’s ID number. |
SWS2 GetDataView Method – quote_reconciliation_3_v
The new view is quote_reconciliation_3_v which is a duplicate of quote_reconciliation_2_v and includes postal_code, updated_by and updated_user.
Returned Parameters
Name | Data Type |
---|---|
QUOTE_ID | Long |
Description | The quote’s ID number. |
ORG_ID | Long |
Description | The organization’s ID number. |
CREATED_BY | Long |
Description | The user’s ID that created the quote/reservation. |
USER_NAME | String |
Description | The user’s username that created the quote/reservation. |
QUOTE_TYPE | Integer |
Description | The numeric value of the quote type for the quote/reservation. |
QUOTE_TYPE_VAL | String |
Description | The textual value of the quote type for the quote/reservation. |
STATUS | Integer |
Description | The numeric value of quote’s status. |
QUOTE_STATUS_VAL | String |
Description | The textual value of the quote’s status. |
QUOTE_SOURCE | String |
Description | The application source that created the quote/reservation. |
QUOTE_START_DATE | DateTime |
Description | The date the quote/reservation was originally created. |
EXPIRATION | DateTime |
Description | The date the quote/reservation is no longer available. |
ACCT_ID | Long |
Description | The account’s ID number. This is returned when you use the CreateNewAccount method or can be retrieved with the SearchBy method. |
CONTACT_ID | Long |
Description | The rental contact’s ID number. This is returned when using the CreateNewAccount or AddNewContact methods or you can search for it using the SearchBy method. |
ADDR_ID | Long |
Description | The primary contact’s address ID number. |
PHONE_ID | Long |
Description | The primary contact’s phone ID number |
SITE_ID | Long |
Description | The site’s ID number. This can be found using the GetSiteList method. |
SITE_NAME | String |
Description | The site’s name as it appears in the Store application. |
ACCT_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. |
FIRST_NAME | String |
Description | The primary contact’s first name. |
LAST_NAME | String |
Description | The primary contact’s last name. |
CONTACT_ADDRESS | String |
Description | The primary contact’s complete address. This includes all applicable address lines, city, state/province and ZIP/postal code. |
PHONE | String |
Description | The primary contact’s phone number. |
String | |
Description | The primary contact’s email address. This acts as the username if eStore/eCommerce are supported. |
UNIT_NUMBER | String |
Description | The unit’s number as assigned by the organization. This is not the UnitID. |
UNIT_STATUS_VAL | String |
Description | The rental status of the unit. |
UNIT_DIMENSIONS | String |
Description | The width and depth measurements together as a string. |
ATTRIBUTE01 | Integer |
Description | The numeric value for the “Attribute01” custom look up as defined by the site. See eUnitAttr01 for the available values. |
ATTRIBUTE01_VAL | String |
Description | The textual value for the “Attribute01” custom look up as defined by the site. See eUnitAttr01 for the available values. |
QUOTED_RATE | Decimal |
Description | The amount quoted for the monthly rental rate. |
DISCOUNT_AMOUNT_OFFERED | Decimal |
Description | The dollar amount of any discount applicable to the quote/reservation. |
MARKET_CODE_VAL | Integer |
Description | The numeric indicator as to where the customer heard about the site. This is available to only specific sites. |
MARKET_SOURCE_VAL | String |
Description | The textual indicator as to where the customer heard about the site. This is available to only specific sites. |
INQUIRY_SOURCE_VAL | String |
Description | Indicates how the customer heard about the site. |
CREATED | DateTime |
Description | The date the quote/reservation was initially created. |
UPDATED | DateTime |
Description | The date that quote/reservation was most recently updated. |
POSTAL_CODE | String |
Description | The ZIP/postal code of the primary contact’s address. |
UPDATED_BY | Long |
Description | The user’s ID that last updated the quote/reservation. |
UPDATED_USER | String |
Description | The username of the person that last updated the quote/reservation. |
SWS2 UpdatePushStreetRate Method
Allows you to do a bulk update on the street or push rates for a group of units at a site. The method allows for a collection of the PushStreetRateInfo object to be passed in. The return object is a comma delimited string of “Succeeded” or “Failed”. Due to a 4,000 character limitation, the unit_ids in the array are parsed into groupings less than 4,000 characters and each group returns a result of “Succeeded” or “Failed” for the batch appended to the return object. Each PushStreetRateInfo object’s array is parsed into their own groups and appended to the return object for the entire method.
Parameters
Name | Data Type | Is Required |
---|---|---|
NewRate | Decimal | Required |
Description | The dollar amount to which the rate will change. | |
RateType | Integer | Required |
Description | Indicates if it is the street rate (“1”) or the push rate (“2”) that is being updated. | |
UnitIDs | Long (or an array of long) | Required |
Description | The unit’s ID number for which the rate is being updated. This is returned when you use any of the GetSiteUnitData calls and is maintained through rentals. |
|
SiteID | Long | Required |
Description | The site’s ID number. This can be found using the GetSiteList method. |
Returned Parameters
Name | Data Type |
---|---|
UnitIDs | Long (or an array of long) |
Description | The list of unit IDs where the street or push rate was updated. |
Example
We’ll assume you’ve got a web reference, let’s name it Store, in your Visual Studio project. At this point we need to reference our objects. We’ll need the standard service object, a UpdatePushStreetRate_Request request object and a PushStreetRateInfo object. We can define and create those like this:
// Create a request and response objects
StoreServiceClient client = new StoreServiceClient();
UpdatePushStreetRate_Request request = new UpdatePushStreetRate_Request();
PushStreetRateInfo rateInfo = new PushStreetRateInfo();
As with every method we need to pass in credentials. We also set up the parameters for our request.
client.ChannelFactory.Credentials.UserName.UserName = "user"; client.ChannelFactory.Credentials.UserName.Password = "pass"; client.ChannelFactory.Credentials.SupportInteractive = true; rateInfo.UnitIDs = new long[] { 123456, 456789 }; rateInfo.RateType = 1; rateInfo.NewRate = 50m; request.SiteID = 123456; request.PushStreetRateInfo = new PushStreetRateInfo[] { rateInfo };
Finally we can call the method and pass across the login object and the request object to update the rate/s. It’s a good idea to do this in a Try Catch block.
try
{
// Call the method that will load the response object
UpdatePushStreetRate_Response resp;
resp = client.UpdatePushStreetRate(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 SWS2 Methods.
SWS UpdateRentRateV2 Method
Lets you change the rent rate for a unit. Multiple units can be individually processed with a new rate. Letters can also be scheduled to be sent when updating the rent rates on active rentals. This method allows you to choose if the letter will be centralized mail or local mail.
Parameters
Name | DataType | Is Required |
---|---|---|
AcctID | Long | Optional |
Description | The account’s ID number. This is returned when you use the CreateNewAccount method or can be retrieved with the SearchBy method. Only required when sending a letter. | |
EffectiveDate | DateTime | Required |
Description | The date the future rate will go into effect. | |
LetterDate | DateTime | Optional |
Description | The date the letter is to be sent. Only required when SendLetter is “True”. | |
NewRate | Decimal | Required |
Description | The new rent rate for the rental item. | |
OrgID | Long | Required |
Description | The organization’s ID number. | |
RentalID | Long | Optional |
Description | The rental item’s ID number. This is returned when using the MakeReservation method or can be searched for using the SearchBy method. Only required if SendLetter is “True”. | |
SendLetter | Boolean | Optional |
Description | Indicates if the system is to generate a rate change letter (“True”) or not (“False”). | |
SiteID | Long | Required |
Description | The site’s ID number. This can be found using the GetSiteList method. | |
UnitID | Long | Required |
Description | This is returned when you use any of the GetSiteUnitData calls. | |
UnitVersion | Decimal | Required |
Description | The unit’s version number which serves to prevent duplicate use of the unit. | |
MailLocal | Boolean | Required |
Description | Indicates if the letter should be printed and mailed through the site (“True”) or through centralized mailing (“False”). |
Returned Parameters
Name | DataType |
---|---|
ErrorMessage | String |
Description | If “Succeeded” is “False” this will give additional information as to what failed. |
Succeeded | Boolean |
Description | Indicates if the rate change was completed successfully (“True”) of not (“False”). |
UnitID | Long |
Description | The unit’s ID number where the rate was updated. This is maintained through rentals. |
Example
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 UpdateRentRateV2 request object, and an UpdateRentRateV2 response object. We will also need a RentRateReqDataV2 array we can pass to the request. We can define and create those like this:
// Create a request and response objects
SWS.WSSoapClient service = new SWS.WSSoapClient();
SWS.UpdateRentRateV2_Request request = new SWS.UpdateRentRateV2_Request();
SWS.UpdateRentRateV2_Response response;
SWS.RentRateReqDataV2[] reqRentRate = new SWS.RentRateReqDataV2[1];
Here is a sample code of the request object:
// UpdateRentRate Request
reqRentRate[0].OrgID = 123456;
reqRentRate[0].SiteID = 123456;
reqRentRate[0].AcctId = 123456;
reqRentRate[0].UnitID = 123456;
reqRentRate[0].UnitVersion = 23;
reqRentRate[0].RentalId = 123456;
reqRentRate[0].NewRate = 55.25m;
reqRentRate[0].EffectiveDate = new DateTime(2017, 9,1);
reqRentRate[0].SendLetter = true;
reqRentRate[0].MailLocal = true;
reqRentRate[0].LetterDate = new DateTime(2017, 8, 1);
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.UpdateRentRateV2(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.