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

# Retrieve Call Logs

> Retrieves a paginated list of call logs with filtering and sorting support.

Retrieves a paginated list of call logs from the system. Use this endpoint to access call logs with metadata, such as timestamps, dispositions, and contact information.

### Query Parameters

#### Pagination & Sorting

* **limit** (*optional*, number): Number of items per page (default: 10, max: 100)
* **page** (*optional*, number): The current page number to retrieve (default: 1)
* **sort** (*optional*, string): Sort field with optional `-` prefix for descending order (default: `-createdAt`)

#### Filters

All filters are passed as query parameters with the `filters[field]` format.

##### Date Filters

* **filters\[start\_date]** (*optional*, ISO 8601 date): Start of date range
* **filters\[end\_date]** (*optional*, ISO 8601 date): End of date range

##### Call Properties

* **filters\[outcome]** (*optional*, string): Filter by call outcome
  * `answered` - Call was answered
  * `no-answer` - Call was not answered
  * `cancelled` - Call was cancelled
* **filters\[direction]** (*optional*, string): Filter by call direction
  * `inbound` - Incoming calls
  * `outbound` - Outgoing calls
* **filters\[min\_duration]** (*optional*, number): Minimum call duration in seconds
* **filters\[max\_duration]** (*optional*, number): Maximum call duration in seconds
* **filters\[has\_recording]** (*optional*, boolean): Filter by recording availability
  * `true` - Only calls with recordings
  * `false` - Only calls without recordings
* **filters\[answered\_by]** (*optional*, string): Filter by who answered
  * `human` - Answered by a person
  * `machine_start` - Answered by voicemail/machine
* **filters\[is\_completed]** (*optional*, boolean): Filter by completion status

##### Disposition Filters

* **filters\[disposition\_ids]** (*optional*, number\[]): Filter by disposition IDs. See [Get Dispositions](/api-reference/endpoint/get-dispositions) for available IDs.
* **filters\[exclude\_negative\_dispositions]** (*optional*, boolean): When `true`, only returns calls with positive dispositions (Meeting Set, Referral, Callback Later, etc.)

##### Entity Filters

* **filters\[user\_ids]** (*optional*, string\[]): Filter by user IDs
* **filters\[contact\_list\_ids]** (*optional*, string\[]): Filter by contact list IDs
* **filters\[contact\_ids]** (*optional*, string\[]): Filter by contact IDs (the contact's `_id`)
* **filters\[crm\_ids]** (*optional*, string\[]): Filter by CRM IDs (the contact's `crm_id`)
* **filters\[sequences]** (*optional*, string\[]): Filter by sequence IDs. See [Get Sequences](/api-reference/endpoint/get-sequences) to discover available sequences.

##### Phone Number Filters

* **filters\[from]** (*optional*, string\[]): Filter by caller phone numbers
* **filters\[to]** (*optional*, string\[]): Filter by called phone numbers

##### Search

* **filters\[search]** (*optional*, string): Full-text search across the contact's name, company, account, title and email, the to/from and contact phone numbers, and the call notes, summary and disposition/call purpose/call sentiment names. Call transcripts are not searched.

### Example Requests

**Basic request with date filter:**

```
GET /v1/call-log?filters[start_date]=2024-01-01&filters[end_date]=2024-01-31
```

**Filter by outcome and minimum duration:**

```
GET /v1/call-log?filters[outcome]=answered&filters[min_duration]=60
```

**Filter by disposition and recording:**

```
GET /v1/call-log?filters[disposition_ids][]=1&filters[disposition_ids][]=4&filters[has_recording]=true
```

**Search with multiple filters:**

```
GET /v1/call-log?filters[search]=Acme&filters[direction]=outbound&page=1&limit=50
```

**Filter by sequence:**

```
GET /v1/call-log?filters[sequences][]=seq_12345&filters[sequences][]=seq_67890
```

**Filter by CRM ID:**

```
GET /v1/call-log?filters[crm_ids][]=00Q5f000001abcXYZ
```

### Response

Returns a JSON object containing the list of call logs with pagination metadata.

<Note>
  Each call log includes both `contact_list` and `source`. `contact_list` is the **dialing-queue** list the call was placed from (its `_id` is the queue id). `source` identifies the **original source list** the call came from — for CSV lists, `source.id` is the CSV list id (which differs from the queue id). `source.id`/`source.name` are `null` for non-CSV lists. `contact_list` is unchanged and remains fully backward compatible.
</Note>

```json theme={null}
{
  "data": [
    {
      "_id": "507f1f77bcf86cd799439011",
      "call_id": "call_abc123",
      "outcome": "answered",
      "direction": "outbound",
      "answered_by": "human",
      "duration": 180,
      "to": "+1234567890",
      "from": "+1987654321",
      "disposition": {
        "internal_id": 1,
        "external_id": "meeting_set",
        "external_name": "Meeting Set"
      },
      "contact": {
        "first_name": "John",
        "last_name": "Doe",
        "company": "Acme Corp",
        "email": "john@acme.com",
        "title": "VP of Sales"
      },
      "contact_list": {
        "_id": "507f1f77bcf86cd799439022",
        "name": "Q1 Prospects"
      },
      "source": {
        "type": "csv",
        "id": "507f1f77bcf86cd799439099",
        "name": "Q1 Prospects"
      },
      "user": {
        "_id": "507f1f77bcf86cd799439033",
        "first_name": "Jane",
        "last_name": "Smith",
        "email": "jane@company.com"
      },
      "recording_url": "https://recordings.example.com/call_abc123.mp3",
      "notes": "Great conversation, follow up next week",
      "is_completed": true,
      "started_at": "2024-01-15T14:30:00.000Z",
      "ended_at": "2024-01-15T14:33:00.000Z",
      "createdAt": "2024-01-15T14:33:00.000Z",
      "updatedAt": "2024-01-15T14:33:00.000Z"
    }
  ],
  "pagination": {
    "total": 150,
    "page": 1,
    "limit": 10,
    "pages": 15
  }
}
```

### Response Fields

| Field           | Type    | Description                                                                                                                                                                                                                                                                                                   |
| --------------- | ------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `_id`           | string  | Unique identifier                                                                                                                                                                                                                                                                                             |
| `call_id`       | string  | Unique call identifier                                                                                                                                                                                                                                                                                        |
| `outcome`       | string  | Call outcome (answered, no-answer, cancelled)                                                                                                                                                                                                                                                                 |
| `direction`     | string  | Call direction (inbound, outbound)                                                                                                                                                                                                                                                                            |
| `answered_by`   | string  | Who answered (human, machine\_start)                                                                                                                                                                                                                                                                          |
| `duration`      | number  | Call duration in seconds                                                                                                                                                                                                                                                                                      |
| `to`            | string  | Called phone number                                                                                                                                                                                                                                                                                           |
| `from`          | string  | Caller phone number                                                                                                                                                                                                                                                                                           |
| `disposition`   | object  | Disposition details with internal\_id                                                                                                                                                                                                                                                                         |
| `contact`       | object  | Contact information                                                                                                                                                                                                                                                                                           |
| `contact_list`  | object  | The dialing-queue list (`ContactList`) the call was placed from; its `_id` is the queue id. Unchanged for backward compatibility.                                                                                                                                                                             |
| `source`        | object  | The original source list the call came from. Additive; leaves `contact_list` untouched. Fields: `type` (integration source, e.g. `csv`/`hubspot`), `id` (the original source list id — the CSV list id for CSV lists, `null` for non-CSV), `name` (source list name). `id`/`name` are `null` when unresolved. |
| `user`          | object  | User who made/received the call                                                                                                                                                                                                                                                                               |
| `recording_url` | string  | URL to call recording (if available)                                                                                                                                                                                                                                                                          |
| `notes`         | string  | Call notes                                                                                                                                                                                                                                                                                                    |
| `transcription` | string  | Call transcription (if available)                                                                                                                                                                                                                                                                             |
| `summary`       | string  | AI-generated call summary (if available)                                                                                                                                                                                                                                                                      |
| `is_completed`  | boolean | Whether the call is completed                                                                                                                                                                                                                                                                                 |
| `started_at`    | date    | Call start time                                                                                                                                                                                                                                                                                               |
| `ended_at`      | date    | Call end time                                                                                                                                                                                                                                                                                                 |
| `createdAt`     | date    | Record creation time                                                                                                                                                                                                                                                                                          |
| `updatedAt`     | date    | Record last update time                                                                                                                                                                                                                                                                                       |


## OpenAPI

````yaml GET /v1/call-log
openapi: 3.0.1
info:
  title: Salesfinity API
  description: API documentation for Salesfinity platform
  license:
    name: MIT
  version: 1.0.0
servers:
  - url: https://client-api.salesfinity.co
security:
  - ApiKeyAuth: []
paths:
  /v1/call-log:
    get:
      tags:
        - Call Logs
      description: >-
        Retrieves a paginated list of call logs with filtering and sorting
        support.
      operationId: get-call-logs
      parameters:
        - name: limit
          in: query
          required: false
          schema:
            type: integer
            minimum: 1
            maximum: 100
            default: 10
          description: 'Number of items per page (default: 10, max: 100)'
        - name: page
          in: query
          required: false
          schema:
            type: integer
            minimum: 1
            default: 1
          description: 'The current page number (default: 1)'
        - name: sort
          in: query
          required: false
          schema:
            type: string
          description: >-
            Sort field with optional `-` prefix for descending order. Default:
            `-createdAt`
        - name: filters[start_date]
          in: query
          required: false
          schema:
            type: string
            format: date-time
          description: Start of date range (ISO 8601)
        - name: filters[end_date]
          in: query
          required: false
          schema:
            type: string
            format: date-time
          description: End of date range (ISO 8601)
        - name: filters[outcome]
          in: query
          required: false
          schema:
            type: string
            enum:
              - answered
              - no-answer
              - cancelled
          description: Filter by call outcome
        - name: filters[direction]
          in: query
          required: false
          schema:
            type: string
            enum:
              - inbound
              - outbound
          description: Filter by call direction
        - name: filters[min_duration]
          in: query
          required: false
          schema:
            type: number
            minimum: 0
          description: Minimum call duration in seconds
        - name: filters[max_duration]
          in: query
          required: false
          schema:
            type: number
            minimum: 0
          description: Maximum call duration in seconds
        - name: filters[has_recording]
          in: query
          required: false
          schema:
            type: boolean
          description: Filter by recording availability
        - name: filters[answered_by]
          in: query
          required: false
          schema:
            type: string
            enum:
              - human
              - machine_start
          description: Filter by who answered the call
        - name: filters[is_completed]
          in: query
          required: false
          schema:
            type: boolean
          description: Filter by completion status
        - name: filters[disposition_ids]
          in: query
          required: false
          schema:
            type: array
            items:
              type: integer
          description: Filter by disposition IDs. See Get Dispositions for available IDs.
        - name: filters[exclude_negative_dispositions]
          in: query
          required: false
          schema:
            type: boolean
          description: >-
            When true, only returns calls with positive dispositions (Meeting
            Set, Referral, Callback Later, etc.)
        - name: filters[user_ids]
          in: query
          required: false
          schema:
            type: array
            items:
              type: string
          description: Filter by user IDs
        - name: filters[contact_list_ids]
          in: query
          required: false
          schema:
            type: array
            items:
              type: string
          description: Filter by contact list IDs
        - name: filters[contact_ids]
          in: query
          required: false
          schema:
            type: array
            items:
              type: string
          description: Filter by contact IDs (the contact's _id)
        - name: filters[crm_ids]
          in: query
          required: false
          schema:
            type: array
            items:
              type: string
          description: Filter by CRM IDs (the contact's crm_id)
        - name: filters[sequences]
          in: query
          required: false
          schema:
            type: array
            items:
              type: string
          description: >-
            Filter by sequence IDs. See Get Sequences to discover available
            sequences.
        - name: filters[from]
          in: query
          required: false
          schema:
            type: array
            items:
              type: string
          description: Filter by caller phone numbers
        - name: filters[to]
          in: query
          required: false
          schema:
            type: array
            items:
              type: string
          description: Filter by called phone numbers
        - name: filters[search]
          in: query
          required: false
          schema:
            type: string
          description: >-
            Full-text search across the contact's name, company, account, title
            and email, the to/from and contact phone numbers, and the call
            notes, summary and disposition/call purpose/call sentiment names.
            Call transcripts are not searched.
      responses:
        '200':
          description: A paginated list of call logs with metadata.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/CallLogListResponse'
components:
  schemas:
    CallLogListResponse:
      type: object
      properties:
        data:
          type: array
          items:
            $ref: '#/components/schemas/CallLogDTO'
        pagination:
          type: object
          properties:
            total:
              type: integer
            page:
              type: integer
            limit:
              type: integer
            pages:
              type: integer
    CallLogDTO:
      type: object
      properties:
        _id:
          type: string
        call_id:
          type: string
        outcome:
          type: string
          enum:
            - answered
            - no-answer
            - cancelled
        direction:
          type: string
          enum:
            - inbound
            - outbound
        answered_by:
          type: string
          enum:
            - human
            - machine_start
        duration:
          type: number
          description: Call duration in seconds
        to:
          type: string
          description: Called phone number
        from:
          type: string
          description: Caller phone number
        disposition:
          type: object
          properties:
            internal_id:
              type: integer
            external_id:
              type: string
            external_name:
              type: string
        contact:
          type: object
        contact_list:
          type: object
          description: >-
            The dialing-queue list (ContactList) the call was placed from. Its
            _id is the queue id. Unchanged for backward compatibility.
        source:
          type: object
          description: >-
            The original source list the call came from. Additive; contact_list
            is left untouched.
          properties:
            type:
              type: string
              description: >-
                Integration source type (e.g. csv, hubspot, salesforce). Null if
                unknown.
              nullable: true
            id:
              type: string
              description: >-
                The original source list id. For CSV lists this is the CSV list
                id (CsvContacts._id). Null for non-CSV lists (no external list
                id is stored).
              nullable: true
            name:
              type: string
              description: The source list name. Null when unresolved.
              nullable: true
        user:
          $ref: '#/components/schemas/UserDTO'
        recording_url:
          type: string
        notes:
          type: string
        transcription:
          type: string
        summary:
          type: string
        is_completed:
          type: boolean
        started_at:
          type: string
          format: date-time
        ended_at:
          type: string
          format: date-time
        createdAt:
          type: string
          format: date-time
        updatedAt:
          type: string
          format: date-time
    UserDTO:
      type: object
      properties:
        _id:
          type: string
        email:
          type: string
        first_name:
          type: string
        last_name:
          type: string
      required:
        - _id
        - email
        - first_name
        - last_name
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: x-api-key

````