Fixed invalid/unset API Key header to be 400 instead of 500
Successfully handle OPTIONS header for API