---
title: "Developer guide to get employee data from ADP Run API"
url: "https://lb.getknit.dev/blog/developer-guide-to-get-employee-data-from-adp-run-api/"
date: "2026-08-13T12:59:05+00:00"
modified: "2026-08-23T11:20:55+00:00"
type: "post"
---

# Developer guide to get employee data from ADP Run API

[Blog](https://lb.getknit.dev/blog) / [Tutorials](https://lb.getknit.dev/blogs/tutorials/) / Developer guide to get employee data from ADP Run API [Tutorials](https://lb.getknit.dev/blogs/tutorials/) · August 13, 2026 

Developer guide to get employee data from ADP Run API
=====================================================

 ![](https://storage.googleapis.com/knit-website-media/2026/08/64c34ca1e0546a9d333bb35a_Kunal-3-150x150.png)Kunal Mishra

3 min read

 

 

 [](https://www.linkedin.com/sharing/share-offsite/?url=https%3A%2F%2Flb.getknit.dev%2Fblog%2Fdeveloper-guide-to-get-employee-data-from-adp-run-api%2F) [](https://twitter.com/intent/tweet?url=https%3A%2F%2Flb.getknit.dev%2Fblog%2Fdeveloper-guide-to-get-employee-data-from-adp-run-api%2F&text=Developer%20guide%20to%20get%20employee%20data%20from%20ADP%20Run%20API)  

 

 

 

  Table of Contents - [Introduction](#)
- [Get Employee Data from ADP Run API](#)
- [Prerequisites](#)
- [API Endpoints](#)
- [Step-by-Step Guide](#)
- [Common Pitfalls](#)
- [Frequently Asked Questions](#)
- [Knit for ADP Run API Integration](#)
 
  Introduction
------------

This article is a part of a series of [HRIS integration articles](/solutions/integrations-for-employee-onboarding-platforms/) covering the ADP Run API in depth, and covers the specific use case of using the ADP Run API to get employee data.

Get Employee Data from ADP Run API
----------------------------------

### Prerequisites

- Obtain OAuth 2.0 credentials (Client ID and Client Secret) from ADP.
- Ensure you have the necessary permissions to access worker data.
- Install Python and the `requests` library.

### API Endpoints

- Get all employees: `/hr/v2/workers`
- Get a specific employee: `/hr/v2/workers/{aoid}`

### Step-by-Step Guide

#### 1. Get All Employees

```
import requests

def get_all_employees(access_token):
    url = "https://api.adp.com/hr/v2/workers"
    headers = {
        "Authorization": f"Bearer {access_token}",
        "Content-Type": "application/json"
    }
    
    response = requests.get(url, headers=headers)
    
    if response.status_code == 200:
        return response.json()
    else:
        return response.status_code
```

#### 2. Get a Specific Employee

```
def get_employee_by_aoid(access_token, aoid):
    url = f"https://api.adp.com/hr/v2/workers/{aoid}"
    headers = {
        "Authorization": f"Bearer {access_token}",
        "Content-Type": "application/json"
    }
    
    response = requests.get(url, headers=headers)
    
    if response.status_code == 200:
        return response.json()
    else:
        return response.status_code
```

### Common Pitfalls

1. Using incorrect or missing OAuth 2.0 credentials.
2. Not having the right permissions to access worker data.
3. Calling the wrong API endpoint.
4. Ignoring HTTP response codes instead of handling them properly.
5. Letting access tokens expire without refreshing them.

### Frequently Asked Questions

**1. What format does the ADP Run API return data in?**
All responses are in JSON format, making them straightforward to parse in most programming languages.

**2. How do I handle pagination when fetching employees?**
ADP uses OData parameters for pagination. Use `$top` to limit results per page and `$skip` to move through subsequent pages.

**3. What should I do if I get a 401 Unauthorized error?**
This usually means your access token is invalid or expired. Refresh your token using OAuth 2.0 and retry the request.

**4. Can I filter the employee data I retrieve?**
Yes. Use the OData `$filter` parameter to narrow results (e.g., filter by department or employment status).

**5. How can I return only specific fields in the response?**
Use the OData `$select` parameter to specify exactly which fields you want, instead of retrieving the entire object.

Knit for ADP Run API Integration
--------------------------------

For quick and seamless access to [ADP Run API](/integration/adp-run-hris/), Knit API offers a convenient solution. By integrating with Knit just once, you can streamline the entire process. Knit takes care of all the authentication, authorization, and ongoing integration maintenance. This approach not only saves time but also ensures a smooth and reliable connection to your [ADP Run API](/mcp-servers/adp-run-hris-mcp-server/).

‍

 

 ![](https://storage.googleapis.com/knit-website-media/2026/08/64c34ca1e0546a9d333bb35a_Kunal-3-150x150.png)Written by Kunal Mishra

Changing integration landscape, one organization at a time‍

 

 

 

 

 

   Keep Reading
------------

  ![](https://storage.googleapis.com/knit-website-media/2026/08/blog-banner-green-640x400.png) [Tutorials](https://lb.getknit.dev/blogs/tutorials/) 

### [How to Create a Slack Bot in 5 Minutes: A to Z Guide](https://lb.getknit.dev/blog/how-to-create-a-slack-bot/)

You can create your own Slack Bot in just a few minutes with the Knit Unified API. Read this step-by-step…

 August 13, 2026 · 3 min read 

 

   ![](https://storage.googleapis.com/knit-website-media/2026/08/blog-banner-green-640x400.png) [Tutorials](https://lb.getknit.dev/blogs/tutorials/) 

### [How to Build and Deploy a Microsoft Teams Bot](https://lb.getknit.dev/blog/how-to-build-and-deploy-a-microsoft-teams-bot/)

You can either build Microsoft Teams Bot on your own or you can use Knit's Unified API to create it…

 August 13, 2026 · 4 min read 

 

   ![](https://storage.googleapis.com/knit-website-media/2026/08/blog-banner-yellow-scaled-640x400.png) [Tutorials](https://lb.getknit.dev/blogs/tutorials/) 

### [What Should You Look For in A Unified API Platform?](https://lb.getknit.dev/blog/what-should-you-look-for-in-a-unified-api-platform/)

The right unified API can solve all your integration woes at minimal effort and cost. Read this to know how…

 August 13, 2026 · 14 min read 

 

  

 

  \#1 in Ease of Integrations
---------------------------

![4.9 out of 5 stars](/wp-content/themes/knit/assets/images/g2/g2-star-rating.svg)

4.9 out of 5 stars on G2

![G2 Leader, Spring 2026](/wp-content/themes/knit/assets/images/g2/g2-leader.svg)![G2 Fastest Implementation, Spring 2026](/wp-content/themes/knit/assets/images/g2/g2-fastest-implementation.svg)![G2 High Performer, Spring 2026](/wp-content/themes/knit/assets/images/g2/g2-high-performer.svg)![G2 Best Est. ROI, Spring 2026](/wp-content/themes/knit/assets/images/g2/g2-best-roi.svg)

 

  Put Integrations on Autopilot. Talk to Experts.
-----------------------------------------------

Knit is loved by customers across the globe due to our seamless product and white glove support. You'll love us too!

 [Talk to a Human](/book-demo)
