---
title: "Get a list of contacts prioritized by their next action"
description: "GET /team_stream — Defaults to the action stream for entire account in a single list. See the action stream of account users, by providing the `user_id` param."
canonical_url: https://developer.onepagecrm.com/api/reference/team-stream/get-team_stream/
source: Markdown mirror of https://developer.onepagecrm.com/api/reference/team-stream/get-team_stream/
---

`GET /team_stream`

Defaults to the action stream for entire account in a single list. See the action stream of account users, by providing the `user_id` param.

Resource: [Team Stream](https://developer.onepagecrm.com/api/reference/team-stream/) · [API Reference](https://developer.onepagecrm.com/api/reference/)

## Request

```bash
curl "https://app.onepagecrm.com/api/v3/team_stream" \
  -u $user_id:$api_key
```

Authentication is HTTP Basic — `user_id` as username, `api_key` as password.
See https://developer.onepagecrm.com/api/authentication/.

## Query parameters

| Name | Type | Description |
| --- | --- | --- |
| `user_id` | string | Get the action stream of another user (leave blank for entire account in a single list) |
| `team` | boolean | Include contacts owned by other users |
| `search` | string | Search contacts by contact name, company name or phone number |
| `phone` | string | Search contacts by phone number |
| `url` | string | Search contacts by web address |
| `action_stream` | boolean | Only return results that are also in action stream |
| `has_actions` | boolean | Only return contacts who are owned by the logged user, and have actions for any user (can not query by `has_actions` and `has_actions_for_me` at the same time) |
| `has_actions_for_me` | boolean | Only return contacts who are owned by, and have actions for, the logged user (can not query by `has_actions` and `has_actions_for_me` at the same time) |
| `pending_deal` | boolean | Only return contacts who have a pending deal |
| `starred` | boolean | Only return contacts who are starred |
| `waiting` | boolean | Only return contacts, for whom I have a next action, of status `waiting` |
| `email` | string | Return contacts whose email matches that provided with this query param |
| `letter` | string | Return contacts whose last name begins with specified letter (or company name, if last name not present) |
| `custom_field_id` | string | Filter contacts by custom field value (combine with `custom_field_value`) |
| `custom_field_value` | string | Filter contacts by custom field value (combine with `custom_field_id`) |
| `lead_source` | string | Return contacts of a specific lead source (only use one of `lead_source` and `lead_source_id` at a time) |
| `lead_source_id` | string | Return contacts of a specific lead source (only use one of `lead_source` and `lead_source_id` at a time) |
| `status_id` | string | Return contacts of a particular status |
| `owner_id` | string | Return contacts owned by a specific user |
| `company_id` | string | Return contacts from a specific company (only use one of `company_id`, `tag` or `filter_id` at a time) |
| `tag` | string | Filter contacts by tag (only use one of `company_id`, `tag` or `filter_id` at a time) |
| `filter_id` | string | Apply filter to contact listing (only use one of `company_id`, `tag` or `filter_id` at a time) |
| `date_filter` | string | Signals which date field to be used for only returning resources, added or edited, in a specified date range (only to be used with `since` and/or `until`, not with `modified_since` or `unmodified_since`) |
| `since` | string | Specifies the start of the date range to filter resources, which have been added or edited (use with `date_filter` - date must be in format `YYYY-MM-DD` or UNIX timestamp) |
| `until` | string | Specifies the end of the date range to filter resources, which have been added or edited (use with `date_filter` - date must be in format `YYYY-MM-DD` or UNIX timestamp) |
| `modified_since` | string | Return only resources that were modified since specified time (cannot be used with `date_filter` - date must be in format `YYYY-MM-DD` or UNIX timestamp) |
| `unmodified_since` | string | Return only resources that were unmodified since specified time (cannot be used with `date_filter` - date must be in format `YYYY-MM-DD` or UNIX timestamp) |
| `sort_by` | string | Specify field by which to order the results (use in conjunction with `order`) |
| `order` | string | Specify the order (ascending or descending) of the sort of the results (use in conjunction with `sort_by`) |
| `page` | integer | Page number. Starts from 1. Default is 1. |
| `per_page` | integer | Number of records to return. Maximum 100 allowed. Default is 10. |

## Responses

### 200

OK

```json
{
  "status": 0,
  "message": "OK",
  "timestamp": 1528373119,
  "data": {
    "contacts": [
      {
        "contact": {
          "id": "5aba31ea9007ba0f570c92d4",
          "title": "Mr",
          "first_name": "Joe",
          "last_name": "Bloggs",
          "job_title": "Engineer",
          "starred": true,
          "photo_url": "https://{foo.bar}/joe-bloggs.jpg",
          "company_id": "5aba31ea9007ba0f570c92d5",
          "company_name": "Morgan's Forensic Lab",
          "urls": [
            {}
          ],
          "phones": [
            {}
          ],
          "emails": [
            {}
          ],
          "address_list": [
            {}
          ],
          "status": "Prospect",
          "status_id": "5e31e030849d781e837b6ba1",
          "tags": [
            "Java",
            "Android",
            "iOS"
          ],
          "lead_source_id": "email_web",
          "lead_source": "Email or Web",
          "background": "I met Joe Bloggs at the annual Eco Conference in Florida. Her company currently provides solar panels (along with a lot of other stuff) to the State Government of California, Nevada, Oregon, Arizona and Utah for capital building projects. Her current supplier is crazy expensive! I've asked to be able to tender for their next order.",
          "owner_id": "5aba31e99007ba0f570c92a5",
          "custom_fields": [
            {}
          ],
          "letter": "b",
          "pending_deal": true,
          "total_pendings": 999.99,
          "total_deals_count": 3,
          "company_size": 1,
          "sales_closed_for": [
            "5aba31e99007ba0f570c12f7"
          ],
          "closed_sales": [
            {}
          ],
          "google_contacts_data": {
            "account_email": "jane.doe@example.com",
            "id": "342c5b5c08d4b0b2",
            "saved_at": 1522840153
          },
          "created_at": "2018-05-16T11:52:09Z",
          "modified_at": "2018-05-16T11:52:09Z"
        },
        "next_actions": [
          {
            "id": "5aeac8789007ba56ffca92b9",
            "assignee_id": "5aaa9b009007ba08c9ebaef7",
            "contact_id": "5aba31ea9007ba0f570c92d4",
            "text": "#1 Email Jane introducing our organization",
            "status": "date_time",
            "date": "2018-05-16",
            "exact_time": 1526472000,
            "position": 1,
            "done": false,
            "done_at": "2018-05-16",
            "created_at": "2018-05-16T11:52:09Z",
            "modified_at": "2018-05-16T12:52:09Z"
          }
        ],
        "next_action": {
          "id": "5aeac8789007ba56ffca92b9",
          "assignee_id": "5aaa9b009007ba08c9ebaef7",
          "contact_id": "5aba31ea9007ba0f570c92d4",
          "text": "#1 Email Jane introducing our organization",
          "status": "date_time",
          "date": "2018-05-16",
          "exact_time": 1526472000,
          "position": 1,
          "done": false,
          "done_at": "2018-05-16",
          "created_at": "2018-05-16T11:52:09Z",
          "modified_at": "2018-05-16T12:52:09Z"
        },
        "queued_actions": [
          {
            "id": "5aeac8789007ba56ffca92b9",
            "assignee_id": "5aaa9b009007ba08c9ebaef7",
            "contact_id": "5aba31ea9007ba0f570c92d4",
            "text": "#1 Email Jane introducing our organization",
            "status": "date_time",
            "date": "2018-05-16",
            "exact_time": 1526472000,
            "position": 1,
            "done": false,
            "done_at": "2018-05-16",
            "created_at": "2018-05-16T11:52:09Z",
            "modified_at": "2018-05-16T12:52:09Z"
          }
        ],
        "next_action_conflicts": [],
        "company": {
          "id": "5aba31e99007ba0f570c92ac",
          "image": "data:image/png;base64,iVBORw...",
          "name": "Crockett & Tubbs Security",
          "description": "For all your security needs",
          "phone": "(912) 644-1771",
          "photo_url": "https://example.com/someimage.png",
          "url": "https://{foo.bar}",
          "address": {
            "address": "Unit 5, Business Innovation Centre",
            "city": "Upper Newcastle",
            "state": "Galway",
            "zip_code": "H91 Y0T0",
            "country_code": "IE"
          },
          "company_fields": [
            {}
          ],
          "syncing_status": true,
          "synced_status_id": "5aaa9b039007ba08c9ebaf0a",
          "syncing_tags": true,
          "synced_tags": [
            "Java",
            "Android",
            "iOS"
          ],
          "contacts_count": 3,
          "won_deals_count": 5,
          "total_won_amount": 999.99,
          "pending_deals_count": 1,
          "total_pending_amount": 99.99,
          "contacts": [
            {}
          ],
          "pending_deals": [
            {}
          ],
          "created_at": "2018-05-16T11:52:09Z",
          "modified_at": "2018-05-16T11:52:09Z"
        }
      }
    ],
    "total_count": 1,
    "page": 1,
    "per_page": 10,
    "max_page": 1
  }
}
```

Standard error responses: 400, 401, 403, 404, 409, 500 — shared across the API. See https://developer.onepagecrm.com/api/errors/.

## Related guides

- [Authentication](https://developer.onepagecrm.com/api/authentication/)
- [Errors](https://developer.onepagecrm.com/api/errors/)
- [Rate limits](https://developer.onepagecrm.com/api/rate-limits/)
- [Pagination](https://developer.onepagecrm.com/api/pagination/)
- [Sorting & time filters](https://developer.onepagecrm.com/api/sorting/)
