[ 
https://issues.apache.org/jira/browse/ATLAS-4366?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17385914#comment-17385914
 ] 

ighack commented on ATLAS-4366:
-------------------------------

import requests
import json

baseurl = 'http://bigdser5:22222'
action = "/api/atlas/v2/search/basic?typeName=hive_db"
resp = requests.get(baseurl+action, auth=('jztwk', '123456'))
content = json.loads(resp.content.decode('utf-8'))
print(content)

> How do I use API
> ----------------
>
>                 Key: ATLAS-4366
>                 URL: https://issues.apache.org/jira/browse/ATLAS-4366
>             Project: Atlas
>          Issue Type: Task
>          Components: atlas-webui
>    Affects Versions: 2.1.0
>            Reporter: ighack
>            Priority: Major
>
> I enable HA
> if I run API without cookie I get 
> "
>  Error 401 Full authentication is required to access this resource
>  "
> in applicaion I get
> "Not active. Redirecting to [http://bigdser5:22222/api/atlas/v2/search/basic] 
> (ActiveServerFilter:172)"
>  
> but I run API with cookie,I get result 
>  
> How can  I login with API and get cookie



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to