From 8aa03a446d14f4c840b59d9fb335a541de1c823c Mon Sep 17 00:00:00 2001 From: Brian Mirletz Date: Fri, 27 Mar 2026 10:16:42 -0600 Subject: [PATCH] First batch of nlr.gov api changes --- deploy/runtime/webapis.conf | 32 ++++++++++++++++---------------- src/casewin.cpp | 2 +- src/codegenerator.cpp | 16 ++++++++-------- src/main_add.h | 2 +- src/nsrdb.cpp | 20 ++++++++++---------- src/private.h | 2 +- src/s3tool.cpp | 2 +- src/urdb.cpp | 2 +- src/welcome.cpp | 2 +- 9 files changed, 40 insertions(+), 40 deletions(-) diff --git a/deploy/runtime/webapis.conf b/deploy/runtime/webapis.conf index 64eff9a50c..6d611a85ae 100644 --- a/deploy/runtime/webapis.conf +++ b/deploy/runtime/webapis.conf @@ -1,26 +1,26 @@ ' This Web API configuration file is a list of URLs SAM uses for NREL API web services. ' Modifying this file may cause SAM's download features to stop working. -forum=https://sam.nrel.gov/support -android_build=https://sam.nrel.gov/sites/default/files/content/mobile/android/readme.html -cambium=https://scenarioviewer.nrel.gov/api/project/detail/?uuid=0f92fe57-3365-428a-8fe8-0afc326b3b43 +forum=https://sam.nlr.gov/support +android_build=https://sam.nlr.gov/sites/default/files/content/mobile/android/readme.html +cambium=https://scenarioviewer.nlr.gov/api/project/detail/?uuid=0f92fe57-3365-428a-8fe8-0afc326b3b43 google_geocode_api=https://maps.googleapis.com/maps/api/geocode/json?&sensor=false&key= google_timezone_api=https://maps.googleapis.com/maps/api/timezone/json?timestamp=1&sensor=false&key= google_staticmap_api=https://maps.googleapis.com/maps/api/staticmap?
&zoom=&size=800x800&maptype=hybrid&sensor=false&format=jpg-baseline&key= -ios_build=https://sam.nrel.gov/sites/default/files/content/mobile/ios/readme.html -nsrdb_query=https://developer.nrel.gov/api/nsrdb/v2/solar/nsrdb-data-query.json?&api_key=&wkt=POINT(%20) -release_notes=https://nrel.github.io/SAM/doc/releasenotes.html -reopt_poll=https://developer.nrel.gov/api/reopt/stable/job//results/?api_key= -reopt_post=https://developer.nrel.gov/api/reopt/stable/job?format=json&api_key= -support_email=mailto:sam.support@nrel.gov +ios_build=https://sam.nlr.gov/sites/default/files/content/mobile/ios/readme.html +nsrdb_query=https://developer.nlr.gov/api/nsrdb/v2/solar/nsrdb-data-query.json?&api_key=&wkt=POINT(%20) +release_notes=https://natlabrockies.github.io/SAM/doc/releasenotes.html +reopt_poll=https://developer.nlr.gov/api/reopt/stable/job//results/?api_key= +reopt_post=https://developer.nlr.gov/api/reopt/stable/job?format=json&api_key= +support_email=mailto:sam.support@nlr.gov urdb_ask=https://en.openei.org/w/index.php?title=Special:Ask&q=&po=&eq=yes&p[format]=json urdb_companies_all=https://api.openei.org/utility_companies?version=3&format=json&api_key=&scope= -urdb_companies_by_lat_lon=https://developer.nrel.gov/api/utility_rates/v3.json?api_key=&lat=&lon= +urdb_companies_by_lat_lon=https://developer.nlr.gov/api/utility_rates/v3.json?api_key=&lat=&lon= urdb_rates=https://api.openei.org/utility_rates?version=8&format=json&limit=&detail=&offset=&ratesforutility=&getpage=&api_key= urdb_view_rate=https://apps.openei.org/IURDB -wave_query_west=https://developer.nrel.gov/api/wave/v2/wave/us-west-coast-hindcast-download.csv?api_key=&wkt=POINT(%20)&interval=180&email=&attributes=significant_wave_height,energy_period&names= -wave_query_atlantic=https://developer.nrel.gov/api/wave/v2/wave/us-atlantic-hindcast-download.csv?api_key=&wkt=POINT(%20)&interval=180&email=&attributes=significant_wave_height,energy_period&names= -wave_query_hawaii=https://developer.nrel.gov/api/wave/v2/wave/hawaii-hindcast-download.csv?api_key=&wkt=POINT(%20)&interval=180&email=&attributes=significant_wave_height,energy_period&names= -wave_query_alaska=https://developer.nrel.gov/api/wave/v2/wave/alaska-hindcast-download.csv?api_key=&wkt=POINT(%20)&interval=180&email=&attributes=significant_wave_height,energy_period&names= -website=https://sam.nrel.gov -windtoolkit=https://developer.nrel.gov/api/wind-toolkit/v2/wind/wtk-download.csv?&api_key=&email=&full_name=SAM%20User&affiliation=none&reason=none&wkt=POINT(%20)&utc=false&leap_day=false&names=&interval=&attributes= +wave_query_west=https://developer.nlr.gov/api/wave/v2/wave/us-west-coast-hindcast-download.csv?api_key=&wkt=POINT(%20)&interval=180&email=&attributes=significant_wave_height,energy_period&names= +wave_query_atlantic=https://developer.nlr.gov/api/wave/v2/wave/us-atlantic-hindcast-download.csv?api_key=&wkt=POINT(%20)&interval=180&email=&attributes=significant_wave_height,energy_period&names= +wave_query_hawaii=https://developer.nlr.gov/api/wave/v2/wave/hawaii-hindcast-download.csv?api_key=&wkt=POINT(%20)&interval=180&email=&attributes=significant_wave_height,energy_period&names= +wave_query_alaska=https://developer.nlr.gov/api/wave/v2/wave/alaska-hindcast-download.csv?api_key=&wkt=POINT(%20)&interval=180&email=&attributes=significant_wave_height,energy_period&names= +website=https://sam.nlr.gov +windtoolkit=https://developer.nlr.gov/api/wind-toolkit/v2/wind/wtk-download.csv?&api_key=&email=&full_name=SAM%20User&affiliation=none&reason=none&wkt=POINT(%20)&utc=false&leap_day=false&names=&interval=&attributes= diff --git a/src/casewin.cpp b/src/casewin.cpp index 7ec9f91eb6..ab094882fc 100644 --- a/src/casewin.cpp +++ b/src/casewin.cpp @@ -569,7 +569,7 @@ bool CaseWindow::GenerateReport( wxString pdffile, wxString templfile, VarValue if (validfiles.Count() == 0) { - wxMessageBox( "SAM could not find any templates valid for the current technology and financing combination.\n\nPlease contact SAM user support at sam.support@nrel.gov for more information." ); + wxMessageBox( "SAM could not find any templates valid for the current technology and financing combination.\n\nPlease contact SAM user support at sam.support@nlr.gov for more information." ); return false; } diff --git a/src/codegenerator.cpp b/src/codegenerator.cpp index 91da71d568..8df518a789 100644 --- a/src/codegenerator.cpp +++ b/src/codegenerator.cpp @@ -1397,7 +1397,7 @@ bool CodeGen_c::SupportingFiles() fprintf(f, "clean :\n"); fprintf(f, " $(RM) $(PROJ_NAME)$(EXT)\n"); fprintf(f, "help:\n"); - fprintf(f, " @echo \"Please check the settings for your system.Your system may not be supported.Please contact sam.support@nrel.gov\"\n"); + fprintf(f, " @echo \"Please check the settings for your system.Your system may not be supported.Please contact sam.support@nlr.gov\"\n"); fclose(f); return true; @@ -4732,7 +4732,7 @@ bool CodeGen_java::SupportingFiles() fprintf(f, "clean :\n"); fprintf(f, " $(RM) $(RM_ALL) $(RM_JAVA)\n"); fprintf(f, "help:\n"); - fprintf(f, " @echo \"Please check the settings for your system.Your system may not be supported.Please contact sam.support@nrel.gov.System: $(PF) $(VERS)\"\n"); + fprintf(f, " @echo \"Please check the settings for your system.Your system may not be supported.Please contact sam.support@nlr.gov.System: $(PF) $(VERS)\"\n"); fclose(f); // Manifest file to define main class fn = m_folder + "/" + m_name + ".Manifest.txt"; @@ -5649,7 +5649,7 @@ bool CodeGen_php5::SupportingFiles() fprintf(f, " rm sscphp.dylib\n"); fprintf(f, "\n"); fprintf(f, "help:\n"); - fprintf(f, " @echo \"Please check the settings for your system.Your system may not be supported.Please contact sam.support@nrel.gov.System: $(PF) $(VERS)\"\n"); + fprintf(f, " @echo \"Please check the settings for your system.Your system may not be supported.Please contact sam.support@nlr.gov.System: $(PF) $(VERS)\"\n"); fclose(f); return true; #elif defined(__WXGTK__) @@ -5681,7 +5681,7 @@ bool CodeGen_php5::SupportingFiles() fprintf(f, " rm sscphp.so\n"); fprintf(f, "\n"); fprintf(f, "help:\n"); - fprintf(f, " @echo \"Please check the settings for your system.Your system may not be supported.Please contact sam.support@nrel.gov.System: $(PF) $(VERS)\"\n"); + fprintf(f, " @echo \"Please check the settings for your system.Your system may not be supported.Please contact sam.support@nlr.gov.System: $(PF) $(VERS)\"\n"); fclose(f); return true; #else @@ -6313,7 +6313,7 @@ bool CodeGen_php7::SupportingFiles() fprintf(f, " rm sscphp.so\n"); fprintf(f, "\n"); fprintf(f, "help:\n"); - fprintf(f, " @echo \"Please check the settings for your system.Your system may not be supported.Please contact sam.support@nrel.gov.System: $(PF) $(VERS)\"\n"); + fprintf(f, " @echo \"Please check the settings for your system.Your system may not be supported.Please contact sam.support@nlr.gov.System: $(PF) $(VERS)\"\n"); fclose(f); return true; #else @@ -6946,7 +6946,7 @@ bool CodeGen_php8::SupportingFiles() fprintf(f, " rm sscphp.so\n"); fprintf(f, "\n"); fprintf(f, "help:\n"); - fprintf(f, " @echo \"Please check the settings for your system.Your system may not be supported.Please contact sam.support@nrel.gov.System: $(PF) $(VERS)\"\n"); + fprintf(f, " @echo \"Please check the settings for your system.Your system may not be supported.Please contact sam.support@nlr.gov.System: $(PF) $(VERS)\"\n"); fclose(f); return true; #else @@ -7822,7 +7822,7 @@ bool CodeGen_ios::SupportingFiles() { // for iOS wxString url = SamApp::WebApi("ios_build"); - if (url.IsEmpty()) url = "https://sam.nrel.gov"; + if (url.IsEmpty()) url = "https://sam.nlr.gov"; wxLaunchDefaultBrowser( url ); #if defined(__WXMSW__) @@ -8290,7 +8290,7 @@ bool CodeGen_android::SupportingFiles() fclose(f); // library files - in readme wxString url = SamApp::WebApi("android_build"); - if (url.IsEmpty()) url = "https://sam.nrel.gov/"; + if (url.IsEmpty()) url = "https://sam.nlr.gov/"; wxLaunchDefaultBrowser( url ); #if defined(__WXMSW__) diff --git a/src/main_add.h b/src/main_add.h index 6703772eed..4478b110c8 100644 --- a/src/main_add.h +++ b/src/main_add.h @@ -308,7 +308,7 @@ bool SamApp::OnInit() /*wxMSWSetupExceptionHandler( wxString("SAM"), SamApp::VersionStr(), - wxString("sam.support@nrel.gov") ); + wxString("sam.support@nlr.gov") ); */ #endif diff --git a/src/nsrdb.cpp b/src/nsrdb.cpp index 88eb543581..d3ce0331fd 100644 --- a/src/nsrdb.cpp +++ b/src/nsrdb.cpp @@ -583,7 +583,7 @@ void NSRDBDialog::GetResources() } // NSRDB Data Query returns a list of links to all available files for a location - // https://developer.nrel.gov/docs/solar/nsrdb/nsrdb_data_query/ + // https://developer.nlr.gov/docs/solar/nsrdb/nsrdb_data_query/ wxString url; url = SamApp::WebApi("nsrdb_query"); url.Replace("", wxString::Format("%lg", lat), 1); @@ -684,15 +684,15 @@ void NSRDBDialog::GetResources() /* datasets have different available intervals in addition to 60 (all datasets have 60 minute data): - psm3 https://developer.nrel.gov/docs/solar/nsrdb/psm3-download/ 30 - psm3-2-2 https://developer.nrel.gov/docs/solar/nsrdb/psm3-2-2-download/ 30 - nsrdb-GOES-aggregated-v4-0-0 https://developer.nrel.gov/api/nsrdb/v2/solar/nsrdb-GOES-aggregated-v4-0-0-download 30 - psm3-5min https://developer.nrel.gov/docs/solar/nsrdb/psm3-5min-download/ 5,15,30 - suny-india https://developer.nrel.gov/docs/solar/nsrdb/suny-india-data-download/ 15,30 - msg-iodc https://developer.nrel.gov/docs/solar/nsrdb/meteosat-download/ 15,30 - msg-v1-0-0 https://developer.nrel.gov/docs/solar/nsrdb/nsrdb-msg-v1-0-0-download/ 15,30 - himawari https://developer.nrel.gov/docs/solar/nsrdb/himawari-download/ 10,30 - himawari7 https://developer.nrel.gov/docs/solar/nsrdb/himawari7-download/ 30 + psm3 https://developer.nlr.gov/docs/solar/nsrdb/psm3-download/ 30 + psm3-2-2 https://developer.nlr.gov/docs/solar/nsrdb/psm3-2-2-download/ 30 + nsrdb-GOES-aggregated-v4-0-0 https://developer.nlr.gov/api/nsrdb/v2/solar/nsrdb-GOES-aggregated-v4-0-0-download 30 + psm3-5min https://developer.nlr.gov/docs/solar/nsrdb/psm3-5min-download/ 5,15,30 + suny-india https://developer.nlr.gov/docs/solar/nsrdb/suny-india-data-download/ 15,30 + msg-iodc https://developer.nlr.gov/docs/solar/nsrdb/meteosat-download/ 15,30 + msg-v1-0-0 https://developer.nlr.gov/docs/solar/nsrdb/nsrdb-msg-v1-0-0-download/ 15,30 + himawari https://developer.nlr.gov/docs/solar/nsrdb/himawari-download/ 10,30 + himawari7 https://developer.nlr.gov/docs/solar/nsrdb/himawari7-download/ 30 */ #ifdef __DEBUG__ diff --git a/src/private.h b/src/private.h index 920eeefc09..a74e70bf26 100644 --- a/src/private.h +++ b/src/private.h @@ -37,7 +37,7 @@ static const char *version_label = 0; //"iscc-ge"; // NREL Developer API: // For calls to NREL Developer APIs for weather file downloads, REopt calls, etc. -// Get an API key at https://developer.nrel.gov +// Get an API key at https://developer.nlr.gov const char *sam_api_key = ""; // Email address used to register for NREL Developer API diff --git a/src/s3tool.cpp b/src/s3tool.cpp index 685219da64..76ce9b2118 100644 --- a/src/s3tool.cpp +++ b/src/s3tool.cpp @@ -2411,7 +2411,7 @@ void ShadeTool::OnCommand( wxCommandEvent &evt) case ID_VIEW_XY: m_book->SetSelection( PG_SCENE ); m_view->SetMode( m_view->TOP_VIEW ); break; case ID_VIEW_XZ: m_book->SetSelection( PG_SCENE ); m_view->SetMode( m_view->Z_VIEW ); break; case ID_FEEDBACK: - wxLaunchDefaultBrowser( "mailto://sam.support@nrel.gov?subject=Shade Calculator - Beta Feedback" ); + wxLaunchDefaultBrowser( "mailto://sam.support@nlr.gov?subject=Shade Calculator - Beta Feedback" ); break; case wxID_HELP: #ifdef S3D_STANDALONE diff --git a/src/urdb.cpp b/src/urdb.cpp index b686612185..7ebc6c6ab8 100644 --- a/src/urdb.cpp +++ b/src/urdb.cpp @@ -289,7 +289,7 @@ bool OpenEI::QueryUtilityCompaniesbyZipcode(const wxString &zipcode, wxArrayStri return false; } - // NREL Developer API to list utility companies by lat/lon https://developer.nrel.gov/docs/electricity/utility-rates-v3/ + // NREL Developer API to list utility companies by lat/lon https://developer.nlr.gov/docs/electricity/utility-rates-v3/ wxString url = SamApp::WebApi("urdb_companies_by_lat_lon"); url.Replace("", wxString::Format("%f",lat)); url.Replace("", wxString::Format("%f",lon)); diff --git a/src/welcome.cpp b/src/welcome.cpp index a267d3ad7f..9ab9f63087 100644 --- a/src/welcome.cpp +++ b/src/welcome.cpp @@ -225,7 +225,7 @@ void WelcomeScreen::RunWelcomeScript( const wxString &script ) env.register_funcs( lk::stdlib_basic() ); // note: do not register SYSIO functions to improve security when running - // LK code downloaded directly from sam.nrel.gov in the welcome window + // LK code downloaded directly from sam.nlr.gov in the welcome window env.register_funcs( lk::stdlib_string() ); env.register_funcs( lk::stdlib_math() );