Valid json
ValidJSON
Bases: BaseValidator
Class that provides functionality to check if a value matches a basic JSON structure.
Source code in dynamiq/nodes/validators/valid_json.py
6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 |
|
validate(content)
Validates if the provided string is a properly formatted JSON.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
content(str) |
The value to check. |
required |
Raises:
Type | Description |
---|---|
ValueError
|
If the value is not a properly formatted JSON. |
Source code in dynamiq/nodes/validators/valid_json.py
11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 |
|