Yep, agave. It's difficult in this case to give an exact ID since so many factors (age, sun, moisture, etc) can affect the appearance of agaves.
As for care, the main things are just make sure it's in very well-draining soil and receives plenty of sun.