---
title: "List pending forms"
method: GET
path: "/api/form"
tags: ["form"]
---

# List pending forms

`GET /api/form`

## Request

- Base URL: `https://opencode.ai` (the document declares no server; this is the origin it was published from)
- URL: `https://opencode.ai/api/form`
- Auth: none required

Retrieve pending forms for a location.

## Query parameters

- `location` object, nullable
  - `directory` string, nullable

## Response `200`

Success

- object
  - `location` LocationPublicRef, required
    - `directory` string, required
  - `data` FormInfo[], required
    - `id` string, required
    - `sessionID` string, required
    - `title` string, required
    - `metadata` FormMetadata
    - `fields` FormField[], required
      - union
        - FormStringField
          - `key` string, required
          - `title` string
          - `description` string
          - `required` boolean
          - `hidden` boolean
          - `when` FormWhen[]
            - `key` string, required
            - `op` 'eq' | 'neq', required
            - `value` union, required
              - …
          - `type` 'string', required
          - `format` 'email' | 'uri' | 'date' | 'date-time'
          - `minLength` integer
          - `maxLength` integer
          - `pattern` string
          - `placeholder` string
          - `default` string
          - `options` FormOption[]
            - `value` string, required
            - `label` string, required
            - `description` string
          - `custom` boolean
        - FormNumberField
          - `key` string, required
          - `title` string
          - `description` string
          - `required` boolean
          - `hidden` boolean
          - `when` FormWhen[]
            - `key` string, required
            - `op` 'eq' | 'neq', required
            - `value` union, required
              - …
          - `type` 'number', required
          - `minimum` union
            - number
            - 'Infinity' | '-Infinity' | 'NaN'
          - `maximum` union
            - number
            - 'Infinity' | '-Infinity' | 'NaN'
          - `default` union
            - number
            - 'Infinity' | '-Infinity' | 'NaN'
        - FormIntegerField
          - `key` string, required
          - `title` string
          - `description` string
          - `required` boolean
          - `hidden` boolean
          - `when` FormWhen[]
            - `key` string, required
            - `op` 'eq' | 'neq', required
            - `value` union, required
              - …
          - `type` 'integer', required
          - `minimum` union
            - number
            - 'Infinity' | '-Infinity' | 'NaN'
          - `maximum` union
            - number
            - 'Infinity' | '-Infinity' | 'NaN'
          - `default` union
            - number
            - 'Infinity' | '-Infinity' | 'NaN'
        - FormBooleanField
          - `key` string, required
          - `title` string
          - `description` string
          - `required` boolean
          - `hidden` boolean
          - `when` FormWhen[]
            - `key` string, required
            - `op` 'eq' | 'neq', required
            - `value` union, required
              - …
          - `type` 'boolean', required
          - `default` boolean
        - FormMultiselectField
          - `key` string, required
          - `title` string
          - `description` string
          - `required` boolean
          - `hidden` boolean
          - `when` FormWhen[]
            - `key` string, required
            - `op` 'eq' | 'neq', required
            - `value` union, required
              - …
          - `type` 'multiselect', required
          - `options` FormOption[], required
            - `value` string, required
            - `label` string, required
            - `description` string
          - `minItems` integer
          - `maxItems` integer
          - `custom` boolean
          - `default` string[]
        - FormExternalField
          - `key` string, required
          - `type` 'external', required
          - `url` string, required
          - `title` string
          - `description` string

## Other responses

- `400`: InvalidRequestError
- `401`: UnauthorizedError
- `404`: LocationNotFoundError

---

[API](https://skmtc.dev/kaaass/apis/opencode.md) - [All operations](https://skmtc.dev/kaaass/apis/opencode/llms.txt) - [OpenAPI document](https://skmtc.dev/kaaass/apis/opencode/revisions/4e083d954707?raw)
