# ObjectClass

Location: [gRPC API](https://developer.m-files.com/APIs/gRPC-API/index.md) > [Reference](https://developer.m-files.com/APIs/gRPC-API/Reference/index.md) > [Messages](https://developer.m-files.com/APIs/gRPC-API/Reference/Messages/index.md)

HTML version: https://developer.m-files.com/APIs/gRPC-API/Reference/Messages/MFiles.ObjectClass/

A class: a kind of object within one object type, with the properties its objects have.

- **Full name:** `MFiles.ObjectClass`
- **Proto file:** [`mfiles/structs.proto`](https://developer.m-files.com/APIs/gRPC-API/downloads/proto/mfiles/structs.proto)

<a id="fields"></a>

## Fields

| Field | Type | Number | Description |
|---|---|---|---|
| <a id="f-base_info"></a>`base_info` | [`ValueListItem`](https://developer.m-files.com/APIs/gRPC-API/Reference/Messages/MFiles.ValueListItem/index.md) | 1 | The class as an item of value list 1 (Classes). The class ID is `base_info.item_info.obj_id.item_id.internal_id` and its name `base_info.item_info.name`. |
| <a id="f-associated_property_defs"></a>`associated_property_defs` | repeated [`AssociatedPropertyDef`](https://developer.m-files.com/APIs/gRPC-API/Reference/Messages/MFiles.AssociatedPropertyDef/index.md) | 2 | The properties of objects of this class, each with `is_required`. Lists only property definitions the caller can see, and includes the built-in properties that every object has (such as 20 Created and 25 Created by). |
| <a id="f-default_workflow"></a>`default_workflow` | `int32` | 3 | The default workflow of the document class, or zero if there is no default workflow. |
| <a id="f-object_type"></a>`object_type` | `int32` | 4 | The ID of the object type the class belongs to. |
| <a id="f-name_property_def"></a>`name_property_def` | `int32` | 5 | The property definition whose value is the object's name: 0 (Name or title) unless the class names its objects by another property. |
| <a id="f-force_workflow"></a>`force_workflow` | `bool` | 6 | True if objects of this class must use `default_workflow`. |
| <a id="f-acl"></a>`acl` | [`AccessControlList`](https://developer.m-files.com/APIs/gRPC-API/Reference/Messages/MFiles.AccessControlList/index.md) | 7 | Specifies the ACL that defines the visibility and other permission settings of this class. Also specifies who can attach objects to this class. |
| <a id="f-current_user_permissions"></a>`current_user_permissions` | [`ClassPermissionsForClient`](https://developer.m-files.com/APIs/gRPC-API/Reference/Messages/MFiles.ClassPermissionsForClient/index.md) | 11 | If set, specifies the permissions for current user that defines the visibility and other permission settings of this class. |
| <a id="f-object_type_class_content"></a>`object_type_class_content` | [`ObjectTypeSpecificClassContentUnion`](https://developer.m-files.com/APIs/gRPC-API/Reference/Messages/MFiles.ObjectTypeSpecificClassContentUnion/index.md) | 8 | Settings that only some object types have; set for the assignment classes of object type 10 (Assignment). |
| <a id="f-is_object_type_default_class"></a>`is_object_type_default_class` | `bool` | 10 | True if this is the default class of its object type. |

<a id="used-by-methods"></a>

## Used by methods

- [IRPCPropertyDefs.GetObjectClass](https://developer.m-files.com/APIs/gRPC-API/Reference/MFiles.IRPCPropertyDefs/GetObjectClass/index.md): Gets one class by ID, with the property definitions associated with it.
- [IRPCPropertyDefs.GetObjectClassesAndGroups](https://developer.m-files.com/APIs/gRPC-API/Reference/MFiles.IRPCPropertyDefs/GetObjectClassesAndGroups/index.md): Gets all classes and class groups that the user is allowed to see.

<a id="used-in-fields"></a>

## Used in fields

- [`GetObjectClassesAndGroupsResponse.classes`](https://developer.m-files.com/APIs/gRPC-API/Reference/MFiles.IRPCPropertyDefs/GetObjectClassesAndGroups/index.md#response): The classes the user can see, or empty if `known_version` was current. See [ObjectClass](https://developer.m-files.com/APIs/gRPC-API/Reference/Messages/MFiles.ObjectClass/index.md).
- [`GetObjectClassResponse.object_class`](https://developer.m-files.com/APIs/gRPC-API/Reference/MFiles.IRPCPropertyDefs/GetObjectClass/index.md#response): The class. See [ObjectClass](https://developer.m-files.com/APIs/gRPC-API/Reference/Messages/MFiles.ObjectClass/index.md).
