Because I find Google Apps Admin SDK Directory API PHP Quickstart to be a bit ... spare, and because I spent far too much time searching to find proper examples, here's one more place for poor saps like myself to maybe find some of what they need.
First, the PHP Quickstart, linked above. That should at least get a person connected.
Second, this lovely bit from Michael Seiler. The details (as of November 2016) are no longer quite the same (e.g., the line numbers he refers to in the code are no longer correct), but on the whole this worked.
Third, this thing that a suitably-energized person can probably figure out. (I was able to see, at least somewhat, what Michael Seiler was referring to by using this. That was not the case from looking at the code I'd downloaded from the Quickstart.)
First, the PHP Quickstart, linked above. That should at least get a person connected.
Second, this lovely bit from Michael Seiler. The details (as of November 2016) are no longer quite the same (e.g., the line numbers he refers to in the code are no longer correct), but on the whole this worked.
Third, this thing that a suitably-energized person can probably figure out. (I was able to see, at least somewhat, what Michael Seiler was referring to by using this. That was not the case from looking at the code I'd downloaded from the Quickstart.)