Python Forum
Fred Economic Data API - Printable Version

+- Python Forum (https://python-forum.io)
+-- Forum: Python Coding (https://python-forum.io/forum-7.html)
+--- Forum: Web Scraping & Web Development (https://python-forum.io/forum-13.html)
+--- Thread: Fred Economic Data API (/thread-41667.html)



Fred Economic Data API - warrior42 - Feb-26-2024

Hello,

I was hoping to get a hand in setting up the Fred Economic Data API. I'm relatively new at using Python so I will need a basic understanding if anyone has some time to help me out here.

I currently have an API key assigned to me but not sure how to retrieve the data. Would I have to download packages from Fred?

I'm throwing darts here and tried the following, but errors were returns. (attached)

pip install full-fred
!pip install fredapi

Thanks,

Mike


RE: Fred Economic Data API - buran - Feb-26-2024

Are you behind a proxy or something? Also, please, don't post images of code/data/errors. Post as text using BBCode


RE: Fred Economic Data API - warrior42 - Feb-26-2024

(Feb-26-2024, 06:29 PM)buran Wrote: Are you behind a proxy or something? Also, please, don't post images of code/data/errors. Post as text using BBCode

Thanks for the response and heads up about BBcode. I am on a VPN and within my proxy settings the option to "use setup script" is "on" with a company script address included.

Just turned the VPN off and got this error (I hope I shared it correctly)
Error:
Could not fetch URL https://pypi.org/simple/full-fred/: There was a problem confirming the ssl certificate: HTTPSConnectionPool(host='pypi.org', port=443): Max retries exceeded with url: /simple/full-fred/ (Caused by SSLError(SSLCertVerificationError(1, '[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: self signed certificate in certificate chain (_ssl.c:1129)'))) - skipping Could not fetch URL https://pypi.org/simple/pip/: There was a problem confirming the ssl certificate: HTTPSConnectionPool(host='pypi.org', port=443): Max retries exceeded with url: /simple/pip/ (Caused by SSLError(SSLCertVerificationError(1, '[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: self signed certificate in certificate chain (_ssl.c:1129)'))) - skipping Note: you may need to restart the kernel to use updated packages. WARNING: Retrying (Retry(total=4, connect=None, read=None, redirect=None, status=None)) after connection broken by 'SSLError(SSLCertVerificationError(1, '[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: self signed certificate in certificate chain (_ssl.c:1129)'))': /simple/full-fred/ WARNING: Retrying (Retry(total=3, connect=None, read=None, redirect=None, status=None)) after connection broken by 'SSLError(SSLCertVerificationError(1, '[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: self signed certificate in certificate chain (_ssl.c:1129)'))': /simple/full-fred/ WARNING: Retrying (Retry(total=2, connect=None, read=None, redirect=None, status=None)) after connection broken by 'SSLError(SSLCertVerificationError(1, '[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: self signed certificate in certificate chain (_ssl.c:1129)'))': /simple/full-fred/ WARNING: Retrying (Retry(total=1, connect=None, read=None, redirect=None, status=None)) after connection broken by 'SSLError(SSLCertVerificationError(1, '[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: self signed certificate in certificate chain (_ssl.c:1129)'))': /simple/full-fred/ WARNING: Retrying (Retry(total=0, connect=None, read=None, redirect=None, status=None)) after connection broken by 'SSLError(SSLCertVerificationError(1, '[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: self signed certificate in certificate chain (_ssl.c:1129)'))': /simple/full-fred/ ERROR: Could not find a version that satisfies the requirement full-fred (from versions: none) ERROR: No matching distribution found for full-fred WARNING: There was an error checking the latest version of pip.