---
title: "Adjuntar un archivo"
method: POST
path: "/bills/{id}/attachment"
tags: ["Facturas de proveedor"]
---

# Adjuntar un archivo

`POST /bills/{id}/attachment`

## Request

- Base URL: `https://api.alegra.com/api/v1`
- URL: `https://api.alegra.com/api/v1/bills/{id}/attachment`
- Auth: HTTP basic

Este endpoint permite adjuntar un archivo a factura de proveedor registrada en la aplicación, mediante su identificador

## Parameters

- `#/paths/~1bills~1%7Bid%7D~1close/post/parameters/0` (unresolved $ref)

## Request body `multipart/form-data`

- object
  - `file` string, binary: Archivo que se va a adjuntar

## Response `200`

Se adjuntó un nuevo archivo

- object
  - `id` string
  - `name` string
  - `url` string

## Other responses

- `404` (unresolved $ref)

---

[API](https://skmtc.dev/alegra/apis/gastos.md) - [All operations](https://skmtc.dev/alegra/apis/gastos/llms.txt) - [OpenAPI document](https://skmtc.dev/alegra/apis/gastos/revisions/0b1ed7b7581d?raw)
