- HTTP request
- Query parameters
- Request body
- Response body
- Authorization scopes
- LatLngBox
- SolarPotential
- SizeAndSunshineStats
- RoofSegmentSizeAndSunshineStats
- SolarPanel
- SolarPanelOrientation
- SolarPanelConfig
- RoofSegmentSummary
- FinancialAnalysis
- Money
- FinancialDetails
- LeasingSavings
- SavingsOverTime
- CashPurchaseSavings
- FinancedPurchaseSavings
- Try it!
Locates the closest building to a query point. Returns an error with code NOT_FOUND
if there are no buildings within approximately 50m of the query point.
HTTP request
GET https://solar.googleapis.com/v1/buildingInsights:findClosest
The URL uses gRPC Transcoding syntax.
Query parameters
Parameters | |
---|---|
location |
Required. The longitude and latitude from which the API looks for the nearest known building. |
required |
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. |
Request body
The request body must be empty.
Response body
Response message for Solar.FindClosestBuildingInsights
. Information about the location, dimensions, and solar potential of a building.
If successful, the response body contains data with the following structure:
JSON representation |
---|
{ "name": string, "center": { object ( |
Fields | |
---|---|
name |
The resource name for the building, of the format |
center |
A point near the center of the building. |
bounding |
The bounding box of the building. |
imagery |
Date that the underlying imagery was acquired. This is approximate. |
imagery |
When processing was completed on this imagery. |
postal |
Postal code (e.g., US zip code) this building is contained by. |
administrative |
Administrative area 1 (e.g., in the US, the state) that contains this building. For example, in the US, the abbreviation might be "MA" or "CA." |
statistical |
Statistical area (e.g., US census tract) this building is in. |
region |
Region code for the country (or region) this building is in. |
solar |
Solar potential of the building. |
imagery |
The quality of the imagery used to compute the data for this building. |
Authorization scopes
Requires the following OAuth scope:
https://www.googleapis.com/auth/cloud-platform
LatLngBox
A bounding box in lat/lng coordinates.
JSON representation |
---|
{ "sw": { object ( |
Fields | |
---|---|
sw |
The southwest corner of the box. |
ne |
The northeast corner of the box. |
SolarPotential
Information about the solar potential of a building. A number of fields in this are defined in terms of "panels". The fields panelCapacityWatts
, panelHeightMeters
, and panelWidthMeters
describe the parameters of the model of panel used in these calculations.
JSON representation |
---|
{ "maxArrayPanelsCount": integer, "panelCapacityWatts": number, "panelHeightMeters": number, "panelWidthMeters": number, "panelLifetimeYears": integer, "maxArrayAreaMeters2": number, "maxSunshineHoursPerYear": number, "carbonOffsetFactorKgPerMwh": number, "wholeRoofStats": { object ( |
Fields | |
---|---|
max |
Size of the maximum array - that is, the maximum number of panels that can fit on the roof. |
panel |
Capacity, in watts, of the panel used in the calculations. |
panel |
Height, in meters in portrait orientation, of the panel used in the calculations. |
panel |
Width, in meters in portrait orientation, of the panel used in the calculations. |
panel |
The expected lifetime, in years, of the solar panels. This is used in the financial calculations. |
max |
Size, in square meters, of the maximum array. |
max |
Maximum number of sunshine hours received per year, by any point on the roof. Sunshine hours are a measure of the total amount of insolation (energy) received per year. 1 sunshine hour = 1 kWh per kW (where kW refers to kW of capacity under Standard Testing Conditions). |
carbon |
Equivalent amount of CO2 produced per MWh of grid electricity. This is a measure of the carbon intensity of grid electricity displaced by solar electricity. |
whole |
Total size and sunlight quantiles for the part of the roof that was assigned to some roof segment. Despite the name, this may not include the entire building. See |
building |
Size and sunlight quantiles for the entire building, including parts of the roof that were not assigned to some roof segment. Because the orientations of these parts are not well characterised, the roof area estimate is unreliable, but the ground area estimate is reliable. It may be that a more reliable whole building roof area can be obtained by scaling the roof area from |
roof |
Size and sunlight quantiles for each roof segment. |
solar |
Each |
solar |
Each |
financial |
A |
SizeAndSunshineStats
Size and sunniness quantiles of a roof, or part of a roof.
JSON representation |
---|
{ "areaMeters2": number, "sunshineQuantiles": [ number ], "groundAreaMeters2": number } |
Fields | |
---|---|
area |
The area of the roof or roof segment, in m^2. This is the roof area (accounting for tilt), not the ground footprint area. |
sunshine |
Quantiles of the pointwise sunniness across the area. If there are N values here, this represents the (N-1)-iles. For example, if there are 5 values, then they would be the quartiles (min, 25%, 50%, 75%, max). Values are in annual kWh/kW like |
ground |
The ground footprint area covered by the roof or roof segment, in m^2. |
RoofSegmentSizeAndSunshineStats
Information about the size and sunniness quantiles of a roof segment.
JSON representation |
---|
{ "stats": { object ( |
Fields | |
---|---|
stats |
Total size and sunlight quantiles for the roof segment. |
center |
A point near the center of the roof segment. |
bounding |
The bounding box of the roof segment. |
pitch |
Angle of the roof segment relative to the theoretical ground plane. 0 = parallel to the ground, 90 = perpendicular to the ground. |
azimuth |
Compass direction the roof segment is pointing in. 0 = North, 90 = East, 180 = South. For a "flat" roof segment ( |
plane |
The height of the roof segment plane, in meters above sea level, at the point designated by |
SolarPanel
SolarPanel describes the position, orientation, and production of a single solar panel. See the panelHeightMeters
, panelWidthMeters
, and panelCapacityWatts
fields in SolarPotential
for information on the parameters of the panel.
JSON representation |
---|
{ "center": { object ( |
Fields | |
---|---|
center |
The centre of the panel. |
orientation |
The orientation of the panel. |
yearly |
How much sunlight energy this layout captures over the course of a year, in DC kWh. |
segment |
Index in |
SolarPanelOrientation
The orientation of a solar panel. This must be interpreted relative to the azimuth of the roof segment that the panel is placed on.
Enums | |
---|---|
SOLAR_PANEL_ORIENTATION_UNSPECIFIED |
No panel orientation is known. |
LANDSCAPE |
A LANDSCAPE panel has its long edge perpendicular to the azimuth direction of the roof segment that it is placed on. |
PORTRAIT |
A PORTRAIT panel has its long edge parallel to the azimuth direction of the roof segment that it is placed on. |
SolarPanelConfig
SolarPanelConfig describes a particular placement of solar panels on the roof.
JSON representation |
---|
{
"panelsCount": integer,
"yearlyEnergyDcKwh": number,
"roofSegmentSummaries": [
{
object ( |
Fields | |
---|---|
panels |
Total number of panels. Note that this is redundant to (the sum of) the corresponding fields in |
yearly |
How much sunlight energy this layout captures over the course of a year, in DC kWh, assuming the panels described above. |
roof |
Information about the production of each roof segment that is carrying at least one panel in this layout. |
RoofSegmentSummary
Information about a roof segment on the building, with some number of panels placed on it.
JSON representation |
---|
{ "panelsCount": integer, "yearlyEnergyDcKwh": number, "pitchDegrees": number, "azimuthDegrees": number, "segmentIndex": integer } |
Fields | |
---|---|
panels |
The total number of panels on this segment. |
yearly |
How much sunlight energy this part of the layout captures over the course of a year, in DC kWh, assuming the panels described above. |
pitch |
Angle of the roof segment relative to the theoretical ground plane. 0 = parallel to the ground, 90 = perpendicular to the ground. |
azimuth |
Compass direction the roof segment is pointing in. 0 = North, 90 = East, 180 = South. For a "flat" roof segment ( |
segment |
Index in |
FinancialAnalysis
Analysis of the cost and benefits of the optimum solar layout for a particular electric bill size.
JSON representation |
---|
{ "monthlyBill": { object ( |
Fields | |
---|---|
monthly |
The monthly electric bill this analysis assumes. |
default |
Whether this is the bill size selected to be the default bill for the area this building is in. Exactly one |
average |
How much electricity the house uses in an average month, based on the bill size and the local electricity rates. |
financial |
Financial information that applies regardless of the financing method used. |
leasing |
Cost and benefit of leasing the solar panels. |
cash |
Cost and benefit of buying the solar panels with cash. |
financed |
Cost and benefit of buying the solar panels by financing the purchase. |
panel |
Index in |
Money
Represents an amount of money with its currency type.
JSON representation |
---|
{ "currencyCode": string, "units": string, "nanos": integer } |
Fields | |
---|---|
currency |
The three-letter currency code defined in ISO 4217. |
units |
The whole units of the amount. For example if |
nanos |
Number of nano (10^-9) units of the amount. The value must be between -999,999,999 and +999,999,999 inclusive. If |
FinancialDetails
Details of a financial analysis. Some of these details are already stored at higher levels (e.g., out of pocket cost). Total money amounts are over a lifetime period defined by the panelLifetimeYears
field in SolarPotential
. Note: The out of pocket cost of purchasing the panels is given in the outOfPocketCost
field in CashPurchaseSavings
.
JSON representation |
---|
{ "initialAcKwhPerYear": number, "remainingLifetimeUtilityBill": { object ( |
Fields | |
---|---|
initial |
How many AC kWh we think the solar panels will generate in their first year. |
remaining |
Utility bill for electricity not produced by solar, for the lifetime of the panels. |
federal |
Amount of money available from federal incentives; this applies if the user buys (with or without a loan) the panels. |
state |
Amount of money available from state incentives; this applies if the user buys (with or without a loan) the panels. |
utility |
Amount of money available from utility incentives; this applies if the user buys (with or without a loan) the panels. |
lifetime |
Amount of money the user will receive from Solar Renewable Energy Credits over the panel lifetime; this applies if the user buys (with or without a loan) the panels. |
cost |
Total cost of electricity the user would have paid over the lifetime period if they didn't install solar. |
net |
Whether net metering is allowed. |
solar |
Percentage (0-100) of the user's power supplied by solar. Valid for the first year but approximately correct for future years. |
percentage |
The percentage (0-100) of solar electricity production we assumed was exported to the grid, based on the first quarter of production. This affects the calculations if net metering is not allowed. |
LeasingSavings
Cost and benefit of leasing a particular configuration of solar panels with a particular electricity usage.
JSON representation |
---|
{ "leasesAllowed": boolean, "leasesSupported": boolean, "annualLeasingCost": { object ( |
Fields | |
---|---|
leases |
Whether leases are allowed in this juristiction (leases are not allowed in some states). If this field is false, then the values in this message should probably be ignored. |
leases |
Whether leases are supported in this juristiction by the financial calculation engine. If this field is false, then the values in this message should probably be ignored. This is independent of |
annual |
Estimated annual leasing cost. |
savings |
How much is saved (or not) over the lifetime period. |
SavingsOverTime
Financial information that's shared between different financing methods.
JSON representation |
---|
{ "savingsYear1": { object ( |
Fields | |
---|---|
savings |
Savings in the first year after panel installation. |
savings |
Savings in the first twenty years after panel installation. |
present |
Using the assumed discount rate, what is the present value of the cumulative 20-year savings? |
savings |
Savings in the entire panel lifetime. |
present |
Using the assumed discount rate, what is the present value of the cumulative lifetime savings? |
financially |
Indicates whether this scenario is financially viable. Will be false for scenarios with poor financial viability (e.g., money-losing). |
CashPurchaseSavings
Cost and benefit of an outright purchase of a particular configuration of solar panels with a particular electricity usage.
JSON representation |
---|
{ "outOfPocketCost": { object ( |
Fields | |
---|---|
out |
Initial cost before tax incentives: the amount that must be paid out-of-pocket. Contrast with |
upfront |
Initial cost after tax incentives: it's the amount that must be paid during first year. Contrast with |
rebate |
The value of all tax rebates. |
savings |
How much is saved (or not) over the lifetime period. |
payback |
Number of years until payback occurs. A negative value means payback never occurs within the lifetime period. |
FinancedPurchaseSavings
Cost and benefit of using a loan to buy a particular configuration of solar panels with a particular electricity usage.
JSON representation |
---|
{ "annualLoanPayment": { object ( |
Fields | |
---|---|
annual |
Annual loan payments. |
rebate |
The value of all tax rebates (including Federal Investment Tax Credit (ITC)). |
loan |
The interest rate on loans assumed in this set of calculations. |
savings |
How much is saved (or not) over the lifetime period. |