> For the complete documentation index, see [llms.txt](https://developer.siteminder.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://developer.siteminder.com/direct-booking-api/guides/quick-start.md).

# Quick Start

Everything you need to begin building with Direct Booking API.

This guide walks you through generating your API key, making your first request, and understanding the responses you'll receive. By the end you'll have a working call returning live property data.

## Get your API key

API keys are generated in two places depending on your integration type:&#x20;

* **Group integration:** Generate in MP Extranet under Direct Booking → API.&#x20;
* **Single property integration:** Generate in Platform under Direct Booking → Configuration → API Integration. \
  \
  → [Generate your API Key](/direct-booking-api/additional-resources/generate-api-key.md)\
  → [Manage your API Key](/direct-booking-api/additional-resources/manage-api-key.md)

{% hint style="warning" %}
Keys do not expire. Keep your key private — this API is for server-to-server use only.&#x20;
{% endhint %}

## API Specification File <a href="#api-specification-file" id="api-specification-file"></a>

**REST (OpenAPI)**

* **Direct Booking** — [download YAML](https://openapi.gitbook.com/o/qrJuVY5UOf3h7cLyla8z/spec/direct-booking-api.yaml)​

## Make your first call

You'll need your API key before continuing.

{% stepper %}
{% step %}

### Authenticate

Pass your key as a header on every call.&#x20;

{% code overflow="wrap" expandable="true" %}

```
Header: x-sm-api-key: YOUR_API_KEY
```

{% endcode %}
{% endstep %}

{% step %}

### Make the call

**If you are using a group-level key:** Your first call retrieves all properties in your group and returns the `uuid` you'll use in subsequent calls:&#x20;

```
GET /properties
```

{% code overflow="wrap" expandable="true" %}

```bash
curl -X GET "https://directbooking.siteminder.com/public-api/api/properties" -H "x-sm-api-key: YOUR_API_KEY" -H "accept: application/json"
```

{% endcode %}

**If you are using a property-level key:** `GET /properties` is not available. You can get your property details using the following:&#x20;

```
GET /properties/{propertyUuid}
```

Your property ID is shown on the API integration screen in Platform. Use it directly in subsequent calls:&#x20;

{% code overflow="wrap" expandable="true" %}

```bash
GET /properties/{propertyUuid}/room-types
GET /properties/{propertyUuid}/room-rates
GET /properties/{propertyUuid}/quotes
```

{% endcode %}
{% endstep %}

{% step %}

###

### Handle the response

The uuid is your property identifier — use it in subsequent calls for room types, room rates, and quotes.

{% code overflow="wrap" expandable="true" %}

```json
{
   "page":1,
   "perPage":10,
   "total":50,
   "totalPages":5,
   "items":[
      {
         "uuid":"f63ce398-da03-4573-856d-ed8d71e57e3d",
         "name":"Demo Hotel"
      },
      "..."
   ]
}
```

{% endcode %}
{% endstep %}

{% step %}

### Handle errors

If your key is missing or invalid:

{% code overflow="wrap" expandable="true" %}

```json
{
   "error":"Unauthorized",
   "message":"Invalid API key"
}
```

{% endcode %}

{% hint style="danger" %}
**401** - check your key is valid and passed in the x-sm-api-key header.
{% endhint %}

{% code overflow="wrap" expandable="true" %}

```json
{
  "errors": [
    {
      "code": "RateLimited",
      "message": "You have exceeded the quota for the key, please try again later."
    }
  ]
}
```

{% endcode %}

{% hint style="danger" %}
**429** - rate limit exceeded. Wait one minute before retrying.
{% endhint %}

→ See [API Reference](/direct-booking-api/reference/properties.md) for the full error details.
{% endstep %}
{% endstepper %}

{% hint style="success" icon="sparkles" %}

## Still have questions?

Use the <i class="fa-gitbook-assistant">:gitbook-assistant:</i> **Ask** button at the top of the page to chat with our AI assistant — it can help you navigate the guide, understand requirements, and troubleshoot issues.

If you need more support, visit [Integration Support](/integration-support/integration-support.md).
{% endhint %}


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://developer.siteminder.com/direct-booking-api/guides/quick-start.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
