> ## 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.

# Get today's accounts

> The accounts of a CRM book worth working today, best first (10 at most). An account gets in with a LoneScale signal in the last 30 days on its domain (job change, new hire, contact sourced, hiring burst; job postings over 14 days) and no CRM activity in the last 7 days. Each account comes with the signal, the person to reach (with the email and phone already known), its owner, the last touch and a score with the lines it adds up from (`score_parts`).

This returns the last list computed for the book. `status: none` means it was never ranked: call `POST /todays-accounts/refresh`, then poll this endpoint while `status` is `pending`.

Requires Today's accounts to be enabled for the API key's holder. Rate limited to **30 requests per minute**.



## OpenAPI

````yaml GET /todays-accounts
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:
    get:
      description: >-
        The accounts of a CRM book worth working today, best first (10 at most).
        An account gets in with a LoneScale signal in the last 30 days on its
        domain (job change, new hire, contact sourced, hiring burst; job
        postings over 14 days) and no CRM activity in the last 7 days. Each
        account comes with the signal, the person to reach (with the email and
        phone already known), its owner, the last touch and a score with the
        lines it adds up from (`score_parts`).


        This returns the last list computed for the book. `status: none` means
        it was never ranked: call `POST /todays-accounts/refresh`, then poll
        this endpoint while `status` is `pending`.


        Requires Today's accounts to be enabled for the API key's holder. Rate
        limited to **30 requests per minute**.
      parameters:
        - name: scope
          in: query
          required: false
          schema:
            type: string
          description: >-
            Which CRM book to rank: omit it for the API key holder's own
            accounts (their linked CRM owner), `all` for every account with a
            domain, `unassigned` for accounts nobody owns (HubSpot only), or a
            CRM owner id from `GET /todays-accounts/owners`.
      responses:
        '200':
          description: The book's list, whatever its status
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/TodaysAccountsList'
        '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:
    TodaysAccountsList:
      type: object
      properties:
        status:
          type: string
          enum:
            - none
            - pending
            - ended
            - error
          description: '`none`: never ranked, call refresh. `pending`: ranking, poll again.'
        scope:
          type: string
          nullable: true
          description: >-
            The book: `all`, `unassigned`, `owner:<CRM owner id>`, or
            `unlinked:<user id>` when the caller has no CRM owner.
        crm:
          type: string
          nullable: true
          enum:
            - hubspot
            - salesforce
        requested_at:
          type: string
          format: date-time
          nullable: true
        generated_at:
          type: string
          format: date-time
          nullable: true
        error:
          type: string
          nullable: true
        owner_linked:
          type: boolean
          nullable: true
          description: >-
            False when the caller's own book was asked and no CRM owner matches
            their email.
        book_size:
          type: integer
          nullable: true
          description: Accounts with a domain in the book.
        accounts:
          type: array
          items:
            $ref: '#/components/schemas/TodaysAccount'
    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
    TodaysAccount:
      type: object
      properties:
        rank:
          type: integer
          example: 1
        domain:
          type: string
          example: pennylane.com
        name:
          type: string
          nullable: true
        location:
          type: string
          nullable: true
          description: City and country from the CRM address; `null` when the CRM has none.
          example: Paris, France
        industry:
          type: string
          nullable: true
          description: The CRM industry; `null` when the CRM has none.
        angle:
          type: string
          nullable: true
          description: >-
            Why this person, why now: one line written at list time in the
            account's language. `null` when it could not be written.
          example: 'Nouveau VP Sales depuis 8 jours : il choisit ses outils maintenant.'
        crm_id:
          type: string
          nullable: true
          description: HubSpot company id or Salesforce Account id.
        owner:
          type: object
          nullable: true
          description: '`null` when unassigned.'
          properties:
            id:
              type: string
            name:
              type: string
              nullable: true
        signal:
          type: object
          properties:
            type:
              type: string
              enum:
                - JOB_CHANGE
                - NEW_HIRE
                - JOB_POSTING
                - CONTACT_SOURCING
                - HIRING
            reason:
              type: string
              example: Charlotte C. just moved here as Team Lead BDR
            detected_at:
              type: string
              format: date-time
              nullable: true
        person:
          type: object
          nullable: true
          description: >-
            The one to reach first (`people[0]`); `null` when no contact is
            known.
          properties:
            role:
              type: string
              nullable: true
              enum:
                - DECISION_MAKER
                - CHAMPION
                - USER
                - null
              description: >-
                Who they are to the purchase, read off the job title; `null`
                when unclear.
            full_name:
              type: string
              nullable: true
            job_title:
              type: string
              nullable: true
            linkedin_url:
              type: string
              nullable: true
            crm_id:
              type: string
              nullable: true
              description: CRM contact id, when the person is in the CRM.
            email:
              type: string
              nullable: true
            phone:
              type: string
              nullable: true
        people:
          type: array
          description: >-
            The buying committee, the signal's person first: up to 3, one per
            role when LoneScale or your CRM knows them (more after
            `find-people`). Older lists carry `[person]`.
          items:
            $ref: '#/components/schemas/TodaysAccountPerson'
        last_activity_at:
          type: string
          format: date-time
          nullable: true
          description: Last sales activity on the account; `null` when never contacted.
        open_deal:
          type: boolean
        looks_like_your_wins:
          type: boolean
          description: Industry and size typical of your recent closed-won deals.
        former_customer:
          type: boolean
          description: >-
            A deal won more than 18 months ago: a win-back. Current customers (a
            deal won in the last 18 months, or the CRM's customer stage) are
            never listed.
        score:
          type: number
          example: 10.4
        score_parts:
          type: array
          description: How the score adds up.
          items:
            type: object
            properties:
              label:
                type: string
                example: Job change, 10 d old
              points:
                type: number
                example: 6.1
    TodaysAccountPerson:
      type: object
      description: A person to reach at a listed account.
      properties:
        role:
          type: string
          nullable: true
          enum:
            - DECISION_MAKER
            - CHAMPION
            - USER
            - null
          description: >-
            Who they are to the purchase, read off the job title; `null` when
            unclear.
        full_name:
          type: string
          nullable: true
        job_title:
          type: string
          nullable: true
        linkedin_url:
          type: string
          nullable: true
        crm_id:
          type: string
          nullable: true
          description: CRM contact id, when the person is in the CRM.
        email:
          type: string
          nullable: true
        phone:
          type: string
          nullable: true
  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.