API Endpoint Reference

https://www.sjvair.com/api/1.0/monitors/

{
    "data": [
        {
            "id": "44xjCf40RGS4yY_prp8yBA",
            "name": "CCA Root Access Hackerspace #1",
            "device": "PurpleAir",
            "is_active": true,
            "is_sjvair": true,
            "position": {
                "type": "Point",
                "coordinates": [
                    -119.798799,
                    36.762744
                ]
            },
            "last_active_limit": 600,
            "location": "inside",
            "latest": {
                "timestamp": "2022-07-05T03:16:11Z",
                "sensor": "a",
                "celcius": "31.7",
                "fahrenheit": "89.0",
                "humidity": "22.0",
                "pressure": "999.53",
                "pm10": "0.80",
                "pm25": "3.82",
                "pm100": "1.55",
                "pm25_avg_15": "3.58",
                "pm25_avg_60": "3.48",
                "particles_03um": "381.59",
                "particles_05um": "107.32",
                "particles_100um": "0.02",
                "particles_10um": "13.20",
                "particles_25um": "0.88",
                "particles_50um": "0.29"
            },
            "county": "Fresno",
            "purple_id": 8854
        }
    ]
}
GET Parameters (filters)
name CharFilter
name__contains CharFilter
name__icontains CharFilter
position GeometryFilter
position__bbcontains GeometryFilter
position__bboverlaps GeometryFilter
position__distance_gt GeometryFilter
position__distance_lt GeometryFilter
is_sjvair BooleanFilter
location ChoiceFilter
county ChoiceFilter
device CharFilter

https://www.sjvair.com/api/1.0/monitors/<monitor_id>/

{
    "data": {
        "id": "xudEmbncQ7iqwy3sZ0jZvQ",
        "name": "CCA Root Access Hackerspace #2",
        "device": "PurpleAir",
        "is_active": true,
        "is_sjvair": true,
        "position": {
            "type": "Point",
            "coordinates": [
                -119.798678,
                36.762742
            ]
        },
        "last_active_limit": 600,
        "location": "outside",
        "latest": {
            "timestamp": "2022-07-05T03:14:43Z",
            "sensor": "a",
            "celcius": "33.3",
            "fahrenheit": "92.0",
            "humidity": "24.0",
            "pressure": "1000.52",
            "pm10": "0.61",
            "pm25": "1.18",
            "pm100": "0.98",
            "pm25_avg_15": "1.59",
            "pm25_avg_60": "0.96",
            "particles_03um": "272.17",
            "particles_05um": "75.80",
            "particles_100um": "0.20",
            "particles_10um": "6.13",
            "particles_25um": "0.65",
            "particles_50um": "0.20"
        },
        "county": "Fresno",
        "purple_id": 8892
    }
}

https://www.sjvair.com/api/1.0/monitors/<monitor_id>/entries/

{
    "data": [
        {
            "timestamp": "2022-07-05T03:14:43Z",
            "sensor": "a",
            "celcius": "33.3",
            "fahrenheit": "92.0",
            "humidity": "24.0",
            "pressure": "1000.52",
            "pm10": "0.61",
            "pm25": "1.18",
            "pm100": "0.98",
            "pm25_avg_15": "1.59",
            "pm25_avg_60": "0.96",
            "particles_03um": "272.17",
            "particles_05um": "75.80",
            "particles_100um": "0.20",
            "particles_10um": "6.13",
            "particles_25um": "0.65",
            "particles_50um": "0.20"
        }
    ],
    "page": 1,
    "count": 858497,
    "pages": 86,
    "has_next_page": true,
    "has_previous_page": false
}
GET Parameters (filters)
sensor CharFilter
timestamp DateTimeFilter
timestamp__lt DateTimeFilter
timestamp__lte DateTimeFilter
timestamp__gt DateTimeFilter
timestamp__gte DateTimeFilter
is_processed BooleanFilter

https://www.sjvair.com/api/1.0/monitors/<monitor_id>/entries/csv/

timestamp,sensor,celcius,fahrenheit,humidity,pressure,pm10,pm25,pm100,pm25_avg_15,pm25_avg_60,particles_03um,particles_05um,particles_100um,particles_10um,particles_25um,particles_50um
2021-01-18 23:59:00+00:00,a,25.6,78.0,28.0,1001.46,33.33,20.72,20.69,21.13,25.43,3690.76,1102.02,0.75,197.53,11.47,1.82
2021-01-18 23:56:59+00:00,a,25.0,77.0,28.0,1001.52,41.14,25.30,24.40,21.08,26.13,4338.47,1285.09,1.04,252.44,17.89,3.98
2021-01-18 23:54:59+00:00,a,25.0,77.0,28.0,1001.59,31.05,18.89,19.17,20.70,26.39,3451.45,1017.95,0.43,179.41,13.90,1.60
2021-01-18 23:53:00+00:00,a,25.6,78.0,28.0,1001.54,31.70,19.94,19.96,21.13,26.89,3499.94,1045.02,0.44,196.54,11.33,1.56
2021-01-18 23:50:59+00:00,a,25.0,77.0,28.0,1001.50,31.84,19.84,19.38,21.18,27.37,3501.16,1039.98,0.57,194.50,11.59,2.02
2021-01-18 23:49:00+00:00,a,25.0,77.0,28.0,1001.51,34.17,21.06,20.38,21.63,27.62,3635.22,1080.02,0.69,215.00,15.71,2.17
2021-01-18 23:46:59+00:00,a,25.0,77.0,28.0,1000.76,34.86,21.71,21.50,22.13,28.21,3859.86,1151.91,0.52,207.10,13.03,2.33
2021-01-18 23:44:59+00:00,a,25.0,77.0,28.0,1001.52,36.85,21.58,21.64,22.26,28.61,3834.38,1139.15,1.27,211.33,17.67,3.44
2021-01-18 23:42:59+00:00,a,25.0,77.0,28.0,1001.58,32.55,20.33,19.75,22.58,29.00,3525.96,1040.43,0.36,204.43,12.47,2.77
GET Parameters (filters)
sensor CharFilter
timestamp DateTimeFilter
timestamp__lt DateTimeFilter
timestamp__lte DateTimeFilter
timestamp__gt DateTimeFilter
timestamp__gte DateTimeFilter
is_processed BooleanFilter

https://www.sjvair.com/api/1.0/methane/<int:methane_id>/data/

{
    "data": [
        {
            "id": "87",
            "rh": "35.4284615385",
            "bin1": "0.0",
            "bin2": "0.0",
            "bin3": "0.0",
            "bin4": "0.0",
            "temp": "24.7776923077",
            "CO_we": "497.020215385",
            "CO_aux": "257.561446154",
            "timestamp": "2021-03-15T09:00:04.274Z",
            "Figaro2600": "711.605723077",
            "Figaro2602": "763.429015385",
            "Plantower1_pm1_mass": "317.384615385",
            "Plantower2_pm1_mass": "0.0",
            "Plantower1_pm10_mass": "1077.76923077",
            "Plantower1_pm1_count": "15169.0769231",
            "Plantower1_pm5_count": "1331.92307692",
            "Plantower2_pm10_mass": "0.0",
            "Plantower2_pm1_count": "0.0",
            "Plantower2_pm5_count": "0.0",
            "Plantower1_pm10_count": "69.6923076923",
            "Plantower1_pm2_5_mass": "824.615384615",
            "Plantower2_pm10_count": "0.0",
            "Plantower2_pm2_5_mass": "0.0",
            "Plantower1_pm0_3_count": "60371.0769231",
            "Plantower1_pm0_5_count": "30656.0769231",
            "Plantower1_pm2_5_count": "4005.46153846",
            "Plantower2_pm0_3_count": "0.0",
            "Plantower2_pm0_5_count": "0.0",
            "Plantower2_pm2_5_count": "0.0"
        }
    ],
    "page": 1,
    "count": 10,
    "pages": 1,
    "has_next_page": false,
    "has_previous_page": false
}
GET Parameters (filters)
sensor CharFilter
timestamp DateTimeFilter
timestamp__lt DateTimeFilter
timestamp__lte DateTimeFilter
timestamp__gt DateTimeFilter
timestamp__gte DateTimeFilter
is_processed BooleanFilter