Search for a guest

GET https://api.zenoti.com/v1/guests/search

This API helps you to search for a guest in the specified center or in the whole organization based on the Zenoti org level setting "Search Guest Across Centers".

Before you begin

Permission: Manage API Keys (on the Administrator security object) — Required to access Zenoti APIs.

Endpoint

GET /v1/guests/search

Base URL: https://api.zenoti.com

Request

Headers

Header Required Description
Authorization Yes bearer {{access_token}}

Query parameters

Parameter Type Required Default Description
center_id string No — Unique 32-character identifier of the center.
zip_code string No — Optional Zip code of the guest's address.
page integer (int32) No 1 Optional Number of the display page. Default value is 1.
size integer (int32) No 10 Optional Number of records per page. Default value is 10.
user_name string No — Optional Username of the guest
user_code string No — Optional User code of the guest
phone string No — Optional Phone number of the guest
email string No — Optional Email ID of the guest
first_name string No — Optional First name of the guest
last_name string No — Optional Last name of the guest
tags string No — Optional Any tags associated with a guest

Response

Success (200 OK)

{
  "guests": [
    {
      "...": "..."
    }
  ]
}

Response fields

Field Type Description
guests object[]
guests[].id string
guests[].code string
guests[].center_id string
guests[].personal_info object
guests[].address_info object
guests[].preferences object
guests[].tags string[]
guests[].referral object
guests[].primary_employee object

Example

curl --request GET \
  --url 'https://api.zenoti.com/v1/guests/search' \
  --header 'Authorization: bearer {{access_token}}'
const response = await fetch('https://api.zenoti.com/v1/guests/search', {
  method: 'GET',
  headers: {
    'Authorization': 'bearer {{access_token}}'
  },
});
const data = await response.json();
import requests

response = requests.get(
    'https://api.zenoti.com/v1/guests/search',
    headers={
        'Authorization': 'bearer {{access_token}}',
    },
)
data = response.json()
using var client = new HttpClient();
client.DefaultRequestHeaders.Add("Authorization", "bearer {{access_token}}");
var response = await client.GetAsync(
    "https://api.zenoti.com/v1/guests/search");
var data = await response.Content.ReadAsStringAsync();
require 'net/http'
require 'json'

uri = URI('https://api.zenoti.com/v1/guests/search')
http = Net::HTTP.new(uri.host, uri.port)
http.use_ssl = true
request = Net::HTTP::Get.new(uri)
request['Authorization'] = 'bearer {{access_token}}'
response = http.request(request)
data = JSON.parse(response.body)

Error codes

Status Description
400 400
401 Unauthorized -- invalid or expired access token
429 Too many requests -- rate limit exceeded