How to Access LAADS DAAC Data Files Using S3 Direct Access
- Download this S3 Direct Access Lambda zipfile to your computer. The file contains necessary libraries and modifiable sample code that you can upload to your Amazon Web Services Account.
- Log in to your Amazon Web Services Account.
- Under Services, click “All Services,” scroll down and choose “Lambda.”
- Select "Oregon (US-West-2)" from the dropdown menu on the top right.
- Click “Create function.”
- Enter a “Function Name” in the associated field and change “Runtime” to Python 3.9. Leave all other settings unchanged. Then click “Create Function” in the lower right.
- Click “Upload From” and select the zipfile you downloaded in step 1 and click “Save.”
- Enter “Event Name” (This field is required).
- Click “Test,” select “Create new event,” enter in the “Event JSON” box the endpoint code below, replacing “YourUsername” and “YourPassword” with your Earthdata Login username and password. Then, click “Save.”
- Click “Code.” Then click the green “+” in the circle, then select “New File.” This will open a tab where you can enter code. Copy the python code from the ReadME file under “Python Example” and paste it in this section.
- Scroll down to “Runtime Settings,” Click “Edit” and change the Handler to “s3_direct_access.lambda_handler.” (Note: this is case sensitive). Then click “Save”
- Click on “Configuration,” then click “Edit.” Under “Timeout” change to 1 minute. Click “Save.”
- Click “Code” then click the orange “Test” button.
{
"s3_endpoint": "https://data.laadsdaac.earthdatacloud.nasa.gov/s3credentials",
"edl_username": "YourUsername",
"edl_password": "YourPassword",
"bucket_name": "prod-lads"
}
Additional instructions and sample code for direct access to LAADS DAAC AWS S3 datasets bucket can be found
at:
https://data.laadsdaac.earthdatacloud.nasa.gov/s3credentialsREADME
AWS credentials (in JSON format) are given by authenticating with Earthdata Login via the LAADS DAAC
s3credentials
endpoint:
https://data.laadsdaac.earthdatacloud.nasa.gov/s3credentials
See the code examples in the S3 Credentials README.
Last updated: May 25, 2023