You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The error occurs because the endpoint requires editor privileges, not just authentication. Even with a valid token, you need to have the "editor" role to add multiple GCPs.
Looks like the methods / endpoint in the API is missing for this.
add_many in the v1/api is adding many control points to many maps - useful during an import process.
In the non-api api used in the application there is the add_many_to_map method, which adds many gcps to one specific map. Confusingly the url is add_many but is gcps/add_many/${map_id}
After successfully getting a token, uploading a map, and verifying a token (all using API), I am unable to add control points to my map.
URL:
https://mapwarper.net/api/v1/gcps/add_many
Method:
POST
headers:
body:
{"gcps":[ { "mapid":"89204", "x":13.732928679828, "y":291.75644916533, "lat":48.3831032911, "lon":16.8349036568 }, { "mapid":"89204", "x":272.42981790593, "y":426.6767830045, "lat":47.826525191, "lon":18.8564658158 }, { "mapid":"89204", "x":379.74677541733, "y":77.53509104687, "lat":49.6134906752, "lon":19.4682669632 }, { "mapid":"89204", "x":582.5919954477, "y":128.54040212423, "lat":49.4184696716, "lon":21.0480880729 }, { "mapid":"89204", "x":777.92583459792, "y":202.42128224564, "lat":49.0879626791, "lon":22.5658321372 }, { "mapid":"89204", "x":416.6113429439, "y":376.89017450668, "lat":48.1247222464, "lon":19.90014553 }, { "mapid":"89204", "x":72.036229135096, "y":198.47591047018, "lat":48.8780240931, "lon":17.2026586527 } ] }
Response:
Maybe this request does not allow token authentication? The example in the doc uses cookie.
The text was updated successfully, but these errors were encountered: