> 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/compliance/contractors.md).

# Contractors

{% 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: web. [Source on GitHub](https://github.com/snapfix/docs/blob/main/spec/screens/compliance/contractors.md).
{% endhint %}

The site's contractors in one table: name, email, first document, expiry date and status. Admins add a contractor by typing its name, or open one.

![Contractors](https://3653879137-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FsVVGa79QbcEkJ7n8srxe%2Fuploads%2Fgit-blob-0b110b158900830871601ca1726106fd7d062d88%2Fcontractors.png?alt=media)

* **Where:** web `/comply`, "Contractors" tab. The tab reads "Contractors (n)" while it is open, where n is the number of contractors. Contractors are also opened from the [Timeline](https://docs.snapfix.com/how-the-apps-work/screens/compliance/timeline.md), the [Dashboard](https://docs.snapfix.com/how-the-apps-work/screens/compliance/dashboard.md#document-list) and a system's contractor chip ([System detail](https://docs.snapfix.com/how-the-apps-work/screens/compliance/system-detail.md)).
* **Who:** site admins (role "Admin"); see [Dashboard](https://docs.snapfix.com/how-the-apps-work/screens/compliance/dashboard.md#getting-here). In the API, any member of the site can read the list \[[ASK-112](https://github.com/snapfix/docs/blob/main/ASK.md#ask-112-which-comply-reads-should-members-who-are-not-admins-get)].
* **Feature:** [Contractors](https://docs.snapfix.com/product/features/compliance/contractors.md)

## Layout

1. **Header:** "Contractors", a search box labelled "Search", and a "+" button with no label.
2. **Table:** the columns "Name", "Email", "Document", "Expiry Date", "Compliant" and "Action". Rows are sorted by name, A to Z.
   * "Name": the contractor's name.
   * "Email": the email, or "-".
   * "Document": the name of the contractor's first document, or "-".
   * "Expiry Date": the date as DD MMM YYYY, or "No Expiry Date".
   * "Compliant": a status dot whose tooltip is "In compliance", "Expiring compliance" or "Out of compliance".
   * "Action": a "⋮" button. It opens the contractor's page, as a click on the row does; it opens no menu.
3. **New row:** after "+", a row at the top with a name box (placeholder "Enter name"), "-" in the other columns and a trash icon.

## Inputs

| Field                 | Type | Required | Default | Rules and messages                                                                                                                  |
| --------------------- | ---- | -------- | ------- | ----------------------------------------------------------------------------------------------------------------------------------- |
| New contractor's name | Text | Yes      | Empty   | Typed in the new row. Saved on Enter or when the box loses focus. An empty name is not sent, and the row stays open with no message |
| Search                | Text | No       | Empty   | Filters the rows by name about a second after the last key press, with no request. No text shows when nothing matches               |

## Actions

| Action                    | Who         | What happens                                                                                                                                                                                                                                                                                                                                      | API                                                                                                                             |
| ------------------------- | ----------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------- |
| Open the tab              | Site admins | Disables every Comply tab, loads the contractors with their documents, then turns the tabs back on                                                                                                                                                                                                                                                | [`GET /v1/app/comply/contractor`](https://docs.snapfix.com/engineering-reference/api/compliance.md#get-v1appcomplycontractor)   |
| "+"                       | Site admins | Adds the new row with its name box in focus. One new row at a time                                                                                                                                                                                                                                                                                | -                                                                                                                               |
| Save the new name         | Site admins | Creates the contractor and opens [Contractor detail](https://docs.snapfix.com/how-the-apps-work/screens/compliance/contractor-detail.md). New contractors start with the frequency "None" and a 30-day alert \[[ASK-109](https://github.com/snapfix/docs/blob/main/ASK.md#ask-109-what-should-frequency-do-and-what-should-new-items-start-with)] | [`POST /v1/app/comply/contractor`](https://docs.snapfix.com/engineering-reference/api/compliance.md#post-v1appcomplycontractor) |
| Trash icon on the new row | Site admins | Discards the row                                                                                                                                                                                                                                                                                                                                  | -                                                                                                                               |
| Click a row, or "⋮"       | Site admins | Opens [Contractor detail](https://docs.snapfix.com/how-the-apps-work/screens/compliance/contractor-detail.md)                                                                                                                                                                                                                                     | -                                                                                                                               |

## States

* **Loading:** every Comply tab is disabled until the list arrives; the table shows only its header.
* **Empty:** only the header row, with no text.
* **Error:** a failed call shows the API's message in the shared alert. A failed list leaves every Comply tab disabled until the page is reloaded.
* **No permission:** a non-admin never reaches the page.
* **Offline (mobile):** not applicable (web only).

## Dialogs and sheets

None. The contractor's fields, users, assets and documents are on [Contractor detail](https://docs.snapfix.com/how-the-apps-work/screens/compliance/contractor-detail.md).

## Platform differences

Web only. The apps have no contractor screens ([Comply](https://docs.snapfix.com/how-the-apps-work/screens/compliance/mobile-notice.md)).


---

# 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/compliance/contractors.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.
