Fastapi return error status code. from fastapi import FastAPI, HTTPException from starlette.