---
title: "Register a field-sales recording upload"
---

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

Path: Channel Automation API › Conversations

`POST /api/field-sales/conversations`

## Authentication

- `BearerAuth`, http, header `Authorization`, format `JWT`

## Request body

_Required._

- `filename` (`post/api/field-sales/conversations.filename`; string, required)
- `mime_type` (`post/api/field-sales/conversations.mime_type`; string, required)
- `size_bytes` (`post/api/field-sales/conversations.size_bytes`; integer, required)
- `consent_confirmed` (`post/api/field-sales/conversations.consent_confirmed`; boolean, required)
- `title` (`post/api/field-sales/conversations.title`; string, optional)
- `source` (`post/api/field-sales/conversations.source`; string, optional)
  - one of `"web_recorder"`, `"file_upload"`, `"mobile_app"`
- `contact_id` (`post/api/field-sales/conversations.contact_id`; string, optional, nullable)
  - format `uuid`
- `appointment_id` (`post/api/field-sales/conversations.appointment_id`; string, optional, nullable)
  - format `uuid`
- `client_recording_id` (`post/api/field-sales/conversations.client_recording_id`; string, optional) — Stable device recording identifier reused for registration retries
  - format `uuid`
- `consent_method` (`post/api/field-sales/conversations.consent_method`; string, optional)
- `started_at` (`post/api/field-sales/conversations.started_at`; string, optional, nullable)
  - format `date-time`
- `ended_at` (`post/api/field-sales/conversations.ended_at`; string, optional, nullable)
  - format `date-time`
- `duration_seconds` (`post/api/field-sales/conversations.duration_seconds`; integer, optional)
  - min 0

## Example request

```json
{
  "title": "string",
  "filename": "string",
  "mime_type": "string",
  "size_bytes": 0,
  "source": "web_recorder",
  "contact_id": "f245e2a3-e141-4d41-912c-b1c1f5bd5598",
  "appointment_id": "21634f0d-2156-4d4b-a142-2e7c783a9212",
  "client_recording_id": "4987f4f6-e33c-42e3-bbee-1db4c1c1d9ab",
  "consent_confirmed": true,
  "consent_method": "string",
  "started_at": "2019-08-24T14:15:22Z",
  "ended_at": "2019-08-24T14:15:22Z",
  "duration_seconds": 0
}
```

## Code samples

### cURL

```bash
curl --request POST \
  --url https://api.channelautomation.com/api/field-sales/conversations \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "title": "string",
  "filename": "string",
  "mime_type": "string",
  "size_bytes": 0,
  "source": "web_recorder",
  "contact_id": "f245e2a3-e141-4d41-912c-b1c1f5bd5598",
  "appointment_id": "21634f0d-2156-4d4b-a142-2e7c783a9212",
  "client_recording_id": "4987f4f6-e33c-42e3-bbee-1db4c1c1d9ab",
  "consent_confirmed": true,
  "consent_method": "string",
  "started_at": "2019-08-24T14:15:22Z",
  "ended_at": "2019-08-24T14:15:22Z",
  "duration_seconds": 0
}
'
```

### TypeScript

```typescript
const url = 'https://api.channelautomation.com/api/field-sales/conversations';
const options = {
  method: 'POST',
  headers: {'Content-Type': 'application/json', Authorization: 'Bearer <token>'},
  body: JSON.stringify({
    title: 'string',
    filename: 'string',
    mime_type: 'string',
    size_bytes: 0,
    source: 'web_recorder',
    contact_id: 'f245e2a3-e141-4d41-912c-b1c1f5bd5598',
    appointment_id: '21634f0d-2156-4d4b-a142-2e7c783a9212',
    client_recording_id: '4987f4f6-e33c-42e3-bbee-1db4c1c1d9ab',
    consent_confirmed: true,
    consent_method: 'string',
    started_at: '2019-08-24T14:15:22Z',
    ended_at: '2019-08-24T14:15:22Z',
    duration_seconds: 0
  })
};

fetch(url, options)
  .then(res => res.json())
  .then(json => console.log(json))
  .catch(err => console.error(err));
```

### Python

```python
import requests

url = "https://api.channelautomation.com/api/field-sales/conversations"

payload = {
    "title": "string",
    "filename": "string",
    "mime_type": "string",
    "size_bytes": 0,
    "source": "web_recorder",
    "contact_id": "f245e2a3-e141-4d41-912c-b1c1f5bd5598",
    "appointment_id": "21634f0d-2156-4d4b-a142-2e7c783a9212",
    "client_recording_id": "4987f4f6-e33c-42e3-bbee-1db4c1c1d9ab",
    "consent_confirmed": True,
    "consent_method": "string",
    "started_at": "2019-08-24T14:15:22Z",
    "ended_at": "2019-08-24T14:15:22Z",
    "duration_seconds": 0
}
headers = {
    "Content-Type": "application/json",
    "Authorization": "Bearer <token>"
}

response = requests.post(url, json=payload, headers=headers)

print(response.text)
```

## Responses

### 201

Conversation and resumable-upload target created

### 404

Feature disabled


Source: https://developer.channelautomations.com/api/post-api-field-sales-conversations/index.md
