Copyright | (c) 2015 Brendan Hay |
---|---|
License | Mozilla Public License, v. 2.0. |
Maintainer | Brendan Hay <brendan.g.hay@gmail.com> |
Stability | auto-generated |
Portability | non-portable (GHC extensions) |
Safe Haskell | None |
Language | Haskell2010 |
- Service Configuration
- LatLng
- AttachmentInfo
- BeaconProperties
- Empty
- DeleteAttachmentsResponse
- GetInfoForObservedBeaconsRequest
- Namespace
- ListNamespacesResponse
- Date
- Beacon
- Diagnostics
- ListBeaconAttachmentsResponse
- IndoorLevel
- BeaconInfo
- Observation
- BeaconAttachment
- ListDiagnosticsResponse
- AdvertisedId
- ListBeaconsResponse
- GetInfoForObservedBeaconsResponse
- proximityBeaconService :: Service
- data LatLng
- latLng :: LatLng
- llLatitude :: Lens' LatLng (Maybe Double)
- llLongitude :: Lens' LatLng (Maybe Double)
- data AttachmentInfo
- attachmentInfo :: AttachmentInfo
- aiData :: Lens' AttachmentInfo (Maybe Word8)
- aiNamespacedType :: Lens' AttachmentInfo (Maybe Text)
- data BeaconProperties
- beaconProperties :: HashMap Text Text -> BeaconProperties
- bpAddtional :: Lens' BeaconProperties (HashMap Text Text)
- data Empty
- empty :: Empty
- data DeleteAttachmentsResponse
- deleteAttachmentsResponse :: DeleteAttachmentsResponse
- darNumDeleted :: Lens' DeleteAttachmentsResponse (Maybe Int32)
- data GetInfoForObservedBeaconsRequest
- getInfoForObservedBeaconsRequest :: GetInfoForObservedBeaconsRequest
- gifobrObservations :: Lens' GetInfoForObservedBeaconsRequest [Observation]
- gifobrNamespacedTypes :: Lens' GetInfoForObservedBeaconsRequest [Text]
- data Namespace
- namespace :: Namespace
- nServingVisibility :: Lens' Namespace (Maybe Text)
- nNamespaceName :: Lens' Namespace (Maybe Text)
- data ListNamespacesResponse
- listNamespacesResponse :: ListNamespacesResponse
- lnrNamespaces :: Lens' ListNamespacesResponse [Namespace]
- data Date
- date :: Date
- dDay :: Lens' Date (Maybe Int32)
- dYear :: Lens' Date (Maybe Int32)
- dMonth :: Lens' Date (Maybe Int32)
- data Beacon
- beacon :: Beacon
- bLatLng :: Lens' Beacon (Maybe LatLng)
- bStatus :: Lens' Beacon (Maybe Text)
- bBeaconName :: Lens' Beacon (Maybe Text)
- bIndoorLevel :: Lens' Beacon (Maybe IndoorLevel)
- bExpectedStability :: Lens' Beacon (Maybe Text)
- bDescription :: Lens' Beacon (Maybe Text)
- bPlaceId :: Lens' Beacon (Maybe Text)
- bAdvertisedId :: Lens' Beacon (Maybe AdvertisedId)
- bProperties :: Lens' Beacon (Maybe BeaconProperties)
- data Diagnostics
- diagnostics :: Diagnostics
- dAlerts :: Lens' Diagnostics [Text]
- dBeaconName :: Lens' Diagnostics (Maybe Text)
- dEstimatedLowBatteryDate :: Lens' Diagnostics (Maybe Date)
- data ListBeaconAttachmentsResponse
- listBeaconAttachmentsResponse :: ListBeaconAttachmentsResponse
- lbarAttachments :: Lens' ListBeaconAttachmentsResponse [BeaconAttachment]
- data IndoorLevel
- indoorLevel :: IndoorLevel
- ilName :: Lens' IndoorLevel (Maybe Text)
- data BeaconInfo
- beaconInfo :: BeaconInfo
- biAttachments :: Lens' BeaconInfo [AttachmentInfo]
- biBeaconName :: Lens' BeaconInfo (Maybe Text)
- biDescription :: Lens' BeaconInfo (Maybe Text)
- biAdvertisedId :: Lens' BeaconInfo (Maybe AdvertisedId)
- data Observation
- observation :: Observation
- oTelemetry :: Lens' Observation (Maybe Word8)
- oTimestampMs :: Lens' Observation (Maybe Text)
- oAdvertisedId :: Lens' Observation (Maybe AdvertisedId)
- data BeaconAttachment
- beaconAttachment :: BeaconAttachment
- baData :: Lens' BeaconAttachment (Maybe Word8)
- baAttachmentName :: Lens' BeaconAttachment (Maybe Text)
- baNamespacedType :: Lens' BeaconAttachment (Maybe Text)
- data ListDiagnosticsResponse
- listDiagnosticsResponse :: ListDiagnosticsResponse
- ldrNextPageToken :: Lens' ListDiagnosticsResponse (Maybe Text)
- ldrDiagnostics :: Lens' ListDiagnosticsResponse [Diagnostics]
- data AdvertisedId
- advertisedId :: AdvertisedId
- aiId :: Lens' AdvertisedId (Maybe Word8)
- aiType :: Lens' AdvertisedId (Maybe Text)
- data ListBeaconsResponse
- listBeaconsResponse :: ListBeaconsResponse
- lbrNextPageToken :: Lens' ListBeaconsResponse (Maybe Text)
- lbrBeacons :: Lens' ListBeaconsResponse [Beacon]
- lbrTotalCount :: Lens' ListBeaconsResponse (Maybe Int64)
- data GetInfoForObservedBeaconsResponse
- getInfoForObservedBeaconsResponse :: GetInfoForObservedBeaconsResponse
- gifobrBeacons :: Lens' GetInfoForObservedBeaconsResponse [BeaconInfo]
Service Configuration
proximityBeaconService :: Service Source
Default request referring to version v1beta1
of the Google Proximity Beacon API. This contains the host and root path used as a starting point for constructing service requests.
LatLng
An object representing a latitude/longitude pair. This is expressed as a pair of doubles representing degrees latitude and degrees longitude. Unless specified otherwise, this must conform to the WGS84 standard. Values must be within normalized ranges. Example of normalization code in Python: def NormalizeLongitude(longitude): """Wrapsdecimal degrees longitude to [-180.0, 180.0].""" q, r = divmod(longitude, 360.0) if r > 180.0 or (r == 180.0 and q <= -1.0): return r - 360.0 return r def NormalizeLatLng(latitude, longitude): """Wraps decimal degrees latitude and longitude to [-180.0, 180.0] and [-90.0, 90.0], respectively.""" r = latitude % 360.0 if r = 270.0: return r - 360, NormalizeLongitude(longitude) else: return 180 - r, NormalizeLongitude(longitude + 180.0) assert 180.0 == NormalizeLongitude(180.0) assert -180.0 == NormalizeLongitude(-180.0) assert -179.0 == NormalizeLongitude(181.0) assert (0.0, 0.0) == NormalizeLatLng(360.0, 0.0) assert (0.0, 0.0) == NormalizeLatLng(-360.0, 0.0) assert (85.0, 180.0) == NormalizeLatLng(95.0, 0.0) assert (-85.0, -170.0) == NormalizeLatLng(-95.0, 10.0) assert (90.0, 10.0) == NormalizeLatLng(90.0, 10.0) assert (-90.0, -10.0) == NormalizeLatLng(-90.0, -10.0) assert (0.0, -170.0) == NormalizeLatLng(-180.0, 10.0) assert (0.0, -170.0) == NormalizeLatLng(180.0, 10.0) assert (-90.0, 10.0) == NormalizeLatLng(270.0, 10.0) assert (90.0, 10.0) == NormalizeLatLng(-270.0, 10.0)
See: latLng
smart constructor.
Creates a value of LatLng
with the minimum fields required to make a request.
Use one of the following lenses to modify other fields as desired:
llLatitude :: Lens' LatLng (Maybe Double) Source
The latitude in degrees. It must be in the range [-90.0, +90.0].
llLongitude :: Lens' LatLng (Maybe Double) Source
The longitude in degrees. It must be in the range [-180.0, +180.0].
AttachmentInfo
data AttachmentInfo Source
A subset of attachment information served via the `beaconinfo.getforobserved` method, used when your users encounter your beacons.
See: attachmentInfo
smart constructor.
attachmentInfo :: AttachmentInfo Source
Creates a value of AttachmentInfo
with the minimum fields required to make a request.
Use one of the following lenses to modify other fields as desired:
aiData :: Lens' AttachmentInfo (Maybe Word8) Source
An opaque data container for client-provided data.
aiNamespacedType :: Lens' AttachmentInfo (Maybe Text) Source
Specifies what kind of attachment this is. Tells a client how to interpret the `data` field. Format is namespace/type, for example scrupulous-wombat-12345/welcome-message
BeaconProperties
data BeaconProperties Source
Properties of the beacon device, for example battery type or firmware version. Optional.
See: beaconProperties
smart constructor.
Creates a value of BeaconProperties
with the minimum fields required to make a request.
Use one of the following lenses to modify other fields as desired:
Empty
A generic empty message that you can re-use to avoid defining duplicated empty messages in your APIs. A typical example is to use it as the request or the response type of an API method. For instance: service Foo { rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty); } The JSON representation for `Empty` is empty JSON object `{}`.
See: empty
smart constructor.
DeleteAttachmentsResponse
data DeleteAttachmentsResponse Source
Response for a request to delete attachments.
See: deleteAttachmentsResponse
smart constructor.
deleteAttachmentsResponse :: DeleteAttachmentsResponse Source
Creates a value of DeleteAttachmentsResponse
with the minimum fields required to make a request.
Use one of the following lenses to modify other fields as desired:
darNumDeleted :: Lens' DeleteAttachmentsResponse (Maybe Int32) Source
The number of attachments that were deleted.
GetInfoForObservedBeaconsRequest
data GetInfoForObservedBeaconsRequest Source
Request for beacon and attachment information about beacons that a mobile client has encountered "in the wild".
See: getInfoForObservedBeaconsRequest
smart constructor.
getInfoForObservedBeaconsRequest :: GetInfoForObservedBeaconsRequest Source
Creates a value of GetInfoForObservedBeaconsRequest
with the minimum fields required to make a request.
Use one of the following lenses to modify other fields as desired:
gifobrObservations :: Lens' GetInfoForObservedBeaconsRequest [Observation] Source
The beacons that the client has encountered. At least one must be given.
gifobrNamespacedTypes :: Lens' GetInfoForObservedBeaconsRequest [Text] Source
Specifies what kind of attachments to include in the response. When given, the response will include only attachments of the given types. When empty, no attachments will be returned. Must be in the format namespace/type. Accepts `*` to specify all types in all namespaces. Optional.
Namespace
An attachment namespace defines read and write access for all the attachments created under it. Each namespace is globally unique, and owned by one project which is the only project that can create attachments under it.
See: namespace
smart constructor.
Creates a value of Namespace
with the minimum fields required to make a request.
Use one of the following lenses to modify other fields as desired:
nServingVisibility :: Lens' Namespace (Maybe Text) Source
Specifies what clients may receive attachments under this namespace via `beaconinfo.getforobserved`.
nNamespaceName :: Lens' Namespace (Maybe Text) Source
Resource name of this namespace. Namespaces names have the format: namespaces/namespace.
ListNamespacesResponse
data ListNamespacesResponse Source
Response to ListNamespacesRequest that contains all the project's namespaces.
See: listNamespacesResponse
smart constructor.
listNamespacesResponse :: ListNamespacesResponse Source
Creates a value of ListNamespacesResponse
with the minimum fields required to make a request.
Use one of the following lenses to modify other fields as desired:
lnrNamespaces :: Lens' ListNamespacesResponse [Namespace] Source
The attachments that corresponded to the request params.
Date
Represents a whole calendar date, e.g. date of birth. The time of day and time zone are either specified elsewhere or are not significant. The date is relative to the Proleptic Gregorian Calendar. The day may be 0 to represent a year and month where the day is not significant, e.g. credit card expiration date. The year may be 0 to represent a month and day independent of year, e.g. anniversary date. Related types are [google.type.TimeOfDay][] and `google.protobuf.Timestamp`.
See: date
smart constructor.
dDay :: Lens' Date (Maybe Int32) Source
Day of month. Must be from 1 to 31 and valid for the year and month, or 0 if specifying a year/month where the day is not sigificant.
dYear :: Lens' Date (Maybe Int32) Source
Year of date. Must be from 1 to 9,999, or 0 if specifying a date without a year.
Beacon
Details of a beacon device.
See: beacon
smart constructor.
Creates a value of Beacon
with the minimum fields required to make a request.
Use one of the following lenses to modify other fields as desired:
bLatLng :: Lens' Beacon (Maybe LatLng) Source
The location of the beacon, expressed as a latitude and longitude pair. This location is given when the beacon is registered or updated. It does not necessarily indicate the actual current location of the beacon. Optional.
bBeaconName :: Lens' Beacon (Maybe Text) Source
Resource name of this beacon. A beacon name has the format "beacons/N!beaconId" where the beaconId is the base16 ID broadcast by the beacon and N is a code for the beacon's type. Possible values are `3` for Eddystone, `1` for iBeacon, or `5` for AltBeacon. This field must be left empty when registering. After reading a beacon, clients can use the name for future operations.
bIndoorLevel :: Lens' Beacon (Maybe IndoorLevel) Source
The indoor level information for this beacon, if known. As returned by the Google Maps API. Optional.
bExpectedStability :: Lens' Beacon (Maybe Text) Source
Expected location stability. This is set when the beacon is registered or updated, not automatically detected in any way. Optional.
bDescription :: Lens' Beacon (Maybe Text) Source
Free text used to identify and describe the beacon. Maximum length 140 characters. Optional.
bPlaceId :: Lens' Beacon (Maybe Text) Source
The Google Places API Place ID of the place where the beacon is deployed. This is given when the beacon is registered or updated, not automatically detected in any way. Optional.
bAdvertisedId :: Lens' Beacon (Maybe AdvertisedId) Source
The identifier of a beacon as advertised by it. This field must be populated when registering. It may be empty when updating a beacon record because it is ignored in updates.
bProperties :: Lens' Beacon (Maybe BeaconProperties) Source
Properties of the beacon device, for example battery type or firmware version. Optional.
Diagnostics
data Diagnostics Source
Diagnostics for a single beacon.
See: diagnostics
smart constructor.
diagnostics :: Diagnostics Source
Creates a value of Diagnostics
with the minimum fields required to make a request.
Use one of the following lenses to modify other fields as desired:
dAlerts :: Lens' Diagnostics [Text] Source
An unordered list of Alerts that the beacon has.
dBeaconName :: Lens' Diagnostics (Maybe Text) Source
Resource name of the beacon.
dEstimatedLowBatteryDate :: Lens' Diagnostics (Maybe Date) Source
The date when the battery is expected to be low. If the value is missing then there is no estimate for when the battery will be low. This value is only an estimate, not an exact date.
ListBeaconAttachmentsResponse
data ListBeaconAttachmentsResponse Source
Response to ListBeaconAttachments that contains the requested attachments.
See: listBeaconAttachmentsResponse
smart constructor.
listBeaconAttachmentsResponse :: ListBeaconAttachmentsResponse Source
Creates a value of ListBeaconAttachmentsResponse
with the minimum fields required to make a request.
Use one of the following lenses to modify other fields as desired:
lbarAttachments :: Lens' ListBeaconAttachmentsResponse [BeaconAttachment] Source
The attachments that corresponded to the request params.
IndoorLevel
data IndoorLevel Source
Indoor level, a human-readable string as returned by Google Maps APIs, useful to indicate which floor of a building a beacon is located on.
See: indoorLevel
smart constructor.
indoorLevel :: IndoorLevel Source
Creates a value of IndoorLevel
with the minimum fields required to make a request.
Use one of the following lenses to modify other fields as desired:
BeaconInfo
data BeaconInfo Source
A subset of beacon information served via the `beaconinfo.getforobserved` method, which you call when users of your app encounter your beacons.
See: beaconInfo
smart constructor.
beaconInfo :: BeaconInfo Source
Creates a value of BeaconInfo
with the minimum fields required to make a request.
Use one of the following lenses to modify other fields as desired:
biAttachments :: Lens' BeaconInfo [AttachmentInfo] Source
Attachments matching the type(s) requested. May be empty if no attachment types were requested, or if none matched.
biBeaconName :: Lens' BeaconInfo (Maybe Text) Source
The name under which the beacon is registered.
biDescription :: Lens' BeaconInfo (Maybe Text) Source
Free text used to identify or describe the beacon in a registered establishment. For example: "entrance", "room 101", etc. May be empty.
biAdvertisedId :: Lens' BeaconInfo (Maybe AdvertisedId) Source
The ID advertised by the beacon.
Observation
data Observation Source
Represents one beacon observed once.
See: observation
smart constructor.
observation :: Observation Source
Creates a value of Observation
with the minimum fields required to make a request.
Use one of the following lenses to modify other fields as desired:
oTelemetry :: Lens' Observation (Maybe Word8) Source
The array of telemetry bytes received from the beacon. The server is responsible for parsing it. This field may frequently be empty, as with a beacon that transmits telemetry only occasionally.
oTimestampMs :: Lens' Observation (Maybe Text) Source
Time when the beacon was observed. Being sourced from a mobile device, this time may be suspect.
oAdvertisedId :: Lens' Observation (Maybe AdvertisedId) Source
The ID advertised by the beacon the client has encountered. Required.
BeaconAttachment
data BeaconAttachment Source
Project-specific data associated with a beacon.
See: beaconAttachment
smart constructor.
beaconAttachment :: BeaconAttachment Source
Creates a value of BeaconAttachment
with the minimum fields required to make a request.
Use one of the following lenses to modify other fields as desired:
baData :: Lens' BeaconAttachment (Maybe Word8) Source
An opaque data container for client-provided data. Must be base64 encoded in HTTP requests, and will be so encoded (with padding) in responses. Required.
baAttachmentName :: Lens' BeaconAttachment (Maybe Text) Source
Resource name of this attachment. Attachment names have the format: beacons/beacon_id/attachments/attachment_id. Leave this empty on creation.
baNamespacedType :: Lens' BeaconAttachment (Maybe Text) Source
Specifies what kind of attachment this is. Tells a client how to interpret the `data` field. Format is namespace/type. Namespace provides type separation between clients. Type describes the type of `data`, for use by the client when parsing the `data` field. Required.
ListDiagnosticsResponse
data ListDiagnosticsResponse Source
Response that contains the requested diagnostics.
See: listDiagnosticsResponse
smart constructor.
listDiagnosticsResponse :: ListDiagnosticsResponse Source
Creates a value of ListDiagnosticsResponse
with the minimum fields required to make a request.
Use one of the following lenses to modify other fields as desired:
ldrNextPageToken :: Lens' ListDiagnosticsResponse (Maybe Text) Source
Token that can be used for pagination. Returned only if the request matches more beacons than can be returned in this response.
ldrDiagnostics :: Lens' ListDiagnosticsResponse [Diagnostics] Source
The diagnostics matching the given request.
AdvertisedId
data AdvertisedId Source
Defines a unique identifier of a beacon as broadcast by the device.
See: advertisedId
smart constructor.
advertisedId :: AdvertisedId Source
Creates a value of AdvertisedId
with the minimum fields required to make a request.
Use one of the following lenses to modify other fields as desired:
aiId :: Lens' AdvertisedId (Maybe Word8) Source
The actual beacon identifier, as broadcast by the beacon hardware. Must be base64 encoded in HTTP requests, and will be so encoded (with padding) in responses. The base64 encoding should be of the binary byte-stream and not any textual (such as hex) representation thereof. Required.
ListBeaconsResponse
data ListBeaconsResponse Source
Response that contains list beacon results and pagination help.
See: listBeaconsResponse
smart constructor.
listBeaconsResponse :: ListBeaconsResponse Source
Creates a value of ListBeaconsResponse
with the minimum fields required to make a request.
Use one of the following lenses to modify other fields as desired:
lbrNextPageToken :: Lens' ListBeaconsResponse (Maybe Text) Source
An opaque pagination token that the client may provide in their next request to retrieve the next page of results.
lbrBeacons :: Lens' ListBeaconsResponse [Beacon] Source
The beacons that matched the search criteria.
lbrTotalCount :: Lens' ListBeaconsResponse (Maybe Int64) Source
Estimate of the total number of beacons matched by the query. Higher values may be less accurate.
GetInfoForObservedBeaconsResponse
data GetInfoForObservedBeaconsResponse Source
Information about the requested beacons, optionally including attachment data.
See: getInfoForObservedBeaconsResponse
smart constructor.
getInfoForObservedBeaconsResponse :: GetInfoForObservedBeaconsResponse Source
Creates a value of GetInfoForObservedBeaconsResponse
with the minimum fields required to make a request.
Use one of the following lenses to modify other fields as desired:
gifobrBeacons :: Lens' GetInfoForObservedBeaconsResponse [BeaconInfo] Source
Public information about beacons. May be empty if the request matched no beacons.