본문으로 건너뛰기

API 문서

근본 사실로 규칙을 판단하기(추론 포함)

montaye 자체 규칙(공식 문서에서 읽고 문서에 인쇄된 계산 예와 대조함)을 보낸 필드로 판단합니다. us.resident_alien은 us.citizen, us.lawful_permanent_resident, 올해와 앞의 2년 동안 미국에 머문 날수(IRS Pub 519의 그린카드 테스트와 실질 체류 테스트)와 us.closer_connection_exception(그 더 밀접한 관계 예외)을 읽습니다. 이 항목을 보내지 않으면 법의 기준이 정합니다: 법이 날수로 선을 그은 부분은 날수대로(올해 183일 이상 머물렀으면 성립하지 않음), 아니면 나머지를 아무도 판단하지 않았을 때 기준이 정한 상태(Form 8840으로 주장하지 않았으면 성립하지 않음)이며, 추론은 그것을 읽는 단계에 붙습니다. 답은 참, 거짓 또는 알 수 없음이며, 기다리는 필드, 추론의 각 단계(산술은 정확히 계산, 기준선과의 차이), 읽어 온 문서와 쪽, 규칙이 사람의 판단에 맡기는 부분(세지 않는 날, 첫해의 선택)을 함께 돌려줍니다. 보낸 내용은 저장하지 않습니다. 규칙 목록은 GET /v1/status에 있습니다. 필드는 추가되기만 합니다.

REST: POST /v1/rules/evaluate MCP 도구: rule_evaluate API 키 필요
거절 코드
  • input_invalid (400) The request does not match the action’s input schema.
  • not_found (404) No such action or document.
  • rule_not_in_force (422) The rule montaye publishes by that code states the law of other days: no revision of it is in force on the day asked.
  • key_missing (401) This action needs an API key (Authorization: Bearer <key>).
  • key_invalid (401) The API key is unknown, revoked or expired.
  • rate_limited (429) Too many requests from this client; slow down.
  • plan_excludes_action (403) The account’s plan does not include this action.
입력 (JSON Schema)
{
  "type": "object",
  "properties": {
    "code": {
      "type": "string",
      "pattern": "^[a-z0-9_.-]+$"
    },
    "on": {
      "type": "string",
      "format": "date"
    },
    "fields": {
      "type": "object",
      "propertyNames": {
        "type": "string",
        "pattern": "^[a-z0-9_.]+$"
      },
      "additionalProperties": {
        "anyOf": [
          {
            "type": "string"
          },
          {
            "type": "integer",
            "minimum": -9007199254740991,
            "maximum": 9007199254740991
          },
          {
            "type": "boolean"
          },
          {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "from": {
                  "type": "string",
                  "format": "date"
                },
                "until": {
                  "anyOf": [
                    {
                      "type": "string",
                      "format": "date"
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "value": {
                  "anyOf": [
                    {
                      "type": "string"
                    },
                    {
                      "type": "integer",
                      "minimum": -9007199254740991,
                      "maximum": 9007199254740991
                    },
                    {
                      "type": "boolean"
                    }
                  ]
                }
              },
              "required": [
                "from",
                "until",
                "value"
              ]
            }
          }
        ]
      }
    }
  },
  "required": [
    "code",
    "fields"
  ],
  "$schema": "http://json-schema.org/draft-07/schema#"
}