Skip to main content
Account

Create metadata

<small>Requires an API token with the Metadata Manager role.</small>

POST
/metadata

Creates a new account-level metadata field definition.

Note that the name and value_type sent in this request are fixed at the time of creation and cannot be changed later.

Authorizationstringheaderrequired

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

application/json
descriptionstring | null

A description of the metadata field.

Maximum string length: 1024
Example: The discount rate applied to the company valuation in a follow-on financing round.
display_namestringrequired

The display name shown in the UI.

Maximum string length: 255
Example: Discount Rate
is_contract_valueboolean | null

Whether this is a contract value field. Can only be true when value_type is currency or currency_duration.

keywordsstring | null

Keywords to help with metadata identification.

Maximum string length: 1024
Example: discount, rate, valuation
namestringrequired

The programmatic name. Cannot be changed after creation. Must be lowercase alphanumeric with underscores only. Must be unique within the account and must not conflict with system metadata names.

Maximum string length: 255
Pattern: ^[a-z0-9_]+$
Example: discount_rate
promptstring | null

An AI prompt used for metadata extraction.

Maximum string length: 1024
Example: Extract the discount rate percentage from the document.
relevant_document_type_uuidsstring[] | null

UUIDs of document types this metadata is relevant for. null means not relevant to any document types. [] (empty array) means relevant to all document types.

select_valuesstring[] | null

The possible values when value_type is select or multi_select.

value_typeenum<string>required

Controls what kinds of values may be stored in the field. Cannot be changed after creation

Available options: id, uuid, bool, date, duration, email, list, number, currency, currency_duration, clause, select, multi_select, text, textarea, timestamp, array, enum
Example: text

Response

application/json

MetadataResource

dataobjectrequired