Last updated

creditcards (B.XML)

This call is used to retrieve credit card information that will be used on the interface B.XML (@name) and OTA (@ota) calls.

If there is no OTA abbreviation given, the standard xml @name term will be used within OTA as well.

Booking.com always accepts American Express, Euro/Mastercard and Visa as guarantee types for all guests, even when the accommodation does not accept them. Additionally, some accommodations do not require credit card information to guarantee the reservation.

Step 1: Request for a list of credit card names and OTA codes in use

POST https://supply-xml.booking.com/hotels/xml/creditcards

Request — HTTP Message Body Model

<?xml version="1.0" encoding="UTF-8"?>
<request>
  <username>providermachinelogin</username>
  <password>********</password>
</request>

Request — Node Overview

Node NameNest LevelParent NodeValue RangeData TypeNode Multiplicity
passwordL1request--string1
requestL0NULL(root)----1
usernameL1request--string1

Request — cURL Model

curl -H "Host: providerhostname" \
-H "Connection: keep-alive" \
-H "Content-Length: XXX" \
-H "Cache-Control: no-cache" \
-H "Origin: XXXXXXXXXXXXX" \
-H "User-Agent: Provider User-Agent name" \
-H "Content-Type: text/xml;charset=UTF-8" \
-H "Accept: */*" \
-H "Accept-Encoding: gzip,deflate" \
--http1.1 \
-d @messagebody.xml -X POST \
'https://supply-xml.booking.com/hotels/xml/creditcards'

Step 2: Response of credit card names and OTA codes

TypeHTTP MethodMessage SenderMessage Receiver
ResponsePOSTBooking.comConnectivity Partner

Response — HTTP Message Body Sample

<creditcards>
  <creditcard name="American Express"
              name_en="American Express"
              ota="AX" />
  <creditcard name="Visa"
              name_en="Visa"
              ota="VI" />
  <creditcard name="MasterCard"
              name_en="Euro/Mastercard"
              ota="MC" />
  <creditcard name="Diners Club"
              name_en="Diners Club"
              ota="DN" />
  <!-- example output. Use the API for a complete updated list -->
</creditcards>
<!-- RUID: [XXXXXXXXXXXXXXXXXXXXXXXXXXX==] -->

Response — Node Overview

Node NameNest LevelParent NodeValue RangeData TypeNode Multiplicity
creditcardL1creditcards----[see below]
creditcardsL0NULL(root)----1
  • The response body consists of a creditcards root element. This is the parent node to the creditcard node, whose multiplicity is determined by the number of credit card types available.

  • The empty child node creditcard contains the @name, @name_en, and @ota described below for the given credit card type.

Response — Attribute(@) Overview

Attribute NameNode NameValue RangeData TypeNode Multiplicity
@namecreditcard--string1
@name_encreditcard--string1
@otacreditcard[see below]string1
  • The @name of creditcard contains the name used in B.XML (and also OTA where **@ota is empty).

  • The @name_en of creditcard contains the English translation of the @name.

  • The @ota of creditcardcontains the two uppercase letters used for the specific @name. If there is not a code implememented, the B.XML @name will be used.

HTML-encoded unicode characters

creditcard[@name] and creditcard[@name_en] can contain HTML-encoded unicode characters, such as diacritics (accents). Examples include &#xE9; (unicode é) and &#xF5; (unicode õ).