Class: Google::Apis::HealthV4::EndpointAuthorization
- Inherits:
-
Object
- Object
- Google::Apis::HealthV4::EndpointAuthorization
- Includes:
- Core::Hashable, Core::JsonObjectSupport
- Defined in:
- lib/google/apis/health_v4/classes.rb,
lib/google/apis/health_v4/representations.rb,
lib/google/apis/health_v4/representations.rb
Overview
Authorization mechanism for a subscriber endpoint. For all requests sent by
the Webhooks service, the JSON payload is cryptographically signed. The
signature is delivered in the GOOGLE-HEALTH-API-SIGNATURE HTTP header. This
is an ECDSA (NIST P256) signature of the JSON payload. Clients must verify
this signature using Google Health API's public key to confirm the payload was
sent by the Health API.
Instance Attribute Summary collapse
-
#secret ⇒ String
Required.
-
#secret_set ⇒ Boolean
(also: #secret_set?)
Output only.
Instance Method Summary collapse
-
#initialize(**args) ⇒ EndpointAuthorization
constructor
A new instance of EndpointAuthorization.
-
#update!(**args) ⇒ Object
Update properties of this object.
Constructor Details
#initialize(**args) ⇒ EndpointAuthorization
Returns a new instance of EndpointAuthorization.
2137 2138 2139 |
# File 'lib/google/apis/health_v4/classes.rb', line 2137 def initialize(**args) update!(**args) end |
Instance Attribute Details
#secret ⇒ String
Required. Input only. Provides a client-provided secret that will be sent with
each notification to the subscriber endpoint using the "Authorization" header.
The value must include the authorization scheme, e.g., "Bearer " or "Basic ",
as it will be used as the full Authorization header value. This secret is used
by the API to test the endpoint during CreateSubscriber and
UpdateSubscriber calls, and will be sent in the Authorization header for
all subsequent webhook notifications to this endpoint.
Corresponds to the JSON property secret
2129 2130 2131 |
# File 'lib/google/apis/health_v4/classes.rb', line 2129 def secret @secret end |
#secret_set ⇒ Boolean Also known as: secret_set?
Output only. Whether the secret is set.
Corresponds to the JSON property secretSet
2134 2135 2136 |
# File 'lib/google/apis/health_v4/classes.rb', line 2134 def secret_set @secret_set end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
2142 2143 2144 2145 |
# File 'lib/google/apis/health_v4/classes.rb', line 2142 def update!(**args) @secret = args[:secret] if args.key?(:secret) @secret_set = args[:secret_set] if args.key?(:secret_set) end |