# Get customs fields for a guest

The **`xp-customs-fields`** endpoint allows partners to retrieve a list of customer and stay customs fields and their value.&#x20;

### Request

<mark style="color:green;">**GET**</mark>

```url
https://interface.experience-hotel.com/api/xp-customs-fields?email=test@test.com
```

* **URL Parameter**: `email` (the email address of the customer)

### Possible return&#x20;

<mark style="color:green;">`200 OK`</mark>

```json
{
    "customer_custom_fields": [
        {
            "name": "Loyalty level",
            "values": [
                "Gold"
            ]
        },
        {
            "name": "Préferences",
            "values": [
                "Some value",
                "Some other value"
            ]
        }
    ],
    "stay_custom_fields": [
        {
            "stay_reference": "123456789",
            "data": [
                {
                    "name": "ota_src",
                    "value": "Booking.com"
                }
            ]
        }
    ]
}
```

<mark style="color:orange;">`404 Not Found`</mark>

```json
"customer not found"
```

&#x20;No Customer found with this email in the CRM.&#x20;


---

# Agent Instructions: Querying This Documentation

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

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://experience-crm.gitbook.io/experience-crm-api/guests/guest-custom-fields/get-customs-fields-for-a-guest.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
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.
