Prewave Suppliers - Sites API

🆕 NEW - Supplier and site management endpoints. Available from January 2026.

OpenAPI Specification

prewave-suppliers-sites-api-openapi.yml Raw ↑
openapi: 3.0.1
info:
  title: Public Prewave Actions Suppliers - Sites API
  description: 'Documentation of the Public Prewave API.


    ## What''s New


    ### Q1 2026 — Supplier Management, User Management, Actions and Feed


    This quarter introduces major v2 upgrades, expanded administrative capabilities, and the new Actions API.


    - **Core Releases:** Deployed Supplier Management API v2 and Feed API v2, alongside the all-new Actions API.

    - **Enhanced Functionality:** Added robust identifier management, granular user and role configuration, and endpoints for managing supplier connection contacts.

    - ⚠️ **Required Migration:** Legacy v1 endpoints for Suppliers and Sites Upsert have been deprecated. Developers must migrate existing integrations to v2 by **May 31, 2027** (original deadline was December 31, 2026).


    📖 **[Read the Q1 2026 changelog](https://docs.prewave.com/en/articles/699847-q1-2026-public-api-updates)**


    ### Q2 2026 — Supplier Screening and External Scores


    We have expanded our v2 documentation to include comprehensive integration guidance for supplier screening and validation workflows and identifier-based external score ingestion.


    - **New Capabilities:** Added support for optional post-onboarding screening and validation during the create event.

    - **External Scores:** Batch POST for multiple supplier sites, per-site history GET, and event-type discovery GET (`/public/v1/scores/externals` and `/public/v1/scores/externals/event-types`). Documented in OpenAPI when enabled for your organization.

    - **Developer Resources:** Published new integration examples and detailed identifier validation rules to streamline your implementation process.


    📖 **[Read the Q2 2026 changelog](https://docs.prewave.com/en/articles/699849-q2-2026-public-api-updates)**


    ### Q3 2026 — Scores Webhooks


    To support event-driven architectures and eliminate the need for continuous API polling, we are introducing webhooks for score state changes later this year.


    - **Event-Driven Architecture:** Register webhook URLs to receive real-time HTTP payloads whenever a supplier''s score updates, so you can drive immediate mitigation responses without polling the API.

    - **Availability:** Comprehensive OpenAPI specifications and payload schemas will be published closer to the release date.

    - **Note:** Schemas and behaviors are subject to refinement prior to general availability.


    Documentation updates will be provided prior to release.


    ### Q4 2026 — Feed V2


    We are enhancing Feed API v2 with additional capabilities on top of the existing `GET /public/v2/feed` contract (see Q1 changelog and OpenAPI for the current Feed v2 integration).


    - **Availability:** Details will be announced before release.

    - **Note:** Schemas and behaviors are subject to refinement prior to the official release.


    Documentation updates will be provided prior to release.


    ---


    ## Authentication

    Prewave’s public api uses *API tokens* to authenticate against our RESTful service. We’ll provide you an *API-token* that each

    endpoint needs present as a http header.


    To pass the token in a request, simply add it as a header-parameter with

    * key = X-Auth-Token

    * value = api-token


    See an example in curl below where the api-token would be 12345678-90ab-cdef-1234-567890abcdef

    ```

    curl --request GET \

    --url https://REPLACE_WITH_SERVER/public/v1/target/prewave/3975230/alerts \

    --header ''X-Auth-Token: 12345678-90ab-cdef-1234-567890abcdef''

    ```


    ---


    ## Manage API Tokens


    Before you can obtain your API token, you''ll need the credentials for your API user. These credentials will be

    sent to you as part of the company-onboarding. If you haven''t got your credentials yet, please reach out to

    your sales-contact at Prewave or contact us via info@prewave.ai


    To generate an API Token, navigate to https://www.prewave.com/management/api and log in with the

    credentials of your API user. Then click at the button "Create New" and use your new api-token authentication as a header parameter.


    You can create multiple API tokens and also remove existing API tokens on https://www.prewave.com/management/api.

    API tokens do not expire, therefore you have to maintain the list of API tokens you are using manually.


    ---


    ## Default Rate Limits


    We have two types of default rate limits. For increased access, please contact customer success.


    | Type                              | Requests per 10 seconds | Requests per Minute |

    |-----------------------------------|-------------------------|---------------------|

    | GET requests                      | 100                     | 500                 |

    | POST, PUT, PATCH, DELETE requests | 20                      | 100                 |


    '
  version: '1.0'
servers:
- url: https://api.prewave.com
  description: Production Environment
security:
- Token authentication: []
tags:
- name: Suppliers - Sites
  description: 🆕 NEW - Supplier and site management endpoints. Available from January 2026.
paths:
  /public/v2/suppliers/sites:
    get:
      tags:
      - Suppliers - Sites
      summary: Get all suppliers
      description: "\nRetrieve all supplier sites accessible to the authenticated user with pagination support.\n\nThis endpoint returns a list of supplier sites (physical locations/branches with addresses), not site-groups (general company owners). Each site represents a specific physical location where the supplier operates.\n\n**Related Endpoints:**\n- To find suppliers by specific identifiers, use `GET /public/v2/suppliers/sites/find-by-identifier`.\n- To create a new supplier, use `POST /public/v2/suppliers/sites`.\n- To check pending supplier creation requests, use `GET /public/v2/suppliers/sites/pending`.\n- To deactivate a supplier, use `DELETE /public/v2/suppliers/sites`.\n\nReturns supplier sites that the user has access to with simplified information:\n- Prewave Target ID\n- Name\n- Address (physical address of the site, if available)\n- City\n- Country Code\n- Supplier IDs\n\n**Ordering:**\n- Supplier sites are ordered alphabetically by name (case-insensitive), then by ID for deterministic pagination\n- Supplier IDs within each supplier site are ordered alphabetically by number, with null sources appearing last\n\n**Pagination:**\n- Results are paginated for efficient data retrieval\n- Use query parameters to control pagination:\n  - `page`: Page number (0-indexed, default: 0)\n  - `size`: Number of items per page (default: 10)\n- Ordering is fixed (alphabetically by name, then by ID) to ensure consistent results across pagination requests\n\n**Required Permission**: `ACCESS_PUBLIC_SUPPLIERS`\n    "
      operationId: getAllSuppliers
      parameters:
      - name: page
        in: query
        description: Zero-based page index (0..N)
        required: false
        schema:
          minimum: 0
          type: integer
          default: 0
      - name: size
        in: query
        description: The size of the page to be returned
        required: false
        schema:
          minimum: 1
          type: integer
          default: 10
      - name: sort
        in: query
        description: 'Sorting criteria in the format: property,(asc|desc). Default sort order is ascending. Multiple sort criteria are supported.'
        required: false
        schema:
          type: array
          items:
            type: string
      responses:
        '200':
          description: Successfully retrieved suppliers
          content:
            application/json:
              schema:
                type: object
                properties:
                  content:
                    type: array
                    items:
                      $ref: '#/components/schemas/PublicSupplierV2DTO'
                  size:
                    type: integer
                    format: int32
                  number:
                    type: integer
                    format: int32
                  totalElements:
                    type: integer
                    format: int32
                  totalPages:
                    type: integer
                    format: int32
                  numberOfElements:
                    type: integer
                    format: int32
                  first:
                    type: boolean
                  last:
                    type: boolean
                  empty:
                    type: boolean
              examples:
                Supplier - Multiple Results:
                  summary: Sample paginated supplier response
                  description: Supplier - Multiple Results
                  value:
                    content:
                    - prewaveTargetId: 102006215
                      name: Acme Corporation
                      address: 123 Main St, Vienna, Austria
                      city: Vienna
                      countryCode: AT
                      supplierIds:
                      - id: SUP-12345
                        source: SAP
                      - id: BNOID-67890
                    - prewaveTargetId: 102006216
                      name: Beta Industries Ltd
                      address: 456 Business Ave, Berlin, Germany
                      city: Berlin
                      countryCode: DE
                      supplierIds:
                      - id: SUP-54321
                        source: Oracle
                    size: 20
                    number: 0
                    totalElements: 57
                    totalPages: 3
                    numberOfElements: 2
        '403':
          description: '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.'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/AccessDeniedErrorDTO'
              examples:
                Access denied example:
                  summary: User lacks necessary permissions or authentication
                  value: "{\n        \"loggedIn\": true,\n        \"code\": \"access_denied\",\n        \"message\": \"Access denied: you don't have necessary permissions to access this resource\",\n        \"solution\": \"Contact support for appropriate permissions\"\n    }"
        '500':
          description: 500 Internal Server Error - An unexpected error occurred on the server. The request may or may not have been processed.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorDTO'
              examples:
                Error - Server Error:
                  summary: Unexpected server error
                  value: "{\n        \"code\": \"internal_error\",\n        \"message\": \"An unexpected error occurred\",\n        \"solution\": \"Please try again later or contact support\"\n    }"
        '429':
          description: '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.'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ApiRateLimitResponse'
              examples:
                Rate limit exceeded example:
                  summary: API rate limit exceeded
                  value: "{\n        \"error\": \"API rate limit exceeded\",\n        \"message\": \"You have reached the maximum allowed requests. Please try again later or upgrade your plan for increased access\",\n        \"requestLimit\": 100,\n        \"requestCount\": 100,\n        \"limits\": [\n            {\n                \"requestLimit\": 100,\n                \"timeInSeconds\": 10\n            },\n            {\n                \"requestLimit\": 500,\n                \"timeInSeconds\": 60\n            }\n        ],\n        \"currentTime\": \"2026-01-15T10:30:00\",\n        \"nextResetAt\": \"2026-01-15T10:30:10\"\n    }"
    post:
      tags:
      - Suppliers - Sites
      summary: Create a new supplier
      description: "\nCreate a new supplier with the specified properties.\n\nThe supplier will be created and automatically added to the user's supplier connections.\nAll required fields must be provided and will be validated.\n\n**Asynchronous Processing:**\n- Supplier creation is an asynchronous process that may take a few hours to complete.\n- The endpoint returns immediately with a `202 Accepted` status and a UUID for tracking.\n- The `202 Accepted` status indicates that the request has been accepted for processing but the resource is not yet fully created.\n- Use the returned UUID to track the request status via `GET /public/v2/suppliers/sites/pending?uuid={UUID}` (the Location header also points to this endpoint with the UUID query parameter).\n- Once processing is complete, the supplier will be available via `GET /public/v2/suppliers/sites` (get all suppliers) or `GET /public/v2/suppliers/sites/find-by-identifier` (find by identifier).\n\n**Request:**\nThe request body includes required fields (name, countryCode, city, address, supplierId) and optional fields (postalCode, industries, screeningPeriodInYears, requestValidationOnCreate). See the `PublicSupplierCreatePayloadV2` schema for complete field definitions, validation rules, and formatting requirements.\n\n**Optional post-init screening and validation:**\n- **`screeningPeriodInYears`** (optional): If set to **2**, **5**, or **10**, a history screening for that many years is scheduled automatically after the supplier is created and onboarding completes. Requires `ACCESS_PUBLIC_SCREENING_REQUEST` in addition to `ACCESS_PUBLIC_CONNECT_TARGET`. Omit or null to skip. Invalid values (e.g. 3) return `400 Bad Request` (`Failed to map screening period …`). After onboarding, poll `GET /public/v2/suppliers/sites/screening` with the same supplier identifiers.\n- **`requestValidationOnCreate`** (optional): If `true`, a validation (discovery) request is scheduled automatically after onboarding completes. Requires `ACCESS_PUBLIC_VALIDATION_REQUEST` in addition to `ACCESS_PUBLIC_CONNECT_TARGET`. Omit, null, or `false` to skip. After onboarding, poll `GET /public/v2/suppliers/sites/validation` with the same supplier identifiers.\n\n**Validation Rules:**\n- The combination of `supplierId.id` + `supplierId.source` must be unique within your organization.\n- A supplier creation request cannot be created if there's already a pending request with the same `supplierId.id` + `supplierId.source` combination (returns `409 Conflict`).\n- The `supplierId.id` must not already exist as a supplier ID for another supplier in your organization (returns `409 Conflict`).\n- All string fields are automatically trimmed of leading/trailing whitespace.\n\n**Idempotency:**\nThis endpoint is not idempotent. Multiple requests with the same data will create multiple pending requests unless a duplicate is detected (which returns `409 Conflict`).\n\n**Use Case Example: Creating a Supplier and Adding a Supplier ID from SAP Ariba**\n\nThis example demonstrates the complete workflow of creating a new supplier, waiting for it to be processed, and then adding an additional supplier ID from SAP Ariba.\n\n**Step 1: Create the Supplier**\n\n```http\nPOST /public/v2/suppliers/sites\nContent-Type: application/json\n\n{\n  \"name\": \"Acme Manufacturing Corp\",\n  \"countryCode\": \"AT\",\n  \"city\": \"Vienna\",\n  \"address\": \"123 Industrial Park, Vienna, Austria\",\n  \"postalCode\": \"1010\",\n  \"supplierId\": {\n    \"id\": \"SUP-ACME-001\",\n    \"source\": \"PUBLIC_API\"\n  },\n  \"industries\": [\"Manufacturing\", \"Electronics\"]\n}\n```\n\n**Response (202 Accepted):**\n```json\n{\n  \"uuid\": \"550e8400-e29b-41d4-a716-446655440000\",\n  \"message\": \"Supplier creation request submitted successfully\",\n  \"pendingEndpoint\": \"GET /public/v2/suppliers/sites/pending\"\n}\n```\n\nThe `202 Accepted` status indicates that the request has been accepted for processing but the supplier resource is not yet fully created. Use the returned UUID or the Location header to track the request status.\n\n**Step 2: Wait for Supplier Creation to Complete**\n\nPoll the pending suppliers endpoint until the supplier is no longer in the pending list:\n\n```http\nGET /public/v2/suppliers/sites/pending?uuid=550e8400-e29b-41d4-a716-446655440000\n```\n\n**While pending, you'll see:**\n```json\n[\n  {\n    \"uuid\": \"550e8400-e29b-41d4-a716-446655440000\",\n    \"supplierId\": {\n      \"id\": \"SUP-ACME-001\",\n      \"source\": \"PUBLIC_API\"\n    },\n    \"name\": \"Acme Manufacturing Corp\",\n    \"countryCode\": \"AT\",\n    \"city\": \"Vienna\",\n    \"address\": \"123 Industrial Park, Vienna, Austria\",\n    \"status\": \"Pending\",\n    \"reason\": null\n  }\n]\n```\n\n**Once processed, the supplier will no longer appear in the pending list** (the array will be empty or won't contain this UUID).\n\n**Step 3: Find the Supplier by Supplier ID**\n\nAfter processing is complete, find the supplier using the supplier ID you provided during creation:\n\n```http\nGET /public/v2/suppliers/sites/find-by-identifier?supplierId=SUP-ACME-001&source=Public_API\n```\n\n**Response:**\n```json\n[\n  {\n    \"prewaveTargetId\": 102006215,\n    \"name\": \"Acme Manufacturing Corp\",\n    \"address\": \"123 Industrial Park, Vienna, Austria\",\n    \"city\": \"Vienna\",\n    \"countryCode\": \"AT\",\n    \"supplierIds\": [\n      {\n        \"id\": \"SUP-ACME-001\",\n        \"source\": \"PUBLIC_API\"\n      }\n    ]\n  }\n]\n```\n\n**Step 4: Add Supplier ID from SAP Ariba**\n\nNow that you have the `prewaveTargetId` (102006215), add the SAP Ariba ERP vendor ID using the create identifier endpoint:\n\n```http\nPOST /public/v2/suppliers/sites/identifiers?prewaveId=102006215\nContent-Type: application/json\n\n{\n  \"type\": \"supplierId\",\n  \"id\": \"0000123456\",\n  \"source\": \"SAP_ARIBA_ERP_VENDOR_ID\"\n}\n```\n\n**Response (201 Created):**\n```json\n{\n  \"type\": \"supplierId\",\n  \"id\": \"0000123456\",\n  \"source\": \"SAP_ARIBA_ERP_VENDOR_ID\",\n  \"prewaveTargetId\": 102006215\n}\n```\n\n**Step 5: Verify the Supplier ID Was Added**\n\nVerify that both supplier IDs are now associated with the supplier by finding the supplier again:\n\n```http\nGET /public/v2/suppliers/sites/find-by-identifier?prewaveId=102006215\n```\n\n**Response:**\n```json\n[\n  {\n    \"prewaveTargetId\": 102006215,\n    \"name\": \"Acme Manufacturing Corp\",\n    \"address\": \"123 Industrial Park, Vienna, Austria\",\n    \"city\": \"Vienna\",\n    \"countryCode\": \"AT\",\n    \"supplierIds\": [\n      {\n        \"id\": \"SUP-ACME-001\",\n        \"source\": \"PUBLIC_API\"\n      },\n      {\n        \"id\": \"0000123456\",\n        \"source\": \"SAP_ARIBA_ERP_VENDOR_ID\"\n      }\n    ]\n  }\n]\n```\n\n**Alternative: Find Supplier by SAP Ariba Supplier ID**\n\nYou can now also find the supplier using the SAP Ariba ERP vendor ID:\n\n```http\nGET /public/v2/suppliers/sites/find-by-identifier?supplierId=0000123456&source=SAP_ARIBA_ERP_VENDOR_ID\n```\n\n**Notes:**\n- Supplier creation is asynchronous and may take a few hours. Poll `GET /public/v2/suppliers/sites/pending` periodically until the supplier is processed.\n- You can add multiple supplier IDs to the same supplier from different systems (SAP Ariba ERP vendor IDs, Coupa, DNB, etc.) using `POST /public/v2/suppliers/sites/identifiers`.\n- To find suppliers by their identifiers, use `GET /public/v2/suppliers/sites/find-by-identifier`.\n- To remove identifiers from suppliers, use `DELETE /public/v2/suppliers/sites/identifiers`.\n- To deactivate a supplier, use `DELETE /public/v2/suppliers/sites`.\n- Supplier IDs allow you to map suppliers in Prewave to identifiers used in your external systems.\n- SAP Ariba ERP vendor IDs typically follow a 10-digit format (e.g., \"0000123456\").\n- The `prewaveTargetId` is stable once the supplier is created, but may change in rare cases due to target merges.\n\n**Required permissions:** `ACCESS_PUBLIC_CONNECT_TARGET`.\n        "
      operationId: createSupplier
      requestBody:
        description: Supplier creation payload. Content-Type must be `application/json`. All required fields must be provided and will be validated. The `supplierId` field contains the supplier ID object with `id` (required) and `source` (optional, defaults to 'PUBLIC_API'). Optional `screeningPeriodInYears` (2, 5, or 10) and `requestValidationOnCreate` schedule post-init screening/validation after onboarding. String values are automatically trimmed of leading/trailing whitespace.
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/PublicSupplierCreatePayloadV2'
            examples:
              Supplier Create - SAP Source:
                summary: Example with SAP as the supplier ID source
                description: Supplier Create - SAP Source
                value:
                  name: Acme Corporation
                  countryCode: AT
                  city: Vienna
                  address: 123 Main St, Vienna, Austria
                  supplierId:
                    id: SUP-12345
                    source: SAP
                  postalCode: '1010'
                  industries:
                  - Manufacturing
                  - Technology
              Supplier Create - No Source:
                summary: Example without supplier ID source (defaults to 'PUBLIC_API')
                description: Supplier Create - No Source
                value:
                  name: Acme Corporation
                  countryCode: AT
                  city: Vienna
                  address: 123 Main St, Vienna, Austria
                  supplierId:
                    number: SUP-12345
              Supplier Create - Coupa Source:
                summary: Example with Coupa as the supplier ID source
                description: Supplier Create - Coupa Source
                value:
                  name: Beta Industries Ltd
                  countryCode: DE
                  city: Berlin
                  address: 456 Business Ave, Berlin, Germany
                  supplierId:
                    id: COUPA-67890
                    source: Coupa
                  postalCode: '10115'
                  industries:
                  - Automotive
                  - Electronics
              Supplier Create - DNB Source:
                summary: Example with DNB as the supplier ID source
                description: Supplier Create - DNB Source
                value:
                  name: Gamma Manufacturing Inc
                  countryCode: US
                  city: New York
                  address: 789 Industrial Blvd, New York, NY 10001
                  supplierId:
                    id: DNB-98765
                    source: DNB
              Supplier Create - Screening on create:
                summary: Schedule 2-year history screening after onboarding (requires ACCESS_PUBLIC_SCREENING_REQUEST)
                description: Supplier Create - Screening on create
                value:
                  name: Acme Corporation
                  countryCode: AT
                  city: Vienna
                  address: 123 Main St, Vienna, Austria
                  supplierId:
                    id: SUP-12345
                    source: PUBLIC_API
                  screeningPeriodInYears: 2
              Supplier Create - Validation on create:
                summary: Schedule validation after onboarding (requires ACCESS_PUBLIC_VALIDATION_REQUEST)
                description: Supplier Create - Validation on create
                value:
                  name: Acme Corporation
                  countryCode: AT
                  city: Vienna
                  address: 123 Main St, Vienna, Austria
                  supplierId:
                    id: SUP-12345
                    source: PUBLIC_API
                  requestValidationOnCreate: true
        required: true
      responses:
        '202':
          description: Accepted - Supplier creation request has been accepted for asynchronous processing. The request is being processed asynchronously and the resource is not yet fully created. Use the Location header or the returned UUID to track the request status via the pending suppliers endpoint.
          headers:
            Location:
              description: Absolute URL to the pending suppliers endpoint where the request status can be monitored. The URL includes the UUID query parameter to filter for this specific pending supplier. Follow this header to check the status of the pending request.
              required: true
              style: simple
              schema:
                type: string
                format: uri
              example: https://api.example.com/public/v2/suppliers/sites/pending?uuid=550e8400-e29b-41d4-a716-446655440000
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PublicSupplierCreateResponseV2'
              examples:
                Success response:
                  summary: Supplier creation request accepted for processing
                  description: The request has been accepted for asynchronous processing. The UUID can be used to track this specific request in the pending suppliers endpoint. The Location header also points to the pending endpoint for status monitoring.
                  value:
                    uuid: 550e8400-e29b-41d4-a716-446655440000
                    message: Supplier creation request submitted successfully
                    pendingEndpoint: GET /public/v2/suppliers/sites/pending
        '400':
          description: 400 Bad Request - Invalid request payload or validation errors. The request body is malformed or contains invalid data.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorDTO'
              examples:
                Missing required field:
                  summary: Required field is missing
                  description: Missing required field
                  value:
                    code: invalid_request
                    message: Name is required
                    solution: Fix the request
                Blank field validation:
                  summary: Required field is blank or contains only whitespace
                  description: Blank field validation
                  value:
                    code: invalid_request
                    message: Supplier ID is required
                    solution: Fix the request
                Invalid JSON:
                  summary: Request body is not valid JSON
                  description: Invalid JSON
                  value:
                    code: invalid_request
                    message: 'JSON parse error: Unexpected character'
                    solution: Fix the request
        '403':
          description: Forbidden — the API token does not have the permissions required for supplier creation (`ACCESS_PUBLIC_CONNECT_TARGET`), or optional post-init screening (`ACCESS_PUBLIC_SCREENING_REQUEST` when `screeningPeriodInYears` is set) or validation (`ACCESS_PUBLIC_VALIDATION_REQUEST` when `requestValidationOnCreate` is true).
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorDTO'
        '409':
          description: '409 Conflict - A resource with the same identifier already exists. This occurs when: (1) a pending supplier creation request with the same `supplierId.id` + `supplierId.source` combination already exists, or (2) the `supplierId.id` already exists as a supplier ID for another supplier in your organization.'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorDTO'
              examples:
                Duplicate pending supplier:
                  summary: Pending request already exists with same supplier ID
                  description: Another supplier creation request with the same supplier ID and source is already pending. Wait for it to be processed or check the pending suppliers endpoint.
                  value:
                    code: invalid_request
                    message: A supplier creation request with supplier ID 'SUP-12345' and source 'SAP' is already pending. Please wait for the existing request to be processed or check pending suppliers at GET /public/v2/suppliers/sites/pending
                    solution: Fix the request
                Duplicate supplier ID:
                  summary: Supplier ID already exists for another supplier
                  description: The supplier ID already exists for a different supplier in your organization.
                  value:
                    code: duplicate_supplier_id
                    message: Duplicate supplier IDs - id=SUP-12345, others_found=1, source=SAP
                    solution: Please provide unique supplier IDs
        '500':
          description: 500 Internal Server Error - An unexpected error occurred on the server. The request may or may not have been processed.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorDTO'
              examples:
                Error - Server Error:
                  summary: Unexpected server error
                  value: "{\n        \"code\": \"internal_error\",\n        \"message\": \"An unexpected error occurred\",\n        \"solution\": \"Please try again later or contact support\"\n    }"
        '429':
          description: '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.'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ApiRateLimitResponse'
              examples:
                Rate limit exceeded example:
                  summary: API rate limit exceeded
                  value: "{\n        \"error\": \"API rate limit exceeded\",\n        \"message\": \"You have reached the maximum allowed requests. Please try again later or upgrade your plan for increased access\",\n        \"requestLimit\": 20,\n        \"requestCount\": 20,\n        \"limits\": [\n            {\n                \"requestLimit\": 20,\n                \"timeInSeconds\": 10\n            },\n            {\n                \"requestLimit\": 100,\n                \"timeInSeconds\": 60\n            }\n        ],\n        \"currentTime\": \"2026-01-15T10:30:00\",\n        \"nextResetAt\": \"2026-01-15T10:30:10\"\n    }"
    delete:
      tags:
      - Suppliers - Sites
      summary: Deactivate a supplier by identifier
      description: "\nDeactivate (disconnect) a supplier from your organization using any identifier (supplier ID, customer ID, own site ID, or Prewave ID).\n\nThis unified endpoint allows you to deactivate suppliers using any type of identifier. You can search by one or more ID types, but **exactly one supplier must be found** for the deletion to proceed.\n\n**Related Endpoints:**\n- To find suppliers by identifier before deactivating, use `GET /public/v2/suppliers/sites/find-by-identifier`.\n- To create a new supplier, use `POST /public/v2/suppliers/sites`.\n- To manage supplier identifiers, use `POST /public/v2/suppliers/sites/identifiers` or `DELETE /public/v2/suppliers/sites/identifiers`.\n\n**Search Parameters:**\n- `supplierId` (optional): Search by supplier ID\n- `customerId` (optional): Search by customer ID\n- `ownId` (optional): Search by own site ID\n- `prewaveId` (optional): Search by Prewave ID\n- `source` (optional): Filter by source system (applies to supplierId, customerId, ownId only)\n\n**Search Behavior:**\n- **Multiple ID types**: If you provide multiple ID parameters, the endpoint searches for s

# --- truncated at 32 KB (129 KB total) ---
# Full source: https://raw.githubusercontent.com/api-evangelist/prewave/refs/heads/main/openapi/prewave-suppliers-sites-api-openapi.yml