/v1/rule-setsReturns each loaded rule set that names a jurisdiction, at its version. Each item of a set has its id, the format it names, the files a check decides for it, the files made for it whatever the company’s settings say, and references: where to read each rule that names it, with a link to the official text. It is information only and not part of the validation. Also each fact’s assumed defaults, in the order they are tried; the rulebooks that check each file Certinvo makes; and each rulebook’s kind: decided (a decision picks it), extra (the company’s own extra check) or claimed (it runs only on a file that claims it). Whether an item is turned off is the company’s setting, in GET /v1/validation-policy. This answer holds no company data: it is the same for every caller. Any credential may read it.
Response
A 200 answer carries these fields.
- ruleSetsarray of objectRequired
Show 5 child fields
- idstringRequired
- versionstringRequired
- jurisdictionstringRequired
- nationalbooleanRequired
True for a country's own rules; false for rules above the countries
- obligationsarray of objectRequired
The items of the rule set, each of which the company can turn off for an establishment.
Show 5 child fields
- idstringRequired
The item, as a policy's
offnames it. - formatstring or nullRequired
The format the item names, such as
EN16931. Null when it names none. - filesarray of stringRequired
The files a check decides for the item.
- requiredarray of stringRequired
The files made for the item whatever the settings say.
- referencesarray of objectRequired
Where to read each rule that names the item, each once.
Show 2 child fields
- labelstringRequired
The name of the law and its article.
- urlstring (uri)Required
The official text.
- factsarray of objectRequired
Show 2 child fields
- namestringRequired
- assumedarray of objectRequired
The defaults the rules assume when nobody states the fact, in the order they are tried. Each applies when the fact
fromholds, or equalsequals; withoutvalueit is that fact's own value.Show 3 child fields
- fromstringRequired
- equalsstring
- valuestring or boolean
- filesarray of objectRequired
Show 2 child fields
- idstringRequired
- rulebooksarray of stringRequired
- rulebooksarray of objectRequired
Show 2 child fields
- namestringRequired
- kindstringRequiredOne of
decided,extra,claimed.
Status codes
| Status | Meaning |
|---|---|
200 |
The rule sets. |
401 |
No usable credential was sent (invalid_credentials). |
/v1/rule-setscurl https://api.certinvo.com/v1/rule-sets \
-H "Authorization: Bearer $CERTINVO_API_KEY"const response = await fetch(`https://api.certinvo.com/v1/rule-sets`, {
headers: {
Authorization: `Bearer ${process.env.CERTINVO_API_KEY}`,
},
})
console.log(response.status, await response.json())import os
import requests
response = requests.get(
"https://api.certinvo.com/v1/rule-sets",
headers={"Authorization": f"Bearer {os.environ['CERTINVO_API_KEY']}"},
)
print(response.status_code, response.text){
"ruleSets": [
{
"id": "string",
"version": "string",
"jurisdiction": "string",
"national": true,
"obligations": [
{
"id": "string",
"format": "string",
"files": [
"string"
],
"required": [
"string"
],
"references": [
{
"label": null,
"url": null
}
]
}
]
}
],
"facts": [
{
"name": "string",
"assumed": [
{
"from": "string",
"equals": "string",
"value": "string"
}
]
}
],
"files": [
{
"id": "string",
"rulebooks": [
"string"
]
}
],
"rulebooks": [
{
"name": "string",
"kind": "decided"
}
]
}