May not be the original source, but the story of the blackbirds selling their song to save a princess is told by a character in ShadowlandShadowland by Peter Straub. Just checked it and it does include the line 'Would you give up your song"Would you give up your song"?'