JSON representation |
---|
{ "type": enum ( |
Fields | |
---|---|
type |
The type of this barcode. |
renderEncoding |
The render encoding for the barcode. When specified, barcode is rendered in the given encoding. Otherwise best known encoding is chosen by Google. |
valuePattern |
String encoded barcode value. This string supports the following substitutions: * {totp_value_n}: Replaced with the TOTP value (see TotpDetails.parameters). * {totp_timestamp_millis}: Replaced with the timestamp (millis since epoch) at which the barcode was generated. * {totp_timestamp_seconds}: Replaced with the timestamp (seconds since epoch) at which the barcode was generated. |
totpDetails |
Details used to evaluate the {totp_value_n} substitutions. |
alternateText |
An optional text that will override the default text that shows under the barcode. This field is intended for a human readable equivalent of the barcode value, used when the barcode cannot be scanned. |
showCodeText |
Optional text that will be shown when the barcode is hidden behind a click action. This happens in cases where a pass has Smart Tap enabled. If not specified, a default is chosen by Google. |
initialRotatingBarcodeValues |
Input only. NOTE: This feature is only available for the transit vertical. Optional set of initial rotating barcode values. This allows a small subset of barcodes to be included with the object. Further rotating barcode values must be uploaded with the UploadRotatingBarcodeValues endpoint. |
TotpDetails
Configuration for the time-based OTP substitutions. See https://tools.ietf.org/html/rfc6238
JSON representation |
---|
{ "periodMillis": string, "algorithm": enum ( |
Fields | |
---|---|
periodMillis |
The time interval used for the TOTP value generation, in milliseconds. |
algorithm |
The TOTP algorithm used to generate the OTP. |
parameters[] |
The TOTP parameters for each of the {totp_value_*} substitutions. The TotpParameters at index n is used for the {totp_value_n} substitution. |
TotpAlgorithm
Enums | |
---|---|
TOTP_ALGORITHM_UNSPECIFIED |
|
TOTP_SHA1 |
TOTP algorithm from RFC 6238 with the SHA1 hash function |
TotpParameters
Configuration for the key and value length. See https://www.rfc-editor.org/rfc/rfc4226#section-5.3
JSON representation |
---|
{ "key": string, "valueLength": integer } |
Fields | |
---|---|
key |
The secret key used for the TOTP value generation, encoded as a Base16 string. |
valueLength |
The length of the TOTP value in decimal digits. |
RotatingBarcodeValues
A payload containing many barcode values and start date/time.
JSON representation |
---|
{ "startDateTime": string, "values": [ string ], "periodMillis": string } |
Fields | |
---|---|
startDateTime |
Required. The date/time the first barcode is valid from. Barcodes will be rotated through using periodMillis defined on the object's RotatingBarcodeValueInfo. This is an ISO 8601 extended format date/time, with an offset. Time may be specified up to nanosecond precision. Offsets may be specified with seconds precision (even though offset seconds is not part of ISO 8601). For example:
|
values[] |
Required. The values to encode in the barcode. At least one value is required. |
periodMillis |
Required. The amount of time each barcode is valid for. |