Rezlynx API

pmsbkg_RoomFolioItemsAndBalance

This method returns the current itemised bill or folio for a resident guest.

Parameters

Name Type Description
SessionID string Session ID
RoomID String Room name or number
FolioID int Folio ID, in case of multiple folios for the room
ItemFormat int Format for presenting line items (default '0')
ItemFormat can be one of the following:
  • 0 = show all items
  • 1 = show only non-ledger items
  • 2 = show ledger items as paid
  • 3 = show ledger items with zero balance
  • 4 = show ledger items as paid with zero balance

Returned data

Name Type Description
Items (object) List of folio line items (see below)
Balance decimal Total balance for the folio

Returned data (Folio line item)

Name Type Description
iTransID int Transaction ID for the item
strSourceSiteID string Site ID
dtTimestamp dateTime Date-time stamp for the transaction
dtForDate dateTime Period system date to which transaction applies
iForStayResourceBlock int ?
strSystemArea string ?
strOperatorCode string Operator code of charge item source, e.g. API vendor
iEntryType int Entry Type code
iItemType int Item Type code
strAnalCode string Sales analysis code
strBookRef string Booking reference
strProfileRef string Profile reference
iRoomPickID int Room Pick ID (integer used for multi-room bookings)
iFolioID int Folio ID, in case of multiple folios per room
iSourceTransID long ?
iFolioSplitID int Folio split ID if using 'bill split'
strRoomID string Room name or number
strCompanyRef string Company reference
strInvoiceID string Invoice ID
strDescription string Item description
strPaymentCode string Item payment code, if payment
iCurrencyConvID int ?
strTaxRule string Applicable Tax Rule
cNettPerUnit decimal Item individual amount, nett of tax
cGrossPerUnit decimal Item individual amount, gross including tax
dQuantity double Item quantity
cNettTotal decimal Item total amount, nett of tax
cTaxTotal decimal Total amount of tax due
cGrossTotal decimal Item total amount, gross including tax
strPackageCode string Package code, if applicable
iPackageTag int ?
iStatus int ?
iParam1 int ?
strParam2 string ?

EntryType can be one of the following:

  • 50 = Direct post
  • 100 = Folio charge
  • 110 = Folio surcharge
  • 200 = Folio credit
  • 220 = Folio adjustment
  • 300 = Folio deposit advance
  • 310 = Folio deposit refund
  • 320 = Folio deposit in-house
  • 330 = Folio deposit used
  • 340 = Folio deposit retained (not used)
  • 350 = Folio deposit tax refund
  • 500 = Invoiced business
  • 700 = Ledger debit
  • 800 = Ledger credit

ItemType can be one of the following:

  • 0 = General
  • 50 = Package header
  • 100 = Adult accomodation
  • 110 = Child SH accomodation
  • 120 = Child OR accomodation
  • 30 = Function room hire
  • 200 = Manual product
  • 250 = Auto-inclusive product
  • 300 = Supplement
  • 400 = Surcharge
  • 500 = Deposit
  • 550 = Ledger credit card debit
  • 560 = Ledger credit card credit
  • 700 = Foreign exchange

Financial status can be one of the following:

  • 0 = Default
  • 50 = Direct post paid off
  • 100 = Advance deposit transfer now transferred
  • 200 = In-house deposit transfer now used
  • 300 = Ledger transfer now transferred
  • 350 = Folio deposit tax refund
  • 400 = Booking transfer now transferred
  • 500 = Folio charge deleted
  • 510 = Folio credit deleted
  • 600 = Folio charge deleted for adjustment
  • 900 = Folio credit transferred
  • 1000 = Folio charge paid off

Request URL

https://pmsws.eu.guestline.net/rlxsoaprouter/rlxsoap.asmx?op=pmsbkg_RoomFolioItemsAndBalance

Request headers

Name Type Description
(optional) string Media type of the body sent to the API.

Request body

<pmsbkg_RoomFolioItemsAndBalance xmlns="http://tempuri.org/RLXSOAP19/RLXSOAP19">
  <SessionID>d9de5589-5781-45bd-a5bd-a385f6d19bce</SessionID>
  <RoomID>110</RoomID>
  <FolioID>1</FolioID>
  <ItemFormat>0</ItemFormat>
</pmsbkg_RoomFolioItemsAndBalance>

Responses

200 OK

Representations

<pmsbkg_RoomFolioItemsAndBalanceResponse xmlns="http://tempuri.org/RLXSOAP19/RLXSOAP19">
  <pmsbkg_RoomFolioItemsAndBalanceResult>
    <ExceptionCode>0</ExceptionCode>
    <ExceptionDescription>No error</ExceptionDescription>
  </pmsbkg_RoomFolioItemsAndBalanceResult>
  <RoomFolioItemsAndBalance>
    <Items>
      <cpmsbkg_RoomFolioItemsAndBalance_Item>
        <iTransID>11653</iTransID> 
        <strSourceSiteID>VENDORCITY</strSourceSiteID> 
        <dtTimestamp>2018-03-19T11:42:42</dtTimestamp> 
        <dtForDate>2018-03-19T00:00:00</dtForDate> 
        <iForStayResourceBlock>0</iForStayResourceBlock> 
        <strSystemArea>56</strSystemArea> 
        <strOperatorCode>XNPROTEL</strOperatorCode> 
        <iEntryType>100</iEntryType> 
        <iItemType>50</iItemType> 
        <strAnalCode>PTR</strAnalCode> 
        <strBookRef>BK000039</strBookRef> 
        <strProfileRef /> 
        <iRoomPickID>1</iRoomPickID> 
        <iFolioID>1</iFolioID> 
        <iSourceTransID>0</iSourceTransID> 
        <iFolioSplitID>1</iFolioSplitID> 
        <strRoomID>110</strRoomID> 
        <strCompanyRef /> 
        <strInvoiceID /> 
        <strDescription>Dallas Rest:108118</strDescription> 
        <strPaymentCode /> 
        <iCurrencyConvID>0</iCurrencyConvID> 
        <strTaxRule>NO_VAT</strTaxRule> 
        <cNettPerUnit>19.8200</cNettPerUnit> 
        <cGrossPerUnit>23.9300</cGrossPerUnit> 
        <dQuantity>5</dQuantity> 
        <cNettTotal>19.8200</cNettTotal> 
        <cTaxTotal>4.1100</cTaxTotal> 
        <cGrossTotal>23.9300</cGrossTotal> 
        <strPackageCode /> 
        <iPackageTag>11653</iPackageTag> 
        <iStatus>0</iStatus> 
        <iParam1>0</iParam1> 
        <strParam2 /> 
      </cpmsbkg_RoomFolioItemsAndBalance_Item>
      <cpmsbkg_RoomFolioItemsAndBalance_Item>
        <iTransID>11686</iTransID> 
        <strSourceSiteID>VENDORCITY</strSourceSiteID> 
        <dtTimestamp>2018-03-19T12:18:02</dtTimestamp> 
        <dtForDate>2018-03-19T00:00:00</dtForDate> 
        <iForStayResourceBlock>0</iForStayResourceBlock> 
        <strSystemArea>56</strSystemArea> 
        <strOperatorCode>XNPROTEL</strOperatorCode> 
        <iEntryType>100</iEntryType> 
        <iItemType>50</iItemType> 
        <strAnalCode>PTR</strAnalCode> 
        <strBookRef>BK000039</strBookRef> 
        <strProfileRef /> 
        <iRoomPickID>1</iRoomPickID> 
        <iFolioID>1</iFolioID> 
        <iSourceTransID>0</iSourceTransID> 
        <iFolioSplitID>1</iFolioSplitID> 
        <strRoomID>110</strRoomID> 
        <strCompanyRef /> 
        <strInvoiceID /> 
        <strDescription>Dallas Rest:108121</strDescription> 
        <strPaymentCode /> 
        <iCurrencyConvID>0</iCurrencyConvID> 
        <strTaxRule>NO_VAT</strTaxRule> 
        <cNettPerUnit>26.3300</cNettPerUnit> 
        <cGrossPerUnit>31.6100</cGrossPerUnit> 
        <dQuantity>3</dQuantity> 
        <cNettTotal>26.3300</cNettTotal> 
        <cTaxTotal>5.2800</cTaxTotal> 
        <cGrossTotal>31.6100</cGrossTotal> 
        <strPackageCode /> 
        <iPackageTag>11686</iPackageTag> 
        <iStatus>0</iStatus> 
        <iParam1>0</iParam1> 
        <strParam2 /> 
      </cpmsbkg_RoomFolioItemsAndBalance_Item>
    </Items>
    <Balance>decimal</Balance>
  </RoomFolioItemsAndBalance>
</pmsbkg_RoomFolioItemsAndBalanceResponse>

Code samples

@ECHO OFF



curl -v -X POST "https://pmsws.eu.guestline.net/rlxsoaprouter/rlxsoap.asmx?op=pmsbkg_RoomFolioItemsAndBalance"
-H "Content-Type: text/xml"

--data-ascii "{body}" 
using System;
using System.Net.Http.Headers;
using System.Text;
using System.Net.Http;
using System.Web;

namespace CSHttpClientSample
{
    static class Program
    {
        static void Main()
        {
            MakeRequest();
            Console.WriteLine("Hit ENTER to exit...");
            Console.ReadLine();
        }
        
        static async void MakeRequest()
        {
            var client = new HttpClient();
            var queryString = HttpUtility.ParseQueryString(string.Empty);

            // Request headers


            
            
            var uri = "https://pmsws.eu.guestline.net/rlxsoaprouter/rlxsoap.asmx?op=pmsbkg_RoomFolioItemsAndBalance&" + queryString;

            HttpResponseMessage response;

            // Request body
            byte[] byteData = Encoding.UTF8.GetBytes("{body}");

            using (var content = new ByteArrayContent(byteData))
            {
               content.Headers.ContentType = new MediaTypeHeaderValue("< your content type, i.e. application/json >");
               response = await client.PostAsync(uri, content);
            }

        }
    }
}	
// // This sample uses the Apache HTTP client from HTTP Components (http://hc.apache.org/httpcomponents-client-ga/)
import java.net.URI;
import org.apache.http.HttpEntity;
import org.apache.http.HttpResponse;
import org.apache.http.client.HttpClient;
import org.apache.http.client.methods.HttpGet;
import org.apache.http.client.utils.URIBuilder;
import org.apache.http.impl.client.HttpClients;
import org.apache.http.util.EntityUtils;

public class JavaSample 
{
    public static void main(String[] args) 
    {
        HttpClient httpclient = HttpClients.createDefault();

        try
        {
            

            URIBuilder builder = new URIBuilder("https://pmsws.eu.guestline.net/rlxsoaprouter/rlxsoap.asmx?op=pmsbkg_RoomFolioItemsAndBalance");


            URI uri = builder.build();
            HttpPost request = new HttpPost(uri);
            request.setHeader("Content-Type", "text/xml");


            // Request body
            StringEntity reqEntity = new StringEntity("{body}");
            request.setEntity(reqEntity);

            HttpResponse response = httpclient.execute(request);
            HttpEntity entity = response.getEntity();

            if (entity != null) 
            {
                System.out.println(EntityUtils.toString(entity));
            }
        }
        catch (Exception e)
        {
            System.out.println(e.getMessage());
        }
    }
}

<!DOCTYPE html>
<html>
<head>
    <title>JSSample</title>
    <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.9.0/jquery.min.js"></script>
</head>
<body>

<script type="text/javascript">
    $(function() {
        var params = {
            // Request parameters
        };
                  

        $.ajax({
            url: "https://pmsws.eu.guestline.net/rlxsoaprouter/rlxsoap.asmx?op=pmsbkg_RoomFolioItemsAndBalance" + $.param(params),
            beforeSend: function(xhrObj){
                // Request headers
                xhrObj.setRequestHeader("Content-Type","text/xml");
            },
            type: "POST",
            // Request body
            data: "{body}",
        })
        .done(function(data) {
            alert("success");
        })
        .fail(function() {
            alert("error");
        });
    });
</script>
</body>
</html>
#import <Foundation/Foundation.h>

int main(int argc, const char * argv[])
{
    NSAutoreleasePool * pool = [[NSAutoreleasePool alloc] init];
                      

    NSString* path = @"https://pmsws.eu.guestline.net/rlxsoaprouter/rlxsoap.asmx?op=pmsbkg_RoomFolioItemsAndBalance";
    NSArray* array = @[
                         // Request parameters
                         @"entities=true",
                      ];
    
    NSString* string = [array componentsJoinedByString:@"&"];
    path = [path stringByAppendingFormat:@"?%@", string];

    NSLog(@"%@", path);

    NSMutableURLRequest* _request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:path]];
    [_request setHTTPMethod:@"POST"];
    // Request headers
    [_request setValue:@"text/xml" forHTTPHeaderField:@"Content-Type"];
    // Request body
    [_request setHTTPBody:[@"{body}" dataUsingEncoding:NSUTF8StringEncoding]];
    
    NSURLResponse *response = nil;
    NSError *error = nil;
    NSData* _connectionData = [NSURLConnection sendSynchronousRequest:_request returningResponse:&response error:&error];

    if (nil != error)
    {
        NSLog(@"Error: %@", error);
    }
    else
    {
        NSError* error = nil;
        NSMutableDictionary* json = nil;
        NSString* dataString = [[NSString alloc] initWithData:_connectionData encoding:NSUTF8StringEncoding];
        NSLog(@"%@", dataString);
        
        if (nil != _connectionData)
        {
            json = [NSJSONSerialization JSONObjectWithData:_connectionData options:NSJSONReadingMutableContainers error:&error];
        }
        
        if (error || !json)
        {
            NSLog(@"Could not parse loaded json with error:%@", error);
        }
        
        NSLog(@"%@", json);
        _connectionData = nil;
    }
    
    [pool drain];

    return 0;
}
<?php
// This sample uses the Apache HTTP client from HTTP Components (http://hc.apache.org/httpcomponents-client-ga/)
require_once 'HTTP/Request2.php';
                      

$request = new Http_Request2('https://pmsws.eu.guestline.net/rlxsoaprouter/rlxsoap.asmx?op=pmsbkg_RoomFolioItemsAndBalance');
$url = $request->getUrl();

$headers = array(
    // Request headers
    'Content-Type' => 'text/xml',
);

$request->setHeader($headers);

$parameters = array(
    // Request parameters
);

$url->setQueryVariables($parameters);

$request->setMethod(HTTP_Request2::METHOD_POST);

// Request body
$request->setBody("{body}");

try
{
    $response = $request->send();
    echo $response->getBody();
}
catch (HttpException $ex)
{
    echo $ex;
}

?>
########### Python 2.7 #############
import httplib, urllib, base64

headers = {
    # Request headers
    'Content-Type': 'text/xml',
}

params = urllib.urlencode({
})

try:
    conn = httplib.HTTPSConnection('pmsws.eu.guestline.net/rlxsoaprouter/rlxsoap.asmx')


    conn.request("POST", "pmsbkg_RoomFolioItemsAndBalance%s" % params, "{body}", headers)
    response = conn.getresponse()
    data = response.read()
    print(data)
    conn.close()
except Exception as e:
    print("[Errno {0}] {1}".format(e.errno, e.strerror))

####################################

########### Python 3.2 #############
import http.client, urllib.request, urllib.parse, urllib.error, base64

headers = {
    # Request headers
    'Content-Type': 'text/xml',
}

params = urllib.parse.urlencode({
})

try:
    conn = http.client.HTTPSConnection('developers.azure-api.net')
    conn.request("POST", "/rezlynx-web-service/?soapAction=http://tempuri.org/RLXSOAP19/RLXSOAP19/pmsbkg_RoomFolioItemsAndBalance&%s" % params, "{body}", headers)
    response = conn.getresponse()
    data = response.read()
    print(data)
    conn.close()
except Exception as e:
    print("[Errno {0}] {1}".format(e.errno, e.strerror))

####################################
require 'net/http'


uri = URI('https://pmsws.eu.guestline.net/rlxsoaprouter/rlxsoap.asmx?op=pmsbkg_RoomFolioItemsAndBalance')


request = Net::HTTP::Post.new(uri.request_uri)
# Request headers
request['Content-Type'] = 'text/xml'
# Request body
request.body = "{body}"

response = Net::HTTP.start(uri.host, uri.port, :use_ssl => uri.scheme == 'https') do |http|
    http.request(request)
end

puts response.body