Filter Organizations by Date with the since= Parameter

Filter Organizations by Date with the since= Parameter

features api 2025
View as Markdown

Query organizations added to our database since a specific date

The /api/organizations endpoint now supports a since= parameter to filter results by date. This enables efficient retrieval of organizations added to the database on or after a specific date.

Usage

Endpoint: GET /api/organizations?since=YYYY-MM-DD

Example:

curl "https://api.charityapi.org/api/organizations?since=2025-01-15" \
  -H "apikey: YOUR_API_KEY"

Behavior

  • Date Format: ISO 8601 (YYYY-MM-DD)
  • Filter Logic: Returns organizations where first_seen_date >= specified_date
  • Date Matching: Organizations added on the specified date are included in results

Implementation Details

The parameter filters to when an organization first appeared in our IRS data imports. This is not the same as the organization’s IRS ruling date or formation date.

Error Handling

Missing the since= parameter returns:

{
  "error": {
    "message": "Missing required 'since' param. Please provide in the format YYYY-MM-DD e.g. 2023-09-15",
    "code": "MISSING_REQUIRED_PARAMETER",
    "details": {
      "parameter": "since",
      "expected_format": "YYYY-MM-DD"
    }
  }
}

Use Cases

  • Incremental Sync: Pull only new organizations since last sync
  • Change Detection: Monitor database additions over time
  • Data Freshness: Verify recent IRS data imports
  • Audit Trails: Track when organizations entered the database

Notes

  • The since= filter operates on database insertion time, not IRS ruling dates
  • Date comparison is inclusive (organizations added exactly on the specified date are included)
  • Test API keys return mock data