Secrets in databricks

User16790091296
Databricks Employee
Databricks Employee

I created a secret on databricks using the secrets API.

Code :

Scope_name : {"scope": "dbtest", "initial_manage_principal":"user"}
Resp= requests.post('https://instancename.net/mynoteid/api/2.0/secrets/scopes/create',json=Scope_name)

Similar way, I added the user and password

Code:

Content = {"scope":"dbtest","key":"user","string_value":"Vidyasekar"}
requests.post('https://instancename.net/mynoteid/api/2.0/secrets/put', json=content)

After the execution I got response : 

<Response [200]>

Which means secrets stored successfully.

While listing the same using the list API call or 

dbutils.secrets.get()

, its shows 'Secret does not exist with scope

Here my doubt is, How to get the databricks intance name? Where the secrets stored in the DBFS location?