> ## Documentation Index
> Fetch the complete documentation index at: https://docs.rapidcert.co.nz/llms.txt
> Use this file to discover all available pages before exploring further.

# Company Management

> Managing contractor companies in RapidCert

# Company Management

This guide covers how to view and manage contractor companies in the admin dashboard.

## Company List

Navigate to **Companies** to see all companies.

### List View

The company list shows the following columns:

| Column       | Description                                        |
| ------------ | -------------------------------------------------- |
| Company Name | The registered name of the company                 |
| NZBN         | New Zealand Business Number                        |
| Email        | Primary contact email address                      |
| Valid Until  | Expiry date of the company's current certification |
| Client       | The client(s) the company is linked to             |
| Status       | Current account status                             |
| Created Date | When the company record was created                |

### Filtering and Searching

Filter and search companies using:

* **Search** — by company name, NZBN, or contact email
* **Status** — Active, Inactive, or Suspended
* **Client selector** — the global client selector scopes the list to companies linked to the selected client

### Quick View (Viewer Role Only)

The Quick View feature is available to the **Viewer role only**. Viewers can preview company information without leaving the directory by clicking the **eye icon** on each table row. The Quick View modal shows:

* Company status and certification summary
* Insurance coverage summary
* A **View Full Details** link to navigate to the full company profile

<Note>
  Quick View is only shown to viewers. Admins and assessors navigate directly to the company profile by clicking a row — they do not see the eye icon.
</Note>

## Company Details

Click a company to view its details. Company information is shown in a card above the tabs.

### Accreditations Tab

The Accreditations tab is the primary view for a company's certification activity. It is split into two areas:

* **Accreditation records table** — lists all accreditation slots for the company, grouped by client and certification type, with their status, current or in-progress evaluation, and action buttons
* **Evaluation cards** — detail cards below the records table showing current certification status and expiry date, in-progress or renewal evaluations, and an actions menu with options to view, manage, or regenerate evaluations

#### Accreditation records and slots

An accreditation slot represents a single tracked certification position for a company under a given certification type. RapidCert supports companies that operate multiple business units, subsidiaries, branches, or locations under the same NZBN — when a client has the **Allow Additional Accreditation Slots** feature enabled (see [Clients — Accreditation slot features](/guides/admins/clients#accreditation-slot-features)), admins can create separate accreditation records for each business unit within the same certification type.

Each accreditation record in the table shows:

| Column                         | Description                                                                     |
| ------------------------------ | ------------------------------------------------------------------------------- |
| Accreditation Type             | The certification type name, with a custom label underneath if one has been set |
| Status                         | Current certification status for this record                                    |
| Current/In progress Evaluation | The most recent evaluation linked to this record                                |
| Actions                        | Edit or archive this record (visible to admins with manage permission)          |

Records are grouped under a row header that shows the client name. If a group contains more than one slot, the header shows the count (e.g. "2 slots").

**Adding a new accreditation slot**

The **Add Slot** button appears on the group header row when the client has accreditation slots enabled and you have the manage permission.

<Steps>
  <Step title="Click Add Slot">
    Click the **Add Slot** button on the group header for the certification type you want to add a record for.
  </Step>

  <Step title="Select the accreditation type (if not pre-selected)">
    If no type is pre-selected, choose one from the dropdown. The dropdown lists certification types available to this company.
  </Step>

  <Step title="Label the existing record (if required)">
    If an unlabelled accreditation already exists for this type, you must give it a label before adding another. The system suggests **Primary Company** as the default. Enter a label that clearly identifies the business unit (e.g. "Parent Company", "Auckland Hotel").
  </Step>

  <Step title="Enter a label for the new slot">
    If any slot already exists for this certification type, a label is required for the new one as well. Use a business unit, subsidiary, branch, or location name (e.g. "Christchurch Branch").
  </Step>

  <Step title="Optionally set a fixed price">
    Check **Set fixed price** to override the client's standard pricing for this slot. Enter a dollar amount — a value of 0 skips payment for the next evaluation. Leave unchecked to use the client's pricing model.
  </Step>

  <Step title="Save">
    Click **Add Accreditation Slot**. The new record is created with `Assigned` status and appears in the table under the same group. The contractor/supplier can then begin an evaluation against it.
  </Step>
</Steps>

**Where the label appears**

Once a label is set, it flows through every surface that displays the accreditation:

* Admin accreditation records table (as a sub-line under the certification type)
* Contractor dashboard cards and notification settings rows
* Issued PDF certificates (as a dedicated `Accreditation Label:` line)
* Payment receipt emails and the contractor's billing history
* Viewer dashboards and viewer CSV exports (both `Accreditation` column and a dedicated `Accreditation Label` column)
* Notification service reminder emails (see [Notifications service](/internal/notifications-service))

A label that exactly matches the certification type name — or the literal word `default` — is treated as unset when rendered on contractor-facing surfaces.

**Labelling rules**

Labels must be unique and meaningful — they are shown to contractors and viewers alongside the certification type name (e.g. "Site Safety Accreditation - Auckland Hotel"). Specifically:

* Labels can be up to **160 characters** long.
* Labels are case-insensitive for uniqueness checks. Duplicate labels within the same certification type on the same company are not permitted.
* Creating an additional slot for a certification type that already has an active slot requires a label on the new slot.
* The existing slot must also be labelled before a second slot can be created for that certification type.
* A label can only be cleared if the slot is the only remaining active slot for that company/certification-type combination.
* A label that exactly matches the certification type name is treated as if no label was set.

**Editing an accreditation slot**

Click the **pencil icon** on a slot row to edit its label or price override.

* If only one slot exists in the group, the label is optional.
* If more than one slot exists in the group, a label is required while multiple live records exist.
* Price overrides can only be set on admin-created slots and replace the standard category price for that slot.

**Archiving an accreditation slot**

Click the **archive icon** on a slot row to archive the record. You must provide a reason (required); notes are optional.

Archived accreditations:

* Are hidden from operational summaries, evaluation creation, renewal flows, notification settings, viewer exports, and scheduled reminder jobs
* Cannot be edited while archived
* Are retained for historical traceability

<Warning>
  Ensure the slot is no longer in active use before archiving. Restoration is controlled and is only available when the archive history and label rules can be verified.
</Warning>

**Viewing and restoring archived accreditations**

Admins with access to the company's accreditation records can open the **View archived (n)** panel below the active records table. The panel shows the archived accreditation, client, archive date, reason, and notes.

Each archived record has one of these outcomes:

* **Unarchive** — the slot can be recovered automatically. Click **Unarchive**, review the confirmation dialog, and confirm. The slot returns to the exact status it had before archiving and reappears in the active records table.
* **Cannot restore automatically** — the archive history cannot be verified, or the slot does not meet the recovery rules. Contact RapidCert support for reviewed recovery.

Restoration is unavailable if it would conflict with a live slot of the same certification type. A successful restoration is recorded in the audit trail.

**Audit trail**

All slot create, update, archive, and successful restore actions are recorded in the audit trail with the acting user, timestamp, and changed values.

#### Adding a historical evaluation

The **Add Evaluation** button on the Accreditations tab allows admins and assessors to manually record an imported or historical evaluation. You can specify the certification type, issued date, and expiry date. This is used to record legacy certifications that exist outside the system — it does not start a new assessment workflow.

**Eligible certification targets**

You can add a historical evaluation against a certification slot in any of the following states: `Assigned`, `Active`, `Expired`, or `Expiring Soon`. Slots in a protected state (`Deleted`, `Suspended`, `Revoked`, or `Archived`) cannot be targeted.

**Lifecycle status after adding a legacy evaluation**

Once a legacy evaluation is recorded, the certification slot lifecycle status is set to **Active** regardless of the expiry date supplied. Expiry is derived at display time from the stored expiry date — the system never writes `Expired` as a stored lifecycle status for a manually created evaluation. This means a slot with a past expiry date will show as Active in the database but Expired in the admin UI and viewer-facing surfaces.

#### Regenerating evaluations

You can regenerate a DRAFT evaluation to recreate it from the current template version. This is useful when the template has been updated and you want the evaluation to reflect the latest questions.

<Warning>
  Regenerating an evaluation permanently deletes all existing responses and attachments. The evaluation is recreated from scratch using the current template version. This action cannot be undone.
</Warning>

To regenerate an evaluation:

1. Locate the DRAFT evaluation in the accreditations tab
2. Click the **three-dot menu** (⋯) next to the evaluation
3. Select **Regenerate Evaluation**
4. Read the warning carefully
5. Type **REGENERATE** in the confirmation field
6. Click **Regenerate**

The system recreates the evaluation with the current template version and displays the number of questions generated.

### Insurance Tab

* Active insurance policies
* Expiry dates
* Compliance status

The **Add Insurance** button on this tab allows admins and assessors to manually add an insurance policy for the company.

### Notification Settings

The **Notification Settings** button on the company detail page (visible to Admin and Assessor roles) opens a modal for managing per-user and per-certification email notification settings for this company.

### Users Tab

* Users associated with the company
* Roles and permissions
* Last activity

#### Multi-tenant companies

When a company is linked to more than one tenant, the Users tab becomes read-only for administrators and assessors. In this state:

* The **Add User**, **Edit user**, and **Delete user** actions are hidden
* User impersonation is not available
* An information notice is displayed at the top of the tab explaining the restriction

This restriction exists because the company is shared across tenants and user management actions could affect users in other tenants' contexts. The users list remains visible so you can still see who is associated with the company.

### Files & Notes Tab

Internal notes with optional file attachments, alongside company documents. Notes and file uploads are scoped to the currently selected client group — you only see notes that belong to clients within your access, and any new notes or uploaded documents are associated with the selected client.

<Note>
  If a company is linked to multiple clients, switch the client group selector to view notes and files for a different client. Notes created under one client are not visible when another client is selected.
</Note>

To add a note:

1. Click **Add Note**
2. Enter your note content
3. Optionally attach files by clicking **Attach Files** — you can upload new files directly or select existing company documents
4. Click **Save**

You can edit a note to update its content or change its attachments, or delete notes you no longer need. Notes are displayed newest first.

### Billing Tab

The **Billing** tab is available to Administrators with access to the company. It shows payment transactions for the selected company, including paid, refunded, and partially refunded records, with receipt or invoice links where Stripe provides them.

Assessors cannot open the Billing tab. Administrators see transactions only for companies in their authorised scope.

### Emails Tab

* Email log for this company
* History of system emails sent to the company's contacts

When a company is linked to more than one tenant, an information notice is displayed at the top of the Emails tab. The notice indicates that you will only see emails explicitly related to your tenancy — emails sent in the context of other tenants are not shown.

## Creating a Company

Administrators can create companies:

1. Click **Add Company**
2. Select the client to link the company to
3. Enter the NZBN or search by company name — if found in the NZBN register, company details are pre-filled
4. Fill in the contact person details:
   * **Contact Person Email** (required) — RapidCert checks whether this email is already registered when you leave the field or submit
   * **Contact Person Name** (required for new users, not shown when linking an existing contractor/supplier account)
   * **Contact Person Phone** (optional)
5. Click **Create Company**

<Info>
  If the contact email belongs to an existing contractor/supplier account, RapidCert links that account as the primary contact automatically — you do not need to enter their name again. If the email belongs to an administrator or assessor, it cannot be used as a company contact and the form will not submit.
</Info>

<Note>
  Companies usually self-register. Admin creation is for special cases.
</Note>

## Editing Company Details

### Modifying Information

1. Open company profile
2. Click **Edit Company Details**
3. Make changes
4. Click **Save Changes**

<Note>
  The **Edit Company Details** button is disabled for companies linked to more than one tenant. Hovering over the button shows a message explaining the restriction. Contact internal RapidCert staff if you need to edit details for a multi-tenant company.
</Note>

### What Can Be Changed

| Field        | Editable in the admin UI |
| ------------ | ------------------------ |
| Trading Name | Yes                      |
| Contact Info | Yes                      |
| Address      | Yes                      |
| Company Name | No                       |
| NZBN         | No                       |

<Note>
  Company Name and NZBN are set during registration and remain read-only in the standard company edit form.
</Note>

## Client Assignment

### Linking to clients

Companies are linked to clients through the **Add Company** modal:

1. Click **Add Company**
2. Select the client you want to link the company to
3. Search for the company by NZBN or name
4. If the company already exists in the system, you are prompted to link it to the selected client — no need to re-enter company details
5. If the company is new, fill in the required details and confirm

A company can be linked to multiple clients by repeating this process with a different client selected.

## Managing Company Users

### Viewing Users

See all users under the company:

* Name and email
* Role within company
* Last login
* Status

### Adding Users

Adding a user to a company uses a two-step flow:

1. Click **Add User**
2. Enter the user's email address and click **Continue** — RapidCert checks whether this email is already registered
3. Depending on the result:
   * **New user** — enter the user's full name (required) and optionally their phone number
   * **Existing contractor/supplier** — the name field is not shown; the existing account is linked automatically. You can optionally enter a phone number for this company association
4. Optionally tick **Make this user the primary contact**
5. Click **Add User** (or **Add Existing User** if linking an existing account)

The following email addresses cannot be added to a company:

* Emails belonging to deleted accounts, unless an eligible deleted viewer account can be recovered
* Emails belonging to inactive contractor/supplier accounts
* Emails belonging to active administrator, assessor, or viewer accounts

<Info>
  If the email belongs to an active administrator, assessor, or viewer account, it cannot be added as
  a company user. A message is shown and the form cannot be submitted.
</Info>

<Info>
  Pending contractor/supplier accounts can be linked to a company. The add-user flow creates a non-primary membership, and the first successful login activates the account without making it primary. An administrator can assign primary status afterward if required; selecting **Make this user the primary contact** does not change the rule while the account is pending.
</Info>

<Info>
  If the email address belonged to a deleted viewer, RapidCert can reuse it when the old viewer has
  no company relationships and belonged to a client you are authorised to manage. The add-user flow
  creates a new contractor/supplier account for that email address. If the old account is not
  eligible, the form explains that the email address cannot be used.
</Info>

You can click **Change Email** on the details step to go back and enter a different address.

### Editing Users

To edit a company user's details:

1. Click the **edit icon** next to the user in the Users tab
2. Update the fields as needed
3. Click **Save Changes**

<Info>
  If a contractor/supplier account is linked to more than one tenant, their name and email are read-only and cannot be changed from this company's Users tab. Only their phone number can be updated. Impersonation is also disabled for these users. Contact RapidCert support if a global identity change is needed for a cross-tenant user.
</Info>

<Note>
  The **Add User** button is not available for companies linked to more than one tenant. See [Multi-tenant companies](#multi-tenant-companies) above.
</Note>

### Removing Users

1. Find user in list
2. Click **Remove**
3. Confirm

<Note>
  User removal is not available for companies linked to more than one tenant. See [Multi-tenant companies](#multi-tenant-companies) above.
</Note>

## Company Status

| Status               | Description                                                                                                                         |
| -------------------- | ----------------------------------------------------------------------------------------------------------------------------------- |
| Active               | Normal operation                                                                                                                    |
| Inactive             | Temporarily disabled                                                                                                                |
| Suspended            | Account suspended                                                                                                                   |
| Pending Verification | Awaiting verification before activation. This status exists in the system but is not currently shown or selectable in the admin UI. |

### Changing Status

Company status is toggled between **Active** and **Inactive** via the API. There is no status change button with a reason field exposed in the current admin UI.

## Sending Communications

### Welcome Email

To resend a welcome email, open the company detail page and click the **mail icon button** next to the primary contact's email address in the company details card. Confirm when prompted.

## Merging companies

If duplicate companies exist:

1. Identify duplicates
2. Contact support
3. Data is consolidated
4. Duplicate is archived

<Note>
  Company merging requires support assistance to ensure data integrity.
</Note>

## Next Steps

<Card title="Insurance Verification" icon="shield-check" href="/guides/admins/insurance-verification">
  Learn about verifying insurance policies
</Card>
