Skip to main content

Endpoint

POST /businesses Creates a new business record and returns an HTML partial with the updated business table rows, ordered by created_at descending (first page only).

Request body

Send as multipart/form-data or application/x-www-form-urlencoded.
name
string
required
Business name. Must be non-empty after trimming whitespace. Maximum 255 characters.
industry
string
Industry category (e.g., crypto, banking, healthcare, gambling). If omitted or blank, stored as null.
country
string
Country name (e.g., USA, Germany, Iran). If omitted or blank, stored as null.

Response

Returns the partials/business_rows.html fragment: the full first page of businesses (up to 15), ordered by created_at descending, including the newly created business.

Error responses

StatusDescription
422 Unprocessable Entityname is empty (after trimming) or exceeds 255 characters.

Example

curl -X POST http://localhost:8000/businesses \
  -F "name=Acme Corp" \
  -F "industry=technology" \
  -F "country=USA"
The industry and country values directly affect the simulated risk score when an evaluation is run. High-risk industries such as crypto and gambling add positive modifiers to the score. Sanctioned countries (Iran, Russia, North Korea, Syria) also increase the score. See Risk evaluation for a full breakdown of how scores are calculated.

Build docs developers (and LLMs) love