# Text

Open-ended text input. The `text.subType` field determines whether the question is a short text, long text, or masked text field.

See the [Short Text field](https://forms.app/en/help-center/short-text) help article for builder options like min/max length, placeholder, and default values.

## Short text

Best for brief, open-ended answers.

| Field | Type | Description |
|  --- | --- | --- |
| `text.subType` | `"shorttext"` | Single-line text input |
| `text.minLength` | number | Minimum character count |
| `text.maxLength` | number | Maximum character count |


```json
{
  "_id": "6a0ef62a3affac35058b05a9",
  "questionType": "text",
  "question": "Short text field title",
  "placeholder": "Short Text Question Placeholder",
  "displayOrder": 4,
  "isRequired": true,
  "isDeleted": false,
  "isActive": true,
  "description": "Short text Helper text",
  "text": {
    "subType": "shorttext",
    "minLength": 400,
    "maxLength": 30
  }
}
```

## Long text

Multi-line input for longer, detailed responses.

| Field | Type | Description |
|  --- | --- | --- |
| `text.subType` | `"longtext"` | Multi-line text area |


```json
{
  "_id": "6a0ef64c3affac35058b05aa",
  "questionType": "text",
  "question": "Long text field title",
  "displayOrder": 5,
  "isRequired": false,
  "isDeleted": false,
  "isActive": true,
  "description": "Long text Helper text",
  "text": {
    "subType": "longtext"
  }
}
```

## Masked text

Forces input to match a pattern. Each `@` in the mask represents one character.

| Field | Type | Description |
|  --- | --- | --- |
| `text.subType` | `"maskedtext"` | Pattern-constrained text input |
| `text.maskPattern` | string | Input mask (for example, `"@@@"`) |


```json
{
  "_id": "6a0ef8603affac35058b0796",
  "questionType": "text",
  "question": "Ask your question here",
  "displayOrder": 13,
  "isRequired": false,
  "isDeleted": false,
  "isActive": true,
  "text": {
    "subType": "maskedtext",
    "maskPattern": "@@@"
  }
}
```