Skip to main content

Hi all,

 

I want to pulling data from a knowledge model through the following code ...

 

space = celonis.apps.get_spaces().find('Default')

package = space.get_packages().find('Knowledge Model Test')

knowledge_model = package.get_knowledge_model('999-automation-rate-bw-download')

content = knowledge_model.get_content()

 

But I get the error "PyCelonisPermissionError: You don't have permission to perform 'GET' ", even I have set all possible permissions (for "Space" / "Package / "Analysis").

Any ideas which permissions are missing.

Unfortunately the article below does not help me here.

 

Thanks in advance,

Best,

Jonas

 

Hi Jonas,

for which call do you get the permission error? Can you try using `celonis.apps.get_space(<space-id>)` ?

 

You can find the ID in the URL when you open the space: /package-manager/ui/studio/ui/spaces/<ID>


Hi Simon,

thanks for your reply.

celonis.apps.get_space(<space-id>) is working. So on space level no problem.

 

But in row 3 I get the permission error, when I want to instantiate the knowledgemodel:

knowledge_model = package.get_knowledge_model('Knowledge_Model_Name_Here')

 

I do it as documented here:

Pulling Data from a Knowledge Model - PyCelonis

 

Thanks in advance.

Best,

Jonas


Hi Jonas,

can you try `package.get_knowledge_models()` to verify if you have access to the knowledge model? If that is the case you can also do `package.get_knowledge_models().find(...)`.

 

Best,

Simon


Hi Simon,

it works now. Stupid mistake on my part. I have used the 'Key' from the Knowledge Model instead of the ID in the URL.

 

Thanks a lot for your support and have a nice weekend.

 

Best,

Jonas


Reply