You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 3 Current »

API import to import meteo/hydro data from https://hydrology.gov.np/gss/api/socket/nve_snow/response, Nepal.


The response gives station data from all (only 8) stations, for the last 3 days. It is not possible to filter on stations and/or dates. For now the solution would therefore be: download all data, and select the data from the response that needs to be imported (based on given station, variable dates/times) .  The API key is for testing and should be configured in the FEWS xml configuration.


<?xml version="1.0" encoding="UTF-8"?>
<!-- edited with XMLSpy v2006 rel. 3 sp1 (http://www.altova.com) by Computer Services (WL | Delft Hydraulics) -->
<timeSeriesImportRun xmlns="http://www.wldelft.nl/fews" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
                 xsi:schemaLocation="http://www.wldelft.nl/fews http://fews.wldelft.nl/schemas/version1.0/timeSeriesImportRun.xsd">
    <import>
       <general>
          <importType>DHM</importType>
          <serverUrl>https://hydrology.gov.np/gss/api/socket/nve_snow/response</serverUrl>
          <user>user</user>
          <password>api-key</password>
          <relativeViewPeriod unit="day" start="-5" end="0" startOverrulable="true" endOverrulable="true"/>
          <idMapId>DHMIdMap</idMapId>
       </general>    
       <timeSeriesSet>
          <moduleInstanceId>DHM</moduleInstanceId>
          <valueType>scalar</valueType>
          <parameterId>parameter</parameterId>
          <locationId>LocA</locationId>
          <timeSeriesType>external historical</timeSeriesType>
          <timeStep unit="nonequidistant"/>
          <readWriteMode>add originals</readWriteMode>
       </timeSeriesSet>      
       </timeSeriesSet>
    </import>


Available parameter Ids are:


parameter_code

parameter description

PCPN_1HAccumulated Precipitation for last 1 h
PCPN_1DAccumulated Precipitation for last 24 h
T_1HAir Temperature 1 Hour Average
TX_1HAir Temperature 1 Hour Maximum
TN_1HAir Temperature 1 Hour Minimum
ALB_1HAlbedo 1 h avg
TD_1HDew Point Temperature 1 hour Average
DLR_1HDownwelling LWR 1 h avg
DSR_1HDownwelling SWR 1 h avg
QFE_I_10MPressure Inst
RH_I_1HRelative Humidity 1 h Inst
SND_1HSnow Depth 1 Hour average
ST_00_10MSoil Temperature at 0 cm, 10 min average
ULR_1HUpwelling LWR 1 h avg
WL_I_10MWater Level Inst

And locations (use the ID field for the ID mapping):
IDNameLatitudeLongitudeElevationDescription
5512GanjaLa_Snow28.154585.56254962Langtang - GanjaLa
5514Langtang - Lower28.19214285.5704314200Langtang - Lower
5556Kyangjing_Snow28.210977685.56716793850AWS station at Kyangjing
190Langtang Khola at Shyaprubesi28.1622222285.346111111484Hydrological Station with RLS
5581Langtang Khola at Ghodatalbela28.19927585.458083022HS at Kyangjin
4824Langtang Khola at Syaprubesi (Velocity)28.16222285.345988
Discharge Measurement Station
5511Mustang - Lower snow station28.75591583.6491744272Mustang - Lower snow station
5510Mustang - Upper Snow Station28.77733583.6005415050Mustang - Upper Snow Station
5595Rikha Samba AWS


Rikha Samba AWS
  • No labels