The calibration of a quantum channel, i.e. the determination of the transmission losses affecting it, is definitely one of the principal objectives in both the quantum communication and quantum metrology frameworks. Another task of the utmost relevance is the identification, e.g. by extracting its photon number distribution, of the noise potentially present in the channel. Here we present a protocol, based on the response of a photon-number-resolving detector at different quantum efficiencies, able to accomplish both of these tasks at once, providing with a single measurement an estimate of the transmission losses as well as the photon statistics of the noise present in the exploited quantum channel. We show and discuss the experimental results obtained in the practical implementation of such protocol, with different kinds and levels of noise.