Skip to content
Leadtime
English
Esc
navigateopen⌘Jpreview

Create object custom field (admin)

POST/administration/object-custom-fields
Authorization
AuthorizationOAuth2 access token · headerrequired
Scopes:api:write
or
AuthorizationBearer token (JWT) · headerrequired
Query parameters
fieldsToReturnstring
Comma-separated list of top-level response fields to return. Overrides the endpoint compact default unless responseShape=full is used.
responseShapestring
Advanced override. Omit for the endpoint compact default. Use full only when you need the complete endpoint response, including nested fields that are not selectable with fieldsToReturn.
Allowed:compactfull
Header parameters
LT-Response-Shapestring
Advanced override. Set to full only when you need the complete endpoint response, including nested fields that are not selectable with fieldsToReturn.
Allowed:full
Request body
requiredapplication/json
descriptionstring
idstring
namestringrequired
objectTypeIdstringrequired
Must be the object type this field belongs to
selectOptionsFieldOptionPublicDto[]
Show properties
Array of FieldOptionPublicDto
idobjectrequired
translationsCustomFieldTranslationPublicDto[]required
Show properties
Array of CustomFieldTranslationPublicDto
languagestringrequired
namestringrequired
valuestringrequired
showInHeaderboolean
showInListboolean
translationsCustomFieldTranslationPublicDto[]required
Show properties
Array of CustomFieldTranslationPublicDto
languagestringrequired
namestringrequired
translationsDescriptionsCustomFieldTranslationPublicDto[]required
Show properties
Array of CustomFieldTranslationPublicDto
languagestringrequired
namestringrequired
typestringrequired
Allowed:TextTextareaNumberDateCheckboxSelectMultiSelectCurrencyUrl
Responses
200
descriptionstringrequired
entitystringrequired
Allowed:TaskProjectOrganizationObject
idstringrequired
namestringrequired
objectTypeIdstringrequired
selectOptionsany[]required
showInHeaderbooleanrequired
showInListbooleanrequired
sortnumberrequired
translationsany[]required
typestringrequired
Allowed:TextTextareaNumberDateCheckboxSelectMultiSelectCurrencyUrl
401Unauthorized - Invalid or missing authentication token
403Forbidden - Insufficient API scopes or permissions
Request
curl -X POST "https://leadtime.app/api/public/administration/object-custom-fields" \
  -H "Authorization: Bearer YOUR_ACCESS_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
  "description": "string",
  "id": "string",
  "name": "string",
  "objectTypeId": "string",
  "selectOptions": [
    {
      "id": {},
      "translations": [
        {
          "language": "string",
          "name": "string"
        }
      ],
      "value": "string"
    }
  ],
  "showInHeader": true,
  "showInList": true,
  "translations": [
    {
      "language": "string",
      "name": "string"
    }
  ],
  "translationsDescriptions": [
    {
      "language": "string",
      "name": "string"
    }
  ],
  "type": "Text"
}'
Response
{
  "description": "string",
  "entity": "Task",
  "id": "string",
  "name": "string",
  "objectTypeId": "string",
  "selectOptions": [
    null
  ],
  "showInHeader": true,
  "showInList": true,
  "sort": 0,
  "translations": [
    null
  ],
  "type": "Text"
}