add agent endpoint