How to edit the endpoint of an activity