personalizeevents

package
v1.50.11 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 5, 2024 License: Apache-2.0 Imports: 10 Imported by: 22

Documentation

Overview

Package personalizeevents provides the client and types for making API requests to Amazon Personalize Events.

Amazon Personalize can consume real-time user event data, such as stream or click data, and use it for model training either alone or combined with historical data. For more information see Recording item interaction events (https://docs.aws.amazon.com/personalize/latest/dg/recording-item-interaction-events.html).

See https://docs.aws.amazon.com/goto/WebAPI/personalize-events-2018-03-22 for more information on this service.

See personalizeevents package documentation for more information. https://docs.aws.amazon.com/sdk-for-go/api/service/personalizeevents/

Using the Client

To contact Amazon Personalize Events with the SDK use the New function to create a new service client. With that client you can make API requests to the service. These clients are safe to use concurrently.

See the SDK's documentation for more information on how to use the SDK. https://docs.aws.amazon.com/sdk-for-go/api/

See aws.Config documentation for more information on configuring SDK clients. https://docs.aws.amazon.com/sdk-for-go/api/aws/#Config

See the Amazon Personalize Events client PersonalizeEvents for more information on creating client for this service. https://docs.aws.amazon.com/sdk-for-go/api/service/personalizeevents/#New

Index

Constants

View Source
const (

	// ErrCodeInvalidInputException for service response error code
	// "InvalidInputException".
	//
	// Provide a valid value for the field or parameter.
	ErrCodeInvalidInputException = "InvalidInputException"

	// ErrCodeResourceInUseException for service response error code
	// "ResourceInUseException".
	//
	// The specified resource is in use.
	ErrCodeResourceInUseException = "ResourceInUseException"

	// ErrCodeResourceNotFoundException for service response error code
	// "ResourceNotFoundException".
	//
	// Could not find the specified resource.
	ErrCodeResourceNotFoundException = "ResourceNotFoundException"
)
View Source
const (
	ServiceName = "Personalize Events" // Name of service.
	EndpointsID = "personalize-events" // ID to lookup a service endpoint with.
	ServiceID   = "Personalize Events" // ServiceID is a unique identifier of a specific service.
)

Service information constants

Variables

This section is empty.

Functions

This section is empty.

Types

type Action added in v1.48.4

type Action struct {

	// The ID associated with the action.
	//
	// ActionId is a required field
	ActionId *string `locationName:"actionId" min:"1" type:"string" required:"true"`

	// A string map of action-specific metadata. Each element in the map consists
	// of a key-value pair. For example, {"value": "100"}.
	//
	// The keys use camel case names that match the fields in the schema for the
	// Actions dataset. In the previous example, the value matches the 'VALUE' field
	// defined in the Actions schema. For categorical string data, to include multiple
	// categories for a single action, separate each category with a pipe separator
	// (|). For example, \"Deluxe|Premium\".
	//
	// Properties is a sensitive parameter and its value will be
	// replaced with "sensitive" in string returned by Action's
	// String and GoString methods.
	Properties *string `locationName:"properties" min:"1" type:"string" sensitive:"true"`
	// contains filtered or unexported fields
}

Represents action metadata added to an Action dataset using the PutActions API. For more information see Importing actions individually (https://docs.aws.amazon.com/personalize/latest/dg/importing-actions.html).

func (Action) GoString added in v1.48.4

func (s Action) GoString() string

GoString returns the string representation.

API parameter values that are decorated as "sensitive" in the API will not be included in the string output. The member name will be present, but the value will be replaced with "sensitive".

func (*Action) SetActionId added in v1.48.4

func (s *Action) SetActionId(v string) *Action

SetActionId sets the ActionId field's value.

func (*Action) SetProperties added in v1.48.4

func (s *Action) SetProperties(v string) *Action

SetProperties sets the Properties field's value.

func (Action) String added in v1.48.4

func (s Action) String() string

String returns the string representation.

API parameter values that are decorated as "sensitive" in the API will not be included in the string output. The member name will be present, but the value will be replaced with "sensitive".

func (*Action) Validate added in v1.48.4

func (s *Action) Validate() error

Validate inspects the fields of the type to determine if they are valid.

type ActionInteraction added in v1.48.4

type ActionInteraction struct {

	// The ID of the action the user interacted with. This corresponds to the ACTION_ID
	// field of the Action interaction schema.
	//
	// ActionId is a sensitive parameter and its value will be
	// replaced with "sensitive" in string returned by ActionInteraction's
	// String and GoString methods.
	//
	// ActionId is a required field
	ActionId *string `locationName:"actionId" min:"1" type:"string" required:"true" sensitive:"true"`

	// An ID associated with the event. If an event ID is not provided, Amazon Personalize
	// generates a unique ID for the event. An event ID is not used as an input
	// to the model. Amazon Personalize uses the event ID to distinguish unique
	// events. Any subsequent events after the first with the same event ID are
	// not used in model training.
	EventId *string `locationName:"eventId" min:"1" type:"string"`

	// The type of action interaction event. You can specify Viewed, Taken, and
	// Not Taken event types. For more information about action interaction event
	// type data, see Event type data (https://docs.aws.amazon.com/personalize/latest/dg/action-interaction-event-type-data.html).
	//
	// EventType is a required field
	EventType *string `locationName:"eventType" min:"1" type:"string" required:"true"`

	// A list of action IDs that represents the sequence of actions you have shown
	// the user. For example, ["actionId1", "actionId2", "actionId3"]. Amazon Personalize
	// doesn't use impressions data from action interaction events. Instead, record
	// multiple events for each action and use the Viewed event type.
	Impression []*string `locationName:"impression" min:"1" type:"list"`

	// A string map of event-specific data that you might choose to record. For
	// example, if a user takes an action, other than the action ID, you might also
	// send the number of actions taken by the user.
	//
	// Each item in the map consists of a key-value pair. For example,
	//
	// {"numberOfActions": "12"}
	//
	// The keys use camel case names that match the fields in the Action interactions
	// schema. In the above example, the numberOfActions would match the 'NUMBER_OF_ACTIONS'
	// field defined in the Action interactions schema.
	//
	// The following can't be included as a keyword for properties (case insensitive).
	//
	//    * userId
	//
	//    * sessionId
	//
	//    * eventType
	//
	//    * timestamp
	//
	//    * recommendationId
	//
	//    * impression
	//
	// Properties is a sensitive parameter and its value will be
	// replaced with "sensitive" in string returned by ActionInteraction's
	// String and GoString methods.
	Properties *string `locationName:"properties" min:"1" type:"string" sensitive:"true"`

	// The ID of the list of recommendations that contains the action the user interacted
	// with.
	RecommendationId *string `locationName:"recommendationId" min:"1" type:"string"`

	// The ID associated with the user's visit. Your application generates a unique
	// sessionId when a user first visits your website or uses your application.
	//
	// SessionId is a required field
	SessionId *string `locationName:"sessionId" min:"1" type:"string" required:"true"`

	// The timestamp for when the action interaction event occurred. Timestamps
	// must be in Unix epoch time format, in seconds.
	//
	// Timestamp is a required field
	Timestamp *time.Time `locationName:"timestamp" type:"timestamp" required:"true"`

	// The ID of the user who interacted with the action. This corresponds to the
	// USER_ID field of the Action interaction schema.
	//
	// UserId is a sensitive parameter and its value will be
	// replaced with "sensitive" in string returned by ActionInteraction's
	// String and GoString methods.
	UserId *string `locationName:"userId" min:"1" type:"string" sensitive:"true"`
	// contains filtered or unexported fields
}

Represents an action interaction event sent using the PutActionInteractions API.

func (ActionInteraction) GoString added in v1.48.4

func (s ActionInteraction) GoString() string

GoString returns the string representation.

API parameter values that are decorated as "sensitive" in the API will not be included in the string output. The member name will be present, but the value will be replaced with "sensitive".

func (*ActionInteraction) SetActionId added in v1.48.4

func (s *ActionInteraction) SetActionId(v string) *ActionInteraction

SetActionId sets the ActionId field's value.

func (*ActionInteraction) SetEventId added in v1.48.4

func (s *ActionInteraction) SetEventId(v string) *ActionInteraction

SetEventId sets the EventId field's value.

func (*ActionInteraction) SetEventType added in v1.48.4

func (s *ActionInteraction) SetEventType(v string) *ActionInteraction

SetEventType sets the EventType field's value.

func (*ActionInteraction) SetImpression added in v1.48.4

func (s *ActionInteraction) SetImpression(v []*string) *ActionInteraction

SetImpression sets the Impression field's value.

func (*ActionInteraction) SetProperties added in v1.48.4

func (s *ActionInteraction) SetProperties(v string) *ActionInteraction

SetProperties sets the Properties field's value.

func (*ActionInteraction) SetRecommendationId added in v1.48.4

func (s *ActionInteraction) SetRecommendationId(v string) *ActionInteraction

SetRecommendationId sets the RecommendationId field's value.

func (*ActionInteraction) SetSessionId added in v1.48.4

func (s *ActionInteraction) SetSessionId(v string) *ActionInteraction

SetSessionId sets the SessionId field's value.

func (*ActionInteraction) SetTimestamp added in v1.48.4

func (s *ActionInteraction) SetTimestamp(v time.Time) *ActionInteraction

SetTimestamp sets the Timestamp field's value.

func (*ActionInteraction) SetUserId added in v1.48.4

func (s *ActionInteraction) SetUserId(v string) *ActionInteraction

SetUserId sets the UserId field's value.

func (ActionInteraction) String added in v1.48.4

func (s ActionInteraction) String() string

String returns the string representation.

API parameter values that are decorated as "sensitive" in the API will not be included in the string output. The member name will be present, but the value will be replaced with "sensitive".

func (*ActionInteraction) Validate added in v1.48.4

func (s *ActionInteraction) Validate() error

Validate inspects the fields of the type to determine if they are valid.

type Event

type Event struct {

	// An ID associated with the event. If an event ID is not provided, Amazon Personalize
	// generates a unique ID for the event. An event ID is not used as an input
	// to the model. Amazon Personalize uses the event ID to distinguish unique
	// events. Any subsequent events after the first with the same event ID are
	// not used in model training.
	EventId *string `locationName:"eventId" min:"1" type:"string"`

	// The type of event, such as click or download. This property corresponds to
	// the EVENT_TYPE field of your Item interactions dataset's schema and depends
	// on the types of events you are tracking.
	//
	// EventType is a required field
	EventType *string `locationName:"eventType" min:"1" type:"string" required:"true"`

	// The event value that corresponds to the EVENT_VALUE field of the Item interactions
	// schema.
	EventValue *float64 `locationName:"eventValue" type:"float"`

	// A list of item IDs that represents the sequence of items you have shown the
	// user. For example, ["itemId1", "itemId2", "itemId3"]. Provide a list of items
	// to manually record impressions data for an event. For more information on
	// recording impressions data, see Recording impressions data (https://docs.aws.amazon.com/personalize/latest/dg/recording-events.html#putevents-including-impressions-data).
	Impression []*string `locationName:"impression" min:"1" type:"list"`

	// The item ID key that corresponds to the ITEM_ID field of the Item interactions
	// dataset's schema.
	//
	// ItemId is a sensitive parameter and its value will be
	// replaced with "sensitive" in string returned by Event's
	// String and GoString methods.
	ItemId *string `locationName:"itemId" min:"1" type:"string" sensitive:"true"`

	// Contains information about the metric attribution associated with an event.
	// For more information about metric attributions, see Measuring impact of recommendations
	// (https://docs.aws.amazon.com/personalize/latest/dg/measuring-recommendation-impact.html).
	MetricAttribution *MetricAttribution `locationName:"metricAttribution" type:"structure"`

	// A string map of event-specific data that you might choose to record. For
	// example, if a user rates a movie on your site, other than movie ID (itemId)
	// and rating (eventValue) , you might also send the number of movie ratings
	// made by the user.
	//
	// Each item in the map consists of a key-value pair. For example,
	//
	// {"numberOfRatings": "12"}
	//
	// The keys use camel case names that match the fields in the Item interactions
	// dataset's schema. In the above example, the numberOfRatings would match the
	// 'NUMBER_OF_RATINGS' field defined in the Item interactions dataset's schema.
	//
	// The following can't be included as a keyword for properties (case insensitive).
	//
	//    * userId
	//
	//    * sessionId
	//
	//    * eventType
	//
	//    * timestamp
	//
	//    * recommendationId
	//
	//    * impression
	Properties aws.JSONValue `locationName:"properties" type:"jsonvalue"`

	// The ID of the list of recommendations that contains the item the user interacted
	// with. Provide a recommendationId to have Amazon Personalize implicitly record
	// the recommendations you show your user as impressions data. Or provide a
	// recommendationId if you use a metric attribution to measure the impact of
	// recommendations.
	//
	// For more information on recording impressions data, see Recording impressions
	// data (https://docs.aws.amazon.com/personalize/latest/dg/recording-events.html#putevents-including-impressions-data).
	// For more information on creating a metric attribution see Measuring impact
	// of recommendations (https://docs.aws.amazon.com/personalize/latest/dg/measuring-recommendation-impact.html).
	RecommendationId *string `locationName:"recommendationId" min:"1" type:"string"`

	// The timestamp (in Unix time) on the client side when the event occurred.
	//
	// SentAt is a required field
	SentAt *time.Time `locationName:"sentAt" type:"timestamp" required:"true"`
	// contains filtered or unexported fields
}

Represents item interaction event information sent using the PutEvents API.

func (Event) GoString

func (s Event) GoString() string

GoString returns the string representation.

API parameter values that are decorated as "sensitive" in the API will not be included in the string output. The member name will be present, but the value will be replaced with "sensitive".

func (*Event) SetEventId

func (s *Event) SetEventId(v string) *Event

SetEventId sets the EventId field's value.

func (*Event) SetEventType

func (s *Event) SetEventType(v string) *Event

SetEventType sets the EventType field's value.

func (*Event) SetEventValue added in v1.33.21

func (s *Event) SetEventValue(v float64) *Event

SetEventValue sets the EventValue field's value.

func (*Event) SetImpression added in v1.33.21

func (s *Event) SetImpression(v []*string) *Event

SetImpression sets the Impression field's value.

func (*Event) SetItemId added in v1.33.21

func (s *Event) SetItemId(v string) *Event

SetItemId sets the ItemId field's value.

func (*Event) SetMetricAttribution added in v1.44.139

func (s *Event) SetMetricAttribution(v *MetricAttribution) *Event

SetMetricAttribution sets the MetricAttribution field's value.

func (*Event) SetProperties

func (s *Event) SetProperties(v aws.JSONValue) *Event

SetProperties sets the Properties field's value.

func (*Event) SetRecommendationId added in v1.33.21

func (s *Event) SetRecommendationId(v string) *Event

SetRecommendationId sets the RecommendationId field's value.

func (*Event) SetSentAt

func (s *Event) SetSentAt(v time.Time) *Event

SetSentAt sets the SentAt field's value.

func (Event) String

func (s Event) String() string

String returns the string representation.

API parameter values that are decorated as "sensitive" in the API will not be included in the string output. The member name will be present, but the value will be replaced with "sensitive".

func (*Event) Validate

func (s *Event) Validate() error

Validate inspects the fields of the type to determine if they are valid.

type InvalidInputException added in v1.28.0

type InvalidInputException struct {
	RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"`

	Message_ *string `locationName:"message" type:"string"`
	// contains filtered or unexported fields
}

Provide a valid value for the field or parameter.

func (*InvalidInputException) Code added in v1.28.0

func (s *InvalidInputException) Code() string

Code returns the exception type name.

func (*InvalidInputException) Error added in v1.28.0

func (s *InvalidInputException) Error() string

func (InvalidInputException) GoString added in v1.28.0

func (s InvalidInputException) GoString() string

GoString returns the string representation.

API parameter values that are decorated as "sensitive" in the API will not be included in the string output. The member name will be present, but the value will be replaced with "sensitive".

func (*InvalidInputException) Message added in v1.28.0

func (s *InvalidInputException) Message() string

Message returns the exception's message.

func (*InvalidInputException) OrigErr added in v1.28.0

func (s *InvalidInputException) OrigErr() error

OrigErr always returns nil, satisfies awserr.Error interface.

func (*InvalidInputException) RequestID added in v1.28.0

func (s *InvalidInputException) RequestID() string

RequestID returns the service's response RequestID for request.

func (*InvalidInputException) StatusCode added in v1.28.0

func (s *InvalidInputException) StatusCode() int

Status code returns the HTTP status code for the request's response error.

func (InvalidInputException) String added in v1.28.0

func (s InvalidInputException) String() string

String returns the string representation.

API parameter values that are decorated as "sensitive" in the API will not be included in the string output. The member name will be present, but the value will be replaced with "sensitive".

type Item added in v1.35.2

type Item struct {

	// The ID associated with the item.
	//
	// ItemId is a required field
	ItemId *string `locationName:"itemId" min:"1" type:"string" required:"true"`

	// A string map of item-specific metadata. Each element in the map consists
	// of a key-value pair. For example, {"numberOfRatings": "12"}.
	//
	// The keys use camel case names that match the fields in the schema for the
	// Items dataset. In the previous example, the numberOfRatings matches the 'NUMBER_OF_RATINGS'
	// field defined in the Items schema. For categorical string data, to include
	// multiple categories for a single item, separate each category with a pipe
	// separator (|). For example, \"Horror|Action\".
	Properties aws.JSONValue `locationName:"properties" type:"jsonvalue"`
	// contains filtered or unexported fields
}

Represents item metadata added to an Items dataset using the PutItems API. For more information see Importing items individually (https://docs.aws.amazon.com/personalize/latest/dg/importing-items.html).

func (Item) GoString added in v1.35.2

func (s Item) GoString() string

GoString returns the string representation.

API parameter values that are decorated as "sensitive" in the API will not be included in the string output. The member name will be present, but the value will be replaced with "sensitive".

func (*Item) SetItemId added in v1.35.2

func (s *Item) SetItemId(v string) *Item

SetItemId sets the ItemId field's value.

func (*Item) SetProperties added in v1.35.2

func (s *Item) SetProperties(v aws.JSONValue) *Item

SetProperties sets the Properties field's value.

func (Item) String added in v1.35.2

func (s Item) String() string

String returns the string representation.

API parameter values that are decorated as "sensitive" in the API will not be included in the string output. The member name will be present, but the value will be replaced with "sensitive".

func (*Item) Validate added in v1.35.2

func (s *Item) Validate() error

Validate inspects the fields of the type to determine if they are valid.

type MetricAttribution added in v1.44.139

type MetricAttribution struct {

	// The source of the event, such as a third party.
	//
	// EventAttributionSource is a required field
	EventAttributionSource *string `locationName:"eventAttributionSource" type:"string" required:"true"`
	// contains filtered or unexported fields
}

Contains information about a metric attribution associated with an event. For more information about metric attributions, see Measuring impact of recommendations (https://docs.aws.amazon.com/personalize/latest/dg/measuring-recommendation-impact.html).

func (MetricAttribution) GoString added in v1.44.139

func (s MetricAttribution) GoString() string

GoString returns the string representation.

API parameter values that are decorated as "sensitive" in the API will not be included in the string output. The member name will be present, but the value will be replaced with "sensitive".

func (*MetricAttribution) SetEventAttributionSource added in v1.44.139

func (s *MetricAttribution) SetEventAttributionSource(v string) *MetricAttribution

SetEventAttributionSource sets the EventAttributionSource field's value.

func (MetricAttribution) String added in v1.44.139

func (s MetricAttribution) String() string

String returns the string representation.

API parameter values that are decorated as "sensitive" in the API will not be included in the string output. The member name will be present, but the value will be replaced with "sensitive".

func (*MetricAttribution) Validate added in v1.44.139

func (s *MetricAttribution) Validate() error

Validate inspects the fields of the type to determine if they are valid.

type PersonalizeEvents

type PersonalizeEvents struct {
	*client.Client
}

PersonalizeEvents provides the API operation methods for making requests to Amazon Personalize Events. See this package's package overview docs for details on the service.

PersonalizeEvents methods are safe to use concurrently. It is not safe to modify mutate any of the struct's properties though.

func New

New creates a new instance of the PersonalizeEvents client with a session. If additional configuration is needed for the client instance use the optional aws.Config parameter to add your extra config.

Example:

mySession := session.Must(session.NewSession())

// Create a PersonalizeEvents client from just a session.
svc := personalizeevents.New(mySession)

// Create a PersonalizeEvents client with additional configuration
svc := personalizeevents.New(mySession, aws.NewConfig().WithRegion("us-west-2"))

func (*PersonalizeEvents) PutActionInteractions added in v1.48.4

PutActionInteractions API operation for Amazon Personalize Events.

Records action interaction event data. An action interaction event is an interaction between a user and an action. For example, a user taking an action, such a enrolling in a membership program or downloading your app.

For more information about recording action interactions, see Recording action interaction events (https://docs.aws.amazon.com/personalize/latest/dg/recording-action-interaction-events.html). For more information about actions in an Actions dataset, see Actions dataset (https://docs.aws.amazon.com/personalize/latest/dg/actions-datasets.html).

Returns awserr.Error for service API and SDK errors. Use runtime type assertions with awserr.Error's Code and Message methods to get detailed information about the error.

See the AWS API reference guide for Amazon Personalize Events's API operation PutActionInteractions for usage and error information.

Returned Error Types:

  • InvalidInputException Provide a valid value for the field or parameter.

  • ResourceNotFoundException Could not find the specified resource.

  • ResourceInUseException The specified resource is in use.

See also, https://docs.aws.amazon.com/goto/WebAPI/personalize-events-2018-03-22/PutActionInteractions

func (*PersonalizeEvents) PutActionInteractionsRequest added in v1.48.4

func (c *PersonalizeEvents) PutActionInteractionsRequest(input *PutActionInteractionsInput) (req *request.Request, output *PutActionInteractionsOutput)

PutActionInteractionsRequest generates a "aws/request.Request" representing the client's request for the PutActionInteractions operation. The "output" return value will be populated with the request's response once the request completes successfully.

Use "Send" method on the returned Request to send the API call to the service. the "output" return value is not valid until after Send returns without error.

See PutActionInteractions for more information on using the PutActionInteractions API call, and error handling.

This method is useful when you want to inject custom logic or configuration into the SDK's request lifecycle. Such as custom headers, or retry logic.

// Example sending a request using the PutActionInteractionsRequest method.
req, resp := client.PutActionInteractionsRequest(params)

err := req.Send()
if err == nil { // resp is now filled
    fmt.Println(resp)
}

See also, https://docs.aws.amazon.com/goto/WebAPI/personalize-events-2018-03-22/PutActionInteractions

func (*PersonalizeEvents) PutActionInteractionsWithContext added in v1.48.4

func (c *PersonalizeEvents) PutActionInteractionsWithContext(ctx aws.Context, input *PutActionInteractionsInput, opts ...request.Option) (*PutActionInteractionsOutput, error)

PutActionInteractionsWithContext is the same as PutActionInteractions with the addition of the ability to pass a context and additional request options.

See PutActionInteractions for details on how to use this API operation.

The context must be non-nil and will be used for request cancellation. If the context is nil a panic will occur. In the future the SDK may create sub-contexts for http.Requests. See https://golang.org/pkg/context/ for more information on using Contexts.

func (*PersonalizeEvents) PutActions added in v1.48.4

func (c *PersonalizeEvents) PutActions(input *PutActionsInput) (*PutActionsOutput, error)

PutActions API operation for Amazon Personalize Events.

Adds one or more actions to an Actions dataset. For more information see Importing actions individually (https://docs.aws.amazon.com/personalize/latest/dg/importing-actions.html).

Returns awserr.Error for service API and SDK errors. Use runtime type assertions with awserr.Error's Code and Message methods to get detailed information about the error.

See the AWS API reference guide for Amazon Personalize Events's API operation PutActions for usage and error information.

Returned Error Types:

  • InvalidInputException Provide a valid value for the field or parameter.

  • ResourceNotFoundException Could not find the specified resource.

  • ResourceInUseException The specified resource is in use.

See also, https://docs.aws.amazon.com/goto/WebAPI/personalize-events-2018-03-22/PutActions

func (*PersonalizeEvents) PutActionsRequest added in v1.48.4

func (c *PersonalizeEvents) PutActionsRequest(input *PutActionsInput) (req *request.Request, output *PutActionsOutput)

PutActionsRequest generates a "aws/request.Request" representing the client's request for the PutActions operation. The "output" return value will be populated with the request's response once the request completes successfully.

Use "Send" method on the returned Request to send the API call to the service. the "output" return value is not valid until after Send returns without error.

See PutActions for more information on using the PutActions API call, and error handling.

This method is useful when you want to inject custom logic or configuration into the SDK's request lifecycle. Such as custom headers, or retry logic.

// Example sending a request using the PutActionsRequest method.
req, resp := client.PutActionsRequest(params)

err := req.Send()
if err == nil { // resp is now filled
    fmt.Println(resp)
}

See also, https://docs.aws.amazon.com/goto/WebAPI/personalize-events-2018-03-22/PutActions

func (*PersonalizeEvents) PutActionsWithContext added in v1.48.4

func (c *PersonalizeEvents) PutActionsWithContext(ctx aws.Context, input *PutActionsInput, opts ...request.Option) (*PutActionsOutput, error)

PutActionsWithContext is the same as PutActions with the addition of the ability to pass a context and additional request options.

See PutActions for details on how to use this API operation.

The context must be non-nil and will be used for request cancellation. If the context is nil a panic will occur. In the future the SDK may create sub-contexts for http.Requests. See https://golang.org/pkg/context/ for more information on using Contexts.

func (*PersonalizeEvents) PutEvents

func (c *PersonalizeEvents) PutEvents(input *PutEventsInput) (*PutEventsOutput, error)

PutEvents API operation for Amazon Personalize Events.

Records item interaction event data. For more information see Recording item interaction events (https://docs.aws.amazon.com/personalize/latest/dg/recording-item-interaction-events.html).

Returns awserr.Error for service API and SDK errors. Use runtime type assertions with awserr.Error's Code and Message methods to get detailed information about the error.

See the AWS API reference guide for Amazon Personalize Events's API operation PutEvents for usage and error information.

Returned Error Types:

  • InvalidInputException Provide a valid value for the field or parameter.

See also, https://docs.aws.amazon.com/goto/WebAPI/personalize-events-2018-03-22/PutEvents

func (*PersonalizeEvents) PutEventsRequest

func (c *PersonalizeEvents) PutEventsRequest(input *PutEventsInput) (req *request.Request, output *PutEventsOutput)

PutEventsRequest generates a "aws/request.Request" representing the client's request for the PutEvents operation. The "output" return value will be populated with the request's response once the request completes successfully.

Use "Send" method on the returned Request to send the API call to the service. the "output" return value is not valid until after Send returns without error.

See PutEvents for more information on using the PutEvents API call, and error handling.

This method is useful when you want to inject custom logic or configuration into the SDK's request lifecycle. Such as custom headers, or retry logic.

// Example sending a request using the PutEventsRequest method.
req, resp := client.PutEventsRequest(params)

err := req.Send()
if err == nil { // resp is now filled
    fmt.Println(resp)
}

See also, https://docs.aws.amazon.com/goto/WebAPI/personalize-events-2018-03-22/PutEvents

func (*PersonalizeEvents) PutEventsWithContext

func (c *PersonalizeEvents) PutEventsWithContext(ctx aws.Context, input *PutEventsInput, opts ...request.Option) (*PutEventsOutput, error)

PutEventsWithContext is the same as PutEvents with the addition of the ability to pass a context and additional request options.

See PutEvents for details on how to use this API operation.

The context must be non-nil and will be used for request cancellation. If the context is nil a panic will occur. In the future the SDK may create sub-contexts for http.Requests. See https://golang.org/pkg/context/ for more information on using Contexts.

func (*PersonalizeEvents) PutItems added in v1.35.2

func (c *PersonalizeEvents) PutItems(input *PutItemsInput) (*PutItemsOutput, error)

PutItems API operation for Amazon Personalize Events.

Adds one or more items to an Items dataset. For more information see Importing items individually (https://docs.aws.amazon.com/personalize/latest/dg/importing-items.html).

Returns awserr.Error for service API and SDK errors. Use runtime type assertions with awserr.Error's Code and Message methods to get detailed information about the error.

See the AWS API reference guide for Amazon Personalize Events's API operation PutItems for usage and error information.

Returned Error Types:

  • InvalidInputException Provide a valid value for the field or parameter.

  • ResourceNotFoundException Could not find the specified resource.

  • ResourceInUseException The specified resource is in use.

See also, https://docs.aws.amazon.com/goto/WebAPI/personalize-events-2018-03-22/PutItems

func (*PersonalizeEvents) PutItemsRequest added in v1.35.2

func (c *PersonalizeEvents) PutItemsRequest(input *PutItemsInput) (req *request.Request, output *PutItemsOutput)

PutItemsRequest generates a "aws/request.Request" representing the client's request for the PutItems operation. The "output" return value will be populated with the request's response once the request completes successfully.

Use "Send" method on the returned Request to send the API call to the service. the "output" return value is not valid until after Send returns without error.

See PutItems for more information on using the PutItems API call, and error handling.

This method is useful when you want to inject custom logic or configuration into the SDK's request lifecycle. Such as custom headers, or retry logic.

// Example sending a request using the PutItemsRequest method.
req, resp := client.PutItemsRequest(params)

err := req.Send()
if err == nil { // resp is now filled
    fmt.Println(resp)
}

See also, https://docs.aws.amazon.com/goto/WebAPI/personalize-events-2018-03-22/PutItems

func (*PersonalizeEvents) PutItemsWithContext added in v1.35.2

func (c *PersonalizeEvents) PutItemsWithContext(ctx aws.Context, input *PutItemsInput, opts ...request.Option) (*PutItemsOutput, error)

PutItemsWithContext is the same as PutItems with the addition of the ability to pass a context and additional request options.

See PutItems for details on how to use this API operation.

The context must be non-nil and will be used for request cancellation. If the context is nil a panic will occur. In the future the SDK may create sub-contexts for http.Requests. See https://golang.org/pkg/context/ for more information on using Contexts.

func (*PersonalizeEvents) PutUsers added in v1.35.2

func (c *PersonalizeEvents) PutUsers(input *PutUsersInput) (*PutUsersOutput, error)

PutUsers API operation for Amazon Personalize Events.

Adds one or more users to a Users dataset. For more information see Importing users individually (https://docs.aws.amazon.com/personalize/latest/dg/importing-users.html).

Returns awserr.Error for service API and SDK errors. Use runtime type assertions with awserr.Error's Code and Message methods to get detailed information about the error.

See the AWS API reference guide for Amazon Personalize Events's API operation PutUsers for usage and error information.

Returned Error Types:

  • InvalidInputException Provide a valid value for the field or parameter.

  • ResourceNotFoundException Could not find the specified resource.

  • ResourceInUseException The specified resource is in use.

See also, https://docs.aws.amazon.com/goto/WebAPI/personalize-events-2018-03-22/PutUsers

func (*PersonalizeEvents) PutUsersRequest added in v1.35.2

func (c *PersonalizeEvents) PutUsersRequest(input *PutUsersInput) (req *request.Request, output *PutUsersOutput)

PutUsersRequest generates a "aws/request.Request" representing the client's request for the PutUsers operation. The "output" return value will be populated with the request's response once the request completes successfully.

Use "Send" method on the returned Request to send the API call to the service. the "output" return value is not valid until after Send returns without error.

See PutUsers for more information on using the PutUsers API call, and error handling.

This method is useful when you want to inject custom logic or configuration into the SDK's request lifecycle. Such as custom headers, or retry logic.

// Example sending a request using the PutUsersRequest method.
req, resp := client.PutUsersRequest(params)

err := req.Send()
if err == nil { // resp is now filled
    fmt.Println(resp)
}

See also, https://docs.aws.amazon.com/goto/WebAPI/personalize-events-2018-03-22/PutUsers

func (*PersonalizeEvents) PutUsersWithContext added in v1.35.2

func (c *PersonalizeEvents) PutUsersWithContext(ctx aws.Context, input *PutUsersInput, opts ...request.Option) (*PutUsersOutput, error)

PutUsersWithContext is the same as PutUsers with the addition of the ability to pass a context and additional request options.

See PutUsers for details on how to use this API operation.

The context must be non-nil and will be used for request cancellation. If the context is nil a panic will occur. In the future the SDK may create sub-contexts for http.Requests. See https://golang.org/pkg/context/ for more information on using Contexts.

type PutActionInteractionsInput added in v1.48.4

type PutActionInteractionsInput struct {

	// A list of action interaction events from the session.
	//
	// ActionInteractions is a required field
	ActionInteractions []*ActionInteraction `locationName:"actionInteractions" min:"1" type:"list" required:"true"`

	// The ID of your action interaction event tracker. When you create an Action
	// interactions dataset, Amazon Personalize creates an action interaction event
	// tracker for you. For more information, see Action interaction event tracker
	// ID (https://docs.aws.amazon.com/personalize/latest/dg/action-interaction-tracker-id.html).
	//
	// TrackingId is a required field
	TrackingId *string `locationName:"trackingId" min:"1" type:"string" required:"true"`
	// contains filtered or unexported fields
}

func (PutActionInteractionsInput) GoString added in v1.48.4

func (s PutActionInteractionsInput) GoString() string

GoString returns the string representation.

API parameter values that are decorated as "sensitive" in the API will not be included in the string output. The member name will be present, but the value will be replaced with "sensitive".

func (*PutActionInteractionsInput) SetActionInteractions added in v1.48.4

SetActionInteractions sets the ActionInteractions field's value.

func (*PutActionInteractionsInput) SetTrackingId added in v1.48.4

SetTrackingId sets the TrackingId field's value.

func (PutActionInteractionsInput) String added in v1.48.4

String returns the string representation.

API parameter values that are decorated as "sensitive" in the API will not be included in the string output. The member name will be present, but the value will be replaced with "sensitive".

func (*PutActionInteractionsInput) Validate added in v1.48.4

func (s *PutActionInteractionsInput) Validate() error

Validate inspects the fields of the type to determine if they are valid.

type PutActionInteractionsOutput added in v1.48.4

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

func (PutActionInteractionsOutput) GoString added in v1.48.4

func (s PutActionInteractionsOutput) GoString() string

GoString returns the string representation.

API parameter values that are decorated as "sensitive" in the API will not be included in the string output. The member name will be present, but the value will be replaced with "sensitive".

func (PutActionInteractionsOutput) String added in v1.48.4

String returns the string representation.

API parameter values that are decorated as "sensitive" in the API will not be included in the string output. The member name will be present, but the value will be replaced with "sensitive".

type PutActionsInput added in v1.48.4

type PutActionsInput struct {

	// A list of action data.
	//
	// Actions is a required field
	Actions []*Action `locationName:"actions" min:"1" type:"list" required:"true"`

	// The Amazon Resource Name (ARN) of the Actions dataset you are adding the
	// action or actions to.
	//
	// DatasetArn is a required field
	DatasetArn *string `locationName:"datasetArn" type:"string" required:"true"`
	// contains filtered or unexported fields
}

func (PutActionsInput) GoString added in v1.48.4

func (s PutActionsInput) GoString() string

GoString returns the string representation.

API parameter values that are decorated as "sensitive" in the API will not be included in the string output. The member name will be present, but the value will be replaced with "sensitive".

func (*PutActionsInput) SetActions added in v1.48.4

func (s *PutActionsInput) SetActions(v []*Action) *PutActionsInput

SetActions sets the Actions field's value.

func (*PutActionsInput) SetDatasetArn added in v1.48.4

func (s *PutActionsInput) SetDatasetArn(v string) *PutActionsInput

SetDatasetArn sets the DatasetArn field's value.

func (PutActionsInput) String added in v1.48.4

func (s PutActionsInput) String() string

String returns the string representation.

API parameter values that are decorated as "sensitive" in the API will not be included in the string output. The member name will be present, but the value will be replaced with "sensitive".

func (*PutActionsInput) Validate added in v1.48.4

func (s *PutActionsInput) Validate() error

Validate inspects the fields of the type to determine if they are valid.

type PutActionsOutput added in v1.48.4

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

func (PutActionsOutput) GoString added in v1.48.4

func (s PutActionsOutput) GoString() string

GoString returns the string representation.

API parameter values that are decorated as "sensitive" in the API will not be included in the string output. The member name will be present, but the value will be replaced with "sensitive".

func (PutActionsOutput) String added in v1.48.4

func (s PutActionsOutput) String() string

String returns the string representation.

API parameter values that are decorated as "sensitive" in the API will not be included in the string output. The member name will be present, but the value will be replaced with "sensitive".

type PutEventsInput

type PutEventsInput struct {

	// A list of event data from the session.
	//
	// EventList is a required field
	EventList []*Event `locationName:"eventList" min:"1" type:"list" required:"true"`

	// The session ID associated with the user's visit. Your application generates
	// the sessionId when a user first visits your website or uses your application.
	// Amazon Personalize uses the sessionId to associate events with the user before
	// they log in. For more information, see Recording item interaction events
	// (https://docs.aws.amazon.com/personalize/latest/dg/recording-item-interaction-events.html).
	//
	// SessionId is a required field
	SessionId *string `locationName:"sessionId" min:"1" type:"string" required:"true"`

	// The tracking ID for the event. The ID is generated by a call to the CreateEventTracker
	// (https://docs.aws.amazon.com/personalize/latest/dg/API_CreateEventTracker.html)
	// API.
	//
	// TrackingId is a required field
	TrackingId *string `locationName:"trackingId" min:"1" type:"string" required:"true"`

	// The user associated with the event.
	//
	// UserId is a sensitive parameter and its value will be
	// replaced with "sensitive" in string returned by PutEventsInput's
	// String and GoString methods.
	UserId *string `locationName:"userId" min:"1" type:"string" sensitive:"true"`
	// contains filtered or unexported fields
}

func (PutEventsInput) GoString

func (s PutEventsInput) GoString() string

GoString returns the string representation.

API parameter values that are decorated as "sensitive" in the API will not be included in the string output. The member name will be present, but the value will be replaced with "sensitive".

func (*PutEventsInput) SetEventList

func (s *PutEventsInput) SetEventList(v []*Event) *PutEventsInput

SetEventList sets the EventList field's value.

func (*PutEventsInput) SetSessionId

func (s *PutEventsInput) SetSessionId(v string) *PutEventsInput

SetSessionId sets the SessionId field's value.

func (*PutEventsInput) SetTrackingId

func (s *PutEventsInput) SetTrackingId(v string) *PutEventsInput

SetTrackingId sets the TrackingId field's value.

func (*PutEventsInput) SetUserId

func (s *PutEventsInput) SetUserId(v string) *PutEventsInput

SetUserId sets the UserId field's value.

func (PutEventsInput) String

func (s PutEventsInput) String() string

String returns the string representation.

API parameter values that are decorated as "sensitive" in the API will not be included in the string output. The member name will be present, but the value will be replaced with "sensitive".

func (*PutEventsInput) Validate

func (s *PutEventsInput) Validate() error

Validate inspects the fields of the type to determine if they are valid.

type PutEventsOutput

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

func (PutEventsOutput) GoString

func (s PutEventsOutput) GoString() string

GoString returns the string representation.

API parameter values that are decorated as "sensitive" in the API will not be included in the string output. The member name will be present, but the value will be replaced with "sensitive".

func (PutEventsOutput) String

func (s PutEventsOutput) String() string

String returns the string representation.

API parameter values that are decorated as "sensitive" in the API will not be included in the string output. The member name will be present, but the value will be replaced with "sensitive".

type PutItemsInput added in v1.35.2

type PutItemsInput struct {

	// The Amazon Resource Name (ARN) of the Items dataset you are adding the item
	// or items to.
	//
	// DatasetArn is a required field
	DatasetArn *string `locationName:"datasetArn" type:"string" required:"true"`

	// A list of item data.
	//
	// Items is a required field
	Items []*Item `locationName:"items" min:"1" type:"list" required:"true"`
	// contains filtered or unexported fields
}

func (PutItemsInput) GoString added in v1.35.2

func (s PutItemsInput) GoString() string

GoString returns the string representation.

API parameter values that are decorated as "sensitive" in the API will not be included in the string output. The member name will be present, but the value will be replaced with "sensitive".

func (*PutItemsInput) SetDatasetArn added in v1.35.2

func (s *PutItemsInput) SetDatasetArn(v string) *PutItemsInput

SetDatasetArn sets the DatasetArn field's value.

func (*PutItemsInput) SetItems added in v1.35.2

func (s *PutItemsInput) SetItems(v []*Item) *PutItemsInput

SetItems sets the Items field's value.

func (PutItemsInput) String added in v1.35.2

func (s PutItemsInput) String() string

String returns the string representation.

API parameter values that are decorated as "sensitive" in the API will not be included in the string output. The member name will be present, but the value will be replaced with "sensitive".

func (*PutItemsInput) Validate added in v1.35.2

func (s *PutItemsInput) Validate() error

Validate inspects the fields of the type to determine if they are valid.

type PutItemsOutput added in v1.35.2

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

func (PutItemsOutput) GoString added in v1.35.2

func (s PutItemsOutput) GoString() string

GoString returns the string representation.

API parameter values that are decorated as "sensitive" in the API will not be included in the string output. The member name will be present, but the value will be replaced with "sensitive".

func (PutItemsOutput) String added in v1.35.2

func (s PutItemsOutput) String() string

String returns the string representation.

API parameter values that are decorated as "sensitive" in the API will not be included in the string output. The member name will be present, but the value will be replaced with "sensitive".

type PutUsersInput added in v1.35.2

type PutUsersInput struct {

	// The Amazon Resource Name (ARN) of the Users dataset you are adding the user
	// or users to.
	//
	// DatasetArn is a required field
	DatasetArn *string `locationName:"datasetArn" type:"string" required:"true"`

	// A list of user data.
	//
	// Users is a required field
	Users []*User `locationName:"users" min:"1" type:"list" required:"true"`
	// contains filtered or unexported fields
}

func (PutUsersInput) GoString added in v1.35.2

func (s PutUsersInput) GoString() string

GoString returns the string representation.

API parameter values that are decorated as "sensitive" in the API will not be included in the string output. The member name will be present, but the value will be replaced with "sensitive".

func (*PutUsersInput) SetDatasetArn added in v1.35.2

func (s *PutUsersInput) SetDatasetArn(v string) *PutUsersInput

SetDatasetArn sets the DatasetArn field's value.

func (*PutUsersInput) SetUsers added in v1.35.2

func (s *PutUsersInput) SetUsers(v []*User) *PutUsersInput

SetUsers sets the Users field's value.

func (PutUsersInput) String added in v1.35.2

func (s PutUsersInput) String() string

String returns the string representation.

API parameter values that are decorated as "sensitive" in the API will not be included in the string output. The member name will be present, but the value will be replaced with "sensitive".

func (*PutUsersInput) Validate added in v1.35.2

func (s *PutUsersInput) Validate() error

Validate inspects the fields of the type to determine if they are valid.

type PutUsersOutput added in v1.35.2

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

func (PutUsersOutput) GoString added in v1.35.2

func (s PutUsersOutput) GoString() string

GoString returns the string representation.

API parameter values that are decorated as "sensitive" in the API will not be included in the string output. The member name will be present, but the value will be replaced with "sensitive".

func (PutUsersOutput) String added in v1.35.2

func (s PutUsersOutput) String() string

String returns the string representation.

API parameter values that are decorated as "sensitive" in the API will not be included in the string output. The member name will be present, but the value will be replaced with "sensitive".

type ResourceInUseException added in v1.37.10

type ResourceInUseException struct {
	RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"`

	Message_ *string `locationName:"message" type:"string"`
	// contains filtered or unexported fields
}

The specified resource is in use.

func (*ResourceInUseException) Code added in v1.37.10

func (s *ResourceInUseException) Code() string

Code returns the exception type name.

func (*ResourceInUseException) Error added in v1.37.10

func (s *ResourceInUseException) Error() string

func (ResourceInUseException) GoString added in v1.37.10

func (s ResourceInUseException) GoString() string

GoString returns the string representation.

API parameter values that are decorated as "sensitive" in the API will not be included in the string output. The member name will be present, but the value will be replaced with "sensitive".

func (*ResourceInUseException) Message added in v1.37.10

func (s *ResourceInUseException) Message() string

Message returns the exception's message.

func (*ResourceInUseException) OrigErr added in v1.37.10

func (s *ResourceInUseException) OrigErr() error

OrigErr always returns nil, satisfies awserr.Error interface.

func (*ResourceInUseException) RequestID added in v1.37.10

func (s *ResourceInUseException) RequestID() string

RequestID returns the service's response RequestID for request.

func (*ResourceInUseException) StatusCode added in v1.37.10

func (s *ResourceInUseException) StatusCode() int

Status code returns the HTTP status code for the request's response error.

func (ResourceInUseException) String added in v1.37.10

func (s ResourceInUseException) String() string

String returns the string representation.

API parameter values that are decorated as "sensitive" in the API will not be included in the string output. The member name will be present, but the value will be replaced with "sensitive".

type ResourceNotFoundException added in v1.35.2

type ResourceNotFoundException struct {
	RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"`

	Message_ *string `locationName:"message" type:"string"`
	// contains filtered or unexported fields
}

Could not find the specified resource.

func (*ResourceNotFoundException) Code added in v1.35.2

Code returns the exception type name.

func (*ResourceNotFoundException) Error added in v1.35.2

func (s *ResourceNotFoundException) Error() string

func (ResourceNotFoundException) GoString added in v1.35.2

func (s ResourceNotFoundException) GoString() string

GoString returns the string representation.

API parameter values that are decorated as "sensitive" in the API will not be included in the string output. The member name will be present, but the value will be replaced with "sensitive".

func (*ResourceNotFoundException) Message added in v1.35.2

func (s *ResourceNotFoundException) Message() string

Message returns the exception's message.

func (*ResourceNotFoundException) OrigErr added in v1.35.2

func (s *ResourceNotFoundException) OrigErr() error

OrigErr always returns nil, satisfies awserr.Error interface.

func (*ResourceNotFoundException) RequestID added in v1.35.2

func (s *ResourceNotFoundException) RequestID() string

RequestID returns the service's response RequestID for request.

func (*ResourceNotFoundException) StatusCode added in v1.35.2

func (s *ResourceNotFoundException) StatusCode() int

Status code returns the HTTP status code for the request's response error.

func (ResourceNotFoundException) String added in v1.35.2

func (s ResourceNotFoundException) String() string

String returns the string representation.

API parameter values that are decorated as "sensitive" in the API will not be included in the string output. The member name will be present, but the value will be replaced with "sensitive".

type User added in v1.35.2

type User struct {

	// A string map of user-specific metadata. Each element in the map consists
	// of a key-value pair. For example, {"numberOfVideosWatched": "45"}.
	//
	// The keys use camel case names that match the fields in the schema for the
	// Users dataset. In the previous example, the numberOfVideosWatched matches
	// the 'NUMBER_OF_VIDEOS_WATCHED' field defined in the Users schema. For categorical
	// string data, to include multiple categories for a single user, separate each
	// category with a pipe separator (|). For example, \"Member|Frequent shopper\".
	Properties aws.JSONValue `locationName:"properties" type:"jsonvalue"`

	// The ID associated with the user.
	//
	// UserId is a required field
	UserId *string `locationName:"userId" min:"1" type:"string" required:"true"`
	// contains filtered or unexported fields
}

Represents user metadata added to a Users dataset using the PutUsers API. For more information see Importing users individually (https://docs.aws.amazon.com/personalize/latest/dg/importing-users.html).

func (User) GoString added in v1.35.2

func (s User) GoString() string

GoString returns the string representation.

API parameter values that are decorated as "sensitive" in the API will not be included in the string output. The member name will be present, but the value will be replaced with "sensitive".

func (*User) SetProperties added in v1.35.2

func (s *User) SetProperties(v aws.JSONValue) *User

SetProperties sets the Properties field's value.

func (*User) SetUserId added in v1.35.2

func (s *User) SetUserId(v string) *User

SetUserId sets the UserId field's value.

func (User) String added in v1.35.2

func (s User) String() string

String returns the string representation.

API parameter values that are decorated as "sensitive" in the API will not be included in the string output. The member name will be present, but the value will be replaced with "sensitive".

func (*User) Validate added in v1.35.2

func (s *User) Validate() error

Validate inspects the fields of the type to determine if they are valid.

Directories

Path Synopsis
Package personalizeeventsiface provides an interface to enable mocking the Amazon Personalize Events service client for testing your code.
Package personalizeeventsiface provides an interface to enable mocking the Amazon Personalize Events service client for testing your code.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL