{"openapi":"3.1.0","info":{"title":"China Workday Calendar and Package Vulnerability Advisories","version":"1.2.0","description":"Pay-per-call x402 APIs (USDC). China Workday Calendar — is a date a working day in mainland China, with official holidays and makeup workdays (调休). Package Vulnerability Advisories — is this npm, PyPI, Go, crates.io or Maven package version safe to install; batch $0.0004 per package.","contact":{"name":"Source and issues","url":"https://github.com/walkley/x402-content-site"},"x-guidance":"Call a paid route without payment to get a 402 with the price; pay with x402 v2 (exact, USDC) and retry with PAYMENT-SIGNATURE. Invalid input gets a free 400/404 first; 502 means upstream failed and nothing was charged. Batch package checks are cheaper per package."},"x-discovery":{"llmsTxtUrl":"https://mvqz0m8d6g.execute-api.ap-northeast-1.amazonaws.com/llms.txt"},"servers":[{"url":"https://mvqz0m8d6g.execute-api.ap-northeast-1.amazonaws.com"}],"tags":[{"name":"China Workday Calendar","description":"Data 2020-01-01..2027-12-31 from State Council (国务院) holiday notices on gov.cn, updated 2026-11-05."},{"name":"Package Vulnerability Advisories","description":"Advisory data from OSV.dev (https://osv.dev, Apache-2.0), which aggregates source databases under their own licenses: GitHub Advisory Database, PyPI Advisory Database, Go Vulnerability Database (CC-BY 4.0), Rust Advisory Database (CC0 1.0), OpenSSF Malicious Packages (Apache-2.0). Records are excerpted and modified (details omitted, ranges restructured). Each advisory carries its source license; summaries of records from other sources are omitted."}],"paths":{"/cn/workday":{"get":{"summary":"Is a given date a working day in mainland China? Applies the State Council (国务院) holiday notice: public holiday periods, weekend makeup workdays (调休补班) and ordinary weekends. Returns holiday name and source link.","tags":["China Workday Calendar"],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.003"},"protocols":[{"x402":{}}]},"x-x402-price":"$0.003","parameters":[{"name":"date","in":"query","required":true,"schema":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$","description":"Calendar date in China (YYYY-MM-DD), 2020-01-01..2027-12-31"}}],"responses":{"200":{"description":"Day classification","headers":{"PAYMENT-RESPONSE":{"type":"string","description":"Base64 JSON SettleResponse: success, transaction (tx hash), network, payer"}},"content":{"application/json":{"schema":{"type":"object","properties":{"date":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},"weekday":{"type":"integer","minimum":1,"maximum":7,"description":"ISO weekday, 1 = Monday, 7 = Sunday"},"is_workday":{"type":"boolean","description":"true for an ordinary weekday or a makeup workday (调休补班)"},"is_public_holiday":{"type":"boolean","description":"true inside an official holiday period (放假) from the State Council notice"},"is_makeup_workday":{"type":"boolean","description":"true for a weekend day officially designated as a working day (调休上班)"},"holiday_name":{"type":["string","null"],"description":"Holiday name as written in the notice, e.g. 春节"},"kind":{"type":"string","enum":["workday","weekend","public_holiday","makeup_workday"]},"source_url":{"type":"string","description":"gov.cn notice the answer is based on"},"data_updated":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$","description":"Publication date of the newest notice in the dataset"}},"required":["date","weekday","is_workday","is_public_holiday","is_makeup_workday","holiday_name","kind","source_url","data_updated"],"additionalProperties":false},"example":{"date":"2026-02-14","weekday":6,"is_workday":true,"is_public_holiday":false,"is_makeup_workday":true,"holiday_name":null,"kind":"makeup_workday","source_url":"https://www.gov.cn/zhengce/zhengceku/202511/content_7047091.htm","data_updated":"2026-11-05"}}}},"400":{"description":"Invalid input or date outside the covered range. Not charged."},"402":{"description":"Payment required (x402 v2). Price $0.003 USDC on eip155:8453. Decode the PAYMENT-REQUIRED header, sign one of its accepts, and retry with a PAYMENT-SIGNATURE header. Returned for a request with no parameters at all, so a probe sees the price. Also returned when a payment is rejected or settlement fails; no content is sent in that case.","headers":{"PAYMENT-REQUIRED":{"type":"string","description":"Base64 JSON PaymentRequired: x402Version, accepts[] (scheme, network, asset, amount, payTo), resource, extensions, error"},"PAYMENT-RESPONSE":{"type":"string","description":"Base64 JSON settlement result; present when settlement was attempted and failed"}},"content":{"application/json":{"schema":{"type":"object","description":"price, network, how_to_pay, docs and an example request/response"}}}},"404":{"description":"Invalid input or date outside the covered range. Not charged."},"502":{"description":"Facilitator unavailable or returned an error. Not charged; retry later."}}}},"/cn/business-days":{"get":{"summary":"Count and list mainland China working days between two dates (inclusive, up to 366 days, may cross years), honouring official holidays and weekend makeup workdays (调休补班) from State Council notices.","tags":["China Workday Calendar"],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.005"},"protocols":[{"x402":{}}]},"x-x402-price":"$0.005","parameters":[{"name":"from","in":"query","required":true,"schema":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$","description":"First date, inclusive (YYYY-MM-DD)"}},{"name":"to","in":"query","required":true,"schema":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$","description":"Last date, inclusive (YYYY-MM-DD); at most 366 days after counting both ends"}}],"responses":{"200":{"description":"Workdays in range","headers":{"PAYMENT-RESPONSE":{"type":"string","description":"Base64 JSON SettleResponse: success, transaction (tx hash), network, payer"}},"content":{"application/json":{"schema":{"type":"object","properties":{"from":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},"to":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},"calendar_days":{"type":"integer","minimum":1,"maximum":366},"workday_count":{"type":"integer","minimum":0},"workdays":{"type":"array","items":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},"description":"Every working day in the range, ascending"},"data_updated":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"}},"required":["from","to","calendar_days","workday_count","workdays","data_updated"],"additionalProperties":false},"example":{"from":"2026-09-28","to":"2026-10-11","calendar_days":14,"workday_count":6,"workdays":["2026-09-28","2026-09-29","2026-09-30","2026-10-08","2026-10-09","2026-10-10"],"data_updated":"2026-11-05"}}}},"400":{"description":"Invalid input or date outside the covered range. Not charged."},"402":{"description":"Payment required (x402 v2). Price $0.005 USDC on eip155:8453. Decode the PAYMENT-REQUIRED header, sign one of its accepts, and retry with a PAYMENT-SIGNATURE header. Returned for a request with no parameters at all, so a probe sees the price. Also returned when a payment is rejected or settlement fails; no content is sent in that case.","headers":{"PAYMENT-REQUIRED":{"type":"string","description":"Base64 JSON PaymentRequired: x402Version, accepts[] (scheme, network, asset, amount, payTo), resource, extensions, error"},"PAYMENT-RESPONSE":{"type":"string","description":"Base64 JSON settlement result; present when settlement was attempted and failed"}},"content":{"application/json":{"schema":{"type":"object","description":"price, network, how_to_pay, docs and an example request/response"}}}},"404":{"description":"Invalid input or date outside the covered range. Not charged."},"502":{"description":"Facilitator unavailable or returned an error. Not charged; retry later."}}}},"/deps/advisories":{"get":{"summary":"Is this package version safe to install? Call before adding or upgrading an npm, PyPI, Go, crates.io or Maven dependency. Returns vulnerable true/false and the known advisories (CVE, GHSA, PYSEC, GO, RUSTSEC) for that exact version: CVSS, affected ranges, fixed versions and links. Package names are case-sensitive (npm: use the published lowercase name). Data from OSV.dev, fetched live (cached up to 1 hour).","tags":["Package Vulnerability Advisories"],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.005"},"protocols":[{"x402":{}}]},"x-x402-price":"$0.005","parameters":[{"name":"ecosystem","in":"query","required":true,"schema":{"type":"string","enum":["npm","PyPI","Go","crates.io","Maven"],"description":"Package ecosystem (case-insensitive on input)"}},{"name":"name","in":"query","required":true,"schema":{"type":"string","minLength":1,"maxLength":214,"description":"Package name exactly as published; matching is case-sensitive for npm (lodash, not Lodash; legacy names such as JSONStream keep their case). Maven uses groupId:artifactId, Go the module path. PyPI names are normalised."}},{"name":"version","in":"query","required":true,"schema":{"type":"string","minLength":1,"maxLength":128,"description":"Exact version, e.g. 4.17.20"}}],"responses":{"200":{"description":"Advisories affecting this version","headers":{"PAYMENT-RESPONSE":{"type":"string","description":"Base64 JSON SettleResponse: success, transaction (tx hash), network, payer"}},"content":{"application/json":{"schema":{"type":"object","properties":{"ecosystem":{"type":"string"},"name":{"type":"string"},"version":{"type":"string"},"vulnerable":{"type":"boolean","description":"true when at least one advisory affects this exact version"},"advisory_count":{"type":"integer","minimum":0},"advisories":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"aliases":{"type":"array","items":{"type":"string"},"description":"Usually CVE ids"},"summary":{"type":["string","null"]},"severity":{"type":"object","properties":{"level":{"type":["string","null"],"description":"Source rating such as LOW, MODERATE, HIGH, CRITICAL"},"cvss":{"type":"array","items":{"type":"object","properties":{"type":{"type":"string"},"vector":{"type":"string"}}}}}},"affected":{"type":"array","items":{"type":"object","properties":{"package":{"type":"string"},"ranges":{"type":"array","items":{"type":"object","properties":{"type":{"type":"string"},"introduced":{"type":"string"},"fixed":{"type":"string"},"last_affected":{"type":"string"}}}}}}},"fixed_versions":{"type":"array","items":{"type":"string"}},"published":{"type":["string","null"]},"modified":{"type":["string","null"]},"references":{"type":"array","items":{"type":"string"}},"url":{"type":"string","description":"osv.dev record page"},"source_database":{"type":"string"},"license":{"type":"string","description":"License of the source record, e.g. CC-BY-4.0"}},"required":["id","aliases","summary","severity","affected","fixed_versions","url","license"]}},"truncated":{"type":"boolean","description":"true if the upstream result had more pages than were fetched"},"data_fetched_at":{"type":"string","description":"When the data was fetched from OSV.dev (ISO 8601)"},"queried_at":{"type":"string","description":"When this request was answered (ISO 8601)"},"source":{"type":"string"}},"required":["ecosystem","name","version","vulnerable","advisory_count","advisories","truncated","data_fetched_at","queried_at","source"]},"example":{"ecosystem":"npm","name":"lodash","version":"4.17.20","vulnerable":true,"advisory_count":1,"advisories":[{"id":"GHSA-35jh-r3h4-6jhm","aliases":["CVE-2021-23337"],"summary":"Command Injection in lodash","severity":{"level":"HIGH","cvss":[{"type":"CVSS_V3","vector":"CVSS:3.1/AV:N/AC:L/PR:H/UI:N/S:U/C:H/I:H/A:H"}]},"affected":[{"package":"lodash","ranges":[{"type":"SEMVER","introduced":"0","fixed":"4.17.21"}]}],"fixed_versions":["4.17.21"],"published":"2021-05-06T16:05:51Z","modified":"2026-10-17T02:55:38.085813876Z","references":["https://nvd.nist.gov/vuln/detail/CVE-2021-23337","https://github.com/lodash/lodash/commit/3469357cff396a26c363f8c1b5a91dde28ba4b1c","https://www.oracle.com/security-alerts/cpuoct2021.html"],"url":"https://osv.dev/vulnerability/GHSA-35jh-r3h4-6jhm","license":"CC-BY-4.0","source_database":"GitHub Advisory Database"}],"truncated":false,"data_fetched_at":"2026-11-24T08:00:00.000Z","queried_at":"2026-11-24T08:00:00.000Z","source":"OSV.dev (https://osv.dev). Excerpted and modified: details text omitted, affected ranges restructured and filtered to the queried package. Per-advisory license in `license`."}}}},"400":{"description":"Invalid ecosystem, name, version or batch body. Not charged."},"402":{"description":"Payment required (x402 v2). Price $0.005 USDC on eip155:8453. Decode the PAYMENT-REQUIRED header, sign one of its accepts, and retry with a PAYMENT-SIGNATURE header. Returned for a request with no parameters at all, so a probe sees the price. Also returned when a payment is rejected or settlement fails; no content is sent in that case.","headers":{"PAYMENT-REQUIRED":{"type":"string","description":"Base64 JSON PaymentRequired: x402Version, accepts[] (scheme, network, asset, amount, payTo), resource, extensions, error"},"PAYMENT-RESPONSE":{"type":"string","description":"Base64 JSON settlement result; present when settlement was attempted and failed"}},"content":{"application/json":{"schema":{"type":"object","description":"price, network, how_to_pay, docs and an example request/response"}}}},"502":{"description":"OSV.dev unavailable, timed out (5 s) or returned an error, or the facilitator failed. Not charged; retry later."}}}},"/deps/advisories/batch":{"post":{"summary":"Are these package versions safe to install? Checks up to 50 npm, PyPI, Go, crates.io or Maven package versions in one call, e.g. a whole lockfile: $0.02 per call, $0.0004 per package. Same fields as GET /deps/advisories for each package, in request order.","tags":["Package Vulnerability Advisories"],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.02"},"protocols":[{"x402":{}}]},"x-x402-price":"$0.02","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"packages":{"type":"array","minItems":1,"maxItems":50,"items":{"type":"object","properties":{"ecosystem":{"type":"string","enum":["npm","PyPI","Go","crates.io","Maven"],"description":"Package ecosystem (case-insensitive on input)"},"name":{"type":"string","minLength":1,"maxLength":214,"description":"Package name exactly as published; matching is case-sensitive for npm (lodash, not Lodash; legacy names such as JSONStream keep their case). Maven uses groupId:artifactId, Go the module path. PyPI names are normalised."},"version":{"type":"string","minLength":1,"maxLength":128,"description":"Exact version, e.g. 4.17.20"}},"required":["ecosystem","name","version"],"additionalProperties":false}}},"required":["packages"],"additionalProperties":false},"example":{"packages":[{"ecosystem":"npm","name":"lodash","version":"4.17.20"}]}}}},"responses":{"200":{"description":"Advisories per package, in request order","headers":{"PAYMENT-RESPONSE":{"type":"string","description":"Base64 JSON SettleResponse: success, transaction (tx hash), network, payer"}},"content":{"application/json":{"schema":{"type":"object","properties":{"count":{"type":"integer"},"vulnerable_count":{"type":"integer"},"results":{"type":"array","items":{"type":"object","properties":{"ecosystem":{"type":"string"},"name":{"type":"string"},"version":{"type":"string"},"vulnerable":{"type":"boolean","description":"true when at least one advisory affects this exact version"},"advisory_count":{"type":"integer","minimum":0},"advisories":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"aliases":{"type":"array","items":{"type":"string"},"description":"Usually CVE ids"},"summary":{"type":["string","null"]},"severity":{"type":"object","properties":{"level":{"type":["string","null"],"description":"Source rating such as LOW, MODERATE, HIGH, CRITICAL"},"cvss":{"type":"array","items":{"type":"object","properties":{"type":{"type":"string"},"vector":{"type":"string"}}}}}},"affected":{"type":"array","items":{"type":"object","properties":{"package":{"type":"string"},"ranges":{"type":"array","items":{"type":"object","properties":{"type":{"type":"string"},"introduced":{"type":"string"},"fixed":{"type":"string"},"last_affected":{"type":"string"}}}}}}},"fixed_versions":{"type":"array","items":{"type":"string"}},"published":{"type":["string","null"]},"modified":{"type":["string","null"]},"references":{"type":"array","items":{"type":"string"}},"url":{"type":"string","description":"osv.dev record page"},"source_database":{"type":"string"},"license":{"type":"string","description":"License of the source record, e.g. CC-BY-4.0"}},"required":["id","aliases","summary","severity","affected","fixed_versions","url","license"]}},"truncated":{"type":"boolean","description":"true if the upstream result had more pages than were fetched"},"data_fetched_at":{"type":"string","description":"When the data was fetched from OSV.dev (ISO 8601)"},"queried_at":{"type":"string","description":"When this request was answered (ISO 8601)"},"source":{"type":"string"}},"required":["ecosystem","name","version","vulnerable","advisory_count","advisories","truncated","data_fetched_at","queried_at","source"]}}},"required":["count","vulnerable_count","results"]},"example":{"count":1,"vulnerable_count":1,"results":[{"ecosystem":"npm","name":"lodash","version":"4.17.20","vulnerable":true,"advisory_count":1,"advisories":[{"id":"GHSA-35jh-r3h4-6jhm","aliases":["CVE-2021-23337"],"summary":"Command Injection in lodash","severity":{"level":"HIGH","cvss":[{"type":"CVSS_V3","vector":"CVSS:3.1/AV:N/AC:L/PR:H/UI:N/S:U/C:H/I:H/A:H"}]},"affected":[{"package":"lodash","ranges":[{"type":"SEMVER","introduced":"0","fixed":"4.17.21"}]}],"fixed_versions":["4.17.21"],"published":"2021-05-06T16:05:51Z","modified":"2026-10-17T02:55:38.085813876Z","references":["https://nvd.nist.gov/vuln/detail/CVE-2021-23337","https://github.com/lodash/lodash/commit/3469357cff396a26c363f8c1b5a91dde28ba4b1c","https://www.oracle.com/security-alerts/cpuoct2021.html"],"url":"https://osv.dev/vulnerability/GHSA-35jh-r3h4-6jhm","license":"CC-BY-4.0","source_database":"GitHub Advisory Database"}],"truncated":false,"data_fetched_at":"2026-11-24T08:00:00.000Z","queried_at":"2026-11-24T08:00:00.000Z","source":"OSV.dev (https://osv.dev). Excerpted and modified: details text omitted, affected ranges restructured and filtered to the queried package. Per-advisory license in `license`."}]}}}},"400":{"description":"Invalid ecosystem, name, version or batch body. Not charged."},"402":{"description":"Payment required (x402 v2). Price $0.02 USDC on eip155:8453. Decode the PAYMENT-REQUIRED header, sign one of its accepts, and retry with a PAYMENT-SIGNATURE header. Returned for a request with no parameters at all, so a probe sees the price. Also returned when a payment is rejected or settlement fails; no content is sent in that case.","headers":{"PAYMENT-REQUIRED":{"type":"string","description":"Base64 JSON PaymentRequired: x402Version, accepts[] (scheme, network, asset, amount, payTo), resource, extensions, error"},"PAYMENT-RESPONSE":{"type":"string","description":"Base64 JSON settlement result; present when settlement was attempted and failed"}},"content":{"application/json":{"schema":{"type":"object","description":"price, network, how_to_pay, docs and an example request/response"}}}},"502":{"description":"OSV.dev unavailable, timed out (5 s) or returned an error, or the facilitator failed. Not charged; retry later."}}}},"/mcp":{"post":{"summary":"MCP server, Streamable HTTP, stateless JSON-RPC (free, 20 tool calls per IP per day, then the tool error names the paid x402 route)","description":"Tools cn_workday_check and package_advisories. Add with: claude mcp add --transport http cn-calendar https://mvqz0m8d6g.execute-api.ap-northeast-1.amazonaws.com/mcp","security":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","description":"One JSON-RPC 2.0 message (initialize, tools/list, tools/call, ping)"}}}},"responses":{"200":{"description":"JSON-RPC response","content":{"application/json":{"schema":{"type":"object"}}}},"202":{"description":"Notification accepted, no body"},"400":{"description":"Not a JSON-RPC message, or unsupported MCP-Protocol-Version"}}}},"/.well-known/mcp.json":{"get":{"summary":"MCP server manifest: endpoint, tools, free quota and prices (free)","security":[],"responses":{"200":{"description":"ok"}}}},"/health":{"get":{"summary":"Liveness check (free)","security":[],"responses":{"200":{"description":"ok"}}}},"/llms.txt":{"get":{"summary":"Agent-oriented summary of these APIs (free)","security":[],"responses":{"200":{"description":"ok"}}}},"/SKILL.md":{"get":{"summary":"Agent skill (AgentSkills SKILL.md): endpoints, prices, examples and how to pay (free)","security":[],"responses":{"200":{"description":"ok"}}}}}}