Class UserEventService.UserEventServiceBase
Base class for server-side implementations of UserEventService
Inheritance
Inherited Members
Namespace: Google.Cloud.Retail.V2
Assembly: Google.Cloud.Retail.V2.dll
Syntax
[BindServiceMethod(typeof(UserEventService), "BindService")]
public abstract class UserEventServiceBase
Methods
CollectUserEvent(CollectUserEventRequest, ServerCallContext)
Writes a single user event from the browser. This uses a GET request to due to browser restriction of POST-ing to a 3rd party domain.
This method is used only by the Retail API JavaScript pixel and Google Tag Manager. Users should not call this method directly.
Declaration
public virtual Task<HttpBody> CollectUserEvent(CollectUserEventRequest request, ServerCallContext context)
Parameters
Type | Name | Description |
---|---|---|
CollectUserEventRequest | request | The request received from the client. |
ServerCallContext | context | The context of the server-side call handler being invoked. |
Returns
Type | Description |
---|---|
System.Threading.Tasks.Task<HttpBody> | The response to send back to the client (wrapped by a task). |
ImportUserEvents(ImportUserEventsRequest, ServerCallContext)
Bulk import of User events. Request processing might be synchronous. Events that already exist are skipped. Use this method for backfilling historical user events.
Operation.response is of type ImportResponse. Note that it is possible for a subset of the items to be successfully inserted. Operation.metadata is of type ImportMetadata.
Declaration
public virtual Task<Operation> ImportUserEvents(ImportUserEventsRequest request, ServerCallContext context)
Parameters
Type | Name | Description |
---|---|---|
ImportUserEventsRequest | request | The request received from the client. |
ServerCallContext | context | The context of the server-side call handler being invoked. |
Returns
Type | Description |
---|---|
System.Threading.Tasks.Task<Operation> | The response to send back to the client (wrapped by a task). |
PurgeUserEvents(PurgeUserEventsRequest, ServerCallContext)
Deletes permanently all user events specified by the filter provided. Depending on the number of events specified by the filter, this operation could take hours or days to complete. To test a filter, use the list command first.
Declaration
public virtual Task<Operation> PurgeUserEvents(PurgeUserEventsRequest request, ServerCallContext context)
Parameters
Type | Name | Description |
---|---|---|
PurgeUserEventsRequest | request | The request received from the client. |
ServerCallContext | context | The context of the server-side call handler being invoked. |
Returns
Type | Description |
---|---|
System.Threading.Tasks.Task<Operation> | The response to send back to the client (wrapped by a task). |
RejoinUserEvents(RejoinUserEventsRequest, ServerCallContext)
Triggers a user event rejoin operation with latest product catalog. Events will not be annotated with detailed product information if product is missing from the catalog at the time the user event is ingested, and these events are stored as unjoined events with a limited usage on training and serving. This API can be used to trigger a 'join' operation on specified events with latest version of product catalog. It can also be used to correct events joined with wrong product catalog.
Declaration
public virtual Task<Operation> RejoinUserEvents(RejoinUserEventsRequest request, ServerCallContext context)
Parameters
Type | Name | Description |
---|---|---|
RejoinUserEventsRequest | request | The request received from the client. |
ServerCallContext | context | The context of the server-side call handler being invoked. |
Returns
Type | Description |
---|---|
System.Threading.Tasks.Task<Operation> | The response to send back to the client (wrapped by a task). |
WriteUserEvent(WriteUserEventRequest, ServerCallContext)
Writes a single user event.
Declaration
public virtual Task<UserEvent> WriteUserEvent(WriteUserEventRequest request, ServerCallContext context)
Parameters
Type | Name | Description |
---|---|---|
WriteUserEventRequest | request | The request received from the client. |
ServerCallContext | context | The context of the server-side call handler being invoked. |
Returns
Type | Description |
---|---|
System.Threading.Tasks.Task<UserEvent> | The response to send back to the client (wrapped by a task). |