Journey Docs
Members APICollections

Get Favorites

Get all favorited properties, optionally filtered by collection

GET/members/me/collections/favorites

Overview

Returns all favorited properties for the authenticated member. Can be filtered to show favorites from a specific collection or all favorites across collections.

Authentication

Requires a valid Clerk JWT token in the Authorization header.

Query Parameters

collectionIdquerynumber

Filter by collection ID. Omit to get all favorites, use null for default collection

Request

curl -X GET "http://localhost:3000/v1/members/me/collections/favorites" \
  -H "Authorization: Bearer YOUR_CLERK_JWT"

Response

favoritesarrayrequired

Array of favorited properties

array items
propertyDocumentIdstringrequired

Property document identifier

propertyNamestringrequired

Property name

propertySlugstring

Property URL slug for building links

heroImageUrlstring

Property hero image URL

collectionIdnumber

ID of the collection containing this favorite (null for default collection)

addedAtstringrequired

ISO 8601 timestamp when property was favorited

Response

[
  {
    "propertyDocumentId": "prop_luxury_maldives",
    "propertyName": "Luxury Resort Maldives",
    "propertySlug": "luxury-resort-maldives",
    "heroImageUrl": "https://cdn.journey.com/properties/maldives-hero.jpg",
    "collectionId": 1,
    "addedAt": "2024-04-15T14:30:00Z"
  },
  {
    "propertyDocumentId": "prop_santorini_villa",
    "propertyName": "Santorini Villa",
    "propertySlug": "santorini-villa",
    "heroImageUrl": "https://cdn.journey.com/properties/santorini-hero.jpg",
    "collectionId": 1,
    "addedAt": "2024-04-16T09:20:00Z"
  },
  {
    "propertyDocumentId": "prop_tokyo_business",
    "propertyName": "Tokyo Business Hotel",
    "propertySlug": "tokyo-business-hotel",
    "heroImageUrl": "https://cdn.journey.com/properties/tokyo-business-hero.jpg",
    "collectionId": 2,
    "addedAt": "2024-04-10T16:45:00Z"
  },
  {
    "propertyDocumentId": "prop_paris_boutique",
    "propertyName": "Paris Boutique Hotel",
    "propertySlug": "paris-boutique-hotel",
    "heroImageUrl": "https://cdn.journey.com/properties/paris-boutique-hero.jpg",
    "collectionId": null,
    "addedAt": "2024-04-08T12:15:00Z"
  }
]

Filtering Options

All Favorites

  • No collectionId parameter: Returns all favorites across all collections
  • Use case: Master view of all favorited properties

Specific Collection

  • collectionId=1: Returns favorites only from collection ID 1
  • Use case: View favorites within a specific themed collection

Default Collection

  • collectionId=null: Returns favorites in the default (unsorted) collection
  • Use case: View favorites that haven't been organized into collections

Collection Associations

collectionId Values

  • null: Property is in the default "Favorites" collection
  • number: Property is in a specific user-created collection
  • Multiple: Properties can be in multiple collections (not currently supported)

Collection Context

The collectionId field helps understand the organization:

  • Use it to group favorites by collection in your UI
  • Filter by collection for focused browsing experiences
  • Show collection context when displaying individual favorites

Sorting

Favorites are returned in chronological order:

  • Most Recent First: Newest favorites appear first
  • addedAt Field: Use for custom sorting if needed
  • Consistent: Order is stable across requests

Property Information

Each favorite includes:

  • Identification: Document ID for API calls, slug for URLs
  • Display: Name and hero image for UI rendering
  • Context: Collection membership and favorite date
  • Linking: Slug can be used to build property detail URLs

On this page