Skip to main content
POST
/
api
/
v1
/
secure
/
check-compliance
Check Compliance
curl --request POST \
  --url https://padsplit.fairsentry.com/api/v1/secure/check-compliance \
  --header 'Content-Type: application/json' \
  --header 'X-API-Key: <api-key>' \
  --data '
{
  "input_text": "<string>",
  "city": "<string>",
  "state": "<string>",
  "listing_id": "<string>",
  "host_id": "<string>",
  "section_type": "<string>"
}
'
{
  "compliant": true,
  "violation_summary": "<string>",
  "violation_categories": [
    "<string>"
  ],
  "compliant_suggestions": [
    "<string>"
  ],
  "severity": 123
}

Authorizations

X-API-Key
string
header
required

Body

application/json
input_text
string
required

The text content of the listing, or section of the listing, to check for compliance.

city
string | null

The name of the city where the listing is located.

state
string | null

The state where the listing is located. Can be either the abbreviated (CA) or full name (California).

listing_id
string | null

The unique identifier for the listing. If not provided, the result will not be stored or affect any metrics on the dashboard. This can be useful for testing purposes.

host_id
string | null

The unique identifier for the host of the listing.

section_type
string | null

The type of section from the listing that is being checked for compliance. It is recommended to use a predefined set of values (e.g. an enum) for this field to ensure consistency across your codebase. For example, 'title', 'description', 'rules', etc.

Response

Successful Response

compliant
boolean
required

Whether the input text is potentiallycompliant with fair housing laws.

violation_summary
string | null

A summary of the potential violations found in the input text, if any.

violation_categories
string[] | null

The categories of potential violations found in the input text, if any.

compliant_suggestions
string[] | null

Suggestions for potentially making the input text compliant, if applicable.

severity
integer | null

The severity level of the potential violations found, if any. This is a number between 1 and 10.