Contract Intelligence

Create a saved view

Create a saved view in a vault. The view is shared with the whole vault the moment it exists: anyone who can read the vault can open it, and anyone with the Manage Views permission can change or delete it.

Column visibility is stored as a hide list. hidden_field_keys names the columns a view hides, so an empty list means the view shows every column the vault has. A column added to the vault later appears in the view until you hide it.

Every field key has to exist in the vault. Keys in hidden_field_keys and field_order can also name a system column (actions, fileName, relationships, extractedAt, sourceName). sort.field takes a vault column or one of fileName, extractedAt, sourceName, because those are the only system columns the table can sort by. A filter field_key takes a vault column or __notes__, the any-column notes filter. Anything else returns 400 naming the keys it could not place, rather than being dropped on the way in and leaving you with a view that ignores half of what you sent.

View names are unique within a vault once trimmed, and the comparison is case sensitive, so Renewals and renewals can both exist. A name already taken returns 409.

Requires the editor or owner role in the vault, the organization-level permission to manage vaults, and the organization-level Manage Views permission. A caller who holds the vault role but not both permissions gets 403.

Requires a user-scoped API key (u:gcai_...). A vault is shared with named people, so an organization-scoped key has no identity to resolve vault access with.

post/vaults/{id}/views

Request

Path parameters

idstring uuid required

The vault ID

Request body

namestring required

View name. Trimmed before it is stored, and unique within the vault.

Example request

{
  "name": "Renewals this quarter",
  "view_state": {
    "sort": {
      "field": "effectiveDate"
    },
    "filters": [
      {
        "field_key": "governingLaw"
      }
    ]
  }
}

Response

The created view

idstring uuid required

Unique view identifier

vault_idstring uuid required

Vault this view belongs to

namestring required

View name, as shown on its tab in the app

positioninteger required

Zero-based slot this view occupies in the vault view order. Read-only over the API: reordering views is not available here yet.

created_by_user_idinteger nullable required

GC AI user ID of whoever created the view, or null when that person has since been removed. Provenance only: a view is shared with the whole vault and is not owned by its creator.

created_atstring required

ISO 8601 creation timestamp

updated_atstring required

ISO 8601 last-update timestamp

Example response

{
  "name": "Renewals this quarter",
  "view_state": {
    "sort": {
      "field": "effectiveDate"
    },
    "filters": [
      {
        "field_key": "governingLaw"
      }
    ]
  }
}

Changes

No recorded changes to this operation across all 1 revision of this API.