```python
from fastapi import FastAPI, Body
import helpers

app = FastAPI()


@app.post("/thumbnail")
async def thumbnail(image_data: bytes = Body(...)):
    thumbnail_data = helpers.resize_image(image_data)
    return {"size": len(thumbnail_data)}
```