Question

Get the ID by inputting the Name in Looker API

  • 2 September 2021
  • 1 reply
  • 108 views

I am trying to get the id of the Model set, Permission set and Role using the Looker API.

I want to know if there is any way to get the id and other details about the above things just by providing their name.

I know there are functions where we can provide the id and get the details but I want to use the entity name instead of the id.


This topic has been closed for comments

1 reply

Userlevel 4
Badge
model_set = sdk.search_model_sets(name="AdamTest")
print(model_set[0].id)

 

This is an example with the python sdk, but the same principle can be applied for search roles and search permission set

 

Please let us know if you have any questions.

 

Thanks,

Eric