> ## Documentation Index
> Fetch the complete documentation index at: https://developers.getswipe.in/llms.txt
> Use this file to discover all available pages before exploring further.

# Update vendor mapping

> Re-links your vendor IDs to existing Swipe records in bulk. Use this after changing IDs in your own system, so future calls don't create duplicate vendors.



## OpenAPI

````yaml post /v2/vendor/list
openapi: 3.0.1
info:
  title: SwipeAPI
  version: '2.0'
  description: >-
    The Swipe Partner API — invoicing, payments, and GST compliance for your
    application. Create GST invoices and other documents, manage customers,
    vendors, products and inventory, record payments, and generate e-invoices
    and e-way bills.


    - Docs & guides: https://developers.getswipe.in

    - Quickstart: https://developers.getswipe.in/quickstart

    - Rate limit: 1 request/second per API key

    - All dates are DD-MM-YYYY
servers:
  - url: https://app.getswipe.in/api/partner
security:
  - bearerAuth: []
paths:
  /v2/vendor/list:
    post:
      tags:
        - Vendor V2
      summary: Update vendor mapping
      description: >-
        Re-links your vendor IDs to existing Swipe records in bulk. Use this
        after changing IDs in your own system, so future calls don't create
        duplicate vendors.
      operationId: post_vendor_list
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/ListVendorMapModel'
        required: true
      responses:
        '200':
          description: Updated successfully
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/VendorResponseV2'
        '400':
          description: Error in mapping Vendor List
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/VendorResponseV2'
        '401':
          description: Unauthorized
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/VendorResponseV2'
        '409':
          description: Error in mapping Vendor List
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/VendorMappingResponseV2'
        '500':
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/VendorResponseV2'
components:
  schemas:
    ListVendorMapModel:
      required:
        - vendor_mapping
      properties:
        vendor_mapping:
          type: array
          items:
            $ref: '#/components/schemas/VendorMapModel'
      type: object
    VendorResponseV2:
      properties:
        success:
          type: boolean
          description: Success flag
          example: true
        message:
          type: string
          description: Response message
          example: ''
        error_code:
          type: string
          description: Error Code
          example: ''
        errors:
          type: object
          description: Errors
        data:
          $ref: '#/components/schemas/EmptyData'
      type: object
    VendorMappingResponseV2:
      properties:
        success:
          type: boolean
          description: Success flag
          example: true
        message:
          type: string
          description: Response message
          example: Message
        error_code:
          type: string
          description: Error Code
          example: ''
        errors:
          type: object
          description: Errors
        data:
          type: object
          description: Data
      type: object
    VendorMapModel:
      required:
        - swipe_id
        - vendor_id
      properties:
        vendor_id:
          type: string
          description: Vendor ID
        swipe_id:
          type: string
          description: Swipe ID
          example: 1
        force_update:
          type: boolean
          description: >-
            Updates even if the vendor id is already mapped with other swipe id,
            no vendor details will be updated
          example: true
      type: object
    EmptyData:
      properties:
        message:
          type: string
          description: Response message
          example: No data found!
      type: object
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT
      description: >-
        Bearer authentication header of the form `Bearer <token>`, where
        `<token>` is an API key from the [API
        Integration](https://app.getswipe.in/user?tab=api_integration) section
        of your dashboard. Keys are scoped to the company they are generated in
        — for testing, [add a separate test
        company](https://community.getswipe.in/t/how-to-add-new-company-on-web/1191)
        and generate the key there, so requests never touch your real books.

````