
# Certification Cases

_A guide for customers integrating against the TTDbooking API platform._

---

## Overview

Every new integration is certified before it is switched on for production. Certification confirms that your implementation drives the booking flow correctly, returns sound data, and satisfies the requirements our suppliers impose on downstream systems. Clearing it is what unlocks production credentials.

The exercise is there to confirm that your integration can:

- Run the complete TTDbooking booking flow from search through to cancellation
- Meet the **mandatory supplier requirements**, which we validate automatically
- Behave predictably and accurately for the travellers using it

We assess **functional correctness only** — how your interface looks is not part of the review.

---

## Test Environment Information

All certification work is carried out against the TTDbooking test environment.

| Item                      | Value                                          |
| ------------------------- | ---------------------------------------------- |
| **Test Environment URL**  | `https://api-test.ttdbooking.com`              |
| **Authentication Method** | Bearer Token (obtained via `/ticket` endpoint) |
| **Documentation URL**     | `https://developer.ttdbooking.com/hotel-api/docs`                                 |
| **Technical Support**     | `integrations@ttdbooking.com`                            |

### Test Credentials

```
appKey: ttdbooking_api_demo
appSecret: ttdbooking_api_demo
```

### Test Hotel IDs

These hotel IDs are kept stable in the test environment and are a convenient starting point for certification runs:

| Hotel ID | Hotel Name                       | Location      | Star Rating |
| -------- | -------------------------------- | ------------- | ----------- |
| `1`      | Marina Bay Sands Singapore       | Singapore     | ⭐⭐⭐⭐⭐  |
| `2`      | Dubai Marina Luxury Resort & Spa | Dubai, UAE    | ⭐⭐⭐⭐⭐  |
| `3`      | Paris Eiffel Tower View Hotel    | Paris, France | ⭐⭐⭐⭐⭐  |
| `4`      | Downtown Dubai Business Hotel    | Dubai, UAE    | ⭐⭐⭐⭐    |
| `5`      | Tokyo Shinjuku Boutique Hotel    | Tokyo, Japan  | ⭐⭐⭐⭐    |

### Test Environment Notes

- What is available in test will not necessarily match production
- Rates and inventory are simulated, but modelled on realistic data
- The hotels above are suggestions only — **any hotel returning availability can be used**
- The simulator produces stable, repeatable rate data, so repeated runs stay consistent

---

## Certification Scenarios

Certification is assessed on **complete end-to-end booking scenarios** rather than on individual API calls in isolation. Each scenario checks that your integration carries every required step of the booking flow through consistently.

### Core Scenarios

Between them, the two scenarios below cover the booking patterns you are most likely to encounter.

| Scenario                                       | Rooms & Occupancy                                                                                                                          | Cancellation                               | Meal                                |
| ---------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------ | ----------------------------------- |
| **Scenario 1**<br>Multiple Rooms, complex case | **3 × Rooms**<br>• Room 1: 2 Adults + 2 Children (Age: 5 and 7 years)<br>• Room 2: 2 Adults + 1 Child (Age: 4 years)<br>• Room 3: 2 Adults | Refundable<br>`"refundableMode": "full"`   | With Breakfast<br>`"boardId": "BB"` |
| **Scenario 2**<br>Single Room, standard case   | **1 × Room**<br>• 2 Adults                                                                                                                 | Non-Refundable<br>`"refundableMode": "no"` | Half-board<br>`"boardId": "HB"`     |

### Test Core Booking Flow

For each scenario, capture and submit the **JSON request and response files** for the full API sequence set out below:

| Booking Flow Method                           | Request Requirements                                                                                                                                                                                                                                                  | Response Requirements                                                                                                                                                                                |
| --------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| **HotelList**                                 | • Search using the rooms and occupancy defined by the scenario<br>• List of hotels searched: ≤ 50                                                                                                                                                                     | • At least one hotel rate matching the scenario criteria is returned<br> - Scenario 1: `"refundableMode": "full"` + `"boardId": "BB"`<br> - Scenario 2: `"refundableMode": "no"` + `"boardId": "HB"` |
| **HotelRates**                                | • Send the **same session-id** returned by HotelList<br>• Send the hotelId that corresponds to the scenario                                                                                                                                                           | • Success response, with the same rate or an updated one                                                                                                                                             |
| **CheckAvail**<br>(Mandatory rate validation) | • `ratePkgId`: the rate package ID you picked out of the HotelRates response<br>• Carry the **same session-id** through so the booking process stays tracked                                                                                                          | • Success response, with the same rate or an updated one                                                                                                                                             |
| **Book**                                      | • `customerReferenceNo`: your reference number for the booking<br>• `ratePkgId`: the rate package ID that CheckAvail validated<br>• `guests`: guest details for the booking, per room<br>• Carry the **same session-id** through so the booking process stays tracked | • Booking succeeds and returns a status                                                                                                                                                              |
| **Cancel**                                    | • `supplierReferenceNo`: the supplier's order reference number                                                                                                                                                                                                        | • Cancellation succeeds                                                                                                                                                                              |
| **QueryOrders**                               | • `customerReferenceNos`: the customer reference numbers issued via the Book API                                                                                                                                                                                      | • The response contains the details of the order being queried                                                                                                                                       |

---

## Additional Self-Testing Scenarios

| Scenario               | Purpose                                            | Test Requirements                                                                                                                               |
| ---------------------- | -------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------- |
| **Response Time Test** | Confirm API response performance                   | • HotelList endpoint response time < 5 seconds<br>• CheckAvail endpoint response time < 3 seconds<br>• Book endpoint response time < 50 seconds |
| **Concurrency Test**   | Confirm the integration copes with concurrent load | • Fire 10 search requests at the same time<br>• Confirm every request comes back normally<br>• Exercise your rate-limit handling                |

---

## Submit for Certification

When you have worked through every scenario, send us the complete set of **raw JSON request and response files** for review, following the requirements below.

### File Requirements

#### File Type

- Everything you submit must be in **`.json` format**
- Raw logs, Postman exports, and server traces are all fine

#### File Naming Convention (Mandatory)

Name every certification file according to this pattern:

```
<scenarioPrefix>_<rq|rs>_<apiName>.json
```

**Where:**

- `scenarioPrefix` = `s1` or `s2`
- `rq` = request
- `rs` = response
- `apiName` = `hotelList`, `hotelRates`, `checkAvail`, `book`, `queryOrders`, `cancel`

#### Example Files (Scenario 1)

| Flow        | Request File             | Response File            |
| ----------- | ------------------------ | ------------------------ |
| HotelList   | `s1_rq_hotelList.json`   | `s1_rs_hotelList.json`   |
| HotelRates  | `s1_rq_hotelRates.json`  | `s1_rs_hotelRates.json`  |
| CheckAvail  | `s1_rq_checkAvail.json`  | `s1_rs_checkAvail.json`  |
| Book        | `s1_rq_book.json`        | `s1_rs_book.json`        |
| Cancel      | `s1_rq_cancel.json`      | `s1_rs_cancel.json`      |
| QueryOrders | `s1_rq_queryOrders.json` | `s1_rs_queryOrders.json` |

### Submission Method

Send the finished files to us by email:

- **Email:** [integrations@ttdbooking.com](mailto:integrations@ttdbooking.com)
- **Email Subject:** **Integration Review – [Your Company Name]**
- **Attachments:** every JSON file, named as described above

---

## Final Certification Outcome

Once we have been through your submitted JSON files, we will come back to you with one of these three results:

| Certification Outcome       | Detail                                                                                                         |
| --------------------------- | -------------------------------------------------------------------------------------------------------------- |
| ✅ **Pass**                 | Everything we require is working as expected. You are cleared to go live.                                      |
| ☑️ **Pass with conditions** | A few minor points need correcting. The integration can move forward once we have confirmed those fixes.       |
| ❌ **Retry Required**       | We found functional errors serious enough to block release. Correct them and resubmit every affected scenario. |

---

## Appendix: Sample Request/Response Templates

### Scenario 1: HotelList Request

```json
{
  "hotelIds": [1, 2, 3],
  "checkIn": "2026-02-15",
  "checkOut": "2026-02-17",
  "roomOccupancies": [
    {
      "adultCount": 2,
      "childrenAges": [5, 7]
    },
    {
      "adultCount": 2,
      "childrenAges": [4]
    },
    {
      "adultCount": 2,
      "childrenAges": []
    }
  ],
  "nationalityCode": "US"
}
```

### Scenario 1: Expected Rate Matching

In Scenario 1, the rate you select needs to look like this:

```json
{
  "refundableMode": "full",
  "board": {
    "boardId": "BB"
  }
}
```

### Scenario 2: HotelList Request

```json
{
  "hotelIds": [4, 5],
  "checkIn": "2026-02-15",
  "checkOut": "2026-02-17",
  "roomOccupancies": [
    {
      "adultCount": 2,
      "childrenAges": []
    }
  ],
  "nationalityCode": "US"
}
```

### Scenario 2: Expected Rate Matching

In Scenario 2, the rate you select needs to look like this:

```json
{
  "refundableMode": "no",
  "board": {
    "boardId": "HB"
  }
}
```

---

## Frequently Asked Questions

### Q: Can I use any hotel for testing?

**A:** Yes. The hotel IDs we list are recommendations that give you a stable baseline, but any hotel that returns availability in the test environment is acceptable for certification.

### Q: What if the test hotel shows no availability?

**A:** The listed test hotels are set up to return availability at all times. If one does not, write to integrations@ttdbooking.com and we will look into it.

### Q: How do I maintain the same session-id across API calls?

**A:** HotelList returns the session-id in its response. Pass that same value on to HotelRates, CheckAvail, and Book, using the same header or request field.

### Q: What currencies are supported in the test environment?

**A:** USD is used by default. EUR, GBP, CNY, and the other major currencies can also be tested by setting the `Currency` header.

### Q: How long is the test data valid?

**A:** Test data is generated on the fly from the parameters you send. For the most reliable results, use a check-in date at least 7 days ahead.

---

Working through this certification is what gives both sides confidence that an integration is ready for live traffic. Pass it, and we will issue your production access.

---

Full API reference: [developer.ttdbooking.com/hotel-api/docs](https://developer.ttdbooking.com/hotel-api/docs)

_Last Updated: December 2025_
_Version: 1.0_
