Data

class oci.audit.models.Data(**kwargs)

Bases: object

The payload of the event. Information within data comes from the resource emitting the event.

Example:

{ "eventGroupingId": null, "eventName": "GetInstance", "compartmentId": "ocid1.tenancy.oc1..<unique_ID>", "compartmentName": "compartmentA", "resourceName": "my_instance", "resourceId": "ocid1.instance.oc1.phx.<unique_ID>", "availabilityDomain": "<availability_domain>", "freeformTags": null, "definedTags": null, "identity": { "principalName": "ExampleName", "principalId": "ocid1.user.oc1..<unique_ID>", "authType": "natv", "callerName": null, "callerId": null, "tenantId": "ocid1.tenancy.oc1..<unique_ID>", "ipAddress": "172.24.80.88", "credentials": null, "userAgent": "Jersey/2.23 (HttpUrlConnection 1.8.0_212)", "consoleSessionId": null }, "request": { "id": "<unique_ID>", "path": "/20160918/instances/ocid1.instance.oc1.phx.<unique_ID>", "action": "GET", "parameters": {}, "headers": { "opc-principal": [ "{"tenantId":"ocid1.tenancy.oc1..<unique_ID>","subjectId":"ocid1.user.oc1..<unique_ID>","claims":[{"key":"pstype","value":"natv","issuer":"authService.oracle.com"},{"key":"h_host","value":"iaas.r2.oracleiaas.com","issuer":"h"},{"key":"h_opc-request-id","value":"<unique_ID>","issuer":"h"},{"key":"ptype","value":"user","issuer":"authService.oracle.com"},{"key":"h_date","value":"Wed, 18 Sep 2019 00:10:58 UTC","issuer":"h"},{"key":"h_accept","value":"application/json","issuer":"h"},{"key":"authorization","value":"Signature headers=\"date (request-target) host accept opc-request-id\",keyId=\"ocid1.tenancy.oc1..<unique_ID>/ocid1.user.oc1..<unique_ID>/8c:b4:5f:18:e7:ec:db:08:b8:fa:d2:2a:7d:11:76:ac\",algorithm=\"rsa-pss-sha256\",signature=\"<unique_ID>\",version=\"1\"","issuer":"h"},{"key":"h_(request-target)","value":"get /20160918/instances/ocid1.instance.oc1.phx.<unique_ID>","issuer":"h"}]}" ], "Accept": [ "application/json" ], "X-Oracle-Auth-Client-CN": [ "splat-proxy-se-02302.node.ad2.r2" ], "X-Forwarded-Host": [ "compute-api.svc.ad1.r2" ], "Connection": [ "close" ], "User-Agent": [ "Jersey/2.23 (HttpUrlConnection 1.8.0_212)" ], "X-Forwarded-For": [ "172.24.80.88" ], "X-Real-IP": [ "172.24.80.88" ], "oci-original-url": [ "https://iaas.r2.oracleiaas.com/20160918/instances/ocid1.instance.oc1.phx.<unique_ID>" ], "opc-request-id": [ "<unique_ID>" ], "Date": [ "Wed, 18 Sep 2019 00:10:58 UTC" ] } }, "response": { "status": "200", "responseTime": "2019-09-18T00:10:59.278Z", "headers": { "ETag": [ "<unique_ID>" ], "Connection": [ "close" ], "Content-Length": [ "1828" ], "opc-request-id": [ "<unique_ID>" ], "Date": [ "Wed, 18 Sep 2019 00:10:59 GMT" ], "Content-Type": [ "application/json" ] }, "payload": { "resourceName": "my_instance", "id": "ocid1.instance.oc1.phx.<unique_ID>" }, "message": null }, "stateChange": { "previous": null, "current": null }, "additionalDetails": { "imageId": "ocid1.image.oc1.phx.<unique_ID>", "shape": "VM.Standard1.1", "type": "CustomerVmi" } } -----

__init__(**kwargs)

Initializes a new Data object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class):

Parameters:
  • event_grouping_id (str) -- The value to assign to the event_grouping_id property of this Data.
  • event_name (str) -- The value to assign to the event_name property of this Data.
  • compartment_id (str) -- The value to assign to the compartment_id property of this Data.
  • compartment_name (str) -- The value to assign to the compartment_name property of this Data.
  • resource_name (str) -- The value to assign to the resource_name property of this Data.
  • resource_id (str) -- The value to assign to the resource_id property of this Data.
  • availability_domain (str) -- The value to assign to the availability_domain property of this Data.
  • freeform_tags (dict(str, str)) -- The value to assign to the freeform_tags property of this Data.
  • defined_tags (dict(str, dict(str, object))) -- The value to assign to the defined_tags property of this Data.
  • identity (Identity) -- The value to assign to the identity property of this Data.
  • request (Request) -- The value to assign to the request property of this Data.
  • response (Response) -- The value to assign to the response property of this Data.
  • state_change (StateChange) -- The value to assign to the state_change property of this Data.
  • additional_details (dict(str, object)) -- The value to assign to the additional_details property of this Data.
additional_details

Gets the additional_details of this Data. A container object for attribues unique to the resource emitting the event.

Example:

{
"imageId": "ocid1.image.oc1.phx.<unique_ID>", "shape": "VM.Standard1.1", "type": "CustomerVmi"

}

Returns:The additional_details of this Data.
Return type:dict(str, object)
availability_domain

Gets the availability_domain of this Data. The availability domain where the resource resides.

Returns:The availability_domain of this Data.
Return type:str
compartment_id

Gets the compartment_id of this Data. The OCID of the compartment of the resource emitting the event.

Returns:The compartment_id of this Data.
Return type:str
compartment_name

Gets the compartment_name of this Data. The name of the compartment. This value is the friendly name associated with compartmentId. This value can change, but the service logs the value that appeared at the time of the audit event.

Example: CompartmentA

Returns:The compartment_name of this Data.
Return type:str
defined_tags

Gets the defined_tags of this Data. Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags.

Example: {"Operations": {"CostCenter": "42"}}

Returns:The defined_tags of this Data.
Return type:dict(str, dict(str, object))
event_grouping_id

Gets the event_grouping_id of this Data. This value links multiple audit events that are part of the same API operation. For example, a long running API operations that emit an event at the start and the end of an operation would use the same value in this field for both events.

Returns:The event_grouping_id of this Data.
Return type:str
event_name

Gets the event_name of this Data. Name of the API operation that generated this event.

Example: GetInstance

Returns:The event_name of this Data.
Return type:str
freeform_tags

Gets the freeform_tags of this Data. Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. Exists for cross-compatibility only. For more information, see Resource Tags.

Example: {"Department": "Finance"}

Returns:The freeform_tags of this Data.
Return type:dict(str, str)
identity

Gets the identity of this Data.

Returns:The identity of this Data.
Return type:Identity
request

Gets the request of this Data.

Returns:The request of this Data.
Return type:Request
resource_id

Gets the resource_id of this Data. An OCID or some other ID for the resource emitting the event.

Returns:The resource_id of this Data.
Return type:str
resource_name

Gets the resource_name of this Data. The name of the resource emitting the event.

Returns:The resource_name of this Data.
Return type:str
response

Gets the response of this Data.

Returns:The response of this Data.
Return type:Response
state_change

Gets the state_change of this Data.

Returns:The state_change of this Data.
Return type:StateChange