# Property

Properties define the schema and field definitions for CaraerObjects. A Property specifies the data type (string, number, date, boolean, etc.), format (text, email, select, multi-select, linked, file, etc.), validation rules (required, unique, character limits, etc.), and display options (label, description, icon, groups). Properties determine what data Records can store, how it's validated, how it's displayed in forms and views, and how it can be searched. Each Property belongs to a CaraerObject and defines one field in that object's schema. Properties support various formats including linked properties (relationships to other Records), file uploads, rich text, and custom option lists. Properties are immutable once created to maintain data integrity, and they can be organized into groups for better UX. The Property system enables dynamic, schema-on-read data modeling where object structures can be customized per company without code changes.

## Fetch a specific property

 - [GET /api/v2/objects/{objectUuid}/properties/{propertyUuid}](https://developer.caraer.com/apis/property/getproperty.md): Retrieves details of a property by its UUID and associates it with its parent object. Returns a ShowResponse containing a PropertyDTO object with complete property details.

## Update an existing property

 - [PUT /api/v2/objects/{objectUuid}/properties/{propertyUuid}](https://developer.caraer.com/apis/property/updateproperty.md): Updates the details of an existing property for a specific object. The property details are provided via SavePropertyDTO, and the property is identified by its UUID. Returns an UpdateResponse containing the updated property as a PropertyDTO. Validation rules: name (required, must be unique, must be lowercase, must match name pattern (lowercase letters, numbers, underscores), cannot be changed after creation), label (required), description (maximum 255 characters), type (required, must be one of valid PropertyTypes, cannot be changed after creation), format (required, must be one of valid PropertyFormats, cannot be changed after creation), rules (required, must be an array of string).

## Delete a property

 - [DELETE /api/v2/objects/{objectUuid}/properties/{propertyUuid}](https://developer.caraer.com/apis/property/deleteproperty.md): Deletes a property from the specified object, identified by the property UUID. Returns a DeleteResponse containing the deleted property's details.

## Update property indices

 - [PUT /api/v2/objects/{objectUuid}/properties/updateIndices](https://developer.caraer.com/apis/property/updateindices_2.md): Updates the indices for properties of a specific object. The request body should contain a mapping between property UUIDs and their new index values. Returns a SuccessResponse containing a list of updated PropertyDTO objects.

## Restore a soft-deleted property

 - [POST /api/v2/objects/{objectUuid}/properties/{propertyUuid}/restore](https://developer.caraer.com/apis/property/restoreproperty.md): Restores a previously deleted property by propertyUuid for the specified objectUuid. Returns a RestoreResponse containing the restored property details.

## Fetch paginated properties

 - [POST /api/v2/objects/{objectUuid}/properties/index](https://developer.caraer.com/apis/property/getproperties.md): Retrieves a paginated list of properties for a given object. Depending on the object UUID format, a Cypher query is constructed to filter properties belonging to that object. Returns a PaginationResponse containing PropertyDTO objects.

## Create a new property

 - [POST /api/v2/objects/{objectUuid}/properties/](https://developer.caraer.com/apis/property/createproperty.md): Creates a new property for a specific object using the provided property details. The SavePropertyDTO must include necessary details, and the object association is determined by the objectUuid path variable. Returns a CreateResponse containing the newly created property as a PropertyDTO. Validation rules: name (required, must be unique, must be lowercase, must match name pattern (lowercase letters, numbers, underscores)), label (required), description (maximum 255 characters), type (required, must be one of valid PropertyTypes, cannot be changed after creation), format (required, must be one of valid PropertyFormats, cannot be changed after creation), rules (required, must be an array of string).

## Retrieve allowed calculation types for a property

 - [GET /api/v2/objects/{objectUuid}/properties/{propertyUuid}/calculation-types](https://developer.caraer.com/apis/property/getpropertycalculationtypes.md): Returns calculation functions supported for the property's type.

## Retrieve property formats

 - [GET /api/v2/objects/{objectUuid}/properties/formats](https://developer.caraer.com/apis/property/getformats.md): Fetches a sorted list of available property formats. The formats are retrieved from the PropertyFormats enum and converted to PropertyFormat instances.

## Retrieve allowed calculation types per property type

 - [GET /api/v2/objects/{objectUuid}/properties/calculation-types](https://developer.caraer.com/apis/property/getcalculationtypes.md): Returns the calculation functions available for each property type (for example min/max on numbers).

## Permanently remove archived property

 - [DELETE /api/v2/objects/{objectUuid}/properties/{propertyUuid}/permanent](https://developer.caraer.com/apis/property/permanentlydeletearchivedproperty.md): Deletes the soft-deleted HAS_PROPERTY link to this object. If the property is not linked to any other object, the property node is hard-deleted.

