triPOS REST API

<back to all web services

ReversalRequest

The following routes are available for this service:
POST/api/v1/reversal/{transactionId}/{paymentType}Creates a new full reversal based on given transaction ID, payment type, and the passed in amounts.
ReversalRequest Parameters:
NameParameterData TypeRequiredDescription
ConfigurationbodyTransactionIdRequestConfigurationNoAny value included in this section will override the corresponding value set in the triPOS.config
ConvenienceFeeAmountbodydecimalNoThe convenience fee amount.
PaymentTypepathstringYesThe original payment type.

Allowable Values

  • credit
  • debit
  • gift
TransactionAmountbodydecimalNoThe original transaction amount.
TransactionIdpathstringYesThe ID of a previous transaction.
ReversalTypequerystringNoThe type of reversal.
LaneRequest Parameters:
NameParameterData TypeRequiredDescription
CardHolderPresentCodebodyCardHolderPresentCode?NoDefines whether the card holder is present at the transaction. This value is optional, but recommended to be set. If this value is not set in the request, it will be automatically set based on the market code.

Allowable Values

  • Default
  • Unknown
  • Present
  • NotPresent
  • MailOrder
  • PhoneOrder
  • StandingAuth
  • ECommerce
ClerkNumberbodystringNoAn optional clerk number for reference.
LaneIdbodyintNoSpecifies which lane to use.
ReferenceNumberbodystringNoA user defined reference number. This reference number is returned in the response
ShiftIdbodystringNoAn optional shift id for reference.
TicketNumberbodystringNoAn optional ticket number.
TransactionIdRequestConfiguration Parameters:
NameParameterData TypeRequiredDescription
MarketCodebodyMarketCodeNoThe market code of the transaction.

Allowable Values

  • Default
  • AutoRental
  • DirectMarketing
  • ECommerce
  • FoodRestaurant
  • HotelLodging
  • Petroleum
  • Retail
  • Qsr
ReversalResponse Parameters:
NameParameterData TypeRequiredDescription
CardLogobodystringNoThe card logo. Possible values are: Visa, Mastercard, Discover, Amex, Diners Club, JCB, Carte Blanche, Other
ConvenienceFeeAmountbodydecimalNoThe convenience fee amount.
PaymentTypebodystringNoOriginal card payment type: Credit, Debit, Gift, EBT
TerminalIdbodystringNoThe ID of the terminal used during the transaction
TotalAmountbodydecimalNoThe total amount of the transaction.
AccountNumberbodystringNoThe card account number.
BaseResponse Parameters:
NameParameterData TypeRequiredDescription
ApprovalNumberbodystringNoApproval number from the processor. Depending on card type and processor an approval number might not be returned.
IsApprovedbodyboolNoSet to true if the host approved the transaction.
ProcessorbodyProcessorNoResponse information from the processor.
StatusCodebodyTransactionFlowStatusNoThe status code for the transaction.

Allowable Values

  • None
  • Success
  • Declined
  • Approved
  • Restart
  • Failed
  • HostError
  • Timeout
  • FailedVerification
  • CardError
  • UnknownCard
  • UnsupportedCard
  • DeviceError
  • Cancelled
  • ChipError
  • PinPadError
  • PinPadTimeout
  • InvalidLane
  • SwipedCardIsChipCapable
  • ApprovedByMerchant
  • ChipReaderError
  • UseChipReader
  • UseMagneticStripe
  • CardRemoved
  • CardBlocked
  • CardNotSupported
  • BadCard
  • CandidateListEmpty
  • IssuerAuthenticationFailed
  • CardDataEncryptionNotEnabled
  • ApprovedExceptCashback
  • ApplicationBlocked
TransactionDateTimebodystringNoTransaction date/time in ISO8601 format
TransactionIdbodystringNoThe transaction ID from the processor
MerchantIdbodystringNoThe Merchant used to process the transaction.

To override the Content-type in your clients, use the HTTP Accept Header, append the .xml suffix or ?format=xml

HTTP + XML

The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.

POST /xml/reply/ReversalRequest HTTP/1.1 
Host: booking.pufferdayspa.com 
Content-Type: application/xml
Content-Length: length

<reversalRequest xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://tripos.vantiv.com/2014/09/TriPos.Api">
  <cardHolderPresentCode>Default</cardHolderPresentCode>
  <clerkNumber>String</clerkNumber>
  <laneId>0</laneId>
  <referenceNumber>String</referenceNumber>
  <shiftId>String</shiftId>
  <ticketNumber>String</ticketNumber>
  <configuration>
    <marketCode>Default</marketCode>
  </configuration>
  <convenienceFeeAmount>0</convenienceFeeAmount>
  <paymentType>None</paymentType>
  <transactionAmount>0</transactionAmount>
  <transactionId>String</transactionId>
  <type>String</type>
</reversalRequest>
HTTP/1.1 200 OK
Content-Type: application/xml
Content-Length: length

<reversalResponse xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://tripos.vantiv.com/2014/09/TriPos.Api">
  <_errors>
    <error>
      <developerMessage>String</developerMessage>
      <errorType>String</errorType>
      <exceptionMessage>String</exceptionMessage>
      <exceptionTypeFullName>String</exceptionTypeFullName>
      <exceptionTypeShortName>String</exceptionTypeShortName>
      <userMessage>String</userMessage>
    </error>
  </_errors>
  <_hasErrors>true</_hasErrors>
  <_links />
  <_logs xmlns:d2p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
    <d2p1:string>String</d2p1:string>
  </_logs>
  <_type>String</_type>
  <_warnings>
    <warning>
      <developerMessage>String</developerMessage>
      <userMessage>String</userMessage>
    </warning>
  </_warnings>
  <_processor>
    <expressResponseCode>String</expressResponseCode>
    <expressResponseMessage>String</expressResponseMessage>
    <hostResponseCode>String</hostResponseCode>
    <hostResponseMessage>String</hostResponseMessage>
    <logs xmlns:d3p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
      <d3p1:string>String</d3p1:string>
    </logs>
    <processorLogs xmlns:d3p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
      <d3p1:string>String</d3p1:string>
    </processorLogs>
    <processorRawResponse>String</processorRawResponse>
    <processorReferenceNumber>String</processorReferenceNumber>
    <processorRequestFailed>false</processorRequestFailed>
    <processorRequestWasApproved>false</processorRequestWasApproved>
    <processorResponseCode>Unknown</processorResponseCode>
    <processorResponseMessage>String</processorResponseMessage>
    <rawResponse>String</rawResponse>
  </_processor>
  <approvalNumber>String</approvalNumber>
  <isApproved>false</isApproved>
  <merchantId>String</merchantId>
  <statusCode>None</statusCode>
  <transactionDateTime>String</transactionDateTime>
  <transactionId>String</transactionId>
  <accountNumber>String</accountNumber>
  <cardLogo>String</cardLogo>
  <convenienceFeeAmount>0</convenienceFeeAmount>
  <paymentType>String</paymentType>
  <terminalId>String</terminalId>
  <totalAmount>0</totalAmount>
</reversalResponse>