---
title: "UpdateByCustomerId"
url: "https://dev-portal.dehaven.org/apis/beer-api-v1/versions/a462a401-23c6-469f-86bf-c6017a4a1733/operations/UpdateByCustomerId"
---

> Full API specification: https://dev-portal.dehaven.org/apis/beer-api-v1/versions/a462a401-23c6-469f-86bf-c6017a4a1733.md

# UpdateByCustomerId

`PUT` `/api/v1/customers/{customerId}`

Operation ID: `UpdateByCustomerId`

Update Customer by Id

## Path parameters

- `customerId` (string, uuid, required) - Customer Id

## Request body (required)

Content types: `application/json`

## Responses

- `204` - Beer Updated
- `400` - Bad Reqeust
- `404` - Not Found
- `409` - Conflict

## OpenAPI definition

```yaml
openapi: 3.0.2
info:
  title: SFG Brewery API
  version: "1.3"
servers:
  - url: http://localhost:8080
    description: Local Host
  - url: http://api.springframework.guru
    description: Demo API
paths:
  /api/v1/customers/{customerId}:
    parameters:
      - $ref: "#/components/parameters/CustomerId"
    put:
      description: Update Customer by Id
      operationId: UpdateByCustomerId
      tags:
        - Order Service
      parameters:
        - $ref: "#/components/parameters/CustomerId"
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/Customer"
      responses:
        "204":
          description: Beer Updated
        "400":
          description: Bad Reqeust
        "404":
          description: Not Found
        "409":
          description: Conflict
components:
  parameters:
    CustomerId:
      name: customerId
      in: path
      description: Customer Id
      required: true
      schema:
        type: string
        format: uuid
  schemas:
    Customer:
      type: object
      required:
        - name
      allOf:
        - $ref: "#/components/schemas/BaseItem"
      properties:
        name:
          type: string
          maxLength: 255
          minLength: 1
    BaseItem:
      type: object
      properties:
        id:
          type: string
          format: uuid
          readOnly: true
          nullable: true
        version:
          type: integer
          readOnly: true
          nullable: true
        createdDate:
          type: string
          format: date-time
          readOnly: true
          nullable: true
        lastModifiedDate:
          type: string
          format: date-time
          readOnly: true
          nullable: true
```
