# Playvox

> Manage people, teams and custom interactions in Playvox and follow quality evaluations, disputes and coaching.

App · 26 actions. Web page: https://docs.lodol.com/docs/integrations/playvox

## Actions

### Add message to interaction

Add a customer message, agent reply or internal note to an interaction.

**Inputs**

- Interaction (`id`, text, required): The interaction's Playvox ID, from List interactions or Create interaction.
- Message (`body_text`, text, required): What was said.
- From (`type`, text, required): Who wrote it. One of: `customer_comment` (Customer), `agent_comment` (Agent), `internal_note` (Internal note).
- Author (`author_id`, text): The author's email or username in Playvox.
- Sent at (`added_at`, date and time): When it was said. Leave empty for now.

**Outputs**

- `data` (object): The response from Playvox.

**Example output**

```json
{
  "data": {
    "result": {
      "_id": "5dd0dcd5c5cf53a30fd89c05",
      "added_at": "2019-11-16T20:00:10.000000Z",
      "author_id": "lina@playvox.com",
      "body": "Hi, I need a refund for my last payment.",
      "created_at": "2019-11-17T05:38:29.931000Z",
      "integration_id": "5dcf04ba195b8c23cff25128",
      "interaction_id": "5dcf05378b2ca38f3e158926",
      "type": "customer_comment",
      "updated_at": "2019-11-17T05:42:24.611000Z"
    },
    "success": true
  }
}
```

### Add user to team

Add a person to a team.

**Inputs**

- Team (`team`, text, required): The team. Pick one, or use a team ID from List teams.
- User (`id`, text, required): The person to add. Pick one, or use a user ID from List users.

**Outputs**

- `data` (object): The response from Playvox.

**Example output**

```json
{
  "data": {
    "result": {
      "_id": "5c2e2b262bec120001d28f91",
      "created_at": "2019-01-03T15:32:54Z",
      "created_by": "5c2d2bcc2bec120001d291fd",
      "default": false,
      "description": "Freelancers Colombia",
      "name": "My new team",
      "site_id": "57cf3965e4b39f3654e0e297",
      "status": "active",
      "team_leader_id": [
        "5c2d2bcc2bec120001d291fd"
      ],
      "total_users": 1,
      "updated_at": "2019-01-03T15:45:52Z",
      "users": [
        "5da87ec92ada421e89ff41e1"
      ]
    },
    "success": true
  }
}
```

### Create integration

Create a custom integration to send interactions from your own systems.

**Inputs**

- Name (`name`, text, required): The integration's name.
- Description (`description`, text): What it brings in.
- Keep data for (`data_storage_minutes`, number): How many minutes to keep interactions before deleting them, up to 129600 (90 days). From 1 to 129600.
- Keep evaluated interactions (`delete_only_non_audited_interactions`, true/false): Turn on to delete only interactions nobody has evaluated when they expire.

**Outputs**

- `data` (object): The response from Playvox.

**Example output**

```json
{
  "data": {
    "result": {
      "_id": "5dd00cd4ac0b7cf615c1fc88",
      "created_at": "2019-11-16T14:51:00.429000Z",
      "created_by": "5c9e97ca2b938500012eaefa",
      "description": "Chats from our in-house tool",
      "metadata": [
        {
          "_id": "5dcf04be14f8893b3b949ace",
          "allowed": [
            "urgent",
            "high",
            "medium",
            "low"
          ],
          "available_in": [
            "filters",
            "display"
          ],
          "field_id": "priority",
          "required": true,
          "type": "string"
        }
      ],
      "name": "My integration",
      "settings": {
        "data_storage_minutes": 129600,
        "delete_only_non_audited_interactions": false
      },
      "status": "active",
      "updated_at": "2019-11-16T14:53:43.084000Z"
    },
    "success": true
  }
}
```

### Create interaction

Send a conversation from your own system to a custom integration so it can be evaluated.

**Inputs**

- Integration (`id`, text, required): The integration. Pick one, or use an integration ID from List integrations.
- Your ID (`interaction_id`, text, required): The conversation's ID in your own system, up to 68 characters.
- Agent (`assignee_id`, text, required): The agent's email or username in Playvox.
- Other agents (`collaborators`, list): Emails or usernames of other agents who worked on it.
- Date (`interaction_date`, date and time): When the conversation happened.

**Outputs**

- `data` (object): The response from Playvox.

**Example output**

```json
{
  "data": {
    "result": {
      "_id": "5dd0d8c37ba057774c0e548f",
      "assignee_id": "jhon@playvox.com",
      "collaborators": [
        "lina@playvox.com"
      ],
      "created_at": "2019-11-17T05:21:07.527000Z",
      "created_by": "5c9e97ca2b938500012eaefa",
      "integration_id": "5dcf04ba195b8c23cff25128",
      "interaction_date": "2019-11-16T20:00:10.000000Z",
      "interaction_id": "456",
      "updated_at": "2019-11-17T05:28:44.071000Z"
    },
    "success": true
  }
}
```

### Create team

Create a team with its team leaders.

**Inputs**

- Name (`name`, text, required): The team's name.
- Team leaders (`team_leader_id`, list, required): The team leaders. Use user IDs from List users.
- Description (`description`, text): What the team is.
- Members (`users`, list): The members. Use user IDs from List users.

**Outputs**

- `data` (object): The response from Playvox.

**Example output**

```json
{
  "data": {
    "result": {
      "_id": "5c2e2b262bec120001d28f91",
      "created_at": "2019-01-03T15:32:54Z",
      "created_by": "5c2d2bcc2bec120001d291fd",
      "default": false,
      "description": "Freelancers Colombia",
      "name": "My new team",
      "site_id": "57cf3965e4b39f3654e0e297",
      "status": "active",
      "team_leader_id": [
        "5c2d2bcc2bec120001d291fd"
      ],
      "total_users": 1,
      "updated_at": "2019-01-03T15:45:52Z",
      "users": [
        "5da87ec92ada421e89ff41e1"
      ]
    },
    "success": true
  }
}
```

### Create user

Add a person to Playvox.

**Inputs**

- First name (`name`, text, required): Their first name.
- Last name (`last_name`, text, required): Their last name.
- Username (`username`, text, required): The username they sign in with.
- Email (`email`, text, required): Their email address.
- Password (`password`, text): A password of at least 10 characters with a number, a capital and a lower case letter. Leave empty to let them set one.
- Roles (`roles`, list): The roles to give them. Use role IDs from List roles.

**Outputs**

- `data` (object): The response from Playvox.

**Example output**

```json
{
  "data": {
    "result": {
      "_id": "5ba82a54e4b39f481e96f168",
      "created_at": "2018-09-24T00:05:40Z",
      "created_by": "9asd8a8f7as87vcav787s8io",
      "email": "johndoe@playvox.com",
      "lang": "es_LA",
      "last_name": "Doe",
      "name": "John",
      "roles": [
        "7asd8a8f7as87vcav787s8io"
      ],
      "site_id": "8asd8a8f7as87vcav787s8io",
      "status": "active",
      "type": "analyst",
      "updated_at": "2018-09-24T00:17:36Z",
      "username": "johndoe@playvox.com"
    },
    "success": true
  }
}
```

### Delete integration

Delete a custom integration.

**Inputs**

- Integration (`id`, text, required): The integration. Pick one, or use an integration ID from List integrations.

**Outputs**

- `data` (object): The response from Playvox.

**Example output**

```json
{
  "data": {
    "success": true
  }
}
```

### Delete interaction

Delete an interaction from a custom integration.

**Inputs**

- Integration (`id`, text, required): The integration. Pick one, or use an integration ID from List integrations.
- Interaction (`interaction_id`, text, required): The interaction's Playvox ID, from List interactions or Create interaction.

**Outputs**

- `data` (object): The response from Playvox.

**Example output**

```json
{
  "data": {
    "success": true
  }
}
```

### Delete team

Delete a team.

**Inputs**

- Team (`team`, text, required): The team. Pick one, or use a team ID from List teams.

**Outputs**

- `data` (object): The response from Playvox.

**Example output**

```json
{
  "data": {
    "result": {
      "_id": "5c2e2b262bec120001d28f91",
      "created_at": "2019-01-03T15:32:54Z",
      "created_by": "5c2d2bcc2bec120001d291fd",
      "default": false,
      "description": "Freelancers Colombia",
      "name": "My new team",
      "site_id": "57cf3965e4b39f3654e0e297",
      "status": "active",
      "team_leader_id": [
        "5c2d2bcc2bec120001d291fd"
      ],
      "total_users": 1,
      "updated_at": "2019-01-03T15:45:52Z",
      "users": [
        "5da87ec92ada421e89ff41e1"
      ]
    },
    "success": true
  }
}
```

### List campaigns

List performance campaigns and their KPIs.

**Inputs**

- Filter (`query`, text): Only campaigns matching this Playvox filter, written as JSON, such as {"status": "active"}.
- Include related records (`include`, text): Set to Everything to add the related people, teams and other records to each result. One of: `all` (Everything).
- Fields (`fields`, list): Only return these fields of each record. Leave empty for every field.
- Sort by (`sort`, text): Sort by these fields, comma-separated. Put - before a field for newest or largest first, such as -created_at.
- Page (`page`, number): Which page to read, starting at 1. At least 1.
- Page size (`per_page`, number): How many records a page holds, up to 100. Playvox's default is 12. From 1 to 100.

**Outputs**

- `data` (object): The response from Playvox.

**Example output**

```json
{
  "data": {
    "count": 1,
    "next_page": 2,
    "result": [
      {
        "_id": "5b3b6d29e4b39f776c201aed",
        "created_at": "2018-07-03T12:33:45Z",
        "is_published": true,
        "kpis": [
          {
            "_id": "5b3b6d9ee4b39f5ec757e399",
            "name": "CSAT",
            "threshold_direction": "up",
            "threshold_value": 0,
            "weight": 100
          }
        ],
        "latest_entry": 1536239280,
        "name": "Q3 support goals",
        "status": "active",
        "team_id": "59356261e4b39f52041a6387",
        "team_leader_id": [
          "4f3a5edcaeac3c0f0000000e"
        ],
        "updated_at": "2018-09-06T13:08:00Z",
        "users": [
          "5da88070d25eec7e7072123e"
        ]
      }
    ],
    "success": true
  }
}
```

### List coachings

List coaching sessions between coaches and agents.

**Inputs**

- Filter (`query`, text): Only coachings matching this Playvox filter, written as JSON, such as {"status": "active"}.
- Include related records (`include`, text): Set to Everything to add the related people, teams and other records to each result. One of: `all` (Everything).
- Fields (`fields`, list): Only return these fields of each record. Leave empty for every field.
- Sort by (`sort`, text): Sort by these fields, comma-separated. Put - before a field for newest or largest first, such as -created_at.
- Page (`page`, number): Which page to read, starting at 1. At least 1.
- Page size (`per_page`, number): How many records a page holds, up to 100. Playvox's default is 12. From 1 to 100.

**Outputs**

- `data` (object): The response from Playvox.

**Example output**

```json
{
  "data": {
    "count": 1,
    "next_page": 2,
    "result": [
      {
        "_id": "5fa45ef683e6ff5012ad05b6",
        "achieved": false,
        "coach_id": [
          "5f2b23122e798880dd12b6af"
        ],
        "created_at": "2020-11-04T20:22:14Z",
        "entity_id": "5e6bed812e34fd000158fb6b",
        "entity_type": "quality",
        "evaluation_ids": [
          "5a5f578fe4b39f571c80f156"
        ],
        "feedback": "<p>Great feedback</p>",
        "follow_up": "2020-11-13T23:59:59Z",
        "sequence": 12,
        "status": "active",
        "team_ids": [
          "5d9e437a85b869000108811c"
        ],
        "trainee_id": "5e344b51fa112e00019b36ea",
        "updated_at": "2020-11-18T13:09:58Z"
      }
    ],
    "success": true
  }
}
```

### List disputes

List disputes agents raised about their evaluations.

**Inputs**

- Filter (`query`, text): Only disputes matching this Playvox filter, written as JSON, such as {"status": "pending"}.
- Fields (`fields`, list): Only return these fields of each record. Leave empty for every field.
- Sort by (`sort`, text): Sort by these fields, comma-separated. Put - before a field for newest or largest first, such as -created_at.
- Page (`page`, number): Which page to read, starting at 1. At least 1.
- Page size (`per_page`, number): How many records a page holds, up to 100. Playvox's default is 12. From 1 to 100.

**Outputs**

- `data` (object): The response from Playvox.

**Example output**

```json
{
  "data": {
    "count": 1,
    "next_page": 2,
    "result": [
      {
        "_id": "5fe1309ab14818cab82b8923",
        "arbitrator_id": "5fbd6165caeb3ecd9643438b",
        "closed_at": "2020-12-21T23:34:42Z",
        "created_at": "2020-12-18T23:33:19Z",
        "custom_fields": {
          "agent_id": "5fc54316d7097320a1e6d240",
          "scorecard_id": "5fe12cdab14818cab92b3746",
          "team_id": "5fc50f94d7097321a0e6d223"
        },
        "entity_id": "5fe12dd2b14818cab92b385d",
        "entity_type": "scorecard_answer",
        "previous_score": 90.5,
        "requester_id": "5fc54316d7097320a1e6d240",
        "resolution_for": "requester",
        "resolved_by": "arbitrator",
        "responsible_id": "5e975fc77994bc17ab6f89a9",
        "score": 96.83544,
        "started_at": "2020-12-18T23:33:19Z",
        "status": "completed",
        "total_reopens": 0,
        "type": "quality",
        "updated_at": "2020-12-21T23:34:42Z"
      }
    ],
    "success": true
  }
}
```

### List evaluations

List quality evaluations of agents, filtered and sorted as you choose.

**Inputs**

- Filter (`query`, text): Only evaluations matching this Playvox filter, written as JSON, such as {"agent_id": "5ed91e768e623ccb88252f99"}.
- Include related records (`include`, text): Set to Everything to add the related people, teams and other records to each result. One of: `all` (Everything).
- Fields (`fields`, list): Only return these fields of each record. Leave empty for every field.
- Sort by (`sort`, text): Sort by these fields, comma-separated. Put - before a field for newest or largest first, such as -created_at.
- Page (`page`, number): Which page to read, starting at 1. At least 1.
- Page size (`per_page`, number): How many records a page holds, up to 100. Playvox's default is 12. From 1 to 100.

**Outputs**

- `data` (object): The response from Playvox.

**Example output**

```json
{
  "data": {
    "count": 1,
    "next_page": 2,
    "result": [
      {
        "_id": "5a5f578fe4b39f571c80f156",
        "agent_agree": "2020-06-25T04:42:34Z",
        "agent_id": "57fb949ae4b39f7b8786384d",
        "calibration_id": "58b58062e4b39f2fa37adc9f",
        "created_at": "2018-01-17T14:02:55Z",
        "date_created": "2018-01-17T14:02:55Z",
        "feedback": "<p>Great call</p>",
        "interaction_id": "5dcf05378b2ca38f3e158926",
        "monitor_id": "5a021083e4b39f13a94fa06a",
        "passed": true,
        "reference": "https://app.hubspot.com/contacts/576554/deal/246702482/",
        "score": 100.0,
        "score_avg": 100.0,
        "scorecard_id": "591461b3e911792fb0e29612",
        "sections": [
          {
            "_id": "58b58062e4b39f2fa37adca2",
            "answers": [
              {
                "answer_id": "58b58062e4b39f2fa37adc9f",
                "comment": "Good opening",
                "question_id": "58b58062e4b39f2fa37adca1",
                "value": 25.0
              }
            ],
            "comment": "175 agents",
            "passed": true,
            "score": 25.0
          }
        ],
        "sequence": 350,
        "status": "active",
        "team_id": "57c590bce91179663c1dcc0a",
        "total_errors": 0,
        "updated_at": "2018-01-17T14:02:55Z"
      }
    ],
    "success": true
  }
}
```

### List integrations

List the custom integrations that bring your own interactions into Playvox.

**Inputs**: None.

**Outputs**

- `data` (object): The response from Playvox.

**Example output**

```json
{
  "data": {
    "count": 1,
    "result": [
      {
        "_id": "5dd00cd4ac0b7cf615c1fc88",
        "created_at": "2019-11-16T14:51:00.429000Z",
        "created_by": "5c9e97ca2b938500012eaefa",
        "description": "Chats from our in-house tool",
        "metadata": [
          {
            "_id": "5dcf04be14f8893b3b949ace",
            "allowed": [
              "urgent",
              "high",
              "medium",
              "low"
            ],
            "available_in": [
              "filters",
              "display"
            ],
            "field_id": "priority",
            "required": true,
            "type": "string"
          }
        ],
        "name": "My integration",
        "settings": {
          "data_storage_minutes": 129600,
          "delete_only_non_audited_interactions": false
        },
        "status": "active",
        "updated_at": "2019-11-16T14:53:43.084000Z"
      }
    ]
  }
}
```

### List interaction messages

List the messages and notes of an interaction.

**Inputs**

- Interaction (`id`, text, required): The interaction's Playvox ID, from List interactions or Create interaction.

**Outputs**

- `data` (object): The response from Playvox.

**Example output**

```json
{
  "data": {
    "count": 1,
    "result": [
      {
        "_id": "5dd0dcd5c5cf53a30fd89c05",
        "added_at": "2019-11-16T20:00:10.000000Z",
        "author_id": "lina@playvox.com",
        "body": "Hi, I need a refund for my last payment.",
        "created_at": "2019-11-17T05:38:29.931000Z",
        "integration_id": "5dcf04ba195b8c23cff25128",
        "interaction_id": "5dcf05378b2ca38f3e158926",
        "type": "customer_comment",
        "updated_at": "2019-11-17T05:42:24.611000Z"
      }
    ]
  }
}
```

### List interactions

List the interactions sent to a custom integration.

**Inputs**

- Integration (`id`, text, required): The integration. Pick one, or use an integration ID from List integrations.

**Outputs**

- `data` (object): The response from Playvox.

**Example output**

```json
{
  "data": {
    "count": 1,
    "result": [
      {
        "_id": "5dd0d8c37ba057774c0e548f",
        "assignee_id": "jhon@playvox.com",
        "collaborators": [
          "lina@playvox.com"
        ],
        "created_at": "2019-11-17T05:21:07.527000Z",
        "created_by": "5c9e97ca2b938500012eaefa",
        "integration_id": "5dcf04ba195b8c23cff25128",
        "interaction_date": "2019-11-16T20:00:10.000000Z",
        "interaction_id": "456",
        "updated_at": "2019-11-17T05:28:44.071000Z"
      }
    ]
  }
}
```

### List roles

List the roles people can have in Playvox.

**Inputs**

- Filter (`query`, text): Only roles matching this Playvox filter, written as JSON, such as {"default": false}.
- Include related records (`include`, text): Set to Everything to add the related people, teams and other records to each result. One of: `all` (Everything).
- Fields (`fields`, list): Only return these fields of each record. Leave empty for every field.
- Sort by (`sort`, text): Sort by these fields, comma-separated. Put - before a field for newest or largest first, such as -created_at.
- Page (`page`, number): Which page to read, starting at 1. At least 1.
- Page size (`per_page`, number): How many records a page holds, up to 100. Playvox's default is 12. From 1 to 100.

**Outputs**

- `data` (object): The response from Playvox.

**Example output**

```json
{
  "data": {
    "count": 1,
    "next_page": 2,
    "result": [
      {
        "_id": "5e94cd6ea865ba51fe844f9a",
        "code": "role-19",
        "created_at": "2020-04-13T20:37:02Z",
        "default": false,
        "name": "Role 19",
        "read": [
          "quality_scorecards_all_data"
        ],
        "role_inherit": "admin",
        "updated_at": "2020-04-13T20:37:02Z",
        "write": [
          "learning_settings_general"
        ]
      }
    ],
    "success": true
  }
}
```

### List scorecards

List the quality scorecards used to evaluate agents.

**Inputs**

- Filter (`query`, text): Only scorecards matching this Playvox filter, written as JSON, such as {"status": "active"}.
- Include related records (`include`, text): Set to Everything to add the related people, teams and other records to each result. One of: `all` (Everything).
- Fields (`fields`, list): Only return these fields of each record. Leave empty for every field.
- Sort by (`sort`, text): Sort by these fields, comma-separated. Put - before a field for newest or largest first, such as -created_at.
- Page (`page`, number): Which page to read, starting at 1. At least 1.
- Page size (`per_page`, number): How many records a page holds, up to 100. Playvox's default is 12. From 1 to 100.

**Outputs**

- `data` (object): The response from Playvox.

**Example output**

```json
{
  "data": {
    "count": 1,
    "next_page": 2,
    "result": [
      {
        "_id": "591461b3e911792fb0e29612",
        "created_at": "2017-05-11T13:05:55Z",
        "description": "Deals review",
        "effectiveness_goal": 80,
        "last_evaluation": "2018-01-19T16:47:48Z",
        "max_score": 100,
        "name": "SDR Deals - Version 2",
        "reference_name": "Link of Deal in HubSpot",
        "status": "active",
        "target": 80,
        "team_ids": [
          "57c590bce91179663c1dcc0a"
        ],
        "total_questions": 4,
        "two_steps_approval": false,
        "updated_at": "2018-01-19T16:47:48Z"
      }
    ],
    "success": true
  }
}
```

### List teams

List the teams in your Playvox account.

**Inputs**

- Filter (`query`, text): Only teams matching this Playvox filter, written as JSON, such as {"status": "active"}.
- Include related records (`include`, text): Set to Everything to add the related people, teams and other records to each result. One of: `all` (Everything).
- Fields (`fields`, list): Only return these fields of each record. Leave empty for every field.
- Sort by (`sort`, text): Sort by these fields, comma-separated. Put - before a field for newest or largest first, such as -created_at.
- Page (`page`, number): Which page to read, starting at 1. At least 1.
- Page size (`per_page`, number): How many records a page holds, up to 100. Playvox's default is 12. From 1 to 100.

**Outputs**

- `data` (object): The response from Playvox.

**Example output**

```json
{
  "data": {
    "count": 1,
    "next_page": 2,
    "result": [
      {
        "_id": "5c2e2b262bec120001d28f91",
        "created_at": "2019-01-03T15:32:54Z",
        "created_by": "5c2d2bcc2bec120001d291fd",
        "default": false,
        "description": "Freelancers Colombia",
        "name": "My new team",
        "site_id": "57cf3965e4b39f3654e0e297",
        "status": "active",
        "team_leader_id": [
          "5c2d2bcc2bec120001d291fd"
        ],
        "team_leader_info": [
          {
            "_id": "5da87ec92ada421e89ff41e1",
            "email": "johnconnor@playvox.com",
            "last_name": "Connor",
            "name": "John",
            "status": "active"
          }
        ],
        "total_users": 1,
        "updated_at": "2019-01-03T15:45:52Z",
        "users": [
          "5da87ec92ada421e89ff41e1"
        ],
        "users_info": [
          {
            "_id": "5da87ec92ada421e89ff41e1",
            "email": "johnconnor@playvox.com",
            "last_name": "Connor",
            "name": "John",
            "status": "active"
          }
        ]
      }
    ],
    "success": true
  }
}
```

### List users

List the people in your Playvox account.

**Inputs**

- Filter (`query`, text): Only users matching this Playvox filter, written as JSON, such as {"status": "active"}.
- Include related records (`include`, text): Set to Everything to add the related people, teams and other records to each result. One of: `all` (Everything).
- Fields (`fields`, list): Only return these fields of each record. Leave empty for every field.
- Sort by (`sort`, text): Sort by these fields, comma-separated. Put - before a field for newest or largest first, such as -created_at.
- Page (`page`, number): Which page to read, starting at 1. At least 1.
- Page size (`per_page`, number): How many records a page holds, up to 100. Playvox's default is 12. From 1 to 100.

**Outputs**

- `data` (object): The response from Playvox.

**Example output**

```json
{
  "data": {
    "count": 1,
    "next_page": 2,
    "result": [
      {
        "_id": "5ba82a54e4b39f481e96f168",
        "created_at": "2018-09-24T00:05:40Z",
        "created_by": "9asd8a8f7as87vcav787s8io",
        "email": "johndoe@playvox.com",
        "lang": "es_LA",
        "last_name": "Doe",
        "name": "John",
        "roles": [
          "7asd8a8f7as87vcav787s8io"
        ],
        "site_id": "8asd8a8f7as87vcav787s8io",
        "status": "active",
        "type": "analyst",
        "updated_at": "2018-09-24T00:17:36Z",
        "username": "johndoe@playvox.com"
      }
    ],
    "success": true
  }
}
```

### List workload assignments

List the evaluation workloads assigned to quality analysts.

**Inputs**

- Filter (`query`, text): Only assignments matching this Playvox filter, written as JSON, such as {"status": "pending"}.
- Include related records (`include`, text): Set to Everything to add the related people, teams and other records to each result. One of: `all` (Everything).
- Fields (`fields`, list): Only return these fields of each record. Leave empty for every field.
- Sort by (`sort`, text): Sort by these fields, comma-separated. Put - before a field for newest or largest first, such as -created_at.
- Page (`page`, number): Which page to read, starting at 1. At least 1.
- Page size (`per_page`, number): How many records a page holds, up to 100. Playvox's default is 12. From 1 to 100.

**Outputs**

- `data` (object): The response from Playvox.

**Example output**

```json
{
  "data": {
    "count": 1,
    "next_page": 2,
    "result": [
      {
        "_id": "5f4ab1a5e9117936fe6c6a12",
        "created_at": "2020-08-29T14:00:00Z",
        "status": "pending",
        "total_assigned_interactions": 12,
        "total_expected_interactions": 12,
        "type": "interactions",
        "updated_at": "2020-08-29T14:00:00Z",
        "users": [
          {
            "_id": "5ec6f0dce684c5c57614463b",
            "completed": 0,
            "goal": 6,
            "progress": 0,
            "workload": 50
          }
        ],
        "workload_id": "5f4ab1a5e9117936fe6c6a10"
      }
    ],
    "success": true
  }
}
```

### Remove user from team

Take a person off a team.

**Inputs**

- Team (`team`, text, required): The team. Pick one, or use a team ID from List teams.
- User (`user`, text, required): The user. Pick one, or use a user ID from List users.

**Outputs**

- `data` (object): The response from Playvox.

**Example output**

```json
{
  "data": {
    "result": {
      "_id": "5c2e2b262bec120001d28f91",
      "created_at": "2019-01-03T15:32:54Z",
      "created_by": "5c2d2bcc2bec120001d291fd",
      "default": false,
      "description": "Freelancers Colombia",
      "name": "My new team",
      "site_id": "57cf3965e4b39f3654e0e297",
      "status": "active",
      "team_leader_id": [
        "5c2d2bcc2bec120001d291fd"
      ],
      "total_users": 1,
      "updated_at": "2019-01-03T15:45:52Z",
      "users": [
        "5da87ec92ada421e89ff41e1"
      ]
    },
    "success": true
  }
}
```

### Send campaign metrics

Send agents' KPI values to a performance campaign.

**Inputs**

- Campaign (`campaign_id`, text, required): The campaign. Pick one, or use a campaign ID from List campaigns.
- Metrics (`metrics`, list, required): One entry for each value to record.

**Outputs**

- `data` (object): The response from Playvox.

**Example output**

```json
{
  "data": {
    "result": {
      "errors": [
        {
          "message": "Unknown variable"
        }
      ],
      "total_entries": 1,
      "total_errors": 0,
      "total_saved": 1
    },
    "success": true
  }
}
```

### Update interaction

Change an interaction's agent, other agents or date.

**Inputs**

- Integration (`id`, text, required): The integration. Pick one, or use an integration ID from List integrations.
- Interaction (`interaction_id`, text, required): The interaction's Playvox ID, from List interactions or Create interaction.
- Agent (`assignee_id`, text): The agent's email or username in Playvox.
- Other agents (`collaborators`, list): Emails or usernames of other agents who worked on it.
- Date (`interaction_date`, date and time): When the conversation happened.

**Outputs**

- `data` (object): The response from Playvox.

**Example output**

```json
{
  "data": {
    "result": {
      "_id": "5dd0d8c37ba057774c0e548f",
      "assignee_id": "jhon@playvox.com",
      "collaborators": [
        "lina@playvox.com"
      ],
      "created_at": "2019-11-17T05:21:07.527000Z",
      "created_by": "5c9e97ca2b938500012eaefa",
      "integration_id": "5dcf04ba195b8c23cff25128",
      "interaction_date": "2019-11-16T20:00:10.000000Z",
      "interaction_id": "456",
      "updated_at": "2019-11-17T05:28:44.071000Z"
    },
    "success": true
  }
}
```

### Update team

Change a team's name, description, leaders or members.

**Inputs**

- Team (`team`, text, required): The team. Pick one, or use a team ID from List teams.
- Name (`name`, text): The team's new name.
- Description (`description`, text): The team's new description.
- Team leaders (`team_leader_id`, list): The team leaders. This replaces the current list.
- Members (`users`, list): The members. This replaces the current list.

**Outputs**

- `data` (object): The response from Playvox.

**Example output**

```json
{
  "data": {
    "result": {
      "_id": "5c2e2b262bec120001d28f91",
      "created_at": "2019-01-03T15:32:54Z",
      "created_by": "5c2d2bcc2bec120001d291fd",
      "default": false,
      "description": "Freelancers Colombia",
      "name": "My new team",
      "site_id": "57cf3965e4b39f3654e0e297",
      "status": "active",
      "team_leader_id": [
        "5c2d2bcc2bec120001d291fd"
      ],
      "total_users": 1,
      "updated_at": "2019-01-03T15:45:52Z",
      "users": [
        "5da87ec92ada421e89ff41e1"
      ]
    },
    "success": true
  }
}
```

### Update user

Change a person's details, or deactivate or reactivate them.

**Inputs**

- User (`user`, text, required): The user. Pick one, or use a user ID from List users.
- First name (`name`, text): Their new first name.
- Last name (`last_name`, text): Their new last name.
- Username (`username`, text): Their new username.
- Email (`email`, text): Their new email address.
- Status (`status`, text): Active to reactivate them, Inactive to deactivate them. One of: `active`, `inactive`.
- Deactivation type (`deactivation_type`, text): When deactivating, the kind of deactivation your Playvox account uses.
- Deactivation reason (`deactivation_reason`, text): When deactivating, why.

**Outputs**

- `data` (object): The response from Playvox.

**Example output**

```json
{
  "data": {
    "result": {
      "_id": "5ba82a54e4b39f481e96f168",
      "created_at": "2018-09-24T00:05:40Z",
      "created_by": "9asd8a8f7as87vcav787s8io",
      "email": "johndoe@playvox.com",
      "lang": "es_LA",
      "last_name": "Doe",
      "name": "John",
      "roles": [
        "7asd8a8f7as87vcav787s8io"
      ],
      "site_id": "8asd8a8f7as87vcav787s8io",
      "status": "active",
      "type": "analyst",
      "updated_at": "2018-09-24T00:17:36Z",
      "username": "johndoe@playvox.com"
    },
    "success": true
  }
}
```
