Payload Validation Error when Filtering User Export with Query Parameter

Overview

This article explains why the following error occurs when attempting to export a list of users filtered by a specific value using the query parameter in the /api/v2/jobs/users-exports endpoint.

 

Payload validation error

 

Applies To

  • Management API
  • User Export
  • /api/v2/jobs/users-exports

Cause

The /api/v2/jobs/users-exports endpoint does not support server-side filtering via the query parameter. This parameter is invalid for this specific operation, resulting in a payload validation error.

Solution

Server-side filtering is not available for user exports. Follow these steps to achieve the desired result by filtering locally:

  1. Remove the query parameter from the API request.

  2. Include the target custom field (for example, app_metadata.test) in the fields array within the request body.

  3. Execute the request to export all users.

  4. Filter the resulting export file locally to isolate the users with the specific value.

Recommended content

No recommended content found...