Pulling CMC SST Data Using Python

Use this Forum to find information on, or ask a question about, NASA Earth Science data.
Post Reply
joseph.hellmers
Posts: 3
Joined: Fri May 19, 2023 2:02 pm America/New_York
Answers: 0

Pulling CMC SST Data Using Python

by joseph.hellmers » Fri May 19, 2023 2:08 pm America/New_York

Hello,

I'm trying to download some data from PO.DAAC using a token that I generated in the user interface by adding an Authorization header to the request, but it is giving me an 401 authorization error.

Does anybody know of a good example of how to do this? I see some examples in a tutorial about authorizing using a Cookie store and the user name and password, but I'm wondering if there is a better way.

Thanks,
Joe Hellmers

Tags:

PODAAC - wenhaoli
Subject Matter Expert
Subject Matter Expert
Posts: 27
Joined: Tue May 11, 2021 12:58 pm America/New_York
Answers: 0

Re: Pulling CMC SST Data Using Python

by PODAAC - wenhaoli » Mon May 22, 2023 7:22 pm America/New_York

Dear Joe,

Thank you for your inquiry.

There is a good example of obtaining the Earthdata authentication, e. g. podaac-data-subscriber. You could find the script resource from https://github.com/podaac/data-subscriber. Actually, We strongly recommend the users to use this script to download/subscriber the datasets from Earthdata cloud. The https://podaac-test.jpl.nasa.gov/dataset/CMC0.2deg-CMC-L4-GLOB-v2.0 data landing page provides the download exapmle under Data Access page. Please let us know if you have more questions.

Best Regards,

Wenhao Li

joseph.hellmers
Posts: 3
Joined: Fri May 19, 2023 2:02 pm America/New_York
Answers: 0

Re: Pulling CMC SST Data Using Python

by joseph.hellmers » Wed May 24, 2023 1:17 pm America/New_York

Thanks Wenhao!

That example uses urllib. I'm wondering if there is an example using urllib3.

Joe Hellmers

PODAAC - wenhaoli
Subject Matter Expert
Subject Matter Expert
Posts: 27
Joined: Tue May 11, 2021 12:58 pm America/New_York
Answers: 0

Re: Pulling CMC SST Data Using Python

by PODAAC - wenhaoli » Thu May 25, 2023 4:08 pm America/New_York

Dear Joe,

Sorry, I have checked with our team and confirmed that there is no examples using the urllib3.

Wenhao Li

joseph.hellmers
Posts: 3
Joined: Fri May 19, 2023 2:02 pm America/New_York
Answers: 0

Re: Pulling CMC SST Data Using Python

by joseph.hellmers » Fri May 26, 2023 8:39 am America/New_York

Thanks Wenhao.

Post Reply