In Dungeons and Dragons 5th edition, when my character successfully hits a monster in combat, does the GM have to tell me whether the attack deals the usual amount of damage or not? If the monster has vulnerability, resistance or immunity to the type of damage I am dealing, is the GM obligated to tell me?
The DM is obliged to tell you
This obligation arises from the How to Play section on p.6 of the PHB, that is, the most fundamental rule in the book:
3. The DM narrates the results of the adventurers’ actions.
The player has scored a hit for a known amount of damage (from the dice they rolled and their modifiers): "the results of the adventurers’ actions" is different if the monster has vulnerability, resistance or immunity to the damage than if they do not and the DM is obliged to communicate that difference to the player.
How that communication takes place is up to the individual table DM: some will straight out tell the player's that the monster is vulnerable/resistant/immune and others will describe the effects ("Your blow does more/less/no damage than you expected" smart players will twig pretty quick). However they do it, it is important that they do do it.
Why it is important is simple: the sole source of information about the world comes from the DM. The players need that information so that they can make informed decisions (like switching to a different damage type). This is not to say that the players should get information their character's don't know or can't perceive, however, following a successful attack the effects of the hit are neither.
GM is not obligated but should in my opinion provide ample opportunity for the players to gather that information. A creature that is vulnerable or immune to something will react differently and this should be reflected in the descriptions given by the GM.
Examples: A Vampire shying away from sunlight, or a Troll suddenly being more cautious against the fighter with the flaming sword, a Salamander wading unhindered through the Wall of Fire as though it was fresh air to it.
Passive Perception (or in some cases Insight) should pick up a bit of this in my opinion depending on distractions but sometimes I wait for a player to declare their character looks for these things and sometimes I don't even require a roll. Table mileage varies and I would not expect to notice things on the first hit or in the first round.
The GM is not "obligated" to do anything.
Ideally they would describe the hits as somehow dealing less damage than usual, or having no effect, to help properly reflect the game world to you. "Your arrows stick into the skeleton but don't appear to do much damage or impede it in any way." But unless you have an ability to actively detect the source of that issue, you don't know what it is - a spell? Resistance? You don't know, you'll have to reason based on the information you do have (try different weapons, etc.).
The DM is obligated to describe what the character perceives. A level 1 adventurer is by no means "seasoned". Tagram the Great, also known as Tagram the Just, the Kraken Slayer, is not actually experienced in how to slay a kraken when he begins his adventures. You darned well cannot tell the difference between your arrow bouncing off of strong armor, or doing 1 instead of 2 damage because of damage resistance, on a monster with 300 hit points......unless you are VERY observant. Now, if a red dragon smiles when you hit it for 100 points of fire damage right after it winced at 10 points of slashing...then sure, a "seasoned" adventurer would notice that. But would a rage-filled level 15 barbarian notice that his flaming sword didn't do 2 extra points instead of just 20? These are issues for a DM to decide, not a question he's obligated to answer in a particular way. My suggestion would be to figure out an appropriate perception check DC...and drop hints to prompt requested perception checks if that DC is above passive.
The DM isn't obligated to be overt, but a good DM will give hints
First we need to recognize rule 0. The rules serve the DM and the story, not the other way around, so the DM isn't actually obligated to do anything in particular, they can shape and adjust the game however they want.
While RAW does say the DM will narrate the results of players actions (to a greater or lesser degree depending on the play group and DM's style), but this doesn't obligate the DM to be clear about how much damage an attack actually does.
That being said the DM should give some idea of some of the vulnerabilities and resistances of creatures in the game as players discover them, but just how clear that is depends on what the damage modification is and what type of damage. These should be pretty logical, like these examples of the extremes:
Immunity: a creature being immune to slashing or piercing damage should be pretty obvious - arrows bounding off their hide, blades refusing to cut, or wounds that close as soon as the blade moves through is harder to miss than a lack of bruising you couldn't even see under armor or clothing or fur from immunity to bludgeoning or force damage.
Vulnerability: bludgeoning vulnerability can be reflected as broken bones which is going to be a lot more clear (particularly in undead where the bones are often visible) than heavier bleeding from vulnerability to slashing, and most things react poorly to fire, unless they are immune - vulnerability might not make creatures react any differently to being burned than normal fire damage.
The DM has no such obligation. However (and this varies with style), the experience of the character should be considered when describing such things. For example, the conclusions drawn by a 16th level barbarian from the impact of his axe swing may be much more on-target than those drawn by a fresh level-one character who has barely ever hit anything with his axe. I would also encourage secret-roll use of skill checks like Perception, Nature or the-like to inform you about what you would share. Set DCs based on the experience of the character as well as how obvious the damage resistance might seem / be (example: slashing through a water elemental). Also note how dim light or other (hazy?) conditions might hamper a character's ability to discern the effects of their attacks. This first-level character might be able to discern that the fire did less damage to his target than the well-seasoned variety that has slung his spell in the fog ...