journeys
Creates, updates, deletes, gets or lists a journeys resource.
Overview
| Name | journeys |
| Type | Resource |
| Id | aws.pinpoint.journeys |
Fields
The following fields are returned by SELECT queries:
- get_journey
- list_journeys
| Name | Datatype | Description |
|---|---|---|
activities | object | A map that contains a set of Activity objects, one object for each activity in the journey. For each Activity object, the key is the unique identifier (string) for an activity and the value is the settings for the activity. |
application_id | string | The unique identifier for the application that the journey applies to. |
closed_days | object | The time when a journey will not send messages. QuietTime should be configured first and SendingSchedule should be set to true. |
creation_date | string | The date, in ISO 8601 format, when the journey was created. |
id | string | The unique identifier for the journey. |
journey_channel_settings | object | The channel-specific configurations for the journey. |
last_modified_date | string | The date, in ISO 8601 format, when the journey was last modified. |
limits | object | The messaging and entry limits for the journey. |
local_time | boolean | Specifies whether the journey's scheduled start and end times use each participant's local time. If this value is true, the schedule uses each participant's local time. |
name | string | The name of the journey. |
open_hours | object | The time when a journey can send messages. QuietTime should be configured first and SendingSchedule should be set to true. |
quiet_time | object | The quiet time settings for the journey. Quiet time is a specific time range when a journey doesn't send messages to participants, if all the following conditions are met: The EndpointDemographic.Timezone property of the endpoint for the participant is set to a valid value. The current time in the participant's time zone is later than or equal to the time specified by the QuietTime.Start property for the journey. The current time in the participant's time zone is earlier than or equal to the time specified by the QuietTime.End property for the journey. If any of the preceding conditions isn't met, the participant will receive messages from the journey, even if quiet time is enabled. |
refresh_frequency | string | The frequency with which Amazon Pinpoint evaluates segment and event data for the journey, as a duration in ISO 8601 format. |
refresh_on_segment_update | boolean | Indicates whether the journey participants should be refreshed when a segment is updated. |
schedule | object | The schedule settings for the journey. |
sending_schedule | boolean | Indicates if journey has Advance Quiet Time enabled. This flag should be set to true in order to allow using OpenHours and ClosedDays. |
start_activity | string | The unique identifier for the first activity in the journey. |
start_condition | object | The segment that defines which users are participants in the journey. |
state | string | The current status of the journey. Possible values are: DRAFT - The journey is being developed and hasn't been published yet. ACTIVE - The journey has been developed and published. Depending on the journey's schedule, the journey may currently be running or scheduled to start running at a later time. If a journey's status is ACTIVE, you can't add, change, or remove activities from it. COMPLETED - The journey has been published and has finished running. All participants have entered the journey and no participants are waiting to complete the journey or any activities in the journey. CANCELLED - The journey has been stopped. If a journey's status is CANCELLED, you can't add, change, or remove activities or segment settings from the journey. CLOSED - The journey has been published and has started running. It may have also passed its scheduled end time, or passed its scheduled start time and a refresh frequency hasn't been specified for it. If a journey's status is CLOSED, you can't add participants to it, and no existing participants can enter the journey for the first time. However, any existing participants who are currently waiting to start an activity may continue the journey. (DRAFT, ACTIVE, COMPLETED, CANCELLED, CLOSED, PAUSED) |
timezone_estimation_methods | array | An array of time zone estimation methods, if any, to use for determining an Endpoints time zone if the Endpoint does not have a value for the Demographic.Timezone attribute. PHONE_NUMBER - A time zone is determined based on the Endpoint.Address and Endpoint.Location.Country. POSTAL_CODE - A time zone is determined based on the Endpoint.Location.PostalCode and Endpoint.Location.Country. POSTAL_CODE detection is only supported in the United States, United Kingdom, Australia, New Zealand, Canada, France, Italy, Spain, Germany and in regions where Amazon Pinpoint is available. |
wait_for_quiet_time | boolean | Indicates whether endpoints in quiet hours should enter a wait activity until quiet hours have elapsed. |
tags | object | This object is not used or supported. |
| Name | Datatype | Description |
|---|---|---|
item | array | An array of responses, one for each journey that's associated with the application. |
next_token | string | The string to use in a subsequent request to get the next page of results in a paginated response. This value is null if there are no additional pages. |
Methods
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
get_journey | select | application-id, journey-id, region | Retrieves information about the status, configuration, and other settings for a journey. | |
list_journeys | select | application-id, region | page-size, token | Retrieves information about the status, configuration, and other settings for all the journeys that are associated with an application. |
create_journey | insert | application-id, region, WriteJourneyRequest | Creates a journey for an application. | |
update_journey | update | application-id, journey-id, region, WriteJourneyRequest | Updates the configuration and other settings for a journey. | |
update_journey_state | update | application-id, journey-id, region, JourneyStateRequest | Cancels (stops) an active journey. | |
delete_journey | delete | application-id, journey-id, region | Deletes a journey from an application. |
Parameters
Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.
| Name | Datatype | Description |
|---|---|---|
application-id | string | The unique identifier for the application. This identifier is displayed as the Project ID on the Amazon Pinpoint console. |
journey-id | string | The unique identifier for the journey. |
region | string | AWS region (default: us-east-1) |
page-size | string | The maximum number of items to include in each page of a paginated response. This parameter is not supported for application, campaign, and journey metrics. |
token | string | The NextToken string that specifies which page of results to return in a paginated response. |
SELECT examples
- get_journey
- list_journeys
Retrieves information about the status, configuration, and other settings for a journey.
SELECT
activities,
application_id,
closed_days,
creation_date,
id,
journey_channel_settings,
last_modified_date,
limits,
local_time,
name,
open_hours,
quiet_time,
refresh_frequency,
refresh_on_segment_update,
schedule,
sending_schedule,
start_activity,
start_condition,
state,
timezone_estimation_methods,
wait_for_quiet_time,
tags
FROM aws.pinpoint.journeys
WHERE `application-id` = '{{ application-id }}' -- required
AND `journey-id` = '{{ journey-id }}' -- required
AND region = '{{ region }}' -- required
;
Retrieves information about the status, configuration, and other settings for all the journeys that are associated with an application.
SELECT
item,
next_token
FROM aws.pinpoint.journeys
WHERE `application-id` = '{{ application-id }}' -- required
AND region = '{{ region }}' -- required
AND `page-size` = '{{ page-size }}'
AND token = '{{ token }}'
;
INSERT examples
- create_journey
- Manifest
Creates a journey for an application.
INSERT INTO aws.pinpoint.journeys (
WriteJourneyRequest,
`application-id`,
region
)
SELECT
'{{ WriteJourneyRequest }}' /* required */,
'{{ application-id }}',
'{{ region }}'
RETURNING
journey_response
;
# Description fields are for documentation purposes
- name: journeys
props:
- name: application-id
value: "{{ application-id }}"
description: Required parameter for the journeys resource.
- name: region
value: "{{ region }}"
description: Required parameter for the journeys resource.
- name: WriteJourneyRequest
description: |
Specifies the configuration and other settings for a journey.
value:
Activities: "{{ Activities }}"
CreationDate: "{{ CreationDate }}"
LastModifiedDate: "{{ LastModifiedDate }}"
Limits:
DailyCap: {{ DailyCap }}
EndpointReentryCap: {{ EndpointReentryCap }}
MessagesPerSecond: {{ MessagesPerSecond }}
EndpointReentryInterval: "{{ EndpointReentryInterval }}"
TimeframeCap:
Cap: {{ Cap }}
Days: {{ Days }}
TotalCap: {{ TotalCap }}
LocalTime: {{ LocalTime }}
Name: "{{ Name }}"
QuietTime:
End: "{{ End }}"
Start: "{{ Start }}"
RefreshFrequency: "{{ RefreshFrequency }}"
Schedule:
EndTime: "{{ EndTime }}"
StartTime: "{{ StartTime }}"
Timezone: "{{ Timezone }}"
StartActivity: "{{ StartActivity }}"
StartCondition:
Description: "{{ Description }}"
EventStartCondition:
EventFilter:
Dimensions:
Attributes: "{{ Attributes }}"
EventType: "{{ EventType }}"
Metrics: "{{ Metrics }}"
FilterType: "{{ FilterType }}"
SegmentId: "{{ SegmentId }}"
SegmentStartCondition:
SegmentId: "{{ SegmentId }}"
State: "{{ State }}"
WaitForQuietTime: {{ WaitForQuietTime }}
RefreshOnSegmentUpdate: {{ RefreshOnSegmentUpdate }}
JourneyChannelSettings:
ConnectCampaignArn: "{{ ConnectCampaignArn }}"
ConnectCampaignExecutionRoleArn: "{{ ConnectCampaignExecutionRoleArn }}"
SendingSchedule: {{ SendingSchedule }}
OpenHours:
EMAIL: "{{ EMAIL }}"
SMS: "{{ SMS }}"
PUSH: "{{ PUSH }}"
VOICE: "{{ VOICE }}"
CUSTOM: "{{ CUSTOM }}"
ClosedDays:
EMAIL:
- Name: "{{ Name }}"
StartDateTime: "{{ StartDateTime }}"
EndDateTime: "{{ EndDateTime }}"
SMS:
- Name: "{{ Name }}"
StartDateTime: "{{ StartDateTime }}"
EndDateTime: "{{ EndDateTime }}"
PUSH:
- Name: "{{ Name }}"
StartDateTime: "{{ StartDateTime }}"
EndDateTime: "{{ EndDateTime }}"
VOICE:
- Name: "{{ Name }}"
StartDateTime: "{{ StartDateTime }}"
EndDateTime: "{{ EndDateTime }}"
CUSTOM:
- Name: "{{ Name }}"
StartDateTime: "{{ StartDateTime }}"
EndDateTime: "{{ EndDateTime }}"
TimezoneEstimationMethods:
- "{{ TimezoneEstimationMethods }}"
UPDATE examples
- update_journey
- update_journey_state
Updates the configuration and other settings for a journey.
UPDATE aws.pinpoint.journeys
SET
WriteJourneyRequest = '{{ WriteJourneyRequest }}'
WHERE
`application-id` = '{{ application-id }}' --required
AND `journey-id` = '{{ journey-id }}' --required
AND region = '{{ region }}' --required
AND WriteJourneyRequest = '{{ WriteJourneyRequest }}' --required
RETURNING
journey_response;
Cancels (stops) an active journey.
UPDATE aws.pinpoint.journeys
SET
JourneyStateRequest = '{{ JourneyStateRequest }}'
WHERE
`application-id` = '{{ application-id }}' --required
AND `journey-id` = '{{ journey-id }}' --required
AND region = '{{ region }}' --required
AND JourneyStateRequest = '{{ JourneyStateRequest }}' --required
RETURNING
journey_response;
DELETE examples
- delete_journey
Deletes a journey from an application.
DELETE FROM aws.pinpoint.journeys
WHERE `application-id` = '{{ application-id }}' --required
AND `journey-id` = '{{ journey-id }}' --required
AND region = '{{ region }}' --required
;