Recently, a tight correlation among three quantities that characterize the prompt emission of long Gamma-Ray Bursts (GRBs) with known redshift z, was discovered (Firmani et al. 2006a). We use this correlation to construct the Hubble diagram (HD) with a sample of 19 GRBs in the broad range of z = 0.17 - 4.5, and carry out a full statistical analysis to constrain cosmological parameters (CPS). To optimally solve the problem of circularity, a Bayesian approach is applied. The main result is that the concordance Lambda CDM cosmology is fully consistent with the GRB data at the level of several tests. If we assume the A cosmology, then we find Omega(m)=0.31(-0.08)(+0.09) and Omega Lambda = 0.80(-0.30)(+0.20) (1 sigma); the flat-geometry case is within 1 sigma. Assuming flatness, we find Omega(m)=0.29(-0.06)(+0.08), and fixing Omega(m)=0.28, we obtain a dark energy equation of state parameter w = -1.07(-0.38)(+0.25), i.e. the Lambda CDM model (w = -1) is within la. Given the low number of usable GRBs we cannot yet constrain well the possible evolution of w = w(z). However, the case w(z) = -1 (Lambda CDM) is consistent at the 68.3% CL with GRBs. It is shown also how a broad range of z's in the used sample improves the determination of CPs from the HD, which is the case of GRBs as distance indicators.