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

# Search sales reps

> Searches the CRM owners (sales reps) of the connected CRM by name or email, 20 at most. Use an `id` as `owner_id` to assign an account, or as `scope` to rank that rep's book. Salesforce needs at least 2 letters.



## OpenAPI

````yaml GET /todays-accounts/owners
openapi: 3.1.0
info:
  title: OpenAPI Lonescale
  description: A sample API for Lonescale
  license:
    name: MIT
  version: 1.0.0
servers:
  - url: https://public-api.lonescale.com
security:
  - ApiKeyAuth: []
paths:
  /todays-accounts/owners:
    get:
      description: >-
        Searches the CRM owners (sales reps) of the connected CRM by name or
        email, 20 at most. Use an `id` as `owner_id` to assign an account, or as
        `scope` to rank that rep's book. Salesforce needs at least 2 letters.
      parameters:
        - name: query
          in: query
          required: false
          schema:
            type: string
          description: A name or email fragment.
      responses:
        '200':
          description: Matching CRM owners
          content:
            application/json:
              schema:
                type: object
                properties:
                  owners:
                    type: array
                    items:
                      $ref: '#/components/schemas/TodaysAccountsOwner'
        '401':
          description: Invalid or missing authentication credentials
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/AuthError'
              example:
                message: Invalid API Key
                error: Unauthorized
                statusCode: 401
        '403':
          description: Today's accounts is not enabled for the API key's holder
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
              example:
                message: >-
                  Today's accounts is not enabled for this user: ask LoneScale
                  to turn it on.
                error: Forbidden
                statusCode: 403
        '429':
          description: 'Rate limit exceeded: 30 requests per minute, counted per API key'
components:
  schemas:
    TodaysAccountsOwner:
      type: object
      properties:
        id:
          type: string
          description: CRM owner id (HubSpot owner id, Salesforce User id).
        name:
          type: string
          nullable: true
        email:
          type: string
          nullable: true
    AuthError:
      required:
        - message
        - error
        - statusCode
      type: object
      properties:
        message:
          type: string
          example: Invalid API Key
        error:
          type: string
          example: Unauthorized
        statusCode:
          type: integer
          example: 401
    Error:
      required:
        - error
        - message
      type: object
      properties:
        error:
          type: integer
          format: int32
        message:
          type: string
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: x-api-key
      description: Provide your API key in the x-api-key header.

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.