Created
December 13, 2017 10:18
-
-
Save leadbi/c18c5b2e3aa31c1c43747d7bfd1f403e to your computer and use it in GitHub Desktop.
LeadBI Python API Call Example
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# LeadBI Python Api call example | |
import requests | |
import json | |
# Examples | |
# https://gist.github.com/leadbi/82235eedc9619d33a7c7e0ba71e41985 | |
# | |
# API Calls | |
# https://gist.github.com/leadbi/4c46c91d4f2d6fb5a3ef431c1414564b | |
# | |
# Note: Only read (GET) requests are allowed by default. For write request please send a email at info@leadbi.com | |
# You can create an api key pair here: https://app.leadbi.com/app/account.html#api-section | |
ACCESS_ID = 'your access id' | |
ACCESS_SECRET = 'your access secret' | |
headers = { | |
'X-Access-Id': ACCESS_ID, | |
'X-Access-Secret': ACCESS_SECRET | |
} | |
url = 'https://app.leadbi.com/api/v1/websites' | |
request = requests.get(url, headers=headers) | |
print(json.loads(request.text)) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment