@googleapis/solar 1.0.1 → 2.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,30 @@
1
1
  # Changelog
2
2
 
3
+ ## [2.0.1](https://github.com/googleapis/google-api-nodejs-client/compare/solar-v2.0.0...solar-v2.0.1) (2025-07-08)
4
+
5
+
6
+ ### Bug Fixes
7
+
8
+ * **solar:** update the API ([2e3e0b9](https://github.com/googleapis/google-api-nodejs-client/commit/2e3e0b98179042e889bb842039ebdb4448b0ae22))
9
+ * **solar:** update the API ([6a93f68](https://github.com/googleapis/google-api-nodejs-client/commit/6a93f682ff13cfec9e105ed00011d851116063ea))
10
+
11
+ ## [2.0.0](https://github.com/googleapis/google-api-nodejs-client/compare/solar-v1.0.1...solar-v2.0.0) (2025-06-30)
12
+
13
+
14
+ ### ⚠ BREAKING CHANGES
15
+
16
+ * upgrade to node 18
17
+
18
+ ### Features
19
+
20
+ * upgrade to node 18 ([682fbb8](https://github.com/googleapis/google-api-nodejs-client/commit/682fbb869189ae92b3e9a194d37d0548af0c1f92))
21
+
22
+
23
+ ### Bug Fixes
24
+
25
+ * **deps:** upgrade googleapis-common to 8.0.2-rc ([f4b0990](https://github.com/googleapis/google-api-nodejs-client/commit/f4b099071040cfbcfe4a2e7d487d45ee93b369e0))
26
+ * **solar:** update the API ([6a93f68](https://github.com/googleapis/google-api-nodejs-client/commit/6a93f682ff13cfec9e105ed00011d851116063ea))
27
+
3
28
  ## [1.0.1](https://github.com/googleapis/google-api-nodejs-client/compare/solar-v1.0.0...solar-v1.0.1) (2025-06-04)
4
29
 
5
30
 
package/README.md CHANGED
@@ -4,6 +4,15 @@
4
4
 
5
5
  > Solar API.
6
6
 
7
+ ## Support status
8
+ **Note**: Google provides multiple libraries for this service. This library is in
9
+ maintenance mode, and will continue to be made available for users who have
10
+ existing applications. If you're building a new application, or modernizing a
11
+ legacy application, please use [@googlemaps/solar](https://www.npmjs.com/package/@googlemaps/solar) instead.
12
+ The [@googlemaps/solar](https://www.npmjs.com/package/@googlemaps/solar) library is faster, easier to use, and better maintained.
13
+
14
+ To learn more, see [Client Libraries Explained](https://cloud.google.com/apis/docs/client-libraries-explained).
15
+
7
16
  ## Installation
8
17
 
9
18
  ```sh
package/build/v1.d.ts CHANGED
@@ -595,6 +595,68 @@ export declare namespace solar_v1 {
595
595
  constructor(context: APIRequestContext);
596
596
  /**
597
597
  * Locates the building whose centroid is closest to a query point. Returns an error with code `NOT_FOUND` if there are no buildings within approximately 50m of the query point.
598
+ * @example
599
+ * ```js
600
+ * // Before running the sample:
601
+ * // - Enable the API at:
602
+ * // https://console.developers.google.com/apis/api/solar.googleapis.com
603
+ * // - Login into gcloud by running:
604
+ * // ```sh
605
+ * // $ gcloud auth application-default login
606
+ * // ```
607
+ * // - Install the npm module by running:
608
+ * // ```sh
609
+ * // $ npm install googleapis
610
+ * // ```
611
+ *
612
+ * const {google} = require('googleapis');
613
+ * const solar = google.solar('v1');
614
+ *
615
+ * async function main() {
616
+ * const auth = new google.auth.GoogleAuth({
617
+ * // Scopes can be specified either as an array or as a single, space-delimited string.
618
+ * scopes: ['https://www.googleapis.com/auth/cloud-platform'],
619
+ * });
620
+ *
621
+ * // Acquire an auth client, and bind it to all future calls
622
+ * const authClient = await auth.getClient();
623
+ * google.options({auth: authClient});
624
+ *
625
+ * // Do the magic
626
+ * const res = await solar.buildingInsights.findClosest({
627
+ * // Optional. Specifies the pre-GA features to enable.
628
+ * experiments: 'placeholder-value',
629
+ * // The latitude in degrees. It must be in the range [-90.0, +90.0].
630
+ * 'location.latitude': 'placeholder-value',
631
+ * // The longitude in degrees. It must be in the range [-180.0, +180.0].
632
+ * 'location.longitude': 'placeholder-value',
633
+ * // Optional. The minimum quality level allowed in the results. No result with lower quality than this will be returned. Not specifying this is equivalent to restricting to HIGH quality only.
634
+ * requiredQuality: 'placeholder-value',
635
+ * });
636
+ * console.log(res.data);
637
+ *
638
+ * // Example response
639
+ * // {
640
+ * // "administrativeArea": "my_administrativeArea",
641
+ * // "boundingBox": {},
642
+ * // "center": {},
643
+ * // "imageryDate": {},
644
+ * // "imageryProcessedDate": {},
645
+ * // "imageryQuality": "my_imageryQuality",
646
+ * // "name": "my_name",
647
+ * // "postalCode": "my_postalCode",
648
+ * // "regionCode": "my_regionCode",
649
+ * // "solarPotential": {},
650
+ * // "statisticalArea": "my_statisticalArea"
651
+ * // }
652
+ * }
653
+ *
654
+ * main().catch(e => {
655
+ * console.error(e);
656
+ * throw e;
657
+ * });
658
+ *
659
+ * ```
598
660
  *
599
661
  * @param params - Parameters for request
600
662
  * @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
@@ -631,6 +693,74 @@ export declare namespace solar_v1 {
631
693
  constructor(context: APIRequestContext);
632
694
  /**
633
695
  * Gets solar information for a region surrounding a location. Returns an error with code `NOT_FOUND` if the location is outside the coverage area.
696
+ * @example
697
+ * ```js
698
+ * // Before running the sample:
699
+ * // - Enable the API at:
700
+ * // https://console.developers.google.com/apis/api/solar.googleapis.com
701
+ * // - Login into gcloud by running:
702
+ * // ```sh
703
+ * // $ gcloud auth application-default login
704
+ * // ```
705
+ * // - Install the npm module by running:
706
+ * // ```sh
707
+ * // $ npm install googleapis
708
+ * // ```
709
+ *
710
+ * const {google} = require('googleapis');
711
+ * const solar = google.solar('v1');
712
+ *
713
+ * async function main() {
714
+ * const auth = new google.auth.GoogleAuth({
715
+ * // Scopes can be specified either as an array or as a single, space-delimited string.
716
+ * scopes: ['https://www.googleapis.com/auth/cloud-platform'],
717
+ * });
718
+ *
719
+ * // Acquire an auth client, and bind it to all future calls
720
+ * const authClient = await auth.getClient();
721
+ * google.options({auth: authClient});
722
+ *
723
+ * // Do the magic
724
+ * const res = await solar.dataLayers.get({
725
+ * // Optional. Whether to require exact quality of the imagery. If set to false, the `required_quality` field is interpreted as the minimum required quality, such that HIGH quality imagery may be returned when `required_quality` is set to MEDIUM. If set to true, `required_quality` is interpreted as the exact required quality and only `MEDIUM` quality imagery is returned if `required_quality` is set to `MEDIUM`.
726
+ * exactQualityRequired: 'placeholder-value',
727
+ * // Optional. Specifies the pre-GA experiments to enable.
728
+ * experiments: 'placeholder-value',
729
+ * // The latitude in degrees. It must be in the range [-90.0, +90.0].
730
+ * 'location.latitude': 'placeholder-value',
731
+ * // The longitude in degrees. It must be in the range [-180.0, +180.0].
732
+ * 'location.longitude': 'placeholder-value',
733
+ * // Optional. The minimum scale, in meters per pixel, of the data to return. Values of 0.1 (the default, if this field is not set explicitly), 0.25, 0.5, and 1.0 are supported. Imagery components whose normal resolution is less than `pixel_size_meters` will be returned at the resolution specified by `pixel_size_meters`; imagery components whose normal resolution is equal to or greater than `pixel_size_meters` will be returned at that normal resolution.
734
+ * pixelSizeMeters: 'placeholder-value',
735
+ * // Required. The radius, in meters, defining the region surrounding that centre point for which data should be returned. The limitations on this value are: * Any value up to 100m can always be specified. * Values over 100m can be specified, as long as `radius_meters` <= `pixel_size_meters * 1000`. * However, for values over 175m, the `DataLayerView` in the request must not include monthly flux or hourly shade.
736
+ * radiusMeters: 'placeholder-value',
737
+ * // Optional. The minimum quality level allowed in the results. No result with lower quality than this will be returned. Not specifying this is equivalent to restricting to HIGH quality only.
738
+ * requiredQuality: 'placeholder-value',
739
+ * // Optional. The desired subset of the data to return.
740
+ * view: 'placeholder-value',
741
+ * });
742
+ * console.log(res.data);
743
+ *
744
+ * // Example response
745
+ * // {
746
+ * // "annualFluxUrl": "my_annualFluxUrl",
747
+ * // "dsmUrl": "my_dsmUrl",
748
+ * // "hourlyShadeUrls": [],
749
+ * // "imageryDate": {},
750
+ * // "imageryProcessedDate": {},
751
+ * // "imageryQuality": "my_imageryQuality",
752
+ * // "maskUrl": "my_maskUrl",
753
+ * // "monthlyFluxUrl": "my_monthlyFluxUrl",
754
+ * // "rgbUrl": "my_rgbUrl"
755
+ * // }
756
+ * }
757
+ *
758
+ * main().catch(e => {
759
+ * console.error(e);
760
+ * throw e;
761
+ * });
762
+ *
763
+ * ```
634
764
  *
635
765
  * @param params - Parameters for request
636
766
  * @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
@@ -683,6 +813,54 @@ export declare namespace solar_v1 {
683
813
  constructor(context: APIRequestContext);
684
814
  /**
685
815
  * Returns an image by its ID.
816
+ * @example
817
+ * ```js
818
+ * // Before running the sample:
819
+ * // - Enable the API at:
820
+ * // https://console.developers.google.com/apis/api/solar.googleapis.com
821
+ * // - Login into gcloud by running:
822
+ * // ```sh
823
+ * // $ gcloud auth application-default login
824
+ * // ```
825
+ * // - Install the npm module by running:
826
+ * // ```sh
827
+ * // $ npm install googleapis
828
+ * // ```
829
+ *
830
+ * const {google} = require('googleapis');
831
+ * const solar = google.solar('v1');
832
+ *
833
+ * async function main() {
834
+ * const auth = new google.auth.GoogleAuth({
835
+ * // Scopes can be specified either as an array or as a single, space-delimited string.
836
+ * scopes: ['https://www.googleapis.com/auth/cloud-platform'],
837
+ * });
838
+ *
839
+ * // Acquire an auth client, and bind it to all future calls
840
+ * const authClient = await auth.getClient();
841
+ * google.options({auth: authClient});
842
+ *
843
+ * // Do the magic
844
+ * const res = await solar.geoTiff.get({
845
+ * // Required. The ID of the asset being requested.
846
+ * id: 'placeholder-value',
847
+ * });
848
+ * console.log(res.data);
849
+ *
850
+ * // Example response
851
+ * // {
852
+ * // "contentType": "my_contentType",
853
+ * // "data": "my_data",
854
+ * // "extensions": []
855
+ * // }
856
+ * }
857
+ *
858
+ * main().catch(e => {
859
+ * console.error(e);
860
+ * throw e;
861
+ * });
862
+ *
863
+ * ```
686
864
  *
687
865
  * @param params - Parameters for request
688
866
  * @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
package/build/v1.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"v1.js","sourceRoot":"","sources":["../v1.ts"],"names":[],"mappings":";AAAA,4BAA4B;AAC5B,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,gDAAgD;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": "1.0.1",
3
+ "version": "2.0.1",
4
4
  "description": "solar",
5
5
  "main": "build/index.js",
6
6
  "types": "build/index.d.ts",
package/v1.ts CHANGED
@@ -652,6 +652,68 @@ export namespace solar_v1 {
652
652
 
653
653
  /**
654
654
  * Locates the building whose centroid is closest to a query point. Returns an error with code `NOT_FOUND` if there are no buildings within approximately 50m of the query point.
655
+ * @example
656
+ * ```js
657
+ * // Before running the sample:
658
+ * // - Enable the API at:
659
+ * // https://console.developers.google.com/apis/api/solar.googleapis.com
660
+ * // - Login into gcloud by running:
661
+ * // ```sh
662
+ * // $ gcloud auth application-default login
663
+ * // ```
664
+ * // - Install the npm module by running:
665
+ * // ```sh
666
+ * // $ npm install googleapis
667
+ * // ```
668
+ *
669
+ * const {google} = require('googleapis');
670
+ * const solar = google.solar('v1');
671
+ *
672
+ * async function main() {
673
+ * const auth = new google.auth.GoogleAuth({
674
+ * // Scopes can be specified either as an array or as a single, space-delimited string.
675
+ * scopes: ['https://www.googleapis.com/auth/cloud-platform'],
676
+ * });
677
+ *
678
+ * // Acquire an auth client, and bind it to all future calls
679
+ * const authClient = await auth.getClient();
680
+ * google.options({auth: authClient});
681
+ *
682
+ * // Do the magic
683
+ * const res = await solar.buildingInsights.findClosest({
684
+ * // Optional. Specifies the pre-GA features to enable.
685
+ * experiments: 'placeholder-value',
686
+ * // The latitude in degrees. It must be in the range [-90.0, +90.0].
687
+ * 'location.latitude': 'placeholder-value',
688
+ * // The longitude in degrees. It must be in the range [-180.0, +180.0].
689
+ * 'location.longitude': 'placeholder-value',
690
+ * // Optional. The minimum quality level allowed in the results. No result with lower quality than this will be returned. Not specifying this is equivalent to restricting to HIGH quality only.
691
+ * requiredQuality: 'placeholder-value',
692
+ * });
693
+ * console.log(res.data);
694
+ *
695
+ * // Example response
696
+ * // {
697
+ * // "administrativeArea": "my_administrativeArea",
698
+ * // "boundingBox": {},
699
+ * // "center": {},
700
+ * // "imageryDate": {},
701
+ * // "imageryProcessedDate": {},
702
+ * // "imageryQuality": "my_imageryQuality",
703
+ * // "name": "my_name",
704
+ * // "postalCode": "my_postalCode",
705
+ * // "regionCode": "my_regionCode",
706
+ * // "solarPotential": {},
707
+ * // "statisticalArea": "my_statisticalArea"
708
+ * // }
709
+ * }
710
+ *
711
+ * main().catch(e => {
712
+ * console.error(e);
713
+ * throw e;
714
+ * });
715
+ *
716
+ * ```
655
717
  *
656
718
  * @param params - Parameters for request
657
719
  * @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
@@ -770,6 +832,74 @@ export namespace solar_v1 {
770
832
 
771
833
  /**
772
834
  * Gets solar information for a region surrounding a location. Returns an error with code `NOT_FOUND` if the location is outside the coverage area.
835
+ * @example
836
+ * ```js
837
+ * // Before running the sample:
838
+ * // - Enable the API at:
839
+ * // https://console.developers.google.com/apis/api/solar.googleapis.com
840
+ * // - Login into gcloud by running:
841
+ * // ```sh
842
+ * // $ gcloud auth application-default login
843
+ * // ```
844
+ * // - Install the npm module by running:
845
+ * // ```sh
846
+ * // $ npm install googleapis
847
+ * // ```
848
+ *
849
+ * const {google} = require('googleapis');
850
+ * const solar = google.solar('v1');
851
+ *
852
+ * async function main() {
853
+ * const auth = new google.auth.GoogleAuth({
854
+ * // Scopes can be specified either as an array or as a single, space-delimited string.
855
+ * scopes: ['https://www.googleapis.com/auth/cloud-platform'],
856
+ * });
857
+ *
858
+ * // Acquire an auth client, and bind it to all future calls
859
+ * const authClient = await auth.getClient();
860
+ * google.options({auth: authClient});
861
+ *
862
+ * // Do the magic
863
+ * const res = await solar.dataLayers.get({
864
+ * // Optional. Whether to require exact quality of the imagery. If set to false, the `required_quality` field is interpreted as the minimum required quality, such that HIGH quality imagery may be returned when `required_quality` is set to MEDIUM. If set to true, `required_quality` is interpreted as the exact required quality and only `MEDIUM` quality imagery is returned if `required_quality` is set to `MEDIUM`.
865
+ * exactQualityRequired: 'placeholder-value',
866
+ * // Optional. Specifies the pre-GA experiments to enable.
867
+ * experiments: 'placeholder-value',
868
+ * // The latitude in degrees. It must be in the range [-90.0, +90.0].
869
+ * 'location.latitude': 'placeholder-value',
870
+ * // The longitude in degrees. It must be in the range [-180.0, +180.0].
871
+ * 'location.longitude': 'placeholder-value',
872
+ * // Optional. The minimum scale, in meters per pixel, of the data to return. Values of 0.1 (the default, if this field is not set explicitly), 0.25, 0.5, and 1.0 are supported. Imagery components whose normal resolution is less than `pixel_size_meters` will be returned at the resolution specified by `pixel_size_meters`; imagery components whose normal resolution is equal to or greater than `pixel_size_meters` will be returned at that normal resolution.
873
+ * pixelSizeMeters: 'placeholder-value',
874
+ * // Required. The radius, in meters, defining the region surrounding that centre point for which data should be returned. The limitations on this value are: * Any value up to 100m can always be specified. * Values over 100m can be specified, as long as `radius_meters` <= `pixel_size_meters * 1000`. * However, for values over 175m, the `DataLayerView` in the request must not include monthly flux or hourly shade.
875
+ * radiusMeters: 'placeholder-value',
876
+ * // Optional. The minimum quality level allowed in the results. No result with lower quality than this will be returned. Not specifying this is equivalent to restricting to HIGH quality only.
877
+ * requiredQuality: 'placeholder-value',
878
+ * // Optional. The desired subset of the data to return.
879
+ * view: 'placeholder-value',
880
+ * });
881
+ * console.log(res.data);
882
+ *
883
+ * // Example response
884
+ * // {
885
+ * // "annualFluxUrl": "my_annualFluxUrl",
886
+ * // "dsmUrl": "my_dsmUrl",
887
+ * // "hourlyShadeUrls": [],
888
+ * // "imageryDate": {},
889
+ * // "imageryProcessedDate": {},
890
+ * // "imageryQuality": "my_imageryQuality",
891
+ * // "maskUrl": "my_maskUrl",
892
+ * // "monthlyFluxUrl": "my_monthlyFluxUrl",
893
+ * // "rgbUrl": "my_rgbUrl"
894
+ * // }
895
+ * }
896
+ *
897
+ * main().catch(e => {
898
+ * console.error(e);
899
+ * throw e;
900
+ * });
901
+ *
902
+ * ```
773
903
  *
774
904
  * @param params - Parameters for request
775
905
  * @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
@@ -899,6 +1029,54 @@ export namespace solar_v1 {
899
1029
 
900
1030
  /**
901
1031
  * Returns an image by its ID.
1032
+ * @example
1033
+ * ```js
1034
+ * // Before running the sample:
1035
+ * // - Enable the API at:
1036
+ * // https://console.developers.google.com/apis/api/solar.googleapis.com
1037
+ * // - Login into gcloud by running:
1038
+ * // ```sh
1039
+ * // $ gcloud auth application-default login
1040
+ * // ```
1041
+ * // - Install the npm module by running:
1042
+ * // ```sh
1043
+ * // $ npm install googleapis
1044
+ * // ```
1045
+ *
1046
+ * const {google} = require('googleapis');
1047
+ * const solar = google.solar('v1');
1048
+ *
1049
+ * async function main() {
1050
+ * const auth = new google.auth.GoogleAuth({
1051
+ * // Scopes can be specified either as an array or as a single, space-delimited string.
1052
+ * scopes: ['https://www.googleapis.com/auth/cloud-platform'],
1053
+ * });
1054
+ *
1055
+ * // Acquire an auth client, and bind it to all future calls
1056
+ * const authClient = await auth.getClient();
1057
+ * google.options({auth: authClient});
1058
+ *
1059
+ * // Do the magic
1060
+ * const res = await solar.geoTiff.get({
1061
+ * // Required. The ID of the asset being requested.
1062
+ * id: 'placeholder-value',
1063
+ * });
1064
+ * console.log(res.data);
1065
+ *
1066
+ * // Example response
1067
+ * // {
1068
+ * // "contentType": "my_contentType",
1069
+ * // "data": "my_data",
1070
+ * // "extensions": []
1071
+ * // }
1072
+ * }
1073
+ *
1074
+ * main().catch(e => {
1075
+ * console.error(e);
1076
+ * throw e;
1077
+ * });
1078
+ *
1079
+ * ```
902
1080
  *
903
1081
  * @param params - Parameters for request
904
1082
  * @param options - Optionally override request options, such as `url`, `method`, and `encoding`.