---
title: "Salvar arquivo"
method: POST
path: "/v2/file"
tags: ["Arquivos"]
---

# Salvar arquivo

`POST /v2/file`

Após o upload do arquivo na URL fornecida na rota GET /core/v2/file execute este metodo para obter o ID do arquivo<br />O Id do arquivo pode ser fornecido no envio de mensagens. <br /><br />O FileId pode ser reaproveitado, não sendo necessário novos uploads para o mesmo arquivo.

## Request body

- PublicReqFileSaveV2DTO
  - `tempFileId` string, uuid, required — Código do arquivo

## Response `200`

Success

- PublicFileV2DTO
  - `id` string, uuid
  - `companyId` string, uuid, nullable
  - `userId` string, uuid, nullable
  - `name` string, nullable
  - `extension` string, nullable
  - `mimeType` string, nullable
  - `type` 'UNDEFINED' | 'PDF' | 'EXCEL' | 'WORD' | 'IMAGE' | 'AUDIO' | 'VIDEO' | 'DOCUMENT'
  - `key` string, nullable
  - `size` integer

## Other responses

- `500` — Server Error

---

[API](https://skmtc.net/wts/apis/core.md) · [All operations](https://skmtc.net/wts/apis/core/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/wts/core/versions/1efd0a6ba643/schema)
