---
title: "Update a user"
method: PATCH
path: "/users/{user_id}/"
tags: ["Users"]
---

# Update a user

`PATCH /users/{user_id}/`

Updates user attributes specified in the request body. Unspecified attributes remain unchanged.
Updates can be performed via **PUT** or **PATCH**. The `full_name` attribute is mandatory for **PUT** requests but optional for **PATCH**.
**Note**: When updating via `/users/me/`, you must use your full user ID in the request body. The `me` alias is not supported in request bodies.
### Instructions for Updating Social, Education, and Employment Fields
- **Social Profiles**:
  - Provide platform usernames or identifiers (not full URLs) for:
    - `github`, `twitter`, `linkedIn`: arrays of strings
    - `scholar`, `orcid`, `researcherId`, `impactStory`: single string
    - `profileWebsites`: array of full URLs
  - Example:
    ```json
    "social": {
      "linkedIn": ["userLinkedInID"],
      "github": ["githubUsername"],
      "twitter": ["twitterHandle"],
      "profileWebsites": ["http://example.com"]
    }
    ```

- **Education and Employment**:
  - Each record must include:
    - `institution` (required, non-empty string)
    - `startYear` and `startMonth` (required integers, startYear ≥ 1900, startMonth 1-12)
    - `ongoing` (required boolean)
    - Optional fields: `degree`, `title`, `department`
    - If `ongoing` is `false`, include `endYear` and `endMonth` (end date ≥ start date)
  - Example:
    ```json
    "employment": [{
      "title": "Data Scientist",
      "institution": "Open Science Framework",
      "department": "Engineering",
      "startYear": 2018,
      "startMonth": 5,
      "ongoing": true
    }]
    ```

## Path parameters

- `user_id` string, required

## Request body

- object
  - `id` string, required — The unique identifier of the user entity.
  - `type` string, required — The type identifier of the user entity (`users`).
  - `attributes` object, required — The properties of the user entity.
    - `active` boolean, required — Whether or not the user is an active user.
    - `date_registered` string, date-time, required — The time at which the user registered their account, as an iso8601 formatted timestamp.
    - `family_name` string — The family name of the user, used for bibliographic citations.
    - `full_name` string, required — The full name of the user, used for display on the OSF.
    - `given_name` string — The given name of the user, used for bibliographic citations.
    - `middle_names` string — The middle names of the user, used for bibliographic citations.
    - `suffix` string — The suffix of the user, used for bibliographic citations.
    - `locale` string — The user's locale, e.g. 'en_US'.
    - `timezone` string — The user's timezone, e.g. 'Etc/UTC'.
    - `social` object — A dictionary of the user's social and academic profile links. Fields may include: - `github`, `twitter`, `linkedIn`: List of profile URLs (strings) - `scholar`, `orcid`, `researcherId`, `impactStory`, etc.: Single URL string - `profileWebsites`: List of personal website URLs (strings)
    - `employment` object[] — A list of the user's employment history records.
      - `title` string
      - `institution` string, required
      - `department` string
      - `startYear` integer, required
      - `startMonth` integer, required
      - `endYear` integer
      - `endMonth` integer
      - `ongoing` boolean, required
    - `education` object[] — A list of the user's educational history records.
      - `degree` string
      - `institution` string, required
      - `department` string
      - `startYear` integer, required
      - `startMonth` integer, required
      - `endYear` integer
      - `endMonth` integer
      - `ongoing` boolean, required
  - `relationships` object, required — URLs to other entities or entity collections that have a relationship to the user entity.
    - `institutions` string — A link to the list of institutions the user is affiliated with.
    - `nodes` string — A link to the list of nodes the user is a contributor to.
  - `links` object, required — URLs to alternative representations of the user entity.
    - `html` string, URL — A link to the user's profile page on the OSF.
    - `profile_image` string, URL — A link to the user's profile image.

## Response `200`

OK

---

[API](https://skmtc.net/osf/apis/osf-apiv2-documentation.md) · [All operations](https://skmtc.net/osf/apis/osf-apiv2-documentation/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/osf/osf-apiv2-documentation/versions/ca701048eb0d/schema)
