Author Topic: Weatherlink API v1 server error #12  (Read 3548 times)

0 Members and 1 Guest are viewing this topic.

Offline Bashy

  • brecklandweather.com/meteo
  • Forecaster
  • *****
  • Posts: 1466
  • brecklandweather.com/index.php
    • Breckland Weather
Weatherlink API v1 server error #12
« on: October 05, 2021, 02:53:32 AM »
Hi, does anyone have any answers to this, please?

Server error! #12

My details were copied and pasted so there is no chance of them being incorrect, plus, its an invalid request if the user details are incorrect, the token on the other produces error #12 when i change some of the characters as a test, so it could very well be a token issue but that too was copied and pasted, i mean, who in their right mind would type all that in lol actually, i am gonna try that now, 2 seconds...... damn it didn't work, same error :(
Kind regards
Bashy

Offline johnd

  • Forecaster
  • *****
  • Posts: 4970
    • www.weatherstations.co.uk
Re: Weatherlink API v1 server error #12
« Reply #1 on: October 05, 2021, 04:01:49 AM »
Don't know what that particular error relates to, but are you trying to access WLL data at wl.com via the v1 API? That won't work AFAIK - you need to use the v2 API for WLL (and EM stations).
Prodata Weather Systems
Prodata's FAQ/support site for Davis stations
Includes many details on 6313 Weatherlink console.
UK Davis Premier Dealer - All Davis stations, accessories and spares
Cambridge UK

Sorry, but I don't usually have time to help with individual issues by email unless you are a Prodata customer. Please post your issue in the relevant forum section here & I will comment there if I have anything useful to add.

Offline Bashy

  • brecklandweather.com/meteo
  • Forecaster
  • *****
  • Posts: 1466
  • brecklandweather.com/index.php
    • Breckland Weather
Re: Weatherlink API v1 server error #12
« Reply #2 on: October 05, 2021, 05:08:14 AM »
I was just following the link examples front he email it sent when I setup v1

https://api.weatherlink.com/v1/NoaaExt.xml?user=001D0A00DE6A&pass=DEMO&apiToken=demo0a002bc5272033001d0a002bc527
Kind regards
Bashy

Online wvdkuil

  • Wim van der kuil
  • Forecaster
  • *****
  • Posts: 2009
    • My PWS at Leuven Belgium Europe
Re: Weatherlink API v1 server error #12
« Reply #3 on: October 05, 2021, 05:21:12 AM »
I was just following the link examples front he email it sent when I setup v1

https://api.weatherlink.com/v1/NoaaExt.xml?user=001D0A00DE6A&pass=DEMO&apiToken=demo0a002bc5272033001d0a002bc527
Hi Martin,

That is version one API: api.weatherlink.com/v1/NoaaExt.xml
That one is used for a Davis IP-logger or upload  by weatherlink.exe to weatherLink.com
That xml has  a lot of other goodies for weather-websites, such as high-lows.

v2 API is needed for WLL devices, totally different data, f.i. a lot of detailed rain-measurements.
But no high-lows for other weather-items such as temperature.

When you have multiple items in your station, you can check / find the correct data and station-number for your devices at https://pwsdashboard.com/wll/

Succes,
Wim
« Last Edit: October 05, 2021, 05:23:38 AM by wvdkuil »

Offline johnd

  • Forecaster
  • *****
  • Posts: 4970
    • www.weatherstations.co.uk
Re: Weatherlink API v1 server error #12
« Reply #4 on: October 05, 2021, 05:27:35 AM »
But accessing what type of station? v1 API is for legacy loggers etc and not WLL. v2 is more complicated but can do a lot more. I have some notes online at https://www.manula.com/manuals/pws/davis-kb/1/en/topic/v2-api-data-access-by-programs and of course the primary API reference is at weatherlink.github.io .
Prodata Weather Systems
Prodata's FAQ/support site for Davis stations
Includes many details on 6313 Weatherlink console.
UK Davis Premier Dealer - All Davis stations, accessories and spares
Cambridge UK

Sorry, but I don't usually have time to help with individual issues by email unless you are a Prodata customer. Please post your issue in the relevant forum section here & I will comment there if I have anything useful to add.

Offline Bashy

  • brecklandweather.com/meteo
  • Forecaster
  • *****
  • Posts: 1466
  • brecklandweather.com/index.php
    • Breckland Weather
Re: Weatherlink API v1 server error #12
« Reply #5 on: October 05, 2021, 05:31:35 AM »
I was just following the link examples front he email it sent when I setup v1

https://api.weatherlink.com/v1/NoaaExt.xml?user=001D0A00DE6A&pass=DEMO&apiToken=demo0a002bc5272033001d0a002bc527
Hi Martin,

That is version one API: api.weatherlink.com/v1/NoaaExt.xml
That one is used for a Davis IP-logger or upload  by weatherlink.exe to weatherLink.com
That xml has  a lot of other goodies for weather-websites, such as high-lows.

v2 API is needed for WLL devices, totally different data, f.i. a lot of detailed rain-measurements.
But no high-lows for other weather-items such as temperature.

When you have multiple items in your station, you can check / find the correct data and station-number for your devices at https://pwsdashboard.com/wll/

Succes,
Wim

Thanks Wim, i just read this morning that the v1 is realtime where as v2 is to the minute? hence looking at V1
I will take a look at your PWS link, thank you
Kind regards
Bashy

Offline Bashy

  • brecklandweather.com/meteo
  • Forecaster
  • *****
  • Posts: 1466
  • brecklandweather.com/index.php
    • Breckland Weather
Re: Weatherlink API v1 server error #12
« Reply #6 on: October 05, 2021, 05:32:57 AM »
But accessing what type of station? v1 API is for legacy loggers etc and not WLL. v2 is more complicated but can do a lot more. I have some notes online at https://www.manula.com/manuals/pws/davis-kb/1/en/topic/v2-api-data-access-by-programs and of course the primary API reference is at weatherlink.github.io .

Hi John, like i just said to Wim,  i just read this morning that the v1 is realtime where as v2 is to the minute? and works with WLL (i think) hence looking at V1, i will have to try to find the reply to the post on here again, may take a while mind...
Kind regards
Bashy

Offline Bashy

  • brecklandweather.com/meteo
  • Forecaster
  • *****
  • Posts: 1466
  • brecklandweather.com/index.php
    • Breckland Weather
Re: Weatherlink API v1 server error #12
« Reply #7 on: October 05, 2021, 05:42:53 AM »
phew, didnt think it would be that easy to find, this is the reply i read, it was actually to you John
https://www.wxforum.net/index.php?topic=42787.msg436637#msg436637

Apologies, its not live, its to the minute and after reading it again, he's obviously doing a lot more than just using the link to view the data
« Last Edit: October 05, 2021, 05:46:55 AM by Bashy »
Kind regards
Bashy

Offline Bashy

  • brecklandweather.com/meteo
  • Forecaster
  • *****
  • Posts: 1466
  • brecklandweather.com/index.php
    • Breckland Weather
Re: Weatherlink API v1 server error #12
« Reply #8 on: October 05, 2021, 05:52:45 AM »
I was just following the link examples front he email it sent when I setup v1

https://api.weatherlink.com/v1/NoaaExt.xml?user=001D0A00DE6A&pass=DEMO&apiToken=demo0a002bc5272033001d0a002bc527
Hi Martin,

That is version one API: api.weatherlink.com/v1/NoaaExt.xml
That one is used for a Davis IP-logger or upload  by weatherlink.exe to weatherLink.com
That xml has  a lot of other goodies for weather-websites, such as high-lows.

v2 API is needed for WLL devices, totally different data, f.i. a lot of detailed rain-measurements.
But no high-lows for other weather-items such as temperature.

When you have multiple items in your station, you can check / find the correct data and station-number for your devices at https://pwsdashboard.com/wll/

Succes,
Wim

Hi again, i add the to keys to your page and it finds the station, but when i add the ID at the bottom of that page to check it, I get a 404 error

Code: [Select]
Returncode =404

{"code":"404","message":"Unable to find weather station settings"}
Kind regards
Bashy

Online wvdkuil

  • Wim van der kuil
  • Forecaster
  • *****
  • Posts: 2009
    • My PWS at Leuven Belgium Europe
Re: Weatherlink API v1 server error #12
« Reply #9 on: October 05, 2021, 06:07:39 AM »

Hi again, i add the to keys to your page and it finds the station, but when i add the ID at the bottom of that page to check it, I get a 404 error

Code: [Select]
Returncode =404
{"code":"404","message":"Unable to find weather station settings"}

I have no idea what you refer to with "add the ID"
The station is a number such as 891234
Both the api-key and the secret key are long strings of characters.

Below  a more readable print of the WLL data, that data you can use in scripts to display the data.
Code: [Select]
Array
(
    [sensors] => Array
        (
            [0] => Array
                (
                    [lsid] => 301024
                    [data] => Array
                        (
                            [0] => Array
                                (
                                    [temp_in] => 63.8
                                    [heat_index_in] => 61.3
                                    [dew_point_in] => 42.3
                                    [ts] => 1633427112
                                    [hum_in] => 45.4
                                )

                        )

                    [sensor_type] => 243
                    [data_structure_type] => 12
                )

            [1] => Array
                (
                    [lsid] => 301025
                    [data] => Array
                        (
                            [0] => Array
                                (
                                    [rx_state] => 0
                                    [wind_speed_hi_last_2_min] => 6.62
                                    [hum] => 72.8
                                    [wind_dir_at_hi_speed_last_10_min] => 149
                                    [wind_chill] => 62.4
                                    [rain_rate_hi_last_15_min_clicks] => 0
                                    [thw_index] => 61.8
                                    [wind_dir_scalar_avg_last_10_min] => 115
                                    [rain_size] => 2
                                    [uv_index] =>
                                    [wind_speed_last] => 1.5
                                    [rainfall_last_60_min_clicks] => 0
                                    [wet_bulb] => 56.6
                                    [rainfall_monthly_clicks] => 134
                                    [wind_speed_avg_last_10_min] => 2.12
                                    [wind_dir_at_hi_speed_last_2_min] => 149
                                    [rainfall_daily_in] => 0
                                    [wind_dir_last] => 96
                                    [rainfall_daily_mm] => 0
                                    [rain_storm_last_clicks] => 134
                                    [tx_id] => 5
                                    [rain_storm_last_start_at] => 1633112281
                                    [rain_rate_hi_clicks] => 0
                                    [rainfall_last_15_min_in] => 0
                                    [rainfall_daily_clicks] => 0
                                    [dew_point] => 53.6
                                    [rainfall_last_15_min_mm] => 0
                                    [rain_rate_hi_in] => 0
                                    [rain_storm_clicks] => 0
                                    [rain_rate_hi_mm] => 0
                                    [rainfall_year_clicks] => 3009
                                    [rain_storm_in] => 0
                                    [rain_storm_last_end_at] => 1633352460
                                    [rain_storm_mm] => 0
                                    [wind_dir_scalar_avg_last_2_min] => 136
                                    [heat_index] => 61.8
                                    [rainfall_last_24_hr_in] => 0
                                    [rainfall_last_60_min_mm] => 0
                                    [trans_battery_flag] => 0
                                    [rainfall_last_60_min_in] => 0
                                    [rain_storm_start_time] =>
                                    [rainfall_last_24_hr_mm] => 0
                                    [rainfall_year_in] => 23.692913
                                    [wind_speed_hi_last_10_min] => 6.62
                                    [rainfall_last_15_min_clicks] => 0
                                    [rainfall_year_mm] => 601.8
                                    [wind_dir_scalar_avg_last_1_min] => 142
                                    [temp] => 62.4
                                    [wind_speed_avg_last_2_min] => 1.87
                                    [solar_rad] =>
                                    [rainfall_monthly_mm] => 26.8
                                    [rain_storm_last_mm] => 26.8
                                    [wind_speed_avg_last_1_min] => 2.25
                                    [thsw_index] =>
                                    [rainfall_monthly_in] => 1.0551181
                                    [rain_rate_last_mm] => 0
                                    [rain_rate_last_clicks] => 0
                                    [rainfall_last_24_hr_clicks] => 0
                                    [rain_storm_last_in] => 1.0551181
                                    [rain_rate_last_in] => 0
                                    [rain_rate_hi_last_15_min_mm] => 0
                                    [rain_rate_hi_last_15_min_in] => 0
                                    [ts] => 1633427112
                                )

                        )

                    [sensor_type] => 37
                    [data_structure_type] => 10
                )

            [2] => Array
                (
                    [lsid] => 301022
                    [data] => Array
                        (
                            [0] => Array
                                (
                                    [battery_voltage] => 6833
                                    [wifi_rssi] =>
                                    [network_error] =>
                                    [ip_v4_gateway] => 192.168.0.1
                                    [bluetooth_version] =>
                                    [bgn] =>
                                    [firmware_version] => 1596147041
                                    [local_api_queries] => 1698776
                                    [rx_bytes] => 395210974
                                    [health_version] => 1
                                    [radio_version] => 621020416
                                    [ip_address_type] => 1
                                    [link_uptime] => 3987211
                                    [input_voltage] => 4428
                                    [tx_bytes] => 1016616080
                                    [ip_v4_netmask] => 255.255.255.0
                                    [rapid_records_sent] => 2645798
                                    [uptime] => 10206964
                                    [touchpad_wakeups] => 73
                                    [ip_v4_address] => 192.168.0.128
                                    [bootloader_version] => 1550707628
                                    [espressif_version] => 1534381024
                                    [dns_type_used] =>
                                    [network_type] => 2
                                    [ts] => 1633427100
                                )

                        )

                    [sensor_type] => 504
                    [data_structure_type] => 15
                )

            [3] => Array
                (
                    [lsid] => 301023
                    [data] => Array
                        (
                            [0] => Array
                                (
                                    [bar_absolute] => 29.53
                                    [bar_sea_level] => 29.588
                                    [bar_offset] => -0.001
                                    [bar_trend] => -0.076
                                    [ts] => 1633427112
                                )

                        )

                    [sensor_type] => 242
                    [data_structure_type] => 12
                )

        )

    [generated_at] => 1633427845
    [station_id] => 87349
)



Offline Bashy

  • brecklandweather.com/meteo
  • Forecaster
  • *****
  • Posts: 1466
  • brecklandweather.com/index.php
    • Breckland Weather
Re: Weatherlink API v1 server error #12
« Reply #10 on: October 05, 2021, 06:12:39 AM »

Hi again, i add the to keys to your page and it finds the station, but when i add the ID at the bottom of that page to check it, I get a 404 error

Code: [Select]
Returncode =404
{"code":"404","message":"Unable to find weather station settings"}

I have no idea what you refer to with "add the ID"

This here on the page you created :)

Kind regards
Bashy

Online wvdkuil

  • Wim van der kuil
  • Forecaster
  • *****
  • Posts: 2009
    • My PWS at Leuven Belgium Europe
Re: Weatherlink API v1 server error #12
« Reply #11 on: October 05, 2021, 06:21:06 AM »

Hi again, i add the to keys to your page and it finds the station, but when i add the ID at the bottom of that page to check it, I get a 404 error

Code: [Select]
Returncode =404
{"code":"404","message":"Unable to find weather station settings"}

I have no idea what you refer to with "add the ID"

This here on the page you created :)


That is the station ID of the sensor, not the gateway-id you used.
Use copy paste. If that sensor is not operational, or a typo, it will not return data.
Code: [Select]
[station_id] => 78538
The links to the data are also displayed (in small print) , you can use them as a starting point to write your own code.

I tested a few minutes ago and with valid keys and station-id, the current data for that station/sensor is returned.

Succes,
wim
« Last Edit: October 05, 2021, 06:23:08 AM by wvdkuil »

Offline johnd

  • Forecaster
  • *****
  • Posts: 4970
    • www.weatherstations.co.uk
Re: Weatherlink API v1 server error #12
« Reply #12 on: October 05, 2021, 06:23:12 AM »
Hi John, like i just said to Wim,  i just read this morning that the v1 is realtime where as v2 is to the minute? and works with WLL (i think) hence looking at V1, i will have to try to find the reply to the post on here again, may take a while mind...

I really wouldn't get too distracted by what is real-time and what isn't. (To me, real-time is something like Davis LOOP data with new data every 2-3 seconds so that genuine wind gust data is available for example. But meaning can also vary with context.) Time resolution of the data is not a major difference between v1 and v2.

The wl.com v1 and v2 API's are totally distinct. v2 works for all type of upload devices to wl.com, new and old. v1 works only for legacy devices (WLIP and devices that emulate that like WFL, MPE, MB etc, Vantage Connect and uploads from Weatherlink for Windows.) But there are other major differences in the data returned by the two API's, eg much of the High/Low content of v1 is missing in v2 but additional stuff like the Health data is there.
Prodata Weather Systems
Prodata's FAQ/support site for Davis stations
Includes many details on 6313 Weatherlink console.
UK Davis Premier Dealer - All Davis stations, accessories and spares
Cambridge UK

Sorry, but I don't usually have time to help with individual issues by email unless you are a Prodata customer. Please post your issue in the relevant forum section here & I will comment there if I have anything useful to add.

Offline Bashy

  • brecklandweather.com/meteo
  • Forecaster
  • *****
  • Posts: 1466
  • brecklandweather.com/index.php
    • Breckland Weather
Re: Weatherlink API v1 server error #12
« Reply #13 on: October 05, 2021, 06:26:58 AM »
Hi Wim, i used copy and paste, double and triple checked, i can pm you my keys and ID if you like, to test it, but it deffo doesn't work for me :(
Kind regards
Bashy

Offline Bashy

  • brecklandweather.com/meteo
  • Forecaster
  • *****
  • Posts: 1466
  • brecklandweather.com/index.php
    • Breckland Weather
Re: Weatherlink API v1 server error #12
« Reply #14 on: October 05, 2021, 06:27:53 AM »
Hi John, like i just said to Wim,  i just read this morning that the v1 is realtime where as v2 is to the minute? and works with WLL (i think) hence looking at V1, i will have to try to find the reply to the post on here again, may take a while mind...

I really wouldn't get too distracted by what is real-time and what isn't. (To me, real-time is something like Davis LOOP data with new data every 2-3 seconds so that genuine wind gust data is available for example. But meaning can also vary with context.) Time resolution of the data is not a major difference between v1 and v2.

The wl.com v1 and v2 API's are totally distinct. v2 works for all type of upload devices to wl.com, new and old. v1 works only for legacy devices (WLIP and devices that emulate that like WFL, MPE, MB etc, Vantage Connect and uploads from Weatherlink for Windows.) But there are other major differences in the data returned by the two API's, eg much of the High/Low content of v1 is missing in v2 but additional stuff like the Health data is there.

Thanks John, its deffo the fast wind updating that suits me just fine :)
Kind regards
Bashy

Online wvdkuil

  • Wim van der kuil
  • Forecaster
  • *****
  • Posts: 2009
    • My PWS at Leuven Belgium Europe
Re: Weatherlink API v1 server error #12
« Reply #15 on: October 05, 2021, 06:46:51 AM »
Hi Wim, i used copy and paste, double and triple checked, i can pm you my keys and ID if you like, to test it, but it deffo doesn't work for me :(

Check your screenshot:
You copied the gateway-id-hex , the 4th line in the data.
The station-id is the first line, it seems to be 121670

Wim
« Last Edit: October 05, 2021, 06:50:28 AM by wvdkuil »

Offline mcrossley

  • Forecaster
  • *****
  • Posts: 1214
    • Wilmslow Astro
Re: Weatherlink API v1 server error #12
« Reply #16 on: October 05, 2021, 06:57:49 AM »
Quote from: Bashy
Thanks John, its deffo the fast wind updating that suits me just fine :)
If you want the 2.5 second updates, then you *must* use the WLL local API, not the wl .com API v1 or v2
Mark

Offline Bashy

  • brecklandweather.com/meteo
  • Forecaster
  • *****
  • Posts: 1466
  • brecklandweather.com/index.php
    • Breckland Weather
Re: Weatherlink API v1 server error #12
« Reply #17 on: October 05, 2021, 07:01:14 AM »
Hi Wim, i used copy and paste, double and triple checked, i can pm you my keys and ID if you like, to test it, but it deffo doesn't work for me :(

Check your screenshot:
You copied the gateway-id-hex , the 4th line in the data.
The station-id is the first line, it seems to be 121670

Wim


Apologies, I'd not seen station ID before and assumed you meant the DID
Kind regards
Bashy

Offline Bashy

  • brecklandweather.com/meteo
  • Forecaster
  • *****
  • Posts: 1466
  • brecklandweather.com/index.php
    • Breckland Weather
Re: Weatherlink API v1 server error #12
« Reply #18 on: October 05, 2021, 07:02:00 AM »

Ah OK, thank you
Quote from: Bashy
Thanks John, its deffo the fast wind updating that suits me just fine :)
If you want the 2.5 second updates, then you *must* use the WLL local API, not the wl .com API v1 or v2
Kind regards
Bashy

Offline misahar

  • Member
  • *
  • Posts: 1
Re: Weatherlink API v1 server error #12
« Reply #19 on: May 29, 2023, 06:57:53 AM »
This thread from two years ago, but I still wanna add a bit. It's frustrating when things don't work as expected, especially when you've double-checked your details and copied them accurately. While it's possible that the error could be related to your token, it's also worth considering other factors that may have caused the issue. Sometimes, small typos or formatting discrepancies can lead to unexpected errors.
To get closer to a resolution, I recommend reaching out to the support team for the Weatherlink API. They might have insights or suggestions to help you troubleshoot and resolve the error.
Additionally, if you're interested in testing the functionality and reliability of your API or other software, you might want to explore zaptest.com. It's a helpful resource for grey box testing, which can uncover potential issues and ensure a smooth user experience.
« Last Edit: June 02, 2023, 09:40:33 AM by misahar »

 

anything