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

# Create a recording

> Creates a recording and issues links for uploading the file to storage. The first step of a file upload.

## Path parameters

<ParamField path="space_id" type="integer" required>
  Space ID.
</ParamField>

## Request body

<ParamField body="title" type="string" required>
  Title up to 255 characters. **Ends with the file extension**: `.mp3`, `.m4a`, `.wav`, `.ogg`, `.webm`, `.mp4`.
</ParamField>

<ParamField body="size" type="integer" required>
  Exact file size in bytes.
</ParamField>

<ParamField body="content_type" type="string" required>
  MIME type of the file.
</ParamField>

## Response

<ResponseField name="id" type="integer">
  Recording ID (`audio_id`).
</ResponseField>

<ResponseField name="url" type="string[]">
  Links for the `PUT` of file parts, one per part of about 10 MB. They live for 5 hours.
</ResponseField>

<ResponseField name="is_uploaded" type="boolean">
  `false` until the upload is completed.
</ResponseField>

Every call creates a new recording. Do not blindly retry it if the response was lost: see [Reliable integration](/en/reference/best-practices).

<RequestExample>
  ```bash cURL theme={null}
  curl -X POST "https://api.aigenda.tech/api/spaces/1024/audio/" \
    -H "Authorization: Bearer <access>" \
    -H "Content-Type: application/json" \
    -d '{
      "title": "Sales team standup.mp3",
      "size": 18874368,
      "content_type": "audio/mpeg"
    }'
  ```

  ```python Python theme={null}
  import requests

  response = requests.post(
      "https://api.aigenda.tech/api/spaces/1024/audio/",
      headers={"Authorization": "Bearer <access>"},
      json={
          "title": "Sales team standup.mp3",
          "size": 18874368,
          "content_type": "audio/mpeg",
      },
      timeout=30,
  )
  response.raise_for_status()
  print(response.json())
  ```

  ```javascript JavaScript theme={null}
  const response = await fetch("https://api.aigenda.tech/api/spaces/1024/audio/", {
    method: "POST",
    headers: { Authorization: "Bearer <access>", "Content-Type": "application/json" },
    body: JSON.stringify({
      "title": "Sales team standup.mp3",
      "size": 18874368,
      "content_type": "audio/mpeg"
    }),
  });
  const data = await response.json();
  console.log(data);
  ```
</RequestExample>

<ResponseExample>
  ```json 201 theme={null}
  {
    "id": 51234,
    "title": "Sales team standup.mp3",
    "created_at": "2026-10-17T12:30:00.481233+03:00",
    "size": 18874368,
    "content_type": "audio/mpeg",
    "space_id": 1024,
    "is_active": true,
    "is_favorite": false,
    "is_uploaded": false,
    "was_classified": false,
    "result_is_ready": false,
    "url": [
      "https://storage.yandexcloud.net/aigenda/3f6c1e0a.mp3?partNumber=1&uploadId=…&X-Amz-Signature=…",
      "https://storage.yandexcloud.net/aigenda/3f6c1e0a.mp3?partNumber=2&uploadId=…&X-Amz-Signature=…"
    ],
    "duration": null
  }
  ```

  ```json 400 theme={null}
  {
    "title": [
      "This field is required."
    ]
  }
  ```
</ResponseExample>


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.