First time here? Check out the FAQ!
Go to System Preferences -> Security & Privacy -> camera -> tick the box for Terminal