The shape of the diffuse cosmic X-ray spectrum