Create a Post
cancel
Showing results for 
Search instead for 
Did you mean: 
mthibaut858
Explorer
Jump to solution

Using the API to read out objects on doman server

We use an MDS and SmartConsole to manage our domains. We would like to read out information from the domains for billing purposes.

But we don't seem to be able to accomplish this using the API.

To reproduce:

  • Open SmartConsole to the MDS
  • Select a domain and connect
  • You can now search for objects in the right hand pane. This works

From the API, how would we accomplish this?

See screenshot for an example, with sensitive info removed.

Thanks for any help you can give me!

 

Thanks,

maarten

0 Kudos
1 Solution

Accepted Solutions
PhoneBoy
Admin
Admin
This can be done one of two ways:
1. Connect to the domain/CMA IP instead.
2. Specify the "domain" parameter as part of your login call.

Note that a given session can only be tied to a given domain/CMA or the global domain.
If you need to query across domains, that requires a separate session to be created.

View solution in original post

4 Replies
PhoneBoy
Admin
Admin
So if I'm understanding correctly, you want a list of gateways and host/network objects correct?
The api calls would be show simple-gateways, show hosts, and show networks respectively.
Note that if you have a lot of these objects, then you will need to iterate through each of these lists in blocks of x (where X is the limit returned, which can be 500, but it depends on the exact call/version).
0 Kudos
mthibaut858
Explorer

Hi PhoneBoy,

Thanks for your answer! I've not been able to get back on this for a while so sorry for the delay in my response.

I've tried all these, but the objects I can see in the SmartConsole GUI aren't showing up. In my code I'm able to iterate over the objects if there's more than 500 entries, so that's not the issue. Interestingly, I also can't see the objects when using a web browser to connect to the MDS. Only SmartConsole appears to "see" them.

I've tried iterating over the domains and looking at the data coming from the domains instead of the MDS, but it's giving the same information. It looks like I'm only getting the objects defined at the MDS level, and not the objects defined in the domains... Plus, there is no way in the API that I can see to specify a domain for any of these calls.

Not sure how to proceed here... I am wondering what calls SmartConsole uses to call the API, or if perhaps SmartConsole doesn't use the API at all.

Thanks!

0 Kudos
PhoneBoy
Admin
Admin
This can be done one of two ways:
1. Connect to the domain/CMA IP instead.
2. Specify the "domain" parameter as part of your login call.

Note that a given session can only be tied to a given domain/CMA or the global domain.
If you need to query across domains, that requires a separate session to be created.
mthibaut858
Explorer

That did the job. I went for #2. I tried #1 but that one didn't work for me unless I also did #2.

Thank you so much for your help!

0 Kudos

Leaderboard

Epsum factorial non deposit quid pro quo hic escorol.

Upcoming Events

    CheckMates Events