Skip to main content
POST
Create Attribute

Authorizations

Authorization
string
header
required

Aspect API key (sk_...) in Authorization header. 'Bearer ' optional.

Query Parameters

project_id
string<uuid> | null
deprecated

Deprecated: send project_id in the body instead

Body

application/json

API request schema for creating a metadata attribute.

name
string
required

Human-readable name, unique per project

Maximum string length: 255
data_type
enum<string>
required

Type of value this attribute holds

Available options:
string,
integer,
float,
boolean,
datetime,
single_select,
multi_select,
user_id,
person_id,
object_id,
directory_id
project_id
string<uuid> | null

Project the attribute belongs to. Required unless given in the deprecated project_id query parameter

options
SelectOption · object[] | null

For select types only

category
string | null

Grouping category for UI

generation_config
MetadataGenerationConfig · object | null

Settings for generating an attribute's values with AI.

Response

Successful Response

API response schema for metadata attribute.

id
string<uuid>
required

Unique identifier for this attribute

name
string
required

Human-readable display name

data_type
enum<string>
required

Type of value this attribute holds

Available options:
string,
integer,
float,
boolean,
datetime,
single_select,
multi_select,
user_id,
person_id,
object_id,
directory_id
source
enum<string>
required

Whether attribute is system-defined or user-created

Available options:
system,
user,
asset
is_filterable
boolean
required

Whether this attribute can be used in filters

is_displayable
boolean
required

Whether this attribute can be shown in generic metadata display UI

is_editable
boolean
required

Whether values for this attribute can be edited through metadata APIs

is_sortable
boolean
required

Whether assets can be sorted by this attribute

created
string<date-time>
required

When the attribute was created

updated
string<date-time>
required

When the attribute was last updated

project_id
string<uuid> | null

Project ID for project-specific attributes, null for system global

options
SelectOption · object[] | null

Available options for select types

category
string | null

Grouping category for UI display

asset_column
string | null

For ASSET source: the asset property this attribute maps to

generation_config
MetadataGenerationConfig · object | null

AI generation settings; null when generation is off

created_by_user_id
string<uuid> | null

User who created the attribute; null for system attributes and ones created before creators were recorded