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

# Set a person's people type

> People type is a company-level record referenced by id, with an optional expiry; null clears both.

**Requires scope:** `people:write`.



## OpenAPI

````yaml /api-docs/openapi.v1.json patch /api/v1/people/{id}/people-type
openapi: 3.0.0
info:
  title: SkillsDB Public API
  description: >-
    The SkillsDB public REST API. Authenticate every request with an API key
    created in Settings → API Credentials, sent as `Authorization: Bearer
    sdb_live_…`. Errors follow RFC 9457 problem details; every `type` URI
    resolves under https://help.skillsdb.com/api-docs/errors/.
  version: '1'
  contact: {}
servers:
  - url: https://prod.skillsdbnext.com
    description: Production
  - url: https://staging.skillsdbnext.com
    description: Staging
security: []
tags: []
paths:
  /api/v1/people/{id}/people-type:
    patch:
      tags:
        - People
      summary: Set a person's people type
      description: >-
        People type is a company-level record referenced by id, with an optional
        expiry; null clears both.


        **Requires scope:** `people:write`.
      operationId: setPersonPeopleType
      parameters:
        - name: Idempotency-Key
          in: header
          required: false
          description: >-
            Any unique string (at most 200 characters). Retrying with the same
            key and identical content replays the stored response for 24h
            instead of executing twice.
          schema:
            type: string
            maxLength: 200
        - name: id
          required: true
          in: path
          description: >-
            The person's email address — or the opaque person id from any
            response.
          schema:
            type: string
            example: ada@example.com
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/SetPeopleTypeDto'
      responses:
        '200':
          description: The resource, enveloped.
          content:
            application/json:
              schema:
                type: object
                required:
                  - data
                properties:
                  data:
                    $ref: '#/components/schemas/PersonDto'
          headers:
            X-Request-Id:
              description: Unique id for this request — quote it when contacting support.
              schema:
                type: string
            RateLimit-Limit:
              description: The bucket's hourly allowance.
              schema:
                type: integer
            RateLimit-Remaining:
              description: Requests left in the current window.
              schema:
                type: integer
            RateLimit-Reset:
              description: Seconds until the window resets.
              schema:
                type: integer
            Idempotency-Replayed:
              description: >-
                `true` when this response was replayed from a previous execution
                under the same Idempotency-Key.
              schema:
                type: string
        '400':
          description: >-
            Validation failed
            (`https://help.skillsdb.com/api-docs/errors/validation-error`)
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/ProblemDetailsDto'
          headers:
            X-Request-Id:
              description: Unique id for this request — quote it when contacting support.
              schema:
                type: string
            RateLimit-Limit:
              description: The bucket's hourly allowance.
              schema:
                type: integer
            RateLimit-Remaining:
              description: Requests left in the current window.
              schema:
                type: integer
            RateLimit-Reset:
              description: Seconds until the window resets.
              schema:
                type: integer
        '401':
          description: >-
            Invalid credential
            (`https://help.skillsdb.com/api-docs/errors/invalid-credential`)
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/ProblemDetailsDto'
          headers:
            X-Request-Id:
              description: Unique id for this request — quote it when contacting support.
              schema:
                type: string
            RateLimit-Limit:
              description: The bucket's hourly allowance.
              schema:
                type: integer
            RateLimit-Remaining:
              description: Requests left in the current window.
              schema:
                type: integer
            RateLimit-Reset:
              description: Seconds until the window resets.
              schema:
                type: integer
        '403':
          description: >-
            Insufficient scope
            (`https://help.skillsdb.com/api-docs/errors/insufficient-scope`) ·
            Insufficient permissions
            (`https://help.skillsdb.com/api-docs/errors/insufficient-permissions`)
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/ProblemDetailsDto'
          headers:
            X-Request-Id:
              description: Unique id for this request — quote it when contacting support.
              schema:
                type: string
            RateLimit-Limit:
              description: The bucket's hourly allowance.
              schema:
                type: integer
            RateLimit-Remaining:
              description: Requests left in the current window.
              schema:
                type: integer
            RateLimit-Reset:
              description: Seconds until the window resets.
              schema:
                type: integer
        '404':
          description: Not found (`https://help.skillsdb.com/api-docs/errors/not-found`)
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/ProblemDetailsDto'
          headers:
            X-Request-Id:
              description: Unique id for this request — quote it when contacting support.
              schema:
                type: string
            RateLimit-Limit:
              description: The bucket's hourly allowance.
              schema:
                type: integer
            RateLimit-Remaining:
              description: Requests left in the current window.
              schema:
                type: integer
            RateLimit-Reset:
              description: Seconds until the window resets.
              schema:
                type: integer
        '409':
          description: >-
            Idempotency key reused with different content
            (`https://help.skillsdb.com/api-docs/errors/idempotency-key-reused`)
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/ProblemDetailsDto'
          headers:
            X-Request-Id:
              description: Unique id for this request — quote it when contacting support.
              schema:
                type: string
            RateLimit-Limit:
              description: The bucket's hourly allowance.
              schema:
                type: integer
            RateLimit-Remaining:
              description: Requests left in the current window.
              schema:
                type: integer
            RateLimit-Reset:
              description: Seconds until the window resets.
              schema:
                type: integer
        '429':
          description: >-
            Rate limit exceeded
            (`https://help.skillsdb.com/api-docs/errors/rate-limit-exceeded`)
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/ProblemDetailsDto'
          headers:
            X-Request-Id:
              description: Unique id for this request — quote it when contacting support.
              schema:
                type: string
            RateLimit-Limit:
              description: The bucket's hourly allowance.
              schema:
                type: integer
            RateLimit-Remaining:
              description: Requests left in the current window.
              schema:
                type: integer
            RateLimit-Reset:
              description: Seconds until the window resets.
              schema:
                type: integer
            Retry-After:
              description: Seconds to wait before retrying.
              schema:
                type: integer
        '500':
          description: >-
            Internal error
            (`https://help.skillsdb.com/api-docs/errors/internal-error`)
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/ProblemDetailsDto'
          headers:
            X-Request-Id:
              description: Unique id for this request — quote it when contacting support.
              schema:
                type: string
            RateLimit-Limit:
              description: The bucket's hourly allowance.
              schema:
                type: integer
            RateLimit-Remaining:
              description: Requests left in the current window.
              schema:
                type: integer
            RateLimit-Reset:
              description: Seconds until the window resets.
              schema:
                type: integer
      security:
        - apiKey:
            - people:write
components:
  schemas:
    SetPeopleTypeDto:
      type: object
      properties:
        peopleTypeId:
          type: string
          example: '3'
          nullable: true
          description: People type id, or null to clear.
        expiresAt:
          type: string
          example: '2026-12-31T00:00:00.000Z'
          nullable: true
      required:
        - peopleTypeId
    PersonDto:
      type: object
      properties:
        id:
          type: string
          example: '91'
          description: Opaque person id.
        externalId:
          type: string
          example: EMP-0042
          nullable: true
          description: >-
            The customer's own identifier — the field an integration should key
            on. Customer-supplied and NOT guaranteed unique.
        firstName:
          type: string
          example: Dana
        lastName:
          type: string
          example: Reviewer
        email:
          type: string
          example: dana@example.com
          nullable: true
        accessLevel:
          nullable: true
          allOf:
            - $ref: '#/components/schemas/AccessLevelDto'
        manager:
          nullable: true
          description: The person's manager.
          allOf:
            - $ref: '#/components/schemas/ReferenceDto'
        isActive:
          type: boolean
          example: true
          description: >-
            Always an explicit boolean — legacy rows with no stored value read
            as active.
        jobTitle:
          nullable: true
          allOf:
            - $ref: '#/components/schemas/ReferenceDto'
        peopleType:
          nullable: true
          allOf:
            - $ref: '#/components/schemas/PersonPeopleTypeDto'
        orgSchema:
          $ref: '#/components/schemas/OrgSchemaDto'
        businessPhone:
          type: string
          example: +1 555 0100
          nullable: true
        mobilePhone:
          type: string
          example: +1 555 0101
          nullable: true
        homePhone:
          type: string
          example: +1 555 0102
          nullable: true
        address:
          type: string
          example: 12 Foundry Rd
          nullable: true
        city:
          type: string
          example: Springfield
          nullable: true
        stateProvince:
          type: string
          example: IL
          nullable: true
        postalCode:
          type: string
          example: '62704'
          nullable: true
        country:
          nullable: true
          description: Reference into the global country list.
          allOf:
            - $ref: '#/components/schemas/ReferenceDto'
        webPage:
          type: string
          example: https://example.com
          nullable: true
        externalCompanyName:
          type: string
          example: Acme Contracting
          nullable: true
          description: Free-text third-party company name — never a tenant reference.
        nextAvailableDate:
          type: string
          example: '2026-04-01T00:00:00.000Z'
          nullable: true
        inactiveAt:
          type: string
          example: null
          nullable: true
          description: When the person became inactive.
        createdAt:
          type: string
          example: '2026-01-12T08:30:00.000Z'
          nullable: true
        createdById:
          type: string
          example: '88'
          nullable: true
        updatedAt:
          type: string
          example: '2026-03-02T14:00:00.000Z'
          nullable: true
        updatedById:
          type: string
          example: '88'
          nullable: true
      required:
        - id
        - externalId
        - firstName
        - lastName
        - email
        - accessLevel
        - manager
        - isActive
        - jobTitle
        - peopleType
        - orgSchema
        - businessPhone
        - mobilePhone
        - homePhone
        - address
        - city
        - stateProvince
        - postalCode
        - country
        - webPage
        - externalCompanyName
        - nextAvailableDate
        - inactiveAt
        - createdAt
        - createdById
        - updatedAt
        - updatedById
    ProblemDetailsDto:
      type: object
      properties:
        type:
          type: string
          example: https://help.skillsdb.com/api-docs/errors/validation-error
          description: >-
            A URI identifying the problem type — always resolves to a
            documentation page.
        title:
          type: string
          example: Validation failed
        status:
          type: number
          example: 400
        detail:
          type: string
          example: limit must be between 1 and 200
          description: Human-readable explanation specific to this occurrence.
        instance:
          type: string
          example: /api/v1/people
        requestId:
          type: string
          example: 0192c2f1-6f4e-7ab3-b1c4-5f6a7b8c9d0e
          description: >-
            Matches the X-Request-Id response header — quote it when contacting
            support.
        errors:
          description: Field-level failures, present on validation-error problems.
          type: array
          items:
            $ref: '#/components/schemas/ProblemFieldErrorDto'
        error:
          type: string
          example: trial_expired
          enum:
            - trial_expired
          description: >-
            Present only on a 403 when the workspace's trial has expired, so API
            access is suspended.
        upgrade_url:
          type: string
          example: https://app.skillsdb.com/settings/billing
          description: >-
            Present only alongside `error: trial_expired`: where a workspace
            admin upgrades to restore API access.
      required:
        - type
        - title
        - status
        - detail
        - instance
        - requestId
    AccessLevelDto:
      type: object
      properties:
        slug:
          type: string
          example: admin
          description: Stable slug — never the stored integer.
        name:
          type: string
          example: Admin
        isAssignable:
          type: boolean
          example: true
          description: >-
            Whether the level can be assigned. Executive, Global Admin and
            Director are legacy: readable on people who hold them, never
            writable.
      required:
        - slug
        - name
        - isAssignable
    ReferenceDto:
      type: object
      properties:
        id:
          type: string
          example: '42'
          description: Opaque resource id.
        name:
          type: string
          example: Welding
          description: Display name.
      required:
        - id
        - name
    PersonPeopleTypeDto:
      type: object
      properties:
        id:
          type: string
          example: '42'
          description: Opaque resource id.
        name:
          type: string
          example: Welding
          description: Display name.
        expiresAt:
          type: string
          example: '2026-12-31T00:00:00.000Z'
          nullable: true
      required:
        - id
        - name
        - expiresAt
    OrgSchemaDto:
      type: object
      properties:
        businessUnits:
          type: array
          items:
            $ref: '#/components/schemas/ReferenceDto'
        divisions:
          type: array
          items:
            $ref: '#/components/schemas/ReferenceDto'
        businessRegions:
          type: array
          items:
            $ref: '#/components/schemas/ReferenceDto'
        countries:
          type: array
          items:
            $ref: '#/components/schemas/ReferenceDto'
        states:
          type: array
          items:
            $ref: '#/components/schemas/ReferenceDto'
        cities:
          type: array
          items:
            $ref: '#/components/schemas/ReferenceDto'
        sites:
          type: array
          items:
            $ref: '#/components/schemas/ReferenceDto'
        buildings:
          type: array
          items:
            $ref: '#/components/schemas/ReferenceDto'
        departments:
          type: array
          items:
            $ref: '#/components/schemas/ReferenceDto'
        teams:
          type: array
          items:
            $ref: '#/components/schemas/ReferenceDto'
        shifts:
          type: array
          items:
            $ref: '#/components/schemas/ReferenceDto'
      required:
        - businessUnits
        - divisions
        - businessRegions
        - countries
        - states
        - cities
        - sites
        - buildings
        - departments
        - teams
        - shifts
    ProblemFieldErrorDto:
      type: object
      properties:
        field:
          type: string
          example: email
        code:
          type: string
          example: max_length
        message:
          type: string
          example: email must be shorter than or equal to 75 characters
      required:
        - field
        - code
        - message
  securitySchemes:
    apiKey:
      scheme: bearer
      type: http
      description: >-
        An API key issued by a company administrator — an environment prefix
        (production: `sdb_live_`) followed by 32 characters. The prefix
        identifies the environment and MUST NOT be hard-coded or validated by
        clients; treat the whole key as opaque. Shown exactly once at creation;
        only a one-way hash is stored.


        **Scopes** (granted per key on the create screen; `:write` never implies
        `:read`):


        - `skills:read`

        - `skills:write`

        - `people:read`

        - `people:write`

        - `careers:read`

        - `careers:write`

        - `training:read`

        - `training:write`

        - `flags:read`

        - `flags:write`

        - `org:read`

        - `org:write`

        - `assessments:read`

        - `learning:read`

        - `learning:write`

        - `certifications:read`

        - `certifications:write`

        - `assessments:write`

        - `proficiency:read`

        - `proficiency:write`

        - `surveys:read`

        - `surveys:write`

        - `labels:read`

        - `labels:write`

````