Skip to content

Error Messages

Should you accidentally use the API incorrectly or if the API didn't return any data, you will get an HTTP Status = '400 Bad Request' and see one of five errors.

Missing API Parameters

If the API is unhappy about not being passed the appropriate parameters, you will see a JSON message similar to this one, but with specific information related to the actual error:

{
    "error": {
        "type": 1,
        "source": "C2",
        "title": "Missing API Parameters",
        "detail": "It appears you have tried to access the API without passing required parameters.",
        "help-link": "https://weather.omegatower.com/current-observations",
        "api": "https://rest.omegatower.ninja/weather",
        "resource": "nws",
        "version": "2018.08.12.09"
    }
}

No Data Returned

If for some reason NOAA's National Weather Service didn't return any data, you will see a JSON message similar to this one, but with specific information related to the actual error:

{
    "error": {
        "type": 2,
        "source": "C1",
        "title": "No Data Returned",
        "detail": "It appears that no data was returned from NOAA using the parameters you entered into the API.",
        "help-link": "https://weather.omegatower.com/current-observations/icao",
        "api": "https://rest.omegatower.ninja/weather",
        "resource": "nws",
        "version": "2018.08.12.09"
    }
}

Invalid API Parameter Value

If the API is unhappy about one of the values you sent in a parameter, you will see a JSON message similar to this one, but with specific information related to the actual error:

{
    "error": {
        "type": 3,
        "source": "T1",
        "title": "Invalid API Parameter Value",
        "detail": "It appears that one of the parameters you entered into the API has an invalid value: test[0]",
        "help-link": "https://weather.omegatower.com/current-observations/tests",
        "api": "https://rest.omegatower.ninja/weather",
        "resource": "nws",
        "version": "2018.08.12.09"
    }
}

No Output Generated

If the API doesn't return any data, you will see a JSON message similar to this one, but with specific information related to the actual error:

{
    "error": {
        "type": 4,
        "source": "C3",
        "title": "No Output Generated",
        "detail": "It appears that no output was generated using the parameters you entered into the API.",
        "help-link": "https://weather.omegatower.com.html",
        "api": "https://rest.omegatower.ninja/weather",
        "resource": "nws",
        "version": "2018.08.12.09"
    }
}