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

# Get a user

> Get a single user by their ID.



## OpenAPI

````yaml /openapi.json get /api/svc/v1/users/{id}
openapi: 3.1.0
info:
  title: TrueFoundry API
  description: API for TrueFoundry
  version: 0.1.0
  contact: {}
servers:
  - url: https://{controlPlaneURL}
    variables:
      controlPlaneURL:
        default: app.truefoundry.com
        description: Control Plane URL
security: []
tags:
  - name: Agent
  - name: Agent Skills
  - name: Applications
  - name: Metrics
  - name: Apply
  - name: Artifacts
  - name: Audit Logs
  - name: Clusters
  - name: Jobs
  - name: Logs
  - name: MCP Servers V2
  - name: MLRepos
  - name: Model Deployments
  - name: Models
  - name: Personal Access Tokens
  - name: Prompts
  - name: Provider Integrations
  - name: SCIM v2
  - name: Secret Groups
  - name: Secrets
  - name: Teams
  - name: Traces
  - name: Users
  - name: Virtual Accounts
  - name: Role Bindings
  - name: Workspaces
paths:
  /api/svc/v1/users/{id}:
    get:
      tags:
        - Users
      summary: Get a user
      description: Get a single user by their ID.
      operationId: User.getUserById
      parameters:
        - name: id
          required: true
          in: path
          description: System-generated user ID.
          schema:
            example: jqfwg345gi25n5ju2yz5iz6m
            type: string
      responses:
        '200':
          description: The user with the given ID.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/GetUserResponse'
        '404':
          description: User with the provided ID was not found.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HttpError'
      security:
        - jwt: []
components:
  schemas:
    GetUserResponse:
      type: object
      properties:
        data:
          description: The requested user.
          allOf:
            - $ref: '#/components/schemas/User'
      required:
        - data
      title: GetUserResponse
      x-fern-type-name: GetUserResponse
    HttpError:
      type: object
      properties:
        statusCode:
          type: integer
          description: HTTP Status Code
        message:
          type: string
          description: Error Message
        code:
          oneOf:
            - type: integer
            - type: string
          description: Error code
          nullable: true
        details:
          type: array
          description: Error details
          items:
            type: object
          nullable: true
      required:
        - statusCode
        - message
      title: HttpError
      x-fern-type-name: HttpError
    User:
      type: object
      properties:
        id:
          type: string
          description: System-generated user ID.
          example: jqfwg345gi25n5ju2yz5iz6m
        email:
          type: string
        tenantName:
          type: string
        metadata:
          $ref: '#/components/schemas/UserMetadata'
        roles:
          nullable: true
          type: array
          items:
            type: string
        rolesWithResource:
          nullable: true
          type: array
          items:
            $ref: '#/components/schemas/RoleWithResource'
        accounts:
          nullable: true
          type: array
          items:
            $ref: '#/components/schemas/AccountInfo'
        active:
          type: boolean
        isEditable:
          type: boolean
        createdAt:
          format: date-time
          type: string
        updatedAt:
          format: date-time
          type: string
        lastAccessedAt:
          format: date-time
          type: string
          nullable: true
          description: Timestamp when the user last accessed the platform.
      required:
        - id
        - email
        - tenantName
        - metadata
        - active
        - isEditable
        - createdAt
        - updatedAt
      title: User
      x-fern-type-name: User
    UserMetadata:
      type: object
      properties:
        sub:
          type: string
          nullable: true
        imageURL:
          type: string
          nullable: true
        pictureDownloadPath:
          type: string
          nullable: true
        displayName:
          type: string
          nullable: true
        userObject:
          type: object
          additionalProperties: true
          nullable: true
        inviteAccepted:
          type: boolean
          nullable: true
        registeredInIdp:
          type: boolean
          nullable: true
        preference:
          type: object
          additionalProperties: true
          nullable: true
        groups:
          nullable: true
          type: array
          items:
            type: string
        tenantRoleManagedBy:
          type: string
          enum:
            - manual
            - group
            - initial
          nullable: true
        ssoName:
          type: string
          nullable: true
        scimUserObject:
          type: object
          additionalProperties: true
          nullable: true
        createdByScim:
          type: boolean
          nullable: true
      title: UserMetadata
      x-fern-type-name: UserMetadata
    RoleWithResource:
      type: object
      properties:
        roleId:
          type: string
        resourceType:
          type: string
          enum:
            - role
            - account
            - cluster
            - workspace
            - environment
            - secret-group
            - deployment
            - application
            - secret
            - docker-registry
            - tenant
            - vcs-integration
            - mlf-project
            - repository
            - provider-integration
            - team
            - service-account
            - llm-gateway
            - policy
            - role-binding
            - settings
            - provider-account
            - user
            - alert-config
            - alert-rule
            - gateway-config
            - gateway-controls
            - gateway-budget
            - tracing-project
            - tracing-application
            - agent
            - agent-app
            - gateway-installation
            - virtual-account
            - sso-based-identity
            - external-identity
            - mcp-server
            - external-identity-provider
            - agent-identity
        resourceId:
          type: string
        roleName:
          type: string
      required:
        - roleId
        - resourceType
        - resourceId
        - roleName
      title: RoleWithResource
      x-fern-type-name: RoleWithResource
    AccountInfo:
      type: object
      properties:
        accountId:
          type: string
        name:
          type: string
      required:
        - accountId
        - name
      title: AccountInfo
      x-fern-type-name: AccountInfo
  securitySchemes:
    jwt:
      type: http
      scheme: bearer
      bearerFormat: JWT

````