---
title: "Get Form"
method: POST
path: "/form/{id}/get-item"
tags: ["Form"]
---

# Get Form

`POST /form/{id}/get-item`

## Request

- Base URL: `https://oneuptime.com/api`
- URL: `https://oneuptime.com/api/form/{id}/get-item`
- Auth: API key in header `APIKey`
- TypeScript: <https://skmtc.dev/oneuptime/apis/oneuptime-openapi-specification/docs/form/:id/get-item/post.ts> (a function with typed inputs; its response is checked against the schema)

Endpoint to retrieve a single Form by ID

## Path parameters

- `id` string, uuid, required

## Request body

- object
  - `select` FormSelectSchema: Select schema for Form. Set fields to true to include them in the response.
    - `_id` boolean
    - `createdAt` boolean
    - `updatedAt` boolean
    - `deletedAt` boolean
    - `projectId` boolean
    - `name` boolean
    - `description` boolean
    - `isEnabled` boolean
    - `shareKey` boolean
    - `targetType` boolean
    - `fields` boolean
    - `templates` boolean
    - `targetSettings` boolean
    - `successMessage` boolean
    - `ipWhitelist` boolean
    - `logoFileId` boolean
    - `logoAltText` boolean
    - `faviconFileId` boolean
    - `createdByUserId` boolean

## Response `200`

Successful response

- object
  - `data` Form
    - `_id` string, uuid: ID of this object. Permissions - Create: [Project Owner, Project Admin, Create Form], Read: [Project Owner, Project Admin, Project Member, Viewer, Incident Admin, Incident Member, Incident Viewer, Scheduled Maintenance Admin, Scheduled Maintenance Member, Scheduled Maintenance Viewer, Read Form], Update: [Project Owner, Project Admin, Edit Form]
    - `createdAt` object: Date and Time when the object was created. Permissions - Create: [Project Owner, Project Admin, Create Form], Read: [Project Owner, Project Admin, Project Member, Viewer, Incident Admin, Incident Member, Incident Viewer, Scheduled Maintenance Admin, Scheduled Maintenance Member, Scheduled Maintenance Viewer, Read Form], Update: [Project Owner, Project Admin, Edit Form]
    - `updatedAt` object: Date and Time when the object was updated. Permissions - Create: [Project Owner, Project Admin, Create Form], Read: [Project Owner, Project Admin, Project Member, Viewer, Incident Admin, Incident Member, Incident Viewer, Scheduled Maintenance Admin, Scheduled Maintenance Member, Scheduled Maintenance Viewer, Read Form], Update: [Project Owner, Project Admin, Edit Form]
    - `deletedAt` object: Date and Time when the object was deleted. Permissions - Create: [Project Owner, Project Admin, Create Form], Read: [Project Owner, Project Admin, Project Member, Viewer, Incident Admin, Incident Member, Incident Viewer, Scheduled Maintenance Admin, Scheduled Maintenance Member, Scheduled Maintenance Viewer, Read Form], Update: [Project Owner, Project Admin, Edit Form]
    - `version` number: Object version
    - `projectId` string, uuid, required: ID of your OneUptime Project in which this object belongs. Permissions - Create: [Project Owner, Project Admin, Create Form], Read: [Project Owner, Project Admin, Project Member, Viewer, Incident Admin, Incident Member, Incident Viewer, Scheduled Maintenance Admin, Scheduled Maintenance Member, Scheduled Maintenance Viewer, Read Form], Update: [No access - you don't have permission for this operation]
    - `name` string, required: The form's name, shown as the heading of its public page. Unique within the project. Permissions - Create: [Project Owner, Project Admin, Create Form], Read: [Project Owner, Project Admin, Project Member, Viewer, Incident Admin, Incident Member, Incident Viewer, Scheduled Maintenance Admin, Scheduled Maintenance Member, Scheduled Maintenance Viewer, Read Form], Update: [Project Owner, Project Admin, Edit Form]
    - `description` string: Shown at the top of the form's public page, above the questions: what the form is for and what happens after it is sent. Markdown. Permissions - Create: [Project Owner, Project Admin, Create Form], Read: [Project Owner, Project Admin, Project Member, Viewer, Incident Admin, Incident Member, Incident Viewer, Scheduled Maintenance Admin, Scheduled Maintenance Member, Scheduled Maintenance Viewer, Read Form], Update: [Project Owner, Project Admin, Edit Form]
    - `isEnabled` boolean, required: Whether the form's link works. While it is off, the public page shows a not-available message and nothing can be submitted. Permissions - Create: [Project Owner, Project Admin, Create Form], Read: [Project Owner, Project Admin, Project Member, Viewer, Incident Admin, Incident Member, Incident Viewer, Scheduled Maintenance Admin, Scheduled Maintenance Member, Scheduled Maintenance Viewer, Read Form], Update: [Project Owner, Project Admin, Edit Form]
    - `shareKey` string, uuid: The key in the form's public link, /accounts/form/<shareKey>. Generated when the form is created. Resetting the link in the dashboard replaces it, and the old link stops working. Permissions - Create: [No access - you don't have permission for this operation], Read: [Project Owner, Project Admin, Project Member, Viewer, Incident Admin, Incident Member, Incident Viewer, Scheduled Maintenance Admin, Scheduled Maintenance Member, Scheduled Maintenance Viewer, Read Form], Update: [Project Owner, Project Admin, Edit Form]
    - `targetType` 'Incident' | 'ScheduledMaintenance', required: What each submission creates: Incident, or ScheduledMaintenance (a scheduled maintenance event). Permissions - Create: [Project Owner, Project Admin, Create Form], Read: [Project Owner, Project Admin, Project Member, Viewer, Incident Admin, Incident Member, Incident Viewer, Scheduled Maintenance Admin, Scheduled Maintenance Member, Scheduled Maintenance Viewer, Read Form], Update: [Project Owner, Project Admin, Edit Form]
    - `fields` object: The questions the form asks, in order. Each has an id, a source (Question: one of the form's own, answered by type; TargetField: a built-in field of what the form creates, by targetField; TargetCustomField: one of its custom fields, by customFieldId; Submitter: the submitter's Name or Email), a label, optional help text, isRequired and isHidden (not shown on the public form unless the template a submission starts from asks it, and otherwise answered only from the template a submission started from; never required, and never a field the target cannot be created without). isRequired and isHidden are the form's default: each template can make a question Required, Optional or Hidden (its fieldSettings). A new form starts with a title, a description and the submitter's name and email. Permissions - Create: [Project Owner, Project Admin, Create Form], Read: [Project Owner, Project Admin, Project Member, Viewer, Incident Admin, Incident Member, Incident Viewer, Scheduled Maintenance Admin, Scheduled Maintenance Member, Scheduled Maintenance Viewer, Read Form], Update: [Project Owner, Project Admin, Edit Form]
    - `templates` object: Named sets of answers a submission can start from, in the order the form lists them. Each has an id, a name (unique within the form), isDefault (the form opens with it; at most one template), answers: an object keyed by question id, each answer as a submission sends it - text, a number, true or false, an option's value, or a list of values for a multi-select - and fieldSettings: an object keyed by question id that makes a question Required, Optional or Hidden when a submission starts from the template; a question it does not list is asked as the form asks it, and a question the form cannot create its record without is always asked and required. The public form lists the templates above its questions and fills in a template's answers when one is chosen, or when its link names one (?template=<id>). A question the submission was not asked - hidden by the form or by the template - is answered only from the template a submission started from. Permissions - Create: [Project Owner, Project Admin, Create Form], Read: [Project Owner, Project Admin, Project Member, Viewer, Incident Admin, Incident Member, Incident Viewer, Scheduled Maintenance Admin, Scheduled Maintenance Member, Scheduled Maintenance Viewer, Read Form], Update: [Project Owner, Project Admin, Edit Form]
    - `targetSettings` object: What every submission starts with besides the answers. For incidents: defaultTitle, incidentSeverityId, incidentTemplateId, monitorIds, labelIds, onCallDutyPolicyIds, ownerUserIds and ownerTeamIds. For scheduled maintenance events: defaultTitle, monitorIds, statusPageIds, labelIds, ownerUserIds, ownerTeamIds, showOnStatusPages and notifySubscribers. Permissions - Create: [Project Owner, Project Admin, Create Form], Read: [Project Owner, Project Admin, Project Member, Viewer, Incident Admin, Incident Member, Incident Viewer, Scheduled Maintenance Admin, Scheduled Maintenance Member, Scheduled Maintenance Viewer, Read Form], Update: [Project Owner, Project Admin, Edit Form]
    - `successMessage` string: Shown after the form is submitted, together with the number of what the submission created. Markdown. Permissions - Create: [Project Owner, Project Admin, Create Form], Read: [Project Owner, Project Admin, Project Member, Viewer, Incident Admin, Incident Member, Incident Viewer, Scheduled Maintenance Admin, Scheduled Maintenance Member, Scheduled Maintenance Viewer, Read Form], Update: [Project Owner, Project Admin, Edit Form]
    - `ipWhitelist` string: The networks the form can be opened and submitted from: one IPv4 or IPv6 address, or one IPv4 range in CIDR notation (such as 10.0.0.0/8), per line. IPv6 ranges are not supported. Leave it empty to allow any network. Permissions - Create: [Project Owner, Project Admin, Create Form], Read: [Project Owner, Project Admin, Project Member, Viewer, Incident Admin, Incident Member, Incident Viewer, Scheduled Maintenance Admin, Scheduled Maintenance Member, Scheduled Maintenance Viewer, Read Form], Update: [Project Owner, Project Admin, Edit Form]
    - `logoFileId` string, uuid: ID of the file the form's public page shows as its logo: upload the image to /api/file first. Leave it empty to show the OneUptime logo. Permissions - Create: [Project Owner, Project Admin, Create Form], Read: [Project Owner, Project Admin, Project Member, Viewer, Incident Admin, Incident Member, Incident Viewer, Scheduled Maintenance Admin, Scheduled Maintenance Member, Scheduled Maintenance Viewer, Read Form], Update: [Project Owner, Project Admin, Edit Form]
    - `logoAltText` string: What the logo says, read out by screen readers: usually your organization's name. Leave it empty and screen readers skip the logo. Permissions - Create: [Project Owner, Project Admin, Create Form], Read: [Project Owner, Project Admin, Project Member, Viewer, Incident Admin, Incident Member, Incident Viewer, Scheduled Maintenance Admin, Scheduled Maintenance Member, Scheduled Maintenance Viewer, Read Form], Update: [Project Owner, Project Admin, Edit Form]
    - `faviconFileId` string, uuid: ID of the file the form's public page shows as the browser tab's icon: upload the image to /api/file first. Leave it empty to show the OneUptime favicon. Permissions - Create: [Project Owner, Project Admin, Create Form], Read: [Project Owner, Project Admin, Project Member, Viewer, Incident Admin, Incident Member, Incident Viewer, Scheduled Maintenance Admin, Scheduled Maintenance Member, Scheduled Maintenance Viewer, Read Form], Update: [Project Owner, Project Admin, Edit Form]
    - `createdByUserId` string, uuid: User ID who created this object (if this object was created by a User). Permissions - Create: [No access - you don't have permission for this operation], Read: [Project Owner, Project Admin, Project Member, Viewer, Incident Admin, Incident Member, Incident Viewer, Scheduled Maintenance Admin, Scheduled Maintenance Member, Scheduled Maintenance Viewer, Read Form], Update: [No access - you don't have permission for this operation]

## Other responses

- `400`: Bad request. This response indicates that the request was malformed or contained invalid data.
- `401`: Unauthorized. This response indicates that the request requires user authentication.
- `402`: Payment Required. This response indicates that the request requires payment or a valid subscription.
- `403`: Forbidden. This response indicates that the server understood the request, but refuses to authorize it.
- `404`: Not found. The record does not exist, belongs to another project, or is one you may not read - the same answer for each.
- `405`: Project not found. This response indicates that the requested project does not exist or is not accessible.
- `408`: Request Timeout. This response indicates that the server timed out waiting for the request.
- `415`: Unable to reach server. This response indicates that the server is currently unreachable or down.
- `422`: Not authorized. This response indicates that the user does not have permission to access the requested resource.
- `500`: Internal Server Error. This response indicates that the server encountered an unexpected condition that prevented it from fulfilling the request.

---

[API](https://skmtc.dev/oneuptime/apis/oneuptime-openapi-specification.md) - [All operations](https://skmtc.dev/oneuptime/apis/oneuptime-openapi-specification/llms.txt) - [OpenAPI document](https://skmtc.dev/oneuptime/apis/oneuptime-openapi-specification/revisions/ba3307d00304?raw)
