Skip to content

[LA-36925] Document customField clear + occupationRole#54

Merged
tejanium merged 4 commits into
mainfrom
LA-36925/document-user-update-clear-and-role
Jun 10, 2026
Merged

[LA-36925] Document customField clear + occupationRole#54
tejanium merged 4 commits into
mainfrom
LA-36925/document-user-update-clear-and-role

Conversation

@tejanium

@tejanium tejanium commented Jun 9, 2026

Copy link
Copy Markdown

Jira

https://learnamp.atlassian.net/browse/LA-36925

What

Documents two verified behaviours on the user-update API (PUT /v1/users/:id and the by_integration_external_id variant) in source/includes/_users.md:

  1. Clearing a customField value — send "value": null or "value": "" to clear a field; omitting a field leaves it unchanged; clearing a presence-validated field returns 400 Bad Request (value retained); an unknown field name returns 404 Not Found.
  2. occupationRole — new optional string attribute. Assigns an occupation role as the user's primary role and applies its target skills. Unknown role name returns 422 Unprocessable Entity. Returned on the user object and readable back via GET /v1/users/:id.

Why

Integrators need accurate docs for these shipped behaviours (customField clearing and occupation-role assignment).

Anything Else

Docs-only change. No build run (Slate/Middleman site; build requires the full gem bundle and is not quick).


Note

Low Risk
Documentation-only change to Slate API reference; no runtime or API behavior changes in this PR.

Overview
Updates the Users API docs in _users.md for user update flows (PUT /v1/users/{id} and by integration external ID).

Documents optional occupationRole: skills-matrix role name on update, returned on user JSON in show/create/update examples, with 422 when the name does not exist in the company.

Adds a Clearing custom field values section: clear via null or "", omission leaves values unchanged, presence-validated fields cannot be cleared (400), unknown field names 404, and customFields ignored when the feature is disabled. Links the customFields parameter to that section and adds matching error response examples.

Notes that the integration-external-id update route follows the same customFields / occupationRole behavior.

Reviewed by Cursor Bugbot for commit 8941a95. Bugbot is set up for automated code reviews on this repo. Configure here.

@tejanium

tejanium commented Jun 9, 2026

Copy link
Copy Markdown
Author

Renamed per review. The param and response field is now occupationRole (was skillsMatrixRole).

I think occupationRole fits better because it matches the product's existing terminology rather than inventing one. The UI labels an Occupation as a "Role" (occupations: Roles in sidebar/settings, occupation: Role in onboarding), and the CSV import feature already use the exact phrase "occupation role" / "occupation roles".

It also stays clearly distinct from the system permission role on this same endpoint, so thats a nice bonus.

Docs updated to use occupationRole throughout the user-update section.

@tejanium tejanium changed the title [LA-36925] Document customField clear + skillsMatrixRole [LA-36925] Document customField clear + occupationRole Jun 9, 2026
@tejanium tejanium marked this pull request as ready for review June 10, 2026 13:19
@tejanium tejanium merged commit 5de279a into main Jun 10, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant