From Epicurious.

Ingredients
4 prickly pears, peeled
Ice
4 ounces tequila
1 1/2 ounces triple sec
1 tablespoon freshly squeezed lime juice
1 tablespoon sugar
Coarse-grained salt for rimming (optional)
Lime slices for garnish (optional)

That does seem like the basic set of ingredients for a cactus margarita. For sugar, I would use agave syrup. You’ll have to click through for the directions on how to peel a prickly pear and what to mix together too.