---
title: "OnlineFormTypes.create"
method: POST
path: "/entities/OnlineFormTypes"
tags: ["Online Form"]
---

# OnlineFormTypes.create

`POST /entities/OnlineFormTypes`

## Request

- Base URL: `https://us-east.api.coevera.com/api/v100/rest/spaces/your_space_id`
- URL: `https://us-east.api.coevera.com/api/v100/rest/spaces/your_space_id/entities/OnlineFormTypes`
- Auth: HTTP basic
- TypeScript: <https://skmtc.dev/coevera/apis/coevera-crm-api/docs/entities/OnlineFormTypes/post.ts> (a function with typed inputs; its response is checked against the schema)

Creates a OnlineFormType record.

## Query parameters

- `validation-level` integer

## Request body

- CreateOnlineFormTypeInput: Field values of a new OnlineFormType record.
  - `modified` string, date-time: Last modification time.
  - `created` string, date-time: Creation time.
  - `auto_prefill_with_javascript` boolean: When true, the embedded form JavaScript pre-fills fields from URL query parameters on load.
  - `description` string: Free-text description shown alongside the form definition in the UI.
  - `entity_api_name` string: API name of the custom entity the form targets. Set only when entity_type is CustomEntity; otherwise empty.
  - `entity_type` 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12, required: Entity the form is built for: its fields can be placed on the form and each submission is linked to a record of this entity. For custom entities, entity_api_name identifies the custom entity. Integer enum value: 1 - Lead, 2 - Account, 3 - Contact, 4 - Opportunity, 5 - Task, 6 - Appointment, 7 - OpptyProductRelation, 8 - Project, 9 - Quote, 10 - OnlineForm, 11 - CustomEntity, 12 - Product
  - `form_edit` object, required: Definition of the form layout (fields, sections, settings) shown to respondents, as a JSON object conforming to the online-form layout schema. Validated on write. This payload conforms to the `OnlineForm` JSON Schema (see the linked schema).
  - `is_enabled` boolean, required: When true, the form is published and accepts new submissions; when false, the form returns an error to respondents.
  - `is_readonly` boolean, required: True when the form is system-managed and its schema cannot be edited by users.
  - `last_schema_change` string, date-time: Timestamp of the most recent change to form_edit (form schema).
  - `last_status_change` string, date-time: Timestamp of the most recent change to is_enabled.
  - `name` string, required: Name of the entity and its default text representation.
  - `notifications_status` object: Tracks which threshold-reached notifications have already been sent for the current form configuration. Reset when the configuration changes.
  - `owner_id` string, uuid, required: Id of the owning user.
  - `style_id` string, uuid, required: Id of the form style.
  - `revision` integer: Revision when entity was lastly changed.
  - `custom_recaptcha` string, binary, required: Custom reCAPTCHA keys (site_key and secret_key) used on the forms of this type instead of the platform default; null switches back to the default. Write-only; has_custom_recaptcha tells whether keys are set.

## Response `201`

The created OnlineFormType record.

- object
  - `success` boolean: True when the request succeeded; false on error.
  - `data` OnlineFormType: Online form definition: the fields and settings of a web form whose submissions create or update records.
    - `has_draft` boolean, required: True when the record has unpublished draft changes, including pending translation changes, that can be published.
    - `is_delete_protected` boolean, required: True when the record is protected against deletion because it must always exist in the space. Deleting a record that is not protected can still fail on other checks. Read-only.
    - `form_edit_api` object, required: Typed, read-only view of the online form definition (form_edit): its fields, layout and settings.
    - `can_change_readonly` boolean: False for types whose read-only setting is fixed, such as the recurrent appointment type; true otherwise.
    - `id` string, uuid, required: Unique identifier of entity.
    - `is_deleted` boolean: Specifies if the entity is considered deleted.
    - `modified` string, date-time: Last modification time.
    - `created` string, date-time: Creation time.
    - `owner` string, uri, required: User who owns the online form. Related Client record, returned as the URI of the record. With the 'expand' parameter the full record is returned instead; see 'Client' for its fields.
    - `style` string, uri, required: Visual style applied to the form when rendered. Related OnlineFormStyle record, returned as the URI of the record. With the 'expand' parameter the full record is returned instead; see 'OnlineFormStyle' for its fields.
    - `auto_prefill_with_javascript` boolean: When true, the embedded form JavaScript pre-fills fields from URL query parameters on load.
    - `description` string: Free-text description shown alongside the form definition in the UI.
    - `entity_api_name` string: API name of the custom entity the form targets. Set only when entity_type is CustomEntity; otherwise empty.
    - `entity_type` 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12, required: Entity the form is built for: its fields can be placed on the form and each submission is linked to a record of this entity. For custom entities, entity_api_name identifies the custom entity. Integer enum value: 1 - Lead, 2 - Account, 3 - Contact, 4 - Opportunity, 5 - Task, 6 - Appointment, 7 - OpptyProductRelation, 8 - Project, 9 - Quote, 10 - OnlineForm, 11 - CustomEntity, 12 - Product
    - `form_edit` object, required: Definition of the form layout (fields, sections, settings) shown to respondents, as a JSON object conforming to the online-form layout schema. Validated on write. This payload conforms to the `OnlineForm` JSON Schema (see the linked schema).
    - `is_enabled` boolean, required: When true, the form is published and accepts new submissions; when false, the form returns an error to respondents.
    - `is_readonly` boolean, required: True when the form is system-managed and its schema cannot be edited by users.
    - `last_schema_change` string, date-time: Timestamp of the most recent change to form_edit (form schema).
    - `last_status_change` string, date-time: Timestamp of the most recent change to is_enabled.
    - `name` string, required: Name of the entity and its default text representation.
    - `notifications_status` object: Tracks which threshold-reached notifications have already been sent for the current form configuration. Reset when the configuration changes.
    - `owner_id` string, uuid, required: Id of the owning user.
    - `style_id` string, uuid, required: Id of the form style.
    - `revision` integer: Revision when entity was lastly changed.
    - `activity_logs` string[]: Submissions (one per response) recorded for this form.
    - `link_id` string, required: Short identifier used in the public form URL (see link). Stable across the lifetime of the form.
    - `summarized_response_values` integer: Sum of response values used to evaluate the response acceptance threshold (e.g. total responses, or evaluated value of the custom acceptance condition). Empty when no threshold is configured.
    - `link` string: Public URL for accessing the form (suitable for sharing with respondents).
    - `has_custom_recaptcha` boolean, required: True when the form is configured with custom reCAPTCHA credentials; false when using the platform default reCAPTCHA setup.

## Other responses

- `400`: Bad request: a bad or unknown parameter (codes 117, 118), a missing permission (code 50), conflicting data (code 2002) or any other API error. The REST API answers 400 where others answer 403 or 409; check `code`.
- `401`: Not authenticated: missing or wrong credentials, a credential of another space, or an expired token (code 401, ERROR_UNAUTHORIZED).
- `422`: Validation failed (code 40000, with the failing fields) or a required parameter is missing (code 119). By default one failed item fails a whole batch and nothing is written.
- `429`: Too many requests (code 182). Wait for the seconds in Retry-After, then retry.
- `500`: Unexpected server error (code 1000, ERROR_UNKNOWN).

---

[API](https://skmtc.dev/coevera/apis/coevera-crm-api.md) - [All operations](https://skmtc.dev/coevera/apis/coevera-crm-api/llms.txt) - [OpenAPI document](https://skmtc.dev/coevera/apis/coevera-crm-api/revisions/40ebbc83f179?raw)
