Accessing ERDDAP private tables using erddapy

52 views
Skip to first unread message

Carles Castro Muniain

unread,
Oct 23, 2023, 12:06:24 PM10/23/23
to ERDDAP
Dear all,

I am trying to access private tables using erddapy in Python. I have been able to find this link where we could access tables via a script, but I was wondering if that would be possible using the Python library.

My example code is very simple, but I wanted to test whether I could access to private tables:

from erddapy import ERDDAP
e = ERDDAP(
    server="https://server-name/erddap",
    protocol="tabledap"
)

e.dataset_id = "dataset-name"
e.auth = ("email...@email.com", "password")
df = e.to_pandas()

The username I am using allows me to access private tables in erddap but not erddapy. This is the log error I get when running the script.

HTTPError: Error { code=401; message="Unauthorized: loggedInAs= isn't authorized to access datasetID="dataset-name";}
Does anyone know how to do this?
Thank you all,

Carles

Bob Simons

unread,
Oct 25, 2023, 5:39:45 AM10/25/23
to Carles Castro Muniain, ERDDAP, Filipe Pires Alvarenga Fernandes
I hope someone will answer here. Otherwise, you might submit this to the ERDDAPY people.

An alternative is to make a request for an alternative way to access private datasets on ERDDAP, e.g., getting a token than can be used for requests from one IP address and is good for e.g., 60 minutes. The advantage is that that would help all users of scripts, not just Python users.

--
You received this message because you are subscribed to the Google Groups "ERDDAP" group.
To unsubscribe from this group and stop receiving emails from it, send an email to erddap+un...@googlegroups.com.
To view this discussion on the web, visit https://groups.google.com/d/msgid/erddap/02975756-3e38-4dd3-836c-52b3a1f01758n%40googlegroups.com.

Micah Wengren - NOAA Federal

unread,
Jan 16, 2024, 11:44:00 AMJan 16
to ERDDAP
Hi Carles, 

Could you please post an issue in the erddapy GitHub repository (https://github.com/ioos/erddapy) to address this?  

The issue you raise is more related to erddapy than ERDDAP itself in regard to authentication, and would be better discussed there.  

Thanks,
Micah

Reply all
Reply to author
Forward
0 new messages