[Answered ]-Converting geoserver cURL to python requests

2👍

I got it:

headers = {'content-type': 'text/xml'}
r1 = requests.post("http://localhost:8080/geoserver/rest/workspaces", 
    auth=('admin', 'geoserver'), 
    data='<workspace><name>acme</name></workspace>',
    headers=headers)
👤mrbf

Leave a comment