---
title: "Promote the vendor names a catalogue sync has staged into suppliers"
method: POST
path: "/api/v1/inventory/suppliers/transfer-vendors"
tags: ["suppliers"]
---

# Promote the vendor names a catalogue sync has staged into suppliers

`POST /api/v1/inventory/suppliers/transfer-vendors`

## Request

- Base URL: `https://api.app.tightly.io`
- URL: `https://api.app.tightly.io/api/v1/inventory/suppliers/transfer-vendors`
- Auth: HTTP bearer

Promotes the vendor names an e-commerce catalogue sync has staged into real suppliers, and answers 200 with the plain body `ok`, not JSON, and not the `{message, data}` envelope. It takes no body and no parameters.

The rows it reads are written by the catalogue sync, so it has an effect only after a sync has run and only for vendors that are not suppliers yet. A vendor already on file is left exactly as it is, so running it twice is harmless and running it on a book with nothing staged is a no-op.

This is not a general import. import_suppliers is the door for a CSV of your own, and create_supplier for suppliers named in a request body.

Scope: `suppliers:write`, which includes `suppliers:read`.

## Headers

- `Tightly-Version` string
- `Idempotency-Key` string

## Response `200`

The staged vendors were promoted. The body is the two characters `ok`.

## Other responses

- `401`: No usable key: malformed, unknown, revoked, expired or stopped. One refusal covers all five, telling a caller which is which maps the surface for them. A request with no Authorization header at all is refused 400 before any key is looked for.
- `403`: The key may not reach this operation. `scope_missing` when the key does not hold Suppliers; `ip_not_allowed` when the caller's address is outside the key's allowlist. There is no `organization_mismatch` on this resource: no supplier or contact route names an organisation in its path, so there is nothing for a key to disagree with.
- `429`: The key has spent its allowance for this minute. 600 reads and 120 writes a minute, counted per key, refused calls included. `Retry-After` says how long to wait.
- `503`: The database is briefly out of reach, which is what a failover or a full connection pool looks like from outside. Wait the seconds `Retry-After` names and send the request again. A read is safe to repeat. A write is not, because the connection was lost in the middle of it, so read the object back before sending it a second time. Branch on the status rather than on `code`, which is `POSTGRES_UNAVAILABLE` from one of the two seams that raise this and `SERVICE_UNAVAILABLE` from the other.

---

[API](https://skmtc.dev/tightly/apis/tightly-api.md) · [All operations](https://skmtc.dev/tightly/apis/tightly-api/llms.txt) · [OpenAPI document](https://skmtc.dev/tightly/apis/tightly-api/revisions/199f7eb35afb?raw)
