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

# User Identity

## Overview

The `/v1/meta/users/me` endpoint is designed to retrieve the current authenticated user's information.

## Authentication

To access all these endpoint, the request must include a valid form of Authentication through one of the available [Authentication Modes](/user-management/api/email-password#authentication-modes). All examples below use the Bearer Token Authentication Mode to demonstrate their usage but in some cases it might be simpler to use the Cookie Authentication Mode. The Authentication used should be of the end-user whose information is to be worked with.​

## Get User Info

### Example Request

<CodeGroup>
  ```bash curl theme={null}
    curl --location 'https://my-project.fastgenapp.com/v1/meta/users/me' \
      --header 'Authorization: Bearer YOUR_TOKEN' 
  ```

  ```python python theme={null}
  import requests

  url = 'https://my-project.fastgenapp.com/v1/meta/users/me'
  headers = {
      'Authorization': 'Bearer YOUR_TOKEN',
  }

  response = requests.get(url, headers=headers)

  print(response.json())
  ```
</CodeGroup>

### Example Response

<CodeGroup>
  ```json json theme={null}
  {
    "Uuid": "b3a5d21a-2b22-4e5a-89c5-6240f1d55904",
    "FirstName": "John",
    "LastName": "Doe",
    "Email": "john.doe@example.com",
    "CreatedAt": "2023-01-15T10:25:30.456789Z",
    "UpdatedAt": "2023-10-24T09:45:15.678910Z"
  }
  ```
</CodeGroup>

## Update User's Name

To set the users first name and last name, either for the first time after signup or to update, make a request to the `/v1/users/me/name` endpoint of your project URL.

### Example Request for User Signup

<CodeGroup>
  ```bash curl theme={null}
    curl --location 'https://my-project.fastgenapp.com/v1/users/me/name' \
      --header 'Authorization: Bearer <THE_ACCESS_TOKEN>' \
      --header 'Content-Type: application/json' \
      --data '{
        "firstname": "spongebob",
        "lastname": "squarepants"
      }'
  ```

  ```python python theme={null}
  import requests
  import json

  url = "https://my-project.fastgenapp.com/v1/users/me/name"
  payload = json.dumps({
    "firstname": "spongebob",
    "lastname": "squarepants"
  })
  headers = {
    'rid': 'thirdpartyemailpassword',
    'Content-Type': 'application/json',
  }

  response = requests.request("POST", url, headers=headers, data=payload)
  print(response.text)
  ```
</CodeGroup>
