Verify signed message

Hi guys,
a couple of things I need your help with if you can kindly provide it:

  1. let’s say a user signs in using Internet Identity on my app. Can I use @dfinity/agent to sign a message in the front end and then in my centralised Node.js backend to verify the signature using a public key? Or how could I do this?

I see SignIdentity has a method sign… but not sure how to use. If you can be more explicit as I am a beginner…

  1. Using Node.js, what SDK can I use to connect to IC to query or update? (I mean how can I do this as a logged in II from Node.js… in front end we use AuthClient and HttpAgent, right? what about the backend though? How do I get the client setup having logged in using public/private key instead of opening window to use provider for authentication?)

for example use:
authClient.login with identity and the private key or something similar directly without getting the user through the login provider