Skip to content

Update Customer

Updates the data of an existing customer.

Request

PUT /api/oauth/v2/resource/customers/{uuid}

HeaderValue
AuthorizationBearer {access_token}
Content-Typeapplication/json

URL parameters

ParameterTypeRequiredDescription
uuidstringYesUnique customer ID

Body parameters

Note: All fields are optional. After the update, at least one of the fields firstName, lastName, or companyName must be set.

FieldTypeRequiredDescription
firstNamestringNoFirst name
lastNamestringNoLast name
companyNamestringNoCompany name
titlestringNoTitle (e.g. Dr., Mag.)
emailstringNoEmail address
telstringNoPhone number
telCodestringNoCountry dialing code (e.g. +43)
streetstringNoStreet and house number
zipstringNoPostal code
citystringNoCity
countrystringNoCountry code (ISO 3166-1 alpha-2, e.g. AT)
birthdaystringNoDate of birth (YYYY-MM-DD)
sexintegerNoSex
noticestringNoInternal note
customerNumberstringNoCustomer number
socialNumberstringNoSocial security number

Response

Success (200 OK)

json
{
  "data": {
    "id": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
    "title": null,
    "firstName": "Anna",
    "lastName": "Muster",
    "email": "anna.neu@example.com",
    "phone": "+43 664 1234567",
    "birthday": "1985-04-12",
    "socialNumber": "1234 120485",
    "tenancies": [
      {
        "id": "f0e1d2c3-b4a5-6789-fedc-ba9876543210",
        "name": "Ordination Muster",
        "abbreviation": "OM",
        "color": "#00adba"
      }
    ]
  }
}

Response fields

See Customer Details for the full field description.

Beispiele
bash
curl -X PUT "https://my.offisy.at/api/oauth/v2/resource/customers/b2c3d4e5-f6a7-8901-bcde-f01234567890" \
  -H "Authorization: Bearer {access_token}" \
  -H "Content-Type: application/json" \
  -d '{
    "firstName": "Max",
    "lastName": "Mustermann",
    "companyName": "Muster GmbH",
    "title": "beispiel",
    "email": "anna.muster@example.com",
    "tel": "+43 664 1234567",
    "telCode": "+43 664 1234567",
    "street": "Musterstraße 1",
    "zip": "4020",
    "city": "Linz",
    "country": "AT",
    "birthday": "beispiel",
    "sex": "1",
    "notice": "beispiel",
    "customerNumber": "beispiel",
    "socialNumber": "1234010190"
  }'
Parameter
Zuerst Token anfordern

Possible errors

StatusCodeDescription
400validation_errorInvalid request data (e.g. no name set)
401invalid_clientInvalid or missing access token
403insufficient_scopeScope customers not present
404not_foundCustomer not found

Offisy GmbH