CQRS
Base URL
Every path below is relative to https://api.laksonoteknologi.com/v2.
Applies to every endpoint on this page
Accept-Languageheader (or?lang=query param, which wins if both are sent) picks the response/error locale - optional, falls back to the server's configured default if neither is sent.- Successful responses are
{"response_code":"001", "response_text":"Success", "data": {...}}.
Get Commands
/v2/cqrs/commandsqueryLists every registered command (POST/PUT/PATCH/DELETE endpoint) with its full metadata - path, method, description, permission key, middleware chain, tags. This is the exact data the docs site generator introspects to build the public API docs, so it's deliberately left public (no auth) even though the data it returns is later republished with no auth anyway one layer up. Optionally filter by group/method/tag/name substring/deprecated. Paginated.
Headers
Accept-Language: en (optional - defaults to server config, or use ?lang= instead)Plain query parameters - no request body /
commandfield needed.
Request fields
| Field | Source | Type | Required | Validation |
|---|---|---|---|---|
group | query | string | false | omitempty |
method | query | string | false | omitempty,oneof=POST PUT PATCH DELETE |
tag | query | string | false | omitempty |
name | query | string | false | omitempty,notblank,min=2,max=100 |
deprecated | query | boolean | false | omitempty |
page | query | integer | false | min=1 |
page_size | query | integer | false | min=1,max=100 |
Example
Get Cqrs Health
/v2/cqrs/healthqueryLightweight health/liveness check for the CQRS registry itself (not an individual command/query) - no request params, no auth required, meant for uptime probes rather than admin dashboards.
Headers
Accept-Language: en (optional - defaults to server config, or use ?lang= instead)Plain query parameters - no request body /
commandfield needed.
Example
Get Cqrs Stats
/v2/cqrs/statsqueryReturns registry-wide CQRS stats - total command/query counts and related aggregates - with three optional breakdowns you can toggle on: include_groups (per-group counts), include_middlewares (per-middleware usage), include_paths (per-path detail). Response is cached 5 minutes server-side, so a change to the registry may take up to that long to show up here. Admin-auth only.
Headers
Authorization: Bearer <token>
Accept-Language: en (optional - defaults to server config, or use ?lang= instead)Plain query parameters - no request body /
commandfield needed.
Request fields
| Field | Source | Type | Required | Validation |
|---|---|---|---|---|
include_groups | query | boolean | false | omitempty |
include_middlewares | query | boolean | false | omitempty |
include_paths | query | boolean | false | omitempty |
Example
Get Queries
/v2/cqrs/queriesqueryLists every registered query (GET/POST-as-read endpoint) with its full metadata - path, method, description, permission key, middleware chain, tags, plus query-specific flags (cacheable/paginated). Same public-by-design docs-generator source as get-commands. Optionally filter by group/method/tag/name substring/cacheable/paginated/deprecated. Paginated.
Headers
Accept-Language: en (optional - defaults to server config, or use ?lang= instead)Plain query parameters - no request body /
commandfield needed.
Request fields
| Field | Source | Type | Required | Validation |
|---|---|---|---|---|
group | query | string | false | omitempty |
method | query | string | false | omitempty,oneof=GET POST |
tag | query | string | false | omitempty |
name | query | string | false | omitempty,notblank,min=2,max=100 |
cacheable | query | boolean | false | omitempty |
paginated | query | boolean | false | omitempty |
deprecated | query | boolean | false | omitempty |
page | query | integer | false | min=1 |
page_size | query | integer | false | min=1,max=100 |
Example
Search Cqrs
/v2/cqrs/searchqueryFull-text searches across registered commands and queries by name/description/path via the required q param (min 2 chars). Narrow results with type (command/query/all), group, and/or deprecated. Admin-auth only, unlike get-commands/get-queries which expose the same underlying data publicly.
Headers
Authorization: Bearer <token>
Accept-Language: en (optional - defaults to server config, or use ?lang= instead)Plain query parameters - no request body /
commandfield needed.
Request fields
| Field | Source | Type | Required | Validation |
|---|---|---|---|---|
q | query | string | true | required,notblank,min=2,max=200 |
type | query | string | false | omitempty,oneof=command query all |
group | query | string | false | omitempty |
deprecated | query | boolean | false | omitempty |
Example
Groups
Get Group Stats
/v2/cqrs/groups/:group_name/statsqueryReturns stats scoped to one CQRS group (e.g. 'system', 'auth', 'profile' - the WithGroupName value each command/query is registered under), identified by group_name in the path. 404s if the group name doesn't match any registered item. Cached 3 minutes server-side. Admin-auth only.
Headers
Authorization: Bearer <token>
Accept-Language: en (optional - defaults to server config, or use ?lang= instead)Plain query parameters - no request body /
commandfield needed.
Request fields
| Field | Source | Type | Required | Validation |
|---|---|---|---|---|
:group_name | path | string | true | required,notblank |
Example
Middlewares
Get Middleware Stats
/v2/cqrs/middlewares/:middleware_name/statsqueryReturns usage stats for one named middleware (e.g. MWAuthAdmin) - how many registered commands/queries have it in their chain - identified by middleware_name in the path. Cached 3 minutes server-side. Admin-auth only.
Headers
Authorization: Bearer <token>
Accept-Language: en (optional - defaults to server config, or use ?lang= instead)Plain query parameters - no request body /
commandfield needed.
Request fields
| Field | Source | Type | Required | Validation |
|---|---|---|---|---|
:middleware_name | path | string | true | required,notblank |
Example