> ## Documentation Index
> Fetch the complete documentation index at: https://docs.getspecs.io/llms.txt
> Use this file to discover all available pages before exploring further.

# Create item field



## OpenAPI

````yaml /openapi.yaml post /item_fields
openapi: 3.0.1
info:
  title: GetSpecs REST API
  description: REST API documentation for GetSpecs.
  version: 1.0.0
servers:
  - url: /v1
  - url: https://demo-api.getspecs.io/v1
security: []
paths:
  /item_fields:
    post:
      tags:
        - ItemField
      summary: Create item field
      operationId: item_fields#create
      parameters: []
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/requestBodyItemFieldCreate'
        required: true
      responses:
        '201':
          description: Created
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/item_field'
        '401':
          description: Unauthorized
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/error'
        '403':
          description: Forbidden
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/error'
        '422':
          description: Unprocessable Entity
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/error'
      security:
        - apiKey: []
          workspaceId: []
components:
  schemas:
    requestBodyItemFieldCreate:
      type: object
      properties:
        name:
          type: string
        description:
          type: string
        field_type:
          type: string
        logic_type:
          type: string
          enum:
            - product_item
            - project_item
          description: >-
            Whether the field belongs to the product (shared by every project
            using it) or to the project item. Defaults to `project_item`;
            areas_list is always `project_item`, and contact cannot be
            `product_item`.
        format:
          type: string
          enum:
            - default
            - currency
          description: >-
            Defaults to `default`. `currency` is allowed for number columns
            only.
        options:
          type: array
          description: >-
            Required for list and multiselect field types. For the contact field
            type, an optional list of company tags the column is restricted to —
            omit or send an empty array for no restriction.
          items:
            type: object
            properties:
              label:
                type: string
              tag:
                type: string
                description: >-
                  For contact columns. Must be one of the workspace's company
                  tags.
      required:
        - name
        - field_type
    item_field:
      type: object
      properties:
        id:
          type: integer
        slug:
          type: string
        name:
          type: string
        description:
          type: string
          nullable: true
        field_type:
          type: string
          enum:
            - number
            - percent
            - string
            - date
            - images
            - docs
            - list
            - multiselect
            - boolean
            - contact
            - item_card
            - quantity
            - areas_list
        format:
          type: string
          enum:
            - default
            - currency
          description: >-
            How the column is displayed. `currency` (number columns only) shows
            the row's currency — the project's for project items, the
            workspace's for product items.
        options:
          type: array
          nullable: true
          items:
            type: object
            properties:
              key:
                type: string
              label:
                type: string
              archived:
                type: boolean
              slug:
                type: string
                nullable: true
              tag:
                type: string
                nullable: true
                description: >-
                  For contact columns — a company tag the column is restricted
                  to.
        bulk_update:
          type: boolean
        sortable:
          type: boolean
        position:
          type: integer
        association_type:
          type: string
          nullable: true
        editable:
          type: boolean
        deletable:
          type: boolean
        deleted_at:
          type: string
          format: date-time
          nullable: true
    error:
      type: object
      properties:
        error:
          type: string
        errors:
          type: array
          items:
            type: object
            properties:
              field:
                type: string
                nullable: true
              code:
                type: string
                nullable: true
              message:
                type: string
            required:
              - message
  securitySchemes:
    apiKey:
      type: apiKey
      name: authorization
      in: header
    workspaceId:
      type: apiKey
      name: X-Workspace-ID
      in: header

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.