# werkzeug.routing.exceptions.BuildError: Could not build url for endpoint 'user_profile' with values ['user_id']. Did you mean 'user' instead?

- **ID:** `python/flask-werkzeug-build-error`
- **Domain:** python
- **Category:** config_error
- **Verification:** ai_generated
- **Fix Rate:** 80%

## Root Cause

The endpoint name or parameters provided to url_for do not match any registered route.

## Version Compatibility

| Version | Status | Introduced | Deprecated |
|---------|--------|------------|------------|
| 3.x | active | — | — |

## Workarounds

1. **Check the endpoint name and parameters** (95% success)
   ```
   print(app.url_map)  # list all routes
url_for('user_profile', user_id=123)  # correct usage
   ```
2. **Use the endpoint parameter in route decorator** (90% success)
   ```
   @app.route('/user/<int:user_id>', endpoint='user_profile')
def user(user_id):
    return ...
   ```

## Dead Ends

- **Using url_for with wrong parameter names** — Parameter names must match the route exactly. (90% fail)
- **Assuming the endpoint name is the function name** — Endpoint names can be customized. (80% fail)
