info:
  name: Update Device Mapping
  type: http
  seq: 10
http:
  method: PUT
  url: '{{base_url}}/api/devices/{{device_id}}/collections/{{mapping_id}}'
  auth: inherit
  body:
    type: json
    jsonBody: "{\n    \"device_shelf_name\": \"Science Fiction\",\n    \"sync_direction\"\
      : \"book_to_device\""

docs: |-
  ## Update Device Mapping
  
    Updates settings for a collection-to-device mapping.
    
    **Method:** PUT
    
    **Endpoint:** /api/devices/{device_id}/collections/{mapping_id}
    
    **Authentication:** Required (Bearer token)
    
    **Path Parameters:**
    - `device_id` (string): Device ID
    - `mapping_id` (string): Mapping ID
    
    **Request Body:**
    - `device_shelf_name` (string, optional): Custom shelf name on device
    - `sync_direction` (string, optional): Sync direction (book_to_device, device_to_book, bidirectional)
    
    **Response:**
    - Updated mapping object
    
    **Status Codes:**
    - 200: Success
    - 400: Invalid request
    - 401: Unauthorized
    - 404: Device or mapping not found
