Technically yes, glam metal is a part of heavy metal. But I consider it poser metal. In the words of Dave Mustaine, Glam = Gay Los Angeles Metal. Please excuse the homophobia. Most of the real metal bands of the day weren't these huge, arena bands like Motley Crue and Poison that dominated the attention of MTV. Most of the real metal bands were playing in dinky little clubs. Bands like Exodus, Dark Angel, Possessed, Cryptic Slaughter, M.O.D., and others like them.
I do consider them to be metal. Not very good metal, certainly very far away from what metal is supposed to be, but sadly they are still metal.
Yes, i consider hair metal as metal.
Glam Metal is basically metal with more of sing-a-long verses and somewhat slower tempo.
First thing is to define the terms. Wikipedia for example defines WASP as a Glam Metal band which is hilarious. Sound wise they were part throwback part pioneer. Glam no, yes they were 80s but very different from what I consider Glam Metal which is what we called poser Metal in the 80s. Glam and Hair Metal are in themselves distinct sub genres of Metal. The Glam boys like Quiet Riot, Poison, Ratt, etc contributed pretty much nothing to Metal. They had some good tunes but as a genre I'm not a big fan. Many of the hair Metal groups did however pioneer styles that heavily influenced later artists to come. Motley Crue for example, Iron Maiden, Whitesnake are some examples of Hair Metal groups that influenced later Metal genres and styles. There'd be no Metalica without some of these groups You can distinctly hear phrasings in many Metalica tunes that harken directly to 80s Metal. Many Metal groups were Metal before there was Hair Metal, Scorpions for example, but in the 80s the Scorps typified Metal and really helped define what 80s Metal was about despite the group having been around since the 60s. Even Deep Purple one of the pioneers of Metal released a Hair Metal style CD in the late 80s early 90s. Alice Cooper was another who tried his hand at Hair Metal with great success for one effort. Metal has many sub genres. There's no real unified Metal scene today. You have the Nu-Metal like Disturbed, Godsmack, etc. You have Death Metal, progressive Metal, Grunge influenced Metal and 1,000 other catagories. Some seem to blur the lines between Metal and Rock or Metal an Jazz in the extremes. Then you still have some old school So yes I consider 80s Hair Metal Metal. I even consider Rap Metal and Severely Jazz influenced progressive Metal as Metal. I also consider Grunge a sub genre of Metal or at the least a very close cousin.