Skip to main content

Messages

This section allows you to view all Messages made by this member. Note that you can only see Messages made in areas you currently have access to.

Messages - wegarzon

1
HMDB / API Py Doubt
I'm trying to obtain information by HMDB ID using API for Python. I use the following code and it does not work, it returns empty values. The code is based on your website.

Python code:

import requests
url = "http://api.xialab.ca/mapcompounds"
payload = "{\n\t\"queryList\": \"HMDB0000002;\",\n\t\"inputType\": \"hmdb\"\n}"

headers = {
    'Content-Type': "application/json",
    'cache-control': "no-cache",
    }

response = requests.request("POST", url, data=payload, headers=headers)
print(response.text)

Thanks

Wilmer G