> ## Documentation Index
> Fetch the complete documentation index at: https://docs.flowpayroll.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Change your preferences

> A JSON Merge Patch (RFC 7396): name only what changes, and everything left out stays as it is; `null` puts a preference, or a whole group, back to its default. A field this API does not know is refused (400), so a misspelt preference is never taken for a saved one. Answers every preference as it now stands. Two changes at once each keep what they changed; 409 `concurrent_change` only when a change keeps losing. API tokens are refused (403 `preferences_need_a_person`).



## OpenAPI

````yaml /api-reference/specs/administration.json patch /users/me/preferences
openapi: 3.0.4
info:
  title: Administration API
  description: >-
    Manage your Flow Payroll account: the organisations it owns, the people who
    can sign in to it, the API tokens it holds, its brand, and a feed of recent
    administration activity. Every resource is scoped to the account your
    credentials belong to, so no request ever names a customer and the
    `X-Org-Id` header is not used.
  version: v1
servers:
  - url: https://api.sandbox.flowpayroll.ai/v1/administration
security:
  - X-Auth-Token: []
tags:
  - name: Customer
    description: >-
      Your account: the customer every other resource on this API belongs to.
      Read it and rename it.
  - name: Organisations
    description: >-
      The organisations your account owns or manages: list them with headcounts
      and your access to each, get one in full, add one or several at a time,
      see everybody who can reach one, and read which of its data an outside
      system manages.
  - name: Organisation groups
    description: >-
      Named sets of your organisations, such as the clients one team looks
      after. Give a person or API token a group, and they reach every
      organisation in it, including ones added later.
  - name: Users
    description: >-
      The people who can sign in to your account: list, invite (one or many),
      resend invitations, and manage each person's direct grants and
      account-wide access.
  - name: Roles
    description: >-
      What people and API tokens can do where they have access: the built-in
      roles, roles of your own, and the default role. Only Administrator can be
      given today.
  - name: API tokens
    description: >-
      The client credentials your integrations authenticate with: create (the
      secret is shown once), rename, rotate, revoke, and manage which
      organisations each token reaches.
  - name: Branding
    description: >-
      Your white-label brand: edit a draft, publish it, upload its files, and
      set a company logo for each organisation.
  - name: Activity
    description: >-
      Recent administration actions in your account, and every change to who has
      access, newest first.
  - name: SCIM
    description: >-
      SCIM 2.0 provisioning: your identity provider adds, updates, suspends and
      removes your account's people, and gives them account-wide roles.
paths:
  /users/me/preferences:
    patch:
      tags:
        - Users
      summary: Change your preferences
      description: >-
        A JSON Merge Patch (RFC 7396): name only what changes, and everything
        left out stays as it is; `null` puts a preference, or a whole group,
        back to its default. A field this API does not know is refused (400), so
        a misspelt preference is never taken for a saved one. Answers every
        preference as it now stands. Two changes at once each keep what they
        changed; 409 `concurrent_change` only when a change keeps losing. API
        tokens are refused (403 `preferences_need_a_person`).
      operationId: UpdateUserPreferences
      requestBody:
        content:
          application/merge-patch+json:
            schema:
              $ref: '#/components/schemas/UpdateUserPreferencesRequest'
          application/json:
            schema:
              $ref: '#/components/schemas/UpdateUserPreferencesRequest'
        required: true
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/UserPreferencesResponseResponseBody'
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ObjectResponseBody'
        '401':
          description: Unauthorized
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ObjectResponseBody'
        '403':
          description: Forbidden
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ObjectResponseBody'
        '409':
          description: Conflict
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ObjectResponseBody'
        '503':
          description: Service Unavailable
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ObjectResponseBody'
components:
  schemas:
    UpdateUserPreferencesRequest:
      type: object
      properties:
        people:
          allOf:
            - $ref: '#/components/schemas/UpdatePeoplePreferencesRequest'
          description: >-
            How lists of people are sorted. `null` puts every one of them back
            to its default.
          nullable: true
      additionalProperties: false
      description: >-
        A JSON Merge Patch (RFC 7396) of the signed-in person's preferences:
        name only what changes, and everything left

        out stays as it is. `null` puts a preference, or a whole group, back to
        its default. A field this API does not

        know is refused rather than ignored, so a misspelt preference is never
        mistaken for a saved one.
    UserPreferencesResponseResponseBody:
      type: object
      properties:
        message:
          $ref: '#/components/schemas/MessageWithTokenResponse'
        content:
          $ref: '#/components/schemas/UserPreferencesResponseContentResponse'
        validationIssues:
          type: array
          items:
            $ref: '#/components/schemas/ValidationIssue'
          nullable: true
      additionalProperties: false
    ObjectResponseBody:
      type: object
      properties:
        message:
          $ref: '#/components/schemas/MessageWithTokenResponse'
        content:
          $ref: '#/components/schemas/ObjectContentResponse'
        validationIssues:
          type: array
          items:
            $ref: '#/components/schemas/ValidationIssue'
          nullable: true
      additionalProperties: false
    UpdatePeoplePreferencesRequest:
      type: object
      properties:
        nameOrder:
          enum:
            - LastName
            - FirstName
          type: string
          description: '`LastName` or `FirstName`; `null` puts it back to `LastName`.'
          nullable: true
      additionalProperties: false
      description: A merge patch of the people preferences.
    MessageWithTokenResponse:
      type: object
      properties:
        text:
          type: string
        token:
          type: string
        tokenArguments:
          type: array
          items:
            $ref: '#/components/schemas/ValidationIssueArgument'
          nullable: true
      additionalProperties: false
    UserPreferencesResponseContentResponse:
      type: object
      properties:
        data:
          $ref: '#/components/schemas/UserPreferencesResponse'
        metadata:
          $ref: '#/components/schemas/ContentMetadataResponse'
      additionalProperties: false
    ValidationIssue:
      type: object
      properties:
        field:
          type: string
        reason:
          type: string
        reasonToken:
          type: string
        reasonTokenArguments:
          type: array
          items:
            $ref: '#/components/schemas/ValidationIssueArgument'
          nullable: true
      additionalProperties: false
    ObjectContentResponse:
      type: object
      properties:
        data: {}
        metadata:
          $ref: '#/components/schemas/ContentMetadataResponse'
      additionalProperties: false
    ValidationIssueArgument:
      type: object
      properties:
        name:
          type: string
        value: {}
      additionalProperties: false
    UserPreferencesResponse:
      type: object
      properties:
        people:
          $ref: '#/components/schemas/PeoplePreferencesResponse'
      additionalProperties: false
      description: >-
        The signed-in person's own preferences, every one of them, each at its
        default until they choose. Grouped by the

        part of the app a preference is about; a new preference arrives inside
        its group, or as a new group, and never

        changes the shape of one that exists.
    ContentMetadataResponse:
      type: object
      properties:
        dateFormat:
          type: string
        dateTimeFormat:
          type: string
        paginationToken:
          type: string
          nullable: true
      additionalProperties: false
    PeoplePreferencesResponse:
      type: object
      properties:
        nameOrder:
          enum:
            - LastName
            - FirstName
          type: string
          description: >-
            `LastName` (the default) or `FirstName`. Names always read first
            name first.
      additionalProperties: false
      description: >-
        How lists of people (employees, payslips, people with access) are sorted
        for this person.
  securitySchemes:
    X-Auth-Token:
      type: apiKey
      description: FlowPayroll JWT (raw token, no Bearer prefix)
      name: X-Auth-Token
      in: header

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.