{
  "openapi": "3.1.0",
  "info": {
    "title": "Japan Graduate Visa Check API",
    "version": "1.0.0",
    "description": "Graduating from a Japanese university, vocational school or language school? See when to change from student visa to a work visa (ISA asks for 1 Dec–31 Jan for April starts), how to stay and keep job hunting, when part-time work stops, the 14-day school-leaving notice and every date that matters.\n\nFree, no API key, CORS open. Fair use: about 120 requests per minute per IP. Also available as MCP tools at https://free-agent-tools.vercel.app/mcp"
  },
  "servers": [
    {
      "url": "https://japan-graduate-visa.vercel.app"
    }
  ],
  "paths": {
    "/api/check": {
      "get": {
        "operationId": "japanGraduateVisaCheck",
        "summary": "International student graduating in Japan: when to change visa, job-hunting visa, part-time end, 14-day notice",
        "description": "Applies ISA guidance (as of 2026-11-10) to a student's graduation. job_offer: change from 留学 to a work status (usually 技術・人文知識・国際業務); for April starts ISA asks for filing 1 Dec–31 Jan; otherwise aim for 2 months before start (standard processing 1–2 months); file with a certificate of expected graduation, collect the card after graduation; renew 留学 first if it ends on/before 31 Jan while still studying; 内定者 特定活動 for long gaps (hire within 1 year of offer and 1 year 6 months of graduation); document omission since 2025-12-01. job_hunting: 継続就職活動 特定活動 6 months + 1 renewal (~1 year) for Japanese university / vocational (専門士) grads with a school recommendation. leaving / further_study: dated steps. Always: part-time work on 留学 permission ends at graduation; report leaving the school within 14 days. Returns verdict (too_early | open | urgent | applied | not_eligible | expired | info), summary, targetStatus, windowOpens, recommendedBy, lastDay, partTimeEnds, notifySchoolLeftBy, jobHuntingUntil, hireBy, fee, deadlines, actions, warnings, sources, disclaimer.\n\nExample: https://japan-graduate-visa.vercel.app/api/check?graduationDate=2027-03-20&jobStartDate=2027-04-01&studentExpiry=2027-07-15&plan=job_offer",
        "parameters": [
          {
            "name": "graduationDate",
            "in": "query",
            "required": true,
            "description": "YYYY-MM-DD (expected) graduation day. Aliases: graduation, gradDate, 卒業日.",
            "schema": {
              "type": "string",
              "description": "YYYY-MM-DD (expected) graduation day. Aliases: graduation, gradDate, 卒業日."
            }
          },
          {
            "name": "plan",
            "in": "query",
            "required": false,
            "description": "job_offer (default when jobStartDate given) | job_hunting | leaving | further_study. Aliases: 内定, 就職活動, 帰国, 進学…",
            "schema": {
              "type": "string",
              "description": "job_offer (default when jobStartDate given) | job_hunting | leaving | further_study. Aliases: 内定, 就職活動, 帰国, 進学…",
              "enum": [
                "job_offer",
                "job_hunting",
                "leaving",
                "further_study"
              ]
            }
          },
          {
            "name": "jobStartDate",
            "in": "query",
            "required": false,
            "description": "YYYY-MM-DD job start (required for job_offer). Aliases: startDate, 入社日.",
            "schema": {
              "type": "string",
              "description": "YYYY-MM-DD job start (required for job_offer). Aliases: startDate, 入社日."
            }
          },
          {
            "name": "studentExpiry",
            "in": "query",
            "required": false,
            "description": "YYYY-MM-DD 留学 period-of-stay expiry on your residence card. Aliases: expiryDate, 満了日.",
            "schema": {
              "type": "string",
              "description": "YYYY-MM-DD 留学 period-of-stay expiry on your residence card. Aliases: expiryDate, 満了日."
            }
          },
          {
            "name": "school",
            "in": "query",
            "required": false,
            "description": "university (incl. graduate school, junior college) | vocational (専門学校 / 専門士) | language_school | other.",
            "schema": {
              "type": "string",
              "description": "university (incl. graduate school, junior college) | vocational (専門学校 / 専門士) | language_school | other.",
              "enum": [
                "university",
                "vocational",
                "language_school",
                "other"
              ],
              "default": "university"
            }
          },
          {
            "name": "foreignBachelor",
            "in": "query",
            "required": false,
            "description": "Language-school students: you hold a foreign bachelor's degree.",
            "schema": {
              "type": "boolean",
              "description": "Language-school students: you hold a foreign bachelor's degree.",
              "default": false
            }
          },
          {
            "name": "offerDate",
            "in": "query",
            "required": false,
            "description": "YYYY-MM-DD job offer (内定) date, for the 内定者 特定活動 hiring limit.",
            "schema": {
              "type": "string",
              "description": "YYYY-MM-DD job offer (内定) date, for the 内定者 特定活動 hiring limit."
            }
          },
          {
            "name": "appliedDate",
            "in": "query",
            "required": false,
            "description": "YYYY-MM-DD if you already filed.",
            "schema": {
              "type": "string",
              "description": "YYYY-MM-DD if you already filed."
            }
          },
          {
            "name": "expectedGrantMonths",
            "in": "query",
            "required": false,
            "description": "Period you expect to be granted, for the fee (default 12; job hunting 6).",
            "schema": {
              "type": "string",
              "description": "Period you expect to be granted, for the fee (default 12; job hunting 6)."
            }
          },
          {
            "name": "method",
            "in": "query",
            "required": false,
            "description": "counter (revenue stamps) or online.",
            "schema": {
              "type": "string",
              "description": "counter (revenue stamps) or online.",
              "enum": [
                "counter",
                "online"
              ],
              "default": "counter"
            }
          },
          {
            "name": "today",
            "in": "query",
            "required": false,
            "description": "Override today's date (default: today in Japan).",
            "schema": {
              "type": "string",
              "description": "Override today's date (default: today in Japan)."
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Result as JSON. Always includes a `disclaimer` field.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "additionalProperties": true
                }
              }
            }
          },
          "400": {
            "description": "Missing or invalid input. The body explains what to send and gives an example."
          },
          "429": {
            "description": "Too many requests from one IP. Retry after the Retry-After seconds."
          }
        }
      },
      "post": {
        "operationId": "japanGraduateVisaCheckPost",
        "summary": "International student graduating in Japan: when to change visa, job-hunting visa, part-time end, 14-day notice (JSON body)",
        "description": "Applies ISA guidance (as of 2026-11-10) to a student's graduation. job_offer: change from 留学 to a work status (usually 技術・人文知識・国際業務); for April starts ISA asks for filing 1 Dec–31 Jan; otherwise aim for 2 months before start (standard processing 1–2 months); file with a certificate of expected graduation, collect the card after graduation; renew 留学 first if it ends on/before 31 Jan while still studying; 内定者 特定活動 for long gaps (hire within 1 year of offer and 1 year 6 months of graduation); document omission since 2025-12-01. job_hunting: 継続就職活動 特定活動 6 months + 1 renewal (~1 year) for Japanese university / vocational (専門士) grads with a school recommendation. leaving / further_study: dated steps. Always: part-time work on 留学 permission ends at graduation; report leaving the school within 14 days. Returns verdict (too_early | open | urgent | applied | not_eligible | expired | info), summary, targetStatus, windowOpens, recommendedBy, lastDay, partTimeEnds, notifySchoolLeftBy, jobHuntingUntil, hireBy, fee, deadlines, actions, warnings, sources, disclaimer.",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "required": [
                  "graduationDate"
                ],
                "properties": {
                  "graduationDate": {
                    "type": "string",
                    "description": "YYYY-MM-DD (expected) graduation day. Aliases: graduation, gradDate, 卒業日."
                  },
                  "plan": {
                    "type": "string",
                    "description": "job_offer (default when jobStartDate given) | job_hunting | leaving | further_study. Aliases: 内定, 就職活動, 帰国, 進学…",
                    "enum": [
                      "job_offer",
                      "job_hunting",
                      "leaving",
                      "further_study"
                    ]
                  },
                  "jobStartDate": {
                    "type": "string",
                    "description": "YYYY-MM-DD job start (required for job_offer). Aliases: startDate, 入社日."
                  },
                  "studentExpiry": {
                    "type": "string",
                    "description": "YYYY-MM-DD 留学 period-of-stay expiry on your residence card. Aliases: expiryDate, 満了日."
                  },
                  "school": {
                    "type": "string",
                    "description": "university (incl. graduate school, junior college) | vocational (専門学校 / 専門士) | language_school | other.",
                    "enum": [
                      "university",
                      "vocational",
                      "language_school",
                      "other"
                    ],
                    "default": "university"
                  },
                  "foreignBachelor": {
                    "type": "boolean",
                    "description": "Language-school students: you hold a foreign bachelor's degree.",
                    "default": false
                  },
                  "offerDate": {
                    "type": "string",
                    "description": "YYYY-MM-DD job offer (内定) date, for the 内定者 特定活動 hiring limit."
                  },
                  "appliedDate": {
                    "type": "string",
                    "description": "YYYY-MM-DD if you already filed."
                  },
                  "expectedGrantMonths": {
                    "type": "string",
                    "description": "Period you expect to be granted, for the fee (default 12; job hunting 6)."
                  },
                  "method": {
                    "type": "string",
                    "description": "counter (revenue stamps) or online.",
                    "enum": [
                      "counter",
                      "online"
                    ],
                    "default": "counter"
                  },
                  "today": {
                    "type": "string",
                    "description": "Override today's date (default: today in Japan)."
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Result as JSON. Always includes a `disclaimer` field.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "additionalProperties": true
                }
              }
            }
          },
          "400": {
            "description": "Missing or invalid input. The body explains what to send and gives an example."
          },
          "429": {
            "description": "Too many requests from one IP. Retry after the Retry-After seconds."
          }
        }
      }
    },
    "/api/rules": {
      "get": {
        "operationId": "japanGraduateVisaRules",
        "summary": "Japan graduation visa rules: April-start filing window (1 Dec–31 Jan), change of status, job-hunting and 内定者 特定活動, part-time end, 14-day notice, 2026-10-01 fees, sources",
        "description": "Returns the rules the checker applies, with official sources and disclaimer. No inputs.",
        "responses": {
          "200": {
            "description": "Rules JSON with rulesAsOf and sources.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "additionalProperties": true
                }
              }
            }
          }
        }
      }
    }
  }
}