> ## Documentation Index
> Fetch the complete documentation index at: https://restoo.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Search Customers

> Searches customers by phone and/or email. At least one parameter is required.
Returns all customers matching any of the provided criteria.



## OpenAPI

````yaml /public-api.json get /customers
openapi: 3.1.0
info:
  title: Restoo Public API
  version: 3.0.0-alpha
  description: Connect your App with Restoo.
servers:
  - url: https://api-dev.myrestoo.net/v3
    description: Dev
  - url: https://api.myrestoo.net/v3
    description: Prod
security:
  - http: []
tags:
  - name: Review
paths:
  /customers:
    get:
      tags:
        - Customer
      summary: Search Customers
      description: >-
        Searches customers by phone and/or email. At least one parameter is
        required.

        Returns all customers matching any of the provided criteria.
      operationId: customer.search
      parameters:
        - name: phone
          in: query
          schema:
            type:
              - string
              - 'null'
            description: The customer phone number in E.164 format
            examples:
              - '+34600111222'
        - name: email
          in: query
          schema:
            type:
              - string
              - 'null'
            format: email
            description: The customer email
            examples:
              - steve.jobs@restoo.me
        - name: Restoo-Partner-Id
          in: header
          required: true
          description: Unique identifier of your Partner account (defined by Restoo).
          schema:
            type: string
          example: your-restoo-partner-id
        - name: Restoo-Account-Id
          in: header
          required: true
          description: >-
            Unique identifier of the
            [Tenant](/getting-started/key-concepts#tenant).
          schema:
            type: string
          example: best-burger
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                type: object
                properties:
                  data:
                    anyOf:
                      - type: array
                        items:
                          $ref: '#/components/schemas/PrivateCustomerResponse'
                      - type: array
                        items:
                          $ref: '#/components/schemas/PublicCustomerResponse'
                required:
                  - data
        '409':
          $ref: '#/components/responses/UserNotFoundException'
        '422':
          $ref: '#/components/responses/ValidationException'
components:
  schemas:
    PrivateCustomerResponse:
      type: object
      description: Private Customer details.
      properties:
        privateNotes:
          type:
            - string
            - 'null'
          description: Internal notes about the customer, visible only to venue staff
          examples:
            - Customer prefers a table near the terrace.
          maxLength: 2048
        visitFrequency:
          type:
            - integer
            - 'null'
          description: >-
            Average frequency of visits, expressed as the number of days between
            visits
          examples:
            - 30
          minimum: 0
        averageOrderAmountPerPax:
          type:
            - integer
            - 'null'
          description: Average order amount per guest (in cents)
          examples:
            - 4500
          minimum: 0
        bookingReputation:
          type: number
          description: >-
            The customer's reputation score based on their booking behavior.

            Calculated by Restoo from attendance, cancellation, and no-show
            history.

             Interpretation:
             - Negative values: poor reputation.
             - 0: no sufficient history (neutral).
             - Positive values: good reputation
          examples:
            - 0.85
        bookingsCount:
          type: integer
          description: Total number of bookings made by the customer
          examples:
            - 25
          minimum: 0
        visitsCount:
          type: integer
          description: Total number of completed visits by the customer
          examples:
            - 18
          minimum: 0
        cancellationsCount:
          type: integer
          description: Total number of cancellations made by the customer
          examples:
            - 3
          minimum: 0
        noShowsCount:
          type: integer
          description: Total number of no-shows by the customer
          examples:
            - 2
          minimum: 0
        firstVisitAt:
          type:
            - string
            - 'null'
          format: date-time
          description: The date and time of the customer's first visit in ISO 8601 format
          examples:
            - '2023-05-10T20:00:00+02:00'
        lastVisitAt:
          type:
            - string
            - 'null'
          format: date-time
          description: >-
            The date and time of the customer's most recent visit in ISO 8601
            format
          examples:
            - '2025-03-15T21:30:00+02:00'
        firstCancellationAt:
          type:
            - string
            - 'null'
          format: date-time
          description: >-
            The date and time of the customer's first cancellation in ISO 8601
            format
          examples:
            - '2024-09-12T19:00:00+02:00'
        nextVisitScheduledAt:
          type:
            - string
            - 'null'
          format: date-time
          description: >-
            The date and time of the customer's next scheduled visit in ISO 8601
            format
          examples:
            - '2025-04-05T22:00:00+02:00'
        tags:
          type: array
          description: List of customer tags
          items:
            $ref: '#/components/schemas/Tag'
        uuid:
          type: string
          description: The Customer UUID
          examples:
            - 50b5571be67b477baa9dead4b290c555
        email:
          type:
            - string
            - 'null'
          format: email
          description: The Customer's email address
          examples:
            - steve.jobs@restoo.me
        phone:
          type:
            - string
            - 'null'
          description: The Customer's phone number in E.164 format
          examples:
            - '+34600111222'
        birthDate:
          type:
            - string
            - 'null'
          format: date
          description: Date of birth of the Customer in ISO 8601 format (YYYY-MM-DD)
          examples:
            - '1979-03-20'
        postalCode:
          type:
            - string
            - 'null'
          description: The Customer's postal code
          examples:
            - '28045'
          maxLength: 12
        isVip:
          type: boolean
          description: Indicates whether the Customer is marked as VIP
          examples:
            - true
        isBusiness:
          type: boolean
          description: Indicates whether the Customer is associated with a business
          examples:
            - false
        language:
          $ref: '#/components/schemas/CustomerLanguageEnum'
          description: >-
            The preferred language of the Customer, represented as an ISO 639-1
            code
          examples:
            - en
        acceptsImportantAlerts:
          type: boolean
          description: >-
            Indicates whether the customer agrees to receive important alerts
            related to their bookings

            (e.g., cancellations due to weather or unexpected incidents)
          examples:
            - true
        hasGdprConsent:
          type: boolean
          description: Indicates whether the Customer has given GDPR consent
          examples:
            - true
        acceptsMarketing:
          type: boolean
          description: >-
            Indicates whether the Customer has consented to receive marketing
            communications
          examples:
            - true
        country:
          $ref: '#/components/schemas/CountryEnum'
          description: The country represented as a two-letter ISO 3166-1 alpha-2 code
          examples:
            - ES
        name:
          type: string
          description: The full name of the Customer
          examples:
            - Steve Jobs
          minLength: 3
          maxLength: 255
      required:
        - privateNotes
        - visitFrequency
        - averageOrderAmountPerPax
        - bookingReputation
        - bookingsCount
        - visitsCount
        - cancellationsCount
        - noShowsCount
        - firstVisitAt
        - lastVisitAt
        - firstCancellationAt
        - nextVisitScheduledAt
        - tags
        - uuid
        - email
        - phone
        - birthDate
        - postalCode
        - isVip
        - isBusiness
        - language
        - acceptsImportantAlerts
        - hasGdprConsent
        - acceptsMarketing
        - country
        - name
      title: PrivateCustomerResponse
    PublicCustomerResponse:
      type: object
      description: Public Customer details.
      properties:
        uuid:
          type: string
          description: The Customer UUID
          examples:
            - 50b5571be67b477baa9dead4b290c555
        email:
          type:
            - string
            - 'null'
          format: email
          description: The Customer's email address
          examples:
            - steve.jobs@restoo.me
        phone:
          type:
            - string
            - 'null'
          description: The Customer's phone number in E.164 format
          examples:
            - '+34600111222'
        birthDate:
          type:
            - string
            - 'null'
          format: date
          description: Date of birth of the Customer in ISO 8601 format (YYYY-MM-DD)
          examples:
            - '1979-03-20'
        postalCode:
          type:
            - string
            - 'null'
          description: The Customer's postal code
          examples:
            - '28045'
          maxLength: 12
        isVip:
          type: boolean
          description: Indicates whether the Customer is marked as VIP
          examples:
            - true
        isBusiness:
          type: boolean
          description: Indicates whether the Customer is associated with a business
          examples:
            - false
        language:
          $ref: '#/components/schemas/CustomerLanguageEnum'
          description: >-
            The preferred language of the Customer, represented as an ISO 639-1
            code
          examples:
            - en
        acceptsImportantAlerts:
          type: boolean
          description: >-
            Indicates whether the customer agrees to receive important alerts
            related to their bookings

            (e.g., cancellations due to weather or unexpected incidents)
          examples:
            - true
        hasGdprConsent:
          type: boolean
          description: Indicates whether the Customer has given GDPR consent
          examples:
            - true
        acceptsMarketing:
          type: boolean
          description: >-
            Indicates whether the Customer has consented to receive marketing
            communications
          examples:
            - true
        country:
          $ref: '#/components/schemas/CountryEnum'
          description: The country represented as a two-letter ISO 3166-1 alpha-2 code
          examples:
            - ES
        name:
          type: string
          description: The full name of the Customer
          examples:
            - Steve Jobs
          minLength: 3
          maxLength: 255
      required:
        - uuid
        - email
        - phone
        - birthDate
        - postalCode
        - isVip
        - isBusiness
        - language
        - acceptsImportantAlerts
        - hasGdprConsent
        - acceptsMarketing
        - country
        - name
      title: PublicCustomerResponse
    Tag:
      type: object
      description: Customer tag details.
      properties:
        id:
          type: integer
          description: The tag unique identifier
          examples:
            - 1
        name:
          type: string
          description: The tag display name
          examples:
            - VIP
        color:
          type: string
          description: The tag color in hexadecimal format
          examples:
            - '#FF5733'
      required:
        - id
        - name
        - color
      title: Tag
    CustomerLanguageEnum:
      type: string
      enum:
        - es
        - ca
        - it
        - en
        - de
        - fr
        - pt
        - eu
      title: CustomerLanguageEnum
    CountryEnum:
      type: string
      enum:
        - AF
        - AX
        - AL
        - DZ
        - AS
        - AD
        - AO
        - AI
        - AQ
        - AG
        - AR
        - AM
        - AW
        - AU
        - AT
        - AZ
        - BS
        - BH
        - BD
        - BB
        - BY
        - BE
        - BZ
        - BJ
        - BM
        - BT
        - BO
        - BQ
        - BA
        - BW
        - BV
        - BR
        - IO
        - BN
        - BG
        - BF
        - BI
        - CV
        - KH
        - CM
        - CA
        - KY
        - CF
        - TD
        - CL
        - CN
        - CX
        - CC
        - CO
        - KM
        - CG
        - CD
        - CK
        - CR
        - CI
        - HR
        - CU
        - CW
        - CY
        - CZ
        - DK
        - DJ
        - DM
        - DO
        - EC
        - EG
        - SV
        - GQ
        - ER
        - EE
        - SZ
        - ET
        - FK
        - FO
        - FJ
        - FI
        - FR
        - GF
        - PF
        - TF
        - GA
        - GM
        - GE
        - DE
        - GH
        - GI
        - GR
        - GL
        - GD
        - GP
        - GU
        - GT
        - GG
        - GN
        - GW
        - GY
        - HT
        - HM
        - VA
        - HN
        - HK
        - HU
        - IS
        - IN
        - ID
        - IR
        - IQ
        - IE
        - IM
        - IL
        - IT
        - JM
        - JP
        - JE
        - JO
        - KZ
        - KE
        - KI
        - KP
        - KR
        - XK
        - KW
        - KG
        - LA
        - LV
        - LB
        - LS
        - LR
        - LY
        - LI
        - LT
        - LU
        - MO
        - MG
        - MW
        - MY
        - MV
        - ML
        - MT
        - MH
        - MQ
        - MR
        - MU
        - YT
        - MX
        - FM
        - MD
        - MC
        - MN
        - ME
        - MS
        - MA
        - MZ
        - MM
        - NA
        - NR
        - NP
        - NL
        - NC
        - NZ
        - NI
        - NE
        - NG
        - NU
        - NF
        - MK
        - MP
        - 'NO'
        - OM
        - PK
        - PW
        - PS
        - PA
        - PG
        - PY
        - PE
        - PH
        - PN
        - PL
        - PT
        - PR
        - QA
        - RE
        - RO
        - RU
        - RW
        - BL
        - SH
        - KN
        - LC
        - MF
        - PM
        - VC
        - WS
        - SM
        - ST
        - SA
        - SN
        - RS
        - SC
        - SL
        - SG
        - SX
        - SK
        - SI
        - SB
        - SO
        - ZA
        - GS
        - SS
        - ES
        - LK
        - SD
        - SR
        - SJ
        - SE
        - CH
        - SY
        - TW
        - TJ
        - TZ
        - TH
        - TL
        - TG
        - TK
        - TO
        - TT
        - TN
        - TR
        - TM
        - TC
        - TV
        - UG
        - UA
        - AE
        - GB
        - UM
        - US
        - UY
        - UZ
        - VU
        - VE
        - VN
        - VG
        - VI
        - WF
        - EH
        - YE
        - ZM
        - ZW
      title: CountryEnum
  responses:
    UserNotFoundException:
      description: >-
        Business Logic Error — The request is syntactically correct but cannot
        be processed due to logical constraints. Example: attempting to create a
        booking on a closed day or outside the allowed hours.
      content:
        application/problem+json:
          schema:
            type: object
            properties:
              type:
                type: string
                description: A URI identifier that categorizes the error type.
                examples:
                  - about:blank
              title:
                type: string
                description: A short, human-readable summary of the problem type.
                examples:
                  - Conflict
              status:
                type: integer
                description: >-
                  The HTTP status code generated by the origin server for this
                  occurrence of the problem.
                examples:
                  - 409
              code:
                type: string
                description: >-
                  A short string indicating the error code that could be handled
                  programmatically.
                examples:
                  - BOOKING_IS_NOT_ON_SEATED_GROUP
              detail:
                type: string
                description: >-
                  A human-readable message providing more details about the
                  error.
                examples:
                  - The booking must be on the seated group status to be ended.
            required:
              - type
              - title
              - status
              - code
              - detail
    ValidationException:
      description: >-
        Validation Error — The request structure is correct, but one or more
        fields contain invalid or missing data. Example: missing required
        parameters, invalid formats, or out-of-range values.
      content:
        application/problem+json:
          schema:
            type: object
            properties:
              type:
                type: string
                description: A URI identifier that categorizes the error type.
                examples:
                  - about:blank
              title:
                type: string
                description: A short, human-readable summary of the problem type.
                examples:
                  - Validation Error
              status:
                type: integer
                description: >-
                  The HTTP status code generated by the origin server for this
                  occurrence of the problem.
                examples:
                  - 422
              code:
                type: string
                description: >-
                  A short string indicating the error code that could be handled
                  programmatically.
                examples:
                  - VALIDATION_ERROR
              detail:
                type: string
                description: >-
                  A human-readable message providing more details about the
                  error.
                examples:
                  - The request is not valid.
              errors:
                type: array
                description: >-
                  A detailed description of each parameter that failed
                  validation.
                items:
                  type: object
                  properties:
                    parameter:
                      type: string
                      description: The name of the parameter that failed validation.
                      examples:
                        - status
                    reason:
                      type: string
                      description: A human-readable description of the validation error.
                      examples:
                        - The selected status is invalid.
                  required:
                    - parameter
                    - reason
            required:
              - type
              - title
              - status
              - code
              - detail
              - errors
  securitySchemes:
    http:
      type: http
      description: >-
        All requests must include the static API Key in the Authorization header
        using the Bearer scheme.
      scheme: bearer

````