Getting channelId instead of teamId from the context

Solution 1:

I think you're seeing the "General" Channel - it's basically the "default" in every Team, and every Team will definitely have a "General" Channel, so it's given the same ID. You can check by looking at alternate channels in the same Team, of course.