A downhole well system for producing hydrocarbon-containing fluid from a reservoir downhole, comprising: - a well tubular metal structure having an inside, the well tubular metal structure is arranged in the borehole, the well tubular metal structure having an outer face facing the wall of the borehole, - a first and a second annular barrier (4, 4A, 4B) for isolating an annulus outside the well tubular metal structure, each annular barrier comprising: - a tubular part adapted to be mounted as part of the well tubular metal structure, the tubular part having an outer face, - an expandable metal sleeve surrounding the tubular part and having an inner sleeve face facing the tubular part and an outer sleeve face facing a wall of a borehole, each end of the expandable metal sleeve being connected with the tubular part, and - an annular space between the inner sleeve face of the expandable metal sleeve and the tubular part, the first and second annular barriers being adapted to isolate a production zone when expanded, and - an inflow valve assembly mounted as part of the tubular metal structure, the inflow valve assembly being arranged between the first and the second annular barriers opposite the production zone for providing fluid communication between the production zone and the inside of the well tubular metal structure through a passage in the inflow valve assembly by adjusting a closing member in relation to the passage, the closing member being mounted in or on the well tubular metal structure, characterised in that the inflow valve assembly comprises - a sensor unit comprising: - a sensor adapted to measure at least one property of the fluid, - a power supply for powering at least the sensor, and - a control unit for activating the adjustment of the closing member based upon the measurement of the sensor. - a well tubular metal structure having an inside, the well tubular metal structure is arranged in the borehole, the well tubular metal structure having an outer face facing the wall of the borehole, - a first and a second annular barrier (4, 4A, 4B) for isolating an annulus outside the well tubular metal structure, each annular barrier comprising: - a tubular part adapted to be mounted as part of the well tubular metal structure, the tubular part having an outer face, - an expandable metal sleeve surrounding the tubular part and having an inner sleeve face facing the tubular part and an outer sleeve face facing a wall of a borehole, each end of the expandable metal sleeve being connected with the tubular part, and - an annular space between the inner sleeve face of the expandable metal sleeve and the tubular part, the first and second annular barriers being adapted to isolate a production zone when expanded, and - a tubular part adapted to be mounted as part of the well tubular metal structure, the tubular part having an outer face, - an expandable metal sleeve surrounding the tubular part and having an inner sleeve face facing the tubular part and an outer sleeve face facing a wall of a borehole, each end of the expandable metal sleeve being connected with the tubular part, and - an annular space between the inner sleeve face of the expandable metal sleeve and the tubular part, - an inflow valve assembly mounted as part of the tubular metal structure, the inflow valve assembly being arranged between the first and the second annular barriers opposite the production zone for providing fluid communication between the production zone and the inside of the well tubular metal structure through a passage in the inflow valve assembly by adjusting a closing member in relation to the passage, the closing member being mounted in or on the well tubular metal structure, - a sensor unit comprising: - a sensor adapted to measure at least one property of the fluid, - a power supply for powering at least the sensor, and - a control unit for activating the adjustment of the closing member based upon the measurement of the sensor. - a sensor adapted to measure at least one property of the fluid, - a power supply for powering at least the sensor, and - a control unit for activating the adjustment of the closing member based upon the measurement of the sensor.