---
title: "Create an identifier for a supplier"
method: POST
path: "/public/v2/suppliers/sites/identifiers"
tags: ["Suppliers - Sites"]
---

# Create an identifier for a supplier

`POST /public/v2/suppliers/sites/identifiers`

Create a new identifier (supplier ID, customer ID, or own site ID) for a supplier using flexible search parameters.

**Related Endpoints:**
- To find suppliers by identifier, use `GET /public/v2/suppliers/sites/find-by-identifier`.
- To delete an identifier, use `DELETE /public/v2/suppliers/sites/identifiers`.
- To create a new supplier, use `POST /public/v2/suppliers/sites`.
- To get all suppliers, use `GET /public/v2/suppliers/sites`.

**How It Works:**

1. **Find the Supplier**: Provide one or more search parameters to identify the supplier:
   - `supplierId` (optional): Search by supplier ID
   - `customerId` (optional): Search by customer ID
   - `ownId` (optional): Search by own site ID
   - `prewaveId` (optional): Search by Prewave ID
   - `source` (optional): Filter by source system (applies to supplierId, customerId, and ownId)

2. **Create the Identifier**: In the request body, specify:
   - `type`: The type of identifier to create (`supplierId`, `customerId`, or `ownId`)
   - `id`: The identifier value
   - `source`: Optional source system (defaults to `PUBLIC_API` if not provided)

**Search Parameters:**
- `supplierId` (optional): Search by supplier ID
- `customerId` (optional): Search by customer ID
- `ownId` (optional): Search by own site ID
- `prewaveId` (optional): Search by Prewave ID
- `source` (optional): Filter by source system

**Search Behavior:**
- Parameters are combined with **OR** logic - suppliers matching ANY of the provided identifiers will be found
- At least one search parameter must be provided
- If multiple suppliers match, an error is returned (use `source` parameter to narrow down)
- If no suppliers match, a 404 error is returned

**Request Body:**
The request body specifies what identifier to create:
- `type`: Must be one of: `supplierId`, `customerId`, `ownId`
- `id`: The identifier value (e.g., "SUP-12345")
- `source`: Optional source system (e.g., "SAP", "Coupa")

**Examples:**

1. **Create a supplier ID by searching with prewaveId:**
   ```
   POST /public/v2/suppliers/sites/identifiers?prewaveId=102006215
   Body: {"type": "supplierId", "id": "SUP-12345", "source": "SAP"}
   ```

2. **Create a customer ID by searching with existing supplier ID:**
   ```
   POST /public/v2/suppliers/sites/identifiers?supplierId=SUP-12345&source=SAP
   Body: {"type": "customerId", "id": "CUST-67890", "source": "SAP"}
   ```

3. **Create an own site ID by searching with customer ID:**
   ```
   POST /public/v2/suppliers/sites/identifiers?customerId=CUST-67890
   Body: {"type": "ownId", "id": "OWN-SITE-01", "source": "SAP"}
   ```

**Important Notes:**
- The combination of identifier value and source must be unique within your organization
- If the identifier already exists for this supplier, a 409 Conflict error is returned
- If the identifier exists for a different supplier, a 409 Conflict error is returned
- All identifier changes are automatically audited

**Required Permission**: `MANAGE_PUBLIC_SUPPLIER_IDS`

## Query parameters

- `supplierId` string
- `customerId` string
- `ownId` string
- `prewaveId` integer
- `source` string

## Request body

- PublicIdentifierCreatePayloadV2 — Payload for creating a new identifier (supplier ID, customer ID, or own site ID)
  - `type` 'SUPPLIER_ID' | 'CUSTOMER_ID' | 'OWN_ID', required — Type of identifier
  - `id` string, required — The identifier value
  - `source` string, nullable — Source system of the identifier (e.g., 'SAP', 'Excel', 'Coupa'). Optional - defaults to 'PUBLIC_API' when not provided.

## Response `201`

Created - Identifier created successfully.

- PublicIdentifierResponseV2 — Response for identifier creation
  - `type` 'SUPPLIER_ID' | 'CUSTOMER_ID' | 'OWN_ID', required — Type of identifier
  - `id` string, required — The identifier value
  - `source` string, nullable — Source system of the identifier
  - `prewaveTargetId` integer, required — Prewave target ID of the supplier this identifier was added to

## Other responses

- `400` — 400 Bad Request - Invalid request. This can occur if: (1) no search parameters provided, (2) invalid identifier type, (3) missing required fields in request body, or (4) multiple suppliers found (use source parameter to narrow down).
- `403` — 403 Forbidden - Authentication or authorization failure. This status code is returned when: (1) the request lacks valid authentication credentials (missing or invalid X-Auth-Token header), or (2) the authenticated user does not have the required permission to access this resource.
- `404` — 404 Not Found - No supplier found matching the provided search parameters.
- `409` — 409 Conflict - The identifier already exists. This occurs when: (1) the identifier already exists for this supplier, or (2) the identifier exists for a different supplier in your organization.
- `429` — 429 Too Many Requests - API rate limit exceeded. The request has been rejected because the rate limit for this endpoint has been exceeded. Default rate limits: GET requests - 100 per 10 seconds, 500 per minute; POST/PUT/PATCH/DELETE requests - 20 per 10 seconds, 100 per minute. For increased access, please contact customer success.
- `500` — 500 Internal Server Error - An unexpected error occurred on the server. The request may or may not have been processed.

---

[API](https://skmtc.net/prewave/apis/public-prewave-api.md) · [All operations](https://skmtc.net/prewave/apis/public-prewave-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/prewave/public-prewave-api/revisions/466169815b78/schema)
