Is there any way to set waypoints directly on a map with a mouseclick?

If it isn’t possible, then is there a workaround?

Thanks in advance.

Could you elaborate what you mean by ‘waypoints’?

By waypoint i mean just a simple coordinate.

So you just want the coordinate in a callback? Something like this,

This is exactly what i needed
thank you