Skip to main content

Get all appointments for a community.

Returns a paginated list of booked appointments ordered by appointment ID.

GET
/api/partners/v1/community/:community_id/appointments/booked/

Request

Example requestGET
curl -X GET \
    -H "Authorization: Bearer YOUR_API_KEY" \
    "https://api.funnelleasing.com/api/partners/v1/community/1234/appointments/booked/"

Response

Example responseJSON200 · application/json
{
  "data": [
    {
      "id": 123,
      "date": "2023-10-05",
      "time": "09:55",
      "client": {
        "id": 1,
        "first_name": "John",
        "last_name": "Doe",
        "email": "johndoe@sample.email",
        "phone": "+15551234567",
        "origin_source": "Online Leasing"
      },
      "agent": {
        "name": "Jane Doe",
        "email": "janedoe@sample.email"
      },
      "tour_type": "Self-Guided",
      "status": "Completed"
    }
  ],
  "page": 1,
  "total_pages": 1,
  "total_items": 1
}
⚠️

No matches returns 404, not an empty list

If nothing matches your filters, this endpoint returns 404 with a data field that's a descriptive string, not an array — a shape change you need to handle separately from the success case. The exact wording depends on which date filter you used:

{ "data": "No booked appointments found for provided date: 2024-01-01" }
{ "data": "No booked appointments found in date range: 2024-01-01 to 2024-01-31" }
{ "data": "No booked appointments found" }

The last form appears when neither date nor from_date/to_date was supplied (for example, filtering only by email or phone, or passing no filters at all). Note this differs from an out-of-range page number, which returns a normal 200 with an empty data array instead.

Errors

Errors specific to this endpoint

to_date Required (400)

Returned when from_date is supplied without to_date.

Error responseJSON400 · application/json
{
"error_type": "ValidationError",
"errors": { "to_date": ["to_date is required when from_date is specified."] }
}

from_date Required (400)

Returned when to_date is supplied without from_date.

Error responseJSON400 · application/json
{
"error_type": "ValidationError",
"errors": { "from_date": ["from_date is required when to_date is specified."] }
}

to_date Before from_date (400)

Returned when to_date is earlier than from_date.

Error responseJSON400 · application/json
{
"error_type": "ValidationError",
"errors": { "to_date": ["to_date can't precede from_date."] }
}

Range Exceeds 365 Days (400)

Returned when the from_date/to_date range spans more than 365 days.

Error responseJSON400 · application/json
{
"error_type": "ValidationError",
"errors": { "from_date": ["Date range cannot exceed 365 days when using from_date and to_date parameters."] }
}

Invalid Phone Number (400)

Returned when phone fails validation. There are three possible message variants depending on why parsing failed: an invalid number ("Invalid phone number."), an unparseable format with additional detail appended ("Could not parse provided phone number: <detail>"), or a bare fallback ("Could not parse provided phone number.") when nothing usable could be extracted.

Error responseJSON400 · application/json
{
"error_type": "ValidationError",
"errors": { "phone": ["Invalid phone number."] }
}

Invalid page or per_page (400)

Returned when page or per_page isn't a valid integer.

Error responseJSON400 · application/json
{
"error_type": "ValidationError",
"errors": { "per_page": "Invalid value" }
}