{"components":{"schemas":{"Entity":{"properties":{"country_code":{"type":"string"},"currency_code":{"type":"string"},"end_year":{"type":"integer"},"fy_calculation_method":{"type":"string"},"fy_start_day":{"type":"integer"},"fy_start_month":{"type":"integer"},"id":{"type":"integer"},"name":{"type":"string"},"start_year":{"type":"integer"},"week_start_day":{"type":"integer"}},"type":"object"},"Holiday":{"properties":{"country_code":{"type":"string"},"date":{"format":"date","type":"string"},"id":{"type":"integer"},"name":{"type":"string"},"year":{"type":"integer"}},"type":"object"}},"securitySchemes":{"ApiKeyAuth":{"bearerFormat":"fck_*","scheme":"bearer","type":"http"}}},"info":{"description":"Read & write fiscal calendars, holidays and period summaries. Authenticate with an API key issued from the admin panel.","title":"Fiscal Calendar API","version":"1.0.0"},"openapi":"3.0.3","paths":{"/entities":{"get":{"parameters":[{"in":"query","name":"country","schema":{"type":"string"}},{"in":"query","name":"limit","schema":{"default":100,"type":"integer"}},{"in":"query","name":"offset","schema":{"default":0,"type":"integer"}}],"responses":{"200":{"description":"OK"}},"summary":"List entities"},"post":{"responses":{"201":{"description":"Created"}},"summary":"Create an entity"}},"/entities/{id}":{"delete":{"responses":{"200":{"description":"OK"}},"summary":"Delete an entity (cascades calendar rows)"},"get":{"parameters":[{"in":"path","name":"id","required":true,"schema":{"type":"integer"}}],"responses":{"200":{"description":"OK"}},"summary":"Get one entity"}},"/entities/{id}/calendar":{"get":{"parameters":[{"in":"path","name":"id","required":true,"schema":{"type":"integer"}},{"in":"query","name":"year","schema":{"type":"integer"}},{"in":"query","name":"from","schema":{"format":"date","type":"string"}},{"in":"query","name":"to","schema":{"format":"date","type":"string"}},{"in":"query","name":"working_days_only","schema":{"type":"boolean"}},{"in":"query","name":"format","schema":{"enum":["json","csv"],"type":"string"}}],"responses":{"200":{"description":"OK"}},"summary":"Day-level calendar"}},"/entities/{id}/calendar.ics":{"get":{"parameters":[{"in":"path","name":"id","required":true,"schema":{"type":"integer"}},{"in":"query","name":"api_key","schema":{"type":"string"}}],"responses":{"200":{"description":"text/calendar"}},"summary":"Subscribable iCal feed"}},"/entities/{id}/years/{year}/summary":{"get":{"responses":{"200":{"description":"OK"}},"summary":"Year summary + quarter & week breakdowns"}},"/holidays":{"get":{"responses":{"200":{"description":"OK"}},"summary":"List holidays"},"post":{"responses":{"201":{"description":"Created"}},"summary":"Add a holiday"}},"/ping":{"get":{"responses":{"200":{"description":"OK"}},"security":[],"summary":"Liveness check"}}},"security":[{"ApiKeyAuth":[]}],"servers":[{"url":"https://fiscal.stefstime.co.za/api/v1"}]}
