Skip to main content
POST
Count matching lawsuits and record a count request

Authorizations

api-key
string
header
required

Replace with the actual API key requirement for your Miner API deployment.

Body

application/json

Mirrors requestLawsuitsInputSchema in @judit-io/miner-shared (strict object).

Cross-field rules (enforced server-side):

  • If both amount_min and amount_max are set, amount_minamount_max.
  • For sentence-execution: budget_years and natures must be absent.
  • For judgement-bond: tags must be absent.
  • amount_tier cannot be used together with amount_min or amount_max.
kind
enum<string>
required
Available options:
judgement-bond,
sentence-execution
amount_min
number

Minimum lawsuit amount filter (cannot be combined with amount_tier)

amount_max
number

Maximum lawsuit amount filter (cannot be combined with amount_tier)

amount_tier
enum<string>
Available options:
0-100k,
100k-250k,
250k-500k,
500k-750k,
750k-1.5M,
1.5M+
tribunals
integer[]
budget_years
integer[]

Only when kind is judgement-bond

natures
enum<string>[]

Only when kind is judgement-bond

Available options:
alimentary,
common
tags
enum<string>[]

Only when kind is sentence-execution

Available options:
precatory_dispatched,
possible_precatory,
possible_approved_calculation
responses_limit
integer

Caps how many lawsuits are included in a find request (/requests/create only).

Required range: x >= 1

Response

Count stored; response includes totals and optional echo of filters.

request_id
integer<int64>
required
total_lawsuits
integer
required
Required range: x >= 0
status
enum<string>
required
Available options:
pending,
completed,
failed
filter
object

Subset of filters returned on GET request (when stored on the entity)