import Onesignal from '@onesignal/node-onesignal';
const configuration = Onesignal.createConfiguration({
restApiKey: 'YOUR_REST_API_KEY',
});
const apiInstance = new Onesignal.DefaultApi(configuration);
// string | Your OneSignal App ID in UUID v4 format.
const appId: string = "YOUR_APP_ID";
// CreateJourneyRequest
const createJourneyRequest: Onesignal.CreateJourneyRequest = {
name: "YOUR_NAME",
};
try {
const response = await apiInstance.createJourney(appId, createJourneyRequest);
console.log(response);
} catch (e) {
if (e instanceof Onesignal.ApiException) {
// `e.errorMessages` flattens any error-envelope shape to a `string[]`;
// the raw parsed body remains on `e.body`.
console.error("createJourney failed: HTTP " + e.code, e.errorMessages);
} else {
throw e;
}
}
import onesignal
from onesignal.api import default_api
from onesignal.models import *
from pprint import pprint
# See configuration.py for a list of all supported configuration parameters.
# Some of the OneSignal endpoints require ORGANIZATION_API_KEY token for authorization, while others require REST_API_KEY.
# We recommend adding both of them in the configuration page so that you will not need to figure it out yourself.
configuration = onesignal.Configuration(
rest_api_key = "YOUR_REST_API_KEY", # App REST API key required for most endpoints
organization_api_key = "YOUR_ORGANIZATION_API_KEY" # Organization key is only required for creating new apps and other top-level endpoints
)
# Enter a context with an instance of the API client
with onesignal.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = default_api.DefaultApi(api_client)
app_id = "YOUR_APP_ID" # Your OneSignal App ID in UUID v4 format.
create_journey_request = CreateJourneyRequest(
name="YOUR_NAME",
)
try:
# Create journey
api_response = api_instance.create_journey(app_id, create_journey_request)
pprint(api_response)
except onesignal.ApiException as e:
print("Exception when calling DefaultApi->create_journey: %s\n" % e)
print("Status Code: %s" % e.status)
print("Response Body: %s" % e.body)
<?php
require_once(__DIR__ . '/vendor/autoload.php');
// Configure Bearer authorization: rest_api_key
$config = onesignal\client\Configuration::getDefaultConfiguration()
->setRestApiKeyToken('YOUR_REST_API_KEY')
->setOrganizationApiKeyToken('YOUR_ORGANIZATION_API_KEY');
$apiInstance = new onesignal\client\Api\DefaultApi(
// If you want use custom http client, pass your client which implements `GuzzleHttp\ClientInterface`.
// This is optional, `GuzzleHttp\Client` will be used as default.
new GuzzleHttp\Client(),
$config
);
$app_id = 'YOUR_APP_ID'; // string | Your OneSignal App ID in UUID v4 format.
$create_journey_request = new \onesignal\client\model\CreateJourneyRequest(['name' => 'YOUR_NAME']); // \onesignal\client\model\CreateJourneyRequest
try {
$result = $apiInstance->createJourney($app_id, $create_journey_request);
print_r($result);
} catch (\onesignal\client\ApiException $e) {
echo 'Exception when calling DefaultApi->createJourney: ', $e->getMessage(), PHP_EOL;
echo 'Status Code: ', $e->getCode(), PHP_EOL;
// getErrorMessages() flattens any error-envelope shape to a string[];
// the raw body remains on getResponseBody().
echo 'Error Messages: ', implode(', ', $e->getErrorMessages()), PHP_EOL;
echo 'Response Body: ', $e->getResponseBody(), PHP_EOL;
} catch (\Exception $e) {
echo 'Exception when calling DefaultApi->createJourney: ', $e->getMessage(), PHP_EOL;
}
package main
import (
"context"
"fmt"
"os"
"github.com/OneSignal/onesignal-go-api/v5"
)
func main() {
appId := "YOUR_APP_ID" // string | Your OneSignal App ID in UUID v4 format.
createJourneyRequest := *onesignal.NewCreateJourneyRequest("YOUR_NAME") // CreateJourneyRequest |
configuration := onesignal.NewConfiguration()
apiClient := onesignal.NewAPIClient(configuration)
restAuth := context.WithValue(context.Background(), onesignal.RestApiKey, "YOUR_REST_API_KEY") // App REST API key required for most endpoints
resp, r, err := apiClient.DefaultApi.CreateJourney(restAuth, appId).CreateJourneyRequest(createJourneyRequest).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `DefaultApi.CreateJourney``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
if apiErr, ok := err.(*onesignal.GenericOpenAPIError); ok {
// ErrorMessages() flattens any error-envelope shape to a []string;
// the raw body remains on Body().
fmt.Fprintf(os.Stderr, "Error Messages: %v\n", apiErr.ErrorMessages())
fmt.Fprintf(os.Stderr, "Response Body: %s\n", apiErr.Body())
}
}
// response from `CreateJourney`: Journey
fmt.Fprintf(os.Stdout, "Response from `DefaultApi.CreateJourney`: %v\n", resp)
}
require 'onesignal'
# setup authorization
OneSignal.configure do |config|
# Configure Bearer authorization: rest_api_key
config.rest_api_key = 'YOUR_REST_API_KEY'
end
api_instance = OneSignal::DefaultApi.new
app_id = 'YOUR_APP_ID' # String | Your OneSignal App ID in UUID v4 format.
create_journey_request = OneSignal::CreateJourneyRequest.new({name: 'YOUR_NAME'}) # CreateJourneyRequest |
begin
# Create journey
result = api_instance.create_journey(app_id, create_journey_request)
p result
rescue OneSignal::ApiError => e
puts "Error when calling DefaultApi->create_journey: #{e}"
puts "Status Code: #{e.code}"
# `e.error_messages` flattens any error-envelope shape to an Array<String>;
# the raw body remains on `e.response_body`.
puts "Error Messages: #{e.error_messages}"
puts "Response Body: #{e.response_body}"
end
// Import classes:
import java.util.Arrays;
import java.util.List;
import com.onesignal.client.ApiClient;
import com.onesignal.client.ApiException;
import com.onesignal.client.Configuration;
import com.onesignal.client.auth.*;
import com.onesignal.client.model.*;
import com.onesignal.client.api.DefaultApi;
public class Example {
public static void main(String[] args) {
ApiClient defaultClient = Configuration.getDefaultApiClient();
defaultClient.setBasePath("https://api.onesignal.com");
// Configure HTTP bearer authorization: rest_api_key
HttpBearerAuth rest_api_key = (HttpBearerAuth) defaultClient.getAuthentication("rest_api_key");
rest_api_key.setBearerToken("YOUR_REST_API_KEY");
DefaultApi apiInstance = new DefaultApi(defaultClient);
String appId = "YOUR_APP_ID"; // String | Your OneSignal App ID in UUID v4 format.
CreateJourneyRequest createJourneyRequest = new CreateJourneyRequest().name("YOUR_NAME"); // CreateJourneyRequest |
try {
Journey result = apiInstance.createJourney(appId, createJourneyRequest);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling DefaultApi#createJourney");
System.err.println("Status code: " + e.getCode());
// getErrorMessages() flattens any error-envelope shape to a List<String>;
// the raw body remains on getResponseBody().
System.err.println("Error messages: " + e.getErrorMessages());
System.err.println("Reason: " + e.getResponseBody());
System.err.println("Response headers: " + e.getResponseHeaders());
e.printStackTrace();
}
}
}
using System;
using System.Collections.Generic;
using System.Diagnostics;
using OneSignalApi.Api;
using OneSignalApi.Client;
using OneSignalApi.Model;
namespace Example
{
public class CreateJourneyExample
{
public static void Main()
{
Configuration config = new Configuration();
config.BasePath = "https://api.onesignal.com";
// Configure Bearer token for authorization: rest_api_key
config.AccessToken = "YOUR_REST_API_KEY";
var apiInstance = new DefaultApi(config);
var appId = "YOUR_APP_ID"; // string | Your OneSignal App ID in UUID v4 format.
var createJourneyRequest = new CreateJourneyRequest(name: "YOUR_NAME"); // CreateJourneyRequest |
try
{
// Create journey
Journey result = apiInstance.CreateJourney(appId, createJourneyRequest);
Debug.WriteLine(result);
}
catch (ApiException e)
{
Debug.Print("Exception when calling DefaultApi.CreateJourney: " + e.Message );
Debug.Print("Status Code: "+ e.ErrorCode);
// e.ErrorMessages flattens any error-envelope shape to an IReadOnlyList<string>;
// the raw body remains on e.ErrorContent.
Debug.Print("Error Messages: " + string.Join(", ", e.ErrorMessages));
Debug.Print("Response Body: " + e.ErrorContent);
Debug.Print(e.StackTrace);
}
}
}
}
use onesignal_rust_api::apis::configuration::Configuration;
use onesignal_rust_api::apis::default_api;
use onesignal_rust_api::models;
#[tokio::main]
async fn main() {
let mut configuration = Configuration::new();
configuration.rest_api_key_token = Some("YOUR_REST_API_KEY".to_string());
// Realistic values are pulled from the spec's `example:` fields where present.
let app_id: &str = "YOUR_APP_ID";
let create_journey_request: models::CreateJourneyRequest = models::CreateJourneyRequest::new("YOUR_NAME".to_string());
match default_api::create_journey(&configuration, app_id, create_journey_request).await {
Ok(resp) => println!("{:?}", resp),
Err(e @ onesignal_rust_api::apis::Error::ResponseError(_)) => {
// `e.error_messages()` flattens any error-envelope shape to a Vec<String>;
// the raw response remains on the ResponseError variant.
eprintln!("create_journey failed: {:?}", e.error_messages());
}
Err(e) => eprintln!("create_journey failed: {:?}", e),
}
}
import Onesignal from '@onesignal/node-onesignal';
const configuration = Onesignal.createConfiguration({
restApiKey: 'YOUR_REST_API_KEY',
});
const apiInstance = new Onesignal.DefaultApi(configuration);
// string | Your OneSignal App ID in UUID v4 format.
const appId: string = "YOUR_APP_ID";
// CreateJourneyRequest
const createJourneyRequest: Onesignal.CreateJourneyRequest = {
name: "YOUR_NAME",
};
try {
const response = await apiInstance.createJourney(appId, createJourneyRequest);
console.log(response);
} catch (e) {
if (e instanceof Onesignal.ApiException) {
// `e.errorMessages` flattens any error-envelope shape to a `string[]`;
// the raw parsed body remains on `e.body`.
console.error("createJourney failed: HTTP " + e.code, e.errorMessages);
} else {
throw e;
}
}
import onesignal
from onesignal.api import default_api
from onesignal.models import *
from pprint import pprint
# See configuration.py for a list of all supported configuration parameters.
# Some of the OneSignal endpoints require ORGANIZATION_API_KEY token for authorization, while others require REST_API_KEY.
# We recommend adding both of them in the configuration page so that you will not need to figure it out yourself.
configuration = onesignal.Configuration(
rest_api_key = "YOUR_REST_API_KEY", # App REST API key required for most endpoints
organization_api_key = "YOUR_ORGANIZATION_API_KEY" # Organization key is only required for creating new apps and other top-level endpoints
)
# Enter a context with an instance of the API client
with onesignal.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = default_api.DefaultApi(api_client)
app_id = "YOUR_APP_ID" # Your OneSignal App ID in UUID v4 format.
create_journey_request = CreateJourneyRequest(
name="YOUR_NAME",
)
try:
# Create journey
api_response = api_instance.create_journey(app_id, create_journey_request)
pprint(api_response)
except onesignal.ApiException as e:
print("Exception when calling DefaultApi->create_journey: %s\n" % e)
print("Status Code: %s" % e.status)
print("Response Body: %s" % e.body)
<?php
require_once(__DIR__ . '/vendor/autoload.php');
// Configure Bearer authorization: rest_api_key
$config = onesignal\client\Configuration::getDefaultConfiguration()
->setRestApiKeyToken('YOUR_REST_API_KEY')
->setOrganizationApiKeyToken('YOUR_ORGANIZATION_API_KEY');
$apiInstance = new onesignal\client\Api\DefaultApi(
// If you want use custom http client, pass your client which implements `GuzzleHttp\ClientInterface`.
// This is optional, `GuzzleHttp\Client` will be used as default.
new GuzzleHttp\Client(),
$config
);
$app_id = 'YOUR_APP_ID'; // string | Your OneSignal App ID in UUID v4 format.
$create_journey_request = new \onesignal\client\model\CreateJourneyRequest(['name' => 'YOUR_NAME']); // \onesignal\client\model\CreateJourneyRequest
try {
$result = $apiInstance->createJourney($app_id, $create_journey_request);
print_r($result);
} catch (\onesignal\client\ApiException $e) {
echo 'Exception when calling DefaultApi->createJourney: ', $e->getMessage(), PHP_EOL;
echo 'Status Code: ', $e->getCode(), PHP_EOL;
// getErrorMessages() flattens any error-envelope shape to a string[];
// the raw body remains on getResponseBody().
echo 'Error Messages: ', implode(', ', $e->getErrorMessages()), PHP_EOL;
echo 'Response Body: ', $e->getResponseBody(), PHP_EOL;
} catch (\Exception $e) {
echo 'Exception when calling DefaultApi->createJourney: ', $e->getMessage(), PHP_EOL;
}
package main
import (
"context"
"fmt"
"os"
"github.com/OneSignal/onesignal-go-api/v5"
)
func main() {
appId := "YOUR_APP_ID" // string | Your OneSignal App ID in UUID v4 format.
createJourneyRequest := *onesignal.NewCreateJourneyRequest("YOUR_NAME") // CreateJourneyRequest |
configuration := onesignal.NewConfiguration()
apiClient := onesignal.NewAPIClient(configuration)
restAuth := context.WithValue(context.Background(), onesignal.RestApiKey, "YOUR_REST_API_KEY") // App REST API key required for most endpoints
resp, r, err := apiClient.DefaultApi.CreateJourney(restAuth, appId).CreateJourneyRequest(createJourneyRequest).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `DefaultApi.CreateJourney``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
if apiErr, ok := err.(*onesignal.GenericOpenAPIError); ok {
// ErrorMessages() flattens any error-envelope shape to a []string;
// the raw body remains on Body().
fmt.Fprintf(os.Stderr, "Error Messages: %v\n", apiErr.ErrorMessages())
fmt.Fprintf(os.Stderr, "Response Body: %s\n", apiErr.Body())
}
}
// response from `CreateJourney`: Journey
fmt.Fprintf(os.Stdout, "Response from `DefaultApi.CreateJourney`: %v\n", resp)
}
require 'onesignal'
# setup authorization
OneSignal.configure do |config|
# Configure Bearer authorization: rest_api_key
config.rest_api_key = 'YOUR_REST_API_KEY'
end
api_instance = OneSignal::DefaultApi.new
app_id = 'YOUR_APP_ID' # String | Your OneSignal App ID in UUID v4 format.
create_journey_request = OneSignal::CreateJourneyRequest.new({name: 'YOUR_NAME'}) # CreateJourneyRequest |
begin
# Create journey
result = api_instance.create_journey(app_id, create_journey_request)
p result
rescue OneSignal::ApiError => e
puts "Error when calling DefaultApi->create_journey: #{e}"
puts "Status Code: #{e.code}"
# `e.error_messages` flattens any error-envelope shape to an Array<String>;
# the raw body remains on `e.response_body`.
puts "Error Messages: #{e.error_messages}"
puts "Response Body: #{e.response_body}"
end
// Import classes:
import java.util.Arrays;
import java.util.List;
import com.onesignal.client.ApiClient;
import com.onesignal.client.ApiException;
import com.onesignal.client.Configuration;
import com.onesignal.client.auth.*;
import com.onesignal.client.model.*;
import com.onesignal.client.api.DefaultApi;
public class Example {
public static void main(String[] args) {
ApiClient defaultClient = Configuration.getDefaultApiClient();
defaultClient.setBasePath("https://api.onesignal.com");
// Configure HTTP bearer authorization: rest_api_key
HttpBearerAuth rest_api_key = (HttpBearerAuth) defaultClient.getAuthentication("rest_api_key");
rest_api_key.setBearerToken("YOUR_REST_API_KEY");
DefaultApi apiInstance = new DefaultApi(defaultClient);
String appId = "YOUR_APP_ID"; // String | Your OneSignal App ID in UUID v4 format.
CreateJourneyRequest createJourneyRequest = new CreateJourneyRequest().name("YOUR_NAME"); // CreateJourneyRequest |
try {
Journey result = apiInstance.createJourney(appId, createJourneyRequest);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling DefaultApi#createJourney");
System.err.println("Status code: " + e.getCode());
// getErrorMessages() flattens any error-envelope shape to a List<String>;
// the raw body remains on getResponseBody().
System.err.println("Error messages: " + e.getErrorMessages());
System.err.println("Reason: " + e.getResponseBody());
System.err.println("Response headers: " + e.getResponseHeaders());
e.printStackTrace();
}
}
}
using System;
using System.Collections.Generic;
using System.Diagnostics;
using OneSignalApi.Api;
using OneSignalApi.Client;
using OneSignalApi.Model;
namespace Example
{
public class CreateJourneyExample
{
public static void Main()
{
Configuration config = new Configuration();
config.BasePath = "https://api.onesignal.com";
// Configure Bearer token for authorization: rest_api_key
config.AccessToken = "YOUR_REST_API_KEY";
var apiInstance = new DefaultApi(config);
var appId = "YOUR_APP_ID"; // string | Your OneSignal App ID in UUID v4 format.
var createJourneyRequest = new CreateJourneyRequest(name: "YOUR_NAME"); // CreateJourneyRequest |
try
{
// Create journey
Journey result = apiInstance.CreateJourney(appId, createJourneyRequest);
Debug.WriteLine(result);
}
catch (ApiException e)
{
Debug.Print("Exception when calling DefaultApi.CreateJourney: " + e.Message );
Debug.Print("Status Code: "+ e.ErrorCode);
// e.ErrorMessages flattens any error-envelope shape to an IReadOnlyList<string>;
// the raw body remains on e.ErrorContent.
Debug.Print("Error Messages: " + string.Join(", ", e.ErrorMessages));
Debug.Print("Response Body: " + e.ErrorContent);
Debug.Print(e.StackTrace);
}
}
}
}
use onesignal_rust_api::apis::configuration::Configuration;
use onesignal_rust_api::apis::default_api;
use onesignal_rust_api::models;
#[tokio::main]
async fn main() {
let mut configuration = Configuration::new();
configuration.rest_api_key_token = Some("YOUR_REST_API_KEY".to_string());
// Realistic values are pulled from the spec's `example:` fields where present.
let app_id: &str = "YOUR_APP_ID";
let create_journey_request: models::CreateJourneyRequest = models::CreateJourneyRequest::new("YOUR_NAME".to_string());
match default_api::create_journey(&configuration, app_id, create_journey_request).await {
Ok(resp) => println!("{:?}", resp),
Err(e @ onesignal_rust_api::apis::Error::ResponseError(_)) => {
// `e.error_messages()` flattens any error-envelope shape to a Vec<String>;
// the raw response remains on the ResponseError variant.
eprintln!("create_journey failed: {:?}", e.error_messages());
}
Err(e) => eprintln!("create_journey failed: {:?}", e),
}
}
Create a new Journey programmatically. A journey is defined by an entry audience and an ordered list of nodes.
Journeys are always created in the draft state. The request accepts only writable fields: sending a server-controlled field such as state or id returns a 400 validation error. Activate a journey with the Update journey API or from the OneSignal dashboard.
Server-assigned id fields on nodes and branches are rejected on create with a 400 validation error. Use client_node_id if you need to reference a node from elsewhere in the same request.
You can retrieve the create schema with operation=create before you construct the Journey document.Authenticate with your App API Key. The authenticated key must have permission to create journeys. Only name is required. Sending an empty nodes array creates a journey with only its required defaults.
The audience sets who enters the journey. It is either segment-based or event-triggered. Segments are referenced by UUID; every segment id (here, in early_exit, and in segment_membership branch conditions) must be a valid UUID that references an existing segment, or the request is rejected.
future_additions_only applies only to segment audiences and defaults to false. When true, only users who newly match the segment after the journey is activated can enter. Users already in the segment at activation never enter, even if they leave and rejoin later.For event-triggered audiences, attributes is a list of condition groups. Send a single group, whose conditions are AND’d together; sending more than one group is rejected. Valid operators are equal, not_equal, less, less_or_equal, greater_or_equal, greater, is, is_not, exists, not_exists, before, and after. The value field is not required for exists and not_exists.An event name is limited to 255 characters, and each attribute key to 255 and value to 1024.equal, not_equal, less, less_or_equal, greater_or_equal, and greater compare numerically: value must be a number (sent as a string, e.g. "5" or "19.99"). A non-numeric value on these operators is rejected. Use is and is_not to compare non-numeric values such as a currency code or plan name.
Each window’s day_of_week (1–7, where 1 is Monday) is a sibling of start and end, not nested inside them. start and end hold only hour and minute. A window with no day_of_week applies to every day of the week. Each window must span at least 15 minutes.A day-agnostic window is stored as seven per-day windows and returned in its original day-agnostic form, so a node read from a response can be sent back unchanged. One consequence: seven per-day windows that all share the same start and end are also returned as a single day-agnostic window.windows apply only when relative_to is schedule_in_timezone. With relative_to: "last_active_time" a journey must not send windows; doing so is rejected. A last_active_time node is returned without a windows key, so a node read from a response can be sent back unchanged.A send_push, send_email, or send_sms node’s template_id must reference an existing template of the matching channel (a push template for send_push, an email template for send_email, an SMS template for send_sms), or the request is rejected. Likewise a send_iam node’s iam_id and a send_webhook node’s webhook_id must reference existing resources. You may omit these ids while drafting, but a send node requires its id before the journey can go live.A wait node’s duration_seconds must be between 60 seconds and 1 year (31556952 seconds). These bounds are enforced on create and on every update, in every state.A tag node’s assignments keys are limited to 255 characters and values to 1024. An empty string value removes the tag. A node’s optional annotation is limited to 1024.
split_range takes between 2 and 25 branches, and their weights must sum to 100. randomize_on_entry defaults to false. When true, the node assigns each user to a branch at random on entry.
yes_no requires exactly two branches. The branch with a condition is the “yes” branch; the branch without one is the “no” branch.
wait_until takes between 1 and 25 condition branches. The optional expiration timer exits the journey when exits is true, or continues to convergence when false. Its duration_seconds follows the same 60 second to 1 year bounds as a wait node. Omit expiration (or set it to null) to wait indefinitely.
An on_notification_action condition branches on what a user did with a message sent earlier in the same journey. The sending node it references must be a message node (send_push, send_email, send_sms, send_iam, or send_webhook) that sits earlier in the flow than the branching node.On create, the sending node has no server id yet. Give it a client_node_id that is unique within the journey, and send that same value on the condition. client_node_id on the condition is write-only: the API resolves it to the sending node’s id.
Which actions are meaningful depends on the sending node’s channel:
Sending node
Supported actions
send_push
received, clicked
send_email
received, clicked, opened
send_sms
received, opened
send_iam
clicked, opened
A send_webhook node reports no user actions, so no action applies to it. An action outside this table is accepted by the API but never matches, so the branch is never taken.An event_trigger condition’s attributes use the same list-of-lists shape and operators as an event-triggered audience. Its optional entry_event_match_attributes is a list of objects, each with two fields, used to match an incoming event against the event that entered the user into the journey:
entry_event_key is the property on the entry event; incoming_event_key is the property on the incoming event compared against it. Both are required and must be non-blank.
schedule timestamps must use UTC (Z or +00:00). A start_at must be at least 5 minutes in the future, and a stop_at must be in the future and later than start_at.
reentry_rules sets how long a user must wait before re-entering. duration_seconds must be at least 600 (10 minutes); a shorter value is rejected. Omit reentry_rules or send null to disallow re-entry.
early_exit removes a user before the journey completes. At least one rule must be set under rules; an early_exit that configures no rule is rejected. Send early_exit: null to remove early exit entirely.
A successful request returns 201 Created with the full journey in its draft state, including server-assigned id fields and a concurrency_key. Pass that concurrency_key unchanged on a later Update journey request to avoid overwriting a concurrent change. Activate the draft by sending state: "active" on that same endpoint.The journey id and state, and node and branch id fields, are server-controlled. Sending any of them is rejected with 400 invalid-payload. A body app_id is ignored: the journey is always created under the app in the URL, and the response returns that app_id.
The request failed validation. This covers schema failures (for example, an unknown node kind, an unknown property, or a server-controlled field) and business-logic failures (for example, split_range branch weights that do not sum to 100). meta.path points to the offending field when applicable.
403
journey-not-entitled
Journeys are not enabled for this app.
429
Rate limit exceeded. Wait the number of seconds in the Retry-After header before retrying. See Rate limits.
Coded errors use the shape { "errors": [{ "code", "title", "meta" }] }; for validation errors the failing field is in meta.attribute, with meta.path for the offending property. Branch on code and meta, not on title, whose wording can change between releases.
Conditions that remove a user from the journey before it completes. At least one rule must be set under rules; an early_exit that configures no rule is rejected. Send null to remove early exit entirely, or null for an individual rule to drop just that rule.
Journey state. Read-only. New journeys are created as draft. processing is a transient state while an activation is in progress, and archived is a journey that has been stopped. Change it through the state field on Update journey.
ISO 8601 time the journey was activated, or null. Read-only. May stay null briefly after you set state to active: activation is enqueued for processing, and started_at populates once the journey finishes processing and becomes active.
Conditions that remove a user from the journey before it completes. At least one rule must be set under rules; an early_exit that configures no rule is rejected. Send null to remove early exit entirely, or null for an individual rule to drop just that rule.
Opaque optimistic-concurrency token. Read-only. Pass it back on update to guard against overwriting a concurrent change (409 journey-stale). Send it back exactly as read from this response; do not construct or parse it.
Was this page helpful?
{"docsConfig":{"theme":"mint","$schema":"https://mintlify.com/docs.json","name":"OneSignal Documentation","description":"OneSignal is a platform for sending push notifications, emails, in-app messages, and SMS campaigns via a single API, Journey Builder, and a dashboard.","colors":{"primary":"#3A3DB3","light":"#E54B4D","dark":"#3A3DB3"},"logo":{"light":"https://mintcdn.com/onesignal/yJcueeDCO7UpHnnY/logo/OneSignal-Logo.svg?fit=max\u0026auto=format\u0026n=yJcueeDCO7UpHnnY\u0026q=85\u0026s=1fcfb6fef6d820fd9d99c74850711107","dark":"https://mintcdn.com/onesignal/s4WC_KzLxf8ornqq/logo/OneSignal-Logo-White.svg?fit=max\u0026auto=format\u0026n=s4WC_KzLxf8ornqq\u0026q=85\u0026s=2573a53b5aea961e18c82b3af8f31925"},"favicon":"https://mintcdn.com/onesignal/SGduBFHpiRdg5l6h/favicon.ico?fit=max\u0026auto=format\u0026n=SGduBFHpiRdg5l6h\u0026q=85\u0026s=c0a99fadc0553c658a83741c5611cef4","api":{"examples":{"languages":["curl","typescript","python","php","go","ruby","java","csharp","rust"],"autogenerate":true}},"navbar":{"links":[{"href":"mailto:support@onesignal.com","label":"Support"}],"primary":{"type":"button","label":"Dashboard","href":"https://dashboard.onesignal.com"}},"footer":{"socials":{"github":"https://github.com/OneSignal","linkedin":"https://linkedin.com/company/onesignal","youtube":"https://www.youtube.com/@onesignalofficial/playlists"}},"seo":{"metatags":{"apple-mobile-web-app-title":"OneSignal Docs"}},"fonts":{"family":"Nunito Sans"},"styling":{"eyebrows":"breadcrumbs","latex":true},"integrations":{"ga4":{"measurementId":"G-2DGWL0VYP5"},"posthog":{"apiKey":"phc_vZpvE0f5eyzcOt30FHer34yddVmNdo9kmlMVRBzLMtn","apiHost":"https://eu.i.posthog.com","sessionRecording":true}},"contextual":{"options":["copy","view","chatgpt","claude"],"display":"header"},"navigation":{"languages":[{"language":"en","href":"docs/en/home"},{"language":"cn","href":"docs/cn/home"},{"language":"ko","href":"docs/ko/home"},{"language":"ja","href":"docs/ja/home"},{"language":"tr","href":"docs/tr/home"},{"language":"pt-BR","href":"docs/pt-BR/home"},{"language":"es","href":"docs/es/home"},{"language":"fr","href":"docs/fr/home"}]}},"deployment":{"deploymentMetadataValue":{"subdomain":"onesignal","hasAudioNarration":false,"actualSubdomain":"onesignal","customDomains":["documentation.onesignal.com"],"gitSource":{"type":"github","owner":"onesignal","repo":"mintlify-docs","deployBranch":"main","contentDirectory":"","isPrivate":true,"mountPath":"","label":""},"feedback":{"thumbs":true},"entitlements":{"AI_CHAT":{"status":"ENABLED"},"WEB_MCP":{"status":"ENABLED"},"NARRATION":{"status":"ENABLED"}},"buildId":"6aee76d2161a823262d5e93f","clientVersion":"0.0.4087","searchFilterCounts":[{"language":"en","tag":"User Guides","count":203},{"language":"es","tag":"Guías del Usuario","count":178},{"language":"fr","tag":"Guides utilisateur","count":178},{"language":"ja","tag":"ユーザーガイド","count":178},{"language":"ko","tag":"사용자 가이드","count":178},{"language":"pt-BR","tag":"Guia do Usuário","count":178},{"language":"tr","tag":"Kullanıcı Kılavuzları","count":178},{"language":"cn","tag":"用户指南","count":176},{"language":"en","tag":"Message channels","count":90},{"language":"es","tag":"Canales de mensajería","count":84},{"language":"fr","tag":"Canaux de messagerie","count":84},{"language":"ja","tag":"メッセージングチャネル","count":84},{"language":"ko","tag":"메시지 채널","count":84},{"language":"pt-BR","tag":"Canais de mensagem","count":84},{"language":"tr","tag":"Mesaj kanalları","count":84},{"language":"cn","tag":"消息渠道","count":83},{"language":"default","tag":"API Reference","count":68},{"language":"default","tag":"API reference","count":64},{"language":"en","tag":"Analytics \u0026 Integrations","count":53},{"language":"es","tag":"Analítica \u0026 Integraciones","count":52},{"language":"fr","tag":"Analyses et intégrations","count":52},{"language":"ja","tag":"分析 \u0026 統合","count":52},{"language":"ko","tag":"분석 \u0026 통합","count":52},{"language":"pt-BR","tag":"Análises \u0026 Integrações","count":52},{"language":"tr","tag":"Analitik ve Entegrasyonlar","count":52},{"language":"cn","tag":"分析和集成","count":51},{"language":"cn","tag":"开发者指南","count":48},{"language":"es","tag":"Guías del desarrollador","count":48},{"language":"fr","tag":"Guides développeur","count":48},{"language":"ja","tag":"開発者ガイド","count":48},{"language":"ko","tag":"개발자 가이드","count":48},{"language":"tr","tag":"Geliştirici Kılavuzları","count":48},{"language":"en","tag":"Developer Guides","count":47},{"language":"pt-BR","tag":"Guia de desenvolvedor","count":47},{"language":"en","tag":"Integrations","count":37},{"language":"es","tag":"Integraciones","count":37},{"language":"fr","tag":"Intégrations","count":37},{"language":"ja","tag":"統合","count":37},{"language":"ko","tag":"통합","count":37},{"language":"pt-BR","tag":"Integrações","count":37},{"language":"tr","tag":"Entegrasyonlar","count":37},{"language":"cn","tag":"集成","count":36},{"language":"en","tag":"Tutorials","count":35},{"language":"cn","tag":"推送通知","count":31},{"language":"cn","tag":"OneSignal 作为目的地","count":31},{"language":"en","tag":"Push","count":31},{"language":"en","tag":"OneSignal as destination","count":31},{"language":"es","tag":"Push notificaciones","count":31},{"language":"es","tag":"OneSignal como destino","count":31},{"language":"fr","tag":"Push","count":31},{"language":"fr","tag":"OneSignal comme destination","count":31},{"language":"ja","tag":"プッシュ通知","count":31},{"language":"ja","tag":"OneSignal as 宛先","count":31},{"language":"ko","tag":"푸시","count":31},{"language":"ko","tag":"OneSignal을 데이터 목적지로 사용","count":31},{"language":"pt-BR","tag":"Push notificações","count":31},{"language":"pt-BR","tag":"OneSignal como destino","count":31},{"language":"tr","tag":"Anlık bildirimler","count":31},{"language":"tr","tag":"OneSignal hedef","count":31},{"language":"en","tag":"Mobile SDKs","count":26},{"language":"cn","tag":"移动SDK","count":25},{"language":"es","tag":"SDKs móviles","count":25},{"language":"fr","tag":"SDK mobiles","count":25},{"language":"ja","tag":"モバイルSDK","count":25},{"language":"ko","tag":"모바일 SDKs","count":25},{"language":"pt-BR","tag":"SDKs móveis","count":25},{"language":"tr","tag":"Mobil SDK'lar","count":25},{"language":"cn","tag":"教程","count":24},{"language":"es","tag":"Tutoriales","count":24},{"language":"fr","tag":"Tutoriels","count":24},{"language":"ja","tag":"チュートリアル","count":24},{"language":"ko","tag":"튜토리얼","count":24},{"language":"pt-BR","tag":"Tutoriais","count":24},{"language":"tr","tag":"Eğitimler","count":24},{"language":"en","tag":"Mobile SDK setup","count":19},{"language":"cn","tag":"移动SDK设置","count":18},{"language":"es","tag":"Configuración del SDK móvil","count":18},{"language":"fr","tag":"Configuration SDK mobile","count":18},{"language":"ja","tag":"モバイルSDKセットアップ","count":18},{"language":"ko","tag":"모바일 SDK 설정","count":18},{"language":"pt-BR","tag":"Configuração do SDK móvel","count":18},{"language":"tr","tag":"Mobil SDK kurulumu","count":18},{"language":"default","tag":"Messages","count":9},{"language":"default","tag":"Users","count":9},{"language":"default","tag":"Organization","count":9},{"language":"default","tag":"Journeys","count":8},{"language":"default","tag":"Deprecated","count":6},{"language":"default","tag":"Templates","count":6},{"language":"default","tag":"Subscriptions","count":6},{"language":"default","tag":"Segments","count":5}]},"assistantConfig":{"enableStarterQuestions":false,"deflection":{"enabled":true,"email":"support@onesignal.com","showHelpButton":true}},"basePath":"","hasChatPermissions":true,"hasWebMcpPermissions":true,"toggles":[{"name":"kill-isr","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-mintlify-slack","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-integrations-settings","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"rbac-expansion","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-pr-grouping","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"custom-prefix","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"analytics-v7","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"user-flows-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"no-publish-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-onboarding","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"llms-txt-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving-live","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"stripTemperatureMiddleware","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"support-platform-pylon-zendesk","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"instant-rollback","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications-server","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-fable","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fixed-ai-action-pricing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automation-resolve-merge-conflict","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"scoped-publishing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"mintql","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"page-level-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-version-history-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"billing-page-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"full-page-search","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workspace-projects","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"assistant-v5","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fork-pr-previews","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"revalidation-jwt","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-sso-scim","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"hobby-abuse-scan","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"dashboard-inbox","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-signup","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-dual-write","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-enabled","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"approve-review-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-metadata","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"sso-setup-deadline-banner","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-serve","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"live-agents","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"comment-mode","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false}],"googleFontsInlined":true},"customCss":[],"page":{"pagePath":"reference/create-journey","slug":"/reference/create-journey","pageMetadata":{"title":"Create journey","tag":"BETA","openapi":"POST /apps/{app_id}/journeys","description":"Create a new journey with an audience and a node graph. Journeys are always created in the draft state.","keywords":["journeys API","create journey","journey automation","journey nodes","journey audience"],"href":"/reference/create-journey"},"description":{"compiledSource":"\"use strict\";\nconst {jsx: _jsx} = arguments[0];\nconst {useMDXComponents: _provideComponents} = arguments[0];\nfunction _createMdxContent(props) {\n const _components = {\n p: \"p\",\n ..._provideComponents(),\n ...props.components\n };\n return _jsx(_components.p, {\n children: \"Create a new journey with an audience and a node graph. Journeys are always created in the draft state.\"\n });\n}\nfunction MDXContent(props = {}) {\n const {wrapper: MDXLayout} = {\n ..._provideComponents(),\n ...props.components\n };\n return MDXLayout ? _jsx(MDXLayout, {\n ...props,\n children: _jsx(_createMdxContent, {\n ...props\n })\n }) : _createMdxContent(props);\n}\nreturn {\n default: MDXContent\n};\n","frontmatter":{},"scope":{}},"pageType":"default","mdx":{"mdxSource":{"compiledSource":"\"use strict\";const{Fragment:_Fragment,jsx:_jsx,jsxs:_jsxs}=arguments[0];const{useMDXComponents:_provideComponents}=arguments[0];function _createMdxContent(props){const _components={a:`a`,code:`code`,hr:`hr`,li:`li`,p:`p`,pre:`pre`,span:`span`,strong:`strong`,tbody:`tbody`,td:`td`,th:`th`,thead:`thead`,tr:`tr`,ul:`ul`,..._provideComponents(),...props.components},{CodeBlock,CodeGroup,Heading,Info,Note,Table,Warning}=_components;if(!CodeBlock)_missingMdxReference(`CodeBlock`,true);if(!CodeGroup)_missingMdxReference(`CodeGroup`,true);if(!Heading)_missingMdxReference(`Heading`,true);if(!Info)_missingMdxReference(`Info`,true);if(!Note)_missingMdxReference(`Note`,true);if(!Table)_missingMdxReference(`Table`,true);if(!Warning)_missingMdxReference(`Warning`,true);return _jsxs(_Fragment,{children:[_jsx(Info,{children:_jsxs(_components.p,{children:[_jsx(_components.strong,{children:`Beta.`}),` The Journeys API is in beta. Endpoints and response fields can still change.`]})}),`\n`,_jsx(Heading,{level:`2`,id:`overview`,children:`Overview`}),`\n`,_jsxs(_components.p,{children:[`Create a new `,_jsx(_components.a,{href:`/docs/en/journeys-overview`,children:`Journey`}),` programmatically. A journey is defined by an entry `,_jsx(_components.code,{children:`audience`}),` and an ordered list of `,_jsx(_components.code,{children:`nodes`}),`.`]}),`\n`,_jsx(Note,{children:_jsxs(_components.p,{children:[`Journeys are always created in the `,_jsx(_components.code,{children:`draft`}),` state. The request accepts only writable fields: sending a server-controlled field such as `,_jsx(_components.code,{children:`state`}),` or `,_jsx(_components.code,{children:`id`}),` returns a `,_jsx(_components.code,{children:`400`}),` validation error. Activate a journey with the `,_jsx(_components.a,{href:`/reference/update-journey`,children:`Update journey`}),` API or from the `,_jsx(_components.a,{href:`/docs/en/managing-journeys`,children:`OneSignal dashboard`}),`.`]})}),`\n`,_jsx(Warning,{children:_jsxs(_components.p,{children:[`Server-assigned `,_jsx(_components.code,{children:`id`}),` fields on nodes and branches are rejected on create with a `,_jsx(_components.code,{children:`400`}),` validation error. Use `,_jsx(_components.code,{children:`client_node_id`}),` if you need to reference a node from elsewhere in the same request.`]})}),`\n`,_jsx(_components.hr,{}),`\n`,_jsx(Heading,{level:`2`,id:`how-to-use-this-api`,children:`How to use this API`}),`\n`,_jsxs(_components.p,{children:[`You can retrieve the `,_jsx(_components.a,{href:`/reference/get-journey-schema`,children:`create schema`}),` with `,_jsx(_components.code,{children:`operation=create`}),` before you construct the Journey document.`]}),`\n`,_jsxs(_components.p,{children:[`Authenticate with your `,_jsx(_components.a,{href:`/docs/en/keys-and-ids`,children:`App API Key`}),`. The authenticated key must have permission to create journeys. Only `,_jsx(_components.code,{children:`name`}),` is required. Sending an empty `,_jsx(_components.code,{children:`nodes`}),` array creates a journey with only its required defaults.`]}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`14`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`14`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"name\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"Welcome series\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"description\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"Onboard new users over their first week.\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"audience\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"kind\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"segment\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"included_segment_ids\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: [`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"YOUR_SEGMENT_ID\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`],`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"excluded_segment_ids\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: []`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` },`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"nodes\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: [`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` { `}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:`\"kind\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"send_push\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:`\"template_id\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"YOUR_TEMPLATE_ID\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` },`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` { `}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:`\"kind\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"wait\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:`\"duration_seconds\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:`86400`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` },`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` { `}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:`\"kind\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"send_email\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:`\"template_id\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"YOUR_TEMPLATE_ID\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` }`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` ]`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),`\n`,_jsx(Heading,{level:`3`,id:`define-the-audience`,children:`Define the audience`}),`\n`,_jsxs(_components.p,{children:[`The `,_jsx(_components.code,{children:`audience`}),` sets who enters the journey. It is either segment-based or event-triggered. Segments are referenced by UUID; every segment id (here, in `,_jsx(_components.code,{children:`early_exit`}),`, and in `,_jsx(_components.code,{children:`segment_membership`}),` branch conditions) must be a valid UUID that references an existing segment, or the request is rejected.`]}),`\n`,_jsxs(CodeGroup,{children:[_jsx(CodeBlock,{filename:`Segment`,numberOfLines:`8`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`8`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"audience\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"kind\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"segment\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"included_segment_ids\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: [`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"YOUR_SEGMENT_ID\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`],`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"excluded_segment_ids\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: [],`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"future_additions_only\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:`false`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` }`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),_jsx(CodeBlock,{filename:`Event-triggered`,numberOfLines:`9`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`9`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"audience\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"kind\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"event_trigger\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"name\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"purchase\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"attributes\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: [`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` [{ `}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:`\"key\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"item_count\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:`\"operator\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"greater_or_equal\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:`\"value\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"5\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` }]`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` ]`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` }`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})})]}),`\n`,_jsxs(_components.p,{children:[_jsx(_components.code,{children:`future_additions_only`}),` applies only to segment audiences and defaults to `,_jsx(_components.code,{children:`false`}),`. When `,_jsx(_components.code,{children:`true`}),`, only users who newly match the segment after the journey is activated can enter. Users already in the segment at activation never enter, even if they leave and rejoin later.`]}),`\n`,_jsxs(_components.p,{children:[`For event-triggered audiences, `,_jsx(_components.code,{children:`attributes`}),` is a list of condition groups. Send a single group, whose conditions are AND’d together; sending more than one group is rejected. Valid operators are `,_jsx(_components.code,{children:`equal`}),`, `,_jsx(_components.code,{children:`not_equal`}),`, `,_jsx(_components.code,{children:`less`}),`, `,_jsx(_components.code,{children:`less_or_equal`}),`, `,_jsx(_components.code,{children:`greater_or_equal`}),`, `,_jsx(_components.code,{children:`greater`}),`, `,_jsx(_components.code,{children:`is`}),`, `,_jsx(_components.code,{children:`is_not`}),`, `,_jsx(_components.code,{children:`exists`}),`, `,_jsx(_components.code,{children:`not_exists`}),`, `,_jsx(_components.code,{children:`before`}),`, and `,_jsx(_components.code,{children:`after`}),`. The `,_jsx(_components.code,{children:`value`}),` field is not required for `,_jsx(_components.code,{children:`exists`}),` and `,_jsx(_components.code,{children:`not_exists`}),`.`]}),`\n`,_jsxs(_components.p,{children:[`An event `,_jsx(_components.code,{children:`name`}),` is limited to 255 characters, and each attribute `,_jsx(_components.code,{children:`key`}),` to 255 and `,_jsx(_components.code,{children:`value`}),` to 1024.`]}),`\n`,_jsxs(_components.p,{children:[_jsx(_components.code,{children:`equal`}),`, `,_jsx(_components.code,{children:`not_equal`}),`, `,_jsx(_components.code,{children:`less`}),`, `,_jsx(_components.code,{children:`less_or_equal`}),`, `,_jsx(_components.code,{children:`greater_or_equal`}),`, and `,_jsx(_components.code,{children:`greater`}),` compare numerically: `,_jsx(_components.code,{children:`value`}),` must be a number (sent as a string, e.g. `,_jsx(_components.code,{children:`\"5\"`}),` or `,_jsx(_components.code,{children:`\"19.99\"`}),`). A non-numeric `,_jsx(_components.code,{children:`value`}),` on these operators is rejected. Use `,_jsx(_components.code,{children:`is`}),` and `,_jsx(_components.code,{children:`is_not`}),` to compare non-numeric values such as a currency code or plan name.`]}),`\n`,_jsx(Heading,{level:`3`,id:`add-nodes`,children:`Add nodes`}),`\n`,_jsxs(_components.p,{children:[_jsx(_components.code,{children:`nodes`}),` is an ordered list. Linear nodes run in sequence. Each node requires a `,_jsx(_components.code,{children:`kind`}),`, plus the fields for that kind.`]}),`\n`,_jsxs(CodeGroup,{children:[_jsx(CodeBlock,{filename:`Linear nodes`,numberOfLines:`7`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`7`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`[`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` { `}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:`\"kind\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"wait\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:`\"duration_seconds\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:`3600`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` },`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` { `}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:`\"kind\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"send_push\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:`\"template_id\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"YOUR_TEMPLATE_ID\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` },`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` { `}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:`\"kind\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"send_iam\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:`\"iam_id\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"YOUR_IAM_ID\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:`\"user_ttl_seconds\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:`86400`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` },`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` { `}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:`\"kind\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"send_webhook\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:`\"webhook_id\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"YOUR_WEBHOOK_ID\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` },`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` { `}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:`\"kind\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"tag\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:`\"assignments\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: { `}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:`\"loyalty_tier\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"gold\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:`\"churned\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` } }`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`]`})}),`\n`]})})}),_jsx(CodeBlock,{filename:`time_window`,numberOfLines:`9`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`9`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"kind\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"time_window\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"relative_to\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"schedule_in_timezone\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"time_zone\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"America/New_York\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"use_user_time_zone\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:`false`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"windows\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: [`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` { `}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:`\"start\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: { `}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:`\"hour\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:`9`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` }, `}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:`\"end\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: { `}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:`\"hour\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:`17`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` }, `}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:`\"day_of_week\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:`1`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` }`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` ]`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})})]}),`\n`,_jsxs(_components.p,{children:[`Each window’s `,_jsx(_components.code,{children:`day_of_week`}),` (1–7, where `,_jsx(_components.code,{children:`1`}),` is Monday) is a sibling of `,_jsx(_components.code,{children:`start`}),` and `,_jsx(_components.code,{children:`end`}),`, not nested inside them. `,_jsx(_components.code,{children:`start`}),` and `,_jsx(_components.code,{children:`end`}),` hold only `,_jsx(_components.code,{children:`hour`}),` and `,_jsx(_components.code,{children:`minute`}),`. A window with no `,_jsx(_components.code,{children:`day_of_week`}),` applies to every day of the week. Each window must span at least 15 minutes.`]}),`\n`,_jsxs(_components.p,{children:[`A day-agnostic window is stored as seven per-day windows and returned in its original day-agnostic form, so a node read from a response can be sent back unchanged. One consequence: seven per-day windows that all share the same `,_jsx(_components.code,{children:`start`}),` and `,_jsx(_components.code,{children:`end`}),` are also returned as a single day-agnostic window.`]}),`\n`,_jsxs(_components.p,{children:[_jsx(_components.code,{children:`windows`}),` apply only when `,_jsx(_components.code,{children:`relative_to`}),` is `,_jsx(_components.code,{children:`schedule_in_timezone`}),`. With `,_jsx(_components.code,{children:`relative_to: \"last_active_time\"`}),` a journey must not send `,_jsx(_components.code,{children:`windows`}),`; doing so is rejected. A `,_jsx(_components.code,{children:`last_active_time`}),` node is returned without a `,_jsx(_components.code,{children:`windows`}),` key, so a node read from a response can be sent back unchanged.`]}),`\n`,_jsxs(_components.p,{children:[`A `,_jsx(_components.code,{children:`send_push`}),`, `,_jsx(_components.code,{children:`send_email`}),`, or `,_jsx(_components.code,{children:`send_sms`}),` node’s `,_jsx(_components.code,{children:`template_id`}),` must reference an existing template of the matching channel (a push template for `,_jsx(_components.code,{children:`send_push`}),`, an email template for `,_jsx(_components.code,{children:`send_email`}),`, an SMS template for `,_jsx(_components.code,{children:`send_sms`}),`), or the request is rejected. Likewise a `,_jsx(_components.code,{children:`send_iam`}),` node’s `,_jsx(_components.code,{children:`iam_id`}),` and a `,_jsx(_components.code,{children:`send_webhook`}),` node’s `,_jsx(_components.code,{children:`webhook_id`}),` must reference existing resources. You may omit these ids while drafting, but a send node requires its id before the journey can go live.`]}),`\n`,_jsxs(_components.p,{children:[`A `,_jsx(_components.code,{children:`wait`}),` node’s `,_jsx(_components.code,{children:`duration_seconds`}),` must be between 60 seconds and 1 year (31556952 seconds). These bounds are enforced on create and on every update, in every state.`]}),`\n`,_jsxs(_components.p,{children:[`A `,_jsx(_components.code,{children:`tag`}),` node’s `,_jsx(_components.code,{children:`assignments`}),` keys are limited to 255 characters and values to 1024. An empty string value removes the tag. A node’s optional `,_jsx(_components.code,{children:`annotation`}),` is limited to 1024.`]}),`\n`,_jsx(Heading,{level:`3`,id:`branching-nodes`,children:`Branching nodes`}),`\n`,_jsxs(_components.p,{children:[`Branching nodes nest their sub-graphs inline through `,_jsx(_components.code,{children:`branches`}),`. After a branching node resolves, flow continues to the next sibling node.`]}),`\n`,_jsxs(CodeGroup,{children:[_jsx(CodeBlock,{filename:`split_range`,numberOfLines:`8`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`8`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"kind\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"split_range\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"randomize_on_entry\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:`false`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"branches\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: [`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` { `}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:`\"weight\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:`50`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:`\"nodes\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: [{ `}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:`\"kind\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"send_push\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:`\"template_id\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"YOUR_TEMPLATE_ID\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` }] },`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` { `}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:`\"weight\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:`50`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:`\"nodes\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: [] }`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` ]`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),_jsx(CodeBlock,{filename:`yes_no`,numberOfLines:`14`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`14`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"kind\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"yes_no\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"branches\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: [`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` {`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"condition\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"kind\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"segment_membership\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"included_segment_ids\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: [`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"YOUR_SEGMENT_ID\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`],`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"excluded_segment_ids\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: []`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` },`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"nodes\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: [{ `}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:`\"kind\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"send_email\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:`\"template_id\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"YOUR_TEMPLATE_ID\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` }]`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` },`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` { `}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:`\"nodes\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: [] }`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` ]`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),_jsx(CodeBlock,{filename:`wait_until`,numberOfLines:`10`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`10`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"kind\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"wait_until\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"branches\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: [`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` {`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"condition\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: { `}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:`\"kind\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"event_trigger\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:`\"name\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"purchase\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:`\"attributes\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: [] },`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"nodes\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: [{ `}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:`\"kind\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"tag\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:`\"assignments\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: { `}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:`\"converted\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"true\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` } }]`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` }`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` ],`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"expiration\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: { `}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:`\"duration_seconds\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:`604800`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:`\"exits\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:`true`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` }`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})})]}),`\n`,_jsxs(_components.ul,{children:[`\n`,_jsxs(_components.li,{children:[_jsx(_components.code,{children:`split_range`}),` takes between 2 and 25 branches, and their weights must sum to 100. `,_jsx(_components.code,{children:`randomize_on_entry`}),` defaults to `,_jsx(_components.code,{children:`false`}),`. When `,_jsx(_components.code,{children:`true`}),`, the node assigns each user to a branch at random on entry.`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.code,{children:`yes_no`}),` requires exactly two branches. The branch with a `,_jsx(_components.code,{children:`condition`}),` is the “yes” branch; the branch without one is the “no” branch.`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.code,{children:`wait_until`}),` takes between 1 and 25 condition branches. The optional `,_jsx(_components.code,{children:`expiration`}),` timer exits the journey when `,_jsx(_components.code,{children:`exits`}),` is `,_jsx(_components.code,{children:`true`}),`, or continues to convergence when `,_jsx(_components.code,{children:`false`}),`. Its `,_jsx(_components.code,{children:`duration_seconds`}),` follows the same 60 second to 1 year bounds as a `,_jsx(_components.code,{children:`wait`}),` node. Omit `,_jsx(_components.code,{children:`expiration`}),` (or set it to `,_jsx(_components.code,{children:`null`}),`) to wait indefinitely.`]}),`\n`]}),`\n`,_jsx(Heading,{level:`3`,id:`branch-conditions`,children:`Branch conditions`}),`\n`,_jsxs(_components.p,{children:[_jsx(_components.code,{children:`yes_no`}),` and `,_jsx(_components.code,{children:`wait_until`}),` branches use a `,_jsx(_components.code,{children:`condition`}),` object selected by its `,_jsx(_components.code,{children:`kind`}),`:`]}),`\n`,_jsxs(Table,{children:[_jsx(_components.thead,{children:_jsxs(_components.tr,{children:[_jsx(_components.th,{children:_jsx(_components.code,{children:`kind`})}),_jsx(_components.th,{children:`Fields`})]})}),_jsxs(_components.tbody,{children:[_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`segment_membership`})}),_jsxs(_components.td,{children:[_jsx(_components.code,{children:`included_segment_ids`}),`, `,_jsx(_components.code,{children:`excluded_segment_ids`}),` (segment UUIDs)`]})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`on_notification_action`})}),_jsxs(_components.td,{children:[_jsx(_components.code,{children:`action`}),`, plus `,_jsx(_components.code,{children:`sending_node_id`}),` or `,_jsx(_components.code,{children:`client_node_id`}),` to reference the sending node`]})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`event_trigger`})}),_jsxs(_components.td,{children:[_jsx(_components.code,{children:`name`}),`, `,_jsx(_components.code,{children:`attributes`}),`, optional `,_jsx(_components.code,{children:`entry_event_match_attributes`})]})]})]})]}),`\n`,_jsxs(_components.p,{children:[`An `,_jsx(_components.code,{children:`on_notification_action`}),` condition branches on what a user did with a message sent earlier in the same journey. The sending node it references must be a message node (`,_jsx(_components.code,{children:`send_push`}),`, `,_jsx(_components.code,{children:`send_email`}),`, `,_jsx(_components.code,{children:`send_sms`}),`, `,_jsx(_components.code,{children:`send_iam`}),`, or `,_jsx(_components.code,{children:`send_webhook`}),`) that sits earlier in the flow than the branching node.`]}),`\n`,_jsxs(_components.p,{children:[`On create, the sending node has no server `,_jsx(_components.code,{children:`id`}),` yet. Give it a `,_jsx(_components.code,{children:`client_node_id`}),` that is unique within the journey, and send that same value on the condition. `,_jsx(_components.code,{children:`client_node_id`}),` on the condition is write-only: the API resolves it to the sending node’s `,_jsx(_components.code,{children:`id`}),`.`]}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`23`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`23`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"nodes\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: [`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` {`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"kind\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"send_push\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"client_node_id\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"welcome_push\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"template_id\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"YOUR_TEMPLATE_ID\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` },`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` {`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"kind\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"yes_no\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"branches\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: [`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` {`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"condition\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"kind\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"on_notification_action\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"action\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"clicked\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"client_node_id\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"welcome_push\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` },`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"nodes\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: [{ `}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:`\"kind\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"send_email\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:`\"template_id\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"YOUR_TEMPLATE_ID\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` }]`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` },`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` { `}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:`\"nodes\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: [] }`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` ]`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` }`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` ]`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),`\n`,_jsx(_components.p,{children:`Which actions are meaningful depends on the sending node’s channel:`}),`\n`,_jsxs(Table,{children:[_jsx(_components.thead,{children:_jsxs(_components.tr,{children:[_jsx(_components.th,{children:`Sending node`}),_jsx(_components.th,{children:`Supported actions`})]})}),_jsxs(_components.tbody,{children:[_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`send_push`})}),_jsxs(_components.td,{children:[_jsx(_components.code,{children:`received`}),`, `,_jsx(_components.code,{children:`clicked`})]})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`send_email`})}),_jsxs(_components.td,{children:[_jsx(_components.code,{children:`received`}),`, `,_jsx(_components.code,{children:`clicked`}),`, `,_jsx(_components.code,{children:`opened`})]})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`send_sms`})}),_jsxs(_components.td,{children:[_jsx(_components.code,{children:`received`}),`, `,_jsx(_components.code,{children:`opened`})]})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`send_iam`})}),_jsxs(_components.td,{children:[_jsx(_components.code,{children:`clicked`}),`, `,_jsx(_components.code,{children:`opened`})]})]})]})]}),`\n`,_jsxs(_components.p,{children:[`A `,_jsx(_components.code,{children:`send_webhook`}),` node reports no user actions, so no action applies to it. An action outside this table is accepted by the API but never matches, so the branch is never taken.`]}),`\n`,_jsxs(_components.p,{children:[`An `,_jsx(_components.code,{children:`event_trigger`}),` condition’s `,_jsx(_components.code,{children:`attributes`}),` use the same list-of-lists shape and operators as an event-triggered audience. Its optional `,_jsx(_components.code,{children:`entry_event_match_attributes`}),` is a list of objects, each with two fields, used to match an incoming event against the event that entered the user into the journey:`]}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`5`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`5`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"entry_event_match_attributes\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: [`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` { `}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:`\"entry_event_key\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"product_id\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:`\"incoming_event_key\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"product_id\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` }`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` ]`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),`\n`,_jsxs(_components.p,{children:[_jsx(_components.code,{children:`entry_event_key`}),` is the property on the entry event; `,_jsx(_components.code,{children:`incoming_event_key`}),` is the property on the incoming event compared against it. Both are required and must be non-blank.`]}),`\n`,_jsx(Heading,{level:`3`,id:`lifecycle-and-early-exit`,children:`Lifecycle and early exit`}),`\n`,_jsxs(_components.p,{children:[`Optionally configure `,_jsx(_components.code,{children:`schedule`}),`, `,_jsx(_components.code,{children:`reentry_rules`}),`, and `,_jsx(_components.code,{children:`early_exit`}),` at the journey level.`]}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`13`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`13`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"schedule\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: { `}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:`\"start_at\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"2026-07-01T14:00:00Z\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:`\"stop_at\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"2026-08-01T14:00:00Z\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` },`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"reentry_rules\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: { `}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:`\"duration_seconds\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:`86400`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` },`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"early_exit\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"rules\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"on_segment\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: { `}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:`\"included_segment_ids\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: [`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"YOUR_SEGMENT_ID\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`] },`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"on_event\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: { `}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:`\"name\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"exit_event\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` },`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"on_session\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:`true`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"when_not_in_audience\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:`true`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` },`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"tag_on_early_exit\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: { `}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:`\"has_exited\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"true\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` }`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` }`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),`\n`,_jsxs(_components.ul,{children:[`\n`,_jsxs(_components.li,{children:[_jsx(_components.code,{children:`schedule`}),` timestamps must use UTC (`,_jsx(_components.code,{children:`Z`}),` or `,_jsx(_components.code,{children:`+00:00`}),`). A `,_jsx(_components.code,{children:`start_at`}),` must be at least 5 minutes in the future, and a `,_jsx(_components.code,{children:`stop_at`}),` must be in the future and later than `,_jsx(_components.code,{children:`start_at`}),`.`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.code,{children:`reentry_rules`}),` sets how long a user must wait before re-entering. `,_jsx(_components.code,{children:`duration_seconds`}),` must be at least 600 (10 minutes); a shorter value is rejected. Omit `,_jsx(_components.code,{children:`reentry_rules`}),` or send `,_jsx(_components.code,{children:`null`}),` to disallow re-entry.`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.code,{children:`early_exit`}),` removes a user before the journey completes. At least one rule must be set under `,_jsx(_components.code,{children:`rules`}),`; an `,_jsx(_components.code,{children:`early_exit`}),` that configures no rule is rejected. Send `,_jsx(_components.code,{children:`early_exit: null`}),` to remove early exit entirely.`]}),`\n`]}),`\n`,_jsx(Heading,{level:`2`,id:`response`,children:`Response`}),`\n`,_jsxs(_components.p,{children:[`A successful request returns `,_jsx(_components.code,{children:`201 Created`}),` with the full journey in its `,_jsx(_components.code,{children:`draft`}),` state, including server-assigned `,_jsx(_components.code,{children:`id`}),` fields and a `,_jsx(_components.code,{children:`concurrency_key`}),`. Pass that `,_jsx(_components.code,{children:`concurrency_key`}),` unchanged on a later `,_jsx(_components.a,{href:`/reference/update-journey`,children:`Update journey`}),` request to avoid overwriting a concurrent change. Activate the draft by sending `,_jsx(_components.code,{children:`state: \"active\"`}),` on that same endpoint.`]}),`\n`,_jsxs(_components.p,{children:[`The journey `,_jsx(_components.code,{children:`id`}),` and `,_jsx(_components.code,{children:`state`}),`, and node and branch `,_jsx(_components.code,{children:`id`}),` fields, are server-controlled. Sending any of them is rejected with `,_jsx(_components.code,{children:`400 invalid-payload`}),`. A body `,_jsx(_components.code,{children:`app_id`}),` is ignored: the journey is always created under the app in the URL, and the response returns that `,_jsx(_components.code,{children:`app_id`}),`.`]}),`\n`,_jsx(Heading,{level:`3`,id:`error-responses`,children:`Error responses`}),`\n`,_jsxs(Table,{children:[_jsx(_components.thead,{children:_jsxs(_components.tr,{children:[_jsx(_components.th,{children:`Status`}),_jsx(_components.th,{children:`Code`}),_jsx(_components.th,{children:`Description`})]})}),_jsxs(_components.tbody,{children:[_jsxs(_components.tr,{children:[_jsx(_components.td,{\"data-numeric\":`true`,children:`400`}),_jsx(_components.td,{children:_jsx(_components.code,{children:`invalid-payload`})}),_jsxs(_components.td,{children:[`The request failed validation. This covers schema failures (for example, an unknown node `,_jsx(_components.code,{children:`kind`}),`, an unknown property, or a server-controlled field) and business-logic failures (for example, `,_jsx(_components.code,{children:`split_range`}),` branch weights that do not sum to 100). `,_jsx(_components.code,{children:`meta.path`}),` points to the offending field when applicable.`]})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{\"data-numeric\":`true`,children:`403`}),_jsx(_components.td,{children:_jsx(_components.code,{children:`journey-not-entitled`})}),_jsx(_components.td,{children:`Journeys are not enabled for this app.`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{\"data-numeric\":`true`,children:`429`}),_jsx(_components.td,{}),_jsxs(_components.td,{children:[`Rate limit exceeded. Wait the number of seconds in the `,_jsx(_components.code,{children:`Retry-After`}),` header before retrying. See `,_jsx(_components.a,{href:`/reference/rate-limits`,children:`Rate limits`}),`.`]})]})]})]}),`\n`,_jsxs(_components.p,{children:[`Coded errors use the shape `,_jsx(_components.code,{children:`{ \"errors\": [{ \"code\", \"title\", \"meta\" }] }`}),`; for validation errors the failing field is in `,_jsx(_components.code,{children:`meta.attribute`}),`, with `,_jsx(_components.code,{children:`meta.path`}),` for the offending property. Branch on `,_jsx(_components.code,{children:`code`}),` and `,_jsx(_components.code,{children:`meta`}),`, not on `,_jsx(_components.code,{children:`title`}),`, whose wording can change between releases.`]})]})}function MDXContent(props={}){const{wrapper:MDXLayout}={..._provideComponents(),...props.components};return MDXLayout?_jsx(MDXLayout,{...props,children:_jsx(_createMdxContent,{...props})}):_createMdxContent(props)}return{default:MDXContent};function _missingMdxReference(id,component){throw new Error(`Expected `+(component?`component`:`object`)+\" `\"+id+\"` to be defined: you likely forgot to import, pass, or provide it.\")}","frontmatter":{},"scope":{"config":{},"pageMetadata":{"title":"Create journey","tag":"BETA","openapi":"POST /apps/{app_id}/journeys","description":"Create a new journey with an audience and a node graph. Journeys are always created in the draft state.","keywords":["journeys API","create journey","journey automation","journey nodes","journey audience"],"href":"/reference/create-journey"}}},"mdxSourceWithNoJs":null},"mdxExtracts":{"tableOfContents":[{"title":"Overview","slug":"overview","depth":2,"children":[]},{"title":"How to use this API","slug":"how-to-use-this-api","depth":2,"children":[{"title":"Define the audience","slug":"define-the-audience","depth":3,"children":[]},{"title":"Add nodes","slug":"add-nodes","depth":3,"children":[]},{"title":"Branching nodes","slug":"branching-nodes","depth":3,"children":[]},{"title":"Branch conditions","slug":"branch-conditions","depth":3,"children":[]},{"title":"Lifecycle and early exit","slug":"lifecycle-and-early-exit","depth":3,"children":[]}]},{"title":"Response","slug":"response","depth":2,"children":[{"title":"Error responses","slug":"error-responses","depth":3,"children":[]}]}],"codeExamples":{}},"jsLinks":["/_mintlify/custom/onesignal/e069c1b9f3157e14/hotjar-koala.js","/_mintlify/custom/onesignal/3e5d03885ab32f49/intercom.js","/_mintlify/custom/onesignal/dbb7af4794d1b586/munchkin-marketo.js"],"openApiReferenceData":{"operation":{"summary":"Create journey","description":"Create a new journey with an audience and a node graph. Journeys are always created in the draft state.","operationId":"create-journey","x-codeSamples":[{"lang":"typescript","label":"Node.js SDK","source":"import Onesignal from '@onesignal/node-onesignal';\n\nconst configuration = Onesignal.createConfiguration({\n restApiKey: 'YOUR_REST_API_KEY',\n});\nconst apiInstance = new Onesignal.DefaultApi(configuration);\n\n// string | Your OneSignal App ID in UUID v4 format.\nconst appId: string = \"YOUR_APP_ID\";\n// CreateJourneyRequest\nconst createJourneyRequest: Onesignal.CreateJourneyRequest = {\n name: \"YOUR_NAME\",\n };\n\ntry {\n const response = await apiInstance.createJourney(appId, createJourneyRequest);\n console.log(response);\n} catch (e) {\n if (e instanceof Onesignal.ApiException) {\n // `e.errorMessages` flattens any error-envelope shape to a `string[]`;\n // the raw parsed body remains on `e.body`.\n console.error(\"createJourney failed: HTTP \" + e.code, e.errorMessages);\n } else {\n throw e;\n }\n}"},{"lang":"python","label":"Python SDK","source":"import onesignal\nfrom onesignal.api import default_api\nfrom onesignal.models import *\nfrom pprint import pprint\n\n# See configuration.py for a list of all supported configuration parameters.\n# Some of the OneSignal endpoints require ORGANIZATION_API_KEY token for authorization, while others require REST_API_KEY.\n# We recommend adding both of them in the configuration page so that you will not need to figure it out yourself.\nconfiguration = onesignal.Configuration(\n rest_api_key = \"YOUR_REST_API_KEY\", # App REST API key required for most endpoints\n organization_api_key = \"YOUR_ORGANIZATION_API_KEY\" # Organization key is only required for creating new apps and other top-level endpoints\n)\n\n\n# Enter a context with an instance of the API client\nwith onesignal.ApiClient(configuration) as api_client:\n # Create an instance of the API class\n api_instance = default_api.DefaultApi(api_client)\n app_id = \"YOUR_APP_ID\" # Your OneSignal App ID in UUID v4 format. \n create_journey_request = CreateJourneyRequest(\n name=\"YOUR_NAME\",\n ) \n\n try:\n # Create journey\n api_response = api_instance.create_journey(app_id, create_journey_request)\n pprint(api_response)\n except onesignal.ApiException as e:\n print(\"Exception when calling DefaultApi->create_journey: %s\\n\" % e)\n print(\"Status Code: %s\" % e.status)\n print(\"Response Body: %s\" % e.body)"},{"lang":"php","label":"PHP SDK","source":"\u003c?php\nrequire_once(__DIR__ . '/vendor/autoload.php');\n\n\n// Configure Bearer authorization: rest_api_key\n$config = onesignal\\client\\Configuration::getDefaultConfiguration()\n ->setRestApiKeyToken('YOUR_REST_API_KEY')\n ->setOrganizationApiKeyToken('YOUR_ORGANIZATION_API_KEY');\n\n\n\n$apiInstance = new onesignal\\client\\Api\\DefaultApi(\n // If you want use custom http client, pass your client which implements `GuzzleHttp\\ClientInterface`.\n // This is optional, `GuzzleHttp\\Client` will be used as default.\n new GuzzleHttp\\Client(),\n $config\n);\n$app_id = 'YOUR_APP_ID'; // string | Your OneSignal App ID in UUID v4 format.\n$create_journey_request = new \\onesignal\\client\\model\\CreateJourneyRequest(['name' => 'YOUR_NAME']); // \\onesignal\\client\\model\\CreateJourneyRequest\n\ntry {\n $result = $apiInstance->createJourney($app_id, $create_journey_request);\n print_r($result);\n} catch (\\onesignal\\client\\ApiException $e) {\n echo 'Exception when calling DefaultApi->createJourney: ', $e->getMessage(), PHP_EOL;\n echo 'Status Code: ', $e->getCode(), PHP_EOL;\n // getErrorMessages() flattens any error-envelope shape to a string[];\n // the raw body remains on getResponseBody().\n echo 'Error Messages: ', implode(', ', $e->getErrorMessages()), PHP_EOL;\n echo 'Response Body: ', $e->getResponseBody(), PHP_EOL;\n} catch (\\Exception $e) {\n echo 'Exception when calling DefaultApi->createJourney: ', $e->getMessage(), PHP_EOL;\n}"},{"lang":"go","label":"Go SDK","source":"package main\n\nimport (\n \"context\"\n \"fmt\"\n \"os\"\n\n \"github.com/OneSignal/onesignal-go-api/v5\"\n)\n\nfunc main() {\n appId := \"YOUR_APP_ID\" // string | Your OneSignal App ID in UUID v4 format.\n createJourneyRequest := *onesignal.NewCreateJourneyRequest(\"YOUR_NAME\") // CreateJourneyRequest | \n\n configuration := onesignal.NewConfiguration()\n apiClient := onesignal.NewAPIClient(configuration)\n\n restAuth := context.WithValue(context.Background(), onesignal.RestApiKey, \"YOUR_REST_API_KEY\") // App REST API key required for most endpoints\n\n resp, r, err := apiClient.DefaultApi.CreateJourney(restAuth, appId).CreateJourneyRequest(createJourneyRequest).Execute()\n\n if err != nil {\n fmt.Fprintf(os.Stderr, \"Error when calling `DefaultApi.CreateJourney``: %v\\n\", err)\n fmt.Fprintf(os.Stderr, \"Full HTTP response: %v\\n\", r)\n if apiErr, ok := err.(*onesignal.GenericOpenAPIError); ok {\n // ErrorMessages() flattens any error-envelope shape to a []string;\n // the raw body remains on Body().\n fmt.Fprintf(os.Stderr, \"Error Messages: %v\\n\", apiErr.ErrorMessages())\n fmt.Fprintf(os.Stderr, \"Response Body: %s\\n\", apiErr.Body())\n }\n }\n // response from `CreateJourney`: Journey\n fmt.Fprintf(os.Stdout, \"Response from `DefaultApi.CreateJourney`: %v\\n\", resp)\n}"},{"lang":"ruby","label":"Ruby SDK","source":"require 'onesignal'\n# setup authorization\nOneSignal.configure do |config|\n # Configure Bearer authorization: rest_api_key\n config.rest_api_key = 'YOUR_REST_API_KEY'\n\nend\n\napi_instance = OneSignal::DefaultApi.new\napp_id = 'YOUR_APP_ID' # String | Your OneSignal App ID in UUID v4 format.\ncreate_journey_request = OneSignal::CreateJourneyRequest.new({name: 'YOUR_NAME'}) # CreateJourneyRequest | \n\nbegin\n # Create journey\n result = api_instance.create_journey(app_id, create_journey_request)\n p result\nrescue OneSignal::ApiError => e\n puts \"Error when calling DefaultApi->create_journey: #{e}\"\n puts \"Status Code: #{e.code}\"\n # `e.error_messages` flattens any error-envelope shape to an Array\u003cString>;\n # the raw body remains on `e.response_body`.\n puts \"Error Messages: #{e.error_messages}\"\n puts \"Response Body: #{e.response_body}\"\nend"},{"lang":"java","label":"Java SDK","source":"// Import classes:\nimport java.util.Arrays;\nimport java.util.List;\nimport com.onesignal.client.ApiClient;\nimport com.onesignal.client.ApiException;\nimport com.onesignal.client.Configuration;\nimport com.onesignal.client.auth.*;\nimport com.onesignal.client.model.*;\nimport com.onesignal.client.api.DefaultApi;\n\npublic class Example {\n public static void main(String[] args) {\n ApiClient defaultClient = Configuration.getDefaultApiClient();\n defaultClient.setBasePath(\"https://api.onesignal.com\");\n \n // Configure HTTP bearer authorization: rest_api_key\n HttpBearerAuth rest_api_key = (HttpBearerAuth) defaultClient.getAuthentication(\"rest_api_key\");\n rest_api_key.setBearerToken(\"YOUR_REST_API_KEY\");\n\n DefaultApi apiInstance = new DefaultApi(defaultClient);\n String appId = \"YOUR_APP_ID\"; // String | Your OneSignal App ID in UUID v4 format.\n CreateJourneyRequest createJourneyRequest = new CreateJourneyRequest().name(\"YOUR_NAME\"); // CreateJourneyRequest | \n try {\n Journey result = apiInstance.createJourney(appId, createJourneyRequest);\n System.out.println(result);\n } catch (ApiException e) {\n System.err.println(\"Exception when calling DefaultApi#createJourney\");\n System.err.println(\"Status code: \" + e.getCode());\n // getErrorMessages() flattens any error-envelope shape to a List\u003cString>;\n // the raw body remains on getResponseBody().\n System.err.println(\"Error messages: \" + e.getErrorMessages());\n System.err.println(\"Reason: \" + e.getResponseBody());\n System.err.println(\"Response headers: \" + e.getResponseHeaders());\n e.printStackTrace();\n }\n }\n}"},{"lang":"csharp","label":"C# SDK","source":"using System;\nusing System.Collections.Generic;\nusing System.Diagnostics;\nusing OneSignalApi.Api;\nusing OneSignalApi.Client;\nusing OneSignalApi.Model;\n\nnamespace Example\n{\n public class CreateJourneyExample\n {\n public static void Main()\n {\n Configuration config = new Configuration();\n config.BasePath = \"https://api.onesignal.com\";\n // Configure Bearer token for authorization: rest_api_key\n config.AccessToken = \"YOUR_REST_API_KEY\";\n\n var apiInstance = new DefaultApi(config);\n var appId = \"YOUR_APP_ID\"; // string | Your OneSignal App ID in UUID v4 format.\n var createJourneyRequest = new CreateJourneyRequest(name: \"YOUR_NAME\"); // CreateJourneyRequest | \n\n try\n {\n // Create journey\n Journey result = apiInstance.CreateJourney(appId, createJourneyRequest);\n Debug.WriteLine(result);\n }\n catch (ApiException e)\n {\n Debug.Print(\"Exception when calling DefaultApi.CreateJourney: \" + e.Message );\n Debug.Print(\"Status Code: \"+ e.ErrorCode);\n // e.ErrorMessages flattens any error-envelope shape to an IReadOnlyList\u003cstring>;\n // the raw body remains on e.ErrorContent.\n Debug.Print(\"Error Messages: \" + string.Join(\", \", e.ErrorMessages));\n Debug.Print(\"Response Body: \" + e.ErrorContent);\n Debug.Print(e.StackTrace);\n }\n }\n }\n}"},{"lang":"rust","label":"Rust SDK","source":"use onesignal_rust_api::apis::configuration::Configuration;\nuse onesignal_rust_api::apis::default_api;\n\nuse onesignal_rust_api::models;\n\n\n#[tokio::main]\nasync fn main() {\n let mut configuration = Configuration::new();\n configuration.rest_api_key_token = Some(\"YOUR_REST_API_KEY\".to_string());\n\n\n // Realistic values are pulled from the spec's `example:` fields where present.\n let app_id: \u0026str = \"YOUR_APP_ID\";\n let create_journey_request: models::CreateJourneyRequest = models::CreateJourneyRequest::new(\"YOUR_NAME\".to_string());\n\n match default_api::create_journey(\u0026configuration, app_id, create_journey_request).await {\n Ok(resp) => println!(\"{:?}\", resp),\n Err(e @ onesignal_rust_api::apis::Error::ResponseError(_)) => {\n // `e.error_messages()` flattens any error-envelope shape to a Vec\u003cString>;\n // the raw response remains on the ResponseError variant.\n eprintln!(\"create_journey failed: {:?}\", e.error_messages());\n }\n Err(e) => eprintln!(\"create_journey failed: {:?}\", e),\n }\n}"}],"parameters":["28ecfe79-c7b6-493d-af5e-3789eac4481d","a591c14d-870f-44ee-b733-79502cd5ea3b","388310de-7fe0-4736-8e09-3502d3be56ef"],"requestBody":"c433f045-b3fe-43a2-b3f7-a6c2beef7c77","responses":{"201":"96cfbfcc-802f-4061-b1b6-08f251438cbe","400":"81df480a-989b-4d8b-b31a-13162645e931","403":"16cad19f-e045-4882-a9bc-b0ad8f639d30","429":"446b3725-ced3-417c-8945-567ec9f2bd3b"},"method":"post","type":"path","servers":["409091ad-6d30-4df4-9e86-f2a13d67c7b3"],"security":["a15236e2-20f7-4712-b1c5-1a2812fdcec4"],"path":"/apps/{app_id}/journeys","baseUrlOptions":["https://api.onesignal.com"],"title":"Create journey","codeSamples":[{"label":"Node.js SDK","lang":"typescript","source":"import Onesignal from '@onesignal/node-onesignal';\n\nconst configuration = Onesignal.createConfiguration({\n restApiKey: 'YOUR_REST_API_KEY',\n});\nconst apiInstance = new Onesignal.DefaultApi(configuration);\n\n// string | Your OneSignal App ID in UUID v4 format.\nconst appId: string = \"YOUR_APP_ID\";\n// CreateJourneyRequest\nconst createJourneyRequest: Onesignal.CreateJourneyRequest = {\n name: \"YOUR_NAME\",\n };\n\ntry {\n const response = await apiInstance.createJourney(appId, createJourneyRequest);\n console.log(response);\n} catch (e) {\n if (e instanceof Onesignal.ApiException) {\n // `e.errorMessages` flattens any error-envelope shape to a `string[]`;\n // the raw parsed body remains on `e.body`.\n console.error(\"createJourney failed: HTTP \" + e.code, e.errorMessages);\n } else {\n throw e;\n }\n}"},{"label":"Python SDK","lang":"python","source":"import onesignal\nfrom onesignal.api import default_api\nfrom onesignal.models import *\nfrom pprint import pprint\n\n# See configuration.py for a list of all supported configuration parameters.\n# Some of the OneSignal endpoints require ORGANIZATION_API_KEY token for authorization, while others require REST_API_KEY.\n# We recommend adding both of them in the configuration page so that you will not need to figure it out yourself.\nconfiguration = onesignal.Configuration(\n rest_api_key = \"YOUR_REST_API_KEY\", # App REST API key required for most endpoints\n organization_api_key = \"YOUR_ORGANIZATION_API_KEY\" # Organization key is only required for creating new apps and other top-level endpoints\n)\n\n\n# Enter a context with an instance of the API client\nwith onesignal.ApiClient(configuration) as api_client:\n # Create an instance of the API class\n api_instance = default_api.DefaultApi(api_client)\n app_id = \"YOUR_APP_ID\" # Your OneSignal App ID in UUID v4 format. \n create_journey_request = CreateJourneyRequest(\n name=\"YOUR_NAME\",\n ) \n\n try:\n # Create journey\n api_response = api_instance.create_journey(app_id, create_journey_request)\n pprint(api_response)\n except onesignal.ApiException as e:\n print(\"Exception when calling DefaultApi->create_journey: %s\\n\" % e)\n print(\"Status Code: %s\" % e.status)\n print(\"Response Body: %s\" % e.body)"},{"label":"PHP SDK","lang":"php","source":"\u003c?php\nrequire_once(__DIR__ . '/vendor/autoload.php');\n\n\n// Configure Bearer authorization: rest_api_key\n$config = onesignal\\client\\Configuration::getDefaultConfiguration()\n ->setRestApiKeyToken('YOUR_REST_API_KEY')\n ->setOrganizationApiKeyToken('YOUR_ORGANIZATION_API_KEY');\n\n\n\n$apiInstance = new onesignal\\client\\Api\\DefaultApi(\n // If you want use custom http client, pass your client which implements `GuzzleHttp\\ClientInterface`.\n // This is optional, `GuzzleHttp\\Client` will be used as default.\n new GuzzleHttp\\Client(),\n $config\n);\n$app_id = 'YOUR_APP_ID'; // string | Your OneSignal App ID in UUID v4 format.\n$create_journey_request = new \\onesignal\\client\\model\\CreateJourneyRequest(['name' => 'YOUR_NAME']); // \\onesignal\\client\\model\\CreateJourneyRequest\n\ntry {\n $result = $apiInstance->createJourney($app_id, $create_journey_request);\n print_r($result);\n} catch (\\onesignal\\client\\ApiException $e) {\n echo 'Exception when calling DefaultApi->createJourney: ', $e->getMessage(), PHP_EOL;\n echo 'Status Code: ', $e->getCode(), PHP_EOL;\n // getErrorMessages() flattens any error-envelope shape to a string[];\n // the raw body remains on getResponseBody().\n echo 'Error Messages: ', implode(', ', $e->getErrorMessages()), PHP_EOL;\n echo 'Response Body: ', $e->getResponseBody(), PHP_EOL;\n} catch (\\Exception $e) {\n echo 'Exception when calling DefaultApi->createJourney: ', $e->getMessage(), PHP_EOL;\n}"},{"label":"Go SDK","lang":"go","source":"package main\n\nimport (\n \"context\"\n \"fmt\"\n \"os\"\n\n \"github.com/OneSignal/onesignal-go-api/v5\"\n)\n\nfunc main() {\n appId := \"YOUR_APP_ID\" // string | Your OneSignal App ID in UUID v4 format.\n createJourneyRequest := *onesignal.NewCreateJourneyRequest(\"YOUR_NAME\") // CreateJourneyRequest | \n\n configuration := onesignal.NewConfiguration()\n apiClient := onesignal.NewAPIClient(configuration)\n\n restAuth := context.WithValue(context.Background(), onesignal.RestApiKey, \"YOUR_REST_API_KEY\") // App REST API key required for most endpoints\n\n resp, r, err := apiClient.DefaultApi.CreateJourney(restAuth, appId).CreateJourneyRequest(createJourneyRequest).Execute()\n\n if err != nil {\n fmt.Fprintf(os.Stderr, \"Error when calling `DefaultApi.CreateJourney``: %v\\n\", err)\n fmt.Fprintf(os.Stderr, \"Full HTTP response: %v\\n\", r)\n if apiErr, ok := err.(*onesignal.GenericOpenAPIError); ok {\n // ErrorMessages() flattens any error-envelope shape to a []string;\n // the raw body remains on Body().\n fmt.Fprintf(os.Stderr, \"Error Messages: %v\\n\", apiErr.ErrorMessages())\n fmt.Fprintf(os.Stderr, \"Response Body: %s\\n\", apiErr.Body())\n }\n }\n // response from `CreateJourney`: Journey\n fmt.Fprintf(os.Stdout, \"Response from `DefaultApi.CreateJourney`: %v\\n\", resp)\n}"},{"label":"Ruby SDK","lang":"ruby","source":"require 'onesignal'\n# setup authorization\nOneSignal.configure do |config|\n # Configure Bearer authorization: rest_api_key\n config.rest_api_key = 'YOUR_REST_API_KEY'\n\nend\n\napi_instance = OneSignal::DefaultApi.new\napp_id = 'YOUR_APP_ID' # String | Your OneSignal App ID in UUID v4 format.\ncreate_journey_request = OneSignal::CreateJourneyRequest.new({name: 'YOUR_NAME'}) # CreateJourneyRequest | \n\nbegin\n # Create journey\n result = api_instance.create_journey(app_id, create_journey_request)\n p result\nrescue OneSignal::ApiError => e\n puts \"Error when calling DefaultApi->create_journey: #{e}\"\n puts \"Status Code: #{e.code}\"\n # `e.error_messages` flattens any error-envelope shape to an Array\u003cString>;\n # the raw body remains on `e.response_body`.\n puts \"Error Messages: #{e.error_messages}\"\n puts \"Response Body: #{e.response_body}\"\nend"},{"label":"Java SDK","lang":"java","source":"// Import classes:\nimport java.util.Arrays;\nimport java.util.List;\nimport com.onesignal.client.ApiClient;\nimport com.onesignal.client.ApiException;\nimport com.onesignal.client.Configuration;\nimport com.onesignal.client.auth.*;\nimport com.onesignal.client.model.*;\nimport com.onesignal.client.api.DefaultApi;\n\npublic class Example {\n public static void main(String[] args) {\n ApiClient defaultClient = Configuration.getDefaultApiClient();\n defaultClient.setBasePath(\"https://api.onesignal.com\");\n \n // Configure HTTP bearer authorization: rest_api_key\n HttpBearerAuth rest_api_key = (HttpBearerAuth) defaultClient.getAuthentication(\"rest_api_key\");\n rest_api_key.setBearerToken(\"YOUR_REST_API_KEY\");\n\n DefaultApi apiInstance = new DefaultApi(defaultClient);\n String appId = \"YOUR_APP_ID\"; // String | Your OneSignal App ID in UUID v4 format.\n CreateJourneyRequest createJourneyRequest = new CreateJourneyRequest().name(\"YOUR_NAME\"); // CreateJourneyRequest | \n try {\n Journey result = apiInstance.createJourney(appId, createJourneyRequest);\n System.out.println(result);\n } catch (ApiException e) {\n System.err.println(\"Exception when calling DefaultApi#createJourney\");\n System.err.println(\"Status code: \" + e.getCode());\n // getErrorMessages() flattens any error-envelope shape to a List\u003cString>;\n // the raw body remains on getResponseBody().\n System.err.println(\"Error messages: \" + e.getErrorMessages());\n System.err.println(\"Reason: \" + e.getResponseBody());\n System.err.println(\"Response headers: \" + e.getResponseHeaders());\n e.printStackTrace();\n }\n }\n}"},{"label":"C# SDK","lang":"csharp","source":"using System;\nusing System.Collections.Generic;\nusing System.Diagnostics;\nusing OneSignalApi.Api;\nusing OneSignalApi.Client;\nusing OneSignalApi.Model;\n\nnamespace Example\n{\n public class CreateJourneyExample\n {\n public static void Main()\n {\n Configuration config = new Configuration();\n config.BasePath = \"https://api.onesignal.com\";\n // Configure Bearer token for authorization: rest_api_key\n config.AccessToken = \"YOUR_REST_API_KEY\";\n\n var apiInstance = new DefaultApi(config);\n var appId = \"YOUR_APP_ID\"; // string | Your OneSignal App ID in UUID v4 format.\n var createJourneyRequest = new CreateJourneyRequest(name: \"YOUR_NAME\"); // CreateJourneyRequest | \n\n try\n {\n // Create journey\n Journey result = apiInstance.CreateJourney(appId, createJourneyRequest);\n Debug.WriteLine(result);\n }\n catch (ApiException e)\n {\n Debug.Print(\"Exception when calling DefaultApi.CreateJourney: \" + e.Message );\n Debug.Print(\"Status Code: \"+ e.ErrorCode);\n // e.ErrorMessages flattens any error-envelope shape to an IReadOnlyList\u003cstring>;\n // the raw body remains on e.ErrorContent.\n Debug.Print(\"Error Messages: \" + string.Join(\", \", e.ErrorMessages));\n Debug.Print(\"Response Body: \" + e.ErrorContent);\n Debug.Print(e.StackTrace);\n }\n }\n }\n}"},{"label":"Rust SDK","lang":"rust","source":"use onesignal_rust_api::apis::configuration::Configuration;\nuse onesignal_rust_api::apis::default_api;\n\nuse onesignal_rust_api::models;\n\n\n#[tokio::main]\nasync fn main() {\n let mut configuration = Configuration::new();\n configuration.rest_api_key_token = Some(\"YOUR_REST_API_KEY\".to_string());\n\n\n // Realistic values are pulled from the spec's `example:` fields where present.\n let app_id: \u0026str = \"YOUR_APP_ID\";\n let create_journey_request: models::CreateJourneyRequest = models::CreateJourneyRequest::new(\"YOUR_NAME\".to_string());\n\n match default_api::create_journey(\u0026configuration, app_id, create_journey_request).await {\n Ok(resp) => println!(\"{:?}\", resp),\n Err(e @ onesignal_rust_api::apis::Error::ResponseError(_)) => {\n // `e.error_messages()` flattens any error-envelope shape to a Vec\u003cString>;\n // the raw response remains on the ResponseError variant.\n eprintln!(\"create_journey failed: {:?}\", e.error_messages());\n }\n Err(e) => eprintln!(\"create_journey failed: {:?}\", e),\n }\n}"}],"requestExampleLanguages":["bash","typescript","python","php","go","ruby","java","csharp","rust"],"requiredOnlyExamples":false,"requestExampleType":"codeSamples","responseExampleType":"generated"},"dependencies":{"parameters":{"28ecfe79-c7b6-493d-af5e-3789eac4481d":{"name":"app_id","in":"path","description":"Your OneSignal App ID in UUID v4 format. See [Keys \u0026 IDs](/docs/en/keys-and-ids).","schema":{"type":"string","default":"YOUR_APP_ID","isRequired":true,"description":"Your OneSignal App ID in UUID v4 format. See [Keys \u0026 IDs](/docs/en/keys-and-ids).","uniqueKey":"","typeLabel":"string"},"required":true},"a591c14d-870f-44ee-b733-79502cd5ea3b":{"name":"Authorization","in":"header","description":"Your App API key with prefix `Key `. See [Keys \u0026 IDs](/docs/en/keys-and-ids).","required":true,"schema":{"type":"string","default":"Key YOUR_APP_API_KEY","isRequired":true,"description":"Your App API key with prefix `Key `. See [Keys \u0026 IDs](/docs/en/keys-and-ids).","uniqueKey":"","typeLabel":"string"}},"388310de-7fe0-4736-8e09-3502d3be56ef":{"name":"Content-Type","in":"header","required":true,"schema":{"type":"string","default":"application/json; charset=utf-8","isRequired":true,"uniqueKey":"","typeLabel":"string"}}},"requestBody":{"content":{"application/json":{"schema":{"type":"object","required":["name"],"properties":{"name":{"type":"string","description":"Journey name.","default":"YOUR_JOURNEY_NAME","isRequired":true,"uniqueKey":"name","typeLabel":"string"},"description":{"oneOf":[{"type":"string","description":"Optional journey description.","uniqueKey":"description.oneOf.0","typeLabel":"string"},{"type":"null","description":"Optional journey description.","uniqueKey":"description.oneOf.1","typeLabel":"null"}],"uniqueKey":"description","typeLabel":"string | null"},"audience":{"oneOf":[{"type":"object","title":"segment","description":"The journey entry audience. Either a segment-based or event-triggered audience.","required":["kind"],"properties":{"kind":{"type":"string","const":"segment","isRequired":true,"uniqueKey":"audience.oneOf.0.kind","typeLabel":"string"},"included_segment_ids":{"type":"array","items":{"type":"string","uniqueKey":"audience.oneOf.0.included_segment_ids.items.[INDEX]","typeLabel":"string"},"description":"Segment UUIDs whose users enter the journey.","uniqueKey":"audience.oneOf.0.included_segment_ids","typeLabel":"string[]"},"excluded_segment_ids":{"type":"array","items":{"type":"string","uniqueKey":"audience.oneOf.0.excluded_segment_ids.items.[INDEX]","typeLabel":"string"},"description":"Segment UUIDs whose users are excluded.","uniqueKey":"audience.oneOf.0.excluded_segment_ids","typeLabel":"string[]"},"future_additions_only":{"type":"boolean","description":"When true, only users who newly match the segment after activation enter the journey. Defaults to false.","uniqueKey":"audience.oneOf.0.future_additions_only","typeLabel":"boolean"}},"uniqueKey":"audience.oneOf.0","typeLabel":"segment · object"},{"type":"object","title":"event_trigger","description":"The journey entry audience. Either a segment-based or event-triggered audience.","required":["kind"],"properties":{"kind":{"type":"string","const":"event_trigger","isRequired":true,"uniqueKey":"audience.oneOf.1.kind","typeLabel":"string"},"name":{"type":"string","description":"Event name that triggers entry, up to 255 characters.","uniqueKey":"audience.oneOf.1.name","typeLabel":"string"},"attributes":{"type":"array","description":"Event attribute matchers, as a list of condition groups. Send a single group whose conditions are AND'd together. More than one group is rejected.","items":{"type":"array","items":{"type":"object","required":["key","operator"],"properties":{"key":{"type":"string","description":"Event attribute key.","isRequired":true,"uniqueKey":"audience.oneOf.1.attributes.items.[INDEX].items.[INDEX].key","typeLabel":"string"},"operator":{"type":"string","enum":["equal","not_equal","less","less_or_equal","greater_or_equal","greater","is","is_not","exists","not_exists","before","after"],"description":"Comparison operator.","isRequired":true,"uniqueKey":"audience.oneOf.1.attributes.items.[INDEX].items.[INDEX].operator","typeLabel":"enum\u003cstring>"},"value":{"type":"string","description":"Value to compare against. Not required for `exists` and `not_exists`.","uniqueKey":"audience.oneOf.1.attributes.items.[INDEX].items.[INDEX].value","typeLabel":"string"}},"uniqueKey":"audience.oneOf.1.attributes.items.[INDEX].items.[INDEX]","typeLabel":"object"},"uniqueKey":"audience.oneOf.1.attributes.items.[INDEX]","typeLabel":"object[]"},"uniqueKey":"audience.oneOf.1.attributes","typeLabel":"object[][]"}},"uniqueKey":"audience.oneOf.1","typeLabel":"event_trigger · object"}],"uniqueKey":"audience","typeLabel":"segment · object | event_trigger · object"},"early_exit":{"oneOf":[{"type":"object","description":"Conditions that remove a user from the journey before it completes. At least one rule must be set under `rules`; an early_exit that configures no rule is rejected. Send `null` to remove early exit entirely, or `null` for an individual rule to drop just that rule.","properties":{"rules":{"type":"object","properties":{"on_segment":{"oneOf":[{"type":"object","properties":{"included_segment_ids":{"type":"array","items":{"type":"string","uniqueKey":"early_exit.oneOf.0.rules.on_segment.oneOf.0.included_segment_ids.items.[INDEX]","typeLabel":"string"},"description":"Exit when the user enters any of these segments.","uniqueKey":"early_exit.oneOf.0.rules.on_segment.oneOf.0.included_segment_ids","typeLabel":"string[]"}},"uniqueKey":"early_exit.oneOf.0.rules.on_segment.oneOf.0","typeLabel":"object"},{"type":"null","properties":{"included_segment_ids":{"type":"array","items":{"type":"string"},"description":"Exit when the user enters any of these segments."}},"uniqueKey":"early_exit.oneOf.0.rules.on_segment.oneOf.1","typeLabel":"null"}],"uniqueKey":"early_exit.oneOf.0.rules.on_segment","typeLabel":"object | null"},"when_not_in_audience":{"oneOf":[{"type":"boolean","description":"Exit when the user no longer matches the journey audience. Defaults to false.","uniqueKey":"early_exit.oneOf.0.rules.when_not_in_audience.oneOf.0","typeLabel":"boolean"},{"type":"null","description":"Exit when the user no longer matches the journey audience. Defaults to false.","uniqueKey":"early_exit.oneOf.0.rules.when_not_in_audience.oneOf.1","typeLabel":"null"}],"uniqueKey":"early_exit.oneOf.0.rules.when_not_in_audience","typeLabel":"boolean | null"},"on_session":{"oneOf":[{"type":"boolean","description":"Exit on a new session start. Defaults to false.","uniqueKey":"early_exit.oneOf.0.rules.on_session.oneOf.0","typeLabel":"boolean"},{"type":"null","description":"Exit on a new session start. Defaults to false.","uniqueKey":"early_exit.oneOf.0.rules.on_session.oneOf.1","typeLabel":"null"}],"uniqueKey":"early_exit.oneOf.0.rules.on_session","typeLabel":"boolean | null"},"on_event":{"oneOf":[{"type":"object","required":["name"],"properties":{"name":{"type":"string","description":"Exit when this event occurs. Up to 255 characters.","isRequired":true,"uniqueKey":"early_exit.oneOf.0.rules.on_event.oneOf.0.name","typeLabel":"string"}},"uniqueKey":"early_exit.oneOf.0.rules.on_event.oneOf.0","typeLabel":"object"},{"type":"null","required":["name"],"properties":{"name":{"type":"string","description":"Exit when this event occurs. Up to 255 characters."}},"uniqueKey":"early_exit.oneOf.0.rules.on_event.oneOf.1","typeLabel":"null"}],"uniqueKey":"early_exit.oneOf.0.rules.on_event","typeLabel":"object | null"}},"uniqueKey":"early_exit.oneOf.0.rules","typeLabel":"object"},"tag_on_early_exit":{"type":"object","additionalProperties":{"type":"string","uniqueKey":"early_exit.oneOf.0.tag_on_early_exit.additionalProperties","typeLabel":"string"},"description":"Tag key-value pairs applied when a user exits early.","uniqueKey":"early_exit.oneOf.0.tag_on_early_exit","typeLabel":"object"}},"uniqueKey":"early_exit.oneOf.0","typeLabel":"object"},{"type":"null","description":"Conditions that remove a user from the journey before it completes. At least one rule must be set under `rules`; an early_exit that configures no rule is rejected. Send `null` to remove early exit entirely, or `null` for an individual rule to drop just that rule.","properties":{"rules":{"type":"object","properties":{"on_segment":{"oneOf":[{"type":"object","properties":{"included_segment_ids":{"type":"array","items":{"type":"string"},"description":"Exit when the user enters any of these segments."}}},{"type":"null","properties":{"included_segment_ids":{"type":"array","items":{"type":"string"},"description":"Exit when the user enters any of these segments."}}}]},"when_not_in_audience":{"oneOf":[{"type":"boolean","description":"Exit when the user no longer matches the journey audience. Defaults to false."},{"type":"null","description":"Exit when the user no longer matches the journey audience. Defaults to false."}]},"on_session":{"oneOf":[{"type":"boolean","description":"Exit on a new session start. Defaults to false."},{"type":"null","description":"Exit on a new session start. Defaults to false."}]},"on_event":{"oneOf":[{"type":"object","required":["name"],"properties":{"name":{"type":"string","description":"Exit when this event occurs. Up to 255 characters."}}},{"type":"null","required":["name"],"properties":{"name":{"type":"string","description":"Exit when this event occurs. Up to 255 characters."}}}]}}},"tag_on_early_exit":{"type":"object","additionalProperties":{"type":"string"},"description":"Tag key-value pairs applied when a user exits early."}},"uniqueKey":"early_exit.oneOf.1","typeLabel":"null"}],"uniqueKey":"early_exit","typeLabel":"object | null"},"reentry_rules":{"oneOf":[{"type":"object","description":"Controls whether and how soon a user can re-enter the journey. `null` means re-entry is not allowed.","properties":{"duration_seconds":{"type":"integer","minimum":600,"description":"Minimum seconds before a user can re-enter. Must be at least `600` (10 minutes).","uniqueKey":"reentry_rules.oneOf.0.duration_seconds","typeLabel":"integer"}},"uniqueKey":"reentry_rules.oneOf.0","typeLabel":"object"},{"type":"null","description":"Controls whether and how soon a user can re-enter the journey. `null` means re-entry is not allowed.","properties":{"duration_seconds":{"type":"integer","minimum":600,"description":"Minimum seconds before a user can re-enter. Must be at least `600` (10 minutes)."}},"uniqueKey":"reentry_rules.oneOf.1","typeLabel":"null"}],"uniqueKey":"reentry_rules","typeLabel":"object | null"},"schedule":{"oneOf":[{"type":"object","description":"Optional future start and/or stop time. `null` means no scheduled activation.","properties":{"start_at":{"oneOf":[{"type":"string","description":"ISO 8601 start time. Use UTC (`Z` or `+00:00`). Must be at least 5 minutes in the future.","uniqueKey":"schedule.oneOf.0.start_at.oneOf.0","typeLabel":"string"},{"type":"null","description":"ISO 8601 start time. Use UTC (`Z` or `+00:00`). Must be at least 5 minutes in the future.","uniqueKey":"schedule.oneOf.0.start_at.oneOf.1","typeLabel":"null"}],"uniqueKey":"schedule.oneOf.0.start_at","typeLabel":"string | null"},"stop_at":{"oneOf":[{"type":"string","description":"ISO 8601 stop time. Use UTC (`Z` or `+00:00`). Must be in the future and later than `start_at`.","uniqueKey":"schedule.oneOf.0.stop_at.oneOf.0","typeLabel":"string"},{"type":"null","description":"ISO 8601 stop time. Use UTC (`Z` or `+00:00`). Must be in the future and later than `start_at`.","uniqueKey":"schedule.oneOf.0.stop_at.oneOf.1","typeLabel":"null"}],"uniqueKey":"schedule.oneOf.0.stop_at","typeLabel":"string | null"},"error":{"oneOf":[{"type":"string","description":"Read-only. Present when a scheduling error occurred.","uniqueKey":"schedule.oneOf.0.error.oneOf.0","typeLabel":"string"},{"type":"null","description":"Read-only. Present when a scheduling error occurred.","uniqueKey":"schedule.oneOf.0.error.oneOf.1","typeLabel":"null"}],"uniqueKey":"schedule.oneOf.0.error","typeLabel":"string | null"}},"uniqueKey":"schedule.oneOf.0","typeLabel":"object"},{"type":"null","description":"Optional future start and/or stop time. `null` means no scheduled activation.","properties":{"start_at":{"oneOf":[{"type":"string","description":"ISO 8601 start time. Use UTC (`Z` or `+00:00`). Must be at least 5 minutes in the future."},{"type":"null","description":"ISO 8601 start time. Use UTC (`Z` or `+00:00`). Must be at least 5 minutes in the future."}]},"stop_at":{"oneOf":[{"type":"string","description":"ISO 8601 stop time. Use UTC (`Z` or `+00:00`). Must be in the future and later than `start_at`."},{"type":"null","description":"ISO 8601 stop time. Use UTC (`Z` or `+00:00`). Must be in the future and later than `start_at`."}]},"error":{"oneOf":[{"type":"string","description":"Read-only. Present when a scheduling error occurred."},{"type":"null","description":"Read-only. Present when a scheduling error occurred."}]}},"uniqueKey":"schedule.oneOf.1","typeLabel":"null"}],"uniqueKey":"schedule","typeLabel":"object | null"},"nodes":{"type":"array","items":{"oneOf":[{"type":"object","description":"A journey node. The `kind` field selects the shape. Branching nodes (`split_range`, `yes_no`, `wait_until`) nest their sub-graphs inline via `branches[].nodes`.","required":["kind"],"properties":{"kind":{"type":"string","const":"wait","description":"Holds the user for a fixed duration before continuing.","isRequired":true,"uniqueKey":"nodes.items.[INDEX].oneOf.0.kind","typeLabel":"string"},"id":{"type":"string","description":"Server-assigned node UUID. Read-only. Returned on reads; sending it on create is rejected with a `400` validation error.","uniqueKey":"nodes.items.[INDEX].oneOf.0.id","typeLabel":"string"},"client_node_id":{"type":"string","description":"Optional client-assigned identifier, unique within the journey. Use it to reference this node from elsewhere in the same request (for example as `client_node_id` on an `on_notification_action` condition). Persisted and returned on reads.","uniqueKey":"nodes.items.[INDEX].oneOf.0.client_node_id","typeLabel":"string"},"annotation":{"type":"string","description":"Optional free-text label, up to 1024 characters. Stored and returned as-is with no effect on journey behavior.","uniqueKey":"nodes.items.[INDEX].oneOf.0.annotation","typeLabel":"string"},"duration_seconds":{"type":"integer","description":"Seconds to hold the user. Minimum `60`, maximum `31556952` (1 year).","minimum":60,"maximum":31556952,"uniqueKey":"nodes.items.[INDEX].oneOf.0.duration_seconds","typeLabel":"integer"}},"uniqueKey":"nodes.items.[INDEX].oneOf.0","typeLabel":"object"},{"type":"object","description":"A journey node. The `kind` field selects the shape. Branching nodes (`split_range`, `yes_no`, `wait_until`) nest their sub-graphs inline via `branches[].nodes`.","required":["kind"],"properties":{"kind":{"type":"string","const":"time_window","description":"Holds the user until the next configured time window opens.","isRequired":true,"uniqueKey":"nodes.items.[INDEX].oneOf.1.kind","typeLabel":"string"},"id":{"type":"string","description":"Server-assigned node UUID. Read-only. Returned on reads; sending it on create is rejected with a `400` validation error.","uniqueKey":"nodes.items.[INDEX].oneOf.1.id","typeLabel":"string"},"client_node_id":{"type":"string","description":"Optional client-assigned identifier, unique within the journey. Use it to reference this node from elsewhere in the same request (for example as `client_node_id` on an `on_notification_action` condition). Persisted and returned on reads.","uniqueKey":"nodes.items.[INDEX].oneOf.1.client_node_id","typeLabel":"string"},"annotation":{"type":"string","description":"Optional free-text label, up to 1024 characters. Stored and returned as-is with no effect on journey behavior.","uniqueKey":"nodes.items.[INDEX].oneOf.1.annotation","typeLabel":"string"},"relative_to":{"type":"string","enum":["schedule_in_timezone","last_active_time"],"description":"`schedule_in_timezone` uses the configured windows; `last_active_time` holds relative to the user's last active time.","uniqueKey":"nodes.items.[INDEX].oneOf.1.relative_to","typeLabel":"enum\u003cstring>"},"windows":{"type":"array","items":{"type":"object","properties":{"start":{"type":"object","description":"When the window opens.","properties":{"hour":{"type":"integer","minimum":0,"maximum":23,"description":"Hour of day, 0-23.","uniqueKey":"nodes.items.[INDEX].oneOf.1.windows.items.[INDEX].start.hour","typeLabel":"integer"},"minute":{"type":"integer","minimum":0,"maximum":59,"description":"Minute of hour, 0-59. Defaults to 0.","uniqueKey":"nodes.items.[INDEX].oneOf.1.windows.items.[INDEX].start.minute","typeLabel":"integer"}},"uniqueKey":"nodes.items.[INDEX].oneOf.1.windows.items.[INDEX].start","typeLabel":"object"},"end":{"type":"object","description":"When the window closes.","properties":{"hour":{"type":"integer","minimum":0,"maximum":23,"description":"Hour of day, 0-23.","uniqueKey":"nodes.items.[INDEX].oneOf.1.windows.items.[INDEX].end.hour","typeLabel":"integer"},"minute":{"type":"integer","minimum":0,"maximum":59,"description":"Minute of hour, 0-59. Defaults to 0.","uniqueKey":"nodes.items.[INDEX].oneOf.1.windows.items.[INDEX].end.minute","typeLabel":"integer"}},"uniqueKey":"nodes.items.[INDEX].oneOf.1.windows.items.[INDEX].end","typeLabel":"object"},"day_of_week":{"type":"integer","minimum":1,"maximum":7,"description":"Day of week, 1 = Monday. Omit to apply the window to every day.","uniqueKey":"nodes.items.[INDEX].oneOf.1.windows.items.[INDEX].day_of_week","typeLabel":"integer"}},"description":"A wall-clock window. Each window must span at least 15 minutes.","uniqueKey":"nodes.items.[INDEX].oneOf.1.windows.items.[INDEX]","typeLabel":"object"},"description":"One or more time windows. A window with no `day_of_week` applies to every day, and is returned in that same day-agnostic form. Required when `relative_to` is `schedule_in_timezone`; must be omitted when it is `last_active_time`, and is absent from responses for those nodes.","uniqueKey":"nodes.items.[INDEX].oneOf.1.windows","typeLabel":"object[]"},"time_zone":{"type":"string","description":"IANA timezone identifier used when the user's timezone is unavailable.","uniqueKey":"nodes.items.[INDEX].oneOf.1.time_zone","typeLabel":"string"},"use_user_time_zone":{"type":"boolean","description":"When true, uses the user's timezone if available.","uniqueKey":"nodes.items.[INDEX].oneOf.1.use_user_time_zone","typeLabel":"boolean"}},"uniqueKey":"nodes.items.[INDEX].oneOf.1","typeLabel":"object"},{"type":"object","description":"A journey node. The `kind` field selects the shape. Branching nodes (`split_range`, `yes_no`, `wait_until`) nest their sub-graphs inline via `branches[].nodes`.","required":["kind"],"properties":{"kind":{"type":"string","enum":["send_push","send_email","send_sms"],"description":"Sends a message on the given channel using a template.","isRequired":true,"uniqueKey":"nodes.items.[INDEX].oneOf.2.kind","typeLabel":"enum\u003cstring>"},"id":{"type":"string","description":"Server-assigned node UUID. Read-only. Returned on reads; sending it on create is rejected with a `400` validation error.","uniqueKey":"nodes.items.[INDEX].oneOf.2.id","typeLabel":"string"},"client_node_id":{"type":"string","description":"Optional client-assigned identifier, unique within the journey. Use it to reference this node from elsewhere in the same request (for example as `client_node_id` on an `on_notification_action` condition). Persisted and returned on reads.","uniqueKey":"nodes.items.[INDEX].oneOf.2.client_node_id","typeLabel":"string"},"annotation":{"type":"string","description":"Optional free-text label, up to 1024 characters. Stored and returned as-is with no effect on journey behavior.","uniqueKey":"nodes.items.[INDEX].oneOf.2.annotation","typeLabel":"string"},"template_id":{"type":"string","description":"UUID of the template to send.","uniqueKey":"nodes.items.[INDEX].oneOf.2.template_id","typeLabel":"string"}},"uniqueKey":"nodes.items.[INDEX].oneOf.2","typeLabel":"object"},{"type":"object","description":"A journey node. The `kind` field selects the shape. Branching nodes (`split_range`, `yes_no`, `wait_until`) nest their sub-graphs inline via `branches[].nodes`.","required":["kind"],"properties":{"kind":{"type":"string","const":"send_iam","description":"Sends an in-app message.","isRequired":true,"uniqueKey":"nodes.items.[INDEX].oneOf.3.kind","typeLabel":"string"},"id":{"type":"string","description":"Server-assigned node UUID. Read-only. Returned on reads; sending it on create is rejected with a `400` validation error.","uniqueKey":"nodes.items.[INDEX].oneOf.3.id","typeLabel":"string"},"client_node_id":{"type":"string","description":"Optional client-assigned identifier, unique within the journey. Use it to reference this node from elsewhere in the same request (for example as `client_node_id` on an `on_notification_action` condition). Persisted and returned on reads.","uniqueKey":"nodes.items.[INDEX].oneOf.3.client_node_id","typeLabel":"string"},"annotation":{"type":"string","description":"Optional free-text label, up to 1024 characters. Stored and returned as-is with no effect on journey behavior.","uniqueKey":"nodes.items.[INDEX].oneOf.3.annotation","typeLabel":"string"},"iam_id":{"type":"string","description":"UUID of the in-app message to send.","uniqueKey":"nodes.items.[INDEX].oneOf.3.iam_id","typeLabel":"string"},"user_ttl_seconds":{"type":"integer","minimum":1,"description":"Optional time-to-live for the in-app message, in seconds.","uniqueKey":"nodes.items.[INDEX].oneOf.3.user_ttl_seconds","typeLabel":"integer"}},"uniqueKey":"nodes.items.[INDEX].oneOf.3","typeLabel":"object"},{"type":"object","description":"A journey node. The `kind` field selects the shape. Branching nodes (`split_range`, `yes_no`, `wait_until`) nest their sub-graphs inline via `branches[].nodes`.","required":["kind"],"properties":{"kind":{"type":"string","const":"send_webhook","description":"Sends a webhook.","isRequired":true,"uniqueKey":"nodes.items.[INDEX].oneOf.4.kind","typeLabel":"string"},"id":{"type":"string","description":"Server-assigned node UUID. Read-only. Returned on reads; sending it on create is rejected with a `400` validation error.","uniqueKey":"nodes.items.[INDEX].oneOf.4.id","typeLabel":"string"},"client_node_id":{"type":"string","description":"Optional client-assigned identifier, unique within the journey. Use it to reference this node from elsewhere in the same request (for example as `client_node_id` on an `on_notification_action` condition). Persisted and returned on reads.","uniqueKey":"nodes.items.[INDEX].oneOf.4.client_node_id","typeLabel":"string"},"annotation":{"type":"string","description":"Optional free-text label, up to 1024 characters. Stored and returned as-is with no effect on journey behavior.","uniqueKey":"nodes.items.[INDEX].oneOf.4.annotation","typeLabel":"string"},"webhook_id":{"type":"string","description":"UUID of the webhook to send.","uniqueKey":"nodes.items.[INDEX].oneOf.4.webhook_id","typeLabel":"string"}},"uniqueKey":"nodes.items.[INDEX].oneOf.4","typeLabel":"object"},{"type":"object","description":"A journey node. The `kind` field selects the shape. Branching nodes (`split_range`, `yes_no`, `wait_until`) nest their sub-graphs inline via `branches[].nodes`.","required":["kind"],"properties":{"kind":{"type":"string","const":"tag","description":"Assigns key-value tags to the user.","isRequired":true,"uniqueKey":"nodes.items.[INDEX].oneOf.5.kind","typeLabel":"string"},"id":{"type":"string","description":"Server-assigned node UUID. Read-only. Returned on reads; sending it on create is rejected with a `400` validation error.","uniqueKey":"nodes.items.[INDEX].oneOf.5.id","typeLabel":"string"},"client_node_id":{"type":"string","description":"Optional client-assigned identifier, unique within the journey. Use it to reference this node from elsewhere in the same request (for example as `client_node_id` on an `on_notification_action` condition). Persisted and returned on reads.","uniqueKey":"nodes.items.[INDEX].oneOf.5.client_node_id","typeLabel":"string"},"annotation":{"type":"string","description":"Optional free-text label, up to 1024 characters. Stored and returned as-is with no effect on journey behavior.","uniqueKey":"nodes.items.[INDEX].oneOf.5.annotation","typeLabel":"string"},"assignments":{"type":"object","additionalProperties":{"type":"string","uniqueKey":"nodes.items.[INDEX].oneOf.5.assignments.additionalProperties","typeLabel":"string"},"description":"Tag key-value pairs to assign. An empty string value removes the tag. Keys are limited to 255 characters and values to 1024.","uniqueKey":"nodes.items.[INDEX].oneOf.5.assignments","typeLabel":"object"}},"uniqueKey":"nodes.items.[INDEX].oneOf.5","typeLabel":"object"},{"type":"object","description":"A journey node. The `kind` field selects the shape. Branching nodes (`split_range`, `yes_no`, `wait_until`) nest their sub-graphs inline via `branches[].nodes`.","required":["kind"],"properties":{"kind":{"type":"string","const":"split_range","description":"Routes users into weighted branches that converge to the next sibling node.","isRequired":true,"uniqueKey":"nodes.items.[INDEX].oneOf.6.kind","typeLabel":"string"},"id":{"type":"string","description":"Server-assigned node UUID. Read-only. Returned on reads; sending it on create is rejected with a `400` validation error.","uniqueKey":"nodes.items.[INDEX].oneOf.6.id","typeLabel":"string"},"client_node_id":{"type":"string","description":"Optional client-assigned identifier, unique within the journey. Use it to reference this node from elsewhere in the same request (for example as `client_node_id` on an `on_notification_action` condition). Persisted and returned on reads.","uniqueKey":"nodes.items.[INDEX].oneOf.6.client_node_id","typeLabel":"string"},"annotation":{"type":"string","description":"Optional free-text label, up to 1024 characters. Stored and returned as-is with no effect on journey behavior.","uniqueKey":"nodes.items.[INDEX].oneOf.6.annotation","typeLabel":"string"},"randomize_on_entry":{"type":"boolean","description":"When true, assigns each user to a branch at random on entry. Defaults to false.","uniqueKey":"nodes.items.[INDEX].oneOf.6.randomize_on_entry","typeLabel":"boolean"},"branches":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","description":"Server-assigned branch identifier. Read-only.","uniqueKey":"nodes.items.[INDEX].oneOf.6.branches.items.[INDEX].id","typeLabel":"string"},"condition":{"oneOf":[{"type":"object","title":"segment_membership","description":"A branch condition. The `kind` field selects the shape.","required":["kind"],"properties":{"kind":{"type":"string","const":"segment_membership","isRequired":true,"uniqueKey":"nodes.items.[INDEX].oneOf.6.branches.items.[INDEX].condition.oneOf.0.kind","typeLabel":"string"},"included_segment_ids":{"type":"array","items":{"type":"string","uniqueKey":"nodes.items.[INDEX].oneOf.6.branches.items.[INDEX].condition.oneOf.0.included_segment_ids.items.[INDEX]","typeLabel":"string"},"description":"Segment UUIDs the user must belong to.","uniqueKey":"nodes.items.[INDEX].oneOf.6.branches.items.[INDEX].condition.oneOf.0.included_segment_ids","typeLabel":"string[]"},"excluded_segment_ids":{"type":"array","items":{"type":"string","uniqueKey":"nodes.items.[INDEX].oneOf.6.branches.items.[INDEX].condition.oneOf.0.excluded_segment_ids.items.[INDEX]","typeLabel":"string"},"description":"Segment UUIDs the user must not belong to.","uniqueKey":"nodes.items.[INDEX].oneOf.6.branches.items.[INDEX].condition.oneOf.0.excluded_segment_ids","typeLabel":"string[]"}},"uniqueKey":"nodes.items.[INDEX].oneOf.6.branches.items.[INDEX].condition.oneOf.0","typeLabel":"segment_membership · object"},{"type":"object","title":"on_notification_action","description":"A branch condition. The `kind` field selects the shape.","required":["kind"],"properties":{"kind":{"type":"string","const":"on_notification_action","isRequired":true,"uniqueKey":"nodes.items.[INDEX].oneOf.6.branches.items.[INDEX].condition.oneOf.1.kind","typeLabel":"string"},"action":{"type":"string","enum":["received","clicked","opened"],"description":"The notification action to branch on. Which actions apply depends on the sending node's channel.","uniqueKey":"nodes.items.[INDEX].oneOf.6.branches.items.[INDEX].condition.oneOf.1.action","typeLabel":"enum\u003cstring>"},"sending_node_id":{"type":"string","description":"`id` of the sending node this action refers to. Returned on reads; accepted on write.","uniqueKey":"nodes.items.[INDEX].oneOf.6.branches.items.[INDEX].condition.oneOf.1.sending_node_id","typeLabel":"string"},"client_node_id":{"type":"string","description":"Write-only alternative to `sending_node_id`. References the sending node by its `client_node_id`, which is resolved to that node's `id`.","uniqueKey":"nodes.items.[INDEX].oneOf.6.branches.items.[INDEX].condition.oneOf.1.client_node_id","typeLabel":"string"}},"uniqueKey":"nodes.items.[INDEX].oneOf.6.branches.items.[INDEX].condition.oneOf.1","typeLabel":"on_notification_action · object"},{"type":"object","title":"event_trigger","description":"A branch condition. The `kind` field selects the shape.","required":["kind"],"properties":{"kind":{"type":"string","const":"event_trigger","isRequired":true,"uniqueKey":"nodes.items.[INDEX].oneOf.6.branches.items.[INDEX].condition.oneOf.2.kind","typeLabel":"string"},"name":{"type":"string","description":"Event name, up to 255 characters.","uniqueKey":"nodes.items.[INDEX].oneOf.6.branches.items.[INDEX].condition.oneOf.2.name","typeLabel":"string"},"attributes":{"type":"array","description":"Event attribute matchers, as a list of condition groups. Send a single group whose conditions are AND'd together. More than one group is rejected.","items":{"type":"array","items":{"type":"object","required":["key","operator"],"properties":{"key":{"type":"string","description":"Event attribute key.","isRequired":true,"uniqueKey":"nodes.items.[INDEX].oneOf.6.branches.items.[INDEX].condition.oneOf.2.attributes.items.[INDEX].items.[INDEX].key","typeLabel":"string"},"operator":{"type":"string","enum":["equal","not_equal","less","less_or_equal","greater_or_equal","greater","is","is_not","exists","not_exists","before","after"],"description":"Comparison operator.","isRequired":true,"uniqueKey":"nodes.items.[INDEX].oneOf.6.branches.items.[INDEX].condition.oneOf.2.attributes.items.[INDEX].items.[INDEX].operator","typeLabel":"enum\u003cstring>"},"value":{"type":"string","description":"Value to compare against. Not required for `exists` and `not_exists`.","uniqueKey":"nodes.items.[INDEX].oneOf.6.branches.items.[INDEX].condition.oneOf.2.attributes.items.[INDEX].items.[INDEX].value","typeLabel":"string"}},"uniqueKey":"nodes.items.[INDEX].oneOf.6.branches.items.[INDEX].condition.oneOf.2.attributes.items.[INDEX].items.[INDEX]","typeLabel":"object"},"uniqueKey":"nodes.items.[INDEX].oneOf.6.branches.items.[INDEX].condition.oneOf.2.attributes.items.[INDEX]","typeLabel":"object[]"},"uniqueKey":"nodes.items.[INDEX].oneOf.6.branches.items.[INDEX].condition.oneOf.2.attributes","typeLabel":"object[][]"},"entry_event_match_attributes":{"oneOf":[{"type":"array","items":{"type":"object","uniqueKey":"nodes.items.[INDEX].oneOf.6.branches.items.[INDEX].condition.oneOf.2.entry_event_match_attributes.oneOf.0.items.[INDEX]","typeLabel":"object"},"description":"Match incoming event properties against the journey's entry event. Only valid on event-triggered journeys.","uniqueKey":"nodes.items.[INDEX].oneOf.6.branches.items.[INDEX].condition.oneOf.2.entry_event_match_attributes.oneOf.0","typeLabel":"object[]"},{"type":"null","items":{"type":"object"},"description":"Match incoming event properties against the journey's entry event. Only valid on event-triggered journeys.","uniqueKey":"nodes.items.[INDEX].oneOf.6.branches.items.[INDEX].condition.oneOf.2.entry_event_match_attributes.oneOf.1","typeLabel":"null"}],"uniqueKey":"nodes.items.[INDEX].oneOf.6.branches.items.[INDEX].condition.oneOf.2.entry_event_match_attributes","typeLabel":"object[] | null"}},"uniqueKey":"nodes.items.[INDEX].oneOf.6.branches.items.[INDEX].condition.oneOf.2","typeLabel":"event_trigger · object"}],"uniqueKey":"nodes.items.[INDEX].oneOf.6.branches.items.[INDEX].condition","typeLabel":"segment_membership · object | on_notification_action · object | event_trigger · object"},"weight":{"type":"number","description":"Branch weight for `split_range` nodes. Weights across a node's branches must sum to 100.","uniqueKey":"nodes.items.[INDEX].oneOf.6.branches.items.[INDEX].weight","typeLabel":"number"},"nodes":{"type":"array","items":{"$circularRef":"f6795843-f004-4026-9a86-d14c359fdee3"},"description":"Nodes run when this branch is taken, before flow converges to the next sibling node.","uniqueKey":"nodes.items.[INDEX].oneOf.6.branches.items.[INDEX].nodes","typeLabel":"array"}},"uniqueKey":"nodes.items.[INDEX].oneOf.6.branches.items.[INDEX]","typeLabel":"object"},"description":"Weighted branches. Between 2 and 25. Weights must sum to 100. Order determines display order.","minItems":2,"maxItems":25,"uniqueKey":"nodes.items.[INDEX].oneOf.6.branches","typeLabel":"object[]"}},"uniqueKey":"nodes.items.[INDEX].oneOf.6","typeLabel":"object"},{"type":"object","description":"A journey node. The `kind` field selects the shape. Branching nodes (`split_range`, `yes_no`, `wait_until`) nest their sub-graphs inline via `branches[].nodes`.","required":["kind"],"properties":{"kind":{"type":"string","const":"yes_no","description":"Routes users into a yes or no branch based on a condition.","isRequired":true,"uniqueKey":"nodes.items.[INDEX].oneOf.7.kind","typeLabel":"string"},"id":{"type":"string","description":"Server-assigned node UUID. Read-only. Returned on reads; sending it on create is rejected with a `400` validation error.","uniqueKey":"nodes.items.[INDEX].oneOf.7.id","typeLabel":"string"},"client_node_id":{"type":"string","description":"Optional client-assigned identifier, unique within the journey. Use it to reference this node from elsewhere in the same request (for example as `client_node_id` on an `on_notification_action` condition). Persisted and returned on reads.","uniqueKey":"nodes.items.[INDEX].oneOf.7.client_node_id","typeLabel":"string"},"annotation":{"type":"string","description":"Optional free-text label, up to 1024 characters. Stored and returned as-is with no effect on journey behavior.","uniqueKey":"nodes.items.[INDEX].oneOf.7.annotation","typeLabel":"string"},"branches":{"type":"array","minItems":2,"maxItems":2,"items":{"type":"object","properties":{"id":{"type":"string","description":"Server-assigned branch identifier. Read-only.","uniqueKey":"nodes.items.[INDEX].oneOf.7.branches.items.[INDEX].id","typeLabel":"string"},"condition":{"oneOf":[{"type":"object","title":"segment_membership","description":"A branch condition. The `kind` field selects the shape.","required":["kind"],"properties":{"kind":{"type":"string","const":"segment_membership","isRequired":true,"uniqueKey":"nodes.items.[INDEX].oneOf.7.branches.items.[INDEX].condition.oneOf.0.kind","typeLabel":"string"},"included_segment_ids":{"type":"array","items":{"type":"string","uniqueKey":"nodes.items.[INDEX].oneOf.7.branches.items.[INDEX].condition.oneOf.0.included_segment_ids.items.[INDEX]","typeLabel":"string"},"description":"Segment UUIDs the user must belong to.","uniqueKey":"nodes.items.[INDEX].oneOf.7.branches.items.[INDEX].condition.oneOf.0.included_segment_ids","typeLabel":"string[]"},"excluded_segment_ids":{"type":"array","items":{"type":"string","uniqueKey":"nodes.items.[INDEX].oneOf.7.branches.items.[INDEX].condition.oneOf.0.excluded_segment_ids.items.[INDEX]","typeLabel":"string"},"description":"Segment UUIDs the user must not belong to.","uniqueKey":"nodes.items.[INDEX].oneOf.7.branches.items.[INDEX].condition.oneOf.0.excluded_segment_ids","typeLabel":"string[]"}},"uniqueKey":"nodes.items.[INDEX].oneOf.7.branches.items.[INDEX].condition.oneOf.0","typeLabel":"segment_membership · object"},{"type":"object","title":"on_notification_action","description":"A branch condition. The `kind` field selects the shape.","required":["kind"],"properties":{"kind":{"type":"string","const":"on_notification_action","isRequired":true,"uniqueKey":"nodes.items.[INDEX].oneOf.7.branches.items.[INDEX].condition.oneOf.1.kind","typeLabel":"string"},"action":{"type":"string","enum":["received","clicked","opened"],"description":"The notification action to branch on. Which actions apply depends on the sending node's channel.","uniqueKey":"nodes.items.[INDEX].oneOf.7.branches.items.[INDEX].condition.oneOf.1.action","typeLabel":"enum\u003cstring>"},"sending_node_id":{"type":"string","description":"`id` of the sending node this action refers to. Returned on reads; accepted on write.","uniqueKey":"nodes.items.[INDEX].oneOf.7.branches.items.[INDEX].condition.oneOf.1.sending_node_id","typeLabel":"string"},"client_node_id":{"type":"string","description":"Write-only alternative to `sending_node_id`. References the sending node by its `client_node_id`, which is resolved to that node's `id`.","uniqueKey":"nodes.items.[INDEX].oneOf.7.branches.items.[INDEX].condition.oneOf.1.client_node_id","typeLabel":"string"}},"uniqueKey":"nodes.items.[INDEX].oneOf.7.branches.items.[INDEX].condition.oneOf.1","typeLabel":"on_notification_action · object"},{"type":"object","title":"event_trigger","description":"A branch condition. The `kind` field selects the shape.","required":["kind"],"properties":{"kind":{"type":"string","const":"event_trigger","isRequired":true,"uniqueKey":"nodes.items.[INDEX].oneOf.7.branches.items.[INDEX].condition.oneOf.2.kind","typeLabel":"string"},"name":{"type":"string","description":"Event name, up to 255 characters.","uniqueKey":"nodes.items.[INDEX].oneOf.7.branches.items.[INDEX].condition.oneOf.2.name","typeLabel":"string"},"attributes":{"type":"array","description":"Event attribute matchers, as a list of condition groups. Send a single group whose conditions are AND'd together. More than one group is rejected.","items":{"type":"array","items":{"type":"object","required":["key","operator"],"properties":{"key":{"type":"string","description":"Event attribute key.","isRequired":true,"uniqueKey":"nodes.items.[INDEX].oneOf.7.branches.items.[INDEX].condition.oneOf.2.attributes.items.[INDEX].items.[INDEX].key","typeLabel":"string"},"operator":{"type":"string","enum":["equal","not_equal","less","less_or_equal","greater_or_equal","greater","is","is_not","exists","not_exists","before","after"],"description":"Comparison operator.","isRequired":true,"uniqueKey":"nodes.items.[INDEX].oneOf.7.branches.items.[INDEX].condition.oneOf.2.attributes.items.[INDEX].items.[INDEX].operator","typeLabel":"enum\u003cstring>"},"value":{"type":"string","description":"Value to compare against. Not required for `exists` and `not_exists`.","uniqueKey":"nodes.items.[INDEX].oneOf.7.branches.items.[INDEX].condition.oneOf.2.attributes.items.[INDEX].items.[INDEX].value","typeLabel":"string"}},"uniqueKey":"nodes.items.[INDEX].oneOf.7.branches.items.[INDEX].condition.oneOf.2.attributes.items.[INDEX].items.[INDEX]","typeLabel":"object"},"uniqueKey":"nodes.items.[INDEX].oneOf.7.branches.items.[INDEX].condition.oneOf.2.attributes.items.[INDEX]","typeLabel":"object[]"},"uniqueKey":"nodes.items.[INDEX].oneOf.7.branches.items.[INDEX].condition.oneOf.2.attributes","typeLabel":"object[][]"},"entry_event_match_attributes":{"oneOf":[{"type":"array","items":{"type":"object","uniqueKey":"nodes.items.[INDEX].oneOf.7.branches.items.[INDEX].condition.oneOf.2.entry_event_match_attributes.oneOf.0.items.[INDEX]","typeLabel":"object"},"description":"Match incoming event properties against the journey's entry event. Only valid on event-triggered journeys.","uniqueKey":"nodes.items.[INDEX].oneOf.7.branches.items.[INDEX].condition.oneOf.2.entry_event_match_attributes.oneOf.0","typeLabel":"object[]"},{"type":"null","items":{"type":"object"},"description":"Match incoming event properties against the journey's entry event. Only valid on event-triggered journeys.","uniqueKey":"nodes.items.[INDEX].oneOf.7.branches.items.[INDEX].condition.oneOf.2.entry_event_match_attributes.oneOf.1","typeLabel":"null"}],"uniqueKey":"nodes.items.[INDEX].oneOf.7.branches.items.[INDEX].condition.oneOf.2.entry_event_match_attributes","typeLabel":"object[] | null"}},"uniqueKey":"nodes.items.[INDEX].oneOf.7.branches.items.[INDEX].condition.oneOf.2","typeLabel":"event_trigger · object"}],"uniqueKey":"nodes.items.[INDEX].oneOf.7.branches.items.[INDEX].condition","typeLabel":"segment_membership · object | on_notification_action · object | event_trigger · object"},"weight":{"type":"number","description":"Branch weight for `split_range` nodes. Weights across a node's branches must sum to 100.","uniqueKey":"nodes.items.[INDEX].oneOf.7.branches.items.[INDEX].weight","typeLabel":"number"},"nodes":{"type":"array","items":{"$circularRef":"f6795843-f004-4026-9a86-d14c359fdee3"},"description":"Nodes run when this branch is taken, before flow converges to the next sibling node.","uniqueKey":"nodes.items.[INDEX].oneOf.7.branches.items.[INDEX].nodes","typeLabel":"array"}},"uniqueKey":"nodes.items.[INDEX].oneOf.7.branches.items.[INDEX]","typeLabel":"object"},"description":"Exactly two branches. The branch with a `condition` is the \"yes\" branch; the branch without one is the \"no\" branch.","uniqueKey":"nodes.items.[INDEX].oneOf.7.branches","typeLabel":"object[]"}},"uniqueKey":"nodes.items.[INDEX].oneOf.7","typeLabel":"object"},{"type":"object","description":"A journey node. The `kind` field selects the shape. Branching nodes (`split_range`, `yes_no`, `wait_until`) nest their sub-graphs inline via `branches[].nodes`.","required":["kind"],"properties":{"kind":{"type":"string","const":"wait_until","description":"Holds the user until any branch condition is met, or an optional expiration timer fires.","isRequired":true,"uniqueKey":"nodes.items.[INDEX].oneOf.8.kind","typeLabel":"string"},"id":{"type":"string","description":"Server-assigned node UUID. Read-only. Returned on reads; sending it on create is rejected with a `400` validation error.","uniqueKey":"nodes.items.[INDEX].oneOf.8.id","typeLabel":"string"},"client_node_id":{"type":"string","description":"Optional client-assigned identifier, unique within the journey. Use it to reference this node from elsewhere in the same request (for example as `client_node_id` on an `on_notification_action` condition). Persisted and returned on reads.","uniqueKey":"nodes.items.[INDEX].oneOf.8.client_node_id","typeLabel":"string"},"annotation":{"type":"string","description":"Optional free-text label, up to 1024 characters. Stored and returned as-is with no effect on journey behavior.","uniqueKey":"nodes.items.[INDEX].oneOf.8.annotation","typeLabel":"string"},"branches":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","description":"Server-assigned branch identifier. Read-only.","uniqueKey":"nodes.items.[INDEX].oneOf.8.branches.items.[INDEX].id","typeLabel":"string"},"condition":{"oneOf":[{"type":"object","title":"segment_membership","description":"A branch condition. The `kind` field selects the shape.","required":["kind"],"properties":{"kind":{"type":"string","const":"segment_membership","isRequired":true,"uniqueKey":"nodes.items.[INDEX].oneOf.8.branches.items.[INDEX].condition.oneOf.0.kind","typeLabel":"string"},"included_segment_ids":{"type":"array","items":{"type":"string","uniqueKey":"nodes.items.[INDEX].oneOf.8.branches.items.[INDEX].condition.oneOf.0.included_segment_ids.items.[INDEX]","typeLabel":"string"},"description":"Segment UUIDs the user must belong to.","uniqueKey":"nodes.items.[INDEX].oneOf.8.branches.items.[INDEX].condition.oneOf.0.included_segment_ids","typeLabel":"string[]"},"excluded_segment_ids":{"type":"array","items":{"type":"string","uniqueKey":"nodes.items.[INDEX].oneOf.8.branches.items.[INDEX].condition.oneOf.0.excluded_segment_ids.items.[INDEX]","typeLabel":"string"},"description":"Segment UUIDs the user must not belong to.","uniqueKey":"nodes.items.[INDEX].oneOf.8.branches.items.[INDEX].condition.oneOf.0.excluded_segment_ids","typeLabel":"string[]"}},"uniqueKey":"nodes.items.[INDEX].oneOf.8.branches.items.[INDEX].condition.oneOf.0","typeLabel":"segment_membership · object"},{"type":"object","title":"on_notification_action","description":"A branch condition. The `kind` field selects the shape.","required":["kind"],"properties":{"kind":{"type":"string","const":"on_notification_action","isRequired":true,"uniqueKey":"nodes.items.[INDEX].oneOf.8.branches.items.[INDEX].condition.oneOf.1.kind","typeLabel":"string"},"action":{"type":"string","enum":["received","clicked","opened"],"description":"The notification action to branch on. Which actions apply depends on the sending node's channel.","uniqueKey":"nodes.items.[INDEX].oneOf.8.branches.items.[INDEX].condition.oneOf.1.action","typeLabel":"enum\u003cstring>"},"sending_node_id":{"type":"string","description":"`id` of the sending node this action refers to. Returned on reads; accepted on write.","uniqueKey":"nodes.items.[INDEX].oneOf.8.branches.items.[INDEX].condition.oneOf.1.sending_node_id","typeLabel":"string"},"client_node_id":{"type":"string","description":"Write-only alternative to `sending_node_id`. References the sending node by its `client_node_id`, which is resolved to that node's `id`.","uniqueKey":"nodes.items.[INDEX].oneOf.8.branches.items.[INDEX].condition.oneOf.1.client_node_id","typeLabel":"string"}},"uniqueKey":"nodes.items.[INDEX].oneOf.8.branches.items.[INDEX].condition.oneOf.1","typeLabel":"on_notification_action · object"},{"type":"object","title":"event_trigger","description":"A branch condition. The `kind` field selects the shape.","required":["kind"],"properties":{"kind":{"type":"string","const":"event_trigger","isRequired":true,"uniqueKey":"nodes.items.[INDEX].oneOf.8.branches.items.[INDEX].condition.oneOf.2.kind","typeLabel":"string"},"name":{"type":"string","description":"Event name, up to 255 characters.","uniqueKey":"nodes.items.[INDEX].oneOf.8.branches.items.[INDEX].condition.oneOf.2.name","typeLabel":"string"},"attributes":{"type":"array","description":"Event attribute matchers, as a list of condition groups. Send a single group whose conditions are AND'd together. More than one group is rejected.","items":{"type":"array","items":{"type":"object","required":["key","operator"],"properties":{"key":{"type":"string","description":"Event attribute key.","isRequired":true,"uniqueKey":"nodes.items.[INDEX].oneOf.8.branches.items.[INDEX].condition.oneOf.2.attributes.items.[INDEX].items.[INDEX].key","typeLabel":"string"},"operator":{"type":"string","enum":["equal","not_equal","less","less_or_equal","greater_or_equal","greater","is","is_not","exists","not_exists","before","after"],"description":"Comparison operator.","isRequired":true,"uniqueKey":"nodes.items.[INDEX].oneOf.8.branches.items.[INDEX].condition.oneOf.2.attributes.items.[INDEX].items.[INDEX].operator","typeLabel":"enum\u003cstring>"},"value":{"type":"string","description":"Value to compare against. Not required for `exists` and `not_exists`.","uniqueKey":"nodes.items.[INDEX].oneOf.8.branches.items.[INDEX].condition.oneOf.2.attributes.items.[INDEX].items.[INDEX].value","typeLabel":"string"}},"uniqueKey":"nodes.items.[INDEX].oneOf.8.branches.items.[INDEX].condition.oneOf.2.attributes.items.[INDEX].items.[INDEX]","typeLabel":"object"},"uniqueKey":"nodes.items.[INDEX].oneOf.8.branches.items.[INDEX].condition.oneOf.2.attributes.items.[INDEX]","typeLabel":"object[]"},"uniqueKey":"nodes.items.[INDEX].oneOf.8.branches.items.[INDEX].condition.oneOf.2.attributes","typeLabel":"object[][]"},"entry_event_match_attributes":{"oneOf":[{"type":"array","items":{"type":"object","uniqueKey":"nodes.items.[INDEX].oneOf.8.branches.items.[INDEX].condition.oneOf.2.entry_event_match_attributes.oneOf.0.items.[INDEX]","typeLabel":"object"},"description":"Match incoming event properties against the journey's entry event. Only valid on event-triggered journeys.","uniqueKey":"nodes.items.[INDEX].oneOf.8.branches.items.[INDEX].condition.oneOf.2.entry_event_match_attributes.oneOf.0","typeLabel":"object[]"},{"type":"null","items":{"type":"object"},"description":"Match incoming event properties against the journey's entry event. Only valid on event-triggered journeys.","uniqueKey":"nodes.items.[INDEX].oneOf.8.branches.items.[INDEX].condition.oneOf.2.entry_event_match_attributes.oneOf.1","typeLabel":"null"}],"uniqueKey":"nodes.items.[INDEX].oneOf.8.branches.items.[INDEX].condition.oneOf.2.entry_event_match_attributes","typeLabel":"object[] | null"}},"uniqueKey":"nodes.items.[INDEX].oneOf.8.branches.items.[INDEX].condition.oneOf.2","typeLabel":"event_trigger · object"}],"uniqueKey":"nodes.items.[INDEX].oneOf.8.branches.items.[INDEX].condition","typeLabel":"segment_membership · object | on_notification_action · object | event_trigger · object"},"weight":{"type":"number","description":"Branch weight for `split_range` nodes. Weights across a node's branches must sum to 100.","uniqueKey":"nodes.items.[INDEX].oneOf.8.branches.items.[INDEX].weight","typeLabel":"number"},"nodes":{"type":"array","items":{"$circularRef":"f6795843-f004-4026-9a86-d14c359fdee3"},"description":"Nodes run when this branch is taken, before flow converges to the next sibling node.","uniqueKey":"nodes.items.[INDEX].oneOf.8.branches.items.[INDEX].nodes","typeLabel":"array"}},"uniqueKey":"nodes.items.[INDEX].oneOf.8.branches.items.[INDEX]","typeLabel":"object"},"description":"Condition branches. At least one required, at most 25. Order determines priority.","minItems":1,"maxItems":25,"uniqueKey":"nodes.items.[INDEX].oneOf.8.branches","typeLabel":"object[]"},"expiration":{"oneOf":[{"type":"object","properties":{"duration_seconds":{"type":"integer","minimum":60,"description":"Seconds to wait before the timer fires. Minimum `60`, maximum `31556952` (1 year).","maximum":31556952,"uniqueKey":"nodes.items.[INDEX].oneOf.8.expiration.oneOf.0.duration_seconds","typeLabel":"integer"},"exits":{"type":"boolean","description":"When true, the user exits the journey when the timer fires; when false, the user continues to convergence.","uniqueKey":"nodes.items.[INDEX].oneOf.8.expiration.oneOf.0.exits","typeLabel":"boolean"}},"description":"Optional expiration timer. `null` waits indefinitely.","uniqueKey":"nodes.items.[INDEX].oneOf.8.expiration.oneOf.0","typeLabel":"object"},{"type":"null","properties":{"duration_seconds":{"type":"integer","minimum":60,"description":"Seconds to wait before the timer fires. Minimum `60`, maximum `31556952` (1 year).","maximum":31556952},"exits":{"type":"boolean","description":"When true, the user exits the journey when the timer fires; when false, the user continues to convergence."}},"description":"Optional expiration timer. `null` waits indefinitely.","uniqueKey":"nodes.items.[INDEX].oneOf.8.expiration.oneOf.1","typeLabel":"null"}],"uniqueKey":"nodes.items.[INDEX].oneOf.8.expiration","typeLabel":"object | null"}},"uniqueKey":"nodes.items.[INDEX].oneOf.8","typeLabel":"object"}],"uniqueKey":"nodes.items.[INDEX]","typeLabel":"object"},"description":"Ordered list of journey nodes. Server-assigned `id` fields are rejected on create with a `400` validation error.","uniqueKey":"nodes","typeLabel":"object[]"}},"uniqueKey":"","typeLabel":"object"},"examples":{"Request":{"title":"Request","value":{"name":"Welcome series","description":"Onboard new users over their first week.","audience":{"kind":"segment","included_segment_ids":["3f7c1e90-0000-0000-0000-000000000001"],"excluded_segment_ids":[]},"nodes":[{"kind":"send_push","template_id":"9a8b7c6d-0000-0000-0000-000000000001"},{"kind":"wait","duration_seconds":86400},{"kind":"send_email","template_id":"9a8b7c6d-0000-0000-0000-000000000002"}]}}},"exampleType":"examples"}},"exampleType":"examples"},"responses":{"96cfbfcc-802f-4061-b1b6-08f251438cbe":{"description":"201","content":{"application/json":{"schema":{"type":"object","description":"Full journey representation returned by the detail and create endpoints.","properties":{"id":{"type":"string","description":"Journey UUID. Read-only.","uniqueKey":"id","typeLabel":"string"},"app_id":{"type":"string","description":"UUID of the app the journey belongs to. Read-only.","uniqueKey":"app_id","typeLabel":"string"},"name":{"type":"string","description":"Journey name, up to 300 characters.","uniqueKey":"name","typeLabel":"string"},"description":{"oneOf":[{"type":"string","description":"Journey description, up to 1024 characters. Defaults to an empty string.","uniqueKey":"description.oneOf.0","typeLabel":"string"},{"type":"null","description":"Journey description, up to 1024 characters. Defaults to an empty string.","uniqueKey":"description.oneOf.1","typeLabel":"null"}],"uniqueKey":"description","typeLabel":"string | null"},"state":{"type":"string","enum":["draft","scheduled","processing","active","archived"],"description":"Journey state. Read-only. New journeys are created as `draft`. `processing` is a transient state while an activation is in progress, and `archived` is a journey that has been stopped. Change it through the `state` field on [Update journey](/reference/update-journey).","uniqueKey":"state","typeLabel":"enum\u003cstring>"},"created_at":{"type":"string","description":"ISO 8601 creation time. Read-only.","uniqueKey":"created_at","typeLabel":"string"},"updated_at":{"type":"string","description":"ISO 8601 last-update time. Read-only.","uniqueKey":"updated_at","typeLabel":"string"},"started_at":{"oneOf":[{"type":"string","description":"ISO 8601 time the journey was activated, or `null`. Read-only. May stay `null` briefly after you set `state` to `active`: activation is enqueued for processing, and `started_at` populates once the journey finishes processing and becomes active.","uniqueKey":"started_at.oneOf.0","typeLabel":"string"},{"type":"null","description":"ISO 8601 time the journey was activated, or `null`. Read-only. May stay `null` briefly after you set `state` to `active`: activation is enqueued for processing, and `started_at` populates once the journey finishes processing and becomes active.","uniqueKey":"started_at.oneOf.1","typeLabel":"null"}],"uniqueKey":"started_at","typeLabel":"string | null"},"archived_at":{"oneOf":[{"type":"string","description":"ISO 8601 time the journey was archived, or `null`. Read-only.","uniqueKey":"archived_at.oneOf.0","typeLabel":"string"},{"type":"null","description":"ISO 8601 time the journey was archived, or `null`. Read-only.","uniqueKey":"archived_at.oneOf.1","typeLabel":"null"}],"uniqueKey":"archived_at","typeLabel":"string | null"},"created_source":{"oneOf":[{"type":"string","description":"Origin of the journey, for example `public_api` or `dashboard`. Read-only.","uniqueKey":"created_source.oneOf.0","typeLabel":"string"},{"type":"null","description":"Origin of the journey, for example `public_api` or `dashboard`. Read-only.","uniqueKey":"created_source.oneOf.1","typeLabel":"null"}],"uniqueKey":"created_source","typeLabel":"string | null"},"audience":{"oneOf":[{"type":"object","title":"segment","description":"The journey entry audience. Either a segment-based or event-triggered audience.","required":["kind"],"properties":{"kind":{"type":"string","const":"segment","isRequired":true,"uniqueKey":"audience.oneOf.0.kind","typeLabel":"string"},"included_segment_ids":{"type":"array","items":{"type":"string","uniqueKey":"audience.oneOf.0.included_segment_ids.items.[INDEX]","typeLabel":"string"},"description":"Segment UUIDs whose users enter the journey.","uniqueKey":"audience.oneOf.0.included_segment_ids","typeLabel":"string[]"},"excluded_segment_ids":{"type":"array","items":{"type":"string","uniqueKey":"audience.oneOf.0.excluded_segment_ids.items.[INDEX]","typeLabel":"string"},"description":"Segment UUIDs whose users are excluded.","uniqueKey":"audience.oneOf.0.excluded_segment_ids","typeLabel":"string[]"},"future_additions_only":{"type":"boolean","description":"When true, only users who newly match the segment after activation enter the journey. Defaults to false.","uniqueKey":"audience.oneOf.0.future_additions_only","typeLabel":"boolean"}},"uniqueKey":"audience.oneOf.0","typeLabel":"segment · object"},{"type":"object","title":"event_trigger","description":"The journey entry audience. Either a segment-based or event-triggered audience.","required":["kind"],"properties":{"kind":{"type":"string","const":"event_trigger","isRequired":true,"uniqueKey":"audience.oneOf.1.kind","typeLabel":"string"},"name":{"type":"string","description":"Event name that triggers entry, up to 255 characters.","uniqueKey":"audience.oneOf.1.name","typeLabel":"string"},"attributes":{"type":"array","description":"Event attribute matchers, as a list of condition groups. Send a single group whose conditions are AND'd together. More than one group is rejected.","items":{"type":"array","items":{"type":"object","required":["key","operator"],"properties":{"key":{"type":"string","description":"Event attribute key.","isRequired":true,"uniqueKey":"audience.oneOf.1.attributes.items.[INDEX].items.[INDEX].key","typeLabel":"string"},"operator":{"type":"string","enum":["equal","not_equal","less","less_or_equal","greater_or_equal","greater","is","is_not","exists","not_exists","before","after"],"description":"Comparison operator.","isRequired":true,"uniqueKey":"audience.oneOf.1.attributes.items.[INDEX].items.[INDEX].operator","typeLabel":"enum\u003cstring>"},"value":{"type":"string","description":"Value to compare against. Not required for `exists` and `not_exists`.","uniqueKey":"audience.oneOf.1.attributes.items.[INDEX].items.[INDEX].value","typeLabel":"string"}},"uniqueKey":"audience.oneOf.1.attributes.items.[INDEX].items.[INDEX]","typeLabel":"object"},"uniqueKey":"audience.oneOf.1.attributes.items.[INDEX]","typeLabel":"object[]"},"uniqueKey":"audience.oneOf.1.attributes","typeLabel":"object[][]"}},"uniqueKey":"audience.oneOf.1","typeLabel":"event_trigger · object"}],"uniqueKey":"audience","typeLabel":"segment · object | event_trigger · object"},"early_exit":{"oneOf":[{"type":"object","description":"Conditions that remove a user from the journey before it completes. At least one rule must be set under `rules`; an early_exit that configures no rule is rejected. Send `null` to remove early exit entirely, or `null` for an individual rule to drop just that rule.","properties":{"rules":{"type":"object","properties":{"on_segment":{"oneOf":[{"type":"object","properties":{"included_segment_ids":{"type":"array","items":{"type":"string","uniqueKey":"early_exit.oneOf.0.rules.on_segment.oneOf.0.included_segment_ids.items.[INDEX]","typeLabel":"string"},"description":"Exit when the user enters any of these segments.","uniqueKey":"early_exit.oneOf.0.rules.on_segment.oneOf.0.included_segment_ids","typeLabel":"string[]"}},"uniqueKey":"early_exit.oneOf.0.rules.on_segment.oneOf.0","typeLabel":"object"},{"type":"null","properties":{"included_segment_ids":{"type":"array","items":{"type":"string"},"description":"Exit when the user enters any of these segments."}},"uniqueKey":"early_exit.oneOf.0.rules.on_segment.oneOf.1","typeLabel":"null"}],"uniqueKey":"early_exit.oneOf.0.rules.on_segment","typeLabel":"object | null"},"when_not_in_audience":{"oneOf":[{"type":"boolean","description":"Exit when the user no longer matches the journey audience. Defaults to false.","uniqueKey":"early_exit.oneOf.0.rules.when_not_in_audience.oneOf.0","typeLabel":"boolean"},{"type":"null","description":"Exit when the user no longer matches the journey audience. Defaults to false.","uniqueKey":"early_exit.oneOf.0.rules.when_not_in_audience.oneOf.1","typeLabel":"null"}],"uniqueKey":"early_exit.oneOf.0.rules.when_not_in_audience","typeLabel":"boolean | null"},"on_session":{"oneOf":[{"type":"boolean","description":"Exit on a new session start. Defaults to false.","uniqueKey":"early_exit.oneOf.0.rules.on_session.oneOf.0","typeLabel":"boolean"},{"type":"null","description":"Exit on a new session start. Defaults to false.","uniqueKey":"early_exit.oneOf.0.rules.on_session.oneOf.1","typeLabel":"null"}],"uniqueKey":"early_exit.oneOf.0.rules.on_session","typeLabel":"boolean | null"},"on_event":{"oneOf":[{"type":"object","required":["name"],"properties":{"name":{"type":"string","description":"Exit when this event occurs. Up to 255 characters.","isRequired":true,"uniqueKey":"early_exit.oneOf.0.rules.on_event.oneOf.0.name","typeLabel":"string"}},"uniqueKey":"early_exit.oneOf.0.rules.on_event.oneOf.0","typeLabel":"object"},{"type":"null","required":["name"],"properties":{"name":{"type":"string","description":"Exit when this event occurs. Up to 255 characters."}},"uniqueKey":"early_exit.oneOf.0.rules.on_event.oneOf.1","typeLabel":"null"}],"uniqueKey":"early_exit.oneOf.0.rules.on_event","typeLabel":"object | null"}},"uniqueKey":"early_exit.oneOf.0.rules","typeLabel":"object"},"tag_on_early_exit":{"type":"object","additionalProperties":{"type":"string","uniqueKey":"early_exit.oneOf.0.tag_on_early_exit.additionalProperties","typeLabel":"string"},"description":"Tag key-value pairs applied when a user exits early.","uniqueKey":"early_exit.oneOf.0.tag_on_early_exit","typeLabel":"object"}},"uniqueKey":"early_exit.oneOf.0","typeLabel":"object"},{"type":"null","description":"Conditions that remove a user from the journey before it completes. At least one rule must be set under `rules`; an early_exit that configures no rule is rejected. Send `null` to remove early exit entirely, or `null` for an individual rule to drop just that rule.","properties":{"rules":{"type":"object","properties":{"on_segment":{"oneOf":[{"type":"object","properties":{"included_segment_ids":{"type":"array","items":{"type":"string"},"description":"Exit when the user enters any of these segments."}}},{"type":"null","properties":{"included_segment_ids":{"type":"array","items":{"type":"string"},"description":"Exit when the user enters any of these segments."}}}]},"when_not_in_audience":{"oneOf":[{"type":"boolean","description":"Exit when the user no longer matches the journey audience. Defaults to false."},{"type":"null","description":"Exit when the user no longer matches the journey audience. Defaults to false."}]},"on_session":{"oneOf":[{"type":"boolean","description":"Exit on a new session start. Defaults to false."},{"type":"null","description":"Exit on a new session start. Defaults to false."}]},"on_event":{"oneOf":[{"type":"object","required":["name"],"properties":{"name":{"type":"string","description":"Exit when this event occurs. Up to 255 characters."}}},{"type":"null","required":["name"],"properties":{"name":{"type":"string","description":"Exit when this event occurs. Up to 255 characters."}}}]}}},"tag_on_early_exit":{"type":"object","additionalProperties":{"type":"string"},"description":"Tag key-value pairs applied when a user exits early."}},"uniqueKey":"early_exit.oneOf.1","typeLabel":"null"}],"uniqueKey":"early_exit","typeLabel":"object | null"},"reentry_rules":{"oneOf":[{"type":"object","description":"Controls whether and how soon a user can re-enter the journey. `null` means re-entry is not allowed.","properties":{"duration_seconds":{"type":"integer","minimum":600,"description":"Minimum seconds before a user can re-enter. Must be at least `600` (10 minutes).","uniqueKey":"reentry_rules.oneOf.0.duration_seconds","typeLabel":"integer"}},"uniqueKey":"reentry_rules.oneOf.0","typeLabel":"object"},{"type":"null","description":"Controls whether and how soon a user can re-enter the journey. `null` means re-entry is not allowed.","properties":{"duration_seconds":{"type":"integer","minimum":600,"description":"Minimum seconds before a user can re-enter. Must be at least `600` (10 minutes)."}},"uniqueKey":"reentry_rules.oneOf.1","typeLabel":"null"}],"uniqueKey":"reentry_rules","typeLabel":"object | null"},"schedule":{"oneOf":[{"type":"object","description":"Optional future start and/or stop time. `null` means no scheduled activation.","properties":{"start_at":{"oneOf":[{"type":"string","description":"ISO 8601 start time. Use UTC (`Z` or `+00:00`). Must be at least 5 minutes in the future.","uniqueKey":"schedule.oneOf.0.start_at.oneOf.0","typeLabel":"string"},{"type":"null","description":"ISO 8601 start time. Use UTC (`Z` or `+00:00`). Must be at least 5 minutes in the future.","uniqueKey":"schedule.oneOf.0.start_at.oneOf.1","typeLabel":"null"}],"uniqueKey":"schedule.oneOf.0.start_at","typeLabel":"string | null"},"stop_at":{"oneOf":[{"type":"string","description":"ISO 8601 stop time. Use UTC (`Z` or `+00:00`). Must be in the future and later than `start_at`.","uniqueKey":"schedule.oneOf.0.stop_at.oneOf.0","typeLabel":"string"},{"type":"null","description":"ISO 8601 stop time. Use UTC (`Z` or `+00:00`). Must be in the future and later than `start_at`.","uniqueKey":"schedule.oneOf.0.stop_at.oneOf.1","typeLabel":"null"}],"uniqueKey":"schedule.oneOf.0.stop_at","typeLabel":"string | null"},"error":{"oneOf":[{"type":"string","description":"Read-only. Present when a scheduling error occurred.","uniqueKey":"schedule.oneOf.0.error.oneOf.0","typeLabel":"string"},{"type":"null","description":"Read-only. Present when a scheduling error occurred.","uniqueKey":"schedule.oneOf.0.error.oneOf.1","typeLabel":"null"}],"uniqueKey":"schedule.oneOf.0.error","typeLabel":"string | null"}},"uniqueKey":"schedule.oneOf.0","typeLabel":"object"},{"type":"null","description":"Optional future start and/or stop time. `null` means no scheduled activation.","properties":{"start_at":{"oneOf":[{"type":"string","description":"ISO 8601 start time. Use UTC (`Z` or `+00:00`). Must be at least 5 minutes in the future."},{"type":"null","description":"ISO 8601 start time. Use UTC (`Z` or `+00:00`). Must be at least 5 minutes in the future."}]},"stop_at":{"oneOf":[{"type":"string","description":"ISO 8601 stop time. Use UTC (`Z` or `+00:00`). Must be in the future and later than `start_at`."},{"type":"null","description":"ISO 8601 stop time. Use UTC (`Z` or `+00:00`). Must be in the future and later than `start_at`."}]},"error":{"oneOf":[{"type":"string","description":"Read-only. Present when a scheduling error occurred."},{"type":"null","description":"Read-only. Present when a scheduling error occurred."}]}},"uniqueKey":"schedule.oneOf.1","typeLabel":"null"}],"uniqueKey":"schedule","typeLabel":"object | null"},"nodes":{"type":"array","items":{"oneOf":[{"type":"object","description":"A journey node. The `kind` field selects the shape. Branching nodes (`split_range`, `yes_no`, `wait_until`) nest their sub-graphs inline via `branches[].nodes`.","required":["kind"],"properties":{"kind":{"type":"string","const":"wait","description":"Holds the user for a fixed duration before continuing.","isRequired":true,"uniqueKey":"nodes.items.[INDEX].oneOf.0.kind","typeLabel":"string"},"id":{"type":"string","description":"Server-assigned node UUID. Read-only. Returned on reads; sending it on create is rejected with a `400` validation error.","uniqueKey":"nodes.items.[INDEX].oneOf.0.id","typeLabel":"string"},"client_node_id":{"type":"string","description":"Optional client-assigned identifier, unique within the journey. Use it to reference this node from elsewhere in the same request (for example as `client_node_id` on an `on_notification_action` condition). Persisted and returned on reads.","uniqueKey":"nodes.items.[INDEX].oneOf.0.client_node_id","typeLabel":"string"},"annotation":{"type":"string","description":"Optional free-text label, up to 1024 characters. Stored and returned as-is with no effect on journey behavior.","uniqueKey":"nodes.items.[INDEX].oneOf.0.annotation","typeLabel":"string"},"duration_seconds":{"type":"integer","description":"Seconds to hold the user. Minimum `60`, maximum `31556952` (1 year).","minimum":60,"maximum":31556952,"uniqueKey":"nodes.items.[INDEX].oneOf.0.duration_seconds","typeLabel":"integer"}},"uniqueKey":"nodes.items.[INDEX].oneOf.0","typeLabel":"object"},{"type":"object","description":"A journey node. The `kind` field selects the shape. Branching nodes (`split_range`, `yes_no`, `wait_until`) nest their sub-graphs inline via `branches[].nodes`.","required":["kind"],"properties":{"kind":{"type":"string","const":"time_window","description":"Holds the user until the next configured time window opens.","isRequired":true,"uniqueKey":"nodes.items.[INDEX].oneOf.1.kind","typeLabel":"string"},"id":{"type":"string","description":"Server-assigned node UUID. Read-only. Returned on reads; sending it on create is rejected with a `400` validation error.","uniqueKey":"nodes.items.[INDEX].oneOf.1.id","typeLabel":"string"},"client_node_id":{"type":"string","description":"Optional client-assigned identifier, unique within the journey. Use it to reference this node from elsewhere in the same request (for example as `client_node_id` on an `on_notification_action` condition). Persisted and returned on reads.","uniqueKey":"nodes.items.[INDEX].oneOf.1.client_node_id","typeLabel":"string"},"annotation":{"type":"string","description":"Optional free-text label, up to 1024 characters. Stored and returned as-is with no effect on journey behavior.","uniqueKey":"nodes.items.[INDEX].oneOf.1.annotation","typeLabel":"string"},"relative_to":{"type":"string","enum":["schedule_in_timezone","last_active_time"],"description":"`schedule_in_timezone` uses the configured windows; `last_active_time` holds relative to the user's last active time.","uniqueKey":"nodes.items.[INDEX].oneOf.1.relative_to","typeLabel":"enum\u003cstring>"},"windows":{"type":"array","items":{"type":"object","properties":{"start":{"type":"object","description":"When the window opens.","properties":{"hour":{"type":"integer","minimum":0,"maximum":23,"description":"Hour of day, 0-23.","uniqueKey":"nodes.items.[INDEX].oneOf.1.windows.items.[INDEX].start.hour","typeLabel":"integer"},"minute":{"type":"integer","minimum":0,"maximum":59,"description":"Minute of hour, 0-59. Defaults to 0.","uniqueKey":"nodes.items.[INDEX].oneOf.1.windows.items.[INDEX].start.minute","typeLabel":"integer"}},"uniqueKey":"nodes.items.[INDEX].oneOf.1.windows.items.[INDEX].start","typeLabel":"object"},"end":{"type":"object","description":"When the window closes.","properties":{"hour":{"type":"integer","minimum":0,"maximum":23,"description":"Hour of day, 0-23.","uniqueKey":"nodes.items.[INDEX].oneOf.1.windows.items.[INDEX].end.hour","typeLabel":"integer"},"minute":{"type":"integer","minimum":0,"maximum":59,"description":"Minute of hour, 0-59. Defaults to 0.","uniqueKey":"nodes.items.[INDEX].oneOf.1.windows.items.[INDEX].end.minute","typeLabel":"integer"}},"uniqueKey":"nodes.items.[INDEX].oneOf.1.windows.items.[INDEX].end","typeLabel":"object"},"day_of_week":{"type":"integer","minimum":1,"maximum":7,"description":"Day of week, 1 = Monday. Omit to apply the window to every day.","uniqueKey":"nodes.items.[INDEX].oneOf.1.windows.items.[INDEX].day_of_week","typeLabel":"integer"}},"description":"A wall-clock window. Each window must span at least 15 minutes.","uniqueKey":"nodes.items.[INDEX].oneOf.1.windows.items.[INDEX]","typeLabel":"object"},"description":"One or more time windows. A window with no `day_of_week` applies to every day, and is returned in that same day-agnostic form. Required when `relative_to` is `schedule_in_timezone`; must be omitted when it is `last_active_time`, and is absent from responses for those nodes.","uniqueKey":"nodes.items.[INDEX].oneOf.1.windows","typeLabel":"object[]"},"time_zone":{"type":"string","description":"IANA timezone identifier used when the user's timezone is unavailable.","uniqueKey":"nodes.items.[INDEX].oneOf.1.time_zone","typeLabel":"string"},"use_user_time_zone":{"type":"boolean","description":"When true, uses the user's timezone if available.","uniqueKey":"nodes.items.[INDEX].oneOf.1.use_user_time_zone","typeLabel":"boolean"}},"uniqueKey":"nodes.items.[INDEX].oneOf.1","typeLabel":"object"},{"type":"object","description":"A journey node. The `kind` field selects the shape. Branching nodes (`split_range`, `yes_no`, `wait_until`) nest their sub-graphs inline via `branches[].nodes`.","required":["kind"],"properties":{"kind":{"type":"string","enum":["send_push","send_email","send_sms"],"description":"Sends a message on the given channel using a template.","isRequired":true,"uniqueKey":"nodes.items.[INDEX].oneOf.2.kind","typeLabel":"enum\u003cstring>"},"id":{"type":"string","description":"Server-assigned node UUID. Read-only. Returned on reads; sending it on create is rejected with a `400` validation error.","uniqueKey":"nodes.items.[INDEX].oneOf.2.id","typeLabel":"string"},"client_node_id":{"type":"string","description":"Optional client-assigned identifier, unique within the journey. Use it to reference this node from elsewhere in the same request (for example as `client_node_id` on an `on_notification_action` condition). Persisted and returned on reads.","uniqueKey":"nodes.items.[INDEX].oneOf.2.client_node_id","typeLabel":"string"},"annotation":{"type":"string","description":"Optional free-text label, up to 1024 characters. Stored and returned as-is with no effect on journey behavior.","uniqueKey":"nodes.items.[INDEX].oneOf.2.annotation","typeLabel":"string"},"template_id":{"type":"string","description":"UUID of the template to send.","uniqueKey":"nodes.items.[INDEX].oneOf.2.template_id","typeLabel":"string"}},"uniqueKey":"nodes.items.[INDEX].oneOf.2","typeLabel":"object"},{"type":"object","description":"A journey node. The `kind` field selects the shape. Branching nodes (`split_range`, `yes_no`, `wait_until`) nest their sub-graphs inline via `branches[].nodes`.","required":["kind"],"properties":{"kind":{"type":"string","const":"send_iam","description":"Sends an in-app message.","isRequired":true,"uniqueKey":"nodes.items.[INDEX].oneOf.3.kind","typeLabel":"string"},"id":{"type":"string","description":"Server-assigned node UUID. Read-only. Returned on reads; sending it on create is rejected with a `400` validation error.","uniqueKey":"nodes.items.[INDEX].oneOf.3.id","typeLabel":"string"},"client_node_id":{"type":"string","description":"Optional client-assigned identifier, unique within the journey. Use it to reference this node from elsewhere in the same request (for example as `client_node_id` on an `on_notification_action` condition). Persisted and returned on reads.","uniqueKey":"nodes.items.[INDEX].oneOf.3.client_node_id","typeLabel":"string"},"annotation":{"type":"string","description":"Optional free-text label, up to 1024 characters. Stored and returned as-is with no effect on journey behavior.","uniqueKey":"nodes.items.[INDEX].oneOf.3.annotation","typeLabel":"string"},"iam_id":{"type":"string","description":"UUID of the in-app message to send.","uniqueKey":"nodes.items.[INDEX].oneOf.3.iam_id","typeLabel":"string"},"user_ttl_seconds":{"type":"integer","minimum":1,"description":"Optional time-to-live for the in-app message, in seconds.","uniqueKey":"nodes.items.[INDEX].oneOf.3.user_ttl_seconds","typeLabel":"integer"}},"uniqueKey":"nodes.items.[INDEX].oneOf.3","typeLabel":"object"},{"type":"object","description":"A journey node. The `kind` field selects the shape. Branching nodes (`split_range`, `yes_no`, `wait_until`) nest their sub-graphs inline via `branches[].nodes`.","required":["kind"],"properties":{"kind":{"type":"string","const":"send_webhook","description":"Sends a webhook.","isRequired":true,"uniqueKey":"nodes.items.[INDEX].oneOf.4.kind","typeLabel":"string"},"id":{"type":"string","description":"Server-assigned node UUID. Read-only. Returned on reads; sending it on create is rejected with a `400` validation error.","uniqueKey":"nodes.items.[INDEX].oneOf.4.id","typeLabel":"string"},"client_node_id":{"type":"string","description":"Optional client-assigned identifier, unique within the journey. Use it to reference this node from elsewhere in the same request (for example as `client_node_id` on an `on_notification_action` condition). Persisted and returned on reads.","uniqueKey":"nodes.items.[INDEX].oneOf.4.client_node_id","typeLabel":"string"},"annotation":{"type":"string","description":"Optional free-text label, up to 1024 characters. Stored and returned as-is with no effect on journey behavior.","uniqueKey":"nodes.items.[INDEX].oneOf.4.annotation","typeLabel":"string"},"webhook_id":{"type":"string","description":"UUID of the webhook to send.","uniqueKey":"nodes.items.[INDEX].oneOf.4.webhook_id","typeLabel":"string"}},"uniqueKey":"nodes.items.[INDEX].oneOf.4","typeLabel":"object"},{"type":"object","description":"A journey node. The `kind` field selects the shape. Branching nodes (`split_range`, `yes_no`, `wait_until`) nest their sub-graphs inline via `branches[].nodes`.","required":["kind"],"properties":{"kind":{"type":"string","const":"tag","description":"Assigns key-value tags to the user.","isRequired":true,"uniqueKey":"nodes.items.[INDEX].oneOf.5.kind","typeLabel":"string"},"id":{"type":"string","description":"Server-assigned node UUID. Read-only. Returned on reads; sending it on create is rejected with a `400` validation error.","uniqueKey":"nodes.items.[INDEX].oneOf.5.id","typeLabel":"string"},"client_node_id":{"type":"string","description":"Optional client-assigned identifier, unique within the journey. Use it to reference this node from elsewhere in the same request (for example as `client_node_id` on an `on_notification_action` condition). Persisted and returned on reads.","uniqueKey":"nodes.items.[INDEX].oneOf.5.client_node_id","typeLabel":"string"},"annotation":{"type":"string","description":"Optional free-text label, up to 1024 characters. Stored and returned as-is with no effect on journey behavior.","uniqueKey":"nodes.items.[INDEX].oneOf.5.annotation","typeLabel":"string"},"assignments":{"type":"object","additionalProperties":{"type":"string","uniqueKey":"nodes.items.[INDEX].oneOf.5.assignments.additionalProperties","typeLabel":"string"},"description":"Tag key-value pairs to assign. An empty string value removes the tag. Keys are limited to 255 characters and values to 1024.","uniqueKey":"nodes.items.[INDEX].oneOf.5.assignments","typeLabel":"object"}},"uniqueKey":"nodes.items.[INDEX].oneOf.5","typeLabel":"object"},{"type":"object","description":"A journey node. The `kind` field selects the shape. Branching nodes (`split_range`, `yes_no`, `wait_until`) nest their sub-graphs inline via `branches[].nodes`.","required":["kind"],"properties":{"kind":{"type":"string","const":"split_range","description":"Routes users into weighted branches that converge to the next sibling node.","isRequired":true,"uniqueKey":"nodes.items.[INDEX].oneOf.6.kind","typeLabel":"string"},"id":{"type":"string","description":"Server-assigned node UUID. Read-only. Returned on reads; sending it on create is rejected with a `400` validation error.","uniqueKey":"nodes.items.[INDEX].oneOf.6.id","typeLabel":"string"},"client_node_id":{"type":"string","description":"Optional client-assigned identifier, unique within the journey. Use it to reference this node from elsewhere in the same request (for example as `client_node_id` on an `on_notification_action` condition). Persisted and returned on reads.","uniqueKey":"nodes.items.[INDEX].oneOf.6.client_node_id","typeLabel":"string"},"annotation":{"type":"string","description":"Optional free-text label, up to 1024 characters. Stored and returned as-is with no effect on journey behavior.","uniqueKey":"nodes.items.[INDEX].oneOf.6.annotation","typeLabel":"string"},"randomize_on_entry":{"type":"boolean","description":"When true, assigns each user to a branch at random on entry. Defaults to false.","uniqueKey":"nodes.items.[INDEX].oneOf.6.randomize_on_entry","typeLabel":"boolean"},"branches":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","description":"Server-assigned branch identifier. Read-only.","uniqueKey":"nodes.items.[INDEX].oneOf.6.branches.items.[INDEX].id","typeLabel":"string"},"condition":{"oneOf":[{"type":"object","title":"segment_membership","description":"A branch condition. The `kind` field selects the shape.","required":["kind"],"properties":{"kind":{"type":"string","const":"segment_membership","isRequired":true,"uniqueKey":"nodes.items.[INDEX].oneOf.6.branches.items.[INDEX].condition.oneOf.0.kind","typeLabel":"string"},"included_segment_ids":{"type":"array","items":{"type":"string","uniqueKey":"nodes.items.[INDEX].oneOf.6.branches.items.[INDEX].condition.oneOf.0.included_segment_ids.items.[INDEX]","typeLabel":"string"},"description":"Segment UUIDs the user must belong to.","uniqueKey":"nodes.items.[INDEX].oneOf.6.branches.items.[INDEX].condition.oneOf.0.included_segment_ids","typeLabel":"string[]"},"excluded_segment_ids":{"type":"array","items":{"type":"string","uniqueKey":"nodes.items.[INDEX].oneOf.6.branches.items.[INDEX].condition.oneOf.0.excluded_segment_ids.items.[INDEX]","typeLabel":"string"},"description":"Segment UUIDs the user must not belong to.","uniqueKey":"nodes.items.[INDEX].oneOf.6.branches.items.[INDEX].condition.oneOf.0.excluded_segment_ids","typeLabel":"string[]"}},"uniqueKey":"nodes.items.[INDEX].oneOf.6.branches.items.[INDEX].condition.oneOf.0","typeLabel":"segment_membership · object"},{"type":"object","title":"on_notification_action","description":"A branch condition. The `kind` field selects the shape.","required":["kind"],"properties":{"kind":{"type":"string","const":"on_notification_action","isRequired":true,"uniqueKey":"nodes.items.[INDEX].oneOf.6.branches.items.[INDEX].condition.oneOf.1.kind","typeLabel":"string"},"action":{"type":"string","enum":["received","clicked","opened"],"description":"The notification action to branch on. Which actions apply depends on the sending node's channel.","uniqueKey":"nodes.items.[INDEX].oneOf.6.branches.items.[INDEX].condition.oneOf.1.action","typeLabel":"enum\u003cstring>"},"sending_node_id":{"type":"string","description":"`id` of the sending node this action refers to. Returned on reads; accepted on write.","uniqueKey":"nodes.items.[INDEX].oneOf.6.branches.items.[INDEX].condition.oneOf.1.sending_node_id","typeLabel":"string"},"client_node_id":{"type":"string","description":"Write-only alternative to `sending_node_id`. References the sending node by its `client_node_id`, which is resolved to that node's `id`.","uniqueKey":"nodes.items.[INDEX].oneOf.6.branches.items.[INDEX].condition.oneOf.1.client_node_id","typeLabel":"string"}},"uniqueKey":"nodes.items.[INDEX].oneOf.6.branches.items.[INDEX].condition.oneOf.1","typeLabel":"on_notification_action · object"},{"type":"object","title":"event_trigger","description":"A branch condition. The `kind` field selects the shape.","required":["kind"],"properties":{"kind":{"type":"string","const":"event_trigger","isRequired":true,"uniqueKey":"nodes.items.[INDEX].oneOf.6.branches.items.[INDEX].condition.oneOf.2.kind","typeLabel":"string"},"name":{"type":"string","description":"Event name, up to 255 characters.","uniqueKey":"nodes.items.[INDEX].oneOf.6.branches.items.[INDEX].condition.oneOf.2.name","typeLabel":"string"},"attributes":{"type":"array","description":"Event attribute matchers, as a list of condition groups. Send a single group whose conditions are AND'd together. More than one group is rejected.","items":{"type":"array","items":{"type":"object","required":["key","operator"],"properties":{"key":{"type":"string","description":"Event attribute key.","isRequired":true,"uniqueKey":"nodes.items.[INDEX].oneOf.6.branches.items.[INDEX].condition.oneOf.2.attributes.items.[INDEX].items.[INDEX].key","typeLabel":"string"},"operator":{"type":"string","enum":["equal","not_equal","less","less_or_equal","greater_or_equal","greater","is","is_not","exists","not_exists","before","after"],"description":"Comparison operator.","isRequired":true,"uniqueKey":"nodes.items.[INDEX].oneOf.6.branches.items.[INDEX].condition.oneOf.2.attributes.items.[INDEX].items.[INDEX].operator","typeLabel":"enum\u003cstring>"},"value":{"type":"string","description":"Value to compare against. Not required for `exists` and `not_exists`.","uniqueKey":"nodes.items.[INDEX].oneOf.6.branches.items.[INDEX].condition.oneOf.2.attributes.items.[INDEX].items.[INDEX].value","typeLabel":"string"}},"uniqueKey":"nodes.items.[INDEX].oneOf.6.branches.items.[INDEX].condition.oneOf.2.attributes.items.[INDEX].items.[INDEX]","typeLabel":"object"},"uniqueKey":"nodes.items.[INDEX].oneOf.6.branches.items.[INDEX].condition.oneOf.2.attributes.items.[INDEX]","typeLabel":"object[]"},"uniqueKey":"nodes.items.[INDEX].oneOf.6.branches.items.[INDEX].condition.oneOf.2.attributes","typeLabel":"object[][]"},"entry_event_match_attributes":{"oneOf":[{"type":"array","items":{"type":"object","uniqueKey":"nodes.items.[INDEX].oneOf.6.branches.items.[INDEX].condition.oneOf.2.entry_event_match_attributes.oneOf.0.items.[INDEX]","typeLabel":"object"},"description":"Match incoming event properties against the journey's entry event. Only valid on event-triggered journeys.","uniqueKey":"nodes.items.[INDEX].oneOf.6.branches.items.[INDEX].condition.oneOf.2.entry_event_match_attributes.oneOf.0","typeLabel":"object[]"},{"type":"null","items":{"type":"object"},"description":"Match incoming event properties against the journey's entry event. Only valid on event-triggered journeys.","uniqueKey":"nodes.items.[INDEX].oneOf.6.branches.items.[INDEX].condition.oneOf.2.entry_event_match_attributes.oneOf.1","typeLabel":"null"}],"uniqueKey":"nodes.items.[INDEX].oneOf.6.branches.items.[INDEX].condition.oneOf.2.entry_event_match_attributes","typeLabel":"object[] | null"}},"uniqueKey":"nodes.items.[INDEX].oneOf.6.branches.items.[INDEX].condition.oneOf.2","typeLabel":"event_trigger · object"}],"uniqueKey":"nodes.items.[INDEX].oneOf.6.branches.items.[INDEX].condition","typeLabel":"segment_membership · object | on_notification_action · object | event_trigger · object"},"weight":{"type":"number","description":"Branch weight for `split_range` nodes. Weights across a node's branches must sum to 100.","uniqueKey":"nodes.items.[INDEX].oneOf.6.branches.items.[INDEX].weight","typeLabel":"number"},"nodes":{"type":"array","items":{"$circularRef":"f6795843-f004-4026-9a86-d14c359fdee3"},"description":"Nodes run when this branch is taken, before flow converges to the next sibling node.","uniqueKey":"nodes.items.[INDEX].oneOf.6.branches.items.[INDEX].nodes","typeLabel":"array"}},"uniqueKey":"nodes.items.[INDEX].oneOf.6.branches.items.[INDEX]","typeLabel":"object"},"description":"Weighted branches. Between 2 and 25. Weights must sum to 100. Order determines display order.","minItems":2,"maxItems":25,"uniqueKey":"nodes.items.[INDEX].oneOf.6.branches","typeLabel":"object[]"}},"uniqueKey":"nodes.items.[INDEX].oneOf.6","typeLabel":"object"},{"type":"object","description":"A journey node. The `kind` field selects the shape. Branching nodes (`split_range`, `yes_no`, `wait_until`) nest their sub-graphs inline via `branches[].nodes`.","required":["kind"],"properties":{"kind":{"type":"string","const":"yes_no","description":"Routes users into a yes or no branch based on a condition.","isRequired":true,"uniqueKey":"nodes.items.[INDEX].oneOf.7.kind","typeLabel":"string"},"id":{"type":"string","description":"Server-assigned node UUID. Read-only. Returned on reads; sending it on create is rejected with a `400` validation error.","uniqueKey":"nodes.items.[INDEX].oneOf.7.id","typeLabel":"string"},"client_node_id":{"type":"string","description":"Optional client-assigned identifier, unique within the journey. Use it to reference this node from elsewhere in the same request (for example as `client_node_id` on an `on_notification_action` condition). Persisted and returned on reads.","uniqueKey":"nodes.items.[INDEX].oneOf.7.client_node_id","typeLabel":"string"},"annotation":{"type":"string","description":"Optional free-text label, up to 1024 characters. Stored and returned as-is with no effect on journey behavior.","uniqueKey":"nodes.items.[INDEX].oneOf.7.annotation","typeLabel":"string"},"branches":{"type":"array","minItems":2,"maxItems":2,"items":{"type":"object","properties":{"id":{"type":"string","description":"Server-assigned branch identifier. Read-only.","uniqueKey":"nodes.items.[INDEX].oneOf.7.branches.items.[INDEX].id","typeLabel":"string"},"condition":{"oneOf":[{"type":"object","title":"segment_membership","description":"A branch condition. The `kind` field selects the shape.","required":["kind"],"properties":{"kind":{"type":"string","const":"segment_membership","isRequired":true,"uniqueKey":"nodes.items.[INDEX].oneOf.7.branches.items.[INDEX].condition.oneOf.0.kind","typeLabel":"string"},"included_segment_ids":{"type":"array","items":{"type":"string","uniqueKey":"nodes.items.[INDEX].oneOf.7.branches.items.[INDEX].condition.oneOf.0.included_segment_ids.items.[INDEX]","typeLabel":"string"},"description":"Segment UUIDs the user must belong to.","uniqueKey":"nodes.items.[INDEX].oneOf.7.branches.items.[INDEX].condition.oneOf.0.included_segment_ids","typeLabel":"string[]"},"excluded_segment_ids":{"type":"array","items":{"type":"string","uniqueKey":"nodes.items.[INDEX].oneOf.7.branches.items.[INDEX].condition.oneOf.0.excluded_segment_ids.items.[INDEX]","typeLabel":"string"},"description":"Segment UUIDs the user must not belong to.","uniqueKey":"nodes.items.[INDEX].oneOf.7.branches.items.[INDEX].condition.oneOf.0.excluded_segment_ids","typeLabel":"string[]"}},"uniqueKey":"nodes.items.[INDEX].oneOf.7.branches.items.[INDEX].condition.oneOf.0","typeLabel":"segment_membership · object"},{"type":"object","title":"on_notification_action","description":"A branch condition. The `kind` field selects the shape.","required":["kind"],"properties":{"kind":{"type":"string","const":"on_notification_action","isRequired":true,"uniqueKey":"nodes.items.[INDEX].oneOf.7.branches.items.[INDEX].condition.oneOf.1.kind","typeLabel":"string"},"action":{"type":"string","enum":["received","clicked","opened"],"description":"The notification action to branch on. Which actions apply depends on the sending node's channel.","uniqueKey":"nodes.items.[INDEX].oneOf.7.branches.items.[INDEX].condition.oneOf.1.action","typeLabel":"enum\u003cstring>"},"sending_node_id":{"type":"string","description":"`id` of the sending node this action refers to. Returned on reads; accepted on write.","uniqueKey":"nodes.items.[INDEX].oneOf.7.branches.items.[INDEX].condition.oneOf.1.sending_node_id","typeLabel":"string"},"client_node_id":{"type":"string","description":"Write-only alternative to `sending_node_id`. References the sending node by its `client_node_id`, which is resolved to that node's `id`.","uniqueKey":"nodes.items.[INDEX].oneOf.7.branches.items.[INDEX].condition.oneOf.1.client_node_id","typeLabel":"string"}},"uniqueKey":"nodes.items.[INDEX].oneOf.7.branches.items.[INDEX].condition.oneOf.1","typeLabel":"on_notification_action · object"},{"type":"object","title":"event_trigger","description":"A branch condition. The `kind` field selects the shape.","required":["kind"],"properties":{"kind":{"type":"string","const":"event_trigger","isRequired":true,"uniqueKey":"nodes.items.[INDEX].oneOf.7.branches.items.[INDEX].condition.oneOf.2.kind","typeLabel":"string"},"name":{"type":"string","description":"Event name, up to 255 characters.","uniqueKey":"nodes.items.[INDEX].oneOf.7.branches.items.[INDEX].condition.oneOf.2.name","typeLabel":"string"},"attributes":{"type":"array","description":"Event attribute matchers, as a list of condition groups. Send a single group whose conditions are AND'd together. More than one group is rejected.","items":{"type":"array","items":{"type":"object","required":["key","operator"],"properties":{"key":{"type":"string","description":"Event attribute key.","isRequired":true,"uniqueKey":"nodes.items.[INDEX].oneOf.7.branches.items.[INDEX].condition.oneOf.2.attributes.items.[INDEX].items.[INDEX].key","typeLabel":"string"},"operator":{"type":"string","enum":["equal","not_equal","less","less_or_equal","greater_or_equal","greater","is","is_not","exists","not_exists","before","after"],"description":"Comparison operator.","isRequired":true,"uniqueKey":"nodes.items.[INDEX].oneOf.7.branches.items.[INDEX].condition.oneOf.2.attributes.items.[INDEX].items.[INDEX].operator","typeLabel":"enum\u003cstring>"},"value":{"type":"string","description":"Value to compare against. Not required for `exists` and `not_exists`.","uniqueKey":"nodes.items.[INDEX].oneOf.7.branches.items.[INDEX].condition.oneOf.2.attributes.items.[INDEX].items.[INDEX].value","typeLabel":"string"}},"uniqueKey":"nodes.items.[INDEX].oneOf.7.branches.items.[INDEX].condition.oneOf.2.attributes.items.[INDEX].items.[INDEX]","typeLabel":"object"},"uniqueKey":"nodes.items.[INDEX].oneOf.7.branches.items.[INDEX].condition.oneOf.2.attributes.items.[INDEX]","typeLabel":"object[]"},"uniqueKey":"nodes.items.[INDEX].oneOf.7.branches.items.[INDEX].condition.oneOf.2.attributes","typeLabel":"object[][]"},"entry_event_match_attributes":{"oneOf":[{"type":"array","items":{"type":"object","uniqueKey":"nodes.items.[INDEX].oneOf.7.branches.items.[INDEX].condition.oneOf.2.entry_event_match_attributes.oneOf.0.items.[INDEX]","typeLabel":"object"},"description":"Match incoming event properties against the journey's entry event. Only valid on event-triggered journeys.","uniqueKey":"nodes.items.[INDEX].oneOf.7.branches.items.[INDEX].condition.oneOf.2.entry_event_match_attributes.oneOf.0","typeLabel":"object[]"},{"type":"null","items":{"type":"object"},"description":"Match incoming event properties against the journey's entry event. Only valid on event-triggered journeys.","uniqueKey":"nodes.items.[INDEX].oneOf.7.branches.items.[INDEX].condition.oneOf.2.entry_event_match_attributes.oneOf.1","typeLabel":"null"}],"uniqueKey":"nodes.items.[INDEX].oneOf.7.branches.items.[INDEX].condition.oneOf.2.entry_event_match_attributes","typeLabel":"object[] | null"}},"uniqueKey":"nodes.items.[INDEX].oneOf.7.branches.items.[INDEX].condition.oneOf.2","typeLabel":"event_trigger · object"}],"uniqueKey":"nodes.items.[INDEX].oneOf.7.branches.items.[INDEX].condition","typeLabel":"segment_membership · object | on_notification_action · object | event_trigger · object"},"weight":{"type":"number","description":"Branch weight for `split_range` nodes. Weights across a node's branches must sum to 100.","uniqueKey":"nodes.items.[INDEX].oneOf.7.branches.items.[INDEX].weight","typeLabel":"number"},"nodes":{"type":"array","items":{"$circularRef":"f6795843-f004-4026-9a86-d14c359fdee3"},"description":"Nodes run when this branch is taken, before flow converges to the next sibling node.","uniqueKey":"nodes.items.[INDEX].oneOf.7.branches.items.[INDEX].nodes","typeLabel":"array"}},"uniqueKey":"nodes.items.[INDEX].oneOf.7.branches.items.[INDEX]","typeLabel":"object"},"description":"Exactly two branches. The branch with a `condition` is the \"yes\" branch; the branch without one is the \"no\" branch.","uniqueKey":"nodes.items.[INDEX].oneOf.7.branches","typeLabel":"object[]"}},"uniqueKey":"nodes.items.[INDEX].oneOf.7","typeLabel":"object"},{"type":"object","description":"A journey node. The `kind` field selects the shape. Branching nodes (`split_range`, `yes_no`, `wait_until`) nest their sub-graphs inline via `branches[].nodes`.","required":["kind"],"properties":{"kind":{"type":"string","const":"wait_until","description":"Holds the user until any branch condition is met, or an optional expiration timer fires.","isRequired":true,"uniqueKey":"nodes.items.[INDEX].oneOf.8.kind","typeLabel":"string"},"id":{"type":"string","description":"Server-assigned node UUID. Read-only. Returned on reads; sending it on create is rejected with a `400` validation error.","uniqueKey":"nodes.items.[INDEX].oneOf.8.id","typeLabel":"string"},"client_node_id":{"type":"string","description":"Optional client-assigned identifier, unique within the journey. Use it to reference this node from elsewhere in the same request (for example as `client_node_id` on an `on_notification_action` condition). Persisted and returned on reads.","uniqueKey":"nodes.items.[INDEX].oneOf.8.client_node_id","typeLabel":"string"},"annotation":{"type":"string","description":"Optional free-text label, up to 1024 characters. Stored and returned as-is with no effect on journey behavior.","uniqueKey":"nodes.items.[INDEX].oneOf.8.annotation","typeLabel":"string"},"branches":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","description":"Server-assigned branch identifier. Read-only.","uniqueKey":"nodes.items.[INDEX].oneOf.8.branches.items.[INDEX].id","typeLabel":"string"},"condition":{"oneOf":[{"type":"object","title":"segment_membership","description":"A branch condition. The `kind` field selects the shape.","required":["kind"],"properties":{"kind":{"type":"string","const":"segment_membership","isRequired":true,"uniqueKey":"nodes.items.[INDEX].oneOf.8.branches.items.[INDEX].condition.oneOf.0.kind","typeLabel":"string"},"included_segment_ids":{"type":"array","items":{"type":"string","uniqueKey":"nodes.items.[INDEX].oneOf.8.branches.items.[INDEX].condition.oneOf.0.included_segment_ids.items.[INDEX]","typeLabel":"string"},"description":"Segment UUIDs the user must belong to.","uniqueKey":"nodes.items.[INDEX].oneOf.8.branches.items.[INDEX].condition.oneOf.0.included_segment_ids","typeLabel":"string[]"},"excluded_segment_ids":{"type":"array","items":{"type":"string","uniqueKey":"nodes.items.[INDEX].oneOf.8.branches.items.[INDEX].condition.oneOf.0.excluded_segment_ids.items.[INDEX]","typeLabel":"string"},"description":"Segment UUIDs the user must not belong to.","uniqueKey":"nodes.items.[INDEX].oneOf.8.branches.items.[INDEX].condition.oneOf.0.excluded_segment_ids","typeLabel":"string[]"}},"uniqueKey":"nodes.items.[INDEX].oneOf.8.branches.items.[INDEX].condition.oneOf.0","typeLabel":"segment_membership · object"},{"type":"object","title":"on_notification_action","description":"A branch condition. The `kind` field selects the shape.","required":["kind"],"properties":{"kind":{"type":"string","const":"on_notification_action","isRequired":true,"uniqueKey":"nodes.items.[INDEX].oneOf.8.branches.items.[INDEX].condition.oneOf.1.kind","typeLabel":"string"},"action":{"type":"string","enum":["received","clicked","opened"],"description":"The notification action to branch on. Which actions apply depends on the sending node's channel.","uniqueKey":"nodes.items.[INDEX].oneOf.8.branches.items.[INDEX].condition.oneOf.1.action","typeLabel":"enum\u003cstring>"},"sending_node_id":{"type":"string","description":"`id` of the sending node this action refers to. Returned on reads; accepted on write.","uniqueKey":"nodes.items.[INDEX].oneOf.8.branches.items.[INDEX].condition.oneOf.1.sending_node_id","typeLabel":"string"},"client_node_id":{"type":"string","description":"Write-only alternative to `sending_node_id`. References the sending node by its `client_node_id`, which is resolved to that node's `id`.","uniqueKey":"nodes.items.[INDEX].oneOf.8.branches.items.[INDEX].condition.oneOf.1.client_node_id","typeLabel":"string"}},"uniqueKey":"nodes.items.[INDEX].oneOf.8.branches.items.[INDEX].condition.oneOf.1","typeLabel":"on_notification_action · object"},{"type":"object","title":"event_trigger","description":"A branch condition. The `kind` field selects the shape.","required":["kind"],"properties":{"kind":{"type":"string","const":"event_trigger","isRequired":true,"uniqueKey":"nodes.items.[INDEX].oneOf.8.branches.items.[INDEX].condition.oneOf.2.kind","typeLabel":"string"},"name":{"type":"string","description":"Event name, up to 255 characters.","uniqueKey":"nodes.items.[INDEX].oneOf.8.branches.items.[INDEX].condition.oneOf.2.name","typeLabel":"string"},"attributes":{"type":"array","description":"Event attribute matchers, as a list of condition groups. Send a single group whose conditions are AND'd together. More than one group is rejected.","items":{"type":"array","items":{"type":"object","required":["key","operator"],"properties":{"key":{"type":"string","description":"Event attribute key.","isRequired":true,"uniqueKey":"nodes.items.[INDEX].oneOf.8.branches.items.[INDEX].condition.oneOf.2.attributes.items.[INDEX].items.[INDEX].key","typeLabel":"string"},"operator":{"type":"string","enum":["equal","not_equal","less","less_or_equal","greater_or_equal","greater","is","is_not","exists","not_exists","before","after"],"description":"Comparison operator.","isRequired":true,"uniqueKey":"nodes.items.[INDEX].oneOf.8.branches.items.[INDEX].condition.oneOf.2.attributes.items.[INDEX].items.[INDEX].operator","typeLabel":"enum\u003cstring>"},"value":{"type":"string","description":"Value to compare against. Not required for `exists` and `not_exists`.","uniqueKey":"nodes.items.[INDEX].oneOf.8.branches.items.[INDEX].condition.oneOf.2.attributes.items.[INDEX].items.[INDEX].value","typeLabel":"string"}},"uniqueKey":"nodes.items.[INDEX].oneOf.8.branches.items.[INDEX].condition.oneOf.2.attributes.items.[INDEX].items.[INDEX]","typeLabel":"object"},"uniqueKey":"nodes.items.[INDEX].oneOf.8.branches.items.[INDEX].condition.oneOf.2.attributes.items.[INDEX]","typeLabel":"object[]"},"uniqueKey":"nodes.items.[INDEX].oneOf.8.branches.items.[INDEX].condition.oneOf.2.attributes","typeLabel":"object[][]"},"entry_event_match_attributes":{"oneOf":[{"type":"array","items":{"type":"object","uniqueKey":"nodes.items.[INDEX].oneOf.8.branches.items.[INDEX].condition.oneOf.2.entry_event_match_attributes.oneOf.0.items.[INDEX]","typeLabel":"object"},"description":"Match incoming event properties against the journey's entry event. Only valid on event-triggered journeys.","uniqueKey":"nodes.items.[INDEX].oneOf.8.branches.items.[INDEX].condition.oneOf.2.entry_event_match_attributes.oneOf.0","typeLabel":"object[]"},{"type":"null","items":{"type":"object"},"description":"Match incoming event properties against the journey's entry event. Only valid on event-triggered journeys.","uniqueKey":"nodes.items.[INDEX].oneOf.8.branches.items.[INDEX].condition.oneOf.2.entry_event_match_attributes.oneOf.1","typeLabel":"null"}],"uniqueKey":"nodes.items.[INDEX].oneOf.8.branches.items.[INDEX].condition.oneOf.2.entry_event_match_attributes","typeLabel":"object[] | null"}},"uniqueKey":"nodes.items.[INDEX].oneOf.8.branches.items.[INDEX].condition.oneOf.2","typeLabel":"event_trigger · object"}],"uniqueKey":"nodes.items.[INDEX].oneOf.8.branches.items.[INDEX].condition","typeLabel":"segment_membership · object | on_notification_action · object | event_trigger · object"},"weight":{"type":"number","description":"Branch weight for `split_range` nodes. Weights across a node's branches must sum to 100.","uniqueKey":"nodes.items.[INDEX].oneOf.8.branches.items.[INDEX].weight","typeLabel":"number"},"nodes":{"type":"array","items":{"$circularRef":"f6795843-f004-4026-9a86-d14c359fdee3"},"description":"Nodes run when this branch is taken, before flow converges to the next sibling node.","uniqueKey":"nodes.items.[INDEX].oneOf.8.branches.items.[INDEX].nodes","typeLabel":"array"}},"uniqueKey":"nodes.items.[INDEX].oneOf.8.branches.items.[INDEX]","typeLabel":"object"},"description":"Condition branches. At least one required, at most 25. Order determines priority.","minItems":1,"maxItems":25,"uniqueKey":"nodes.items.[INDEX].oneOf.8.branches","typeLabel":"object[]"},"expiration":{"oneOf":[{"type":"object","properties":{"duration_seconds":{"type":"integer","minimum":60,"description":"Seconds to wait before the timer fires. Minimum `60`, maximum `31556952` (1 year).","maximum":31556952,"uniqueKey":"nodes.items.[INDEX].oneOf.8.expiration.oneOf.0.duration_seconds","typeLabel":"integer"},"exits":{"type":"boolean","description":"When true, the user exits the journey when the timer fires; when false, the user continues to convergence.","uniqueKey":"nodes.items.[INDEX].oneOf.8.expiration.oneOf.0.exits","typeLabel":"boolean"}},"description":"Optional expiration timer. `null` waits indefinitely.","uniqueKey":"nodes.items.[INDEX].oneOf.8.expiration.oneOf.0","typeLabel":"object"},{"type":"null","properties":{"duration_seconds":{"type":"integer","minimum":60,"description":"Seconds to wait before the timer fires. Minimum `60`, maximum `31556952` (1 year).","maximum":31556952},"exits":{"type":"boolean","description":"When true, the user exits the journey when the timer fires; when false, the user continues to convergence."}},"description":"Optional expiration timer. `null` waits indefinitely.","uniqueKey":"nodes.items.[INDEX].oneOf.8.expiration.oneOf.1","typeLabel":"null"}],"uniqueKey":"nodes.items.[INDEX].oneOf.8.expiration","typeLabel":"object | null"}},"uniqueKey":"nodes.items.[INDEX].oneOf.8","typeLabel":"object"}],"uniqueKey":"nodes.items.[INDEX]","typeLabel":"object"},"description":"Ordered list of journey nodes.","uniqueKey":"nodes","typeLabel":"object[]"},"concurrency_key":{"type":"string","description":"Opaque optimistic-concurrency token. Read-only. Pass it back on update to guard against overwriting a concurrent change (`409 journey-stale`). Send it back exactly as read from this response; do not construct or parse it.","uniqueKey":"concurrency_key","typeLabel":"string"}},"uniqueKey":"","typeLabel":"object"},"examples":{"Result":{"title":"Result","value":{"id":"0a1b2c3d-4e5f-6071-8293-a4b5c6d7e8f9","app_id":"1a2b3c4d-5e6f-7081-92a3-b4c5d6e7f809","name":"Welcome series","description":"Onboard new users over their first week.","state":"draft","created_at":"2026-06-01T14:00:00Z","updated_at":"2026-06-01T14:00:00Z","started_at":null,"archived_at":null,"created_source":"public_api","audience":{"kind":"segment","included_segment_ids":["3f7c1e90-0000-0000-0000-000000000001"],"excluded_segment_ids":[],"future_additions_only":false},"early_exit":null,"reentry_rules":null,"schedule":null,"nodes":[{"id":"11111111-0000-0000-0000-000000000001","kind":"send_push","template_id":"9a8b7c6d-0000-0000-0000-000000000001"},{"id":"11111111-0000-0000-0000-000000000002","kind":"wait","duration_seconds":86400},{"id":"11111111-0000-0000-0000-000000000003","kind":"send_email","template_id":"9a8b7c6d-0000-0000-0000-000000000002"}],"concurrency_key":"dcae4794fee16e450e448e37a6f8d0a5a7335755ff8cc76606e3d04b2f574e46"}}},"exampleType":"examples"}},"exampleType":"examples"},"81df480a-989b-4d8b-b31a-13162645e931":{"description":"400","content":{"application/json":{"schema":{"type":"object","description":"Validation error response. Uses the same `code`/`title`/`meta` shape as every other error; the failing field and any positional detail travel in `meta`.","properties":{"errors":{"type":"array","items":{"type":"object","properties":{"code":{"type":"string","description":"Stable, kebab-case error identifier. Always `invalid-payload` for validation failures.","uniqueKey":"errors.items.[INDEX].code","typeLabel":"string"},"title":{"type":"string","description":"Human-readable message. Wording may change between releases.","uniqueKey":"errors.items.[INDEX].title","typeLabel":"string"},"meta":{"type":"object","description":"Structured context. Always includes `attribute` (the field, or `base` for request-level errors); may also include `path`, `node_id`, or `client_node_id`.","uniqueKey":"errors.items.[INDEX].meta","typeLabel":"object"}},"uniqueKey":"errors.items.[INDEX]","typeLabel":"object"},"uniqueKey":"errors","typeLabel":"object[]"}},"uniqueKey":"","typeLabel":"object"},"example":{"errors":[{"code":"invalid-payload","title":"did not contain a required property of 'name'","meta":{"attribute":"base","path":"name"}}]},"examples":{"Example":{"title":"Example","value":{"errors":[{"code":"invalid-payload","title":"did not contain a required property of 'name'","meta":{"attribute":"base","path":"name"}}]}}},"exampleType":"examples"}},"exampleType":"examples"},"16cad19f-e045-4882-a9bc-b0ad8f639d30":{"description":"403","content":{"application/json":{"schema":{"type":"object","description":"Error response with a stable machine-readable `code`.","properties":{"errors":{"type":"array","items":{"type":"object","properties":{"code":{"type":"string","description":"Stable, kebab-case error identifier. Does not change once shipped.","uniqueKey":"errors.items.[INDEX].code","typeLabel":"string"},"title":{"type":"string","description":"Human-readable message. Wording may change between releases.","uniqueKey":"errors.items.[INDEX].title","typeLabel":"string"},"meta":{"type":"object","description":"Optional structured context. Shape varies by error.","uniqueKey":"errors.items.[INDEX].meta","typeLabel":"object"}},"uniqueKey":"errors.items.[INDEX]","typeLabel":"object"},"uniqueKey":"errors","typeLabel":"object[]"}},"uniqueKey":"","typeLabel":"object"},"example":{"errors":[{"code":"journey-not-entitled","title":"Journeys are not enabled for this app","meta":{}}]},"examples":{"Example":{"title":"Example","value":{"errors":[{"code":"journey-not-entitled","title":"Journeys are not enabled for this app","meta":{}}]}}},"exampleType":"examples"}},"exampleType":"examples"},"446b3725-ced3-417c-8945-567ec9f2bd3b":{"description":"Rate limit exceeded. Wait the number of seconds in the `Retry-After` header before retrying.","headers":{"Retry-After":{"description":"Number of seconds to wait before retrying the request. Always emitted on 429 responses.","schema":{"type":"integer","minimum":0}}},"content":{"application/json":{"schema":{"type":"object","properties":{"errors":{"type":"array","items":{"type":"string","uniqueKey":"errors.items.[INDEX]","typeLabel":"string"},"description":"One or more human-readable error messages.","uniqueKey":"errors","typeLabel":"string[]"},"success":{"type":"boolean","description":"Present (and `false`) on some endpoints (notifications, templates, segments). Not emitted by every endpoint.","uniqueKey":"success","typeLabel":"boolean"},"reference":{"type":"array","items":{"type":"string","uniqueKey":"reference.items.[INDEX]","typeLabel":"string"},"description":"Documentation URL fragments related to the error. Only emitted by the API-key auth error helpers.","uniqueKey":"reference","typeLabel":"string[]"}},"uniqueKey":"","typeLabel":"object"},"example":{"errors":["API rate limit exceeded."]},"examples":{"Example":{"title":"Example","value":{"errors":["API rate limit exceeded."]}}},"exampleType":"examples"}},"exampleType":"examples"}},"security":{"a15236e2-20f7-4712-b1c5-1a2812fdcec4":{}},"servers":{"409091ad-6d30-4df4-9e86-f2a13d67c7b3":{"url":"https://api.onesignal.com"}},"schemas":{"f6795843-f004-4026-9a86-d14c359fdee3":{"oneOf":[{"type":"object","description":"A journey node. The `kind` field selects the shape. Branching nodes (`split_range`, `yes_no`, `wait_until`) nest their sub-graphs inline via `branches[].nodes`.","required":["kind"],"properties":{"kind":{"type":"string","const":"wait","description":"Holds the user for a fixed duration before continuing.","isRequired":true},"id":{"type":"string","description":"Server-assigned node UUID. Read-only. Returned on reads; sending it on create is rejected with a `400` validation error."},"client_node_id":{"type":"string","description":"Optional client-assigned identifier, unique within the journey. Use it to reference this node from elsewhere in the same request (for example as `client_node_id` on an `on_notification_action` condition). Persisted and returned on reads."},"annotation":{"type":"string","description":"Optional free-text label, up to 1024 characters. Stored and returned as-is with no effect on journey behavior."},"duration_seconds":{"type":"integer","description":"Seconds to hold the user. Minimum `60`, maximum `31556952` (1 year).","minimum":60,"maximum":31556952}}},{"type":"object","description":"A journey node. The `kind` field selects the shape. Branching nodes (`split_range`, `yes_no`, `wait_until`) nest their sub-graphs inline via `branches[].nodes`.","required":["kind"],"properties":{"kind":{"type":"string","const":"time_window","description":"Holds the user until the next configured time window opens.","isRequired":true},"id":{"type":"string","description":"Server-assigned node UUID. Read-only. Returned on reads; sending it on create is rejected with a `400` validation error."},"client_node_id":{"type":"string","description":"Optional client-assigned identifier, unique within the journey. Use it to reference this node from elsewhere in the same request (for example as `client_node_id` on an `on_notification_action` condition). Persisted and returned on reads."},"annotation":{"type":"string","description":"Optional free-text label, up to 1024 characters. Stored and returned as-is with no effect on journey behavior."},"relative_to":{"type":"string","enum":["schedule_in_timezone","last_active_time"],"description":"`schedule_in_timezone` uses the configured windows; `last_active_time` holds relative to the user's last active time."},"windows":{"type":"array","items":{"type":"object","properties":{"start":{"type":"object","description":"When the window opens.","properties":{"hour":{"type":"integer","minimum":0,"maximum":23,"description":"Hour of day, 0-23."},"minute":{"type":"integer","minimum":0,"maximum":59,"description":"Minute of hour, 0-59. Defaults to 0."}}},"end":{"type":"object","description":"When the window closes.","properties":{"hour":{"type":"integer","minimum":0,"maximum":23,"description":"Hour of day, 0-23."},"minute":{"type":"integer","minimum":0,"maximum":59,"description":"Minute of hour, 0-59. Defaults to 0."}}},"day_of_week":{"type":"integer","minimum":1,"maximum":7,"description":"Day of week, 1 = Monday. Omit to apply the window to every day."}},"description":"A wall-clock window. Each window must span at least 15 minutes."},"description":"One or more time windows. A window with no `day_of_week` applies to every day, and is returned in that same day-agnostic form. Required when `relative_to` is `schedule_in_timezone`; must be omitted when it is `last_active_time`, and is absent from responses for those nodes."},"time_zone":{"type":"string","description":"IANA timezone identifier used when the user's timezone is unavailable."},"use_user_time_zone":{"type":"boolean","description":"When true, uses the user's timezone if available."}}},{"type":"object","description":"A journey node. The `kind` field selects the shape. Branching nodes (`split_range`, `yes_no`, `wait_until`) nest their sub-graphs inline via `branches[].nodes`.","required":["kind"],"properties":{"kind":{"type":"string","enum":["send_push","send_email","send_sms"],"description":"Sends a message on the given channel using a template.","isRequired":true},"id":{"type":"string","description":"Server-assigned node UUID. Read-only. Returned on reads; sending it on create is rejected with a `400` validation error."},"client_node_id":{"type":"string","description":"Optional client-assigned identifier, unique within the journey. Use it to reference this node from elsewhere in the same request (for example as `client_node_id` on an `on_notification_action` condition). Persisted and returned on reads."},"annotation":{"type":"string","description":"Optional free-text label, up to 1024 characters. Stored and returned as-is with no effect on journey behavior."},"template_id":{"type":"string","description":"UUID of the template to send."}}},{"type":"object","description":"A journey node. The `kind` field selects the shape. Branching nodes (`split_range`, `yes_no`, `wait_until`) nest their sub-graphs inline via `branches[].nodes`.","required":["kind"],"properties":{"kind":{"type":"string","const":"send_iam","description":"Sends an in-app message.","isRequired":true},"id":{"type":"string","description":"Server-assigned node UUID. Read-only. Returned on reads; sending it on create is rejected with a `400` validation error."},"client_node_id":{"type":"string","description":"Optional client-assigned identifier, unique within the journey. Use it to reference this node from elsewhere in the same request (for example as `client_node_id` on an `on_notification_action` condition). Persisted and returned on reads."},"annotation":{"type":"string","description":"Optional free-text label, up to 1024 characters. Stored and returned as-is with no effect on journey behavior."},"iam_id":{"type":"string","description":"UUID of the in-app message to send."},"user_ttl_seconds":{"type":"integer","minimum":1,"description":"Optional time-to-live for the in-app message, in seconds."}}},{"type":"object","description":"A journey node. The `kind` field selects the shape. Branching nodes (`split_range`, `yes_no`, `wait_until`) nest their sub-graphs inline via `branches[].nodes`.","required":["kind"],"properties":{"kind":{"type":"string","const":"send_webhook","description":"Sends a webhook.","isRequired":true},"id":{"type":"string","description":"Server-assigned node UUID. Read-only. Returned on reads; sending it on create is rejected with a `400` validation error."},"client_node_id":{"type":"string","description":"Optional client-assigned identifier, unique within the journey. Use it to reference this node from elsewhere in the same request (for example as `client_node_id` on an `on_notification_action` condition). Persisted and returned on reads."},"annotation":{"type":"string","description":"Optional free-text label, up to 1024 characters. Stored and returned as-is with no effect on journey behavior."},"webhook_id":{"type":"string","description":"UUID of the webhook to send."}}},{"type":"object","description":"A journey node. The `kind` field selects the shape. Branching nodes (`split_range`, `yes_no`, `wait_until`) nest their sub-graphs inline via `branches[].nodes`.","required":["kind"],"properties":{"kind":{"type":"string","const":"tag","description":"Assigns key-value tags to the user.","isRequired":true},"id":{"type":"string","description":"Server-assigned node UUID. Read-only. Returned on reads; sending it on create is rejected with a `400` validation error."},"client_node_id":{"type":"string","description":"Optional client-assigned identifier, unique within the journey. Use it to reference this node from elsewhere in the same request (for example as `client_node_id` on an `on_notification_action` condition). Persisted and returned on reads."},"annotation":{"type":"string","description":"Optional free-text label, up to 1024 characters. Stored and returned as-is with no effect on journey behavior."},"assignments":{"type":"object","additionalProperties":{"type":"string"},"description":"Tag key-value pairs to assign. An empty string value removes the tag. Keys are limited to 255 characters and values to 1024."}}},{"type":"object","description":"A journey node. The `kind` field selects the shape. Branching nodes (`split_range`, `yes_no`, `wait_until`) nest their sub-graphs inline via `branches[].nodes`.","required":["kind"],"properties":{"kind":{"type":"string","const":"split_range","description":"Routes users into weighted branches that converge to the next sibling node.","isRequired":true},"id":{"type":"string","description":"Server-assigned node UUID. Read-only. Returned on reads; sending it on create is rejected with a `400` validation error."},"client_node_id":{"type":"string","description":"Optional client-assigned identifier, unique within the journey. Use it to reference this node from elsewhere in the same request (for example as `client_node_id` on an `on_notification_action` condition). Persisted and returned on reads."},"annotation":{"type":"string","description":"Optional free-text label, up to 1024 characters. Stored and returned as-is with no effect on journey behavior."},"randomize_on_entry":{"type":"boolean","description":"When true, assigns each user to a branch at random on entry. Defaults to false."},"branches":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","description":"Server-assigned branch identifier. Read-only."},"condition":{"oneOf":[{"type":"object","title":"segment_membership","description":"A branch condition. The `kind` field selects the shape.","required":["kind"],"properties":{"kind":{"type":"string","const":"segment_membership","isRequired":true},"included_segment_ids":{"type":"array","items":{"type":"string"},"description":"Segment UUIDs the user must belong to."},"excluded_segment_ids":{"type":"array","items":{"type":"string"},"description":"Segment UUIDs the user must not belong to."}}},{"type":"object","title":"on_notification_action","description":"A branch condition. The `kind` field selects the shape.","required":["kind"],"properties":{"kind":{"type":"string","const":"on_notification_action","isRequired":true},"action":{"type":"string","enum":["received","clicked","opened"],"description":"The notification action to branch on. Which actions apply depends on the sending node's channel."},"sending_node_id":{"type":"string","description":"`id` of the sending node this action refers to. Returned on reads; accepted on write."},"client_node_id":{"type":"string","description":"Write-only alternative to `sending_node_id`. References the sending node by its `client_node_id`, which is resolved to that node's `id`."}}},{"type":"object","title":"event_trigger","description":"A branch condition. The `kind` field selects the shape.","required":["kind"],"properties":{"kind":{"type":"string","const":"event_trigger","isRequired":true},"name":{"type":"string","description":"Event name, up to 255 characters."},"attributes":{"type":"array","description":"Event attribute matchers, as a list of condition groups. Send a single group whose conditions are AND'd together. More than one group is rejected.","items":{"type":"array","items":{"type":"object","required":["key","operator"],"properties":{"key":{"type":"string","description":"Event attribute key.","isRequired":true},"operator":{"type":"string","enum":["equal","not_equal","less","less_or_equal","greater_or_equal","greater","is","is_not","exists","not_exists","before","after"],"description":"Comparison operator.","isRequired":true},"value":{"type":"string","description":"Value to compare against. Not required for `exists` and `not_exists`."}}}}},"entry_event_match_attributes":{"oneOf":[{"type":"array","items":{"type":"object"},"description":"Match incoming event properties against the journey's entry event. Only valid on event-triggered journeys."},{"type":"null","description":"Match incoming event properties against the journey's entry event. Only valid on event-triggered journeys."}]}}}]},"weight":{"type":"number","description":"Branch weight for `split_range` nodes. Weights across a node's branches must sum to 100."},"nodes":{"type":"array","items":{"$circularRef":"f6795843-f004-4026-9a86-d14c359fdee3"},"description":"Nodes run when this branch is taken, before flow converges to the next sibling node."}}},"description":"Weighted branches. Between 2 and 25. Weights must sum to 100. Order determines display order.","minItems":2,"maxItems":25}}},{"type":"object","description":"A journey node. The `kind` field selects the shape. Branching nodes (`split_range`, `yes_no`, `wait_until`) nest their sub-graphs inline via `branches[].nodes`.","required":["kind"],"properties":{"kind":{"type":"string","const":"yes_no","description":"Routes users into a yes or no branch based on a condition.","isRequired":true},"id":{"type":"string","description":"Server-assigned node UUID. Read-only. Returned on reads; sending it on create is rejected with a `400` validation error."},"client_node_id":{"type":"string","description":"Optional client-assigned identifier, unique within the journey. Use it to reference this node from elsewhere in the same request (for example as `client_node_id` on an `on_notification_action` condition). Persisted and returned on reads."},"annotation":{"type":"string","description":"Optional free-text label, up to 1024 characters. Stored and returned as-is with no effect on journey behavior."},"branches":{"type":"array","minItems":2,"maxItems":2,"items":{"type":"object","properties":{"id":{"type":"string","description":"Server-assigned branch identifier. Read-only."},"condition":{"oneOf":[{"type":"object","title":"segment_membership","description":"A branch condition. The `kind` field selects the shape.","required":["kind"],"properties":{"kind":{"type":"string","const":"segment_membership","isRequired":true},"included_segment_ids":{"type":"array","items":{"type":"string"},"description":"Segment UUIDs the user must belong to."},"excluded_segment_ids":{"type":"array","items":{"type":"string"},"description":"Segment UUIDs the user must not belong to."}}},{"type":"object","title":"on_notification_action","description":"A branch condition. The `kind` field selects the shape.","required":["kind"],"properties":{"kind":{"type":"string","const":"on_notification_action","isRequired":true},"action":{"type":"string","enum":["received","clicked","opened"],"description":"The notification action to branch on. Which actions apply depends on the sending node's channel."},"sending_node_id":{"type":"string","description":"`id` of the sending node this action refers to. Returned on reads; accepted on write."},"client_node_id":{"type":"string","description":"Write-only alternative to `sending_node_id`. References the sending node by its `client_node_id`, which is resolved to that node's `id`."}}},{"type":"object","title":"event_trigger","description":"A branch condition. The `kind` field selects the shape.","required":["kind"],"properties":{"kind":{"type":"string","const":"event_trigger","isRequired":true},"name":{"type":"string","description":"Event name, up to 255 characters."},"attributes":{"type":"array","description":"Event attribute matchers, as a list of condition groups. Send a single group whose conditions are AND'd together. More than one group is rejected.","items":{"type":"array","items":{"type":"object","required":["key","operator"],"properties":{"key":{"type":"string","description":"Event attribute key.","isRequired":true},"operator":{"type":"string","enum":["equal","not_equal","less","less_or_equal","greater_or_equal","greater","is","is_not","exists","not_exists","before","after"],"description":"Comparison operator.","isRequired":true},"value":{"type":"string","description":"Value to compare against. Not required for `exists` and `not_exists`."}}}}},"entry_event_match_attributes":{"oneOf":[{"type":"array","items":{"type":"object"},"description":"Match incoming event properties against the journey's entry event. Only valid on event-triggered journeys."},{"type":"null","description":"Match incoming event properties against the journey's entry event. Only valid on event-triggered journeys."}]}}}]},"weight":{"type":"number","description":"Branch weight for `split_range` nodes. Weights across a node's branches must sum to 100."},"nodes":{"type":"array","items":{"$circularRef":"f6795843-f004-4026-9a86-d14c359fdee3"},"description":"Nodes run when this branch is taken, before flow converges to the next sibling node."}}},"description":"Exactly two branches. The branch with a `condition` is the \"yes\" branch; the branch without one is the \"no\" branch."}}},{"type":"object","description":"A journey node. The `kind` field selects the shape. Branching nodes (`split_range`, `yes_no`, `wait_until`) nest their sub-graphs inline via `branches[].nodes`.","required":["kind"],"properties":{"kind":{"type":"string","const":"wait_until","description":"Holds the user until any branch condition is met, or an optional expiration timer fires.","isRequired":true},"id":{"type":"string","description":"Server-assigned node UUID. Read-only. Returned on reads; sending it on create is rejected with a `400` validation error."},"client_node_id":{"type":"string","description":"Optional client-assigned identifier, unique within the journey. Use it to reference this node from elsewhere in the same request (for example as `client_node_id` on an `on_notification_action` condition). Persisted and returned on reads."},"annotation":{"type":"string","description":"Optional free-text label, up to 1024 characters. Stored and returned as-is with no effect on journey behavior."},"branches":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","description":"Server-assigned branch identifier. Read-only."},"condition":{"oneOf":[{"type":"object","title":"segment_membership","description":"A branch condition. The `kind` field selects the shape.","required":["kind"],"properties":{"kind":{"type":"string","const":"segment_membership","isRequired":true},"included_segment_ids":{"type":"array","items":{"type":"string"},"description":"Segment UUIDs the user must belong to."},"excluded_segment_ids":{"type":"array","items":{"type":"string"},"description":"Segment UUIDs the user must not belong to."}}},{"type":"object","title":"on_notification_action","description":"A branch condition. The `kind` field selects the shape.","required":["kind"],"properties":{"kind":{"type":"string","const":"on_notification_action","isRequired":true},"action":{"type":"string","enum":["received","clicked","opened"],"description":"The notification action to branch on. Which actions apply depends on the sending node's channel."},"sending_node_id":{"type":"string","description":"`id` of the sending node this action refers to. Returned on reads; accepted on write."},"client_node_id":{"type":"string","description":"Write-only alternative to `sending_node_id`. References the sending node by its `client_node_id`, which is resolved to that node's `id`."}}},{"type":"object","title":"event_trigger","description":"A branch condition. The `kind` field selects the shape.","required":["kind"],"properties":{"kind":{"type":"string","const":"event_trigger","isRequired":true},"name":{"type":"string","description":"Event name, up to 255 characters."},"attributes":{"type":"array","description":"Event attribute matchers, as a list of condition groups. Send a single group whose conditions are AND'd together. More than one group is rejected.","items":{"type":"array","items":{"type":"object","required":["key","operator"],"properties":{"key":{"type":"string","description":"Event attribute key.","isRequired":true},"operator":{"type":"string","enum":["equal","not_equal","less","less_or_equal","greater_or_equal","greater","is","is_not","exists","not_exists","before","after"],"description":"Comparison operator.","isRequired":true},"value":{"type":"string","description":"Value to compare against. Not required for `exists` and `not_exists`."}}}}},"entry_event_match_attributes":{"oneOf":[{"type":"array","items":{"type":"object"},"description":"Match incoming event properties against the journey's entry event. Only valid on event-triggered journeys."},{"type":"null","description":"Match incoming event properties against the journey's entry event. Only valid on event-triggered journeys."}]}}}]},"weight":{"type":"number","description":"Branch weight for `split_range` nodes. Weights across a node's branches must sum to 100."},"nodes":{"type":"array","items":{"$circularRef":"f6795843-f004-4026-9a86-d14c359fdee3"},"description":"Nodes run when this branch is taken, before flow converges to the next sibling node."}}},"description":"Condition branches. At least one required, at most 25. Order determines priority.","minItems":1,"maxItems":25},"expiration":{"oneOf":[{"type":"object","description":"Optional expiration timer. `null` waits indefinitely.","properties":{"duration_seconds":{"type":"integer","minimum":60,"description":"Seconds to wait before the timer fires. Minimum `60`, maximum `31556952` (1 year).","maximum":31556952},"exits":{"type":"boolean","description":"When true, the user exits the journey when the timer fires; when false, the user continues to convergence."}}},{"type":"null","description":"Optional expiration timer. `null` waits indefinitely.","properties":{"duration_seconds":{"type":"integer","minimum":60,"description":"Seconds to wait before the timer fires. Minimum `60`, maximum `31556952` (1 year).","maximum":31556952},"exits":{"type":"boolean","description":"When true, the user exits the journey when the timer fires; when false, the user continues to convergence."}}}]}}}]}}},"originalFileLocation":"openapi.json"},"subdomain":"onesignal","siteName":"OneSignal Documentation","title":"Create journey - OneSignal Documentation","navMaps":{"firstHrefInVersion":{},"firstHrefInLanguage":{"en":{"href":"/reference/create-journey","matchLevel":0},"cn":{"href":"/reference/create-journey","matchLevel":0},"ko":{"href":"/reference/create-journey","matchLevel":0},"ja":{"href":"/reference/create-journey","matchLevel":0},"tr":{"href":"/reference/create-journey","matchLevel":0},"pt-BR":{"href":"/reference/create-journey","matchLevel":0},"es":{"href":"/reference/create-journey","matchLevel":0},"fr":{"href":"/reference/create-journey","matchLevel":0}}},"lastModified":"2026-11-06T21:46:44.111Z","originalFileLocation":"reference/create-journey.mdx","locale":"en"},"headHtml":"\u003cscript data-mint-head>(function(){var d=document.documentElement,p=null;if(!p){try{p=localStorage.getItem(\"isDarkMode\")}catch(e){}if(p==='true')p='dark';else if(p==='false')p='light';if(p!=='light'\u0026\u0026p!=='dark'\u0026\u0026p!=='system')p=\"system\"}var r=p==='system'?(matchMedia(\"(prefers-color-scheme: dark)\").matches?'dark':'light'):p;d.classList.remove(r==='dark'?'light':'dark');d.classList.add(r);d.setAttribute(\"data-theme-preference\",p)})();\u003c/script>\u003cmeta data-mint-head name=\"description\" content=\"Create a new journey with an audience and a node graph. Journeys are always created in the draft state.\">\u003cmeta data-mint-head name=\"application-name\" content=\"OneSignal Documentation\">\u003cmeta data-mint-head name=\"generator\" content=\"Mintlify\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/onesignal/eCiRydtW5fLfLRWp/_generated/favicon/android-chrome-192x192.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"apple-touch-icon\" type=\"image/png\" sizes=\"180x180\" href=\"/mintlify-assets/_mintlify/favicons/onesignal/eCiRydtW5fLfLRWp/_generated/favicon/apple-touch-icon.png\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/onesignal/eCiRydtW5fLfLRWp/_generated/favicon/favicon-16x16.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/onesignal/eCiRydtW5fLfLRWp/_generated/favicon/favicon-32x32.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/onesignal/eCiRydtW5fLfLRWp/_generated/favicon/favicon.ico\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/onesignal/eCiRydtW5fLfLRWp/_generated/favicon-dark/android-chrome-192x192.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/onesignal/eCiRydtW5fLfLRWp/_generated/favicon-dark/favicon-16x16.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/onesignal/eCiRydtW5fLfLRWp/_generated/favicon-dark/favicon-32x32.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/onesignal/eCiRydtW5fLfLRWp/_generated/favicon-dark/favicon.ico\" media=\"(prefers-color-scheme: dark)\">\u003cmeta data-mint-head property=\"og:title\" content=\"Create journey - OneSignal Documentation\">\u003cmeta data-mint-head property=\"og:description\" content=\"Create a new journey with an audience and a node graph. Journeys are always created in the draft state.\">\u003cmeta data-mint-head property=\"og:site_name\" content=\"OneSignal Documentation\">\u003cmeta data-mint-head property=\"og:url\" content=\"https://documentation.onesignal.com/reference/create-journey\">\u003cmeta data-mint-head property=\"og:type\" content=\"website\">\u003cmeta data-mint-head property=\"og:image\" content=\"https://onesignal.mintlify.site/_mintlify/api/og/v2?division=Journeys\u0026amp;title=Create+journey\u0026amp;description=Create+a+new+journey+with+an+audience+and+a+node+graph.+Journeys+are+always+created+in+the+draft+state.\u0026amp;theme=8d648f04f85028b307bd669b\u0026amp;signature=6cad1daf684eb218afece8411565adabacffc17d1982361abdf6bbddd8cebda6\">\u003cmeta data-mint-head property=\"og:image:width\" content=\"1200\">\u003cmeta data-mint-head property=\"og:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"twitter:card\" content=\"summary_large_image\">\u003cmeta data-mint-head name=\"twitter:title\" content=\"Create journey - OneSignal Documentation\">\u003cmeta data-mint-head name=\"twitter:description\" content=\"Create a new journey with an audience and a node graph. Journeys are always created in the draft state.\">\u003cmeta data-mint-head name=\"twitter:image\" content=\"https://onesignal.mintlify.site/_mintlify/api/og/v2?division=Journeys\u0026amp;title=Create+journey\u0026amp;description=Create+a+new+journey+with+an+audience+and+a+node+graph.+Journeys+are+always+created+in+the+draft+state.\u0026amp;theme=8d648f04f85028b307bd669b\u0026amp;signature=6cad1daf684eb218afece8411565adabacffc17d1982361abdf6bbddd8cebda6\">\u003cmeta data-mint-head name=\"twitter:image:width\" content=\"1200\">\u003cmeta data-mint-head name=\"twitter:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"msapplication-config\" content=\"/mintlify-assets/_mintlify/favicons/onesignal/eCiRydtW5fLfLRWp/_generated/favicon/browserconfig.xml\">\u003cmeta data-mint-head name=\"apple-mobile-web-app-title\" content=\"OneSignal Docs\">\u003cmeta data-mint-head name=\"msapplication-TileColor\" content=\"#3A3DB3\">\u003clink data-mint-head rel=\"canonical\" href=\"https://documentation.onesignal.com/reference/create-journey\">\u003clink data-mint-head rel=\"alternate\" type=\"application/xml\" href=\"/sitemap.xml\">\u003clink data-mint-head rel=\"alternate\" type=\"text/markdown\" href=\"/reference/create-journey.md\">\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@graph\":[{\"@type\":\"Organization\",\"@id\":\"https://documentation.onesignal.com/#organization\",\"name\":\"OneSignal Documentation\",\"url\":\"https://documentation.onesignal.com\",\"logo\":{\"@type\":\"ImageObject\",\"url\":\"https://mintcdn.com/onesignal/yJcueeDCO7UpHnnY/logo/OneSignal-Logo.svg?fit=max\u0026auto=format\u0026n=yJcueeDCO7UpHnnY\u0026q=85\u0026s=1fcfb6fef6d820fd9d99c74850711107\"}},{\"@type\":\"WebSite\",\"@id\":\"https://documentation.onesignal.com#website\",\"name\":\"OneSignal Documentation\",\"url\":\"https://documentation.onesignal.com\",\"publisher\":{\"@id\":\"https://documentation.onesignal.com/#organization\"}},{\"@type\":\"WebPage\",\"@id\":\"https://documentation.onesignal.com/reference/create-journey#webpage\",\"url\":\"https://documentation.onesignal.com/reference/create-journey\",\"name\":\"Create journey\",\"description\":\"Create a new journey with an audience and a node graph. Journeys are always created in the draft state.\",\"dateModified\":\"2026-11-06T21:46:44.111Z\",\"isPartOf\":{\"@id\":\"https://documentation.onesignal.com#website\"},\"breadcrumb\":{\"@id\":\"https://documentation.onesignal.com/reference/create-journey#breadcrumb\"}},{\"@type\":\"BreadcrumbList\",\"@id\":\"https://documentation.onesignal.com/reference/create-journey#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"API reference\",\"item\":\"https://documentation.onesignal.com/reference/create-message\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Journeys\",\"item\":\"https://documentation.onesignal.com/reference/view-journeys\"},{\"@type\":\"ListItem\",\"position\":3,\"name\":\"Create journey\",\"item\":\"https://documentation.onesignal.com/reference/create-journey\"}]},{\"@type\":[\"TechArticle\",\"APIReference\"],\"@id\":\"https://documentation.onesignal.com/reference/create-journey#apireference\",\"headline\":\"Create journey\",\"name\":\"Create journey\",\"description\":\"Create a new journey with an audience and a node graph. Journeys are always created in the draft state.\",\"url\":\"https://documentation.onesignal.com/reference/create-journey\",\"mainEntityOfPage\":{\"@id\":\"https://documentation.onesignal.com/reference/create-journey#webpage\"},\"dateModified\":\"2026-11-06T21:46:44.111Z\",\"keywords\":\"journeys API, create journey, journey automation, journey nodes, journey audience\",\"publisher\":{\"@id\":\"https://documentation.onesignal.com/#organization\"},\"isPartOf\":{\"@id\":\"https://documentation.onesignal.com#website\"}}]}\u003c/script>\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@type\":\"WebSite\",\"name\":\"OneSignal Documentation\",\"creator\":{\"@type\":\"Organization\",\"name\":\"Mintlify\",\"url\":\"https://mintlify.com\"}}\u003c/script>","siteName":"OneSignal Documentation","nav":{"global":null,"languages":[{"language":"en","tabs":[{"tab":"Home","pages":[{"title":"Home","href":"/docs/en/home"}]},{"tab":"User Guides","pages":[{"title":"User Guides","href":"/docs/en/quickstart-guide"}]},{"tab":"Developer Guides","pages":[{"title":"Developer Guides","href":"/docs/en/developers"}]},{"tab":"Tutorials","pages":[{"title":"Tutorials","href":"/docs/en/tutorials"}]},{"tab":"API Reference","groups":[{"group":"Using the REST APIs","pages":[{"title":"REST API overview","href":"/reference/rest-api-overview"},{"title":"Rate limits and error handling","href":"/reference/rate-limits"},{"title":"Idempotent API requests","href":"/reference/idempotent-notification-requests"},{"title":"Server SDK reference","href":"/docs/en/server-sdk-reference"}]},{"group":"API reference","pages":[{"group":"Messages","pages":[{"title":"Sending messages with the OneSignal API","href":"/reference/create-message"},{"title":"Push notification","openapi":"POST /notifications?c=push","href":"/reference/push-notification"},{"title":"Email","openapi":"POST /notifications?c=email","href":"/reference/email"},{"title":"SMS","openapi":"POST /notifications?c=sms","href":"/reference/sms"},{"title":"View message","openapi":"GET /notifications/{message_id}?app_id={app_id}","href":"/reference/view-message"},{"title":"View messages","openapi":"GET /notifications?app_id={app_id}\u0026limit={limit}\u0026offset={offset}\u0026kind={kind}\u0026template_id={template_id}\u0026time_offset={time_offset}","href":"/reference/view-messages"},{"title":"Cancel message","openapi":"DELETE /notifications/{message_id}?app_id={app_id}","href":"/reference/cancel-message"},{"title":"Message history","openapi":"POST /notifications/{message_id}/history","href":"/reference/message-history"},{"title":"Estimated recipients","openapi":"POST /notifications/count-unsaved","href":"/reference/count-unsaved"}]},{"group":"Live Activities","pages":[{"title":"Start Live Activity","openapi":"POST /apps/{app_id}/activities/activity/{activity_type}","href":"/reference/start-live-activity"},{"title":"Update Live Activity","openapi":"POST /apps/{app_id}/live_activities/{activity_id}/notifications","href":"/reference/update-live-activity-api"}]},{"group":"Custom Events","pages":[{"title":"Create custom events","openapi":"POST /apps/{app_id}/custom_events","href":"/reference/create-custom-events"}]},{"group":"Users","pages":[{"title":"Create user","openapi":"POST /apps/{app_id}/users","href":"/reference/create-user"},{"title":"View user","openapi":"GET /apps/{app_id}/users/by/{alias_label}/{alias_id}","href":"/reference/view-user"},{"title":"Update user","openapi":"PATCH /apps/{app_id}/users/by/{alias_label}/{alias_id}","href":"/reference/update-user"},{"title":"Delete user","openapi":"DELETE /apps/{app_id}/users/by/{alias_label}/{alias_id}","href":"/reference/delete-user"},{"title":"View user identity","openapi":"GET /apps/{app_id}/users/by/{alias_label}/{alias_id}/identity","href":"/reference/fetch-aliases"},{"title":"View user identity (by subscription)","openapi":"GET /apps/{app_id}/subscriptions/{subscription_id}/user/identity","href":"/reference/fetch-identity-by-subscription"},{"title":"Create or update alias","openapi":"PATCH /apps/{app_id}/users/by/{alias_label}/{alias_id}/identity","href":"/reference/create-alias"},{"title":"Create alias (by subscription)","openapi":"PATCH /apps/{app_id}/subscriptions/{subscription_id}/user/identity","href":"/reference/create-alias-by-subscription"},{"title":"Delete alias","openapi":"DELETE /apps/{app_id}/users/by/{alias_label}/{alias_id}/identity/{alias_label_to_delete}","href":"/reference/delete-alias"}]},{"group":"Subscriptions","pages":[{"title":"Create Subscription by alias","openapi":"POST /apps/{app_id}/users/by/{alias_label}/{alias_id}/subscriptions","href":"/reference/create-subscription"},{"title":"Update Subscription by ID","openapi":"PATCH /apps/{app_id}/subscriptions/{subscription_id}","href":"/reference/update-subscription"},{"title":"Update Subscription by token","openapi":"PATCH /apps/{app_id}/subscriptions_by_token/{token_type}/{token}","href":"/reference/update-subscription-by-token"},{"title":"Delete Subscription","openapi":"DELETE /apps/{app_id}/subscriptions/{subscription_id}","href":"/reference/delete-subscription"},{"title":"Transfer Subscription","openapi":"PATCH /apps/{app_id}/subscriptions/{subscription_id}/owner","href":"/reference/transfer-subscription"},{"title":"Unsubscribe email with token","openapi":"POST /apps/{app_id}/notifications/{notification_id}/unsubscribe?token={token}","href":"/reference/unsubscribe-with-token"}]},{"group":"Templates","pages":[{"title":"Create template","openapi":"POST /templates","href":"/reference/create-template"},{"title":"Update template","openapi":"PATCH /templates/{template_id}?app_id={app_id}","href":"/reference/update-template"},{"title":"View templates","openapi":"GET /templates?app_id={app_id}\u0026limit={limit}\u0026offset={offset}","href":"/reference/view-templates"},{"title":"View template","openapi":"GET /templates/{template_id}?app_id={app_id}","href":"/reference/view-template"},{"title":"Delete template","openapi":"DELETE /templates/{template_id}?app_id={app_id}","href":"/reference/delete-template"},{"title":"Copy template to another app","openapi":"POST /templates/{template_id}/copy_to_app?app_id={app_id}","href":"/reference/copy-template-to-another-app"}]},{"group":"Segments","pages":[{"title":"View segments","openapi":"GET /apps/{app_id}/segments","href":"/reference/view-segments"},{"title":"View segment","openapi":"GET /apps/{app_id}/segments/{segment_id}","href":"/reference/view-segment"},{"title":"Create segment","openapi":"POST /apps/{app_id}/segments","href":"/reference/create-segments"},{"title":"Update segment","openapi":"PATCH /apps/{app_id}/segments/{segment_id}","href":"/reference/update-segment"},{"title":"Delete segment","openapi":"DELETE /apps/{app_id}/segments/{segment_id}","href":"/reference/delete-segments"}]},{"group":"Journeys","pages":[{"title":"View journeys","tag":"BETA","openapi":"GET /apps/{app_id}/journeys","href":"/reference/view-journeys"},{"title":"View journey","tag":"BETA","openapi":"GET /apps/{app_id}/journeys/{id}","href":"/reference/view-journey"},{"title":"View journey stats","tag":"BETA","openapi":"GET /apps/{app_id}/journeys/{id}/stats","href":"/reference/view-journey-stats"},{"title":"Get Journey schema","tag":"BETA","openapi":"GET /journeys/schema","description":"Retrieve the JSON Schema for creating, duplicating, or updating a Journey or step before you construct a request.","href":"/reference/get-journey-schema"},{"title":"Create journey","tag":"BETA","openapi":"POST /apps/{app_id}/journeys","href":"/reference/create-journey"},{"title":"Duplicate journey","tag":"BETA","openapi":"POST /apps/{app_id}/journeys/{id}/duplicate","description":"Copy an existing journey into a new draft. You can apply overrides to the copy in the same request.","href":"/reference/duplicate-journey"},{"title":"Update journey","tag":"BETA","openapi":"PATCH /apps/{app_id}/journeys/{id}","href":"/reference/update-journey"},{"title":"Update journey node","tag":"BETA","openapi":"PATCH /apps/{app_id}/journeys/{id}/nodes/{node_id}","href":"/reference/update-journey-node"},{"title":"Delete journey","tag":"BETA","openapi":"DELETE /apps/{app_id}/journeys/{id}","href":"/reference/delete-journey"}]},{"group":"Organization","pages":[{"title":"List audit logs","openapi":"GET /organizations/{organization_id}/audit_logs","href":"/reference/list-audit-logs"},{"title":"View apps","openapi":"GET /apps","href":"/reference/view-apps"},{"title":"View an app","openapi":"GET /apps/{app_id}","href":"/reference/view-an-app"},{"title":"Create an app","openapi":"POST /apps","href":"/reference/create-an-app"},{"title":"Update an app","openapi":"PUT /apps/{app_id}","href":"/reference/update-an-app"},{"title":"View API keys","openapi":"GET /apps/{app_id}/auth/tokens","href":"/reference/view-api-keys"},{"title":"Create API key","openapi":"POST /apps/{app_id}/auth/tokens","href":"/reference/create-api-key"},{"title":"Delete API key","openapi":"DELETE /apps/{app_id}/auth/tokens/{token_id}","href":"/reference/delete-api-key"},{"title":"Update API key","openapi":"PATCH /apps/{app_id}/auth/tokens/{token_id}","href":"/reference/update-api-key"},{"title":"Rotate API key","openapi":"POST /apps/{app_id}/auth/tokens/{token_id}/rotate","href":"/reference/rotate-api-key"}]},{"group":"Analytics","pages":[{"title":"Export subscriptions CSV","openapi":"POST /players/csv_export","href":"/reference/csv-export"},{"title":"Export audience activity CSV","openapi":"POST /notifications/{message_id}/export_events","href":"/reference/export-csv-of-events"},{"title":"View outcomes","openapi":"GET /apps/{app_id}/outcomes?outcome_names={outcome_names}\u0026outcome_time_range={outcome_time_range}\u0026outcome_platforms={outcome_platforms}\u0026outcome_attribution={outcome_attribution}","href":"/reference/view-outcomes"},{"title":"Email reputation statistics","openapi":"GET /apps/{app_id}/email_analytics/delivery_metrics","href":"/reference/delivery-metrics"},{"title":"Email provider metrics","openapi":"GET /apps/{app_id}/email_analytics/provider_metrics","href":"/reference/provider-metrics"},{"title":"Email provider metrics timeseries","openapi":"GET /apps/{app_id}/email_analytics/provider_metrics_timeseries","href":"/reference/provider-metrics-timeseries"}]},{"group":"Deprecated","pages":[{"title":"View players","deprecated":true,"href":"/reference/view-devices"},{"title":"View player","deprecated":true,"href":"/reference/view-device"},{"title":"Add a player","deprecated":true,"href":"/reference/add-a-device"},{"title":"Edit player","deprecated":true,"href":"/reference/edit-device"},{"title":"Edit tags with external user id","deprecated":true,"href":"/reference/edit-tags-with-external-user-id"},{"title":"Delete player record","deprecated":true,"href":"/reference/delete-user-record"}]}]}]},{"tab":"Release Notes","pages":[{"title":"Release Notes","href":"/release-notes/changelog"}]},{"tab":"Customer Success Hub","pages":[{"title":"Customer Success Hub","href":"/docs/en/customer-success-hub"}]}],"global":{"anchors":[{"anchor":"Blog","icon":"newspaper","href":"https://onesignal.com/blog"},{"anchor":"GitHub","icon":"github","href":"https://github.com/OneSignal"},{"anchor":"YouTube","icon":"youtube","href":"https://www.youtube.com/@onesignalofficial/playlists"}]}},{"language":"cn","tabs":[{"tab":"主页","pages":[{"title":"主页","href":"/docs/cn/home"}]},{"tab":"用户指南","pages":[{"title":"用户指南","href":"/docs/cn/quickstart-guide"}]},{"tab":"开发者指南","pages":[{"title":"开发者指南","href":"/docs/cn/developers"}]},{"tab":"教程","pages":[{"title":"教程","href":"/docs/cn/tutorials"}]},{"tab":"API Reference","groups":[{"group":"Using REST APIs","pages":[{"title":"REST API overview","href":"/reference/rest-api-overview"},{"title":"Rate limits and error handling","href":"/reference/rate-limits"}]},{"group":"API Reference","pages":[{"group":"Messages","pages":[{"title":"Sending messages with the OneSignal API","href":"/reference/create-message"},{"title":"Idempotent API requests","href":"/reference/idempotent-notification-requests"},{"title":"Push notification","openapi":"POST /notifications?c=push","href":"/reference/push-notification"},{"title":"Email","openapi":"POST /notifications?c=email","href":"/reference/email"},{"title":"SMS","openapi":"POST /notifications?c=sms","href":"/reference/sms"},{"title":"View message","openapi":"GET /notifications/{message_id}?app_id={app_id}","href":"/reference/view-message"},{"title":"View messages","openapi":"GET /notifications?app_id={app_id}\u0026limit={limit}\u0026offset={offset}\u0026kind={kind}\u0026template_id={template_id}\u0026time_offset={time_offset}","href":"/reference/view-messages"},{"title":"Cancel message","openapi":"DELETE /notifications/{message_id}?app_id={app_id}","href":"/reference/cancel-message"},{"title":"Message history","openapi":"POST /notifications/{message_id}/history","href":"/reference/message-history"},{"title":"Estimated recipients","openapi":"POST /notifications/count-unsaved","href":"/reference/count-unsaved"}]},{"group":"Live Activities","pages":[{"title":"Start Live Activity","openapi":"POST /apps/{app_id}/activities/activity/{activity_type}","href":"/reference/start-live-activity"},{"title":"Update Live Activity","openapi":"POST /apps/{app_id}/live_activities/{activity_id}/notifications","href":"/reference/update-live-activity-api"}]},{"group":"Custom Events","pages":[{"title":"Create custom events","openapi":"POST /apps/{app_id}/custom_events","href":"/reference/create-custom-events"}]},{"group":"Users","pages":[{"title":"Create user","openapi":"POST /apps/{app_id}/users","href":"/reference/create-user"},{"title":"View user","openapi":"GET /apps/{app_id}/users/by/{alias_label}/{alias_id}","href":"/reference/view-user"},{"title":"Update user","openapi":"PATCH /apps/{app_id}/users/by/{alias_label}/{alias_id}","href":"/reference/update-user"},{"title":"Delete user","openapi":"DELETE /apps/{app_id}/users/by/{alias_label}/{alias_id}","href":"/reference/delete-user"},{"title":"View user identity","openapi":"GET /apps/{app_id}/users/by/{alias_label}/{alias_id}/identity","href":"/reference/fetch-aliases"},{"title":"View user identity (by subscription)","openapi":"GET /apps/{app_id}/subscriptions/{subscription_id}/user/identity","href":"/reference/fetch-identity-by-subscription"},{"title":"Create or update alias","openapi":"PATCH /apps/{app_id}/users/by/{alias_label}/{alias_id}/identity","href":"/reference/create-alias"},{"title":"Create alias (by subscription)","openapi":"PATCH /apps/{app_id}/subscriptions/{subscription_id}/user/identity","href":"/reference/create-alias-by-subscription"},{"title":"Delete alias","openapi":"DELETE /apps/{app_id}/users/by/{alias_label}/{alias_id}/identity/{alias_label_to_delete}","href":"/reference/delete-alias"}]},{"group":"Subscriptions","pages":[{"title":"Create Subscription by alias","openapi":"POST /apps/{app_id}/users/by/{alias_label}/{alias_id}/subscriptions","href":"/reference/create-subscription"},{"title":"Update Subscription by ID","openapi":"PATCH /apps/{app_id}/subscriptions/{subscription_id}","href":"/reference/update-subscription"},{"title":"Update Subscription by token","openapi":"PATCH /apps/{app_id}/subscriptions_by_token/{token_type}/{token}","href":"/reference/update-subscription-by-token"},{"title":"Delete Subscription","openapi":"DELETE /apps/{app_id}/subscriptions/{subscription_id}","href":"/reference/delete-subscription"},{"title":"Transfer Subscription","openapi":"PATCH /apps/{app_id}/subscriptions/{subscription_id}/owner","href":"/reference/transfer-subscription"},{"title":"Unsubscribe email with token","openapi":"POST /apps/{app_id}/notifications/{notification_id}/unsubscribe?token={token}","href":"/reference/unsubscribe-with-token"}]},{"group":"Templates","pages":[{"title":"Create template","openapi":"POST /templates","href":"/reference/create-template"},{"title":"Update template","openapi":"PATCH /templates/{template_id}?app_id={app_id}","href":"/reference/update-template"},{"title":"View templates","openapi":"GET /templates?app_id={app_id}\u0026limit={limit}\u0026offset={offset}","href":"/reference/view-templates"},{"title":"View template","openapi":"GET /templates/{template_id}?app_id={app_id}","href":"/reference/view-template"},{"title":"Delete template","openapi":"DELETE /templates/{template_id}?app_id={app_id}","href":"/reference/delete-template"},{"title":"Copy template to another app","openapi":"POST /templates/{template_id}/copy_to_app?app_id={app_id}","href":"/reference/copy-template-to-another-app"}]},{"group":"Segments","pages":[{"title":"View segments","openapi":"GET /apps/{app_id}/segments","href":"/reference/view-segments"},{"title":"View segment","openapi":"GET /apps/{app_id}/segments/{segment_id}","href":"/reference/view-segment"},{"title":"Create segment","openapi":"POST /apps/{app_id}/segments","href":"/reference/create-segments"},{"title":"Update segment","openapi":"PATCH /apps/{app_id}/segments/{segment_id}","href":"/reference/update-segment"},{"title":"Delete segment","openapi":"DELETE /apps/{app_id}/segments/{segment_id}","href":"/reference/delete-segments"}]},{"group":"Journeys","pages":[{"title":"View journeys","tag":"BETA","openapi":"GET /apps/{app_id}/journeys","href":"/reference/view-journeys"},{"title":"View journey","tag":"BETA","openapi":"GET /apps/{app_id}/journeys/{id}","href":"/reference/view-journey"},{"title":"View journey stats","tag":"BETA","openapi":"GET /apps/{app_id}/journeys/{id}/stats","description":"Retrieve performance stats for a single journey, including journey-level counts, per-node counts, per-branch counts, and channel delivery stats.","href":"/reference/view-journey-stats"},{"title":"Create journey","tag":"BETA","openapi":"POST /apps/{app_id}/journeys","href":"/reference/create-journey"},{"title":"Duplicate journey","tag":"BETA","openapi":"POST /apps/{app_id}/journeys/{id}/duplicate","description":"Copy an existing journey into a new draft. You can apply overrides to the copy in the same request.","href":"/reference/duplicate-journey"},{"title":"Update journey","tag":"BETA","openapi":"PATCH /apps/{app_id}/journeys/{id}","href":"/reference/update-journey"},{"title":"Update journey node","tag":"BETA","openapi":"PATCH /apps/{app_id}/journeys/{id}/nodes/{node_id}","href":"/reference/update-journey-node"},{"title":"Delete journey","tag":"BETA","openapi":"DELETE /apps/{app_id}/journeys/{id}","href":"/reference/delete-journey"}]},{"group":"Configuration","pages":[{"title":"View apps","openapi":"GET /apps","href":"/reference/view-apps"},{"title":"View an app","openapi":"GET /apps/{app_id}","href":"/reference/view-an-app"},{"title":"Create an app","openapi":"POST /apps","href":"/reference/create-an-app"},{"title":"Update an app","openapi":"PUT /apps/{app_id}","href":"/reference/update-an-app"},{"title":"View API keys","openapi":"GET /apps/{app_id}/auth/tokens","href":"/reference/view-api-keys"},{"title":"Create API key","openapi":"POST /apps/{app_id}/auth/tokens","href":"/reference/create-api-key"},{"title":"Delete API key","openapi":"DELETE /apps/{app_id}/auth/tokens/{token_id}","href":"/reference/delete-api-key"},{"title":"Update API key","openapi":"PATCH /apps/{app_id}/auth/tokens/{token_id}","href":"/reference/update-api-key"},{"title":"Rotate API key","openapi":"POST /apps/{app_id}/auth/tokens/{token_id}/rotate","href":"/reference/rotate-api-key"}]},{"group":"Analytics","pages":[{"title":"Export subscriptions CSV","openapi":"POST /players/csv_export","href":"/reference/csv-export"},{"title":"Export audience activity CSV","openapi":"POST /notifications/{message_id}/export_events","href":"/reference/export-csv-of-events"},{"title":"View outcomes","openapi":"GET /apps/{app_id}/outcomes?outcome_names={outcome_names}\u0026outcome_time_range={outcome_time_range}\u0026outcome_platforms={outcome_platforms}\u0026outcome_attribution={outcome_attribution}","href":"/reference/view-outcomes"}]},{"group":"Deprecated","pages":[{"title":"View players","deprecated":true,"href":"/reference/view-devices"},{"title":"View player","deprecated":true,"href":"/reference/view-device"},{"title":"Add a player","deprecated":true,"href":"/reference/add-a-device"},{"title":"Edit player","deprecated":true,"href":"/reference/edit-device"},{"title":"Edit tags with external user id","deprecated":true,"href":"/reference/edit-tags-with-external-user-id"},{"title":"Delete player record","deprecated":true,"href":"/reference/delete-user-record"}]}]},{"group":"SDKs","pages":[{"title":"服务器 SDK 参考","href":"/docs/cn/server-sdk-reference"}]}]},{"tab":"Release Notes","pages":[{"title":"Release Notes","href":"/release-notes/changelog"}]}],"global":{"anchors":[{"anchor":"Blog","icon":"newspaper","href":"https://onesignal.com/blog"},{"anchor":"GitHub","icon":"github","href":"https://github.com/OneSignal"},{"anchor":"YouTube","icon":"youtube","href":"https://www.youtube.com/@onesignalofficial/playlists"}]}},{"language":"ko","tabs":[{"tab":"홈","pages":[{"title":"홈","href":"/docs/ko/home"}]},{"tab":"사용자 가이드","pages":[{"title":"사용자 가이드","href":"/docs/ko/quickstart-guide"}]},{"tab":"개발자 가이드","pages":[{"title":"개발자 가이드","href":"/docs/ko/developers"}]},{"tab":"튜토리얼","pages":[{"title":"튜토리얼","href":"/docs/ko/tutorials"}]},{"tab":"API Reference","groups":[{"group":"Using the REST APIs","pages":[{"title":"REST API overview","href":"/reference/rest-api-overview"},{"title":"Rate limits and error handling","href":"/reference/rate-limits"}]},{"group":"API reference","pages":[{"group":"Messages","pages":[{"title":"Sending messages with the OneSignal API","href":"/reference/create-message"},{"title":"Idempotent API requests","href":"/reference/idempotent-notification-requests"},{"title":"Push notification","openapi":"POST /notifications?c=push","href":"/reference/push-notification"},{"title":"Email","openapi":"POST /notifications?c=email","href":"/reference/email"},{"title":"SMS","openapi":"POST /notifications?c=sms","href":"/reference/sms"},{"title":"View message","openapi":"GET /notifications/{message_id}?app_id={app_id}","href":"/reference/view-message"},{"title":"View messages","openapi":"GET /notifications?app_id={app_id}\u0026limit={limit}\u0026offset={offset}\u0026kind={kind}\u0026template_id={template_id}\u0026time_offset={time_offset}","href":"/reference/view-messages"},{"title":"Cancel message","openapi":"DELETE /notifications/{message_id}?app_id={app_id}","href":"/reference/cancel-message"},{"title":"Message history","openapi":"POST /notifications/{message_id}/history","href":"/reference/message-history"},{"title":"Estimated recipients","openapi":"POST /notifications/count-unsaved","href":"/reference/count-unsaved"}]},{"group":"Live Activities","pages":[{"title":"Start Live Activity","openapi":"POST /apps/{app_id}/activities/activity/{activity_type}","href":"/reference/start-live-activity"},{"title":"Update Live Activity","openapi":"POST /apps/{app_id}/live_activities/{activity_id}/notifications","href":"/reference/update-live-activity-api"}]},{"group":"Custom Events","pages":[{"title":"Create custom events","openapi":"POST /apps/{app_id}/custom_events","href":"/reference/create-custom-events"}]},{"group":"Users","pages":[{"title":"Create user","openapi":"POST /apps/{app_id}/users","href":"/reference/create-user"},{"title":"View user","openapi":"GET /apps/{app_id}/users/by/{alias_label}/{alias_id}","href":"/reference/view-user"},{"title":"Update user","openapi":"PATCH /apps/{app_id}/users/by/{alias_label}/{alias_id}","href":"/reference/update-user"},{"title":"Delete user","openapi":"DELETE /apps/{app_id}/users/by/{alias_label}/{alias_id}","href":"/reference/delete-user"},{"title":"View user identity","openapi":"GET /apps/{app_id}/users/by/{alias_label}/{alias_id}/identity","href":"/reference/fetch-aliases"},{"title":"View user identity (by subscription)","openapi":"GET /apps/{app_id}/subscriptions/{subscription_id}/user/identity","href":"/reference/fetch-identity-by-subscription"},{"title":"Create or update alias","openapi":"PATCH /apps/{app_id}/users/by/{alias_label}/{alias_id}/identity","href":"/reference/create-alias"},{"title":"Create alias (by subscription)","openapi":"PATCH /apps/{app_id}/subscriptions/{subscription_id}/user/identity","href":"/reference/create-alias-by-subscription"},{"title":"Delete alias","openapi":"DELETE /apps/{app_id}/users/by/{alias_label}/{alias_id}/identity/{alias_label_to_delete}","href":"/reference/delete-alias"}]},{"group":"Subscriptions","pages":[{"title":"Create Subscription by alias","openapi":"POST /apps/{app_id}/users/by/{alias_label}/{alias_id}/subscriptions","href":"/reference/create-subscription"},{"title":"Update Subscription by ID","openapi":"PATCH /apps/{app_id}/subscriptions/{subscription_id}","href":"/reference/update-subscription"},{"title":"Update Subscription by token","openapi":"PATCH /apps/{app_id}/subscriptions_by_token/{token_type}/{token}","href":"/reference/update-subscription-by-token"},{"title":"Delete Subscription","openapi":"DELETE /apps/{app_id}/subscriptions/{subscription_id}","href":"/reference/delete-subscription"},{"title":"Transfer Subscription","openapi":"PATCH /apps/{app_id}/subscriptions/{subscription_id}/owner","href":"/reference/transfer-subscription"},{"title":"Unsubscribe email with token","openapi":"POST /apps/{app_id}/notifications/{notification_id}/unsubscribe?token={token}","href":"/reference/unsubscribe-with-token"}]},{"group":"Templates","pages":[{"title":"Create template","openapi":"POST /templates","href":"/reference/create-template"},{"title":"Update template","openapi":"PATCH /templates/{template_id}?app_id={app_id}","href":"/reference/update-template"},{"title":"View templates","openapi":"GET /templates?app_id={app_id}\u0026limit={limit}\u0026offset={offset}","href":"/reference/view-templates"},{"title":"View template","openapi":"GET /templates/{template_id}?app_id={app_id}","href":"/reference/view-template"},{"title":"Delete template","openapi":"DELETE /templates/{template_id}?app_id={app_id}","href":"/reference/delete-template"},{"title":"Copy template to another app","openapi":"POST /templates/{template_id}/copy_to_app?app_id={app_id}","href":"/reference/copy-template-to-another-app"}]},{"group":"Segments","pages":[{"title":"View segments","openapi":"GET /apps/{app_id}/segments","href":"/reference/view-segments"},{"title":"View segment","openapi":"GET /apps/{app_id}/segments/{segment_id}","href":"/reference/view-segment"},{"title":"Create segment","openapi":"POST /apps/{app_id}/segments","href":"/reference/create-segments"},{"title":"Update segment","openapi":"PATCH /apps/{app_id}/segments/{segment_id}","href":"/reference/update-segment"},{"title":"Delete segment","openapi":"DELETE /apps/{app_id}/segments/{segment_id}","href":"/reference/delete-segments"}]},{"group":"Journeys","pages":[{"title":"View journeys","tag":"BETA","openapi":"GET /apps/{app_id}/journeys","href":"/reference/view-journeys"},{"title":"View journey","tag":"BETA","openapi":"GET /apps/{app_id}/journeys/{id}","href":"/reference/view-journey"},{"title":"View journey stats","tag":"BETA","openapi":"GET /apps/{app_id}/journeys/{id}/stats","description":"Retrieve performance stats for a single journey, including journey-level counts, per-node counts, per-branch counts, and channel delivery stats.","href":"/reference/view-journey-stats"},{"title":"Create journey","tag":"BETA","openapi":"POST /apps/{app_id}/journeys","href":"/reference/create-journey"},{"title":"Duplicate journey","tag":"BETA","openapi":"POST /apps/{app_id}/journeys/{id}/duplicate","description":"Copy an existing journey into a new draft. You can apply overrides to the copy in the same request.","href":"/reference/duplicate-journey"},{"title":"Update journey","tag":"BETA","openapi":"PATCH /apps/{app_id}/journeys/{id}","href":"/reference/update-journey"},{"title":"Update journey node","tag":"BETA","openapi":"PATCH /apps/{app_id}/journeys/{id}/nodes/{node_id}","href":"/reference/update-journey-node"},{"title":"Delete journey","tag":"BETA","openapi":"DELETE /apps/{app_id}/journeys/{id}","href":"/reference/delete-journey"}]},{"group":"Configuration","pages":[{"title":"View apps","openapi":"GET /apps","href":"/reference/view-apps"},{"title":"View an app","openapi":"GET /apps/{app_id}","href":"/reference/view-an-app"},{"title":"Create an app","openapi":"POST /apps","href":"/reference/create-an-app"},{"title":"Update an app","openapi":"PUT /apps/{app_id}","href":"/reference/update-an-app"},{"title":"View API keys","openapi":"GET /apps/{app_id}/auth/tokens","href":"/reference/view-api-keys"},{"title":"Create API key","openapi":"POST /apps/{app_id}/auth/tokens","href":"/reference/create-api-key"},{"title":"Delete API key","openapi":"DELETE /apps/{app_id}/auth/tokens/{token_id}","href":"/reference/delete-api-key"},{"title":"Update API key","openapi":"PATCH /apps/{app_id}/auth/tokens/{token_id}","href":"/reference/update-api-key"},{"title":"Rotate API key","openapi":"POST /apps/{app_id}/auth/tokens/{token_id}/rotate","href":"/reference/rotate-api-key"}]},{"group":"Analytics","pages":[{"title":"Export subscriptions CSV","openapi":"POST /players/csv_export","href":"/reference/csv-export"},{"title":"Export audience activity CSV","openapi":"POST /notifications/{message_id}/export_events","href":"/reference/export-csv-of-events"},{"title":"View outcomes","openapi":"GET /apps/{app_id}/outcomes?outcome_names={outcome_names}\u0026outcome_time_range={outcome_time_range}\u0026outcome_platforms={outcome_platforms}\u0026outcome_attribution={outcome_attribution}","href":"/reference/view-outcomes"}]},{"group":"Deprecated","pages":[{"title":"View players","deprecated":true,"href":"/reference/view-devices"},{"title":"View player","deprecated":true,"href":"/reference/view-device"},{"title":"Add a player","deprecated":true,"href":"/reference/add-a-device"},{"title":"Edit player","deprecated":true,"href":"/reference/edit-device"},{"title":"Edit tags with external user id","deprecated":true,"href":"/reference/edit-tags-with-external-user-id"},{"title":"Delete player record","deprecated":true,"href":"/reference/delete-user-record"}]}]},{"group":"SDKs","pages":[{"title":"Server SDK 참조","href":"/docs/ko/server-sdk-reference"}]}]},{"tab":"Release Notes","pages":[{"title":"Release Notes","href":"/release-notes/changelog"}]}],"global":{"anchors":[{"anchor":"Blog","icon":"newspaper","href":"https://onesignal.com/blog"},{"anchor":"GitHub","icon":"github","href":"https://github.com/OneSignal"},{"anchor":"YouTube","icon":"youtube","href":"https://www.youtube.com/@onesignalofficial/playlists"}]}},{"language":"ja","tabs":[{"tab":"ホームページ","pages":[{"title":"ホームページ","href":"/docs/ja/home"}]},{"tab":"ユーザーガイド","pages":[{"title":"ユーザーガイド","href":"/docs/ja/quickstart-guide"}]},{"tab":"開発者ガイド","pages":[{"title":"開発者ガイド","href":"/docs/ja/developers"}]},{"tab":"チュートリアル","pages":[{"title":"チュートリアル","href":"/docs/ja/tutorials"}]},{"tab":"API Reference","groups":[{"group":"Using the REST APIs","pages":[{"title":"REST API overview","href":"/reference/rest-api-overview"},{"title":"Rate limits and error handling","href":"/reference/rate-limits"}]},{"group":"API reference","pages":[{"group":"Messages","pages":[{"title":"Sending messages with the OneSignal API","href":"/reference/create-message"},{"title":"Idempotent API requests","href":"/reference/idempotent-notification-requests"},{"title":"Push notification","openapi":"POST /notifications?c=push","href":"/reference/push-notification"},{"title":"Email","openapi":"POST /notifications?c=email","href":"/reference/email"},{"title":"SMS","openapi":"POST /notifications?c=sms","href":"/reference/sms"},{"title":"View message","openapi":"GET /notifications/{message_id}?app_id={app_id}","href":"/reference/view-message"},{"title":"View messages","openapi":"GET /notifications?app_id={app_id}\u0026limit={limit}\u0026offset={offset}\u0026kind={kind}\u0026template_id={template_id}\u0026time_offset={time_offset}","href":"/reference/view-messages"},{"title":"Cancel message","openapi":"DELETE /notifications/{message_id}?app_id={app_id}","href":"/reference/cancel-message"},{"title":"Message history","openapi":"POST /notifications/{message_id}/history","href":"/reference/message-history"},{"title":"Estimated recipients","openapi":"POST /notifications/count-unsaved","href":"/reference/count-unsaved"}]},{"group":"Live Activities","pages":[{"title":"Start Live Activity","openapi":"POST /apps/{app_id}/activities/activity/{activity_type}","href":"/reference/start-live-activity"},{"title":"Update Live Activity","openapi":"POST /apps/{app_id}/live_activities/{activity_id}/notifications","href":"/reference/update-live-activity-api"}]},{"group":"Custom Events","pages":[{"title":"Create custom events","openapi":"POST /apps/{app_id}/custom_events","href":"/reference/create-custom-events"}]},{"group":"Users","pages":[{"title":"Create user","openapi":"POST /apps/{app_id}/users","href":"/reference/create-user"},{"title":"View user","openapi":"GET /apps/{app_id}/users/by/{alias_label}/{alias_id}","href":"/reference/view-user"},{"title":"Update user","openapi":"PATCH /apps/{app_id}/users/by/{alias_label}/{alias_id}","href":"/reference/update-user"},{"title":"Delete user","openapi":"DELETE /apps/{app_id}/users/by/{alias_label}/{alias_id}","href":"/reference/delete-user"},{"title":"View user identity","openapi":"GET /apps/{app_id}/users/by/{alias_label}/{alias_id}/identity","href":"/reference/fetch-aliases"},{"title":"View user identity (by subscription)","openapi":"GET /apps/{app_id}/subscriptions/{subscription_id}/user/identity","href":"/reference/fetch-identity-by-subscription"},{"title":"Create or update alias","openapi":"PATCH /apps/{app_id}/users/by/{alias_label}/{alias_id}/identity","href":"/reference/create-alias"},{"title":"Create alias (by subscription)","openapi":"PATCH /apps/{app_id}/subscriptions/{subscription_id}/user/identity","href":"/reference/create-alias-by-subscription"},{"title":"Delete alias","openapi":"DELETE /apps/{app_id}/users/by/{alias_label}/{alias_id}/identity/{alias_label_to_delete}","href":"/reference/delete-alias"}]},{"group":"Subscriptions","pages":[{"title":"Create Subscription by alias","openapi":"POST /apps/{app_id}/users/by/{alias_label}/{alias_id}/subscriptions","href":"/reference/create-subscription"},{"title":"Update Subscription by ID","openapi":"PATCH /apps/{app_id}/subscriptions/{subscription_id}","href":"/reference/update-subscription"},{"title":"Update Subscription by token","openapi":"PATCH /apps/{app_id}/subscriptions_by_token/{token_type}/{token}","href":"/reference/update-subscription-by-token"},{"title":"Delete Subscription","openapi":"DELETE /apps/{app_id}/subscriptions/{subscription_id}","href":"/reference/delete-subscription"},{"title":"Transfer Subscription","openapi":"PATCH /apps/{app_id}/subscriptions/{subscription_id}/owner","href":"/reference/transfer-subscription"},{"title":"Unsubscribe email with token","openapi":"POST /apps/{app_id}/notifications/{notification_id}/unsubscribe?token={token}","href":"/reference/unsubscribe-with-token"}]},{"group":"Templates","pages":[{"title":"Create template","openapi":"POST /templates","href":"/reference/create-template"},{"title":"Update template","openapi":"PATCH /templates/{template_id}?app_id={app_id}","href":"/reference/update-template"},{"title":"View templates","openapi":"GET /templates?app_id={app_id}\u0026limit={limit}\u0026offset={offset}","href":"/reference/view-templates"},{"title":"View template","openapi":"GET /templates/{template_id}?app_id={app_id}","href":"/reference/view-template"},{"title":"Delete template","openapi":"DELETE /templates/{template_id}?app_id={app_id}","href":"/reference/delete-template"},{"title":"Copy template to another app","openapi":"POST /templates/{template_id}/copy_to_app?app_id={app_id}","href":"/reference/copy-template-to-another-app"}]},{"group":"Segments","pages":[{"title":"View segments","openapi":"GET /apps/{app_id}/segments","href":"/reference/view-segments"},{"title":"View segment","openapi":"GET /apps/{app_id}/segments/{segment_id}","href":"/reference/view-segment"},{"title":"Create segment","openapi":"POST /apps/{app_id}/segments","href":"/reference/create-segments"},{"title":"Update segment","openapi":"PATCH /apps/{app_id}/segments/{segment_id}","href":"/reference/update-segment"},{"title":"Delete segment","openapi":"DELETE /apps/{app_id}/segments/{segment_id}","href":"/reference/delete-segments"}]},{"group":"Journeys","pages":[{"title":"View journeys","tag":"BETA","openapi":"GET /apps/{app_id}/journeys","href":"/reference/view-journeys"},{"title":"View journey","tag":"BETA","openapi":"GET /apps/{app_id}/journeys/{id}","href":"/reference/view-journey"},{"title":"View journey stats","tag":"BETA","openapi":"GET /apps/{app_id}/journeys/{id}/stats","description":"Retrieve performance stats for a single journey, including journey-level counts, per-node counts, per-branch counts, and channel delivery stats.","href":"/reference/view-journey-stats"},{"title":"Create journey","tag":"BETA","openapi":"POST /apps/{app_id}/journeys","href":"/reference/create-journey"},{"title":"Duplicate journey","tag":"BETA","openapi":"POST /apps/{app_id}/journeys/{id}/duplicate","description":"Copy an existing journey into a new draft. You can apply overrides to the copy in the same request.","href":"/reference/duplicate-journey"},{"title":"Update journey","tag":"BETA","openapi":"PATCH /apps/{app_id}/journeys/{id}","href":"/reference/update-journey"},{"title":"Update journey node","tag":"BETA","openapi":"PATCH /apps/{app_id}/journeys/{id}/nodes/{node_id}","href":"/reference/update-journey-node"},{"title":"Delete journey","tag":"BETA","openapi":"DELETE /apps/{app_id}/journeys/{id}","href":"/reference/delete-journey"}]},{"group":"Configuration","pages":[{"title":"View apps","openapi":"GET /apps","href":"/reference/view-apps"},{"title":"View an app","openapi":"GET /apps/{app_id}","href":"/reference/view-an-app"},{"title":"Create an app","openapi":"POST /apps","href":"/reference/create-an-app"},{"title":"Update an app","openapi":"PUT /apps/{app_id}","href":"/reference/update-an-app"},{"title":"View API keys","openapi":"GET /apps/{app_id}/auth/tokens","href":"/reference/view-api-keys"},{"title":"Create API key","openapi":"POST /apps/{app_id}/auth/tokens","href":"/reference/create-api-key"},{"title":"Delete API key","openapi":"DELETE /apps/{app_id}/auth/tokens/{token_id}","href":"/reference/delete-api-key"},{"title":"Update API key","openapi":"PATCH /apps/{app_id}/auth/tokens/{token_id}","href":"/reference/update-api-key"},{"title":"Rotate API key","openapi":"POST /apps/{app_id}/auth/tokens/{token_id}/rotate","href":"/reference/rotate-api-key"}]},{"group":"Analytics","pages":[{"title":"Export subscriptions CSV","openapi":"POST /players/csv_export","href":"/reference/csv-export"},{"title":"Export audience activity CSV","openapi":"POST /notifications/{message_id}/export_events","href":"/reference/export-csv-of-events"},{"title":"View outcomes","openapi":"GET /apps/{app_id}/outcomes?outcome_names={outcome_names}\u0026outcome_time_range={outcome_time_range}\u0026outcome_platforms={outcome_platforms}\u0026outcome_attribution={outcome_attribution}","href":"/reference/view-outcomes"}]},{"group":"Deprecated","pages":[{"title":"View players","deprecated":true,"href":"/reference/view-devices"},{"title":"View player","deprecated":true,"href":"/reference/view-device"},{"title":"Add a player","deprecated":true,"href":"/reference/add-a-device"},{"title":"Edit player","deprecated":true,"href":"/reference/edit-device"},{"title":"Edit tags with external user id","deprecated":true,"href":"/reference/edit-tags-with-external-user-id"},{"title":"Delete player record","deprecated":true,"href":"/reference/delete-user-record"}]}]},{"group":"SDKs","pages":[{"title":"Server SDK reference","href":"/docs/en/server-sdk-reference"}]}]},{"tab":"Release Notes","pages":[{"title":"Release Notes","href":"/release-notes/changelog"}]}],"global":{"anchors":[{"anchor":"Blog","icon":"newspaper","href":"https://onesignal.com/blog"},{"anchor":"GitHub","icon":"github","href":"https://github.com/OneSignal"},{"anchor":"YouTube","icon":"youtube","href":"https://www.youtube.com/@onesignalofficial/playlists"}]}},{"language":"tr","tabs":[{"tab":"Ana Sayfa","pages":[{"title":"Ana Sayfa","href":"/docs/tr/home"}]},{"tab":"Kullanıcı Kılavuzları","pages":[{"title":"Kullanıcı Kılavuzları","href":"/docs/tr/quickstart-guide"}]},{"tab":"Geliştirici Kılavuzları","pages":[{"title":"Geliştirici Kılavuzları","href":"/docs/tr/developers"}]},{"tab":"Eğitimler","pages":[{"title":"Eğitimler","href":"/docs/tr/tutorials"}]},{"tab":"API Reference","groups":[{"group":"Using the REST APIs","pages":[{"title":"REST API overview","href":"/reference/rest-api-overview"},{"title":"Rate limits and error handling","href":"/reference/rate-limits"}]},{"group":"API reference","pages":[{"group":"Messages","pages":[{"title":"Sending messages with the OneSignal API","href":"/reference/create-message"},{"title":"Idempotent API requests","href":"/reference/idempotent-notification-requests"},{"title":"Push notification","openapi":"POST /notifications?c=push","href":"/reference/push-notification"},{"title":"Email","openapi":"POST /notifications?c=email","href":"/reference/email"},{"title":"SMS","openapi":"POST /notifications?c=sms","href":"/reference/sms"},{"title":"View message","openapi":"GET /notifications/{message_id}?app_id={app_id}","href":"/reference/view-message"},{"title":"View messages","openapi":"GET /notifications?app_id={app_id}\u0026limit={limit}\u0026offset={offset}\u0026kind={kind}\u0026template_id={template_id}\u0026time_offset={time_offset}","href":"/reference/view-messages"},{"title":"Cancel message","openapi":"DELETE /notifications/{message_id}?app_id={app_id}","href":"/reference/cancel-message"},{"title":"Message history","openapi":"POST /notifications/{message_id}/history","href":"/reference/message-history"},{"title":"Estimated recipients","openapi":"POST /notifications/count-unsaved","href":"/reference/count-unsaved"}]},{"group":"Live Activities","pages":[{"title":"Start Live Activity","openapi":"POST /apps/{app_id}/activities/activity/{activity_type}","href":"/reference/start-live-activity"},{"title":"Update Live Activity","openapi":"POST /apps/{app_id}/live_activities/{activity_id}/notifications","href":"/reference/update-live-activity-api"}]},{"group":"Custom Events","pages":[{"title":"Create custom events","openapi":"POST /apps/{app_id}/custom_events","href":"/reference/create-custom-events"}]},{"group":"Users","pages":[{"title":"Create user","openapi":"POST /apps/{app_id}/users","href":"/reference/create-user"},{"title":"View user","openapi":"GET /apps/{app_id}/users/by/{alias_label}/{alias_id}","href":"/reference/view-user"},{"title":"Update user","openapi":"PATCH /apps/{app_id}/users/by/{alias_label}/{alias_id}","href":"/reference/update-user"},{"title":"Delete user","openapi":"DELETE /apps/{app_id}/users/by/{alias_label}/{alias_id}","href":"/reference/delete-user"},{"title":"View user identity","openapi":"GET /apps/{app_id}/users/by/{alias_label}/{alias_id}/identity","href":"/reference/fetch-aliases"},{"title":"View user identity (by subscription)","openapi":"GET /apps/{app_id}/subscriptions/{subscription_id}/user/identity","href":"/reference/fetch-identity-by-subscription"},{"title":"Create or update alias","openapi":"PATCH /apps/{app_id}/users/by/{alias_label}/{alias_id}/identity","href":"/reference/create-alias"},{"title":"Create alias (by subscription)","openapi":"PATCH /apps/{app_id}/subscriptions/{subscription_id}/user/identity","href":"/reference/create-alias-by-subscription"},{"title":"Delete alias","openapi":"DELETE /apps/{app_id}/users/by/{alias_label}/{alias_id}/identity/{alias_label_to_delete}","href":"/reference/delete-alias"}]},{"group":"Subscriptions","pages":[{"title":"Create Subscription by alias","openapi":"POST /apps/{app_id}/users/by/{alias_label}/{alias_id}/subscriptions","href":"/reference/create-subscription"},{"title":"Update Subscription by ID","openapi":"PATCH /apps/{app_id}/subscriptions/{subscription_id}","href":"/reference/update-subscription"},{"title":"Update Subscription by token","openapi":"PATCH /apps/{app_id}/subscriptions_by_token/{token_type}/{token}","href":"/reference/update-subscription-by-token"},{"title":"Delete Subscription","openapi":"DELETE /apps/{app_id}/subscriptions/{subscription_id}","href":"/reference/delete-subscription"},{"title":"Transfer Subscription","openapi":"PATCH /apps/{app_id}/subscriptions/{subscription_id}/owner","href":"/reference/transfer-subscription"},{"title":"Unsubscribe email with token","openapi":"POST /apps/{app_id}/notifications/{notification_id}/unsubscribe?token={token}","href":"/reference/unsubscribe-with-token"}]},{"group":"Templates","pages":[{"title":"Create template","openapi":"POST /templates","href":"/reference/create-template"},{"title":"Update template","openapi":"PATCH /templates/{template_id}?app_id={app_id}","href":"/reference/update-template"},{"title":"View templates","openapi":"GET /templates?app_id={app_id}\u0026limit={limit}\u0026offset={offset}","href":"/reference/view-templates"},{"title":"View template","openapi":"GET /templates/{template_id}?app_id={app_id}","href":"/reference/view-template"},{"title":"Delete template","openapi":"DELETE /templates/{template_id}?app_id={app_id}","href":"/reference/delete-template"},{"title":"Copy template to another app","openapi":"POST /templates/{template_id}/copy_to_app?app_id={app_id}","href":"/reference/copy-template-to-another-app"}]},{"group":"Segments","pages":[{"title":"View segments","openapi":"GET /apps/{app_id}/segments","href":"/reference/view-segments"},{"title":"View segment","openapi":"GET /apps/{app_id}/segments/{segment_id}","href":"/reference/view-segment"},{"title":"Create segment","openapi":"POST /apps/{app_id}/segments","href":"/reference/create-segments"},{"title":"Update segment","openapi":"PATCH /apps/{app_id}/segments/{segment_id}","href":"/reference/update-segment"},{"title":"Delete segment","openapi":"DELETE /apps/{app_id}/segments/{segment_id}","href":"/reference/delete-segments"}]},{"group":"Journeys","pages":[{"title":"View journeys","tag":"BETA","openapi":"GET /apps/{app_id}/journeys","href":"/reference/view-journeys"},{"title":"View journey","tag":"BETA","openapi":"GET /apps/{app_id}/journeys/{id}","href":"/reference/view-journey"},{"title":"View journey stats","tag":"BETA","openapi":"GET /apps/{app_id}/journeys/{id}/stats","description":"Retrieve performance stats for a single journey, including journey-level counts, per-node counts, per-branch counts, and channel delivery stats.","href":"/reference/view-journey-stats"},{"title":"Create journey","tag":"BETA","openapi":"POST /apps/{app_id}/journeys","href":"/reference/create-journey"},{"title":"Duplicate journey","tag":"BETA","openapi":"POST /apps/{app_id}/journeys/{id}/duplicate","description":"Copy an existing journey into a new draft. You can apply overrides to the copy in the same request.","href":"/reference/duplicate-journey"},{"title":"Update journey","tag":"BETA","openapi":"PATCH /apps/{app_id}/journeys/{id}","href":"/reference/update-journey"},{"title":"Update journey node","tag":"BETA","openapi":"PATCH /apps/{app_id}/journeys/{id}/nodes/{node_id}","href":"/reference/update-journey-node"},{"title":"Delete journey","tag":"BETA","openapi":"DELETE /apps/{app_id}/journeys/{id}","href":"/reference/delete-journey"}]},{"group":"Configuration","pages":[{"title":"View apps","openapi":"GET /apps","href":"/reference/view-apps"},{"title":"View an app","openapi":"GET /apps/{app_id}","href":"/reference/view-an-app"},{"title":"Create an app","openapi":"POST /apps","href":"/reference/create-an-app"},{"title":"Update an app","openapi":"PUT /apps/{app_id}","href":"/reference/update-an-app"},{"title":"View API keys","openapi":"GET /apps/{app_id}/auth/tokens","href":"/reference/view-api-keys"},{"title":"Create API key","openapi":"POST /apps/{app_id}/auth/tokens","href":"/reference/create-api-key"},{"title":"Delete API key","openapi":"DELETE /apps/{app_id}/auth/tokens/{token_id}","href":"/reference/delete-api-key"},{"title":"Update API key","openapi":"PATCH /apps/{app_id}/auth/tokens/{token_id}","href":"/reference/update-api-key"},{"title":"Rotate API key","openapi":"POST /apps/{app_id}/auth/tokens/{token_id}/rotate","href":"/reference/rotate-api-key"}]},{"group":"Analytics","pages":[{"title":"Export subscriptions CSV","openapi":"POST /players/csv_export","href":"/reference/csv-export"},{"title":"Export audience activity CSV","openapi":"POST /notifications/{message_id}/export_events","href":"/reference/export-csv-of-events"},{"title":"View outcomes","openapi":"GET /apps/{app_id}/outcomes?outcome_names={outcome_names}\u0026outcome_time_range={outcome_time_range}\u0026outcome_platforms={outcome_platforms}\u0026outcome_attribution={outcome_attribution}","href":"/reference/view-outcomes"}]},{"group":"Deprecated","pages":[{"title":"View players","deprecated":true,"href":"/reference/view-devices"},{"title":"View player","deprecated":true,"href":"/reference/view-device"},{"title":"Add a player","deprecated":true,"href":"/reference/add-a-device"},{"title":"Edit player","deprecated":true,"href":"/reference/edit-device"},{"title":"Edit tags with external user id","deprecated":true,"href":"/reference/edit-tags-with-external-user-id"},{"title":"Delete player record","deprecated":true,"href":"/reference/delete-user-record"}]}]},{"group":"SDKs","pages":[{"title":"Server SDK reference","href":"/docs/en/server-sdk-reference"}]}]},{"tab":"Release Notes","pages":[{"title":"Release Notes","href":"/release-notes/changelog"}]}],"global":{"anchors":[{"anchor":"Blog","icon":"newspaper","href":"https://onesignal.com/blog"},{"anchor":"GitHub","icon":"github","href":"https://github.com/OneSignal"},{"anchor":"YouTube","icon":"youtube","href":"https://www.youtube.com/@onesignalofficial/playlists"}]}},{"language":"pt-BR","tabs":[{"tab":"Início","pages":[{"title":"Início","href":"/docs/pt-BR/home"}]},{"tab":"Guia do Usuário","pages":[{"title":"Guia do Usuário","href":"/docs/pt-BR/quickstart-guide"}]},{"tab":"Guia de desenvolvedor","pages":[{"title":"Guia de desenvolvedor","href":"/docs/pt-BR/developers"}]},{"tab":"Tutoriais","pages":[{"title":"Tutoriais","href":"/docs/pt-BR/tutorials"}]},{"tab":"API Reference","groups":[{"group":"Using the REST APIs","pages":[{"title":"REST API overview","href":"/reference/rest-api-overview"},{"title":"Rate limits and error handling","href":"/reference/rate-limits"}]},{"group":"API reference","pages":[{"group":"Messages","pages":[{"title":"Sending messages with the OneSignal API","href":"/reference/create-message"},{"title":"Idempotent API requests","href":"/reference/idempotent-notification-requests"},{"title":"Push notification","openapi":"POST /notifications?c=push","href":"/reference/push-notification"},{"title":"Email","openapi":"POST /notifications?c=email","href":"/reference/email"},{"title":"SMS","openapi":"POST /notifications?c=sms","href":"/reference/sms"},{"title":"View message","openapi":"GET /notifications/{message_id}?app_id={app_id}","href":"/reference/view-message"},{"title":"View messages","openapi":"GET /notifications?app_id={app_id}\u0026limit={limit}\u0026offset={offset}\u0026kind={kind}\u0026template_id={template_id}\u0026time_offset={time_offset}","href":"/reference/view-messages"},{"title":"Cancel message","openapi":"DELETE /notifications/{message_id}?app_id={app_id}","href":"/reference/cancel-message"},{"title":"Message history","openapi":"POST /notifications/{message_id}/history","href":"/reference/message-history"},{"title":"Estimated recipients","openapi":"POST /notifications/count-unsaved","href":"/reference/count-unsaved"}]},{"group":"Live Activities","pages":[{"title":"Start Live Activity","openapi":"POST /apps/{app_id}/activities/activity/{activity_type}","href":"/reference/start-live-activity"},{"title":"Update Live Activity","openapi":"POST /apps/{app_id}/live_activities/{activity_id}/notifications","href":"/reference/update-live-activity-api"}]},{"group":"Custom Events","pages":[{"title":"Create custom events","openapi":"POST /apps/{app_id}/custom_events","href":"/reference/create-custom-events"}]},{"group":"Users","pages":[{"title":"Create user","openapi":"POST /apps/{app_id}/users","href":"/reference/create-user"},{"title":"View user","openapi":"GET /apps/{app_id}/users/by/{alias_label}/{alias_id}","href":"/reference/view-user"},{"title":"Update user","openapi":"PATCH /apps/{app_id}/users/by/{alias_label}/{alias_id}","href":"/reference/update-user"},{"title":"Delete user","openapi":"DELETE /apps/{app_id}/users/by/{alias_label}/{alias_id}","href":"/reference/delete-user"},{"title":"View user identity","openapi":"GET /apps/{app_id}/users/by/{alias_label}/{alias_id}/identity","href":"/reference/fetch-aliases"},{"title":"View user identity (by subscription)","openapi":"GET /apps/{app_id}/subscriptions/{subscription_id}/user/identity","href":"/reference/fetch-identity-by-subscription"},{"title":"Create or update alias","openapi":"PATCH /apps/{app_id}/users/by/{alias_label}/{alias_id}/identity","href":"/reference/create-alias"},{"title":"Create alias (by subscription)","openapi":"PATCH /apps/{app_id}/subscriptions/{subscription_id}/user/identity","href":"/reference/create-alias-by-subscription"},{"title":"Delete alias","openapi":"DELETE /apps/{app_id}/users/by/{alias_label}/{alias_id}/identity/{alias_label_to_delete}","href":"/reference/delete-alias"}]},{"group":"Subscriptions","pages":[{"title":"Create Subscription by alias","openapi":"POST /apps/{app_id}/users/by/{alias_label}/{alias_id}/subscriptions","href":"/reference/create-subscription"},{"title":"Update Subscription by ID","openapi":"PATCH /apps/{app_id}/subscriptions/{subscription_id}","href":"/reference/update-subscription"},{"title":"Update Subscription by token","openapi":"PATCH /apps/{app_id}/subscriptions_by_token/{token_type}/{token}","href":"/reference/update-subscription-by-token"},{"title":"Delete Subscription","openapi":"DELETE /apps/{app_id}/subscriptions/{subscription_id}","href":"/reference/delete-subscription"},{"title":"Transfer Subscription","openapi":"PATCH /apps/{app_id}/subscriptions/{subscription_id}/owner","href":"/reference/transfer-subscription"},{"title":"Unsubscribe email with token","openapi":"POST /apps/{app_id}/notifications/{notification_id}/unsubscribe?token={token}","href":"/reference/unsubscribe-with-token"}]},{"group":"Templates","pages":[{"title":"Create template","openapi":"POST /templates","href":"/reference/create-template"},{"title":"Update template","openapi":"PATCH /templates/{template_id}?app_id={app_id}","href":"/reference/update-template"},{"title":"View templates","openapi":"GET /templates?app_id={app_id}\u0026limit={limit}\u0026offset={offset}","href":"/reference/view-templates"},{"title":"View template","openapi":"GET /templates/{template_id}?app_id={app_id}","href":"/reference/view-template"},{"title":"Delete template","openapi":"DELETE /templates/{template_id}?app_id={app_id}","href":"/reference/delete-template"},{"title":"Copy template to another app","openapi":"POST /templates/{template_id}/copy_to_app?app_id={app_id}","href":"/reference/copy-template-to-another-app"}]},{"group":"Segments","pages":[{"title":"View segments","openapi":"GET /apps/{app_id}/segments","href":"/reference/view-segments"},{"title":"View segment","openapi":"GET /apps/{app_id}/segments/{segment_id}","href":"/reference/view-segment"},{"title":"Create segment","openapi":"POST /apps/{app_id}/segments","href":"/reference/create-segments"},{"title":"Update segment","openapi":"PATCH /apps/{app_id}/segments/{segment_id}","href":"/reference/update-segment"},{"title":"Delete segment","openapi":"DELETE /apps/{app_id}/segments/{segment_id}","href":"/reference/delete-segments"}]},{"group":"Journeys","pages":[{"title":"View journeys","tag":"BETA","openapi":"GET /apps/{app_id}/journeys","href":"/reference/view-journeys"},{"title":"View journey","tag":"BETA","openapi":"GET /apps/{app_id}/journeys/{id}","href":"/reference/view-journey"},{"title":"View journey stats","tag":"BETA","openapi":"GET /apps/{app_id}/journeys/{id}/stats","description":"Retrieve performance stats for a single journey, including journey-level counts, per-node counts, per-branch counts, and channel delivery stats.","href":"/reference/view-journey-stats"},{"title":"Create journey","tag":"BETA","openapi":"POST /apps/{app_id}/journeys","href":"/reference/create-journey"},{"title":"Duplicate journey","tag":"BETA","openapi":"POST /apps/{app_id}/journeys/{id}/duplicate","description":"Copy an existing journey into a new draft. You can apply overrides to the copy in the same request.","href":"/reference/duplicate-journey"},{"title":"Update journey","tag":"BETA","openapi":"PATCH /apps/{app_id}/journeys/{id}","href":"/reference/update-journey"},{"title":"Update journey node","tag":"BETA","openapi":"PATCH /apps/{app_id}/journeys/{id}/nodes/{node_id}","href":"/reference/update-journey-node"},{"title":"Delete journey","tag":"BETA","openapi":"DELETE /apps/{app_id}/journeys/{id}","href":"/reference/delete-journey"}]},{"group":"Configuration","pages":[{"title":"View apps","openapi":"GET /apps","href":"/reference/view-apps"},{"title":"View an app","openapi":"GET /apps/{app_id}","href":"/reference/view-an-app"},{"title":"Create an app","openapi":"POST /apps","href":"/reference/create-an-app"},{"title":"Update an app","openapi":"PUT /apps/{app_id}","href":"/reference/update-an-app"},{"title":"View API keys","openapi":"GET /apps/{app_id}/auth/tokens","href":"/reference/view-api-keys"},{"title":"Create API key","openapi":"POST /apps/{app_id}/auth/tokens","href":"/reference/create-api-key"},{"title":"Delete API key","openapi":"DELETE /apps/{app_id}/auth/tokens/{token_id}","href":"/reference/delete-api-key"},{"title":"Update API key","openapi":"PATCH /apps/{app_id}/auth/tokens/{token_id}","href":"/reference/update-api-key"},{"title":"Rotate API key","openapi":"POST /apps/{app_id}/auth/tokens/{token_id}/rotate","href":"/reference/rotate-api-key"}]},{"group":"Analytics","pages":[{"title":"Export subscriptions CSV","openapi":"POST /players/csv_export","href":"/reference/csv-export"},{"title":"Export audience activity CSV","openapi":"POST /notifications/{message_id}/export_events","href":"/reference/export-csv-of-events"},{"title":"View outcomes","openapi":"GET /apps/{app_id}/outcomes?outcome_names={outcome_names}\u0026outcome_time_range={outcome_time_range}\u0026outcome_platforms={outcome_platforms}\u0026outcome_attribution={outcome_attribution}","href":"/reference/view-outcomes"}]},{"group":"Deprecated","pages":[{"title":"View players","deprecated":true,"href":"/reference/view-devices"},{"title":"View player","deprecated":true,"href":"/reference/view-device"},{"title":"Add a player","deprecated":true,"href":"/reference/add-a-device"},{"title":"Edit player","deprecated":true,"href":"/reference/edit-device"},{"title":"Edit tags with external user id","deprecated":true,"href":"/reference/edit-tags-with-external-user-id"},{"title":"Delete player record","deprecated":true,"href":"/reference/delete-user-record"}]}]},{"group":"SDKs","pages":[{"title":"Referência do SDK do Servidor","href":"/docs/pt-BR/server-sdk-reference"}]}]},{"tab":"Release Notes","pages":[{"title":"Release Notes","href":"/release-notes/changelog"}]}],"global":{"anchors":[{"anchor":"Blog","icon":"newspaper","href":"https://onesignal.com/blog"},{"anchor":"GitHub","icon":"github","href":"https://github.com/OneSignal"},{"anchor":"YouTube","icon":"youtube","href":"https://www.youtube.com/@onesignalofficial/playlists"}]}},{"language":"es","tabs":[{"tab":"Inicio","pages":[{"title":"Inicio","href":"/docs/es/home"}]},{"tab":"Guías del Usuario","pages":[{"title":"Guías del Usuario","href":"/docs/es/quickstart-guide"}]},{"tab":"Guías del desarrollador","pages":[{"title":"Guías del desarrollador","href":"/docs/es/developers"}]},{"tab":"Tutoriales","pages":[{"title":"Tutoriales","href":"/docs/es/tutorials"}]},{"tab":"API Reference","groups":[{"group":"Using the REST APIs","pages":[{"title":"REST API overview","href":"/reference/rest-api-overview"},{"title":"Rate limits and error handling","href":"/reference/rate-limits"}]},{"group":"API reference","pages":[{"group":"Messages","pages":[{"title":"Sending messages with the OneSignal API","href":"/reference/create-message"},{"title":"Idempotent API requests","href":"/reference/idempotent-notification-requests"},{"title":"Push notification","openapi":"POST /notifications?c=push","href":"/reference/push-notification"},{"title":"Email","openapi":"POST /notifications?c=email","href":"/reference/email"},{"title":"SMS","openapi":"POST /notifications?c=sms","href":"/reference/sms"},{"title":"View message","openapi":"GET /notifications/{message_id}?app_id={app_id}","href":"/reference/view-message"},{"title":"View messages","openapi":"GET /notifications?app_id={app_id}\u0026limit={limit}\u0026offset={offset}\u0026kind={kind}\u0026template_id={template_id}\u0026time_offset={time_offset}","href":"/reference/view-messages"},{"title":"Cancel message","openapi":"DELETE /notifications/{message_id}?app_id={app_id}","href":"/reference/cancel-message"},{"title":"Message history","openapi":"POST /notifications/{message_id}/history","href":"/reference/message-history"},{"title":"Estimated recipients","openapi":"POST /notifications/count-unsaved","href":"/reference/count-unsaved"}]},{"group":"Live Activities","pages":[{"title":"Start Live Activity","openapi":"POST /apps/{app_id}/activities/activity/{activity_type}","href":"/reference/start-live-activity"},{"title":"Update Live Activity","openapi":"POST /apps/{app_id}/live_activities/{activity_id}/notifications","href":"/reference/update-live-activity-api"}]},{"group":"Custom Events","pages":[{"title":"Create custom events","openapi":"POST /apps/{app_id}/custom_events","href":"/reference/create-custom-events"}]},{"group":"Users","pages":[{"title":"Create user","openapi":"POST /apps/{app_id}/users","href":"/reference/create-user"},{"title":"View user","openapi":"GET /apps/{app_id}/users/by/{alias_label}/{alias_id}","href":"/reference/view-user"},{"title":"Update user","openapi":"PATCH /apps/{app_id}/users/by/{alias_label}/{alias_id}","href":"/reference/update-user"},{"title":"Delete user","openapi":"DELETE /apps/{app_id}/users/by/{alias_label}/{alias_id}","href":"/reference/delete-user"},{"title":"View user identity","openapi":"GET /apps/{app_id}/users/by/{alias_label}/{alias_id}/identity","href":"/reference/fetch-aliases"},{"title":"View user identity (by subscription)","openapi":"GET /apps/{app_id}/subscriptions/{subscription_id}/user/identity","href":"/reference/fetch-identity-by-subscription"},{"title":"Create or update alias","openapi":"PATCH /apps/{app_id}/users/by/{alias_label}/{alias_id}/identity","href":"/reference/create-alias"},{"title":"Create alias (by subscription)","openapi":"PATCH /apps/{app_id}/subscriptions/{subscription_id}/user/identity","href":"/reference/create-alias-by-subscription"},{"title":"Delete alias","openapi":"DELETE /apps/{app_id}/users/by/{alias_label}/{alias_id}/identity/{alias_label_to_delete}","href":"/reference/delete-alias"}]},{"group":"Subscriptions","pages":[{"title":"Create Subscription by alias","openapi":"POST /apps/{app_id}/users/by/{alias_label}/{alias_id}/subscriptions","href":"/reference/create-subscription"},{"title":"Update Subscription by ID","openapi":"PATCH /apps/{app_id}/subscriptions/{subscription_id}","href":"/reference/update-subscription"},{"title":"Update Subscription by token","openapi":"PATCH /apps/{app_id}/subscriptions_by_token/{token_type}/{token}","href":"/reference/update-subscription-by-token"},{"title":"Delete Subscription","openapi":"DELETE /apps/{app_id}/subscriptions/{subscription_id}","href":"/reference/delete-subscription"},{"title":"Transfer Subscription","openapi":"PATCH /apps/{app_id}/subscriptions/{subscription_id}/owner","href":"/reference/transfer-subscription"},{"title":"Unsubscribe email with token","openapi":"POST /apps/{app_id}/notifications/{notification_id}/unsubscribe?token={token}","href":"/reference/unsubscribe-with-token"}]},{"group":"Templates","pages":[{"title":"Create template","openapi":"POST /templates","href":"/reference/create-template"},{"title":"Update template","openapi":"PATCH /templates/{template_id}?app_id={app_id}","href":"/reference/update-template"},{"title":"View templates","openapi":"GET /templates?app_id={app_id}\u0026limit={limit}\u0026offset={offset}","href":"/reference/view-templates"},{"title":"View template","openapi":"GET /templates/{template_id}?app_id={app_id}","href":"/reference/view-template"},{"title":"Delete template","openapi":"DELETE /templates/{template_id}?app_id={app_id}","href":"/reference/delete-template"},{"title":"Copy template to another app","openapi":"POST /templates/{template_id}/copy_to_app?app_id={app_id}","href":"/reference/copy-template-to-another-app"}]},{"group":"Segments","pages":[{"title":"View segments","openapi":"GET /apps/{app_id}/segments","href":"/reference/view-segments"},{"title":"View segment","openapi":"GET /apps/{app_id}/segments/{segment_id}","href":"/reference/view-segment"},{"title":"Create segment","openapi":"POST /apps/{app_id}/segments","href":"/reference/create-segments"},{"title":"Update segment","openapi":"PATCH /apps/{app_id}/segments/{segment_id}","href":"/reference/update-segment"},{"title":"Delete segment","openapi":"DELETE /apps/{app_id}/segments/{segment_id}","href":"/reference/delete-segments"}]},{"group":"Journeys","pages":[{"title":"View journeys","tag":"BETA","openapi":"GET /apps/{app_id}/journeys","href":"/reference/view-journeys"},{"title":"View journey","tag":"BETA","openapi":"GET /apps/{app_id}/journeys/{id}","href":"/reference/view-journey"},{"title":"View journey stats","tag":"BETA","openapi":"GET /apps/{app_id}/journeys/{id}/stats","description":"Retrieve performance stats for a single journey, including journey-level counts, per-node counts, per-branch counts, and channel delivery stats.","href":"/reference/view-journey-stats"},{"title":"Create journey","tag":"BETA","openapi":"POST /apps/{app_id}/journeys","href":"/reference/create-journey"},{"title":"Duplicate journey","tag":"BETA","openapi":"POST /apps/{app_id}/journeys/{id}/duplicate","description":"Copy an existing journey into a new draft. You can apply overrides to the copy in the same request.","href":"/reference/duplicate-journey"},{"title":"Update journey","tag":"BETA","openapi":"PATCH /apps/{app_id}/journeys/{id}","href":"/reference/update-journey"},{"title":"Update journey node","tag":"BETA","openapi":"PATCH /apps/{app_id}/journeys/{id}/nodes/{node_id}","href":"/reference/update-journey-node"},{"title":"Delete journey","tag":"BETA","openapi":"DELETE /apps/{app_id}/journeys/{id}","href":"/reference/delete-journey"}]},{"group":"Configuration","pages":[{"title":"View apps","openapi":"GET /apps","href":"/reference/view-apps"},{"title":"View an app","openapi":"GET /apps/{app_id}","href":"/reference/view-an-app"},{"title":"Create an app","openapi":"POST /apps","href":"/reference/create-an-app"},{"title":"Update an app","openapi":"PUT /apps/{app_id}","href":"/reference/update-an-app"},{"title":"View API keys","openapi":"GET /apps/{app_id}/auth/tokens","href":"/reference/view-api-keys"},{"title":"Create API key","openapi":"POST /apps/{app_id}/auth/tokens","href":"/reference/create-api-key"},{"title":"Delete API key","openapi":"DELETE /apps/{app_id}/auth/tokens/{token_id}","href":"/reference/delete-api-key"},{"title":"Update API key","openapi":"PATCH /apps/{app_id}/auth/tokens/{token_id}","href":"/reference/update-api-key"},{"title":"Rotate API key","openapi":"POST /apps/{app_id}/auth/tokens/{token_id}/rotate","href":"/reference/rotate-api-key"}]},{"group":"Analytics","pages":[{"title":"Export subscriptions CSV","openapi":"POST /players/csv_export","href":"/reference/csv-export"},{"title":"Export audience activity CSV","openapi":"POST /notifications/{message_id}/export_events","href":"/reference/export-csv-of-events"},{"title":"View outcomes","openapi":"GET /apps/{app_id}/outcomes?outcome_names={outcome_names}\u0026outcome_time_range={outcome_time_range}\u0026outcome_platforms={outcome_platforms}\u0026outcome_attribution={outcome_attribution}","href":"/reference/view-outcomes"}]},{"group":"Deprecated","pages":[{"title":"View players","deprecated":true,"href":"/reference/view-devices"},{"title":"View player","deprecated":true,"href":"/reference/view-device"},{"title":"Add a player","deprecated":true,"href":"/reference/add-a-device"},{"title":"Edit player","deprecated":true,"href":"/reference/edit-device"},{"title":"Edit tags with external user id","deprecated":true,"href":"/reference/edit-tags-with-external-user-id"},{"title":"Delete player record","deprecated":true,"href":"/reference/delete-user-record"}]}]},{"group":"SDKs","pages":[{"title":"Server SDK reference","href":"/docs/en/server-sdk-reference"}]}]},{"tab":"Release Notes","pages":[{"title":"Release Notes","href":"/release-notes/changelog"}]}],"global":{"anchors":[{"anchor":"Blog","icon":"newspaper","href":"https://onesignal.com/blog"},{"anchor":"GitHub","icon":"github","href":"https://github.com/OneSignal"},{"anchor":"YouTube","icon":"youtube","href":"https://www.youtube.com/@onesignalofficial/playlists"}]}},{"language":"fr","tabs":[{"tab":"Accueil","pages":[{"title":"Accueil","href":"/docs/fr/home"}]},{"tab":"Guides utilisateur","pages":[{"title":"Guides utilisateur","href":"/docs/fr/quickstart-guide"}]},{"tab":"Guides développeur","pages":[{"title":"Guides développeur","href":"/docs/fr/developers"}]},{"tab":"Tutoriels","pages":[{"title":"Tutoriels","href":"/docs/fr/tutorials"}]},{"tab":"API Reference","groups":[{"group":"Using the REST APIs","pages":[{"title":"REST API overview","href":"/reference/rest-api-overview"},{"title":"Rate limits and error handling","href":"/reference/rate-limits"}]},{"group":"API reference","pages":[{"group":"Messages","pages":[{"title":"Sending messages with the OneSignal API","href":"/reference/create-message"},{"title":"Idempotent API requests","href":"/reference/idempotent-notification-requests"},{"title":"Push notification","openapi":"POST /notifications?c=push","href":"/reference/push-notification"},{"title":"Email","openapi":"POST /notifications?c=email","href":"/reference/email"},{"title":"SMS","openapi":"POST /notifications?c=sms","href":"/reference/sms"},{"title":"View message","openapi":"GET /notifications/{message_id}?app_id={app_id}","href":"/reference/view-message"},{"title":"View messages","openapi":"GET /notifications?app_id={app_id}\u0026limit={limit}\u0026offset={offset}\u0026kind={kind}\u0026template_id={template_id}\u0026time_offset={time_offset}","href":"/reference/view-messages"},{"title":"Cancel message","openapi":"DELETE /notifications/{message_id}?app_id={app_id}","href":"/reference/cancel-message"},{"title":"Message history","openapi":"POST /notifications/{message_id}/history","href":"/reference/message-history"},{"title":"Estimated recipients","openapi":"POST /notifications/count-unsaved","href":"/reference/count-unsaved"}]},{"group":"Live Activities","pages":[{"title":"Start Live Activity","openapi":"POST /apps/{app_id}/activities/activity/{activity_type}","href":"/reference/start-live-activity"},{"title":"Update Live Activity","openapi":"POST /apps/{app_id}/live_activities/{activity_id}/notifications","href":"/reference/update-live-activity-api"}]},{"group":"Custom Events","pages":[{"title":"Create custom events","openapi":"POST /apps/{app_id}/custom_events","href":"/reference/create-custom-events"}]},{"group":"Users","pages":[{"title":"Create user","openapi":"POST /apps/{app_id}/users","href":"/reference/create-user"},{"title":"View user","openapi":"GET /apps/{app_id}/users/by/{alias_label}/{alias_id}","href":"/reference/view-user"},{"title":"Update user","openapi":"PATCH /apps/{app_id}/users/by/{alias_label}/{alias_id}","href":"/reference/update-user"},{"title":"Delete user","openapi":"DELETE /apps/{app_id}/users/by/{alias_label}/{alias_id}","href":"/reference/delete-user"},{"title":"View user identity","openapi":"GET /apps/{app_id}/users/by/{alias_label}/{alias_id}/identity","href":"/reference/fetch-aliases"},{"title":"View user identity (by subscription)","openapi":"GET /apps/{app_id}/subscriptions/{subscription_id}/user/identity","href":"/reference/fetch-identity-by-subscription"},{"title":"Create or update alias","openapi":"PATCH /apps/{app_id}/users/by/{alias_label}/{alias_id}/identity","href":"/reference/create-alias"},{"title":"Create alias (by subscription)","openapi":"PATCH /apps/{app_id}/subscriptions/{subscription_id}/user/identity","href":"/reference/create-alias-by-subscription"},{"title":"Delete alias","openapi":"DELETE /apps/{app_id}/users/by/{alias_label}/{alias_id}/identity/{alias_label_to_delete}","href":"/reference/delete-alias"}]},{"group":"Subscriptions","pages":[{"title":"Create Subscription by alias","openapi":"POST /apps/{app_id}/users/by/{alias_label}/{alias_id}/subscriptions","href":"/reference/create-subscription"},{"title":"Update Subscription by ID","openapi":"PATCH /apps/{app_id}/subscriptions/{subscription_id}","href":"/reference/update-subscription"},{"title":"Update Subscription by token","openapi":"PATCH /apps/{app_id}/subscriptions_by_token/{token_type}/{token}","href":"/reference/update-subscription-by-token"},{"title":"Delete Subscription","openapi":"DELETE /apps/{app_id}/subscriptions/{subscription_id}","href":"/reference/delete-subscription"},{"title":"Transfer Subscription","openapi":"PATCH /apps/{app_id}/subscriptions/{subscription_id}/owner","href":"/reference/transfer-subscription"},{"title":"Unsubscribe email with token","openapi":"POST /apps/{app_id}/notifications/{notification_id}/unsubscribe?token={token}","href":"/reference/unsubscribe-with-token"}]},{"group":"Templates","pages":[{"title":"Create template","openapi":"POST /templates","href":"/reference/create-template"},{"title":"Update template","openapi":"PATCH /templates/{template_id}?app_id={app_id}","href":"/reference/update-template"},{"title":"View templates","openapi":"GET /templates?app_id={app_id}\u0026limit={limit}\u0026offset={offset}","href":"/reference/view-templates"},{"title":"View template","openapi":"GET /templates/{template_id}?app_id={app_id}","href":"/reference/view-template"},{"title":"Delete template","openapi":"DELETE /templates/{template_id}?app_id={app_id}","href":"/reference/delete-template"},{"title":"Copy template to another app","openapi":"POST /templates/{template_id}/copy_to_app?app_id={app_id}","href":"/reference/copy-template-to-another-app"}]},{"group":"Segments","pages":[{"title":"View segments","openapi":"GET /apps/{app_id}/segments","href":"/reference/view-segments"},{"title":"View segment","openapi":"GET /apps/{app_id}/segments/{segment_id}","href":"/reference/view-segment"},{"title":"Create segment","openapi":"POST /apps/{app_id}/segments","href":"/reference/create-segments"},{"title":"Update segment","openapi":"PATCH /apps/{app_id}/segments/{segment_id}","href":"/reference/update-segment"},{"title":"Delete segment","openapi":"DELETE /apps/{app_id}/segments/{segment_id}","href":"/reference/delete-segments"}]},{"group":"Journeys","pages":[{"title":"View journeys","tag":"BETA","openapi":"GET /apps/{app_id}/journeys","href":"/reference/view-journeys"},{"title":"View journey","tag":"BETA","openapi":"GET /apps/{app_id}/journeys/{id}","href":"/reference/view-journey"},{"title":"View journey stats","tag":"BETA","openapi":"GET /apps/{app_id}/journeys/{id}/stats","description":"Retrieve performance stats for a single journey, including journey-level counts, per-node counts, per-branch counts, and channel delivery stats.","href":"/reference/view-journey-stats"},{"title":"Create journey","tag":"BETA","openapi":"POST /apps/{app_id}/journeys","href":"/reference/create-journey"},{"title":"Duplicate journey","tag":"BETA","openapi":"POST /apps/{app_id}/journeys/{id}/duplicate","description":"Copy an existing journey into a new draft. You can apply overrides to the copy in the same request.","href":"/reference/duplicate-journey"},{"title":"Update journey","tag":"BETA","openapi":"PATCH /apps/{app_id}/journeys/{id}","href":"/reference/update-journey"},{"title":"Update journey node","tag":"BETA","openapi":"PATCH /apps/{app_id}/journeys/{id}/nodes/{node_id}","href":"/reference/update-journey-node"},{"title":"Delete journey","tag":"BETA","openapi":"DELETE /apps/{app_id}/journeys/{id}","href":"/reference/delete-journey"}]},{"group":"Configuration","pages":[{"title":"View apps","openapi":"GET /apps","href":"/reference/view-apps"},{"title":"View an app","openapi":"GET /apps/{app_id}","href":"/reference/view-an-app"},{"title":"Create an app","openapi":"POST /apps","href":"/reference/create-an-app"},{"title":"Update an app","openapi":"PUT /apps/{app_id}","href":"/reference/update-an-app"},{"title":"View API keys","openapi":"GET /apps/{app_id}/auth/tokens","href":"/reference/view-api-keys"},{"title":"Create API key","openapi":"POST /apps/{app_id}/auth/tokens","href":"/reference/create-api-key"},{"title":"Delete API key","openapi":"DELETE /apps/{app_id}/auth/tokens/{token_id}","href":"/reference/delete-api-key"},{"title":"Update API key","openapi":"PATCH /apps/{app_id}/auth/tokens/{token_id}","href":"/reference/update-api-key"},{"title":"Rotate API key","openapi":"POST /apps/{app_id}/auth/tokens/{token_id}/rotate","href":"/reference/rotate-api-key"}]},{"group":"Analytics","pages":[{"title":"Export subscriptions CSV","openapi":"POST /players/csv_export","href":"/reference/csv-export"},{"title":"Export audience activity CSV","openapi":"POST /notifications/{message_id}/export_events","href":"/reference/export-csv-of-events"},{"title":"View outcomes","openapi":"GET /apps/{app_id}/outcomes?outcome_names={outcome_names}\u0026outcome_time_range={outcome_time_range}\u0026outcome_platforms={outcome_platforms}\u0026outcome_attribution={outcome_attribution}","href":"/reference/view-outcomes"}]},{"group":"Deprecated","pages":[{"title":"View players","deprecated":true,"href":"/reference/view-devices"},{"title":"View player","deprecated":true,"href":"/reference/view-device"},{"title":"Add a player","deprecated":true,"href":"/reference/add-a-device"},{"title":"Edit player","deprecated":true,"href":"/reference/edit-device"},{"title":"Edit tags with external user id","deprecated":true,"href":"/reference/edit-tags-with-external-user-id"},{"title":"Delete player record","deprecated":true,"href":"/reference/delete-user-record"}]}]},{"group":"SDKs","pages":[{"title":"Référence du SDK Serveur","href":"/docs/fr/server-sdk-reference"}]}]},{"tab":"Release Notes","pages":[{"title":"Release Notes","href":"/release-notes/changelog"}]}],"global":{"anchors":[{"anchor":"Blog","icon":"newspaper","href":"https://onesignal.com/blog"},{"anchor":"GitHub","icon":"github","href":"https://github.com/OneSignal"},{"anchor":"YouTube","icon":"youtube","href":"https://www.youtube.com/@onesignalofficial/playlists"}]}}]},"basePath":"","title":"Create journey - OneSignal Documentation","buildId":"dpl_FWZhTb2vab28gFGFH4ojka6qEznQ","deploymentId":"dpl_FWZhTb2vab28gFGFH4ojka6qEznQ","dynamics":["c2aa737661","2b790eda92","b0f84f53ff","a9bb46feb3"],"chunks":["OpenApiReferenceProvider-CBsVopKK.js","utils-DZAk68jJ.js","cloneDeep-izs3Hzxb.js","_Uint8Array-BVIqJ90l.js","isObjectLike-C8vmzPEN.js","isArray-Dcu1dQ5t.js","utils-D32AYZrP.js","toString-BX-iyh8G.js","isSymbol-CSH9U2Gm.js","addUniqueKeysToSchema-D_A5_cny.js","snippetPresets-xNRfS9th.js","style-to-object-BY3JEAdk.js","v4-DIgz8zy6.js","conditional-requirements-CFM0id0Q.js","ApiExamples-BIB25-tq.js","isEqual-BfaiBbcl.js","usePlaygroundInputsStore-CydJ4w4j.js","shallow-CYPBeQSG.js","getApiPlaygroundDisplay-A5xJVBOu.js","CodeSnippet-BVRTgi3m.js","CodeSnippets-DjD6BSlt.js","Page-Dr40SSJq.js","getPastedJson-D4V4JyrR.js","icon-uhcnG22T.js","MethodPill-CM-ZQdGH.js","DuplicateIcon-B_WnOiNf.js","createIcon-CJsb8utt.js","DynamicMarkdown-D-2HDKEp.js","SectionHeading-KP5xmMgQ.js","axios-vUo_bRtp.js","Markdown-D_k0dg6k.js","clsx-DK3K4Z1S.js","lib-DuNMoZ05.js","lib-B8HbPgcC.js","html-void-elements-mCSPHezU.js","dist-DE3EVdvd.js","katex-YMM-FMeD.js","marked.esm-CZWythHk.js","AssistantPageLink-fN9H9n9g.js"]}