Palmy Investing API

KOSTENLOS
Durch palmyinvesting | Aktualisiert לפני חודשיים | Finance
Popularität

8.3 / 10

Latenz

1,280ms

Service Level

100%

Health Check

N/A

Zurück zu allen Tutorials (3)

Python GET request

Requirements
  • Code Editor f.ex. PyCharm
  • Python Interpreter set up
  • Requests library (pip install requests)
  • An API key similar to:
    • 41176a86205a3aa668c4b30d41dbfc50bd29bdd2e5aeb6abfb02f2d8304e2f6e
GET Requests

Now we will make a request to one of the Quote endpoints:

import requests

#Keep this format and set variable_for_api_key
my_api_key = “Token {}”.format(variable_for_api_key)

#change this with the endpoint you need to call:
url = “https:/palmy-investing.com/api/earning-events/”

#prepare the headers headers = {“Authorization”: my_api_key}

#start the request
response = requests.get(url, headers=headers)

#json_response holds the data
json_response = response.json()

#You can f.ex. print it
print(json_response)