# Reference

Property Type: `reference`‌

A Reference property is a structure that exposes the object, identifier of another object instance. Some references can be expanded , allowing an object instance to be read through another.‌

Property ACLs can be attached to references in order to allow greater access to expanded properties than would normally be allowed. For example, the Patient File Object *account* property exposes the *name* property of the referenced account when expanded to anyone who is *Connected* to the Patient File.‌

Custom reference properties can be configured to allow the reference identifier to be updated, but only if the caller has the required `referenceAccess` to the instance being referenced. References can also be configured to include a static list of properties, or disallow expansion entirely.‌

### Property Options <a href="#property-options-1" id="property-options-1"></a>

| Option               | Type      | Default                  | Description                                                                                                                                                                                                              |
| -------------------- | --------- | ------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| expandable           | Boolean   | false                    | If true, this property can be expanded using "expand" options                                                                                                                                                            |
| autoCreate           | Boolean   | false                    | If true, a referenced object is auto-created, owned by the owner of the host context (in the case of account, the account holder)                                                                                        |
| grant                | Number    | acl.AccessLevels.NoAllow | Applies to expansions. The access level granted to the calling principal through expansion. Warning! This option can expose private context details. Consider using object pacls instead, and leave the grant level low. |
| sourceObject         | String    | ​Content                 | Applies to expansions. The name of the object from which to expand.                                                                                                                                                      |
| paths                | String    | ​Content                 | Applies to expansions. A list of fixed property names to load if the property is expanded. If set, access is always granted to these paths.                                                                              |
| referenceAccess      | Number    | acl.AccessLevels.Share   | The access required by the calling principal on the referenced context in order to set the reference \_id.                                                                                                               |
| pacl                 | Document  | ​Content                 | Adds augmented access to individual properties in the expanded object.                                                                                                                                                   |
| writeThrough         | Boolean   | false                    | Allows updating referenced objects, overriding access control using custom defaultAcl, gran and roles.                                                                                                                   |
| inheritInstanceRoles | Boolean   | false                    | When true, instance roles held by the caller on the current instance are applied to the reference when expanded or updated using write-through.                                                                          |
| defaultAcl           | Object\[] | \[]                      | An overriding set of acl rules to apply to referenced instances when expandable or write-through is enabled.                                                                                                             |


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.medable.com/cortex-api/objects-definition/object-properties/reference.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
