# Update warehouse

Updates an existing Ship From Location (formerly known as warehouse).

Note: In the API, the endpoint is called warehouse, but the process actually affects Ship From Locations in the UI.

Endpoint: PUT /warehouses/updatewarehouse
Version: 1.0.0
Security: basicAuth

## Request fields (application/json):

  - `warehouseId` (integer, required)
    Unique identifier for the warehouse
    Example: 17977

  - `warehouseName` (string)
    Name of Ship From Location
    Example: "Flagship Location"

  - `originAddress` (object, required)
    Physical address for shipping or billing

  - `originAddress.name` (string)
    Name of the recipient
    Example: "John Doe"

  - `originAddress.company` (any)
    Company name
    Example: "Acme Corp"

  - `originAddress.street1` (string)
    First line of the street address
    Example: "123 Main St"

  - `originAddress.street2` (any)
    Second line of the street address
    Example: "Apt 4B"

  - `originAddress.street3` (any)
    Third line of the street address
    Example: "Building B"

  - `originAddress.city` (string)
    City name
    Example: "Austin"

  - `originAddress.state` (string)
    State or province code
    Example: "TX"

  - `originAddress.postalCode` (string)
    Postal or ZIP code
    Example: "78701"

  - `originAddress.country` (string)
    Two-letter ISO country code
    Example: "US"

  - `originAddress.phone` (any)
    Phone number
    Example: "512-555-1234"

  - `originAddress.residential` (any)
    Whether the address is residential
    Example: true

  - `originAddress.addressVerified` (any)
    Address verification status
    Example: "Address validated successfully"

  - `returnAddress` (any)

  - `isDefault` (boolean)
    Whether this will be the default Ship From Location
    Example: true

## Response 200 fields (application/json):

  - `warehouseId` (integer)

  - `warehouseName` (string)

  - `originAddress` (object)
    Physical address for shipping or billing

  - `returnAddress` (any)

  - `isDefault` (boolean)

## Response 400 fields (application/json):

  - `message` (string)
    Example: "Invalid request parameters"

## Response 401 fields (application/json):

  - `message` (string)
    Example: "Invalid API credentials"

## Response 404 fields (application/json):

  - `message` (string)
    Example: "Resource not found"

## Response 500 fields (application/json):

  - `message` (string)
    Example: "An internal error occurred"


