Skip to Content
ReferenceAPI referenceCrowdSec

List active CrowdSec decisions, one row per target

GET
/api/v1/crowdsec/decisions

Returns the active decisions grouped by target, in the order the LAPI lists them, paged with currentPage and pageSize. total counts targets, not decisions. The country, city and 24-hour request count come from GeoMetrikks' own access logs of the last 30 days, and the GeoIP database fills in the place for an IP the logs do not locate.

Authorization

cookiesession<token>

Session cookie authentication.

Query Parameters

currentPage?integer

The page to return, counted from 1. Defaults to 1.

Range1 <= value
Default1
pageSize?integer

Rows per page, from 1 to 500. Defaults to 10.

Range1 <= value <= 500
Default10
origins?|

A comma-separated list of origins to keep, such as crowdsec,cscli,CAPI. Defaults to crowdsec,cscli,geometrikks, which leaves out the blocklists. An IP or CIDR in q ignores it.

q?|

Search, up to 200 characters. An IP or CIDR matches decisions on addresses inside it and ranges that hold it, across every origin. Other text matches the start of the target or any part of a scenario name, ignoring case.

Lengthlength <= 200

Response Body

Request fulfilled, document follows

application/json
  1. response

One page of results. total counts the matches on every page, limit is the page size and offset is how many matches come before this page.

items?array<>
limit?integer

Maximal number of items to send.

offset?integer

Offset from the beginning of the query.

total?integer

Total number of items.

Example Request
curl -X GET 'https://geometrikks.example.com/api/v1/crowdsec/decisions'
Example Response
{  "items": [    {      "city": "string",      "countryCode": "string",      "countryName": "string",      "decisionCount": 0,      "decisions": [        {          "duration": "string",          "id": 0,          "origin": "string",          "scenario": "string",          "type": "string"        }      ],      "duration": "string",      "ip": "string",      "origins": [        "string"      ],      "requestCount24h": 0,      "scope": "string",      "type": "string"    }  ],  "limit": 0,  "offset": 0,  "total": 0}