[Spce-user] Inconsistency in customers API

Irina Peshinskaya ipeshinskaya at sipwise.com
Wed Jan 10 15:01:26 EST 2018


Dear Javier,

Could you please send output of the:
grep api_embedded_forcearray /etc/ngcp-config/config.yml

?

Best regards,
Irina Peshinskaya

On 10.01.2018 19:58, Javier Matos Odut wrote:
> Hello,
>
> I am working with the API and I found an inconsistency in results 
> (SIPWISE v5.5.2).
>
> Entry point: /api/customers/
>
> Case 1: retrieve page 1 with 1 row:
>
> {
>     "_embedded": {
>     ...,
>     "ngcp:customers": [...] <- this is a list of objects
>     },
>     "_links": {
>     ...,
>     "ngcp:customers": {...} <- this is an object
>     }
> }
>
> Case 2: retrieve page 1 with 2 or more rows:
>
> {
>     "_embedded": {
>     ...,
>     "ngcp:customers": [...] <- this is a list of objects
>     },
>     "_links": {
>     ...,
>     "ngcp:customers": [...] <- this is a list of objects
>     }
> }
>
> So "ngcp:customers" must always be a list in "_links", even when you 
> are asking for one row.
>
> Regards,
> Javier
>
>
> _______________________________________________
> Spce-user mailing list
> Spce-user at lists.sipwise.com
> https://lists.sipwise.com/listinfo/spce-user

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.sipwise.com/pipermail/spce-user_lists.sipwise.com/attachments/20180110/3a7ea1df/attachment-0001.html>


More information about the Spce-user mailing list