Prime-facia that above is spot on
It is I and only I who has concluded that I just don’t warrant the role and the concern (bordering on fear) of being found out that in reality I do very little of value add to earn my salary is stressing me out.
I do have a referral for a psychiatrist so perhaps should explore that avenue.
I know exactly what you mean about impostor syndrome. I feel it a lot, having been in the software development industry for over 30 years. Most of the technology I started with has since become obsolete. Although the problems being faced remain very similar, so a lot of the time it's a case of re-inventing the wheel, with newer shinier, cooler tech.
But as software development technology and processes has about a 5-10 year sliding window of relevance, you can see how fresh grads coming straight out of Uni know as much, if not more about current fashionable things. Like web frameworks. Cloud deployment. DevOps. Absolutely none of this stuff even existed back when I started.
And worse still, the salary discrepancy causes resentment, and tension.
These days I try and find roles that involve team members in a similar age bracket to myself. That helps because they're on my wavelength, and getting paid similar salaries. I don't really want to stress out about some cocky little 20 something trying to prove he's better at React or Java than I am, so should get paid as much as me.
But I tell myself that experience is worth a lot. I've been around for many years, and seen projects fail. That can teach you a lot. New starters don't have that experience.
Don't know if this helps at all OP, but you're not alone in feeling impostor syndrome. Stick with it, if you don't hate your job. Take the money and invest it, as others have suggested.