API not working with polyline query param?

Is the server down? I’m using the following link, and it’s returning an empty array, should be returning a JSON object with15 stations.
https://api.openchargemap.io/v3/poi/?output=json&polyline=czjaG|zzyN|CmDpHlFfJKbDtWyUjn@}d@hWzRxgAy@xo@sDh^_^hZceAj@iRpZudApkD_h@uAsu@zFo\\na@cDfm@hJxnBxUqAhFjhDzCpbAqOxv@y]ns@m@hjBpBrrFnIx_E~JbuOsZfwAaFnv@p@xm@cOdl@gJ~c@tDtk@fi@veAbJvuG|Tro@fq@vs@~aB|nHfr@vc@~m@laArhAfeDrEzh@bDb}FhEfaE~MrmChJpd@f~AzZ~b@r_@NftAsKlsBl_AfBtIt~BqLjuBse@zdBaK{@rF~pE|DmDkObeCfIdvDhTznKvLbpF{T~@{LdkAEmDnHbyCzPxAs@lzAfNtwAaFdaA}Aj_FtBlpCl\\|pAp_@r{ApA|w@bQjy@vDnu@FzsCvPwGrRllBqFvgBbOtgArDjsBMzuKOzdMx@pyBn\xpAnJz~A^gEV~dCiLliDQzaHsMbk@s[|_@sr@jv@qRh]{Fnl@fB|hIvCrpMwEzjBqQxi@{q@|rA{Mrt@cB~hIaBxrFeJxgADve@l^bmBxg@tbBdSr|Dtp@hdBvxAddDtCzq@eMt}ByFnmFugArhKk^xeDa@~ChMtxCpe@|dFvYl_CkDtC~HlfGpnBlpDtsAj~EyBdrJr@vdJjKdAjkAfdEvBfhHfSnGbVrkEh^hhAl[hwA|HpFCh}Cb|@frEp[v~Bif@xvDuDnqLSpoAd@hdBbFlsEjVmEbk@hmEnRzqCjLrqFpNf~Bd|DpG~B|lCz@sAfBn~@dsBhAnp@bl@pBv_Evy@jfFpdBrwBzdAzyBj_@b@v}AzMrxBhk@v~Afs@tlCdzAzuAvl@||@yIvdAvu@foB~aBx{@bg@ptAjEfVtRvEvxInaBpjDxsAjwAndBnnAzs@~j@bp@n~@rkBvzCxsCbjFdu@l~@htBvGzgBph@hAnfBnb@|dD|n@dw@Xp^zJpe@[p{DmAt_HzF|wA|xAxeDncBbtDhLb{AxDb{DhPft@|fAhfBpNveBrHfdDxWjbBsAnnDtPnrBjQbzAvm@jrAxJl@}ZtMkG{EuBpa@jg@ftHJf|@aU|e@ko@~Ic\WgTtuC{RtyAkI~yBKhdBrMrkBkSnaE{B~iGqWr~@iXv\\kl@lScj@dAwgAnXwu@lf@q~Bl@ixCCqc@~U{WzX{e@bl@sClrD_~DngGox@~vAiA]e\\nWurDDeh@kHs`Ap@glBxCwVdaAeWvSgUu@ckAsAml@z@}GqWMwfA}NrB&maxresults=100&levelid=3&distance=5&compact=true&verbose=false

Using the same URL in my initial post, I am now getting stations that are in Fort Wayne, IN and Windsor, ON, which have never shown up in my results before using the same request parameters. It’s not an empty array any longer, but the results are still off. Could it be an issue with the polyline encoding?

Hi Mike, looks like a temporary caching glitch. The API call is returning results for that query currently. I only get 3 stations though, maybe need to adjust the filter on max distance or level.

So your polyline looks OK:
image

And it will sample results near (within 5 miles) of the polyline from this set (I’ve filtered on connector types):

I’d remove your Level filter to begin with as you will exclude results where power level is unknown. Data will variously have fields unpopulated such as connection type, level, power kw etc so any filters mean you are dropping anything that doesn’t have that data populated.

Thanks Christopher. The polyline should be a route from Detroit to Chicago, so I’ll have to investigate why the encoding (fetched from google directions api) gave me a route from Detroit to somewhere in Indiana. Possibly an issue with something unrelated to openchargemaps API. Thanks for investigating.

1 Like