API Response differs from Documentation

When calling the GET /user/{tenantId}/users/{id} endpoint (GET /User API: https://cumulocity.com/api/core/#operation/getUserResource), I’m seeing a mismatch between the documentation and the actual response.

According to the docs, the response should include fields like firstName, lastName, and displayName (example model shown in the documentation). However, in my response these fields are missing (specifically: firstName, lastName, displayName).

Is there a prerequisite, permission, or request parameter I’m missing, or is this expected behavior in certain cases?

Hi,

these are optional fields, so they are only included if these fields are actually populated for a specific user. I checked this for both a user who has the fields populated and for a user where they are not provided. In the first case they are included in the response.

Best regards,
Harald

1 Like