Skip to content

Create a functional area type

Request

Adds a category that functional areas can be filed under. Point a functional area at it with headcount_functional_area_type_id on the create or update endpoint for that area.

A type created without sort_order comes back without that field, rather than with its stored default of 0. Read the type back if you need its complete state.

Security
default
Headers
Rosterfy-Platformstring
Bodyapplication/jsonrequired
namestringrequired

The name of the group type. Required. Sending a plain string sets the name for the account's default language; it is returned as a plain string in the language of the request.

sort_orderinteger

Where this type sits when types are listed together. Lower values come first, and types sharing a value keep no guaranteed order between them. Defaults to 0.

curl -i -X POST \
  https://developer.rosterfy.com/_mock/api-docs/openapi/api/v2/headcount/functionalarea/type \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
  -H 'Content-Type: application/json' \
  -H 'Rosterfy-Platform: admin' \
  -d '{
    "name": "Operations",
    "sort_order": 1
  }'

Responses

Bodyapplication/json
objectobject
niceArray of any
relationsArray of any
permissionsobject
Response
{ "object": { "id": 1, "name": "Operations", "sort_order": 1, "uuid": "f5d2192c-e3b6-4162-8e6c-5bc6f65900e9" }, "nice": [], "relations": [], "permissions": { "read": true, "update": true, "delete": true } }