起初,我尝试了the instructions in the official wiki of OpenStreetMap尽管警告版本0.6。
当想要下载节点的数据但删除节点不起作用时,建议的方法仍然有效:
curl -u username:password -X DELETE 'https://api.openstreetmap.org/api/0.6/node/6345940173'
The documentation of the API声明“预期要删除的元素的有效XML表示”。我还需要做些什么才能让它发挥作用?
我的最后一次尝试不起作用:
curl -u username:password -X DELETE 'https://api.openstreetmap.org/api/0.6/node/6345940173' -T delete.xml
delete.hml:
<?xml version="1.0" encoding="UTF-8"?><osm><node id="6345940173" version="1" changeset="68272837" lat="48.8647893" lon="2.4283983"></node></osm>
它只是告诉:
变更集68272837于2019-03-18 21:01:43 UTC结束
当我使用echo -ne username:password|base64 --wrap 0
编写凭证并且当我调用curl -H "Authorization: Basic <my_token>" -X DELETE 'https://api.openstreetmap.org/api/0.6/node/6345940173' -T delete.xml
时,我获得了相同的结果。