Skip to main content
Version: 2.0

Update a Value List

PATCH https://api.fraudio.com/v1/value-lists/:value_list_id

Endpoint Overview​

The "Update Value List" endpoint allows you to modify and adjust a specific value list using its unique identifier. This capability ensures that as your organization's requirements change, the reusable values referenced by your rules can evolve to match.

tip

If you face any challenges when updating a value list or need clarity on certain aspects of this endpoint, don't hesitate to contact our Support Team. We're eager to help.

Request Parameters​

Path Parameters​

The endpoint requires the following path parameter:

  • value_list_id: The unique identifier (UUID) of the value list you wish to update.

Example Request With Path Parameter

PATCH https://api.fraudio.com/v1/value-lists/123e4567-e89b-12d3-a456-426614174000

Request Body​

The body of the request should contain the fields of the value list you wish to update. You can replace all entries with entries, or apply incremental changes with entriesToAdd and entriesToRemove. Do not combine entries with entriesToAdd or entriesToRemove.

note

You cannot change slug or matchType while non-archived rules still reference the value list.

Example:

{
"displayName": "Blocked countries updated",
"entriesToAdd": ["cn"],
"entriesToRemove": ["kp"]
}

Request parameters: Field Reference Table​

FieldData TypeDescription
displayNameString
Updated human-readable name. Optional; send only fields you want to change.
slugString
Updated slug. Optional. Cannot change while non-archived rules still reference the list.
entriesArray of String
Full replacement of all entries. Optional. Do not combine with entriesToAdd or entriesToRemove.
entriesToAddArray of String
Values to add. Optional. Do not combine with entries.
entriesToRemoveArray of String
Values to remove. Optional. Do not combine with entries.
matchTypeString
Updated match type. Optional. Cannot change while non-archived rules still reference the list.
statusString
Updated status. Optional. Can be enabled or archived. Prefer DELETE to archive.

Response Parameters​

Status CodeStatus MessageDescriptionSchema
200OKStandard response for successful HTTP requests when updating a value list.200 OK - Value List updated response
400Bad RequestResponse when the request body is malformed or contains invalid data.Problem response
404Not FoundResponse when the specified value list ID does not exist.Problem response
4xx, 500, 501, 502, 503, 504errorVarious error messages for unsuccessful HTTP requests.Problem response

Code Samples​

curl -X PATCH 'https://api.fraudio.com/v1/value-lists/YOUR_VALUE_LIST_ID_HERE' \
-H 'Content-Type: application/json' \
-H "authorization: Bearer $ACCESS_TOKEN" \
-d '{
"displayName": "Blocked countries updated",
"entriesToAdd": ["cn"],
"entriesToRemove": ["kp"]
}'