Class: Infrawrench::PostureSettingsNamespace
- Inherits:
-
Object
- Object
- Infrawrench::PostureSettingsNamespace
- Defined in:
- lib/infrawrench/client.rb,
sig/infrawrench/sdk.rbs
Overview
client.posture.settings
Instance Method Summary collapse
-
#get(org_id: nil, request_options: nil) ⇒ Hash
Get the organization's posture alert settings.
-
#initialize(transport) ⇒ PostureSettingsNamespace
constructor
private
A new instance of PostureSettingsNamespace.
-
#update(org_id: nil, body: nil, request_options: nil) ⇒ Hash
Update the posture alert settings.
Constructor Details
#initialize(transport) ⇒ PostureSettingsNamespace
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Returns a new instance of PostureSettingsNamespace.
4585 4586 4587 |
# File 'lib/infrawrench/client.rb', line 4585 def initialize(transport) @transport = transport end |
Instance Method Details
#get(org_id: nil, request_options: nil) ⇒ Hash
Get the organization's posture alert settings
Whether the poller's daily posture alert scan is enabled. An organization that never saved reads the shipped defaults (enabled).
Requires permission: org:settings:write.
GET /api/org/orgId/posture/settings
4604 4605 4606 4607 4608 4609 4610 4611 |
# File 'lib/infrawrench/client.rb', line 4604 def get(org_id: nil, request_options: nil) @transport.request( http_method: "GET", path: "/api/org/{orgId}/posture/settings", path_params: { "orgId" => org_id }, request_options: ) end |
#update(org_id: nil, body: nil, request_options: nil) ⇒ Hash
Update the posture alert settings
Saving never resets the alert cooldown.
Requires permission: org:settings:write.
PUT /api/org/orgId/posture/settings
Raises on 400: Bad request
4630 4631 4632 4633 4634 4635 4636 4637 4638 |
# File 'lib/infrawrench/client.rb', line 4630 def update(org_id: nil, body: nil, request_options: nil) @transport.request( http_method: "PUT", path: "/api/org/{orgId}/posture/settings", path_params: { "orgId" => org_id }, body: body, request_options: ) end |