---
# REST Decision Service: `VacationDays`

## Overview

**`VacationDays`** is a decision service exposed via a RESTful HTTP API. It accepts structured input data, evaluates the embedded decision logic, and returns a structured decision result.
The decision service goal is **`DetermineVacationDays`**.
---
---

## Endpoints

| Method | Path                           | Description |
|--------|--------------------------------|-------------|
| `POST` | `../vacation-days`              | Execute the decision model |
| `GET`  | `../vacation-days/schema.json`  | Retrieve the service description in MCP tool format |

---
## MCP Tool Schema
A JSON schema describing this service in MCP tool format is available at:

GET ../decision-loan/schema.json

Agents should fetch this schema to discover input/output structure dynamically.

## Request

**`POST ../vacation-days`**

## Request Parameters
### `company`

| Variable Name | JSON Field | Type | Required | Domain | Default | Description |
|---|---|---|---|---|---|---|
| Vacation Days Min | `vacationDaysMin` | `Integer` | No |  | 22 |  |
| Vacation Days Max | `vacationDaysMax` | `Integer` | No |  | 31 |  |
### `employee`

| Variable Name | JSON Field | Type | Required | Domain | Default | Description |
|---|---|---|---|---|---|---|
| Age in Years | `age` | `Integer` | **Yes** |  |  |  |
| Years of Service | `service` | `Integer` | **Yes** |  |  |  |
| Student | `student` | `Boolean` | No |  | false |  |
| Veteran | `veteran` | `Boolean` | No |  | false |  |

## Response Fields
### `results`

| Variable Name | JSON Field | Type | Description |
|---|---|---|---|
| Explanations | `explanations` | `String[]` |  |
| Vacation Days | `vacationDays` | `Integer` |  |

## Response Envelope
```json
{
  "decisionStatusCode": 200,
  "response": { ... },
  "executedRules": ["rule1", "rule2"],
  "errorMessage": null
}
```


## Usage Notes
- The `VacationDays` service is **stateless** meaning each call is independent.
- All timestamps follow **ISO 8601** format (UTC).
- To populate `executedRules` in the response, include `"trace": true` in the request.
- `decisionStatusCode` 200 indicates success.
- `decisionStatusCode` 4xx/5xx indicates an error shown in `errorMessage`.
- Generated by OpenRules Decision Manager 11.3.0 (build of 2026-04-04).
