Perspective - Scripting - Get default provider for active project

I’m on 8.1.5

Is there a way to get the default provider name for the active project ?

Unable to read that tag in perspective

image

Added the perspective tag to the post title.

Since you hadn’t specified, @jespinmartin1 pointed you to a client tag, which doesn’t exist in perspective. :wink:

I’ll poke around a bit, unless someone already knows and chimes in before I get back.

Running this in the client scope should get you your default provider:

system.tag.getConfiguration('', False)[0]['path']

1 Like

Thanks, do what I want

Any tricks to get the list of all provider ?

ohh, since you asked for a default provider of project I assumed the non complicate answer.
There is no such a good way to get the provider of a project in a session, we could write some script to .getDefaultProvider() at gateway scope but well need to specify the project name somewhere, which results complicate if you just use a static global prop at your session.
I can advice you to create a session custom property with the name of the provider and make all your bindings using this.
image

[provider['name'] for provider in system.tag.browse('')]

Tanks