You could use the
AdGroupCriterionService.get() method to retrieve the
id of criterion. You may check this
sample code in Java (also available in other languages) for your reference. In reports, you could get the criteriaId by searching the report field name in this
link. Also, you could check this
guide for table of criterion IDs.
Feel free to write back if you have further clarifications.