# Objects and the data model (/docs/contacts/objects)

Objects are the tables Mokanata keeps next to your contacts: orders, products, properties, vehicles, subscriptions, whatever your business tracks. Contacts is built in; you add your own objects or sync tables from your database, relate them to contacts and to each other, and agents read them as context when they work a conversation.

- **Who can use it:** Everyone in the workspace can open the Objects tab, every table and each object's fields. Only owners and admins can change the data model (create, edit and delete objects, fields and relations) and connect databases. This comes with Admin access, so it can't be given to other roles one by one. Everyone else sees the notice **The data model is view only**, a greyed-out **New object** button and **View fields** instead of **Edit object**. See [Roles and permissions](/docs/settings/roles).
- **Before you start:** Nothing. Every workspace starts with the built-in Contacts object.

## Open the Objects tab [#open-the-objects-tab]

<Steps>
<Step>

### Open Setup [#open-setup]

In the sidebar, under **Automation**, click **Setup**. You can also press <kbd>G</kbd> then <kbd>U</kbd> from anywhere.

</Step>
<Step>

### Choose Objects [#choose-objects]

Click the **Objects** tab. Its count is the number of objects in the workspace. The tab has three parts: the **Connected databases** panel, the list of objects, and a switch between **List** and **Data model** on the right.

![The Objects tab of Setup with the Connected databases panel and a list of Contacts, Orders and Products](/screenshots/objects/01-objects-tab.webp)

</Step>
</Steps>

## Read the objects list [#read-the-objects-list]

Each row is one object. Click a row to open its table: Contacts opens the [Contacts](/docs/contacts/contacts) page, every other object opens its own records table (see [Work with records](/docs/contacts/records)).

| Column | What it shows |
| --- | --- |
| **Object** | The object's icon and name. Contacts carries a **Built in** badge. An object synced from a database carries a badge with the sync's name and a status dot (hover it for the table and status). |
| **Records** | How many records the object holds. |
| **Fields** | How many fields each record has, relation fields included. |
| **Related to** | The objects it's related to, or **Nothing yet**. See [Relate objects](/docs/contacts/relations). |

The footer shows the range, such as **1–3 of 3 objects**, and **Rows per page** (10, 25 or 50). On a phone, the record and field counts and the related objects move under each object's name.

## Find an object [#find-an-object]

- **Search objects** matches an object's singular and plural names, and the table name of a synced object. Press <kbd>/</kbd> to jump to it and <kbd>Esc</kbd> to clear it.
- **Filter → Source** appears once a database is connected. Pick **Made in Mokanata** or **From** a connected database to see only those objects. While the list is narrowed, a count such as **2 of 5 objects** shows beside the toolbar.

When nothing matches you see **No objects match** with **Clear search** or **Clear filters**.

## Object actions [#object-actions]

Click **⋯** at the end of a row for that object's actions.

![The actions menu of the Orders row, with Open table, Edit object and Delete Orders](/screenshots/objects/02-row-menu.webp)

| Action | What it does | Who sees it |
| --- | --- | --- |
| **Open table** | Opens the object's records table. | Everyone |
| **Edit object** | Opens the object sheet to change its name, icon, fields, relations and agent settings. See [Create a custom object](/docs/contacts/create-object). | Owners and admins |
| **View fields** | Opens the same sheet read-only, with a **Close** button. | Everyone else |
| **Sync settings** | Opens the database sync the object comes from. See [Tables, columns, row filters and sync status](/docs/contacts/database-sync). | Synced objects only |
| **Delete** | Deletes the object, its records and its relations. | Owners and admins, not for Contacts or synced objects |

## Delete objects [#delete-objects]

Deleting an object removes all its records and every relation it has. Objects related to it lose their side of each relation, and the links stored there.

<Steps>
<Step>

### Choose what to delete [#choose-what-to-delete]

For one object, open its **⋯** menu and click **Delete** followed by the object's name, for example **Delete Orders**.

For several, tick the checkbox at the start of each row (or the header checkbox for the whole page). A bar appears at the bottom of the screen with the number selected. Contacts and synced objects have no checkbox.

![Orders and Products ticked in the objects list, with the bar at the bottom reading 2 selected](/screenshots/objects/03-bulk-bar.webp)

</Step>
<Step>

### Delete from the bar [#delete-from-the-bar]

In the bar, click **⋯**, then **Delete**. **Clear** unticks everything instead.

</Step>
<Step>

### Confirm [#confirm]

The confirmation counts what goes with the objects: their records and relations, and which other objects lose their link. Click **Delete** to go ahead, or **Keep them** (**Keep** followed by the name for one object) to stop.

![The Delete 2 objects confirmation: Orders and Products go, with 11 records and 2 relations, and Contacts lose their link to them](/screenshots/objects/04-delete-objects.webp)

</Step>
</Steps>

<Callout type="error" title="There is no undo">
Deleting an object, a field or a relation can't be undone. Records you delete one by one in a table can be brought back from the notice that follows, but a deleted object takes its records with it for good.
</Callout>

## Switch to the data model view [#switch-to-the-data-model-view]

Click **Data model** beside the search to see every object as a card and every relation as a line between them. Its count is the number of relations. Everything you do there you can also do from the list and the object sheet. See [The data model canvas](/docs/contacts/data-model-canvas).

## When the data model is view only [#when-the-data-model-is-view-only]

Members, viewers and custom roles see the same tables, but can't change the data model or connect databases.

![The Objects tab for a member: a The data model is view only notice under the tabs, with New object and Connect database greyed out](/screenshots/objects/05-view-only.webp)

- **New object** and **Connect database** are greyed out. Hover them to see why, for example “Only workspace owners and admins can change the data model.”
- The row menu offers **View fields** instead of **Edit object**, and no **Delete**.
- On the [data model canvas](/docs/contacts/data-model-canvas) the cards don't move and clicking a card shows its fields.

Working with records is a separate set of permissions: by default members can add, edit and delete records, and viewers only read them. See [Work with records](/docs/contacts/records).

## Share a link [#share-a-link]

Every object's table and every record has its own address: copy it from your browser to send a teammate straight there. Sheets have addresses too. Opening **New object**, an object's fields, a relation or **Connect a database** adds to the address, and your browser's Back button closes the sheet again.

Someone who can't change the data model can still follow a link to an object's fields; it opens read-only. Links to the **New object** or **Connect a database** sheet just open the Objects tab for them.

## Keyboard shortcuts [#keyboard-shortcuts]

| Keys | What it does |
| --- | --- |
| <kbd>G</kbd> then <kbd>U</kbd> | Go to Setup |
| <kbd>N</kbd> | New object (on the Objects tab, for owners and admins) |
| <kbd>/</kbd> | Focus **Search objects** |
| <kbd>Esc</kbd> | Clear the search while it's focused |

You can change these in [Keyboard shortcuts](/docs/settings/keyboard-shortcuts).

## Troubleshooting [#troubleshooting]

<Accordions type="single">
<Accordion title="There's no Delete for Contacts">
Contacts is built in and can't be deleted. You can still add your own fields and relations to it: see [Custom fields on contacts](/docs/contacts/contact-fields).
</Accordion>
<Accordion title="There's no Delete for a synced object">
A synced object goes when you untick its table in the sync, or disconnect the database. See [Tables, columns, row filters and sync status](/docs/contacts/database-sync).
</Accordion>
<Accordion title="A link says “That object no longer exists”">
Someone deleted the object after the link was shared. The objects list shows every object that's left.
</Accordion>
</Accordions>

## Next steps [#next-steps]

<Cards>
<Card title="Create a custom object" href="/docs/contacts/create-object" description="Name it, add fields and relations, and create it in one go." />
<Card title="Work with records" href="/docs/contacts/records" description="Add, edit, link and delete the records in an object's table." />
<Card title="Connect a database" href="/docs/contacts/connect-database" description="Sync live tables from Postgres, Supabase, Neon and more." />
</Cards>
