---
title: "GET /rule-spec"
method: GET
path: "/rule-spec"
tags: ["Law"]
---

# GET /rule-spec

`GET /rule-spec`

Get rule spec

## Query parameters

- `service` string, required
- `law` string, required
- `referenceDate` string, date, required — reference date

## Response `200`

Rule spec response

- object
  - `data` RuleSpec, required
    - `uuid` string, uuid, required — Unique identifier for the rule specification
    - `name` string, required — Name of the rule specification
    - `law` string, required — Associated law reference
    - `law_type` string, nullable — Type of law
    - `legal_character` string, nullable — Legal character of the rule
    - `decision_type` string, nullable — Type of decision
    - `discoverable` string, nullable — Discoverability setting
    - `valid_from` string, date-time, required — Date from which the rule is valid
    - `service` string, required — Associated service identifier
    - `description` string, required — Description of the rule specification
    - `references` Reference[] — Legal references
      - `law` string, required — Law reference
      - `article` string, required — Article reference
      - `url` string, uri, required — URL to the legal reference
    - `properties` Properties, required
      - `parameters` ParameterField[] — Parameter fields
        - `name` string, required — Field name
        - `description` string, required — Field description
        - `type` string, required — Field type
        - `type_spec` TypeSpec
          - `type` string, required — Specific type definition
          - `unit` string, nullable — Unit of measurement
          - `precision` integer, nullable — Precision for numeric types
          - `min` number, double, nullable — Minimum value
          - `max` number, double, nullable — Maximum value
        - `temporal` Temporal
          - `type` string, required — Temporal type
          - `period_type` string, nullable — Period type specification
          - `reference` string, nullable — Reference (can be string or VariableReference)
          - `immutable_after` string, nullable — Immutability rule
        - `required` boolean, nullable — Whether the field is required
      - `sources` SourceField[] — Source fields
        - `name` string, required — Field name
        - `description` string, required — Field description
        - `type` string, required — Field type
        - `type_spec` TypeSpec
          - `type` string, required — Specific type definition
          - `unit` string, nullable — Unit of measurement
          - `precision` integer, nullable — Precision for numeric types
          - `min` number, double, nullable — Minimum value
          - `max` number, double, nullable — Maximum value
        - `temporal` Temporal
          - `type` string, required — Temporal type
          - `period_type` string, nullable — Period type specification
          - `reference` string, nullable — Reference (can be string or VariableReference)
          - `immutable_after` string, nullable — Immutability rule
        - `required` boolean, nullable — Whether the field is required
        - `source_reference` SourceReference
          - `source_type` string — Type of the data source
          - `table` string — Table name in the source
          - `field` string, nullable — Specific field to reference
          - `fields` string[], nullable — Multiple fields to reference
          - `select_on` SelectField[] — Selection criteria
            - `name` string, required — Field name
            - `description` string, required — Field description
            - `type` string, required — Field type
            - `value` union, required — Represents a value in an operation (can be a primitive value or nested action)
              - …
          - `wallet_attribute` string — Name of the wallet attribute on a claim
        - `service_reference` ServiceReference
          - `service` string, required — Referenced service identifier
          - `field` string, required — Field in the referenced service
          - `law` string, required — Associated law
          - `parameters` Parameter[] — Service parameters
            - `name` string, required — Parameter name
            - `reference` string, required — Parameter reference
      - `input` InputField[] — Input fields
        - `name` string, required — Field name
        - `description` string, required — Field description
        - `type` string, required — Field type
        - `type_spec` TypeSpec
          - `type` string, required — Specific type definition
          - `unit` string, nullable — Unit of measurement
          - `precision` integer, nullable — Precision for numeric types
          - `min` number, double, nullable — Minimum value
          - `max` number, double, nullable — Maximum value
        - `temporal` Temporal
          - `type` string, required — Temporal type
          - `period_type` string, nullable — Period type specification
          - `reference` string, nullable — Reference (can be string or VariableReference)
          - `immutable_after` string, nullable — Immutability rule
        - `required` boolean, nullable — Whether the field is required
        - `service_reference` ServiceReference, required
          - `service` string, required — Referenced service identifier
          - `field` string, required — Field in the referenced service
          - `law` string, required — Associated law
          - `parameters` Parameter[] — Service parameters
            - `name` string, required — Parameter name
            - `reference` string, required — Parameter reference
      - `output` OutputField[] — Output fields
        - `name` string, required — Field name
        - `description` string, required — Field description
        - `type` string, required — Field type
        - `type_spec` TypeSpec
          - `type` string, required — Specific type definition
          - `unit` string, nullable — Unit of measurement
          - `precision` integer, nullable — Precision for numeric types
          - `min` number, double, nullable — Minimum value
          - `max` number, double, nullable — Maximum value
        - `temporal` Temporal
          - `type` string, required — Temporal type
          - `period_type` string, nullable — Period type specification
          - `reference` string, nullable — Reference (can be string or VariableReference)
          - `immutable_after` string, nullable — Immutability rule
        - `required` boolean, nullable — Whether the field is required
        - `citizen_relevance` string, required
      - `definitions` object — Additional definitions
      - `applies` Apply[] — Application rules
        - `name` string, required — Name of the application rule
        - `aggregate` string, required — Aggregate identifier
        - `events` ApplyEvent[], required — Associated events
          - `type` string, required — Event type
          - `filter` object, required — Event filter criteria
        - `update` Update[], required — Update rules
          - `method` string, required — Update method
          - `mapping` object, required — Field mapping configuration
    - `requirements` Requirement[] — Requirements for the rule
      - `all` ActionRequirement[], nullable — All requirements must be met (AND logic)
        - union — Either a nested requirement or an action
          - Requirement — recursive
          - Action
            - `output` string, required — Action output
            - `value` union — Represents a value in an operation (can be a primitive value or nested action)
              - …
            - `operation` string, nullable — Operation to perform
            - `subject` string, nullable — Subject of the action
            - `unit` string, nullable — Unit for the action
            - `combine` string, nullable — Combination method
            - `values` union — Represents multiple values or a single value
              - …
            - `conditions` Condition[] — Conditional logic
              - …
      - `or` ActionRequirement[], nullable — Any requirement must be met (OR logic)
        - union — Either a nested requirement or an action
          - Requirement — recursive
          - Action
            - `output` string, required — Action output
            - `value` union — Represents a value in an operation (can be a primitive value or nested action)
              - …
            - `operation` string, nullable — Operation to perform
            - `subject` string, nullable — Subject of the action
            - `unit` string, nullable — Unit for the action
            - `combine` string, nullable — Combination method
            - `values` union — Represents multiple values or a single value
              - …
            - `conditions` Condition[] — Conditional logic
              - …
    - `actions` Action[] — Actions associated with the rule
      - `output` string, required — Action output
      - `value` union — Represents a value in an operation (can be a primitive value or nested action)
        - Action — recursive
        - unknown
      - `operation` string, nullable — Operation to perform
      - `subject` string, nullable — Subject of the action
      - `unit` string, nullable — Unit for the action
      - `combine` string, nullable — Combination method
      - `values` union — Represents multiple values or a single value
        - ActionValue[]
          - union — Represents a value in an operation (can be a primitive value or nested action)
            - Action — recursive
            - unknown
        - unknown
      - `conditions` Condition[] — Conditional logic
        - `test` Action — recursive
        - `then` union — Represents a value in an operation (can be a primitive value or nested action)
          - Action — recursive
          - unknown
        - `else` union — Represents a value in an operation (can be a primitive value or nested action)
          - Action — recursive
          - unknown

## Other responses

- `400` — Invalid input supplied.
- `500` — Internal server error.

## Changes

> 15 revisions in range; 1 could not be searched.

- **2025-11-24** `b5fe3c24162e` — 1 info
  - added the optional property `data/properties/sources/items/allOf[subschema #2]/source_reference/wallet_attribute` to the response with the `200` status
- **2025-06-10** `478b6ca4b28e` — 14 info
  - added the optional property `data/actions` to the response with the `200` status
  - added the optional property `data/decision_type` to the response with the `200` status
  - added the optional property `data/discoverable` to the response with the `200` status
  - added the optional property `data/law_type` to the response with the `200` status
  - …10 more
- **2025-04-16** `73ada8f52635` — 7 breaking, 7 warning
  - removed the required property `data/description` from the response with the `200` status
  - removed the required property `data/law` from the response with the `200` status
  - removed the required property `data/name` from the response with the `200` status
  - removed the required property `data/properties` from the response with the `200` status
  - …10 more

[Change history](https://skmtc.dev/minbzk/apis/regelrecht-engine-api/changes/rule-spec/get.md)

---

[API](https://skmtc.dev/minbzk/apis/regelrecht-engine-api.md) · [All operations](https://skmtc.dev/minbzk/apis/regelrecht-engine-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/minbzk/regelrecht-engine-api/revisions/dd8f1496c9bc/schema)
