Skip to main content
PUT
/
levels
/
{id}
{
  "name": "Staff Engineer",
  "min_salary": 90000,
  "max_salary": 140000
}
{
  "success": true,
  "data": {
    "id": "550e8400-e29b-41d4-a716-446655440000",
    "company_id": "123e4567-e89b-12d3-a456-426614174000",
    "name": "Staff Engineer",
    "hierarchy_level": 3,
    "min_salary": 90000,
    "max_salary": 140000,
    "description": "Senior level individual contributor",
    "created_at": "2024-01-15T10:30:00Z",
    "updated_at": "2024-01-15T14:20:00Z"
  }
}

Authorization

Requires authentication with a Bearer token. Only users with the following roles can update levels:
  • Super Admin
  • HR Manager

Path Parameters

id
string
required
The unique identifier of the level (UUID format)

Request Body

All fields are optional. Only include fields you want to update.
name
string
Name of the level (2-255 characters)
hierarchy_level
integer
Hierarchy level number (minimum 1). Used for ordering levels within the organization.
min_salary
number
Minimum salary for this level (must be non-negative)
max_salary
number
Maximum salary for this level (must be non-negative)
description
string
Description of the level

Response

success
boolean
Indicates if the request was successful
data
object
The updated level object
{
  "name": "Staff Engineer",
  "min_salary": 90000,
  "max_salary": 140000
}
{
  "success": true,
  "data": {
    "id": "550e8400-e29b-41d4-a716-446655440000",
    "company_id": "123e4567-e89b-12d3-a456-426614174000",
    "name": "Staff Engineer",
    "hierarchy_level": 3,
    "min_salary": 90000,
    "max_salary": 140000,
    "description": "Senior level individual contributor",
    "created_at": "2024-01-15T10:30:00Z",
    "updated_at": "2024-01-15T14:20:00Z"
  }
}

HTTP Methods

This endpoint supports both PUT and PATCH methods with the same behavior. Both methods perform partial updates, allowing you to update only the fields you specify.

Error Responses

{
  "success": false,
  "message": "invalid level id"
}
{
  "success": false,
  "message": "unauthorized"
}
{
  "success": false,
  "message": "internal server error"
}

Build docs developers (and LLMs) love