> For the complete documentation index, see [llms.txt](https://docs.snapfix.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.snapfix.com/how-the-apps-work/screens/assets/create-register.md).

# Create a new asset register

{% hint style="info" %}
Draft, written by an agent and not yet checked by a person ([how to read these docs](https://docs.snapfix.com/how-to-read.md)). Platforms: iOS and Android. [Source on GitHub](https://github.com/snapfix/docs/blob/main/spec/screens/assets/create-register.md).
{% endhint %}

Name a new asset register; on the web the same step is the dialog "Create a new Asset Register" on [Asset registers](https://docs.snapfix.com/how-the-apps-work/screens/assets/registers.md#create-a-new-asset-register-web).

* **Where:** iOS: [Asset registers](https://docs.snapfix.com/how-the-apps-work/screens/assets/registers.md), the header "+" (`AddAssetGroupVC`), or the app's "+" menu while asset registers are open. Android: [Asset registers](https://docs.snapfix.com/how-the-apps-work/screens/assets/registers.md), "+" menu, "Create a new asset register" (`CreateAssetGroupActivity`).
* **Who:** the screens check no permission themselves; the lists decide who reaches them. iOS shows the header "+" to admins of an asset register or a task group and to account admins \[[ASK-104](https://github.com/snapfix/docs/blob/main/ASK.md#ask-104-who-may-create-an-asset-register)]. Android shows the menu item when the device's copy of the site's create flag allows it, or to account admins.
* **Feature:** [Asset registers](https://docs.snapfix.com/product/features/assets/asset-registers.md)

## Layout

One screen: the title "Create a new Asset Register", the label "Asset Register Name", the hint "Asset Register name must be unique", the name field, and the button "Create Asset Register" at the bottom. A back button leaves.

## Inputs

| Field                 | Type | Required | Default | Rules and messages                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  |
| --------------------- | ---- | -------- | ------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| "Asset Register Name" | Text | Yes      | Empty   | Unique among the site's registers that are not deleted, in any letter case. iOS turns the button on as soon as the field has any character, spaces only included, and then saves the trimmed, empty name. Android turns it on only when the trimmed name is not empty. A taken name: iOS shows the alert "An asset register with this name already exists. Choose another one." with "OK" (the app swaps the words of "A group with this name already exists. Choose another one."); Android marks the field "An asset register with this name already exists. Choose another one." |

## Actions

| Action                  | Who                           | What happens                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                     | API                                                                                                                                                                                                                                                                                                                                                                                                                                                          |
| ----------------------- | ----------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| "Create Asset Register" | Anyone who reaches the screen | Checks the name on the device first. iOS builds that query by pasting the name in, so a name with an apostrophe skips the device check. Then asks the server, with the site, the name and the type `asset`; an answer that names an active or inactive group is a duplicate. Otherwise the register is created on the device with the user as its admin, the default settings, the red, amber and green statuses and the default attribute rules ("Asset ID", "Description", "Type", "Manufacturer", "Model", "Location" and "Notes", and in "Tracking": "NFC", "QR" and "Barcode"), and the sync sends it. iOS returns to the list, which shows "New asset register created :" with the name for three seconds. | [`?action=check_duplicate_business`](https://docs.snapfix.com/engineering-reference/api/groups.md#post-actioncheck_duplicate_business), then the sync ([`?action=save_pri_business`](https://docs.snapfix.com/engineering-reference/api/groups.md#post-actionsave_pri_business) and the related rows). The web creates registers with [`POST /v1/app/asset-regs`](https://docs.snapfix.com/engineering-reference/api/assets.md#post-v1appasset-regs) instead |
| Back                    | Anyone                        | Leaves without creating.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                         | None                                                                                                                                                                                                                                                                                                                                                                                                                                                         |

The new register's attributes can then be changed in [Asset register settings](https://docs.snapfix.com/how-the-apps-work/screens/assets/register-settings.md).

## States

* **Loading:** "Creating asset register..." while the server check runs.
* **Duplicate:** the messages in [Inputs](#inputs); the screen stays open.
* **Error:** iOS creates the register anyway when the server check fails for any reason. Android shows "Something went wrong. Please try again." when the check fails.
* **Offline (mobile):** Android skips the server check without a connection and creates the register; iOS's check fails offline, so it creates the register too. Either way the sync sends it later.

## Platform differences

| Topic                           | iOS                                                                                                                                                        | Android                                                                       |
| ------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------- |
| Blank name                      | Allowed through, saved empty                                                                                                                               | Refused                                                                       |
| Taken name                      | Alert                                                                                                                                                      | Field error                                                                   |
| Server check offline or failing | Creates anyway                                                                                                                                             | Offline: skipped, creates; failing: "Something went wrong. Please try again." |
| Who reaches it                  | Admins of a register or task group, account admins \[[ASK-104](https://github.com/snapfix/docs/blob/main/ASK.md#ask-104-who-may-create-an-asset-register)] | Create flag on the device, or account admin                                   |


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

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

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.snapfix.com/how-the-apps-work/screens/assets/create-register.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

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.
