There should be fuse info in your owner's manual or manually checking for a blown fuse (if the power roof fuse is blown). The engine fuse box should have labeling on the inside of the fuse cover or outside in plain view. Other fuses may be inside one or both footwells. If the buy was recent, returning to the seller may be part of their warranty. Hopefully, a blown fuse is preventing sunroof operation. A damaged or worn out sr motor may be a worse case scenario when lack of periodic lubrication or cleaning is performed to keep track free of debris is likely a reason for wear and tear. Roof damage and water leaks are other reasons for sticking sunroofs.