4D Payments SDK 2016 .NET Edition

Questions / Feedback?

FDMSHotel Component

Properties   Methods   Events   Configuration Settings   Errors  

The FDMSHotel component is an advanced tool used to authorize credit cards in a retail environment, where the customer is purchasing products or services in person. This component makes authorizing these types of transactions very easy.




This component connects to the First Data Merchant Services (FDMS) processor, by way of the Datawire VXN transaction transport network. Transactions originating with these components go through Datawire, to the FDMS processor where the transaction is authorized. The result is then returned back through Datawire and received by the component. This component can be integrated into web pages or stand-alone Point Of Sale applications. Because all SSL communications are handled inside the component, any application or web page can be deployed without the need for expensive dedicated SSL servers.

The FDMSHotel component makes authorizing transactions in a hotel/lodging environment very easy by adding an additional layer of abstraction between the programmer and the protocol. There is no need to deal with raw sockets, TLS/SSL handshakes, or data packet formatting. The steps to setting up the component and authorizing a transaction are outlined below:

First, you must register and activate your account with Datawire. Datawire will provide you with a MerchantNumber and MerchantTerminalNumber, but you'll need to use the FDMSRegister component to activate the merchant and receive a DatawireId. Once you acquire the DatawireId and receive your transaction URLs through Service Discovery, you may begin to authorize transactions.

To authorize a credit card, set the MerchantNumber and MerchantTerminalNumber with the values supplied by FDMS and Datawire, and the DatawireId with the value retrieved by the FDMSRegister component after activating your merchant account. Set the URL property with one of the URLs you retrieved during Service Discovery.

  FDMSHotel.MerchantNumber = "000000999990";                  'Supplied by FDMS/Datawire
  FDMSHotel.MerchantTerminalNumber = "555555";                'Supplied by FDMS/Datawire
  FDMSHotel.TPPID = "VNT001";                                 'Supplied by FDMS/Datawire
  FDMSHotel.VisaIdentifier = "0B34567890123456789";           'Supplied by FDMS/Datawire
  FDMSHotel.DatawireId = "0000B47FFFFFFFFFFFFF";              'Retrieved with the FDMSRegister component.  
  FDMSHotel.URL = "https://staging1.datawire.net/sd/";        'Retrieved with the FDMSRegister component.

Then set the Card fields with the customer's cardholder data. Most card readers are capable of reading both Track1 and Track2 data off of a credit card. If both are present and correctly read, you should default to sending Track1 data. If your card reader cannot read the card at all, you may manually enter the credit card number and expiration date. Do not forget to set the EntryDataSource field, as it is used by the component during authorization to create the proper type of payload.

   FDMSHotel.Card.MagneticStripe = "B4662060000000005^FDCS TEST CARD^120410123456789"
   FDMSHotel.Card.EntryDataSource = edsTrack1

Next, set properties that contain details about the transaction. The TransactionNumber should be incremented for every transaction you authorize. The TransactionAmount must now be set, along with any optional values such as InvoiceNumber, ReferenceNumber, RoomNumber, RoomRate, ArrivalDate, DepartureDate, or StayDuration. All amounts are set with an implied decimal point (ie: $1.00 is "100").

  FDMSHotel.TransactionNumber = 1
  FDMSHotel.InvoiceNumber = "FOLIONUM1234"
  FDMSHotel.ReferenceNumber = "REFNUM1"
  FDMSHotel.RoomNumber = "101"
  FDMSHotel.RoomRate = "10000"
  FDMSHotel.ArrivalDate = "0127" 		' MMdd
  FDMSHotel.DepartureDate = "0128" 	' MMdd
  FDMSHotel.StayDuration = 1

Finally, submit the transaction via the Authorize method.

When the component receives a response, the result of the authorization will be available in several Response properties. The DatawireStatus and DatawireReturnCode indicate whether any errors occurred while passing the transaction through the Datawire VXN system. These two properties alone do not indicate a successful transaction, they only tell whether or not there were any problems transporting the authorization request and response through the Datawire system. If the transaction was successfully authorized by FDMS, then the CaptureFlag will be True, and the ApprovalCode will contain an approval code that beings with "AP". (or "AL" for components that support partially-approved/split-tender transactions).

Once an authorization request is approved, the money in the customer's account is blocked and tagged for the merchant. This transaction must go through the Batch Settlement process in order for the blocked money to be transferred to the merchant account. This is done by passing the XML aggregate returned from the GetDetailAggregate method to the FDMSSettle component. Usually, a Batch Settlement of all authorized transactions is done at the end of each business day.

Property List

The following is the full list of the properties of the component with short descriptions. Click on the links for further details.

ApplicationIdIdentifies the merchant application to the Datawire System.
ArrivalDateThe arrival date of the guest.
CardContains the customer's credit card information.
CardholderNameThe name of the Cardholder.
CustomerAddressThe customer's billing address.
CustomerZipCustomer's zip code (or postal code if outside of the USA).
DatawireIdIdentifies the merchant to the Datawire System.
DepartureDateThe departure date of the guest.
ExtraChargesList of extra charges for Hotel transactions.
FDMSPlatformSpecifies the FDMS platform that the transactions will be processed on.
InvoiceNumberThe Folio or Room Agreement number assigned by the hotel.
MerchantNumberA unique number used to identify the merchant within the FDMS and Datawire systems.
MerchantTerminalNumberUsed to identify a unique terminal within a merchant location.
NoShowIndicates whether the guest did not show.
PrestigiousIndicatorPrestigious Lodging Program indicator for the Hotel Industry Type.
ProgramIndicatorSpecial Program Indicator.
ProxyA set of properties related to proxy access.
ReferenceNumberA reference number assigned by the hotel.
ResponseContains the response to an authorization request.
RoomNumberThe Room Number assigned by the hotel.
RoomRateThe daily room rate.
RoomTaxThe daily room tax amount.
SSLAcceptServerCertInstructs the component to unconditionally accept the server certificate that matches the supplied certificate.
SSLCertThe certificate to be used during SSL negotiation.
SSLServerCertThe server certificate for the last established connection.
StayDurationLength of hotel stay in days.
TimeoutA timeout for the component.
TPPIDThird Party Processor Identifier assigned by FDMS.
TransactionAmountPurchase amount to be authorized.
TransactionNumberUniquely identifies the transaction.
URLLocation of the Datawire server to which transactions are sent.
VisaIdentifierAdditional merchant identification field used when authorizing Visa transactions.

Method List

The following is the full list of the methods of the component with short descriptions. Click on the links for further details.

AuthorizeAuthorizes a credit card using track1, track2, or manually entered card data.
AVSAndCVVOnlyPerforms an AVS/CVV only check using the specified Card data.
BalanceInquiryPerforms a Balance Inquiry Request using the specified Card data.
ConfigSets or retrieves a configuration setting.
GetDetailAggregateReturns an aggregate containing details of this transaction, which is then used for settlement.
GetHotelDataAggregateReturns an aggregate containing the Hotel/Lodging data of this transaction, which is then used for reversals.
IncrementalAuthPerforms an incremental authorization.
InterruptInterrupts the current action.
ResetClears all properties to their default values.

Event List

The following is the full list of the events fired by the component with short descriptions. Click on the links for further details.

ConnectedFired immediately after a connection completes (or fails).
DataPacketInFired when receiving a data packet from the transaction server.
DataPacketOutFired when sending a data packet to the transaction server.
DisconnectedFired when a connection is closed.
ErrorInformation about errors during data delivery.
SSLServerAuthenticationFired after the server presents its certificate to the client.
SSLStatusShows the progress of the secure connection.
StatusShows the progress of the FDMS/Datawire connection.

Configuration Settings

The following is a list of configuration settings for the component with short descriptions. Click on the links for further details.

ACIRequested Authorization Characteristics Indicator (ACI).
AllowPartialAuthsIndicates whether partial authorizations are to be supported.
ClientTimeoutIndicates timeout client application will wait for response.
CurrencyCodeCurrency Code for this transaction.
CustomerAddressThe customer's billing address.
CustomerZipCustomer's zip code (or postal code if outside of the USA).
DebugTraceWhether to enable debug logging.
GetTransArmorTokenAllows you to retrieve a TransArmor Token for a specified card.
IsOnlineRefundIndicates whether a transaction is Online Refund Authorization.
TerminalLaneNumberThe Unique Terminal Lane Number.
TransArmorKeySpecifies the TransArmor key used to perform the encryption.
TransArmorKeyIdSpecifies the Id of the TransArmor key used to perform the encryption.
TransArmorModeSpecifies the TransArmor Security Level to use.
TransArmorProviderIdThe Id of the Provider that issued a TransArmorToken.
TransArmorTokenA TransArmor Token used in place of a card number or magnetic stripe data.
TransArmorTokenTypeSpecifies the type of TransArmor token that will be used.
TransArmorUpdateIndicatorIndicates whether your TransArmorKey needs to be updated.
UpdateTransArmorKeyAllows you to update your TransArmor Key.
CloseStreamAfterTransferIf true, the component will close the upload or download stream after the transfer.
ConnectionTimeoutSets a separate timeout value for establishing a connection.
FirewallAutoDetectTells the component whether or not to automatically detect and use firewall system settings, if available.
FirewallHostName or IP address of firewall (optional).
FirewallListenerIf true, the component binds to a SOCKS firewall as a server (IPPort only).
FirewallPasswordPassword to be used if authentication is to be used when connecting through the firewall.
FirewallPortThe TCP port for the FirewallHost;.
FirewallTypeDetermines the type of firewall to connect through.
FirewallUserA user name if authentication is to be used connecting through a firewall.
KeepAliveIntervalThe retry interval, in milliseconds, to be used when a TCP keep-alive packet is sent and no response is received.
KeepAliveTimeThe inactivity time in milliseconds before a TCP keep-alive packet is sent.
LingerWhen set to True, connections are terminated gracefully.
LingerTimeTime in seconds to have the connection linger.
LocalHostThe name of the local host through which connections are initiated or accepted.
LocalPortThe port in the local host where the component binds.
MaxLineLengthThe maximum amount of data to accumulate when no EOL is found.
MaxTransferRateThe transfer rate limit in bytes per second.
ProxyExceptionsListA semicolon separated list of hosts and IPs to bypass when using a proxy.
TCPKeepAliveDetermines whether or not the keep alive socket option is enabled.
TcpNoDelayWhether or not to delay when sending packets.
UseIPv6Whether to use IPv6.
UseNTLMv2Whether to use NTLM V2.
CACertFilePathsThe paths to CA certificate files when using Mono on Unix/Linux.
LogSSLPacketsControls whether SSL packets are logged when using the internal security API.
ReuseSSLSessionDetermines if the SSL session is reused.
SSLCACertsA newline separated list of CA certificate to use during SSL client authentication.
SSLCheckCRLWhether to check the Certificate Revocation List for the server certificate.
SSLCipherStrengthThe minimum cipher strength used for bulk encryption.
SSLEnabledCipherSuitesThe cipher suite to be used in an SSL negotiation.
SSLEnabledProtocolsUsed to enable/disable the supported security protocols.
SSLEnableRenegotiationWhether the renegotiation_info SSL extension is supported.
SSLIncludeCertChainWhether the entire certificate chain is included in the SSLServerAuthentication event.
SSLNegotiatedCipherReturns the negotiated ciphersuite.
SSLNegotiatedCipherStrengthReturns the negotiated ciphersuite strength.
SSLNegotiatedKeyExchangeReturns the negotiated key exchange algorithm.
SSLNegotiatedKeyExchangeStrengthReturns the negotiated key exchange algorithm strength.
SSLNegotiatedProtocolReturns the negotiated protocol version.
SSLProviderThe name of the security provider to use.
SSLSecurityFlagsFlags that control certificate verification.
SSLServerCACertsA newline separated list of CA certificate to use during SSL server certificate validation.
TLS12SignatureAlgorithmsDefines the allowed TLS 1.2 signature algorithms when UseInternalSecurityAPI is True.
TLS12SupportedGroupsThe supported groups for ECC.
TLS13KeyShareGroupsThe groups for which to pregenerate key shares.
TLS13SignatureAlgorithmsThe allowed certificate signature algorithms.
TLS13SupportedGroupsThe supported groups for (EC)DHE key exchange.
AbsoluteTimeoutDetermines whether timeouts are inactivity timeouts or absolute timeouts.
FirewallDataUsed to send extra data to the firewall.
InBufferSizeThe size in bytes of the incoming queue of the socket.
OutBufferSizeThe size in bytes of the outgoing queue of the socket.
BuildInfoInformation about the product's build.
GUIAvailableTells the component whether or not a message loop is available for processing events.
LicenseInfoInformation about the current license.
UseInternalSecurityAPITells the component whether or not to use the system security libraries or an internal implementation.

Copyright (c) 2021 4D Payments Inc. - All rights reserved.
4D Payments SDK 2016 .NET Edition - Version 16.0 [Build 8017]