Calculate response deadlines for Official Information Act (OIA) and Local Government Official Information and Meetings Act (LGOIMA) requests using the NZ Ombudsman's calculator.
Calculate the latest response date for an official information request.
{
"date": "2025-01-15",
"type": "OIA"
}
date (string, required): Date the request was received (YYYY-MM-DD format)type (string, required): Type of request - "OIA" or "LGOIMA"{
"success": true,
"data": {
"response_date": "2025-02-15",
"response_date_formatted": "15 February 2025",
"considerations": [
"This calculation assumes the request was received during business hours"
],
"request_date": "2025-01-15",
"request_type": "OIA"
}
}
Health check endpoint to verify the service is running.
{
"status": "healthy",
"timestamp": "2025-01-15T10:30:00.000Z",
"service": "OIA Calculator API"
}
curl -X POST https://your-worker.workers.dev/calculate \
-H "Content-Type: application/json" \
-d '{"date": "2025-01-15", "type": "OIA"}'
const response = await fetch('https://your-worker.workers.dev/calculate', {
method: 'POST',
headers: {
'Content-Type': 'application/json',
},
body: JSON.stringify({
date: '2025-01-15',
type: 'OIA'
})
});
const result = await response.json();
console.log('Response due by:', result.data.response_date, '(' + result.data.response_date_formatted + ')');
The API returns appropriate HTTP status codes:
Please be respectful when using this API. The service caches form data to minimize requests to the official Ombudsman website.
This API is a wrapper around the NZ Ombudsman's official calculator. It provides a programmatic interface to calculate response deadlines for official information requests.
Legal Notice: This is an unofficial service. Always verify important deadlines with the official Ombudsman calculator or seek legal advice for critical matters.