Ensure path is passed through to API middleware