What do you want to save?
Add Code snippet
New code examples
-
TypeScript 2021-09-13 02:28:01
how to convert price data into charts in python
import plotly.express as px import plotly.graph_objects as go import pandas as pd import requests import json quote = ‘AAPL’days = 300 def candlestick(quote,days): r = requests.get(f’https://financialmodelingprep.com/api/v3/historical-p... Add solution -
Other 2021-09-07 20:24:02
web scrape forex live prices
import pandas as pd import time import requests from bs4 import BeautifulSoup from selenium import webdriver url = 'https://www.forexfactory.com/calendar.php?month=last' response = requests.get(url) data = response.text soup = BeautifulSoup(data, 'lxml') Add solution -
Javascript 2021-09-06 13:04:02
nested json to csv python
import json import csv import requests response = requests.get('https://statsapi.web.nhl.com/api/v1/teams') json_data = response.json() def get_leaves(item, key=None): if isinstance(item, dict): leaves = {} for i in item.keys(): ... Add solution -
Python 2021-09-06 05:55:03
python requests
>>> r = requests.get('https://api.github.com/user', auth=('user', 'pass')) >>> r.status_code 200 >>> r.headers['content-type'] 'application/json; charset=utf8' >>> r.encoding 'utf-8' >>> r.text u'{"type&qu... Add solution -
Python 2021-09-06 00:22:02
save request response json to file python
import requests # there is inbuilt json() constructor for requests.get() method json_data = requests.get("https://api.blinkist.com/v4/books/5420831a63656400089f0000").json() print(json_data) # To actually write the data to the file, we just cal... Add solution