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

# Time clock

> Clock in and out from the mobile app with PIN, selfie, and location

The time clock lets employees record their **clock-in** and **clock-out** from the FileXpress mobile app. Each punch feeds the same daily [Attendance](https://docs.filexpress.app/en/docs/rrhh/asistencia.md) that is used when generating payroll, so there is no need to type or import those hours.

* The **first** punch of the day is the **clock-in**.
* The **second** punch of the day is the **clock-out**.
* A **third** punch is rejected. If something needs to be corrected, HR does it from **Human Resources → Attendance** on the web.

> [!NOTE]
>
> Employees **do not need a system user** to clock in. An administrator just has to assign them a PIN.

## Ways to clock in

> [card] With their account
>
> Employees who have a FileXpress user (linked to their record or with the same email). They clock in from **My time clock** in the app, **without a PIN**.

> [card] Branch clock
>
> A shared phone or tablet at the branch. Any employee of the company clocks in by typing their PIN.

> [card] Personal phone
>
> The employee's own phone, linked by an administrator. It only accepts that employee's PIN.

## Employee PIN

* It has **4 to 6 digits**.
* An administrator assigns it.
* It is **unique within the company** (two different companies can use the same number).
* It can be changed or removed at any time.

### Assign or change a PIN

> [tab] From the web
>
> **1. Go to Human Resources → Time clock → Employees and PIN tab**
>
> **2. Find the employee and assign the PIN**
>
> Type a 4 to 6 digit PIN and save. To delete it, use **Remove PIN**.
>
> **3. Give the PIN to the employee privately**

> [tab] From the app
>
> **1. Open More → Time clock**
>
> **2. Tap the employee**
>
> **3. Assign, change, or remove the PIN**

## Authorized devices

For security, a PIN **only works on an authorized device**. That way, if an employee shares their PIN, another person cannot clock in for them from just any phone.

### Set up a branch clock

**1. Sign in to the app with a system user**

Use the phone or tablet that will stay fixed at the branch.

**2. Go to Time clock and tap Use as branch clock**

**3. Leave the device available for employees**

To clock in, the employee just types their PIN; they do not have to search for their name.

### Link an employee's personal phone

**1. Generate the linking code**

In **Human Resources → Time clock → Employees and PIN** (or in the app, in **More → Time clock** by tapping the employee), choose **Link phone**. A **6-character** code is shown, valid for **10 minutes** and **single use**.

**2. The employee opens the app on their phone**

Without signing in, they tap **Clock in** on the home screen.

**3. The employee types the code**

From that moment, that phone only accepts that employee's PIN.

> [!WARNING]
>
> Each employee can have **only one personal phone** linked.

### Change phones

**1. Remove the current phone**

In the employee's record within **Time clock**, use **Remove phone** (in the app, the **Authorized phones** section).

**2. Generate a new code and link the new phone**

Follow the steps in [Link an employee's personal phone](#link-an-employees-personal-phone).

### Remove devices

An administrator can remove branch clocks (**Branch clocks** tab) and personal phones. A removed device stops accepting punches and asks to be linked again.

> [!NOTE]
>
> After **5 incorrect PINs**, the device is locked for **10 minutes**.

## How an employee clocks in

> [tab] With a PIN (clock or personal phone)
>
> **1. Open the app and tap Clock in**
>
> **2. Type the PIN**
>
> **3. Take the selfie with the front camera**
>
> The selfie is **mandatory** for punches with a PIN.
>
> **4. Confirm**
>
> The app indicates whether it was recorded as a clock-in or clock-out.

> [tab] With their account
>
> **1. Sign in to the app**
>
> **2. Open My time clock and clock in**

### Evidence saved with each punch

| Data | Detail |
| - | - |
| Selfie | Mandatory for punches with a PIN, taken with the front camera |
| GPS location | Saved if the employee granted location permission; if not, the punch is still accepted |
| Device | Personal phone, branch clock, or the employee's account |
| Branch | Branch from which the punch was made |

## Clock in without internet

If the phone has no connection, the punch **is not lost**:

1. It is saved on the phone with its **actual time**, the selfie, and the location, and the app shows **Punch saved**.
2. It is sent automatically when the connection returns: every minute, when the app is reopened, or before the next punch.
3. Punches up to **7 days** old are accepted.

> [!WARNING]
>
> The PIN of a punch made without internet is validated at sync time. If it was incorrect, the punch appears as **rejected** in the app and can be discarded.

## View punches on the web

Go to **Human Resources → Time clock**. The page has three tabs:

> [accordion] Punches
>
> Shows each punch with: selfie thumbnail, type (**clock-in** or **clock-out**), date and time, map link with the GPS accuracy, and the source (**Their account**, **Personal phone**, or **Branch clock**). Punches that arrived more than 5 minutes late carry the **Offline** label.
>
> You can filter by **employee** and by **date range**.

> [accordion] Employees and PIN
>
> List of employees with their PIN, account, and linked phone status. From here you assign PINs, link phones, and remove them.

> [accordion] Branch clocks
>
> Devices set up as a branch clock, with the option to remove them.

> [!NOTE]
>
> Selfies are private and are opened through temporary links. Only users with the **root** or **administrator** role can see punches and manage PINs and devices. See [Roles and permissions](https://docs.filexpress.app/en/docs/roles.md).

## FAQ and troubleshooting

> [accordion] The app says the PIN is incorrect
>
> Check the assigned PIN with the administrator in **Employees and PIN**. On a personal phone, only the PIN of the employee who owns that phone works. After 5 failed attempts the device is locked for 10 minutes.

> [accordion] Unauthorized device
>
> The phone is not set up as a branch clock or linked to an employee, or it was removed. Set it up as a clock or generate a new linking code.

> [accordion] Already clocked in and out
>
> Only two punches per day are allowed. To correct hours, HR edits the record in [Attendance](https://docs.filexpress.app/en/docs/rrhh/asistencia.md).

> [accordion] The phone's time is wrong
>
> Set the phone to automatic date and time. Punches saved offline use the phone's time, and the system rejects times in the future or more than 7 days old.

> [accordion] I want to link a second phone to the same employee
>
> It is not possible: you must first remove the current phone and then link the new one.

> [accordion] The linking code does not work
>
> The code expires after 10 minutes and can only be used once. Generate a new one.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.