AgroDataCube / api-v1

AgroDataCube API service Version 1 - A newer version is in use now.
1 stars 0 forks source link

request for soilcode with forward slash #56

Closed zoot-inge closed 4 years ago

zoot-inge commented 6 years ago

soilcode can contain forward slashes, e.g. aVz/vWz/pZn21 (8327) The request using this code fails.

yke commented 5 years ago

Encode them ?

zoot-inge commented 5 years ago

I tried encoding using JS:encodeURIComponent. Will try again...

zoot-inge commented 5 years ago

Double encoding is needed: soilcode: aVz/vWz/pZn21 encode /: aVz%2FvWz%2FpZn21 encode whole uri: aVz%252FvWz%252FpZn21

Solved but needs documentation!

robknapen commented 5 years ago

Similar issue with this request:

http://agrodatacube.wur.nl/api/v1/rest/codes/soilcodes/pZg23/pRn59

The soil code is 'pZg23/pRn59', I think this means an association between two soil types? In that case the lookup needs to be different. Sending the request with double returns an empty result.

yke commented 4 years ago

No solution at this moment. Added to WENR GIT