---
description: >
  Find here a reference and glossary of common annotations intrinsically supported by the CDS compiler and runtimes.
uacp: Used as link target from Help Portal at https://help.sap.com/products/BTP/65de2977205c403bbc107264b8eccf4b/855e00bd559742a3b8276fbed4af1008.html
---

# Common Annotations

{{ $frontmatter.description }}

[Learn more about the syntax of annotations.](./cdl#annotations){.learn-more}

[[toc]]


## General Purpose

| Annotation     | Description | Alternatives        |
|----------------|-------------|---------------------|
| `@title`       |             | `@Common.Label`     |
| `@description` |             | `@Core.Description` |


## Access Control

| Annotation  | Description                                                               |
|-------------|---------------------------------------------------------------------------|
| `@restrict` | see [Authorization](../guides/security/authorization#restrict-annotation) |
| `@requires` | see [Authorization](../guides/security/authorization#requires)            |


## Input Validation

| Annotation       | Description                                                          |
|------------------|----------------------------------------------------------------------|
| `@readonly `     | see [Input Validation](../guides/services/constraints#readonly)      |
| `@mandatory`     | see [Input Validation](../guides/services/constraints#mandatory)     |
| `@assert.target` | see [Input Validation](../guides/services/constraints#asserttarget) |
| `@assert.format` | see [Input Validation](../guides/services/constraints#assertformat) |
| `@assert.range`  | see [Input Validation](../guides/services/constraints#assertrange)  |




## Services / APIs

| Annotation           | Description                                                                             |
|----------------------|-----------------------------------------------------------------------------------------|
| `@path`              | see [Services](./cdl#service-definitions)                                               |
| `@impl`              | see [Reuse & Compose](../guides/integration/reuse-and-compose#reuse-code)                    |
| `@odata.etag`        | see [Providing Services](../guides/services/served-ootb#etag)                           |
| `@cds.autoexpose`    | see [Providing Services](../guides/services/providing-services#auto-exposed-entities)   |
| `@cds.api.ignore`    | see [OData](../guides/protocols/odata#omitting-elements-from-apis)                      |
| `@cds.query.limit`   | see [Providing Services](../guides/services/served-ootb#annotation-cds-query-limit)     |
| `@cds.localized`     | see [Localized Data](../guides/uis/localized-data#read-operations)                      |
| `@cds.valid.from/to` | see [Temporal Data](../guides/domain/temporal-data#using-annotations-cdsvalidfromto) |
| `@cds.search`        | see [Search Capabilities](../guides/services/served-ootb#searching-data)                |

## Persistence

| Annotation                | Description                                                                  |
|---------------------------|------------------------------------------------------------------------------|
| `@cds.persistence.exists` | see [Generating DDL Files](../guides/databases/cdl-to-ddl#cdspersistenceexists) |
| `@cds.persistence.table`  | see [Generating DDL Files](../guides/databases/cdl-to-ddl#cdspersistencetable)  |
| `@cds.persistence.skip`   | see [Generating DDL Files](../guides/databases/cdl-to-ddl#cdspersistenceskip)   |
| `@cds.persistence.mock`   | `false` excludes this entity from automatic mocking                          |
| `@cds.on.insert`          | see [Providing Services](../guides/services/providing-services)              |
| `@cds.on.update`          | see [Providing Services](../guides/services/providing-services)              |
| `@sql.prepend`            | see [Generating DDL Files](../guides/databases/cdl-to-ddl#sqlprepend--append)     |
| `@sql.append`             | see [Generating DDL Files](../guides/databases/cdl-to-ddl#sqlprepend--append)     |

## OData

[Learn more about **OData Annotations in CDS**.](../guides/protocols/odata#annotations){.learn-more}

Shortcuts:

| Annotation          | Description                                                  |
|---------------------|--------------------------------------------------------------|
| `@ValueList.entity` | see [Domain Modeling](../guides/domain/index)                |
| `@odata.Type`       | see [OData](../guides/protocols/odata#override-type-mapping) |
| `@odata.MaxLength`  | see [OData](../guides/protocols/odata#override-type-mapping) |
| `@odata.Precision`  | see [OData](../guides/protocols/odata#override-type-mapping) |
| `@odata.Scale`      | see [OData](../guides/protocols/odata#override-type-mapping) |
| `@odata.singleton`  | see [OData](../guides/protocols/odata#singletons)            |
Intrinsically supported OData Annotations:

| Annotation          | Description                                                       |
|---------------------|-------------------------------------------------------------------|
| `@Core.Computed`    | see [Providing Services](../guides/services/constraints#readonly) |
| `@Core.Immutable`   | see [Providing Services](../guides/services/constraints#readonly) |
| `@Core.MediaType`   | see [Media Data](../guides/services/media-data)                   |
| `@Core.IsMediaType` | see [Media Data](../guides/services/media-data)                   |
| `@Core.IsUrl`       | see [Media Data](../guides/services/media-data)                   |
| `@Capabilities...`  | see [Fiori](../guides/uis/fiori)                                  |
