Back

Popdock API – How to Successfully Filter by Date Range

Published: Sep 25, 2025
Post Author Written by Maksudul Haq

Filtering Popdock API results by a date range requires some extra setup. By default, Popdock API parameters work as equals filters, meaning you can only match an exact value. If you want to return records between two dates, for example, all sales transactions within a specific time frame, you first need to configure a restriction list and add a variable restriction before exposing the API endpoint.

If you’d like to watch a video explaining this, see below or click here.

Contents

Prerequisite Setup – Create a Restriction List

Add a Variable Restriction to the list

Create an API Endpoint

Add Date filters to API Endpoint

Testing and Troubleshooting

Configuration

Below are the setup steps to configure an API endpoint that can be filtered for a date range using the provided startDate and endDate parameters.

Prerequisite Setup – Create a Restriction List

Before you configure the API endpoint, you will need to create a new restriction list based on the list that contains the desired data. This ensures that any restrictions, customizations, or logic required for use by the external app through the Popdock API will not affect the original list.

1. From the main menu in Popdock, select Connectors. Then edit the desired connector.

2. Select Groups and then select Add group.

3. Create a new group named API Endpoints and then click Add.

4. Select Custom lists.

5. Select Add custom list and then select the Restrict data in a list.

6. Provide a Name for the list, for example you could name the list Sales Transactions API List.

7. For the Base list, select the existing list you want to use in the API.

8. Select the API Endpoints, for the Group.

9. Check Select all or choose the desired fields from the list.

10. Select Add list.

Add a Variable Restriction to the list

11. Select Variables.

12. Select Add user variable.

13. Add a new user variable

14. In the Name field, enter StartDate.

15. For the Field type, select Date from the dropdown list.

16. Select Relative date, for the Default value type.

17. Select Start of month for the Default value.

The default value of the variable will define the start date filter if the endpoint is called without the StartDate parameter provided. Any Default date value will be accepted here.


18. Select Add.

19. Select Add variable to add a second variable.

20. In the Name field, enter EndDate.

21. For the Field type, select Date from the dropdown list.

22. Select Constant for the Default value type.

23. Select Any date for the Default value.

Setting a default value far in the future will allow all records to be returned if the EndDate parameter is not set on the endpoint.


24. Select Add.

25. Select Restrictions.

26. Select Add restrictions.

27. In the Field dropdown, select the date field you will be filtering.

28. For the Restriction type, select Greater than.

29. For the Value, change the value type to Select variable. Then set the value to StartDate

30. Add another restriction.

31. In the Field dropdown, select the date field you will be filtering.

32. For the Restriction type, select Less than.

33. For the Value, change the value type to Select variable. Then set the value to EndDate.

Create a Popdock API Endpoint

34. From the main menu, select Security.

35. Select API users and then create an API User.

36. Save the generated API token for use later.

37. From the main menu, select Endpoints.

38. Select Add endpoint.

39. In the Name field, enter a name for the endpoint.

40. For the Endpoint, you can enter a customizable API endpoint.

41. Select your connector that contains the restriction list you created, from the Connector dropdown.

42. Select API Endpoints for the Group.

43. Select the restriction list you created.

44. You can leave the Favorite set to Default view.

45. If the connector uses companies, select the desired company from the Company dropdown list.

If multiple companies are needed in the endpoint, a merged list can be created instead of the restriction list and the endpoint built based on the merged list.

46. Select Add.

47. Select Fields.

48. Add all the fields that you want to be available on the endpoint.

49. Click Add.

50. Navigate to Security.

51. Grant the API user you created earlier access to the endpoint.

52. Click Add.

Add Date filters to API Endpoint

53. Select Parameters.

54. Add the StartDate and EndDate parameters.

55. Select API endpoints.

56. Copy the Get data endpoint.

Testing and Troubleshooting

To test the endpoint, use the copied Get data endpoint and access token to make a Postman call:

1. Open Postman.

2. Create a new request.

3. Add the endpoint URL.

4. Select the Authorization tab. Set Auth Type to Bearer Token. Add the user token to the Token field.

5. Select the Params tab and add StartDate and EndDate as parameters

Always send dates to Popdock endpoints in (yyyy-MM-dd) format. Popdock will automatically convert this into the correct format for your target application.

6. Click Send and review the response Body to confirm whether the data is returned as expected.

If you have questions on configuring API endpoints, contact support@eonesolutions.com

Feeling stuck? Get the support and guidance you need to help you power through any data challenge

We're on your integration team. Connect with our people and let us know how we can help you.