Skip to main content
Set who a user reports to, month by month, and return what changed. managers is the user’s whole reporting line, past stretches included, not an addition to it: a manager the list leaves out stops managing the user over those months. Read the user with get_user first and send back every stretch to keep, or the ones missing from your list are removed. Passing an empty list leaves the user reporting to no one. Re-sending what is stored changes nothing, so the same call can be sent twice. Only what actually changed comes back in attribution_changes, each row saying whether it was created, moved or removed. No statement is recalculated by this call: a calculation that depends on the reporting line picks the change up the next time it runs. The call is refused, and nothing is written, when:
  • two rows cover the same month: a user reports to one manager at a time.
  • the user is named as their own manager.
  • the user is archived.
  • a new stretch names an archived manager.
Requires write permission on users. Every write is recorded in the audit trail as the Qobra MCP agent.
Example arguments

Parameters

Body

string
required
Id from list_users, or the user’s exact email.
object[]
required
The complete list of managers, each with the months they manage the user for. It replaces the current managers: one left out stops managing over those months. An empty list leaves the user reporting to no one. No month may be covered by two rows.

Response

Body

object
The user whose managers the call set.
object[]
Every management the call changed, as created, moved or removed. Empty when the declared managers already matched.