Question on the M2M

Aloha,

I’m using wget to obtain data from the server. I’m wondering if there is
a way to specify the format of the data downloaded?

My request looks like:
wget --auth-no-challenge --http-user=“OOIAPI-NOTTHEREALUSER”
–http-password=“TEMP-TOKEN-NOTTHEREALPASSWORD” "
https://ooinet.oceanobservatories.org/api/m2m/12576/sensor/inv/RS03AXBS/MJ03A/06-PRESTA301/streamed/prest_real_time?beginDT=2020-12-12T00:00:22.038Z&endDT=2020-12-18T00:00:22.038Z&limit=1000&parameters=94,7
"

This gives a bit more info than I need. Is there a way to specify the
format? For example, can I request CSV formatted pressure and time?

Thanks for your help

Stuart

Hi Stuart,

You can add the following to your url:

&format=application/csv&include_provenance=false&include_annotations=false

format can be application/netcdf or application/csv or application/json

I added include_provenance and include_annotations with a value of false just to cut down on output, but you can set to true if you want to keep those outputs.

Let me know if you have any other questions.

Regards,
Jim