Skip to Content
Menu
This question has been flagged
1200 Rodiniai

I have found this code connect odoo with api but from where I can get url, db,username, and password? Can anyone help me from where I can get these credentials?

I have found psql information from odoo shell env. I tried but its showing authentication failed.


Looking for these credentials. Anyone can help to find these information?



import requests

url = "instance url"
db = "your_database"
username = "your_username"
password = "your_password"

headers = {'Content-Type': 'application/json'}
data = {
    'jsonrpc': '2.0',
    'method': 'call',
    'params': {
        'db': db,
        'login': username,
        'password': password
    },
    'id': 1
}

response = requests.post(url, json=data, headers=headers)
session_id = response.cookies.get('session_id')





Portretas
Atmesti
Related Posts Replies Rodiniai Veikla
1
bal. 25
797
2
saus. 25
864
0
rugs. 24
4
1
birž. 24
1652
1
kov. 24
2046