# Retrieve a brand by ID

Endpoint: GET /brands/{brandId}
Version: 1.0
Security: bearer

## Security:

  - `bearer` (unknown)
    http bearer JWT

## Path parameters:

  - `brandId` (number, required)

## Query parameters:

  - `userId` (number)
    Filter by related userId (via UserBrand relation)

  - `title` (string)
    The title of the brand

  - `organizationId` (array)
    The organizationId of the brand

  - `clientAccountId` (array)
    The clientAccountId of the brand

## Response 200:

  - `200` (unknown)
    Brand retrieved successfully.

## Response 200 fields (application/json):

  - `id` (number, required)
    The ID of the brand to be updated
    Example: 456

  - `title` (string, required)
    The title of the brand
    Example: HealthCorp

  - `clientAccountId` (number, required)
    The client account id of the brand
    Example: 1

  - `clientAccount` (object, required)
    The client account of the brand

  - `clientAccount.id` (number, required)
    The ID of the client account
    Example: 123

  - `clientAccount.title` (string, required)
    The title of the client account
    Example: Downtown Clinic

  - `organization` (object, required)
    The organization the brand

  - `organization.id` (number)
    The ID of the organization the brand is associated with
    Example: 123

  - `organization.title` (string, required)
    The title of the organization the brand is associated with
    Example: HealthCorp

  - `organization.clientAccountId` (number)
    The ID of the client account the brand is associated with
    Example: 123

  - `organization.website` (string)
    The website of the organization the brand is associated with
    Example: www.healthcorp.com

  - `organization.isEnabled` (boolean, required)
    Indicates whether the organization is enabled
    Example: true

  - `organization.createdAt` (string, required)
    The date and time the brand was created
    Example: 2021-05-01T12:00:00Z

  - `organization.updatedAt` (string, required)
    The date and time the brand was last updated
    Example: 2021-05-01T12:00:00Z

  - `sites` (array, required)
    The sites associated with the brand

  - `sites.id` (number, required)
    The ID of the site the brand is associated with
    Example: 123

  - `sites.name` (string, required)
    The name of the site
    Example: Downtown Clinic

  - `sites.address` (object, required)
    The address information of the site

  - `sites.address.lat` (number, required)
    The latitude coordinate of the address
    Example: 37.7749

  - `sites.address.lng` (number, required)
    The longitude coordinate of the address
    Example: -122.4194

  - `sites.address.url` (string, required)
    The URL associated with the address
    Example: https://maps.google.com/?q=123+Main+St

  - `sites.address.formatted_address` (string, required)
    The formatted address string
    Example: 123 Main St, San Francisco, CA 94103

  - `sites.googlePlaceId` (string, required)
    The Google Place ID for the site
    Example: ChIJN1t_tDeuEmsRUsoyG83frY4

  - `sites.phoneNumber` (string)
    The phone number of the site
    Example: +1 (555) 123-4567

  - `sites.website` (string)
    The website of the site
    Example: https://downtownclinic.com

  - `sites.anyDeskIp` (string)
    The AnyDesk IP address for remote access
    Example: 192.168.1.100

  - `sites.createdByUserId` (number, required)
    The ID of the user who created the site
    Example: 456

  - `sites.createdAt` (string, required)
    The date and time the site was created
    Example: 2021-05-01T12:00:00Z

  - `sites.updatedAt` (string, required)
    The date and time the site was last updated
    Example: 2021-05-01T12:00:00Z

  - `sites.deletedAt` (string)
    The date and time the site was deleted, if applicable
    Example: null

  - `sites.organizationId` (number, required)
    The ID of the organization the site belongs to
    Example: 789

  - `sites.clientAccountId` (number, required)
    The ID of the client account the site is associated with
    Example: 101

  - `sites.brandId` (number, required)
    The ID of the brand the site is associated with
    Example: 202

  - `sites.practiceManagementSystemId` (number, required)
    The ID of the practice management system used by the site
    Example: 303

  - `sites.licenseKey` (string, required)
    The license key for the site
    Example: XXX-YYY-ZZZ-AAA-BBB

  - `sites.fhirStoreId` (string, required)
    The ID of the FHIR store associated with the site
    Example: fhir-store-123

  - `sites.firstSyncDate` (string)
    The date of the first sync with the site
    Example: 2021-05-15T12:00:00Z

  - `sites.latestSyncDate` (string)
    The date of the most recent sync with the site
    Example: 2021-06-01T12:00:00Z

  - `sites.siteManagerUserId` (number, required)
    The ID of the user who manages the site
    Example: 505

  - `sites.cloudUserName` (string)
    The cloud username for the site
    Example: downtown.clinic

  - `sites.cloudOrganizationName` (string)
    The name of the cloud organization for the site
    Example: HealthCorp Cloud

  - `sites.cloudLoginUrl` (string)
    The URL for cloud login
    Example: https://cloud.healthcorp.com/login

  - `sites.practiceManagementSystem` (object, required)
    The practice management system used by the site

  - `sites.practiceManagementSystem.id` (number, required)
    The ID of the practice management system
    Example: 789

  - `sites.practiceManagementSystem.title` (string, required)
    The title of the practice management system
    Example: MedicalSoft Pro

  - `sites.practiceManagementSystem.isCloudBased` (boolean, required)
    Indicates whether the system is cloud-based
    Example: true

  - `sites.practiceManagementSystem.isEnabled` (boolean, required)
    Indicates whether the system is enabled
    Example: true

  - `sites.practiceManagementSystem.createdAt` (string, required)
    The date and time the system was created
    Example: 2021-05-01T12:00:00Z

  - `sites.practiceManagementSystem.updatedAt` (string, required)
    The date and time the system was last updated
    Example: 2021-05-01T12:00:00Z

  - `isEnabled` (boolean, required)
    Indicates whether the brand is enabled
    Example: true

  - `createdAt` (string, required)
    The date and time the brand was created
    Example: 2021-05-01T12:00:00Z

  - `updatedAt` (string, required)
    The date and time the brand was last updated
    Example: 2021-05-01T12:00:00Z

## Response 400:

  - `400` (unknown)
    Bad Request

## Response 401:

  - `401` (unknown)
    Unauthorized: Invalid or missing token.

## Response 401 fields (application/json):

  - `message` (string, required)
    Error message indicating unauthorized access.
    Example: Unauthorized

  - `statusCode` (number, required)
    HTTP status code for unauthorized access.
    Example: 401

## Response 403:

  - `403` (unknown)
    Forbidden: Access denied due to unaccepted Terms or insufficient permissions.

## Response 403 fields (application/json):

  - `statusCode` (number, required)
    HTTP status code indicating forbidden access due to unaccepted Terms of Service.
    Example: 403

  - `message` (string, required)
    Human-readable explanation of the error.
    Example: User must accept Terms of Service before continuing

  - `reason` (string, required)
    Machine-readable reason code for the error.
    Example: tos_required

  - `termsOfServicesLink` (string, required)
    URL to the Terms of Service the user must accept.
    Example: https://heydonto.com/terms-of-use/

  - `timestamp` (string, required)
    Timestamp when the error occurred (ISO 8601).
    Example: 2025-01-01T00:00:00.000Z

  - `statusCode` (number, required)
    HTTP status code indicating forbidden access.
    Example: 403

