As terrible as AppleScript is as a language, it's really nice that Apple even built a framework for apps to use to expose their functionality to external scripts -- I'm not sure today's Apple would have gone to the trouble. And now that you can use JavaScript instead of AppleScript, with a more or less standard way of translating calls between the two, scripting+automating macOS is really painless.
I do wonder why the Shortcuts app seems to be reinventing the wheel. You'd think the functionality an app exposed to AppleScript would've been automatically made available in Shortcuts, with Shortcuts being more or less a block-based interface to the same scripting environment that AppleScript uses, but that doesn't seem to be the case. Kind of an odd choice to not build off their existing work there.
I do wonder why the Shortcuts app seems to be reinventing the wheel. You'd think the functionality an app exposed to AppleScript would've been automatically made available in Shortcuts, with Shortcuts being more or less a block-based interface to the same scripting environment that AppleScript uses, but that doesn't seem to be the case. Kind of an odd choice to not build off their existing work there.