# Paycom (Legacy)

## Overview <a href="#overview" id="overview"></a>

The **HR Module with Paycom** Book integrates with Paycom, enabling you to automate and simplify HR management. This integration enables users to perform a wide range of operations on Paycom data, including querying employee details, and managing punch entries.

## Prerequisites <a href="#prerequisites" id="prerequisites"></a>

1. **Paycom Account**: You need to have an active Paycom account. If you do not have one, you can sign up for a Paycom account to get started.
2. **API Access**: Ensure that your Paycom account has API access enabled. API access is required for Kognitos to communicate with Paycom.
3. **Credentials**: Obtain your Paycom environment, username, and password. These credentials are necessary to establish a secure connection with Paycom.

## Learning the Paycom HR and Payroll Book <a href="#learning-the-paycom-hr-and-payroll-book" id="learning-the-paycom-hr-and-payroll-book"></a>

To use this Book, you must **learn** it in your agent first.

1. Navigate to **Books → All Books.**
2. Search for **HR Module with Paycom** and click on it.
3. Click on **Add Connection**.
4. Add in the credentials when you are prompted:
   1. **Paycom Environment**: The environment of your Paycom instance (e.g., "production").
   2. **Username**: The email address or username associated with your Paycom account.
   3. **Password**: The password for your Paycom account.

## Procedures

### Querying Employee Details <a href="#querying-employee-details" id="querying-employee-details"></a>

**Get an Employee's Details**

To retrieve details of a specific employee by their ID:

```
get an employee's details whose
    employee id is "12345"
```

**Get Some Employees' Details**

To retrieve details of multiple employees based on specific filters:

```
get some employees details where
    the department is "Engineering"
    the job title is "Software Developer"
```

### Creating Punch Entries <a href="#creating-punch-entries" id="creating-punch-entries"></a>

To create a new punch entry for an employee:

```
create an employee's punch entry with
    the EntryType is "clock in"
    the PunchTime is "2023-04-01T08:00:00"
    the EmployeeId is "12345"
    the PunchDesc is "Morning shift start"
    the PunchType is "start"
```

### Deleting Punch Entries <a href="#deleting-punch-entries" id="deleting-punch-entries"></a>

To delete an existing punch entry for an employee:

```
delete the employee's punch entry with
    the punch ID is "12345"
```
