The q-Onsager algebra and multivariable q-special functions