---
title: "2. Upload a File"
method: POST
path: "/bdmanager.upload/{typedId}/{slotId}"
tags: ["Attachments"]
---

# 2. Upload a File

`POST /bdmanager.upload/{typedId}/{slotId}`

## Request

- Base URL: `https://companynode.pricefx.com/pricefx/companypartition`
- URL: `https://companynode.pricefx.com/pricefx/companypartition/bdmanager.upload/{typedId}/{slotId}`
- Auth: one of:
  - HTTP basic
  - API key in header `X-PriceFx-jwt`
- TypeScript: <https://skmtc.dev/pricefx/apis/the-pricefx-backend-api/docs/bdmanager.upload/:typedId/:slotId/post.ts> (a function with typed inputs; its response is checked against the schema)

Uploads a file.

To upload a file you need to retrieve the slot ID using the `/uploadmanager.newuploadslot` (**Create an Upload Slot**) endpoint.

## Request body `multipart/form-data`

- object
  - `file` string, binary: A **base64** encoded file data.

## Response `200`

OK

- object
  - `response` object
    - `node` string
    - `data` BinaryData[]
      - `lastUpdateByName` string, nullable
      - `createdByName` string
      - `fileName` string
      - `typedId` string
      - `lastUpdateDate` string, date-time, nullable
      - `length` integer
      - `latestUploadStatusId` integer
      - `version` integer
      - `sender` string, nullable
      - `createdBy` integer
      - `recipients` string, nullable
      - `sentViaEmail` boolean
      - `userGroupEdit` string, nullable
      - `userGroupViewDetails` string, nullable
      - `contentType` string
      - `embeddedOwner` string, nullable
      - `createDate` string, date-time
      - `lastUpdateBy` integer
    - `status` integer

---

[API](https://skmtc.dev/pricefx/apis/the-pricefx-backend-api.md) - [All operations](https://skmtc.dev/pricefx/apis/the-pricefx-backend-api/llms.txt) - [OpenAPI document](https://skmtc.dev/pricefx/apis/the-pricefx-backend-api/revisions/23d941b00ac0?raw)
