api: google.golang.org/api/alertcenter/v1beta1 Index | Files

package alertcenter

import "google.golang.org/api/alertcenter/v1beta1"

Package alertcenter provides access to the G Suite Alert Center API.

For product documentation, see: https://developers.google.com/admin-sdk/alertcenter/

Creating a client

Usage example:

import "google.golang.org/api/alertcenter/v1beta1"
...
ctx := context.Background()
alertcenterService, err := alertcenter.NewService(ctx)

In this example, Google Application Default Credentials are used for authentication.

For information on how to create and obtain Application Default Credentials, see https://developers.google.com/identity/protocols/application-default-credentials.

Other authentication options

To use an API key for authentication (note: some APIs do not support API keys), use option.WithAPIKey:

alertcenterService, err := alertcenter.NewService(ctx, option.WithAPIKey("AIza..."))

To use an OAuth token (e.g., a user token obtained via a three-legged OAuth flow), use option.WithTokenSource:

config := &oauth2.Config{...}
// ...
token, err := config.Exchange(ctx, ...)
alertcenterService, err := alertcenter.NewService(ctx, option.WithTokenSource(config.TokenSource(ctx, token)))

See https://godoc.org/google.golang.org/api/option/ for details on options.

Index

Package Files

alertcenter-gen.go

Constants

const (
    // See and delete your domain's G Suite alerts, and send alert feedback
    AppsAlertsScope = "https://www.googleapis.com/auth/apps.alerts"
)

OAuth2 scopes used by this API.

type AccountWarning Uses

type AccountWarning struct {
    // Email: Required. The email of the user that this event belongs to.
    Email string `json:"email,omitempty"`

    // LoginDetails: Optional. Details of the login action associated with
    // the warning event.
    // This is only available for:
    //
    // * Suspicious login
    // * Suspicious login (less secure app)
    // * Suspicious programmatic login
    // * User suspended (suspicious activity)
    LoginDetails *LoginDetails `json:"loginDetails,omitempty"`

    // ForceSendFields is a list of field names (e.g. "Email") to
    // unconditionally include in API requests. By default, fields with
    // empty values are omitted from API requests. However, any non-pointer,
    // non-interface field appearing in ForceSendFields will be sent to the
    // server regardless of whether the field is empty or not. This may be
    // used to include empty fields in Patch requests.
    ForceSendFields []string `json:"-"`

    // NullFields is a list of field names (e.g. "Email") to include in API
    // requests with the JSON null value. By default, fields with empty
    // values are omitted from API requests. However, any field with an
    // empty value appearing in NullFields will be sent to the server as
    // null. It is an error if a field in this list has a non-empty value.
    // This may be used to include null fields in Patch requests.
    NullFields []string `json:"-"`
}

AccountWarning: Alerts for user account warning events.

func (*AccountWarning) MarshalJSON Uses

func (s *AccountWarning) MarshalJSON() ([]byte, error)

type ActivityRule Uses

type ActivityRule struct {
    // ActionNames: List of action names associated with the rule threshold.
    ActionNames []string `json:"actionNames,omitempty"`

    // CreateTime: Rule create timestamp.
    CreateTime string `json:"createTime,omitempty"`

    // Description: Description of the rule.
    Description string `json:"description,omitempty"`

    // DisplayName: Alert display name.
    DisplayName string `json:"displayName,omitempty"`

    // Name: Rule name.
    Name string `json:"name,omitempty"`

    // Query: Query that is used to get the data from the associated source.
    Query string `json:"query,omitempty"`

    // SupersededAlerts: List of alert ids superseded by this alert. It is
    // used to indicate that
    // this alert is essentially extension of superseded alerts and we found
    // the
    // relationship after creating these alerts.
    SupersededAlerts []string `json:"supersededAlerts,omitempty"`

    // SupersedingAlert: Alert id superseding this alert. It is used to
    // indicate that superseding
    // alert is essentially extension of this alert and we found the
    // relationship
    // after creating both alerts.
    SupersedingAlert string `json:"supersedingAlert,omitempty"`

    // Threshold: Alert threshold is for example “COUNT > 5”.
    Threshold string `json:"threshold,omitempty"`

    // TriggerSource: The trigger sources for this rule.
    //
    // * GMAIL_EVENTS
    // * DEVICE_EVENTS
    // * USER_EVENTS
    TriggerSource string `json:"triggerSource,omitempty"`

    // UpdateTime: The timestamp of the last update to the rule.
    UpdateTime string `json:"updateTime,omitempty"`

    // WindowSize: Rule window size. Possible values are 1 hour or 24 hours.
    WindowSize string `json:"windowSize,omitempty"`

    // ForceSendFields is a list of field names (e.g. "ActionNames") to
    // unconditionally include in API requests. By default, fields with
    // empty values are omitted from API requests. However, any non-pointer,
    // non-interface field appearing in ForceSendFields will be sent to the
    // server regardless of whether the field is empty or not. This may be
    // used to include empty fields in Patch requests.
    ForceSendFields []string `json:"-"`

    // NullFields is a list of field names (e.g. "ActionNames") to include
    // in API requests with the JSON null value. By default, fields with
    // empty values are omitted from API requests. However, any field with
    // an empty value appearing in NullFields will be sent to the server as
    // null. It is an error if a field in this list has a non-empty value.
    // This may be used to include null fields in Patch requests.
    NullFields []string `json:"-"`
}

ActivityRule: Alerts from G Suite Security Center rules service configured by admin.

func (*ActivityRule) MarshalJSON Uses

func (s *ActivityRule) MarshalJSON() ([]byte, error)

type Alert Uses

type Alert struct {
    // AlertId: Output only. The unique identifier for the alert.
    AlertId string `json:"alertId,omitempty"`

    // CreateTime: Output only. The time this alert was created.
    CreateTime string `json:"createTime,omitempty"`

    // CustomerId: Output only. The unique identifier of the Google account
    // of the customer.
    CustomerId string `json:"customerId,omitempty"`

    // Data: Optional. The data associated with this alert, for
    // example
    // google.apps.alertcenter.type.DeviceCompromised.
    Data googleapi.RawMessage `json:"data,omitempty"`

    // Deleted: Output only. `True` if this alert is marked for deletion.
    Deleted bool `json:"deleted,omitempty"`

    // EndTime: Optional. The time the event that caused this alert ceased
    // being active.
    // If provided, the end time must not be earlier than the start time.
    // If not provided, it indicates an ongoing alert.
    EndTime string `json:"endTime,omitempty"`

    // SecurityInvestigationToolLink: Output only. An optional
    // [Security Investigation
    // Tool](https://support.google.com/a/answer/7575955)
    // query for this alert.
    SecurityInvestigationToolLink string `json:"securityInvestigationToolLink,omitempty"`

    // Source: Required. A unique identifier for the system that reported
    // the alert.
    // This is output only after alert is created.
    //
    // Supported sources are any of the following:
    //
    // * Google Operations
    // * Mobile device management
    // * Gmail phishing
    // * Domain wide takeout
    // * Government attack warning
    // * Google identity
    Source string `json:"source,omitempty"`

    // StartTime: Required. The time the event that caused this alert was
    // started or
    // detected.
    StartTime string `json:"startTime,omitempty"`

    // Type: Required. The type of the alert.
    // This is output only after alert is created.
    // For a list of available alert types see
    // [G Suite Alert types](/admin-sdk/alertcenter/reference/alert-types).
    Type string `json:"type,omitempty"`

    // UpdateTime: Output only. The time this alert was last updated.
    UpdateTime string `json:"updateTime,omitempty"`

    // ServerResponse contains the HTTP response code and headers from the
    // server.
    googleapi.ServerResponse `json:"-"`

    // ForceSendFields is a list of field names (e.g. "AlertId") to
    // unconditionally include in API requests. By default, fields with
    // empty values are omitted from API requests. However, any non-pointer,
    // non-interface field appearing in ForceSendFields will be sent to the
    // server regardless of whether the field is empty or not. This may be
    // used to include empty fields in Patch requests.
    ForceSendFields []string `json:"-"`

    // NullFields is a list of field names (e.g. "AlertId") to include in
    // API requests with the JSON null value. By default, fields with empty
    // values are omitted from API requests. However, any field with an
    // empty value appearing in NullFields will be sent to the server as
    // null. It is an error if a field in this list has a non-empty value.
    // This may be used to include null fields in Patch requests.
    NullFields []string `json:"-"`
}

Alert: An alert affecting a customer.

func (*Alert) MarshalJSON Uses

func (s *Alert) MarshalJSON() ([]byte, error)

type AlertFeedback Uses

type AlertFeedback struct {
    // AlertId: Output only. The alert identifier.
    AlertId string `json:"alertId,omitempty"`

    // CreateTime: Output only. The time this feedback was created.
    CreateTime string `json:"createTime,omitempty"`

    // CustomerId: Output only. The unique identifier of the Google account
    // of the customer.
    CustomerId string `json:"customerId,omitempty"`

    // Email: Output only. The email of the user that provided the feedback.
    Email string `json:"email,omitempty"`

    // FeedbackId: Output only. The unique identifier for the feedback.
    FeedbackId string `json:"feedbackId,omitempty"`

    // Type: Required. The type of the feedback.
    //
    // Possible values:
    //   "ALERT_FEEDBACK_TYPE_UNSPECIFIED" - The feedback type is not
    // specified.
    //   "NOT_USEFUL" - The alert report is not useful.
    //   "SOMEWHAT_USEFUL" - The alert report is somewhat useful.
    //   "VERY_USEFUL" - The alert report is very useful.
    Type string `json:"type,omitempty"`

    // ServerResponse contains the HTTP response code and headers from the
    // server.
    googleapi.ServerResponse `json:"-"`

    // ForceSendFields is a list of field names (e.g. "AlertId") to
    // unconditionally include in API requests. By default, fields with
    // empty values are omitted from API requests. However, any non-pointer,
    // non-interface field appearing in ForceSendFields will be sent to the
    // server regardless of whether the field is empty or not. This may be
    // used to include empty fields in Patch requests.
    ForceSendFields []string `json:"-"`

    // NullFields is a list of field names (e.g. "AlertId") to include in
    // API requests with the JSON null value. By default, fields with empty
    // values are omitted from API requests. However, any field with an
    // empty value appearing in NullFields will be sent to the server as
    // null. It is an error if a field in this list has a non-empty value.
    // This may be used to include null fields in Patch requests.
    NullFields []string `json:"-"`
}

AlertFeedback: A customer feedback about an alert.

func (*AlertFeedback) MarshalJSON Uses

func (s *AlertFeedback) MarshalJSON() ([]byte, error)

type AlertsDeleteCall Uses

type AlertsDeleteCall struct {
    // contains filtered or unexported fields
}

func (*AlertsDeleteCall) Context Uses

func (c *AlertsDeleteCall) Context(ctx context.Context) *AlertsDeleteCall

Context sets the context to be used in this call's Do method. Any pending HTTP request will be aborted if the provided context is canceled.

func (*AlertsDeleteCall) CustomerId Uses

func (c *AlertsDeleteCall) CustomerId(customerId string) *AlertsDeleteCall

CustomerId sets the optional parameter "customerId": The unique identifier of the G Suite organization account of the customer the alert is associated with. Inferred from the caller identity if not provided.

func (*AlertsDeleteCall) Do Uses

func (c *AlertsDeleteCall) Do(opts ...googleapi.CallOption) (*Empty, error)

Do executes the "alertcenter.alerts.delete" call. Exactly one of *Empty or error will be non-nil. Any non-2xx status code is an error. Response headers are in either *Empty.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.

func (*AlertsDeleteCall) Fields Uses

func (c *AlertsDeleteCall) Fields(s ...googleapi.Field) *AlertsDeleteCall

Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.

func (*AlertsDeleteCall) Header Uses

func (c *AlertsDeleteCall) Header() http.Header

Header returns an http.Header that can be modified by the caller to add HTTP headers to the request.

type AlertsFeedbackCreateCall Uses

type AlertsFeedbackCreateCall struct {
    // contains filtered or unexported fields
}

func (*AlertsFeedbackCreateCall) Context Uses

func (c *AlertsFeedbackCreateCall) Context(ctx context.Context) *AlertsFeedbackCreateCall

Context sets the context to be used in this call's Do method. Any pending HTTP request will be aborted if the provided context is canceled.

func (*AlertsFeedbackCreateCall) CustomerId Uses

func (c *AlertsFeedbackCreateCall) CustomerId(customerId string) *AlertsFeedbackCreateCall

CustomerId sets the optional parameter "customerId": The unique identifier of the G Suite organization account of the customer the alert is associated with. Inferred from the caller identity if not provided.

func (*AlertsFeedbackCreateCall) Do Uses

func (c *AlertsFeedbackCreateCall) Do(opts ...googleapi.CallOption) (*AlertFeedback, error)

Do executes the "alertcenter.alerts.feedback.create" call. Exactly one of *AlertFeedback or error will be non-nil. Any non-2xx status code is an error. Response headers are in either *AlertFeedback.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.

func (*AlertsFeedbackCreateCall) Fields Uses

func (c *AlertsFeedbackCreateCall) Fields(s ...googleapi.Field) *AlertsFeedbackCreateCall

Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.

func (*AlertsFeedbackCreateCall) Header Uses

func (c *AlertsFeedbackCreateCall) Header() http.Header

Header returns an http.Header that can be modified by the caller to add HTTP headers to the request.

type AlertsFeedbackListCall Uses

type AlertsFeedbackListCall struct {
    // contains filtered or unexported fields
}

func (*AlertsFeedbackListCall) Context Uses

func (c *AlertsFeedbackListCall) Context(ctx context.Context) *AlertsFeedbackListCall

Context sets the context to be used in this call's Do method. Any pending HTTP request will be aborted if the provided context is canceled.

func (*AlertsFeedbackListCall) CustomerId Uses

func (c *AlertsFeedbackListCall) CustomerId(customerId string) *AlertsFeedbackListCall

CustomerId sets the optional parameter "customerId": The unique identifier of the G Suite organization account of the customer the alert feedback are associated with. Inferred from the caller identity if not provided.

func (*AlertsFeedbackListCall) Do Uses

func (c *AlertsFeedbackListCall) Do(opts ...googleapi.CallOption) (*ListAlertFeedbackResponse, error)

Do executes the "alertcenter.alerts.feedback.list" call. Exactly one of *ListAlertFeedbackResponse or error will be non-nil. Any non-2xx status code is an error. Response headers are in either *ListAlertFeedbackResponse.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.

func (*AlertsFeedbackListCall) Fields Uses

func (c *AlertsFeedbackListCall) Fields(s ...googleapi.Field) *AlertsFeedbackListCall

Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.

func (*AlertsFeedbackListCall) Filter Uses

func (c *AlertsFeedbackListCall) Filter(filter string) *AlertsFeedbackListCall

Filter sets the optional parameter "filter": A query string for filtering alert feedback results. For more details, see [Query filters](/admin-sdk/alertcenter/guides/query-filters) and [Supported query filter fields](/admin-sdk/alertcenter/reference/filter-fields#alerts.f eedback.list).

func (*AlertsFeedbackListCall) Header Uses

func (c *AlertsFeedbackListCall) Header() http.Header

Header returns an http.Header that can be modified by the caller to add HTTP headers to the request.

func (*AlertsFeedbackListCall) IfNoneMatch Uses

func (c *AlertsFeedbackListCall) IfNoneMatch(entityTag string) *AlertsFeedbackListCall

IfNoneMatch sets the optional parameter which makes the operation fail if the object's ETag matches the given value. This is useful for getting updates only after the object has changed since the last request. Use googleapi.IsNotModified to check whether the response error from Do is the result of In-None-Match.

type AlertsFeedbackService Uses

type AlertsFeedbackService struct {
    // contains filtered or unexported fields
}

func NewAlertsFeedbackService Uses

func NewAlertsFeedbackService(s *Service) *AlertsFeedbackService

func (*AlertsFeedbackService) Create Uses

func (r *AlertsFeedbackService) Create(alertId string, alertfeedback *AlertFeedback) *AlertsFeedbackCreateCall

Create: Creates new feedback for an alert. Attempting to create a feedback for a non-existent alert returns `NOT_FOUND` error.

func (*AlertsFeedbackService) List Uses

func (r *AlertsFeedbackService) List(alertId string) *AlertsFeedbackListCall

List: Lists all the feedback for an alert. Attempting to list feedbacks for a non-existent alert returns `NOT_FOUND` error.

type AlertsGetCall Uses

type AlertsGetCall struct {
    // contains filtered or unexported fields
}

func (*AlertsGetCall) Context Uses

func (c *AlertsGetCall) Context(ctx context.Context) *AlertsGetCall

Context sets the context to be used in this call's Do method. Any pending HTTP request will be aborted if the provided context is canceled.

func (*AlertsGetCall) CustomerId Uses

func (c *AlertsGetCall) CustomerId(customerId string) *AlertsGetCall

CustomerId sets the optional parameter "customerId": The unique identifier of the G Suite organization account of the customer the alert is associated with. Inferred from the caller identity if not provided.

func (*AlertsGetCall) Do Uses

func (c *AlertsGetCall) Do(opts ...googleapi.CallOption) (*Alert, error)

Do executes the "alertcenter.alerts.get" call. Exactly one of *Alert or error will be non-nil. Any non-2xx status code is an error. Response headers are in either *Alert.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.

func (*AlertsGetCall) Fields Uses

func (c *AlertsGetCall) Fields(s ...googleapi.Field) *AlertsGetCall

Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.

func (*AlertsGetCall) Header Uses

func (c *AlertsGetCall) Header() http.Header

Header returns an http.Header that can be modified by the caller to add HTTP headers to the request.

func (*AlertsGetCall) IfNoneMatch Uses

func (c *AlertsGetCall) IfNoneMatch(entityTag string) *AlertsGetCall

IfNoneMatch sets the optional parameter which makes the operation fail if the object's ETag matches the given value. This is useful for getting updates only after the object has changed since the last request. Use googleapi.IsNotModified to check whether the response error from Do is the result of In-None-Match.

type AlertsListCall Uses

type AlertsListCall struct {
    // contains filtered or unexported fields
}

func (*AlertsListCall) Context Uses

func (c *AlertsListCall) Context(ctx context.Context) *AlertsListCall

Context sets the context to be used in this call's Do method. Any pending HTTP request will be aborted if the provided context is canceled.

func (*AlertsListCall) CustomerId Uses

func (c *AlertsListCall) CustomerId(customerId string) *AlertsListCall

CustomerId sets the optional parameter "customerId": The unique identifier of the G Suite organization account of the customer the alerts are associated with. Inferred from the caller identity if not provided.

func (*AlertsListCall) Do Uses

func (c *AlertsListCall) Do(opts ...googleapi.CallOption) (*ListAlertsResponse, error)

Do executes the "alertcenter.alerts.list" call. Exactly one of *ListAlertsResponse or error will be non-nil. Any non-2xx status code is an error. Response headers are in either *ListAlertsResponse.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.

func (*AlertsListCall) Fields Uses

func (c *AlertsListCall) Fields(s ...googleapi.Field) *AlertsListCall

Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.

func (*AlertsListCall) Filter Uses

func (c *AlertsListCall) Filter(filter string) *AlertsListCall

Filter sets the optional parameter "filter": A query string for filtering alert results. For more details, see [Query filters](/admin-sdk/alertcenter/guides/query-filters) and [Supported query filter fields](/admin-sdk/alertcenter/reference/filter-fields#alerts.l ist).

func (*AlertsListCall) Header Uses

func (c *AlertsListCall) Header() http.Header

Header returns an http.Header that can be modified by the caller to add HTTP headers to the request.

func (*AlertsListCall) IfNoneMatch Uses

func (c *AlertsListCall) IfNoneMatch(entityTag string) *AlertsListCall

IfNoneMatch sets the optional parameter which makes the operation fail if the object's ETag matches the given value. This is useful for getting updates only after the object has changed since the last request. Use googleapi.IsNotModified to check whether the response error from Do is the result of In-None-Match.

func (*AlertsListCall) OrderBy Uses

func (c *AlertsListCall) OrderBy(orderBy string) *AlertsListCall

OrderBy sets the optional parameter "orderBy": The sort order of the list results. If not specified results may be returned in arbitrary order. You can sort the results in descending order based on the creation timestamp using `order_by="create_time desc". Currently, supported sorting are `create_time asc`, `create_time desc`, `update_time desc`

func (*AlertsListCall) PageSize Uses

func (c *AlertsListCall) PageSize(pageSize int64) *AlertsListCall

PageSize sets the optional parameter "pageSize": The requested page size. Server may return fewer items than requested. If unspecified, server picks an appropriate default.

func (*AlertsListCall) PageToken Uses

func (c *AlertsListCall) PageToken(pageToken string) *AlertsListCall

PageToken sets the optional parameter "pageToken": A token identifying a page of results the server should return. If empty, a new iteration is started. To continue an iteration, pass in the value from the previous ListAlertsResponse's next_page_token field.

func (*AlertsListCall) Pages Uses

func (c *AlertsListCall) Pages(ctx context.Context, f func(*ListAlertsResponse) error) error

Pages invokes f for each page of results. A non-nil error returned from f will halt the iteration. The provided context supersedes any context provided to the Context method.

type AlertsService Uses

type AlertsService struct {
    Feedback *AlertsFeedbackService
    // contains filtered or unexported fields
}

func NewAlertsService Uses

func NewAlertsService(s *Service) *AlertsService

func (*AlertsService) Delete Uses

func (r *AlertsService) Delete(alertId string) *AlertsDeleteCall

Delete: Marks the specified alert for deletion. An alert that has been marked for deletion is removed from Alert Center after 30 days. Marking an alert for deletion has no effect on an alert which has already been marked for deletion. Attempting to mark a nonexistent alert for deletion results in a `NOT_FOUND` error.

func (*AlertsService) Get Uses

func (r *AlertsService) Get(alertId string) *AlertsGetCall

Get: Gets the specified alert. Attempting to get a nonexistent alert returns `NOT_FOUND` error.

func (*AlertsService) List Uses

func (r *AlertsService) List() *AlertsListCall

List: Lists the alerts.

func (*AlertsService) Undelete Uses

func (r *AlertsService) Undelete(alertId string, undeletealertrequest *UndeleteAlertRequest) *AlertsUndeleteCall

Undelete: Restores, or "undeletes", an alert that was marked for deletion within the past 30 days. Attempting to undelete an alert which was marked for deletion over 30 days ago (which has been removed from the Alert Center database) or a nonexistent alert returns a `NOT_FOUND` error. Attempting to undelete an alert which has not been marked for deletion has no effect.

type AlertsUndeleteCall Uses

type AlertsUndeleteCall struct {
    // contains filtered or unexported fields
}

func (*AlertsUndeleteCall) Context Uses

func (c *AlertsUndeleteCall) Context(ctx context.Context) *AlertsUndeleteCall

Context sets the context to be used in this call's Do method. Any pending HTTP request will be aborted if the provided context is canceled.

func (*AlertsUndeleteCall) Do Uses

func (c *AlertsUndeleteCall) Do(opts ...googleapi.CallOption) (*Alert, error)

Do executes the "alertcenter.alerts.undelete" call. Exactly one of *Alert or error will be non-nil. Any non-2xx status code is an error. Response headers are in either *Alert.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.

func (*AlertsUndeleteCall) Fields Uses

func (c *AlertsUndeleteCall) Fields(s ...googleapi.Field) *AlertsUndeleteCall

Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.

func (*AlertsUndeleteCall) Header Uses

func (c *AlertsUndeleteCall) Header() http.Header

Header returns an http.Header that can be modified by the caller to add HTTP headers to the request.

type Attachment Uses

type Attachment struct {
    // Csv: A CSV file attachment.
    Csv *Csv `json:"csv,omitempty"`

    // ForceSendFields is a list of field names (e.g. "Csv") to
    // unconditionally include in API requests. By default, fields with
    // empty values are omitted from API requests. However, any non-pointer,
    // non-interface field appearing in ForceSendFields will be sent to the
    // server regardless of whether the field is empty or not. This may be
    // used to include empty fields in Patch requests.
    ForceSendFields []string `json:"-"`

    // NullFields is a list of field names (e.g. "Csv") to include in API
    // requests with the JSON null value. By default, fields with empty
    // values are omitted from API requests. However, any field with an
    // empty value appearing in NullFields will be sent to the server as
    // null. It is an error if a field in this list has a non-empty value.
    // This may be used to include null fields in Patch requests.
    NullFields []string `json:"-"`
}

Attachment: Attachment with application-specific information about an alert.

func (*Attachment) MarshalJSON Uses

func (s *Attachment) MarshalJSON() ([]byte, error)

type BadWhitelist Uses

type BadWhitelist struct {
    // DomainId: The domain ID.
    DomainId *DomainId `json:"domainId,omitempty"`

    // MaliciousEntity: The entity whose actions triggered a Gmail phishing
    // alert.
    MaliciousEntity *MaliciousEntity `json:"maliciousEntity,omitempty"`

    // Messages: The list of messages contained by this alert.
    Messages []*GmailMessageInfo `json:"messages,omitempty"`

    // SourceIp: The source IP address of the malicious email, for
    // example,
    // `127.0.0.1`.
    SourceIp string `json:"sourceIp,omitempty"`

    // ForceSendFields is a list of field names (e.g. "DomainId") to
    // unconditionally include in API requests. By default, fields with
    // empty values are omitted from API requests. However, any non-pointer,
    // non-interface field appearing in ForceSendFields will be sent to the
    // server regardless of whether the field is empty or not. This may be
    // used to include empty fields in Patch requests.
    ForceSendFields []string `json:"-"`

    // NullFields is a list of field names (e.g. "DomainId") to include in
    // API requests with the JSON null value. By default, fields with empty
    // values are omitted from API requests. However, any field with an
    // empty value appearing in NullFields will be sent to the server as
    // null. It is an error if a field in this list has a non-empty value.
    // This may be used to include null fields in Patch requests.
    NullFields []string `json:"-"`
}

BadWhitelist: Alert for setting the domain or IP that malicious email comes from as whitelisted domain or IP in Gmail advanced settings.

func (*BadWhitelist) MarshalJSON Uses

func (s *BadWhitelist) MarshalJSON() ([]byte, error)

type CloudPubsubTopic Uses

type CloudPubsubTopic struct {
    // PayloadFormat: Optional. The format of the payload that would be
    // sent.
    // If not specified the format will be JSON.
    //
    // Possible values:
    //   "PAYLOAD_FORMAT_UNSPECIFIED" - Payload format is not specified
    // (will use JSON as default).
    //   "JSON" - Use JSON.
    PayloadFormat string `json:"payloadFormat,omitempty"`

    // TopicName: The `name` field of a Cloud Pubsub
    // [Topic]
    // (https://cloud.google.com/pubsub/docs/reference/rest/v1/projec
    // ts.topics#Topic).
    TopicName string `json:"topicName,omitempty"`

    // ForceSendFields is a list of field names (e.g. "PayloadFormat") to
    // unconditionally include in API requests. By default, fields with
    // empty values are omitted from API requests. However, any non-pointer,
    // non-interface field appearing in ForceSendFields will be sent to the
    // server regardless of whether the field is empty or not. This may be
    // used to include empty fields in Patch requests.
    ForceSendFields []string `json:"-"`

    // NullFields is a list of field names (e.g. "PayloadFormat") to include
    // in API requests with the JSON null value. By default, fields with
    // empty values are omitted from API requests. However, any field with
    // an empty value appearing in NullFields will be sent to the server as
    // null. It is an error if a field in this list has a non-empty value.
    // This may be used to include null fields in Patch requests.
    NullFields []string `json:"-"`
}

CloudPubsubTopic: A reference to a Cloud Pubsub topic.

To register for notifications, the owner of the topic must grant `alerts-api-push-notifications@system.gserviceaccount.com` the

`projects.topics.publish` permission.

func (*CloudPubsubTopic) MarshalJSON Uses

func (s *CloudPubsubTopic) MarshalJSON() ([]byte, error)

type Csv Uses

type Csv struct {
    // DataRows: The list of data rows in a CSV file, as string arrays
    // rather than as a
    // single comma-separated string.
    DataRows []*CsvRow `json:"dataRows,omitempty"`

    // Headers: The list of headers for data columns in a CSV file.
    Headers []string `json:"headers,omitempty"`

    // ForceSendFields is a list of field names (e.g. "DataRows") to
    // unconditionally include in API requests. By default, fields with
    // empty values are omitted from API requests. However, any non-pointer,
    // non-interface field appearing in ForceSendFields will be sent to the
    // server regardless of whether the field is empty or not. This may be
    // used to include empty fields in Patch requests.
    ForceSendFields []string `json:"-"`

    // NullFields is a list of field names (e.g. "DataRows") to include in
    // API requests with the JSON null value. By default, fields with empty
    // values are omitted from API requests. However, any field with an
    // empty value appearing in NullFields will be sent to the server as
    // null. It is an error if a field in this list has a non-empty value.
    // This may be used to include null fields in Patch requests.
    NullFields []string `json:"-"`
}

Csv: A representation of a CSV file attachment, as a list of column headers and a list of data rows.

func (*Csv) MarshalJSON Uses

func (s *Csv) MarshalJSON() ([]byte, error)

type CsvRow Uses

type CsvRow struct {
    // Entries: The data entries in a CSV file row, as a string array rather
    // than a
    // single comma-separated string.
    Entries []string `json:"entries,omitempty"`

    // ForceSendFields is a list of field names (e.g. "Entries") to
    // unconditionally include in API requests. By default, fields with
    // empty values are omitted from API requests. However, any non-pointer,
    // non-interface field appearing in ForceSendFields will be sent to the
    // server regardless of whether the field is empty or not. This may be
    // used to include empty fields in Patch requests.
    ForceSendFields []string `json:"-"`

    // NullFields is a list of field names (e.g. "Entries") to include in
    // API requests with the JSON null value. By default, fields with empty
    // values are omitted from API requests. However, any field with an
    // empty value appearing in NullFields will be sent to the server as
    // null. It is an error if a field in this list has a non-empty value.
    // This may be used to include null fields in Patch requests.
    NullFields []string `json:"-"`
}

CsvRow: A representation of a single data row in a CSV file.

func (*CsvRow) MarshalJSON Uses

func (s *CsvRow) MarshalJSON() ([]byte, error)

type DeviceCompromised Uses

type DeviceCompromised struct {
    // Email: The email of the user this alert was created for.
    Email string `json:"email,omitempty"`

    // Events: Required. The list of security events.
    Events []*DeviceCompromisedSecurityDetail `json:"events,omitempty"`

    // ForceSendFields is a list of field names (e.g. "Email") to
    // unconditionally include in API requests. By default, fields with
    // empty values are omitted from API requests. However, any non-pointer,
    // non-interface field appearing in ForceSendFields will be sent to the
    // server regardless of whether the field is empty or not. This may be
    // used to include empty fields in Patch requests.
    ForceSendFields []string `json:"-"`

    // NullFields is a list of field names (e.g. "Email") to include in API
    // requests with the JSON null value. By default, fields with empty
    // values are omitted from API requests. However, any field with an
    // empty value appearing in NullFields will be sent to the server as
    // null. It is an error if a field in this list has a non-empty value.
    // This may be used to include null fields in Patch requests.
    NullFields []string `json:"-"`
}

DeviceCompromised: A mobile device compromised alert. Derived from audit logs.

func (*DeviceCompromised) MarshalJSON Uses

func (s *DeviceCompromised) MarshalJSON() ([]byte, error)

type DeviceCompromisedSecurityDetail Uses

type DeviceCompromisedSecurityDetail struct {
    // DeviceCompromisedState: The device compromised state. Possible values
    // are "Compromised" or
    // "Not Compromised".
    DeviceCompromisedState string `json:"deviceCompromisedState,omitempty"`

    // DeviceId: Required. The device ID.
    DeviceId string `json:"deviceId,omitempty"`

    // DeviceModel: The model of the device.
    DeviceModel string `json:"deviceModel,omitempty"`

    // DeviceType: The type of the device.
    DeviceType string `json:"deviceType,omitempty"`

    // IosVendorId: Required for iOS, empty for others.
    IosVendorId string `json:"iosVendorId,omitempty"`

    // ResourceId: The device resource ID.
    ResourceId string `json:"resourceId,omitempty"`

    // SerialNumber: The serial number of the device.
    SerialNumber string `json:"serialNumber,omitempty"`

    // ForceSendFields is a list of field names (e.g.
    // "DeviceCompromisedState") to unconditionally include in API requests.
    // By default, fields with empty values are omitted from API requests.
    // However, any non-pointer, non-interface field appearing in
    // ForceSendFields will be sent to the server regardless of whether the
    // field is empty or not. This may be used to include empty fields in
    // Patch requests.
    ForceSendFields []string `json:"-"`

    // NullFields is a list of field names (e.g. "DeviceCompromisedState")
    // to include in API requests with the JSON null value. By default,
    // fields with empty values are omitted from API requests. However, any
    // field with an empty value appearing in NullFields will be sent to the
    // server as null. It is an error if a field in this list has a
    // non-empty value. This may be used to include null fields in Patch
    // requests.
    NullFields []string `json:"-"`
}

DeviceCompromisedSecurityDetail: Detailed information of a single MDM device compromised event.

func (*DeviceCompromisedSecurityDetail) MarshalJSON Uses

func (s *DeviceCompromisedSecurityDetail) MarshalJSON() ([]byte, error)

type DomainId Uses

type DomainId struct {
    // CustomerPrimaryDomain: The primary domain for the customer.
    CustomerPrimaryDomain string `json:"customerPrimaryDomain,omitempty"`

    // ForceSendFields is a list of field names (e.g.
    // "CustomerPrimaryDomain") to unconditionally include in API requests.
    // By default, fields with empty values are omitted from API requests.
    // However, any non-pointer, non-interface field appearing in
    // ForceSendFields will be sent to the server regardless of whether the
    // field is empty or not. This may be used to include empty fields in
    // Patch requests.
    ForceSendFields []string `json:"-"`

    // NullFields is a list of field names (e.g. "CustomerPrimaryDomain") to
    // include in API requests with the JSON null value. By default, fields
    // with empty values are omitted from API requests. However, any field
    // with an empty value appearing in NullFields will be sent to the
    // server as null. It is an error if a field in this list has a
    // non-empty value. This may be used to include null fields in Patch
    // requests.
    NullFields []string `json:"-"`
}

DomainId: Domain ID of Gmail phishing alerts.

func (*DomainId) MarshalJSON Uses

func (s *DomainId) MarshalJSON() ([]byte, error)

type DomainWideTakeoutInitiated Uses

type DomainWideTakeoutInitiated struct {
    // Email: The email of the admin who initiated the takeout.
    Email string `json:"email,omitempty"`

    // TakeoutRequestId: The takeout request ID.
    TakeoutRequestId string `json:"takeoutRequestId,omitempty"`

    // ForceSendFields is a list of field names (e.g. "Email") to
    // unconditionally include in API requests. By default, fields with
    // empty values are omitted from API requests. However, any non-pointer,
    // non-interface field appearing in ForceSendFields will be sent to the
    // server regardless of whether the field is empty or not. This may be
    // used to include empty fields in Patch requests.
    ForceSendFields []string `json:"-"`

    // NullFields is a list of field names (e.g. "Email") to include in API
    // requests with the JSON null value. By default, fields with empty
    // values are omitted from API requests. However, any field with an
    // empty value appearing in NullFields will be sent to the server as
    // null. It is an error if a field in this list has a non-empty value.
    // This may be used to include null fields in Patch requests.
    NullFields []string `json:"-"`
}

DomainWideTakeoutInitiated: A takeout operation for the entire domain was initiated by an admin. Derived from audit logs.

func (*DomainWideTakeoutInitiated) MarshalJSON Uses

func (s *DomainWideTakeoutInitiated) MarshalJSON() ([]byte, error)

type Empty Uses

type Empty struct {
    // ServerResponse contains the HTTP response code and headers from the
    // server.
    googleapi.ServerResponse `json:"-"`
}

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 `{}`.

type GmailMessageInfo Uses

type GmailMessageInfo struct {
    // AttachmentsSha256Hash: The `SHA256` hash of email's attachment and
    // all MIME parts.
    AttachmentsSha256Hash []string `json:"attachmentsSha256Hash,omitempty"`

    // Date: The date the malicious email was sent.
    Date string `json:"date,omitempty"`

    // Md5HashMessageBody: The hash of the message body text.
    Md5HashMessageBody string `json:"md5HashMessageBody,omitempty"`

    // Md5HashSubject: The MD5 Hash of email's subject (only available for
    // reported emails).
    Md5HashSubject string `json:"md5HashSubject,omitempty"`

    // MessageBodySnippet: The snippet of the message body text (only
    // available for reported emails).
    MessageBodySnippet string `json:"messageBodySnippet,omitempty"`

    // MessageId: The message ID.
    MessageId string `json:"messageId,omitempty"`

    // Recipient: The recipient of this email.
    Recipient string `json:"recipient,omitempty"`

    // SubjectText: The email subject text (only available for reported
    // emails).
    SubjectText string `json:"subjectText,omitempty"`

    // ForceSendFields is a list of field names (e.g.
    // "AttachmentsSha256Hash") to unconditionally include in API requests.
    // By default, fields with empty values are omitted from API requests.
    // However, any non-pointer, non-interface field appearing in
    // ForceSendFields will be sent to the server regardless of whether the
    // field is empty or not. This may be used to include empty fields in
    // Patch requests.
    ForceSendFields []string `json:"-"`

    // NullFields is a list of field names (e.g. "AttachmentsSha256Hash") to
    // include in API requests with the JSON null value. By default, fields
    // with empty values are omitted from API requests. However, any field
    // with an empty value appearing in NullFields will be sent to the
    // server as null. It is an error if a field in this list has a
    // non-empty value. This may be used to include null fields in Patch
    // requests.
    NullFields []string `json:"-"`
}

GmailMessageInfo: Details of a message in phishing spike alert.

func (*GmailMessageInfo) MarshalJSON Uses

func (s *GmailMessageInfo) MarshalJSON() ([]byte, error)

type GoogleOperations Uses

type GoogleOperations struct {
    // AffectedUserEmails: The list of emails which correspond to the users
    // directly affected by the
    // incident.
    AffectedUserEmails []string `json:"affectedUserEmails,omitempty"`

    // AttachmentData: Optional. Application-specific data for an incident,
    // provided when the
    // G Suite application which reported the incident cannot be
    // completely
    // restored to a valid state.
    AttachmentData *Attachment `json:"attachmentData,omitempty"`

    // Description: A detailed, freeform incident description.
    Description string `json:"description,omitempty"`

    // Title: A one-line incident description.
    Title string `json:"title,omitempty"`

    // ForceSendFields is a list of field names (e.g. "AffectedUserEmails")
    // to unconditionally include in API requests. By default, fields with
    // empty values are omitted from API requests. However, any non-pointer,
    // non-interface field appearing in ForceSendFields will be sent to the
    // server regardless of whether the field is empty or not. This may be
    // used to include empty fields in Patch requests.
    ForceSendFields []string `json:"-"`

    // NullFields is a list of field names (e.g. "AffectedUserEmails") to
    // include in API requests with the JSON null value. By default, fields
    // with empty values are omitted from API requests. However, any field
    // with an empty value appearing in NullFields will be sent to the
    // server as null. It is an error if a field in this list has a
    // non-empty value. This may be used to include null fields in Patch
    // requests.
    NullFields []string `json:"-"`
}

GoogleOperations: An incident reported by Google Operations for a G Suite application.

func (*GoogleOperations) MarshalJSON Uses

func (s *GoogleOperations) MarshalJSON() ([]byte, error)

type ListAlertFeedbackResponse Uses

type ListAlertFeedbackResponse struct {
    // Feedback: The list of alert feedback.
    // Feedback entries for each alert are ordered by creation time
    // descending.
    Feedback []*AlertFeedback `json:"feedback,omitempty"`

    // ServerResponse contains the HTTP response code and headers from the
    // server.
    googleapi.ServerResponse `json:"-"`

    // ForceSendFields is a list of field names (e.g. "Feedback") to
    // unconditionally include in API requests. By default, fields with
    // empty values are omitted from API requests. However, any non-pointer,
    // non-interface field appearing in ForceSendFields will be sent to the
    // server regardless of whether the field is empty or not. This may be
    // used to include empty fields in Patch requests.
    ForceSendFields []string `json:"-"`

    // NullFields is a list of field names (e.g. "Feedback") to include in
    // API requests with the JSON null value. By default, fields with empty
    // values are omitted from API requests. However, any field with an
    // empty value appearing in NullFields will be sent to the server as
    // null. It is an error if a field in this list has a non-empty value.
    // This may be used to include null fields in Patch requests.
    NullFields []string `json:"-"`
}

ListAlertFeedbackResponse: Response message for an alert feedback listing request.

func (*ListAlertFeedbackResponse) MarshalJSON Uses

func (s *ListAlertFeedbackResponse) MarshalJSON() ([]byte, error)

type ListAlertsResponse Uses

type ListAlertsResponse struct {
    // Alerts: The list of alerts.
    Alerts []*Alert `json:"alerts,omitempty"`

    // NextPageToken: The token for the next page. If not empty, indicates
    // that there may be more
    // alerts that match the listing request; this value can be used in
    // a
    // subsequent ListAlertsRequest to get alerts continuing from last
    // result
    // of the current list call.
    NextPageToken string `json:"nextPageToken,omitempty"`

    // ServerResponse contains the HTTP response code and headers from the
    // server.
    googleapi.ServerResponse `json:"-"`

    // ForceSendFields is a list of field names (e.g. "Alerts") to
    // unconditionally include in API requests. By default, fields with
    // empty values are omitted from API requests. However, any non-pointer,
    // non-interface field appearing in ForceSendFields will be sent to the
    // server regardless of whether the field is empty or not. This may be
    // used to include empty fields in Patch requests.
    ForceSendFields []string `json:"-"`

    // NullFields is a list of field names (e.g. "Alerts") to include in API
    // requests with the JSON null value. By default, fields with empty
    // values are omitted from API requests. However, any field with an
    // empty value appearing in NullFields will be sent to the server as
    // null. It is an error if a field in this list has a non-empty value.
    // This may be used to include null fields in Patch requests.
    NullFields []string `json:"-"`
}

ListAlertsResponse: Response message for an alert listing request.

func (*ListAlertsResponse) MarshalJSON Uses

func (s *ListAlertsResponse) MarshalJSON() ([]byte, error)

type LoginDetails Uses

type LoginDetails struct {
    // IpAddress: Optional. The human-readable IP address (for
    // example,
    // `11.22.33.44`) that is associated with the warning event.
    IpAddress string `json:"ipAddress,omitempty"`

    // LoginTime: Optional. The successful login time that is associated
    // with the warning
    // event. This will not be present for blocked login attempts.
    LoginTime string `json:"loginTime,omitempty"`

    // ForceSendFields is a list of field names (e.g. "IpAddress") to
    // unconditionally include in API requests. By default, fields with
    // empty values are omitted from API requests. However, any non-pointer,
    // non-interface field appearing in ForceSendFields will be sent to the
    // server regardless of whether the field is empty or not. This may be
    // used to include empty fields in Patch requests.
    ForceSendFields []string `json:"-"`

    // NullFields is a list of field names (e.g. "IpAddress") to include in
    // API requests with the JSON null value. By default, fields with empty
    // values are omitted from API requests. However, any field with an
    // empty value appearing in NullFields will be sent to the server as
    // null. It is an error if a field in this list has a non-empty value.
    // This may be used to include null fields in Patch requests.
    NullFields []string `json:"-"`
}

LoginDetails: The details of the login action.

func (*LoginDetails) MarshalJSON Uses

func (s *LoginDetails) MarshalJSON() ([]byte, error)

type MailPhishing Uses

type MailPhishing struct {
    // DomainId: The domain ID.
    DomainId *DomainId `json:"domainId,omitempty"`

    // IsInternal: If `true`, the email originated from within the
    // organization.
    IsInternal bool `json:"isInternal,omitempty"`

    // MaliciousEntity: The entity whose actions triggered a Gmail phishing
    // alert.
    MaliciousEntity *MaliciousEntity `json:"maliciousEntity,omitempty"`

    // Messages: The list of messages contained by this alert.
    Messages []*GmailMessageInfo `json:"messages,omitempty"`

    // ForceSendFields is a list of field names (e.g. "DomainId") to
    // unconditionally include in API requests. By default, fields with
    // empty values are omitted from API requests. However, any non-pointer,
    // non-interface field appearing in ForceSendFields will be sent to the
    // server regardless of whether the field is empty or not. This may be
    // used to include empty fields in Patch requests.
    ForceSendFields []string `json:"-"`

    // NullFields is a list of field names (e.g. "DomainId") to include in
    // API requests with the JSON null value. By default, fields with empty
    // values are omitted from API requests. However, any field with an
    // empty value appearing in NullFields will be sent to the server as
    // null. It is an error if a field in this list has a non-empty value.
    // This may be used to include null fields in Patch requests.
    NullFields []string `json:"-"`
}

MailPhishing: Proto for all phishing alerts with common payload. Supported types are any of the following:

* User reported phishing * User reported spam spike * Suspicious message reported * Phishing reclassification * Malware reclassification

func (*MailPhishing) MarshalJSON Uses

func (s *MailPhishing) MarshalJSON() ([]byte, error)

type MaliciousEntity Uses

type MaliciousEntity struct {
    // DisplayName: The header from display name.
    DisplayName string `json:"displayName,omitempty"`

    // FromHeader: The sender email address.
    FromHeader string `json:"fromHeader,omitempty"`

    // ForceSendFields is a list of field names (e.g. "DisplayName") to
    // unconditionally include in API requests. By default, fields with
    // empty values are omitted from API requests. However, any non-pointer,
    // non-interface field appearing in ForceSendFields will be sent to the
    // server regardless of whether the field is empty or not. This may be
    // used to include empty fields in Patch requests.
    ForceSendFields []string `json:"-"`

    // NullFields is a list of field names (e.g. "DisplayName") to include
    // in API requests with the JSON null value. By default, fields with
    // empty values are omitted from API requests. However, any field with
    // an empty value appearing in NullFields will be sent to the server as
    // null. It is an error if a field in this list has a non-empty value.
    // This may be used to include null fields in Patch requests.
    NullFields []string `json:"-"`
}

MaliciousEntity: Entity whose actions triggered a Gmail phishing alert.

func (*MaliciousEntity) MarshalJSON Uses

func (s *MaliciousEntity) MarshalJSON() ([]byte, error)

type Notification Uses

type Notification struct {
    // CloudPubsubTopic: A Google Cloud Pub/sub topic destination.
    CloudPubsubTopic *CloudPubsubTopic `json:"cloudPubsubTopic,omitempty"`

    // ForceSendFields is a list of field names (e.g. "CloudPubsubTopic") to
    // unconditionally include in API requests. By default, fields with
    // empty values are omitted from API requests. However, any non-pointer,
    // non-interface field appearing in ForceSendFields will be sent to the
    // server regardless of whether the field is empty or not. This may be
    // used to include empty fields in Patch requests.
    ForceSendFields []string `json:"-"`

    // NullFields is a list of field names (e.g. "CloudPubsubTopic") to
    // include in API requests with the JSON null value. By default, fields
    // with empty values are omitted from API requests. However, any field
    // with an empty value appearing in NullFields will be sent to the
    // server as null. It is an error if a field in this list has a
    // non-empty value. This may be used to include null fields in Patch
    // requests.
    NullFields []string `json:"-"`
}

Notification: Settings for callback notifications. For more details see [G Suite Alert Notification](/admin-sdk/alertcenter/guides/notifications).

func (*Notification) MarshalJSON Uses

func (s *Notification) MarshalJSON() ([]byte, error)

type PhishingSpike Uses

type PhishingSpike struct {
    // DomainId: The domain ID.
    DomainId *DomainId `json:"domainId,omitempty"`

    // IsInternal: If `true`, the email originated from within the
    // organization.
    IsInternal bool `json:"isInternal,omitempty"`

    // MaliciousEntity: The entity whose actions triggered a Gmail phishing
    // alert.
    MaliciousEntity *MaliciousEntity `json:"maliciousEntity,omitempty"`

    // Messages: The list of messages contained by this alert.
    Messages []*GmailMessageInfo `json:"messages,omitempty"`

    // ForceSendFields is a list of field names (e.g. "DomainId") to
    // unconditionally include in API requests. By default, fields with
    // empty values are omitted from API requests. However, any non-pointer,
    // non-interface field appearing in ForceSendFields will be sent to the
    // server regardless of whether the field is empty or not. This may be
    // used to include empty fields in Patch requests.
    ForceSendFields []string `json:"-"`

    // NullFields is a list of field names (e.g. "DomainId") to include in
    // API requests with the JSON null value. By default, fields with empty
    // values are omitted from API requests. However, any field with an
    // empty value appearing in NullFields will be sent to the server as
    // null. It is an error if a field in this list has a non-empty value.
    // This may be used to include null fields in Patch requests.
    NullFields []string `json:"-"`
}

PhishingSpike: Alert for a spike in user reported phishing. <aside class="warning"><b>Warning</b>: This type has been deprecated. Use [MailPhishing](/admin-sdk/alertcenter/reference/rest/v1beta1/MailP hishing) instead.</aside>

func (*PhishingSpike) MarshalJSON Uses

func (s *PhishingSpike) MarshalJSON() ([]byte, error)

type Service Uses

type Service struct {
    BasePath  string // API endpoint base URL
    UserAgent string // optional additional User-Agent fragment

    Alerts *AlertsService

    V1beta1 *V1beta1Service
    // contains filtered or unexported fields
}

func New Uses

func New(client *http.Client) (*Service, error)

New creates a new Service. It uses the provided http.Client for requests.

Deprecated: please use NewService instead. To provide a custom HTTP client, use option.WithHTTPClient. If you are using google.golang.org/api/googleapis/transport.APIKey, use option.WithAPIKey with NewService instead.

func NewService Uses

func NewService(ctx context.Context, opts ...option.ClientOption) (*Service, error)

NewService creates a new Service.

type Settings Uses

type Settings struct {
    // Notifications: The list of notifications.
    Notifications []*Notification `json:"notifications,omitempty"`

    // ServerResponse contains the HTTP response code and headers from the
    // server.
    googleapi.ServerResponse `json:"-"`

    // ForceSendFields is a list of field names (e.g. "Notifications") to
    // unconditionally include in API requests. By default, fields with
    // empty values are omitted from API requests. However, any non-pointer,
    // non-interface field appearing in ForceSendFields will be sent to the
    // server regardless of whether the field is empty or not. This may be
    // used to include empty fields in Patch requests.
    ForceSendFields []string `json:"-"`

    // NullFields is a list of field names (e.g. "Notifications") to include
    // in API requests with the JSON null value. By default, fields with
    // empty values are omitted from API requests. However, any field with
    // an empty value appearing in NullFields will be sent to the server as
    // null. It is an error if a field in this list has a non-empty value.
    // This may be used to include null fields in Patch requests.
    NullFields []string `json:"-"`
}

Settings: Customer-level settings.

func (*Settings) MarshalJSON Uses

func (s *Settings) MarshalJSON() ([]byte, error)

type StateSponsoredAttack Uses

type StateSponsoredAttack struct {
    // Email: The email of the user this incident was created for.
    Email string `json:"email,omitempty"`

    // ForceSendFields is a list of field names (e.g. "Email") to
    // unconditionally include in API requests. By default, fields with
    // empty values are omitted from API requests. However, any non-pointer,
    // non-interface field appearing in ForceSendFields will be sent to the
    // server regardless of whether the field is empty or not. This may be
    // used to include empty fields in Patch requests.
    ForceSendFields []string `json:"-"`

    // NullFields is a list of field names (e.g. "Email") to include in API
    // requests with the JSON null value. By default, fields with empty
    // values are omitted from API requests. However, any field with an
    // empty value appearing in NullFields will be sent to the server as
    // null. It is an error if a field in this list has a non-empty value.
    // This may be used to include null fields in Patch requests.
    NullFields []string `json:"-"`
}

StateSponsoredAttack: A state-sponsored attack alert. Derived from audit logs.

func (*StateSponsoredAttack) MarshalJSON Uses

func (s *StateSponsoredAttack) MarshalJSON() ([]byte, error)

type SuspiciousActivity Uses

type SuspiciousActivity struct {
    // Email: The email of the user this alert was created for.
    Email string `json:"email,omitempty"`

    // Events: Required. The list of security events.
    Events []*SuspiciousActivitySecurityDetail `json:"events,omitempty"`

    // ForceSendFields is a list of field names (e.g. "Email") to
    // unconditionally include in API requests. By default, fields with
    // empty values are omitted from API requests. However, any non-pointer,
    // non-interface field appearing in ForceSendFields will be sent to the
    // server regardless of whether the field is empty or not. This may be
    // used to include empty fields in Patch requests.
    ForceSendFields []string `json:"-"`

    // NullFields is a list of field names (e.g. "Email") to include in API
    // requests with the JSON null value. By default, fields with empty
    // values are omitted from API requests. However, any field with an
    // empty value appearing in NullFields will be sent to the server as
    // null. It is an error if a field in this list has a non-empty value.
    // This may be used to include null fields in Patch requests.
    NullFields []string `json:"-"`
}

SuspiciousActivity: A mobile suspicious activity alert. Derived from audit logs.

func (*SuspiciousActivity) MarshalJSON Uses

func (s *SuspiciousActivity) MarshalJSON() ([]byte, error)

type SuspiciousActivitySecurityDetail Uses

type SuspiciousActivitySecurityDetail struct {
    // DeviceId: Required. The device ID.
    DeviceId string `json:"deviceId,omitempty"`

    // DeviceModel: The model of the device.
    DeviceModel string `json:"deviceModel,omitempty"`

    // DeviceProperty: The device property which was changed.
    DeviceProperty string `json:"deviceProperty,omitempty"`

    // DeviceType: The type of the device.
    DeviceType string `json:"deviceType,omitempty"`

    // IosVendorId: Required for iOS, empty for others.
    IosVendorId string `json:"iosVendorId,omitempty"`

    // NewValue: The new value of the device property after the change.
    NewValue string `json:"newValue,omitempty"`

    // OldValue: The old value of the device property before the change.
    OldValue string `json:"oldValue,omitempty"`

    // ResourceId: The device resource ID.
    ResourceId string `json:"resourceId,omitempty"`

    // SerialNumber: The serial number of the device.
    SerialNumber string `json:"serialNumber,omitempty"`

    // ForceSendFields is a list of field names (e.g. "DeviceId") to
    // unconditionally include in API requests. By default, fields with
    // empty values are omitted from API requests. However, any non-pointer,
    // non-interface field appearing in ForceSendFields will be sent to the
    // server regardless of whether the field is empty or not. This may be
    // used to include empty fields in Patch requests.
    ForceSendFields []string `json:"-"`

    // NullFields is a list of field names (e.g. "DeviceId") to include in
    // API requests with the JSON null value. By default, fields with empty
    // values are omitted from API requests. However, any field with an
    // empty value appearing in NullFields will be sent to the server as
    // null. It is an error if a field in this list has a non-empty value.
    // This may be used to include null fields in Patch requests.
    NullFields []string `json:"-"`
}

SuspiciousActivitySecurityDetail: Detailed information of a single MDM suspicious activity event.

func (*SuspiciousActivitySecurityDetail) MarshalJSON Uses

func (s *SuspiciousActivitySecurityDetail) MarshalJSON() ([]byte, error)

type UndeleteAlertRequest Uses

type UndeleteAlertRequest struct {
    // CustomerId: Optional. The unique identifier of the G Suite
    // organization account of the
    // customer the alert is associated with.
    // Inferred from the caller identity if not provided.
    CustomerId string `json:"customerId,omitempty"`

    // ForceSendFields is a list of field names (e.g. "CustomerId") to
    // unconditionally include in API requests. By default, fields with
    // empty values are omitted from API requests. However, any non-pointer,
    // non-interface field appearing in ForceSendFields will be sent to the
    // server regardless of whether the field is empty or not. This may be
    // used to include empty fields in Patch requests.
    ForceSendFields []string `json:"-"`

    // NullFields is a list of field names (e.g. "CustomerId") to include in
    // API requests with the JSON null value. By default, fields with empty
    // values are omitted from API requests. However, any field with an
    // empty value appearing in NullFields will be sent to the server as
    // null. It is an error if a field in this list has a non-empty value.
    // This may be used to include null fields in Patch requests.
    NullFields []string `json:"-"`
}

UndeleteAlertRequest: A request to undelete a specific alert that was marked for deletion.

func (*UndeleteAlertRequest) MarshalJSON Uses

func (s *UndeleteAlertRequest) MarshalJSON() ([]byte, error)

type V1beta1GetSettingsCall Uses

type V1beta1GetSettingsCall struct {
    // contains filtered or unexported fields
}

func (*V1beta1GetSettingsCall) Context Uses

func (c *V1beta1GetSettingsCall) Context(ctx context.Context) *V1beta1GetSettingsCall

Context sets the context to be used in this call's Do method. Any pending HTTP request will be aborted if the provided context is canceled.

func (*V1beta1GetSettingsCall) CustomerId Uses

func (c *V1beta1GetSettingsCall) CustomerId(customerId string) *V1beta1GetSettingsCall

CustomerId sets the optional parameter "customerId": The unique identifier of the G Suite organization account of the customer the alert settings are associated with. Inferred from the caller identity if not provided.

func (*V1beta1GetSettingsCall) Do Uses

func (c *V1beta1GetSettingsCall) Do(opts ...googleapi.CallOption) (*Settings, error)

Do executes the "alertcenter.getSettings" call. Exactly one of *Settings or error will be non-nil. Any non-2xx status code is an error. Response headers are in either *Settings.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.

func (*V1beta1GetSettingsCall) Fields Uses

func (c *V1beta1GetSettingsCall) Fields(s ...googleapi.Field) *V1beta1GetSettingsCall

Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.

func (*V1beta1GetSettingsCall) Header Uses

func (c *V1beta1GetSettingsCall) Header() http.Header

Header returns an http.Header that can be modified by the caller to add HTTP headers to the request.

func (*V1beta1GetSettingsCall) IfNoneMatch Uses

func (c *V1beta1GetSettingsCall) IfNoneMatch(entityTag string) *V1beta1GetSettingsCall

IfNoneMatch sets the optional parameter which makes the operation fail if the object's ETag matches the given value. This is useful for getting updates only after the object has changed since the last request. Use googleapi.IsNotModified to check whether the response error from Do is the result of In-None-Match.

type V1beta1Service Uses

type V1beta1Service struct {
    // contains filtered or unexported fields
}

func NewV1beta1Service Uses

func NewV1beta1Service(s *Service) *V1beta1Service

func (*V1beta1Service) GetSettings Uses

func (r *V1beta1Service) GetSettings() *V1beta1GetSettingsCall

GetSettings: Returns customer-level settings.

func (*V1beta1Service) UpdateSettings Uses

func (r *V1beta1Service) UpdateSettings(settings *Settings) *V1beta1UpdateSettingsCall

UpdateSettings: Updates the customer-level settings.

type V1beta1UpdateSettingsCall Uses

type V1beta1UpdateSettingsCall struct {
    // contains filtered or unexported fields
}

func (*V1beta1UpdateSettingsCall) Context Uses

func (c *V1beta1UpdateSettingsCall) Context(ctx context.Context) *V1beta1UpdateSettingsCall

Context sets the context to be used in this call's Do method. Any pending HTTP request will be aborted if the provided context is canceled.

func (*V1beta1UpdateSettingsCall) CustomerId Uses

func (c *V1beta1UpdateSettingsCall) CustomerId(customerId string) *V1beta1UpdateSettingsCall

CustomerId sets the optional parameter "customerId": The unique identifier of the G Suite organization account of the customer the alert settings are associated with. Inferred from the caller identity if not provided.

func (*V1beta1UpdateSettingsCall) Do Uses

func (c *V1beta1UpdateSettingsCall) Do(opts ...googleapi.CallOption) (*Settings, error)

Do executes the "alertcenter.updateSettings" call. Exactly one of *Settings or error will be non-nil. Any non-2xx status code is an error. Response headers are in either *Settings.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.

func (*V1beta1UpdateSettingsCall) Fields Uses

func (c *V1beta1UpdateSettingsCall) Fields(s ...googleapi.Field) *V1beta1UpdateSettingsCall

Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.

func (*V1beta1UpdateSettingsCall) Header Uses

func (c *V1beta1UpdateSettingsCall) Header() http.Header

Header returns an http.Header that can be modified by the caller to add HTTP headers to the request.

Package alertcenter imports 14 packages (graph). Updated 2019-07-18. Refresh now. Tools for package owners.