Starting with the REST API

Hello,

I’m trying to research datagerry to see if it’s suitable for for us. Though I’m blocked on the REST API trying to query out objects.

Though I can’t find the URL or path to query. I’ve read this several times: https://docs.datagerry.com/latest/api/rest/index.html but it dose not explain what “module” is or how to query an object.

Is there a howto or example for using the REST API ?

Thanks
J

Hi @Jeremy
i think You can use:
curl -s -u user:password https://eewid.gkpge.pl/rest/object/ - show all objects
curl -s -u user:password https://eewid.gkpge.pl/rest/object/1 - show object with id 1
if use “type” instead of “object” you could show types

Hello @marcinw that is what I was looking for, thank you. :grinning:

@Jeremy
No problem, i knowed so i wrote it :slight_smile:

Hi all

Is there a way i can get objects of a specific type through an API call?
As to then get the desired object ID?

Thank you
Best Regards
Konstantinos Betsis

Hi @kbetsis,

you can use the following REST call to get all objects of a specific type:

curl -u user:password http://127.0.0.1:4000/rest/object/type/<typeID>

An other option is to use the Exportd ExternalSystemGenericPullJson plugin (long word :slight_smile: ). With that, you can define a JSON output with a custom structure.