Add Project Custom Fields

POST /api/v1.0/projects/{project_id}/fields

This endpoint creates the custom fields for the project.

application/json

Body Required

  • field_id string

    field_id

  • name string Required

    Custom field name

  • description

  • type string Required

    Custom field type

    Values are dropdown, text, reminder, number, url, phone, email, location, currency, checkbox, budget, calc, date, user, or datesdiff.

  • currency string

    Currency

  • Tracking Type

    Values are auto or manual.

  • Cost per hour

  • options array[object] Required
    Hide options attributes Show options attributes object
    • value string Required

      Custom field option value

    • color string Required

      Custom field option color

  • roles array[string] Required

    Roles

  • save boolean

    Save

  • Association

  • Project ID

Responses

  • The resource created successfully

  • The client request has not been completed because it lacks valid authentication credentials for the requested resource.

  • The client does not have access rights to the content.

  • The request method is known by the server but is not supported by the target resource.

POST /api/v1.0/projects/{project_id}/fields
curl \
 --request POST 'https://openapi.niftypm.com/api/v1.0/projects/{project_id}/fields' \
 --header "Content-Type: application/json" \
 --data '{"field_id":"string","name":"string","description":"string","type":"dropdown","currency":"string","tracking_type":"auto","cost_per_hour":42.0,"options":[{"value":"string","color":"string"}],"roles":["string"],"save":true,"association":"string","project_id":"string"}'
Request examples
{
  "field_id": "string",
  "name": "string",
  "description": "string",
  "type": "dropdown",
  "currency": "string",
  "tracking_type": "auto",
  "cost_per_hour": 42.0,
  "options": [
    {
      "value": "string",
      "color": "string"
    }
  ],
  "roles": [
    "string"
  ],
  "save": true,
  "association": "string",
  "project_id": "string"
}