An other option is to use the Exportd ExternalSystemGenericPullJson plugin (long word ). With that, you can define a JSON output with a custom structure.
Happy new year with lots of wishes for health, happiness and everything you wish for you, your family and colleagues.
I am trying to create some custom endpoint, as mentioned above “ExternalSystemGenericPullJson”, as to enable a more “user friendly” API for users to get the necessary information.
I have successfully created two API calls, one for objects type A and one for objects type B.
Type B has a parent relationship with Type A, like branches with routers.
So in theory one would be able to GET all branches through an API call and by selecting the desired branch_id = branches object_id he could use it to get all routers attached to that branch.
However, when I issue the second API and put as a query parameter the branch_id i still get all type B results without any filtering.
How, can I filter the results of JSON pull through the value of one variable and only get all results that have the requested variable included?
Did something change? If I do /rest/object/ I just get told that the method is not allowed. I’m just trying to list alle objects - no matter of the type they have.
I can answer my own questions. The URL is /rest/objects/ and not /rest/object/ as mentioned above. Cant say if it’s a change or allways have been with the “S”.