{
  "name": "Portioned restaurant compliance calendar: personalised feed parameters",
  "page": "https://portioned.pro/restaurant-compliance-calendar",
  "feed_url_pattern": "https://portioned.pro/compliance-calendar/feed.php?e={entity}&s={sales}&f={flags}&x={dates}&c={reminders}",
  "method": "GET",
  "response": "text/calendar (ICS, all-day events)",
  "notes": [
    "All parameters optional; unknown or invalid values are ignored, not rejected.",
    "Events dated before today (America/New_York) are dropped.",
    "Nothing is stored per person."
  ],
  "parameters": {
    "e": {
      "description": "business type",
      "allowed": [
        "any",
        "sole",
        "partnership",
        "scorp",
        "ccorp"
      ],
      "default": "any"
    },
    "s": {
      "description": "NYS sales tax filing frequency; unsure includes monthly, quarterly and annual",
      "allowed": [
        "unsure",
        "monthly",
        "quarterly",
        "annual"
      ],
      "default": "unsure"
    },
    "f": {
      "description": "comma-separated flags",
      "allowed": [
        "employees",
        "tips",
        "mctmt",
        "liquor",
        "crt",
        "building",
        "assembly",
        "outdoor",
        "tobacco",
        "hood",
        "sprinkler",
        "tco"
      ],
      "default": "none",
      "implies": {
        "tips": [
          "employees"
        ],
        "mctmt": [
          "employees"
        ]
      }
    },
    "x": {
      "description": "license, permit and equipment dates",
      "format": "id~YYYY-MM-DD, comma-separated",
      "separators": {
        "pair": ",",
        "id_date": "~"
      },
      "date_format": "YYYY-MM-DD, valid calendar date, year 2000-2100",
      "max_entries": 40,
      "ids": [
        {
          "id": "nyc-dohmh-fse-permit",
          "type": "date",
          "reminders_days_before": [
            90,
            60,
            30
          ],
          "date_meaning": "expiry or due date"
        },
        {
          "id": "nyc-dcwp-tobacco-dealer",
          "type": "date",
          "reminders_days_before": [
            90,
            60,
            30
          ],
          "date_meaning": "expiry or due date"
        },
        {
          "id": "nyc-dcwp-ecig-dealer",
          "type": "date",
          "reminders_days_before": [
            90,
            60,
            30
          ],
          "date_meaning": "expiry or due date"
        },
        {
          "id": "nyc-fdny-cooking-permit",
          "type": "date",
          "reminders_days_before": [
            90,
            60,
            30
          ],
          "date_meaning": "expiry or due date"
        },
        {
          "id": "nyc-fdny-hood-cleaning",
          "type": "interval",
          "months": 3,
          "reminders_days_before": [
            14,
            7
          ],
          "date_meaning": "date last done; due date = date + months"
        },
        {
          "id": "nyc-fdny-suppression-6mo",
          "type": "interval",
          "months": 6,
          "reminders_days_before": [
            30,
            14
          ],
          "date_meaning": "date last done; due date = date + months"
        },
        {
          "id": "nyc-fdny-extinguishers",
          "type": "interval",
          "months": 12,
          "reminders_days_before": [
            30,
            14
          ],
          "date_meaning": "date last done; due date = date + months"
        },
        {
          "id": "nyc-fdny-sprinkler-standpipe-5yr",
          "type": "interval",
          "months": 60,
          "reminders_days_before": [
            180,
            90,
            30
          ],
          "date_meaning": "date last done; due date = date + months"
        },
        {
          "id": "nyc-fdny-pa-permit",
          "type": "date",
          "reminders_days_before": [
            90,
            60,
            30
          ],
          "date_meaning": "expiry or due date"
        },
        {
          "id": "nyc-fdny-cof-f03",
          "type": "date",
          "reminders_days_before": [
            90,
            60,
            30
          ],
          "date_meaning": "expiry or due date"
        },
        {
          "id": "nyc-dob-tco",
          "type": "date",
          "reminders_days_before": [
            30,
            14,
            7
          ],
          "date_meaning": "expiry or due date"
        },
        {
          "id": "nyc-pto-unpaid-bank",
          "type": "date",
          "reminders_days_before": [
            14
          ],
          "date_meaning": "expiry or due date"
        },
        {
          "id": "nys-sla-liquor-renewal",
          "type": "date",
          "reminders_days_before": [
            90,
            75,
            40
          ],
          "date_meaning": "expiry or due date"
        },
        {
          "id": "nyc-outdoor-cafe-license",
          "type": "interval",
          "months": 48,
          "reminders_days_before": [
            270,
            240,
            120
          ],
          "date_meaning": "date last done; due date = date + months"
        },
        {
          "id": "nyc-outdoor-cafe-compensation",
          "type": "date",
          "reminders_days_before": [
            45,
            30,
            7
          ],
          "date_meaning": "expiry or due date"
        }
      ]
    },
    "c": {
      "description": "own reminders",
      "format": "frequency~YYYY-MM-DD~title, comma-separated",
      "separators": {
        "entry": ",",
        "field": "~"
      },
      "frequency": [
        "once",
        "weekly",
        "biweekly",
        "monthly",
        "bimonthly",
        "quarterly",
        "yearly"
      ],
      "title": "percent-encoded with encodeURIComponent inside the entry; max 60 characters after decoding; control characters become spaces",
      "encoding_note": "The page's own links percent-encode the whole c value once more; the feed accepts both because PHP decodes the query string once and the title is then decoded again.",
      "max_entries": 10,
      "past_dates": "a 'once' reminder dated before today is dropped"
    }
  },
  "example": {
    "description": "S corporation, quarterly sales tax, employees + tips + liquor, hood cleaned 2026-09-15, monthly 'Run payroll' reminder",
    "url": "https://portioned.pro/compliance-calendar/feed.php?e=scorp&s=quarterly&f=employees,tips,liquor&x=nyc-fdny-hood-cleaning~2026-09-15&c=monthly~2026-11-01~Run%20payroll"
  },
  "static_feeds": [
    "https://portioned.pro/compliance-calendar/feeds/restaurant-compliance-federal-nys-nyc.ics",
    "https://portioned.pro/compliance-calendar/feeds/restaurant-compliance-federal.ics",
    "https://portioned.pro/compliance-calendar/feeds/restaurant-compliance-nys.ics",
    "https://portioned.pro/compliance-calendar/feeds/restaurant-compliance-nyc.ics"
  ],
  "dataset": {
    "url": "https://portioned.pro/compliance-calendar/feed-data.json",
    "fields": {
      "built": "build date (YYYY-MM-DD)",
      "seq": "dataset version, used as ICS SEQUENCE",
      "events": "array of dated deadlines: uid, date, summary, description, url, requires, entity, alarmDays",
      "exp": "rules behind the x parameter",
      "disclaimer": "text",
      "page": "page URL"
    }
  }
}
