Package google.maps.solar.v1

Index

Solar

Service definition for the Solar API.

FindClosestBuildingInsights

rpc FindClosestBuildingInsights(FindClosestBuildingInsightsRequest) returns (BuildingInsights)

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.

Authorization scopes

Requires the following OAuth scope:

  • https://www.googleapis.com/auth/cloud-platform
GetDataLayers

rpc GetDataLayers(GetDataLayersRequest) returns (DataLayers)

Gets solar information for a region surrounding a location. Returns an error with code NOT_FOUND if the location is outside the coverage area.

Authorization scopes

Requires the following OAuth scope:

  • https://www.googleapis.com/auth/cloud-platform
GetGeoTiff

rpc GetGeoTiff(GetGeoTiffRequest) returns (HttpBody)

Returns an image by its ID.

Authorization scopes

Requires the following OAuth scope:

  • https://www.googleapis.com/auth/cloud-platform

BuildingInsights

Response message for Solar.FindClosestBuildingInsights. Information about the location, dimensions, and solar potential of a building.

Fields
name

string

The resource name for the building, of the format buildings/{place_id}.

center

LatLng

A point near the center of the building.

bounding_box

LatLngBox

The bounding box of the building.

imagery_date

Date

Date that the underlying imagery was acquired. This is approximate.

imagery_processed_date

Date

When processing was completed on this imagery.

postal_code

string

Postal code (e.g., US zip code) this building is contained by.

administrative_area

string

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_area

string

Statistical area (e.g., US census tract) this building is in.

region_code

string

Region code for the country (or region) this building is in.

solar_potential

SolarPotential

Solar potential of the building.

imagery_quality

ImageryQuality

The quality of the imagery used to compute the data for this building.

CashPurchaseSavings

Cost and benefit of an outright purchase of a particular configuration of solar panels with a particular electricity usage.

Fields
out_of_pocket_cost

Money

Initial cost before tax incentives: the amount that must be paid out-of-pocket. Contrast with upfront_cost, which is after tax incentives.

upfront_cost

Money

Initial cost after tax incentives: it's the amount that must be paid during first year. Contrast with out_of_pocket_cost, which is before tax incentives.

rebate_value

Money

The value of all tax rebates.

savings

SavingsOverTime

How much is saved (or not) over the lifetime period.

payback_years

float

Number of years until payback occurs. A negative value means payback never occurs within the lifetime period.

DataLayerView

What subset of the solar information to return.

Enums
DATA_LAYER_VIEW_UNSPECIFIED Equivalent to FULL.
DSM_LAYER Get the DSM only.
IMAGERY_LAYERS Get the DSM, RGB, and mask.
IMAGERY_AND_ANNUAL_FLUX_LAYERS Get the DSM, RGB, mask, and annual flux.
IMAGERY_AND_ALL_FLUX_LAYERS Get the DSM, RGB, mask, annual flux, and monthly flux.
FULL_LAYERS Get all data.

DataLayers

Information about the solar potential of a region. The actual data are contained in a number of GeoTIFF files covering the requested region, for which this message contains URLs: Each string in the DataLayers message contains a URL from which the corresponding GeoTIFF can be fetched. These URLs are valid for a few hours after they've been generated. Most of the GeoTIFF files are at a resolution of 0.1m/pixel, but the monthly flux file is at 0.5m/pixel, and the hourly shade files are at 1m/pixel. If a pixel_size_meters value was specified in the GetDataLayersRequest, then the minimum resolution in the GeoTIFF files will be that value.

Fields
imagery_date

Date

When the source imagery (from which all the other data are derived) in this region was taken. It is necessarily somewhat approximate, as the images may have been taken over more than one day.

imagery_processed_date

Date

When processing was completed on this imagery.

dsm_url

string

The URL for an image of the DSM (Digital Surface Model) of the region. Values are in meters above EGM96 geoid (i.e., sea level). Invalid locations (where we don't have data) are stored as -9999.

rgb_url

string

The URL for an image of RGB data (aerial photo) of the region.

mask_url

string

The URL for the building mask image: one bit per pixel saying whether that pixel is considered to be part of a rooftop or not.

annual_flux_url

string

The URL for the annual flux map (annual sunlight on roofs) of the region. Values are kWh/kW/year. This is unmasked flux: flux is computed for every location, not just building rooftops. Invalid locations are stored as -9999: locations outside our coverage area will be invalid, and a few locations inside the coverage area, where we were unable to calculate flux, will also be invalid.

monthly_flux_url

string

The URL for the monthly flux map (sunlight on roofs, broken down by month) of the region. Values are kWh/kW/year. The GeoTIFF pointed to by this URL will contain twelve bands, corresponding to January...December, in order.

hourly_shade_urls[]

string

Twelve URLs for hourly shade, corresponding to January...December, in order. Each GeoTIFF will contain 24 bands, corresponding to the 24 hours of the day. Each pixel is a 32 bit integer, corresponding to the (up to) 31 days of that month; a 1 bit means that the corresponding location is able to see the sun at that day, of that hour, of that month. Invalid locations are stored as -9999 (since this is negative, it has bit 31 set, and no valid value could have bit 31 set as that would correspond to the 32nd day of the month).

An example may be useful. If you want to know whether a point (at pixel location (x, y)) saw sun at 4pm on the 22nd of June you would:

  1. fetch the sixth URL in this list (corresponding to June).
  2. look up the 17th channel (corresponding to 4pm).
  3. read the 32-bit value at (x, y).
  4. read bit 21 of the value (corresponding to the 22nd of the month).
  5. if that bit is a 1, then that spot saw the sun at 4pm 22 June.

More formally: Given month (1-12), day (1...month max; February has 28 days) and hour (0-23), the shade/sun for that month/day/hour at a position (x, y) is the bit

(hourly_shade[month - 1])(x, y)[hour] & (1 << (day - 1))

where (x, y) is spatial indexing, [month - 1] refers to fetching the month - 1st URL (indexing from zero), [hour] is indexing into the channels, and a final non-zero result means "sunny". There are no leap days, and DST doesn't exist (all days are 24 hours long; noon is always "standard time" noon).

imagery_quality

ImageryQuality

The quality of the result's imagery.

FinancedPurchaseSavings

Cost and benefit of using a loan to buy a particular configuration of solar panels with a particular electricity usage.

Fields
annual_loan_payment

Money

Annual loan payments.

rebate_value

Money

The value of all tax rebates (including Federal Investment Tax Credit (ITC)).

loan_interest_rate

float

The interest rate on loans assumed in this set of calculations.

savings

SavingsOverTime

How much is saved (or not) over the lifetime period.

FinancialAnalysis

Analysis of the cost and benefits of the optimum solar layout for a particular electric bill size.

Fields
monthly_bill

Money

The monthly electric bill this analysis assumes.

default_bill

bool

Whether this is the bill size selected to be the default bill for the area this building is in. Exactly one FinancialAnalysis in BuildingSolarPotential should have default_bill set.

average_kwh_per_month

float

How much electricity the house uses in an average month, based on the bill size and the local electricity rates.

financial_details

FinancialDetails

Financial information that applies regardless of the financing method used.

leasing_savings

LeasingSavings

Cost and benefit of leasing the solar panels.

cash_purchase_savings

CashPurchaseSavings

Cost and benefit of buying the solar panels with cash.

financed_purchase_savings

FinancedPurchaseSavings

Cost and benefit of buying the solar panels by financing the purchase.

panel_config_index

int32

Index in solar_panel_configs of the optimum solar layout for this bill size. This can be -1 indicating that there is no layout. In this case, the remaining submessages will be omitted.

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 panel_lifetime_years field in SolarPotential. Note: The out of pocket cost of purchasing the panels is given in the out_of_pocket_cost field in CashPurchaseSavings.

Fields
initial_ac_kwh_per_year

float

How many AC kWh we think the solar panels will generate in their first year.

remaining_lifetime_utility_bill

Money

Utility bill for electricity not produced by solar, for the lifetime of the panels.

federal_incentive

Money

Amount of money available from federal incentives; this applies if the user buys (with or without a loan) the panels.

state_incentive

Money

Amount of money available from state incentives; this applies if the user buys (with or without a loan) the panels.

utility_incentive

Money

Amount of money available from utility incentives; this applies if the user buys (with or without a loan) the panels.

lifetime_srec_total

Money

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_of_electricity_without_solar

Money

Total cost of electricity the user would have paid over the lifetime period if they didn't install solar.

net_metering_allowed

bool

Whether net metering is allowed.

solar_percentage

float

Percentage (0-100) of the user's power supplied by solar. Valid for the first year but approximately correct for future years.

percentage_exported_to_grid

float

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.

FindClosestBuildingInsightsRequest

Request message for Solar.FindClosestBuildingInsights.

Fields
location

LatLng

Required. The longitude and latitude from which the API looks for the nearest known building.

required_quality

ImageryQuality

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.

GetDataLayersRequest

Request message for Solar.GetDataLayers.

Fields
location

LatLng

Required. The longitude and latitude for the center of the region to get data for.

radius_meters

float

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.
view

DataLayerView

Optional. The desired subset of the data to return.

required_quality

ImageryQuality

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.

pixel_size_meters

float

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.

exact_quality_required

bool

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.

GetGeoTiffRequest

Request message for Solar.GetGeoTiff.

Fields
id

string

Required. The ID of the asset being requested.

ImageryQuality

The quality of the imagery used to compute some API result.

Note: Regardless of imagery quality level, DSM outputs always have a resolution of 0.1 m/pixel, monthly flux outputs always have a resolution of 0.5 m/pixel, and hourly shade outputs always have a resolution of 1 m/pixel.

Enums
IMAGERY_QUALITY_UNSPECIFIED No quality is known.
HIGH Solar data is derived from aerial imagery captured at low-altitude and processed at 0.1 m/pixel.
MEDIUM Solar data is derived from enhanced aerial imagery captured at high-altitude and processed at 0.25 m/pixel.
LOW Solar data is derived from enhanced satellite imagery processed at 0.25 m/pixel.
BASE Solar data is derived from enhanced satellite imagery processed at 0.25 m/pixel.

LatLngBox

A bounding box in lat/lng coordinates.

Fields
sw

LatLng

The southwest corner of the box.

ne

LatLng

The northeast corner of the box.

LeasingSavings

Cost and benefit of leasing a particular configuration of solar panels with a particular electricity usage.

Fields
leases_allowed

bool

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_supported

bool

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 leases_allowed: in some areas leases are allowed, but under conditions that aren't handled by the financial models.

annual_leasing_cost

Money

Estimated annual leasing cost.

savings

SavingsOverTime

How much is saved (or not) over the lifetime period.

RoofSegmentSizeAndSunshineStats

Information about the size and sunniness quantiles of a roof segment.

Fields
stats

SizeAndSunshineStats

Total size and sunlight quantiles for the roof segment.

center

LatLng

A point near the center of the roof segment.

bounding_box

LatLngBox

The bounding box of the roof segment.

pitch_degrees

float

Angle of the roof segment relative to the theoretical ground plane. 0 = parallel to the ground, 90 = perpendicular to the ground.

azimuth_degrees

float

Compass direction the roof segment is pointing in. 0 = North, 90 = East, 180 = South. For a "flat" roof segment (pitch_degrees very near 0), azimuth is not well defined, so for consistency, we define it arbitrarily to be 0 (North).

plane_height_at_center_meters

float

The height of the roof segment plane, in meters above sea level, at the point designated by center. Together with the pitch, azimuth, and center location, this fully defines the roof segment plane.

RoofSegmentSummary

Information about a roof segment on the building, with some number of panels placed on it.

Fields
panels_count

int32

The total number of panels on this segment.

yearly_energy_dc_kwh

float

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_degrees

float

Angle of the roof segment relative to the theoretical ground plane. 0 = parallel to the ground, 90 = perpendicular to the ground.

azimuth_degrees

float

Compass direction the roof segment is pointing in. 0 = North, 90 = East, 180 = South. For a "flat" roof segment (pitch_degrees very near 0), azimuth is not well defined, so for consistency, we define it arbitrarily to be 0 (North).

segment_index

int32

Index in roof_segment_stats of the corresponding RoofSegmentSizeAndSunshineStats.

SavingsOverTime

Financial information that's shared between different financing methods.

Fields
savings_year1

Money

Savings in the first year after panel installation.

savings_year20

Money

Savings in the first twenty years after panel installation.

present_value_of_savings_year20

Money

Using the assumed discount rate, what is the present value of the cumulative 20-year savings?

savings_lifetime

Money

Savings in the entire panel lifetime.

present_value_of_savings_lifetime

Money

Using the assumed discount rate, what is the present value of the cumulative lifetime savings?

financially_viable

bool

Indicates whether this scenario is financially viable. Will be false for scenarios with poor financial viability (e.g., money-losing).

SizeAndSunshineStats

Size and sunniness quantiles of a roof, or part of a roof.

Fields
area_meters2

float

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[]

float

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 max_sunshine_hours_per_year.

ground_area_meters2

float

The ground footprint area covered by the roof or roof segment, in m^2.

SolarPanel

SolarPanel describes the position, orientation, and production of a single solar panel. See the panel_height_meters, panel_width_meters, and panel_capacity_watts fields in SolarPotential for information on the parameters of the panel.

Fields
center

LatLng

The centre of the panel.

orientation

SolarPanelOrientation

The orientation of the panel.

yearly_energy_dc_kwh

float

How much sunlight energy this layout captures over the course of a year, in DC kWh.

segment_index

int32

Index in roof_segment_stats of the RoofSegmentSizeAndSunshineStats which corresponds to the roof segment that this panel is placed on.

SolarPanelConfig

SolarPanelConfig describes a particular placement of solar panels on the roof.

Fields
panels_count

int32

Total number of panels. Note that this is redundant to (the sum of) the corresponding fields in roof_segment_summaries.

yearly_energy_dc_kwh

float

How much sunlight energy this layout captures over the course of a year, in DC kWh, assuming the panels described above.

roof_segment_summaries[]

RoofSegmentSummary

Information about the production of each roof segment that is carrying at least one panel in this layout. roof_segment_summaries[i] describes the i-th roof segment, including its size, expected production and orientation.

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.

SolarPotential

Information about the solar potential of a building. A number of fields in this are defined in terms of "panels". The fields panel_capacity_watts, panel_height_meters, and panel_width_meters describe the parameters of the model of panel used in these calculations.

Fields
max_array_panels_count

int32

Size of the maximum array - that is, the maximum number of panels that can fit on the roof.

panel_capacity_watts

float

Capacity, in watts, of the panel used in the calculations.

panel_height_meters

float

Height, in meters in portrait orientation, of the panel used in the calculations.

panel_width_meters

float

Width, in meters in portrait orientation, of the panel used in the calculations.

panel_lifetime_years

int32

The expected lifetime, in years, of the solar panels. This is used in the financial calculations.

max_array_area_meters2

float

Size, in square meters, of the maximum array.

max_sunshine_hours_per_year

float

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_offset_factor_kg_per_mwh

float

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_roof_stats

SizeAndSunshineStats

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_stats.

building_stats

SizeAndSunshineStats

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 whole_roof_stats by the ratio of the ground areas of building_stats and whole_roof_stats.

roof_segment_stats[]

RoofSegmentSizeAndSunshineStats

Size and sunlight quantiles for each roof segment.

solar_panels[]

SolarPanel

Each SolarPanel describes a single solar panel. They are listed in the order that the panel layout algorithm placed this. This is usually, though not always, in decreasing order of annual energy production.

solar_panel_configs[]

SolarPanelConfig

Each SolarPanelConfig describes a different arrangement of solar panels on the roof. They are in order of increasing number of panels. The SolarPanelConfig with panels_count=N is based on the first N panels in the solar_panels list. This field is only populated if at least 4 panels can fit on a roof.

financial_analyses[]

FinancialAnalysis

A FinancialAnalysis gives the savings from going solar assuming a given monthly bill and a given electricity provider. They are in order of increasing order of monthly bill amount. This field will be empty for buildings in areas for which the Solar API does not have enough information to perform financial computations.