Only take land boundary

I am trying to get the boundaries of locations via “http://overpass-api.de/api/interpreter”.My query is like this (python)

[out:json];  
relation["name:en"="{place_name}"]["boundary"="administrative"];
(._;>;);
out geom;    

The problem is that the nodes I get in the result include coordinates that are over sea. How can I get the nodes that have coordinates that are only on land?
Thank you

Please have a look at Administrative borders Germany - #5 by Nakaner where @Nakaner explains this for admin_level=5 in Germany.

You may be able to adapt this to your problem.