POST
/api/public/v1/benefits

Create a benefit

Adds something to the catalog. Enroll people with the employee benefits endpoint.

Required scope

The access token must carry this scope. A token missing it gets 403 Forbidden. Grant them to an API client under Settings → Company → API, and to a teammate under Employee → Permissions.

hr:write

Request Body

PropertyTypeDescription
namestringWhat it is called.
descriptionstringWhat it covers.
POSTExample request
curl
curl -X POST "https://www.pxb.app/api/public/v1/benefits" \
  -H "Authorization: Bearer your_access_token" \
  -H "Content-Type: application/json" \
  -d '{
    "name": "Health insurance",
    "description": "Medical, dental and vision."
  }'
200Example response
json
{
  "message": "Benefit created successfully!",
  "content": {
    "benefit": {
      "id": "ben_08de",
      "name": "Health insurance",
      "description": "Medical, dental and vision.",
      "createdAt": "2026-01-04T09:00:00.000Z",
      "updatedAt": "2026-01-04T09:00:00.000Z"
    }
  }
}

In the console

The same thing done by hand, for anyone comparing the API against the screen they already use.

Employees → Benefits
/employee/benefits