Create a routing strategy. Requires a name and routing configuration at minimum. Channels and providers default to empty if omitted.
POST
/
routing-strategies
JavaScript
import Courier from '@trycourier/courier';const client = new Courier({ apiKey: process.env['COURIER_API_KEY'], // This is the default and can be omitted});const routingStrategyGetResponse = await client.routingStrategies.create({ name: 'Email via SendGrid', routing: { method: 'single', channels: ['email'] }, channels: { email: { providers: ['sendgrid', 'ses'] } }, description: 'Routes email through sendgrid with SES failover', providers: { sendgrid: { override: {} } }, tags: ['production', 'email'],});console.log(routingStrategyGetResponse.id);
import os
from courier import Courier
client = Courier(
api_key=os.environ.get("COURIER_API_KEY"), # This is the default and can be omitted
)
routing_strategy_get_response = client.routing_strategies.create(
name="Email via SendGrid",
routing={
"method": "single",
"channels": ["email"],
},
channels={
"email": {
"providers": ["sendgrid", "ses"]
}
},
description="Routes email through sendgrid with SES failover",
providers={
"sendgrid": {
"override": {}
}
},
tags=["production", "email"],
)
print(routing_strategy_get_response.id)
A unique key that makes this request idempotent. If Courier receives another request with the same Idempotency-Key, it returns the stored response from the first request without performing the operation again (including the original status code and any error). Use it to safely retry POST requests after network failures without risking duplicate sends. The key is scoped to this endpoint.
How long the idempotency key remains valid, as a Unix epoch timestamp in seconds or an ISO 8601 date string. Only applies when Idempotency-Key is provided. If omitted, the key is retained for 25 hours; the maximum is 1 year.
import Courier from '@trycourier/courier';const client = new Courier({ apiKey: process.env['COURIER_API_KEY'], // This is the default and can be omitted});const routingStrategyGetResponse = await client.routingStrategies.create({ name: 'Email via SendGrid', routing: { method: 'single', channels: ['email'] }, channels: { email: { providers: ['sendgrid', 'ses'] } }, description: 'Routes email through sendgrid with SES failover', providers: { sendgrid: { override: {} } }, tags: ['production', 'email'],});console.log(routingStrategyGetResponse.id);
import os
from courier import Courier
client = Courier(
api_key=os.environ.get("COURIER_API_KEY"), # This is the default and can be omitted
)
routing_strategy_get_response = client.routing_strategies.create(
name="Email via SendGrid",
routing={
"method": "single",
"channels": ["email"],
},
channels={
"email": {
"providers": ["sendgrid", "ses"]
}
},
description="Routes email through sendgrid with SES failover",
providers={
"sendgrid": {
"override": {}
}
},
tags=["production", "email"],
)
print(routing_strategy_get_response.id)
{"docsConfig":{"theme":"almond","$schema":"https://mintlify.com/docs.json","name":"Courier","description":"Courier is one API for email, SMS, push, chat, and in-app inbox, sending through the notification providers you already use. It adds templates, routing, preferences, and multi-step journeys, so your application makes one request instead of integrating each channel.","colors":{"primary":"#7C3AED","light":"#A78BFA","dark":"#5B21B6"},"logo":{"light":"https://mintcdn.com/courier-4f1f25dc/xDJPBS8EQ58X_0-v/assets/logo-light.svg?fit=max\u0026auto=format\u0026n=xDJPBS8EQ58X_0-v\u0026q=85\u0026s=2da40366f40ee5623aeabb98e65c6295","dark":"https://mintcdn.com/courier-4f1f25dc/xDJPBS8EQ58X_0-v/assets/logo-dark.svg?fit=max\u0026auto=format\u0026n=xDJPBS8EQ58X_0-v\u0026q=85\u0026s=eb1071ffaff93617b67ff4a2778f81d0","href":"https://www.courier.com/docs/overview"},"favicon":"https://mintcdn.com/courier-4f1f25dc/0KoAxE2unzOHL3EV/favicon.ico?fit=max\u0026auto=format\u0026n=0KoAxE2unzOHL3EV\u0026q=85\u0026s=3081d4055f7ca229bdeaac300a92b39c","navbar":{"links":[{"href":"https://www.courier.com/request-demo","label":"Request demo"},{"href":"https://app.courier.com/login?_gl=1*29rs2q*_gcl_au*MTYxMjIwODg4NS4xNzI5NjU5MDE4","label":"Login"}],"primary":{"type":"button","label":"Sign Up","href":"https://app.courier.com/signup?_gl=1*1130zcw*_gcl_au*MTYxMjIwODg4NS4xNzI5NjU5MDE4"}},"footer":{"socials":{"github":"https://github.com/trycourier","linkedin":"https://www.linkedin.com/company/trycourier","x":"https://x.com/trycourier"}},"search":{"prompt":"Search or ask AI"},"seo":{"metatags":{"canonical":"https://www.courier.com/docs"}},"fonts":{"heading":{"family":"Inter"},"body":{"family":"Inter"}},"integrations":{"gtm":{"tagId":"GTM-5PCP3R6"}},"contextual":{"options":["copy","view","chatgpt","claude"],"display":"header"},"markdown":{"instructions":["Install the Courier skill before writing code: `npx skills add trycourier/courier-skills`. It carries the verified SDK shapes and the rules you cannot get wrong.","Authenticate every request with `Authorization: Bearer \u003cAPI_KEY>`. A workspace has several environments and each has its own keys, which are plain `pk_` strings with no environment prefix. Start with Test.","Send with `client.send.message` from the Node SDK (`@trycourier/courier` v7 and later, where the client is the default import). Reference a template by its `nt_` id or its alias.","A send accepts a bare Elemental element list, but storing content on a template requires the top-level elements wrapped in a channel element.","To translate a template, write one locale at a time with `PUT /notifications/{id}/locales/{localeId}`, which merges into the existing translations. `PUT /notifications/{id}/content` and `PUT /notifications/{id}/elements/{elementId}` overwrite translations along with the content, so send each element's `id` and `locales` back, and first remove every `checksum` and any `locales` key that starts with an underscore.","Templates and journeys can be built in the Courier app or created through the API. Either way they live in the workspace and are referenced by ID when you send.","The hosted MCP server is https://mcp.courier.com. For a briefing on what Courier is and when to use it, read https://www.courier.com/llms.txt.","Prefer the Guides tab for how-do-I questions and the Docs tab for how-does-it-behave questions. The API reference lives under /api-reference."]},"styling":{"latex":true},"navigation":{"pages":[]}},"deployment":{"deploymentMetadataValue":{"subdomain":"courier-4f1f25dc","hasAudioNarration":false,"actualSubdomain":"courier-4f1f25dc","customDomains":["www.courier.com"],"gitSource":{"type":"github","owner":"trycourier","repo":"mintlify-docs","deployBranch":"main","contentDirectory":"","isPrivate":true,"mountPath":"","label":""},"feedback":{"thumbs":false},"entitlements":{"AI_CHAT":{"status":"ENABLED"},"REMOVE_BRANDING":{"status":"ENABLED"},"CONTEXTUAL_FEEDBACK":{"status":"ENABLED"},"CODE_SNIPPET_FEEDBACK":{"status":"ENABLED"},"WEB_MCP":{"status":"ENABLED"},"NARRATION":{"status":"ENABLED"}},"buildId":"6af611480eb27df7acc1c112","clientVersion":"0.0.4117","searchFilterCounts":[{"language":"default","tag":"API Reference","count":169},{"language":"default","tag":"Docs","count":99},{"language":"default","tag":"Integrations","count":67},{"language":"default","tag":"Available integrations","count":65},{"language":"default","tag":"Guides","count":43},{"language":"default","tag":"Journeys","count":36},{"language":"default","tag":"Design","count":33},{"language":"default","tag":"Templates","count":25},{"language":"default","tag":"Elemental","count":17},{"language":"default","tag":"SDKs","count":17}]},"assistantConfig":{"enableAskAiButton":true,"enableAskAiSearchBar":true},"basePath":"/docs","hasChatPermissions":true,"hasWebMcpPermissions":true,"toggles":[],"googleFontsInlined":false},"customCss":[{"filePath":"styles.css","content":"html{scroll-behavior:smooth}#navbar div:has(>a img.nav-logo){flex:0 0 256px!important}#navbar div:has(>div>div>.nav-tabs){flex:1 1 auto!important}#navbar div:has(>div>.nav-tabs){margin-left:0!important;justify-content:space-between!important}#content-area{max-width:50rem!important;margin-left:auto!important;margin-right:auto!important}#content-container{position:relative;isolation:isolate}#content-container::before{content:\"\";position:absolute;top:0;left:0;right:0;height:420px;z-index:-1;pointer-events:none;background-image:radial-gradient(\n 140% 100% at 50% 20%,\n rgba(139, 92, 246, 0.06),\n rgba(139, 92, 246, 0.015)\n );-webkit-mask-image:repeating-linear-gradient(to right, #000 0 3px, transparent 3px 4px),\n repeating-linear-gradient(to bottom, #000 0 3px, transparent 3px 4px),\n linear-gradient(\n to bottom,\n #000 0,\n #000 112px,\n rgba(0, 0, 0, 0.70) 176px,\n rgba(0, 0, 0, 0.45) 240px,\n rgba(0, 0, 0, 0.26) 300px,\n rgba(0, 0, 0, 0.12) 352px,\n rgba(0, 0, 0, 0.05) 392px,\n transparent 420px\n );-webkit-mask-composite:source-in, source-in;mask-image:repeating-linear-gradient(to right, #000 0 3px, transparent 3px 4px),\n repeating-linear-gradient(to bottom, #000 0 3px, transparent 3px 4px),\n linear-gradient(\n to bottom,\n #000 0,\n #000 112px,\n rgba(0, 0, 0, 0.70) 176px,\n rgba(0, 0, 0, 0.45) 240px,\n rgba(0, 0, 0, 0.26) 300px,\n rgba(0, 0, 0, 0.12) 352px,\n rgba(0, 0, 0, 0.05) 392px,\n transparent 420px\n );mask-composite:intersect, intersect, intersect}.dark #content-container::before{background-image:radial-gradient(\n 140% 100% at 50% 20%,\n rgba(139, 92, 246, 0.12),\n rgba(139, 92, 246, 0.03)\n )}#topbar-cta-button svg{display:inline-block!important;color:#fff!important}#topbar-cta-button a>div{gap:0.25rem!important}@media (min-width: 1024px){.sticky:has(>#chat-assistant-sheet){top:calc(var(--banner-height, 0px) + var(--cx-navbar-height, 56px))!important;margin-top:calc(var(--banner-height, 0px) + var(--cx-navbar-height, 56px))!important;height:calc(100vh - var(--banner-height, 0px) - var(--cx-navbar-height, 56px))!important;padding-top:0!important}}.chat-assistant-floating-input{visibility:hidden!important}@media (min-width: 1024px){#navbar{width:100%!important}}#navbar a.nav-tabs-item{white-space:nowrap}@media (min-width: 1024px) and (max-width: 1129px){#navbar li:has(>a[href*=\"courier.com/signup\"]){display:none!important}}@media (min-width: 1024px) and (max-width: 1199px){#navbar li:has(>a[href*=\"courier.com/login\"]){display:none!important}}@media (max-width: 1023px){#navbar div:has(>a img.nav-logo){flex:0 1 auto!important}#navbar .lg\\:hidden.items-center.gap-3{margin-left:auto!important}}.cx-mobile-demo{display:inline-flex;align-items:center;white-space:nowrap;font-size:13px;font-weight:500;line-height:1;text-decoration:none;padding:7px 11px;border-radius:8px;border:1px solid rgba(130, 130, 140, 0.35);color:inherit}div:has(>.sidebar-group-header)+div:has(>.sidebar-group-header){position:relative;margin-top:1rem!important;padding-top:1.375rem}div:has(>.sidebar-group-header)+div:has(>.sidebar-group-header)::before{content:\"\";position:absolute;top:0;left:0.5rem;right:0.5rem;border-top:1px solid rgba(17, 24, 39, 0.08)}.dark div:has(>.sidebar-group-header)+div:has(>.sidebar-group-header)::before{border-top-color:rgba(255, 255, 255, 0.1)}#content-area [data-component-part=\"card-icon\"]:has(>img[src*=\"/assets/provider-\"]),#content-area [data-component-part=\"card-icon\"]>img[src*=\"/assets/provider-\"]{width:2rem;height:2rem;object-fit:contain}.cx-provider-logo-slot{display:block;width:3.75rem;height:3.75rem;margin-bottom:0.75rem;font-size:0;line-height:0}.cx-provider-logo{width:100%;height:100%;object-fit:contain;object-position:left center}.dark img[src$=\"/provider-apple-push-notification.webp\"],.dark img[src$=\"/provider-beamer.svg\"],.dark img[src$=\"/provider-custom-provider.svg\"],.dark img[src$=\"/provider-expo.svg\"],.dark img[src$=\"/provider-pagerduty.svg\"],.dark img[src$=\"/provider-postmark.webp\"],.dark img[src$=\"/provider-resend.svg\"],.dark img[src$=\"/provider-splunk-on-call.svg\"],.dark img[src$=\"/provider-vonage.svg\"]{filter:invert(1)}.cx-tags{display:flex;flex-wrap:wrap;align-items:center;gap:0.375rem;margin:0 0 1.5em}.cx-tag{display:inline-flex;align-items:center;gap:0.375rem;padding:0.25rem 0.5rem;border:0;border-radius:0.5rem;background-color:var(--cx-tag-bg);color:var(--cx-tag-fg);font-size:0.875rem;font-weight:600;line-height:1.25;white-space:nowrap;text-decoration:none!important;transition:background-color 120ms ease, color 120ms ease;--cx-tag-fg: #584f69;--cx-tag-bg: #f5f3f8}.cx-tag[data-icon]::before{content:\"\";flex:none;width:0.875em;height:0.875em;background-color:currentColor;-webkit-mask-image:var(--cx-tag-icon);mask-image:var(--cx-tag-icon);-webkit-mask-size:contain;mask-size:contain;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat;-webkit-mask-position:center;mask-position:center}.dark .cx-tag{--cx-tag-fg: #cdc4dc;--cx-tag-bg: rgba(167, 139, 250, 0.10)}a.cx-tag:hover{--cx-tag-fg: #443c52;--cx-tag-bg: #ece9f1}.dark a.cx-tag:hover{--cx-tag-fg: #ded7e8;--cx-tag-bg: rgba(167, 139, 250, 0.18)}a.cx-tag:focus-visible{outline:2px solid rgba(124, 58, 237, 0.5);outline-offset:2px}.code-scroll [data-component-part=\"scroll-area-viewport\"]{max-height:30rem}"},{"filePath":"photo-shoot/index.css","content":"@font-face{font-family:'Poppins';src:url('/Poppins-Regular.ttf') format('truetype');font-weight:400;font-style:normal;font-display:swap}:root{font-family:system-ui, Avenir, Helvetica, Arial, sans-serif;font-weight:400;font-synthesis:none;text-rendering:optimizeLegibility;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}body{margin:0;min-width:320px}"}],"page":{"pagePath":"api-reference/routing-strategies/create-routing-strategy","slug":"/api-reference/routing-strategies/create-routing-strategy","pageMetadata":{"title":"Create Routing Strategy","description":"Create a routing strategy. Requires a name and routing configuration at minimum. Channels and providers default to empty if omitted.","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml post /routing-strategies","href":"/api-reference/routing-strategies/create-routing-strategy","autogeneratedByOpenApi":true},"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 routing strategy. Requires a name and routing configuration at minimum. Channels and providers default to empty if omitted.\"\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}=arguments[0];const{useMDXComponents:_provideComponents}=arguments[0];function _createMdxContent(props){return _jsx(_Fragment,{})}function MDXContent(props={}){const{wrapper:MDXLayout}={..._provideComponents(),...props.components};return MDXLayout?_jsx(MDXLayout,{...props,children:_jsx(_createMdxContent,{...props})}):_createMdxContent(props)}return{default:MDXContent}","frontmatter":{},"scope":{"config":{},"pageMetadata":{"title":"Create Routing Strategy","description":"Create a routing strategy. Requires a name and routing configuration at minimum. Channels and providers default to empty if omitted.","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml post /routing-strategies","href":"/api-reference/routing-strategies/create-routing-strategy","autogeneratedByOpenApi":true}}},"mdxSourceWithNoJs":null},"mdxExtracts":{"tableOfContents":[],"codeExamples":{}},"jsLinks":["/docs/_mintlify/custom/courier-4f1f25dc/57421be0d4eec0e0/content/favicons.js","/docs/_mintlify/custom/courier-4f1f25dc/05bb41119f2419fd/scripts.js"],"openApiReferenceData":{"operation":{"description":"Create a routing strategy. Requires a name and routing configuration at minimum. Channels and providers default to empty if omitted.","operationId":"routingStrategies_create","tags":["Routing Strategies"],"parameters":["d63cf81c-7cc7-40be-80e4-4f9357b6e9c3","61b1f61c-1d02-438b-9d87-ecd82538ec3e"],"responses":{"201":"32bc442e-805d-455a-85f7-b1f098dc95e0","400":"fade0145-522a-4086-aa71-4acabcfeabe5"},"summary":"Create Routing Strategy","security":["a93a4e6e-c3ff-4853-89ad-6bc218b82a5b"],"requestBody":"473c05e4-81d0-4e5c-9d90-7092a548fe88","x-codeSamples":[{"lang":"JavaScript","source":"import Courier from '@trycourier/courier';\n\nconst client = new Courier({\n apiKey: process.env['COURIER_API_KEY'], // This is the default and can be omitted\n});\n\nconst routingStrategyGetResponse = await client.routingStrategies.create({\n name: 'Email via SendGrid',\n routing: { method: 'single', channels: ['email'] },\n channels: { email: { providers: ['sendgrid', 'ses'] } },\n description: 'Routes email through sendgrid with SES failover',\n providers: { sendgrid: { override: {} } },\n tags: ['production', 'email'],\n});\n\nconsole.log(routingStrategyGetResponse.id);"},{"lang":"Python","source":"import os\nfrom courier import Courier\n\nclient = Courier(\n api_key=os.environ.get(\"COURIER_API_KEY\"), # This is the default and can be omitted\n)\nrouting_strategy_get_response = client.routing_strategies.create(\n name=\"Email via SendGrid\",\n routing={\n \"method\": \"single\",\n \"channels\": [\"email\"],\n },\n channels={\n \"email\": {\n \"providers\": [\"sendgrid\", \"ses\"]\n }\n },\n description=\"Routes email through sendgrid with SES failover\",\n providers={\n \"sendgrid\": {\n \"override\": {}\n }\n },\n tags=[\"production\", \"email\"],\n)\nprint(routing_strategy_get_response.id)"},{"lang":"Go","source":"package main\n\nimport (\n\t\"context\"\n\t\"fmt\"\n\n\t\"github.com/trycourier/courier-go/v4\"\n\t\"github.com/trycourier/courier-go/v4/option\"\n\t\"github.com/trycourier/courier-go/v4/shared\"\n)\n\nfunc main() {\n\tclient := courier.NewClient(\n\t\toption.WithAPIKey(\"My API Key\"),\n\t)\n\troutingStrategyGetResponse, err := client.RoutingStrategies.New(context.TODO(), courier.RoutingStrategyNewParams{\n\t\tRoutingStrategyCreateRequest: courier.RoutingStrategyCreateRequestParam{\n\t\t\tName: \"Email via SendGrid\",\n\t\t\tRouting: shared.MessageRoutingParam{\n\t\t\t\tChannels: []shared.MessageRoutingChannelUnionParam{{\n\t\t\t\t\tOfString: courier.String(\"email\"),\n\t\t\t\t}},\n\t\t\t\tMethod: shared.MessageRoutingMethodSingle,\n\t\t\t},\n\t\t},\n\t})\n\tif err != nil {\n\t\tpanic(err.Error())\n\t}\n\tfmt.Printf(\"%+v\\n\", routingStrategyGetResponse.ID)\n}\n"},{"lang":"Java","source":"package com.courier.example;\n\nimport com.courier.client.CourierClient;\nimport com.courier.client.okhttp.CourierOkHttpClient;\nimport com.courier.models.MessageRouting;\nimport com.courier.models.routingstrategies.RoutingStrategyCreateRequest;\nimport com.courier.models.routingstrategies.RoutingStrategyGetResponse;\n\npublic final class Main {\n private Main() {}\n\n public static void main(String[] args) {\n CourierClient client = CourierOkHttpClient.fromEnv();\n\n RoutingStrategyCreateRequest params = RoutingStrategyCreateRequest.builder()\n .name(\"Email via SendGrid\")\n .routing(MessageRouting.builder()\n .addChannel(\"email\")\n .method(MessageRouting.Method.SINGLE)\n .build())\n .build();\n RoutingStrategyGetResponse routingStrategyGetResponse = client.routingStrategies().create(params);\n }\n}"},{"lang":"Ruby","source":"require \"courier\"\n\ncourier = Courier::Client.new(api_key: \"My API Key\")\n\nrouting_strategy_get_response = courier.routing_strategies.create(\n name: \"Email via SendGrid\",\n routing: {channels: [\"email\"], method: :single}\n)\n\nputs(routing_strategy_get_response)"},{"lang":"PHP","source":"\u003c?php\n\nrequire_once dirname(__DIR__) . '/vendor/autoload.php';\n\nuse Courier\\Client;\nuse Courier\\Core\\Exceptions\\APIException;\n\n$client = new Client(apiKey: getenv('COURIER_API_KEY') ?: 'My API Key');\n\ntry {\n $routingStrategyGetResponse = $client->routingStrategies->create(\n name: 'Email via SendGrid',\n routing: ['channels' => ['email'], 'method' => 'single'],\n channels: [\n 'email' => [\n 'brandID' => 'brand_id',\n 'if' => 'if',\n 'metadata' => [\n 'utm' => [\n 'campaign' => 'campaign',\n 'content' => 'content',\n 'medium' => 'medium',\n 'source' => 'source',\n 'term' => 'term',\n ],\n ],\n 'override' => ['foo' => 'bar'],\n 'providers' => ['sendgrid', 'ses'],\n 'routingMethod' => 'all',\n 'timeouts' => ['channel' => 0, 'provider' => 0],\n ],\n ],\n description: 'Routes email through sendgrid with SES failover',\n providers: [\n 'sendgrid' => [\n 'if' => 'if',\n 'metadata' => [\n 'utm' => [\n 'campaign' => 'campaign',\n 'content' => 'content',\n 'medium' => 'medium',\n 'source' => 'source',\n 'term' => 'term',\n ],\n ],\n 'override' => [],\n 'timeouts' => 0,\n ],\n ],\n tags: ['production', 'email'],\n idempotencyKey: 'order-ORD-456-user-123',\n xIdempotencyExpiration: '1785312000',\n );\n\n var_dump($routingStrategyGetResponse);\n} catch (APIException $e) {\n echo $e->getMessage();\n}"},{"lang":"C#","source":"using System;\nusing TryCourier;\nusing TryCourier.Models;\nusing TryCourier.Models.RoutingStrategies;\n\nCourierClient client = new();\n\nRoutingStrategyCreateParams parameters = new()\n{\n Name = \"Email via SendGrid\",\n Routing = new()\n {\n Channels =\n [\n \"email\"\n ],\n Method = Method.Single,\n },\n};\n\nvar routingStrategyGetResponse = await client.RoutingStrategies.Create(parameters);\n\nConsole.WriteLine(routingStrategyGetResponse);"},{"lang":"CLI","source":"courier routing-strategies create \\\n --api-key 'My API Key' \\\n --name 'Email via SendGrid' \\\n --routing '{channels: [email], method: single}'"}],"method":"post","type":"path","servers":["d796b094-be40-4858-8eb5-01c6e6c3e5f8"],"path":"/routing-strategies","baseUrlOptions":["https://api.courier.com"],"title":"Create Routing Strategy","codeSamples":[{"lang":"JavaScript","source":"import Courier from '@trycourier/courier';\n\nconst client = new Courier({\n apiKey: process.env['COURIER_API_KEY'], // This is the default and can be omitted\n});\n\nconst routingStrategyGetResponse = await client.routingStrategies.create({\n name: 'Email via SendGrid',\n routing: { method: 'single', channels: ['email'] },\n channels: { email: { providers: ['sendgrid', 'ses'] } },\n description: 'Routes email through sendgrid with SES failover',\n providers: { sendgrid: { override: {} } },\n tags: ['production', 'email'],\n});\n\nconsole.log(routingStrategyGetResponse.id);"},{"lang":"Python","source":"import os\nfrom courier import Courier\n\nclient = Courier(\n api_key=os.environ.get(\"COURIER_API_KEY\"), # This is the default and can be omitted\n)\nrouting_strategy_get_response = client.routing_strategies.create(\n name=\"Email via SendGrid\",\n routing={\n \"method\": \"single\",\n \"channels\": [\"email\"],\n },\n channels={\n \"email\": {\n \"providers\": [\"sendgrid\", \"ses\"]\n }\n },\n description=\"Routes email through sendgrid with SES failover\",\n providers={\n \"sendgrid\": {\n \"override\": {}\n }\n },\n tags=[\"production\", \"email\"],\n)\nprint(routing_strategy_get_response.id)"},{"lang":"Go","source":"package main\n\nimport (\n\t\"context\"\n\t\"fmt\"\n\n\t\"github.com/trycourier/courier-go/v4\"\n\t\"github.com/trycourier/courier-go/v4/option\"\n\t\"github.com/trycourier/courier-go/v4/shared\"\n)\n\nfunc main() {\n\tclient := courier.NewClient(\n\t\toption.WithAPIKey(\"My API Key\"),\n\t)\n\troutingStrategyGetResponse, err := client.RoutingStrategies.New(context.TODO(), courier.RoutingStrategyNewParams{\n\t\tRoutingStrategyCreateRequest: courier.RoutingStrategyCreateRequestParam{\n\t\t\tName: \"Email via SendGrid\",\n\t\t\tRouting: shared.MessageRoutingParam{\n\t\t\t\tChannels: []shared.MessageRoutingChannelUnionParam{{\n\t\t\t\t\tOfString: courier.String(\"email\"),\n\t\t\t\t}},\n\t\t\t\tMethod: shared.MessageRoutingMethodSingle,\n\t\t\t},\n\t\t},\n\t})\n\tif err != nil {\n\t\tpanic(err.Error())\n\t}\n\tfmt.Printf(\"%+v\\n\", routingStrategyGetResponse.ID)\n}\n"},{"lang":"Java","source":"package com.courier.example;\n\nimport com.courier.client.CourierClient;\nimport com.courier.client.okhttp.CourierOkHttpClient;\nimport com.courier.models.MessageRouting;\nimport com.courier.models.routingstrategies.RoutingStrategyCreateRequest;\nimport com.courier.models.routingstrategies.RoutingStrategyGetResponse;\n\npublic final class Main {\n private Main() {}\n\n public static void main(String[] args) {\n CourierClient client = CourierOkHttpClient.fromEnv();\n\n RoutingStrategyCreateRequest params = RoutingStrategyCreateRequest.builder()\n .name(\"Email via SendGrid\")\n .routing(MessageRouting.builder()\n .addChannel(\"email\")\n .method(MessageRouting.Method.SINGLE)\n .build())\n .build();\n RoutingStrategyGetResponse routingStrategyGetResponse = client.routingStrategies().create(params);\n }\n}"},{"lang":"Ruby","source":"require \"courier\"\n\ncourier = Courier::Client.new(api_key: \"My API Key\")\n\nrouting_strategy_get_response = courier.routing_strategies.create(\n name: \"Email via SendGrid\",\n routing: {channels: [\"email\"], method: :single}\n)\n\nputs(routing_strategy_get_response)"},{"lang":"PHP","source":"\u003c?php\n\nrequire_once dirname(__DIR__) . '/vendor/autoload.php';\n\nuse Courier\\Client;\nuse Courier\\Core\\Exceptions\\APIException;\n\n$client = new Client(apiKey: getenv('COURIER_API_KEY') ?: 'My API Key');\n\ntry {\n $routingStrategyGetResponse = $client->routingStrategies->create(\n name: 'Email via SendGrid',\n routing: ['channels' => ['email'], 'method' => 'single'],\n channels: [\n 'email' => [\n 'brandID' => 'brand_id',\n 'if' => 'if',\n 'metadata' => [\n 'utm' => [\n 'campaign' => 'campaign',\n 'content' => 'content',\n 'medium' => 'medium',\n 'source' => 'source',\n 'term' => 'term',\n ],\n ],\n 'override' => ['foo' => 'bar'],\n 'providers' => ['sendgrid', 'ses'],\n 'routingMethod' => 'all',\n 'timeouts' => ['channel' => 0, 'provider' => 0],\n ],\n ],\n description: 'Routes email through sendgrid with SES failover',\n providers: [\n 'sendgrid' => [\n 'if' => 'if',\n 'metadata' => [\n 'utm' => [\n 'campaign' => 'campaign',\n 'content' => 'content',\n 'medium' => 'medium',\n 'source' => 'source',\n 'term' => 'term',\n ],\n ],\n 'override' => [],\n 'timeouts' => 0,\n ],\n ],\n tags: ['production', 'email'],\n idempotencyKey: 'order-ORD-456-user-123',\n xIdempotencyExpiration: '1785312000',\n );\n\n var_dump($routingStrategyGetResponse);\n} catch (APIException $e) {\n echo $e->getMessage();\n}"},{"lang":"C#","source":"using System;\nusing TryCourier;\nusing TryCourier.Models;\nusing TryCourier.Models.RoutingStrategies;\n\nCourierClient client = new();\n\nRoutingStrategyCreateParams parameters = new()\n{\n Name = \"Email via SendGrid\",\n Routing = new()\n {\n Channels =\n [\n \"email\"\n ],\n Method = Method.Single,\n },\n};\n\nvar routingStrategyGetResponse = await client.RoutingStrategies.Create(parameters);\n\nConsole.WriteLine(routingStrategyGetResponse);"},{"lang":"CLI","source":"courier routing-strategies create \\\n --api-key 'My API Key' \\\n --name 'Email via SendGrid' \\\n --routing '{channels: [email], method: single}'"}],"requiredOnlyExamples":false,"requestExampleType":"codeSamples","responseExampleType":"generated"},"dependencies":{"parameters":{"d63cf81c-7cc7-40be-80e4-4f9357b6e9c3":{"name":"Idempotency-Key","in":"header","required":false,"description":"A unique key that makes this request idempotent. If Courier receives another request with the same `Idempotency-Key`, it returns the stored response from the first request without performing the operation again (including the original status code and any error). Use it to safely retry `POST` requests after network failures without risking duplicate sends. The key is scoped to this endpoint.","schema":{"type":"string","isRequired":false,"description":"A unique key that makes this request idempotent. If Courier receives another request with the same `Idempotency-Key`, it returns the stored response from the first request without performing the operation again (including the original status code and any error). Use it to safely retry `POST` requests after network failures without risking duplicate sends. The key is scoped to this endpoint.","uniqueKey":"","typeLabel":"string"},"example":"order-ORD-456-user-123"},"61b1f61c-1d02-438b-9d87-ecd82538ec3e":{"name":"x-idempotency-expiration","in":"header","required":false,"description":"How long the idempotency key remains valid, as a Unix epoch timestamp in seconds or an ISO 8601 date string. Only applies when `Idempotency-Key` is provided. If omitted, the key is retained for 25 hours; the maximum is 1 year.","schema":{"type":"string","isRequired":false,"description":"How long the idempotency key remains valid, as a Unix epoch timestamp in seconds or an ISO 8601 date string. Only applies when `Idempotency-Key` is provided. If omitted, the key is retained for 25 hours; the maximum is 1 year.","uniqueKey":"","typeLabel":"string"},"example":"1785312000"}},"requestBody":{"required":true,"content":{"application/json":{"schema":{"title":"RoutingStrategyCreateRequest","type":"object","description":"Request body for creating a routing strategy.","properties":{"name":{"type":"string","description":"Human-readable name for the routing strategy.","isRequired":true,"uniqueKey":"name","typeLabel":"string"},"routing":{"title":"MessageRouting","type":"object","properties":{"method":{"title":"MessageRoutingMethod","type":"string","enum":["all","single"],"isRequired":true,"uniqueKey":"routing.method","typeLabel":"enum\u003cstring>"},"channels":{"type":"array","items":{"oneOf":[{"type":"string","title":"MessageRoutingChannel","uniqueKey":"routing.channels.items.[INDEX].oneOf.0","typeLabel":"string"},{"title":"MessageRoutingChannel"}],"uniqueKey":"routing.channels.items.[INDEX]","typeLabel":"string"},"isRequired":true,"uniqueKey":"routing.channels","typeLabel":"string[]"}},"required":["method","channels"],"description":"Routing tree defining channel selection method and order.","isRequired":true,"uniqueKey":"routing","typeLabel":"MessageRouting · object"},"description":{"oneOf":[{"type":"string","description":"Optional description of the routing strategy.","uniqueKey":"description.oneOf.0","typeLabel":"string"},{"type":"null","description":"Optional description of the routing strategy.","uniqueKey":"description.oneOf.1","typeLabel":"null"}],"uniqueKey":"description","typeLabel":"string | null"},"tags":{"oneOf":[{"type":"array","items":{"type":"string","uniqueKey":"tags.oneOf.0.items.[INDEX]","typeLabel":"string"},"description":"Optional tags for categorization.","uniqueKey":"tags.oneOf.0","typeLabel":"string[]"},{"type":"null","items":{"type":"string"},"description":"Optional tags for categorization.","uniqueKey":"tags.oneOf.1","typeLabel":"null"}],"uniqueKey":"tags","typeLabel":"string[] | null"},"channels":{"oneOf":[{"title":"MessageChannels","type":"object","additionalProperties":{"title":"Channel","type":"object","properties":{"brand_id":{"oneOf":[{"type":"string","description":"Brand id used for rendering.","uniqueKey":"channels.oneOf.0.additionalProperties.brand_id.oneOf.0","typeLabel":"string"},{"type":"null","description":"Brand id used for rendering.","uniqueKey":"channels.oneOf.0.additionalProperties.brand_id.oneOf.1","typeLabel":"null"}],"uniqueKey":"channels.oneOf.0.additionalProperties.brand_id","typeLabel":"string | null"},"providers":{"oneOf":[{"type":"array","items":{"type":"string","uniqueKey":"channels.oneOf.0.additionalProperties.providers.oneOf.0.items.[INDEX]","typeLabel":"string"},"description":"Providers enabled for this channel.","uniqueKey":"channels.oneOf.0.additionalProperties.providers.oneOf.0","typeLabel":"string[]"},{"type":"null","items":{"type":"string"},"description":"Providers enabled for this channel.","uniqueKey":"channels.oneOf.0.additionalProperties.providers.oneOf.1","typeLabel":"null"}],"uniqueKey":"channels.oneOf.0.additionalProperties.providers","typeLabel":"string[] | null"},"routing_method":{"oneOf":[{"title":"RoutingMethod","type":"string","enum":["all","single"],"description":"Defaults to `single`.","uniqueKey":"channels.oneOf.0.additionalProperties.routing_method.oneOf.0","typeLabel":"enum\u003cstring>"},{"title":"RoutingMethod","type":"null","enum":["all","single"],"description":"Defaults to `single`.","uniqueKey":"channels.oneOf.0.additionalProperties.routing_method.oneOf.1","typeLabel":"null"}],"uniqueKey":"channels.oneOf.0.additionalProperties.routing_method","typeLabel":"enum\u003cstring> | null"},"if":{"oneOf":[{"type":"string","description":"JS conditional with access to data/profile.","uniqueKey":"channels.oneOf.0.additionalProperties.if.oneOf.0","typeLabel":"string"},{"type":"null","description":"JS conditional with access to data/profile.","uniqueKey":"channels.oneOf.0.additionalProperties.if.oneOf.1","typeLabel":"null"}],"uniqueKey":"channels.oneOf.0.additionalProperties.if","typeLabel":"string | null"},"timeouts":{"oneOf":[{"title":"Timeouts","type":"object","properties":{"provider":{"oneOf":[{"type":"integer","uniqueKey":"channels.oneOf.0.additionalProperties.timeouts.oneOf.0.provider.oneOf.0","typeLabel":"integer"},{"type":"null","uniqueKey":"channels.oneOf.0.additionalProperties.timeouts.oneOf.0.provider.oneOf.1","typeLabel":"null"}],"uniqueKey":"channels.oneOf.0.additionalProperties.timeouts.oneOf.0.provider","typeLabel":"integer | null"},"channel":{"oneOf":[{"type":"integer","uniqueKey":"channels.oneOf.0.additionalProperties.timeouts.oneOf.0.channel.oneOf.0","typeLabel":"integer"},{"type":"null","uniqueKey":"channels.oneOf.0.additionalProperties.timeouts.oneOf.0.channel.oneOf.1","typeLabel":"null"}],"uniqueKey":"channels.oneOf.0.additionalProperties.timeouts.oneOf.0.channel","typeLabel":"integer | null"}},"x-stainless-naming":{"csharp":{"type_name":"ChannelTimeouts"}},"uniqueKey":"channels.oneOf.0.additionalProperties.timeouts.oneOf.0","typeLabel":"Timeouts · object"},{"title":"Timeouts","type":"null","properties":{"provider":{"oneOf":[{"type":"integer"},{"type":"null"}]},"channel":{"oneOf":[{"type":"integer"},{"type":"null"}]}},"x-stainless-naming":{"csharp":{"type_name":"ChannelTimeouts"}},"uniqueKey":"channels.oneOf.0.additionalProperties.timeouts.oneOf.1","typeLabel":"null"}],"uniqueKey":"channels.oneOf.0.additionalProperties.timeouts","typeLabel":"Timeouts · object | null"},"override":{"oneOf":[{"type":"object","additionalProperties":true,"description":"Channel specific overrides.","uniqueKey":"channels.oneOf.0.additionalProperties.override.oneOf.0","typeLabel":"object"},{"type":"null","additionalProperties":true,"description":"Channel specific overrides.","uniqueKey":"channels.oneOf.0.additionalProperties.override.oneOf.1","typeLabel":"null"}],"uniqueKey":"channels.oneOf.0.additionalProperties.override","typeLabel":"object | null"},"metadata":{"oneOf":[{"title":"ChannelMetadata","type":"object","properties":{"utm":{"oneOf":[{"title":"UTM","type":"object","properties":{"source":{"oneOf":[{"type":"string","uniqueKey":"channels.oneOf.0.additionalProperties.metadata.oneOf.0.utm.oneOf.0.source.oneOf.0","typeLabel":"string"},{"type":"null","uniqueKey":"channels.oneOf.0.additionalProperties.metadata.oneOf.0.utm.oneOf.0.source.oneOf.1","typeLabel":"null"}],"uniqueKey":"channels.oneOf.0.additionalProperties.metadata.oneOf.0.utm.oneOf.0.source","typeLabel":"string | null"},"medium":{"oneOf":[{"type":"string","uniqueKey":"channels.oneOf.0.additionalProperties.metadata.oneOf.0.utm.oneOf.0.medium.oneOf.0","typeLabel":"string"},{"type":"null","uniqueKey":"channels.oneOf.0.additionalProperties.metadata.oneOf.0.utm.oneOf.0.medium.oneOf.1","typeLabel":"null"}],"uniqueKey":"channels.oneOf.0.additionalProperties.metadata.oneOf.0.utm.oneOf.0.medium","typeLabel":"string | null"},"campaign":{"oneOf":[{"type":"string","uniqueKey":"channels.oneOf.0.additionalProperties.metadata.oneOf.0.utm.oneOf.0.campaign.oneOf.0","typeLabel":"string"},{"type":"null","uniqueKey":"channels.oneOf.0.additionalProperties.metadata.oneOf.0.utm.oneOf.0.campaign.oneOf.1","typeLabel":"null"}],"uniqueKey":"channels.oneOf.0.additionalProperties.metadata.oneOf.0.utm.oneOf.0.campaign","typeLabel":"string | null"},"term":{"oneOf":[{"type":"string","uniqueKey":"channels.oneOf.0.additionalProperties.metadata.oneOf.0.utm.oneOf.0.term.oneOf.0","typeLabel":"string"},{"type":"null","uniqueKey":"channels.oneOf.0.additionalProperties.metadata.oneOf.0.utm.oneOf.0.term.oneOf.1","typeLabel":"null"}],"uniqueKey":"channels.oneOf.0.additionalProperties.metadata.oneOf.0.utm.oneOf.0.term","typeLabel":"string | null"},"content":{"oneOf":[{"type":"string","uniqueKey":"channels.oneOf.0.additionalProperties.metadata.oneOf.0.utm.oneOf.0.content.oneOf.0","typeLabel":"string"},{"type":"null","uniqueKey":"channels.oneOf.0.additionalProperties.metadata.oneOf.0.utm.oneOf.0.content.oneOf.1","typeLabel":"null"}],"uniqueKey":"channels.oneOf.0.additionalProperties.metadata.oneOf.0.utm.oneOf.0.content","typeLabel":"string | null"}},"uniqueKey":"channels.oneOf.0.additionalProperties.metadata.oneOf.0.utm.oneOf.0","typeLabel":"UTM · object"},{"title":"UTM","type":"null","properties":{"source":{"oneOf":[{"type":"string"},{"type":"null"}]},"medium":{"oneOf":[{"type":"string"},{"type":"null"}]},"campaign":{"oneOf":[{"type":"string"},{"type":"null"}]},"term":{"oneOf":[{"type":"string"},{"type":"null"}]},"content":{"oneOf":[{"type":"string"},{"type":"null"}]}},"uniqueKey":"channels.oneOf.0.additionalProperties.metadata.oneOf.0.utm.oneOf.1","typeLabel":"null"}],"uniqueKey":"channels.oneOf.0.additionalProperties.metadata.oneOf.0.utm","typeLabel":"UTM · object | null"}},"uniqueKey":"channels.oneOf.0.additionalProperties.metadata.oneOf.0","typeLabel":"ChannelMetadata · object"},{"title":"ChannelMetadata","type":"null","properties":{"utm":{"oneOf":[{"title":"UTM","type":"object","properties":{"source":{"oneOf":[{"type":"string"},{"type":"null"}]},"medium":{"oneOf":[{"type":"string"},{"type":"null"}]},"campaign":{"oneOf":[{"type":"string"},{"type":"null"}]},"term":{"oneOf":[{"type":"string"},{"type":"null"}]},"content":{"oneOf":[{"type":"string"},{"type":"null"}]}}},{"title":"UTM","type":"null","properties":{"source":{"oneOf":[{"type":"string"},{"type":"null"}]},"medium":{"oneOf":[{"type":"string"},{"type":"null"}]},"campaign":{"oneOf":[{"type":"string"},{"type":"null"}]},"term":{"oneOf":[{"type":"string"},{"type":"null"}]},"content":{"oneOf":[{"type":"string"},{"type":"null"}]}}}]}},"uniqueKey":"channels.oneOf.0.additionalProperties.metadata.oneOf.1","typeLabel":"null"}],"uniqueKey":"channels.oneOf.0.additionalProperties.metadata","typeLabel":"ChannelMetadata · object | null"}},"x-stainless-naming":{"csharp":{"type_name":"MessageChannel"}},"uniqueKey":"channels.oneOf.0.additionalProperties","typeLabel":"Channel · object"},"description":"Per-channel delivery configuration. Defaults to empty if omitted.","uniqueKey":"channels.oneOf.0","typeLabel":"MessageChannels · object"},{"title":"MessageChannels","type":"null","additionalProperties":{"title":"Channel","type":"object","properties":{"brand_id":{"oneOf":[{"type":"string","description":"Brand id used for rendering.","uniqueKey":"channels.oneOf.1.additionalProperties.brand_id.oneOf.0","typeLabel":"string"},{"type":"null","description":"Brand id used for rendering.","uniqueKey":"channels.oneOf.1.additionalProperties.brand_id.oneOf.1","typeLabel":"null"}],"uniqueKey":"channels.oneOf.1.additionalProperties.brand_id","typeLabel":"string | null"},"providers":{"oneOf":[{"type":"array","items":{"type":"string","uniqueKey":"channels.oneOf.1.additionalProperties.providers.oneOf.0.items.[INDEX]","typeLabel":"string"},"description":"Providers enabled for this channel.","uniqueKey":"channels.oneOf.1.additionalProperties.providers.oneOf.0","typeLabel":"string[]"},{"type":"null","items":{"type":"string"},"description":"Providers enabled for this channel.","uniqueKey":"channels.oneOf.1.additionalProperties.providers.oneOf.1","typeLabel":"null"}],"uniqueKey":"channels.oneOf.1.additionalProperties.providers","typeLabel":"string[] | null"},"routing_method":{"oneOf":[{"title":"RoutingMethod","type":"string","enum":["all","single"],"description":"Defaults to `single`.","uniqueKey":"channels.oneOf.1.additionalProperties.routing_method.oneOf.0","typeLabel":"enum\u003cstring>"},{"title":"RoutingMethod","type":"null","enum":["all","single"],"description":"Defaults to `single`.","uniqueKey":"channels.oneOf.1.additionalProperties.routing_method.oneOf.1","typeLabel":"null"}],"uniqueKey":"channels.oneOf.1.additionalProperties.routing_method","typeLabel":"enum\u003cstring> | null"},"if":{"oneOf":[{"type":"string","description":"JS conditional with access to data/profile.","uniqueKey":"channels.oneOf.1.additionalProperties.if.oneOf.0","typeLabel":"string"},{"type":"null","description":"JS conditional with access to data/profile.","uniqueKey":"channels.oneOf.1.additionalProperties.if.oneOf.1","typeLabel":"null"}],"uniqueKey":"channels.oneOf.1.additionalProperties.if","typeLabel":"string | null"},"timeouts":{"oneOf":[{"title":"Timeouts","type":"object","properties":{"provider":{"oneOf":[{"type":"integer","uniqueKey":"channels.oneOf.1.additionalProperties.timeouts.oneOf.0.provider.oneOf.0","typeLabel":"integer"},{"type":"null","uniqueKey":"channels.oneOf.1.additionalProperties.timeouts.oneOf.0.provider.oneOf.1","typeLabel":"null"}],"uniqueKey":"channels.oneOf.1.additionalProperties.timeouts.oneOf.0.provider","typeLabel":"integer | null"},"channel":{"oneOf":[{"type":"integer","uniqueKey":"channels.oneOf.1.additionalProperties.timeouts.oneOf.0.channel.oneOf.0","typeLabel":"integer"},{"type":"null","uniqueKey":"channels.oneOf.1.additionalProperties.timeouts.oneOf.0.channel.oneOf.1","typeLabel":"null"}],"uniqueKey":"channels.oneOf.1.additionalProperties.timeouts.oneOf.0.channel","typeLabel":"integer | null"}},"x-stainless-naming":{"csharp":{"type_name":"ChannelTimeouts"}},"uniqueKey":"channels.oneOf.1.additionalProperties.timeouts.oneOf.0","typeLabel":"Timeouts · object"},{"title":"Timeouts","type":"null","properties":{"provider":{"oneOf":[{"type":"integer"},{"type":"null"}]},"channel":{"oneOf":[{"type":"integer"},{"type":"null"}]}},"x-stainless-naming":{"csharp":{"type_name":"ChannelTimeouts"}},"uniqueKey":"channels.oneOf.1.additionalProperties.timeouts.oneOf.1","typeLabel":"null"}],"uniqueKey":"channels.oneOf.1.additionalProperties.timeouts","typeLabel":"Timeouts · object | null"},"override":{"oneOf":[{"type":"object","additionalProperties":true,"description":"Channel specific overrides.","uniqueKey":"channels.oneOf.1.additionalProperties.override.oneOf.0","typeLabel":"object"},{"type":"null","additionalProperties":true,"description":"Channel specific overrides.","uniqueKey":"channels.oneOf.1.additionalProperties.override.oneOf.1","typeLabel":"null"}],"uniqueKey":"channels.oneOf.1.additionalProperties.override","typeLabel":"object | null"},"metadata":{"oneOf":[{"title":"ChannelMetadata","type":"object","properties":{"utm":{"oneOf":[{"title":"UTM","type":"object","properties":{"source":{"oneOf":[{"type":"string","uniqueKey":"channels.oneOf.1.additionalProperties.metadata.oneOf.0.utm.oneOf.0.source.oneOf.0","typeLabel":"string"},{"type":"null","uniqueKey":"channels.oneOf.1.additionalProperties.metadata.oneOf.0.utm.oneOf.0.source.oneOf.1","typeLabel":"null"}],"uniqueKey":"channels.oneOf.1.additionalProperties.metadata.oneOf.0.utm.oneOf.0.source","typeLabel":"string | null"},"medium":{"oneOf":[{"type":"string","uniqueKey":"channels.oneOf.1.additionalProperties.metadata.oneOf.0.utm.oneOf.0.medium.oneOf.0","typeLabel":"string"},{"type":"null","uniqueKey":"channels.oneOf.1.additionalProperties.metadata.oneOf.0.utm.oneOf.0.medium.oneOf.1","typeLabel":"null"}],"uniqueKey":"channels.oneOf.1.additionalProperties.metadata.oneOf.0.utm.oneOf.0.medium","typeLabel":"string | null"},"campaign":{"oneOf":[{"type":"string","uniqueKey":"channels.oneOf.1.additionalProperties.metadata.oneOf.0.utm.oneOf.0.campaign.oneOf.0","typeLabel":"string"},{"type":"null","uniqueKey":"channels.oneOf.1.additionalProperties.metadata.oneOf.0.utm.oneOf.0.campaign.oneOf.1","typeLabel":"null"}],"uniqueKey":"channels.oneOf.1.additionalProperties.metadata.oneOf.0.utm.oneOf.0.campaign","typeLabel":"string | null"},"term":{"oneOf":[{"type":"string","uniqueKey":"channels.oneOf.1.additionalProperties.metadata.oneOf.0.utm.oneOf.0.term.oneOf.0","typeLabel":"string"},{"type":"null","uniqueKey":"channels.oneOf.1.additionalProperties.metadata.oneOf.0.utm.oneOf.0.term.oneOf.1","typeLabel":"null"}],"uniqueKey":"channels.oneOf.1.additionalProperties.metadata.oneOf.0.utm.oneOf.0.term","typeLabel":"string | null"},"content":{"oneOf":[{"type":"string","uniqueKey":"channels.oneOf.1.additionalProperties.metadata.oneOf.0.utm.oneOf.0.content.oneOf.0","typeLabel":"string"},{"type":"null","uniqueKey":"channels.oneOf.1.additionalProperties.metadata.oneOf.0.utm.oneOf.0.content.oneOf.1","typeLabel":"null"}],"uniqueKey":"channels.oneOf.1.additionalProperties.metadata.oneOf.0.utm.oneOf.0.content","typeLabel":"string | null"}},"uniqueKey":"channels.oneOf.1.additionalProperties.metadata.oneOf.0.utm.oneOf.0","typeLabel":"UTM · object"},{"title":"UTM","type":"null","properties":{"source":{"oneOf":[{"type":"string"},{"type":"null"}]},"medium":{"oneOf":[{"type":"string"},{"type":"null"}]},"campaign":{"oneOf":[{"type":"string"},{"type":"null"}]},"term":{"oneOf":[{"type":"string"},{"type":"null"}]},"content":{"oneOf":[{"type":"string"},{"type":"null"}]}},"uniqueKey":"channels.oneOf.1.additionalProperties.metadata.oneOf.0.utm.oneOf.1","typeLabel":"null"}],"uniqueKey":"channels.oneOf.1.additionalProperties.metadata.oneOf.0.utm","typeLabel":"UTM · object | null"}},"uniqueKey":"channels.oneOf.1.additionalProperties.metadata.oneOf.0","typeLabel":"ChannelMetadata · object"},{"title":"ChannelMetadata","type":"null","properties":{"utm":{"oneOf":[{"title":"UTM","type":"object","properties":{"source":{"oneOf":[{"type":"string"},{"type":"null"}]},"medium":{"oneOf":[{"type":"string"},{"type":"null"}]},"campaign":{"oneOf":[{"type":"string"},{"type":"null"}]},"term":{"oneOf":[{"type":"string"},{"type":"null"}]},"content":{"oneOf":[{"type":"string"},{"type":"null"}]}}},{"title":"UTM","type":"null","properties":{"source":{"oneOf":[{"type":"string"},{"type":"null"}]},"medium":{"oneOf":[{"type":"string"},{"type":"null"}]},"campaign":{"oneOf":[{"type":"string"},{"type":"null"}]},"term":{"oneOf":[{"type":"string"},{"type":"null"}]},"content":{"oneOf":[{"type":"string"},{"type":"null"}]}}}]}},"uniqueKey":"channels.oneOf.1.additionalProperties.metadata.oneOf.1","typeLabel":"null"}],"uniqueKey":"channels.oneOf.1.additionalProperties.metadata","typeLabel":"ChannelMetadata · object | null"}},"x-stainless-naming":{"csharp":{"type_name":"MessageChannel"}},"uniqueKey":"channels.oneOf.1.additionalProperties","typeLabel":"Channel · object"},"description":"Per-channel delivery configuration. Defaults to empty if omitted.","uniqueKey":"channels.oneOf.1","typeLabel":"null"}],"uniqueKey":"channels","typeLabel":"MessageChannels · object | null"},"providers":{"oneOf":[{"title":"MessageProviders","type":"object","additionalProperties":{"title":"MessageProvidersType","type":"object","properties":{"override":{"oneOf":[{"type":"object","additionalProperties":true,"description":"Provider-specific overrides.","uniqueKey":"providers.oneOf.0.additionalProperties.override.oneOf.0","typeLabel":"object"},{"type":"null","additionalProperties":true,"description":"Provider-specific overrides.","uniqueKey":"providers.oneOf.0.additionalProperties.override.oneOf.1","typeLabel":"null"}],"uniqueKey":"providers.oneOf.0.additionalProperties.override","typeLabel":"object | null"},"if":{"oneOf":[{"type":"string","description":"JS conditional with access to data/profile.","uniqueKey":"providers.oneOf.0.additionalProperties.if.oneOf.0","typeLabel":"string"},{"type":"null","description":"JS conditional with access to data/profile.","uniqueKey":"providers.oneOf.0.additionalProperties.if.oneOf.1","typeLabel":"null"}],"uniqueKey":"providers.oneOf.0.additionalProperties.if","typeLabel":"string | null"},"timeouts":{"oneOf":[{"type":"integer","uniqueKey":"providers.oneOf.0.additionalProperties.timeouts.oneOf.0","typeLabel":"integer"},{"type":"null","uniqueKey":"providers.oneOf.0.additionalProperties.timeouts.oneOf.1","typeLabel":"null"}],"uniqueKey":"providers.oneOf.0.additionalProperties.timeouts","typeLabel":"integer | null"},"metadata":{"oneOf":[{"title":"Metadata","type":"object","properties":{"utm":{"oneOf":[{"title":"UTM","type":"object","properties":{"source":{"oneOf":[{"type":"string","uniqueKey":"providers.oneOf.0.additionalProperties.metadata.oneOf.0.utm.oneOf.0.source.oneOf.0","typeLabel":"string"},{"type":"null","uniqueKey":"providers.oneOf.0.additionalProperties.metadata.oneOf.0.utm.oneOf.0.source.oneOf.1","typeLabel":"null"}],"uniqueKey":"providers.oneOf.0.additionalProperties.metadata.oneOf.0.utm.oneOf.0.source","typeLabel":"string | null"},"medium":{"oneOf":[{"type":"string","uniqueKey":"providers.oneOf.0.additionalProperties.metadata.oneOf.0.utm.oneOf.0.medium.oneOf.0","typeLabel":"string"},{"type":"null","uniqueKey":"providers.oneOf.0.additionalProperties.metadata.oneOf.0.utm.oneOf.0.medium.oneOf.1","typeLabel":"null"}],"uniqueKey":"providers.oneOf.0.additionalProperties.metadata.oneOf.0.utm.oneOf.0.medium","typeLabel":"string | null"},"campaign":{"oneOf":[{"type":"string","uniqueKey":"providers.oneOf.0.additionalProperties.metadata.oneOf.0.utm.oneOf.0.campaign.oneOf.0","typeLabel":"string"},{"type":"null","uniqueKey":"providers.oneOf.0.additionalProperties.metadata.oneOf.0.utm.oneOf.0.campaign.oneOf.1","typeLabel":"null"}],"uniqueKey":"providers.oneOf.0.additionalProperties.metadata.oneOf.0.utm.oneOf.0.campaign","typeLabel":"string | null"},"term":{"oneOf":[{"type":"string","uniqueKey":"providers.oneOf.0.additionalProperties.metadata.oneOf.0.utm.oneOf.0.term.oneOf.0","typeLabel":"string"},{"type":"null","uniqueKey":"providers.oneOf.0.additionalProperties.metadata.oneOf.0.utm.oneOf.0.term.oneOf.1","typeLabel":"null"}],"uniqueKey":"providers.oneOf.0.additionalProperties.metadata.oneOf.0.utm.oneOf.0.term","typeLabel":"string | null"},"content":{"oneOf":[{"type":"string","uniqueKey":"providers.oneOf.0.additionalProperties.metadata.oneOf.0.utm.oneOf.0.content.oneOf.0","typeLabel":"string"},{"type":"null","uniqueKey":"providers.oneOf.0.additionalProperties.metadata.oneOf.0.utm.oneOf.0.content.oneOf.1","typeLabel":"null"}],"uniqueKey":"providers.oneOf.0.additionalProperties.metadata.oneOf.0.utm.oneOf.0.content","typeLabel":"string | null"}},"uniqueKey":"providers.oneOf.0.additionalProperties.metadata.oneOf.0.utm.oneOf.0","typeLabel":"UTM · object"},{"title":"UTM","type":"null","properties":{"source":{"oneOf":[{"type":"string"},{"type":"null"}]},"medium":{"oneOf":[{"type":"string"},{"type":"null"}]},"campaign":{"oneOf":[{"type":"string"},{"type":"null"}]},"term":{"oneOf":[{"type":"string"},{"type":"null"}]},"content":{"oneOf":[{"type":"string"},{"type":"null"}]}},"uniqueKey":"providers.oneOf.0.additionalProperties.metadata.oneOf.0.utm.oneOf.1","typeLabel":"null"}],"uniqueKey":"providers.oneOf.0.additionalProperties.metadata.oneOf.0.utm","typeLabel":"UTM · object | null"}},"x-stainless-naming":{"csharp":{"type_name":"ProviderMetadata"}},"uniqueKey":"providers.oneOf.0.additionalProperties.metadata.oneOf.0","typeLabel":"Metadata · object"},{"title":"Metadata","type":"null","properties":{"utm":{"oneOf":[{"title":"UTM","type":"object","properties":{"source":{"oneOf":[{"type":"string"},{"type":"null"}]},"medium":{"oneOf":[{"type":"string"},{"type":"null"}]},"campaign":{"oneOf":[{"type":"string"},{"type":"null"}]},"term":{"oneOf":[{"type":"string"},{"type":"null"}]},"content":{"oneOf":[{"type":"string"},{"type":"null"}]}}},{"title":"UTM","type":"null","properties":{"source":{"oneOf":[{"type":"string"},{"type":"null"}]},"medium":{"oneOf":[{"type":"string"},{"type":"null"}]},"campaign":{"oneOf":[{"type":"string"},{"type":"null"}]},"term":{"oneOf":[{"type":"string"},{"type":"null"}]},"content":{"oneOf":[{"type":"string"},{"type":"null"}]}}}]}},"x-stainless-naming":{"csharp":{"type_name":"ProviderMetadata"}},"uniqueKey":"providers.oneOf.0.additionalProperties.metadata.oneOf.1","typeLabel":"null"}],"uniqueKey":"providers.oneOf.0.additionalProperties.metadata","typeLabel":"Metadata · object | null"}},"uniqueKey":"providers.oneOf.0.additionalProperties","typeLabel":"MessageProvidersType · object"},"description":"Per-provider delivery configuration. Defaults to empty if omitted.","uniqueKey":"providers.oneOf.0","typeLabel":"MessageProviders · object"},{"title":"MessageProviders","type":"null","additionalProperties":{"title":"MessageProvidersType","type":"object","properties":{"override":{"oneOf":[{"type":"object","additionalProperties":true,"description":"Provider-specific overrides.","uniqueKey":"providers.oneOf.1.additionalProperties.override.oneOf.0","typeLabel":"object"},{"type":"null","additionalProperties":true,"description":"Provider-specific overrides.","uniqueKey":"providers.oneOf.1.additionalProperties.override.oneOf.1","typeLabel":"null"}],"uniqueKey":"providers.oneOf.1.additionalProperties.override","typeLabel":"object | null"},"if":{"oneOf":[{"type":"string","description":"JS conditional with access to data/profile.","uniqueKey":"providers.oneOf.1.additionalProperties.if.oneOf.0","typeLabel":"string"},{"type":"null","description":"JS conditional with access to data/profile.","uniqueKey":"providers.oneOf.1.additionalProperties.if.oneOf.1","typeLabel":"null"}],"uniqueKey":"providers.oneOf.1.additionalProperties.if","typeLabel":"string | null"},"timeouts":{"oneOf":[{"type":"integer","uniqueKey":"providers.oneOf.1.additionalProperties.timeouts.oneOf.0","typeLabel":"integer"},{"type":"null","uniqueKey":"providers.oneOf.1.additionalProperties.timeouts.oneOf.1","typeLabel":"null"}],"uniqueKey":"providers.oneOf.1.additionalProperties.timeouts","typeLabel":"integer | null"},"metadata":{"oneOf":[{"title":"Metadata","type":"object","properties":{"utm":{"oneOf":[{"title":"UTM","type":"object","properties":{"source":{"oneOf":[{"type":"string","uniqueKey":"providers.oneOf.1.additionalProperties.metadata.oneOf.0.utm.oneOf.0.source.oneOf.0","typeLabel":"string"},{"type":"null","uniqueKey":"providers.oneOf.1.additionalProperties.metadata.oneOf.0.utm.oneOf.0.source.oneOf.1","typeLabel":"null"}],"uniqueKey":"providers.oneOf.1.additionalProperties.metadata.oneOf.0.utm.oneOf.0.source","typeLabel":"string | null"},"medium":{"oneOf":[{"type":"string","uniqueKey":"providers.oneOf.1.additionalProperties.metadata.oneOf.0.utm.oneOf.0.medium.oneOf.0","typeLabel":"string"},{"type":"null","uniqueKey":"providers.oneOf.1.additionalProperties.metadata.oneOf.0.utm.oneOf.0.medium.oneOf.1","typeLabel":"null"}],"uniqueKey":"providers.oneOf.1.additionalProperties.metadata.oneOf.0.utm.oneOf.0.medium","typeLabel":"string | null"},"campaign":{"oneOf":[{"type":"string","uniqueKey":"providers.oneOf.1.additionalProperties.metadata.oneOf.0.utm.oneOf.0.campaign.oneOf.0","typeLabel":"string"},{"type":"null","uniqueKey":"providers.oneOf.1.additionalProperties.metadata.oneOf.0.utm.oneOf.0.campaign.oneOf.1","typeLabel":"null"}],"uniqueKey":"providers.oneOf.1.additionalProperties.metadata.oneOf.0.utm.oneOf.0.campaign","typeLabel":"string | null"},"term":{"oneOf":[{"type":"string","uniqueKey":"providers.oneOf.1.additionalProperties.metadata.oneOf.0.utm.oneOf.0.term.oneOf.0","typeLabel":"string"},{"type":"null","uniqueKey":"providers.oneOf.1.additionalProperties.metadata.oneOf.0.utm.oneOf.0.term.oneOf.1","typeLabel":"null"}],"uniqueKey":"providers.oneOf.1.additionalProperties.metadata.oneOf.0.utm.oneOf.0.term","typeLabel":"string | null"},"content":{"oneOf":[{"type":"string","uniqueKey":"providers.oneOf.1.additionalProperties.metadata.oneOf.0.utm.oneOf.0.content.oneOf.0","typeLabel":"string"},{"type":"null","uniqueKey":"providers.oneOf.1.additionalProperties.metadata.oneOf.0.utm.oneOf.0.content.oneOf.1","typeLabel":"null"}],"uniqueKey":"providers.oneOf.1.additionalProperties.metadata.oneOf.0.utm.oneOf.0.content","typeLabel":"string | null"}},"uniqueKey":"providers.oneOf.1.additionalProperties.metadata.oneOf.0.utm.oneOf.0","typeLabel":"UTM · object"},{"title":"UTM","type":"null","properties":{"source":{"oneOf":[{"type":"string"},{"type":"null"}]},"medium":{"oneOf":[{"type":"string"},{"type":"null"}]},"campaign":{"oneOf":[{"type":"string"},{"type":"null"}]},"term":{"oneOf":[{"type":"string"},{"type":"null"}]},"content":{"oneOf":[{"type":"string"},{"type":"null"}]}},"uniqueKey":"providers.oneOf.1.additionalProperties.metadata.oneOf.0.utm.oneOf.1","typeLabel":"null"}],"uniqueKey":"providers.oneOf.1.additionalProperties.metadata.oneOf.0.utm","typeLabel":"UTM · object | null"}},"x-stainless-naming":{"csharp":{"type_name":"ProviderMetadata"}},"uniqueKey":"providers.oneOf.1.additionalProperties.metadata.oneOf.0","typeLabel":"Metadata · object"},{"title":"Metadata","type":"null","properties":{"utm":{"oneOf":[{"title":"UTM","type":"object","properties":{"source":{"oneOf":[{"type":"string"},{"type":"null"}]},"medium":{"oneOf":[{"type":"string"},{"type":"null"}]},"campaign":{"oneOf":[{"type":"string"},{"type":"null"}]},"term":{"oneOf":[{"type":"string"},{"type":"null"}]},"content":{"oneOf":[{"type":"string"},{"type":"null"}]}}},{"title":"UTM","type":"null","properties":{"source":{"oneOf":[{"type":"string"},{"type":"null"}]},"medium":{"oneOf":[{"type":"string"},{"type":"null"}]},"campaign":{"oneOf":[{"type":"string"},{"type":"null"}]},"term":{"oneOf":[{"type":"string"},{"type":"null"}]},"content":{"oneOf":[{"type":"string"},{"type":"null"}]}}}]}},"x-stainless-naming":{"csharp":{"type_name":"ProviderMetadata"}},"uniqueKey":"providers.oneOf.1.additionalProperties.metadata.oneOf.1","typeLabel":"null"}],"uniqueKey":"providers.oneOf.1.additionalProperties.metadata","typeLabel":"Metadata · object | null"}},"uniqueKey":"providers.oneOf.1.additionalProperties","typeLabel":"MessageProvidersType · object"},"description":"Per-provider delivery configuration. Defaults to empty if omitted.","uniqueKey":"providers.oneOf.1","typeLabel":"null"}],"uniqueKey":"providers","typeLabel":"MessageProviders · object | null"}},"required":["name","routing"],"uniqueKey":"","typeLabel":"RoutingStrategyCreateRequest · object"},"examples":{"FullExample":{"title":"FullExample","value":{"name":"Email via SendGrid","description":"Routes email through sendgrid with SES failover","tags":["production","email"],"routing":{"method":"single","channels":["email"]},"channels":{"email":{"providers":["sendgrid","ses"]}},"providers":{"sendgrid":{"override":{}}}}},"Minimal":{"title":"Minimal","value":{"name":"Simple Email","routing":{"method":"single","channels":["email"]}}}},"exampleType":"examples"}},"exampleType":"examples"},"responses":{"32bc442e-805d-455a-85f7-b1f098dc95e0":{"description":"Created","content":{"application/json":{"schema":{"title":"RoutingStrategyGetResponse","type":"object","description":"Full routing strategy entity returned by GET.","properties":{"id":{"type":"string","description":"The routing strategy ID (rs_ prefix).","isRequired":true,"uniqueKey":"id","typeLabel":"string"},"name":{"type":"string","description":"Human-readable name.","isRequired":true,"uniqueKey":"name","typeLabel":"string"},"routing":{"title":"MessageRouting","type":"object","properties":{"method":{"title":"MessageRoutingMethod","type":"string","enum":["all","single"],"isRequired":true,"uniqueKey":"routing.method","typeLabel":"enum\u003cstring>"},"channels":{"type":"array","items":{"oneOf":[{"type":"string","title":"MessageRoutingChannel","uniqueKey":"routing.channels.items.[INDEX].oneOf.0","typeLabel":"string"},{"title":"MessageRoutingChannel"}],"uniqueKey":"routing.channels.items.[INDEX]","typeLabel":"string"},"isRequired":true,"uniqueKey":"routing.channels","typeLabel":"string[]"}},"required":["method","channels"],"description":"Routing tree defining channel selection method and order.","isRequired":true,"uniqueKey":"routing","typeLabel":"MessageRouting · object"},"channels":{"title":"MessageChannels","type":"object","additionalProperties":{"title":"Channel","type":"object","properties":{"brand_id":{"oneOf":[{"type":"string","description":"Brand id used for rendering.","uniqueKey":"channels.additionalProperties.brand_id.oneOf.0","typeLabel":"string"},{"type":"null","description":"Brand id used for rendering.","uniqueKey":"channels.additionalProperties.brand_id.oneOf.1","typeLabel":"null"}],"uniqueKey":"channels.additionalProperties.brand_id","typeLabel":"string | null"},"providers":{"oneOf":[{"type":"array","items":{"type":"string","uniqueKey":"channels.additionalProperties.providers.oneOf.0.items.[INDEX]","typeLabel":"string"},"description":"Providers enabled for this channel.","uniqueKey":"channels.additionalProperties.providers.oneOf.0","typeLabel":"string[]"},{"type":"null","items":{"type":"string"},"description":"Providers enabled for this channel.","uniqueKey":"channels.additionalProperties.providers.oneOf.1","typeLabel":"null"}],"uniqueKey":"channels.additionalProperties.providers","typeLabel":"string[] | null"},"routing_method":{"oneOf":[{"title":"RoutingMethod","type":"string","enum":["all","single"],"description":"Defaults to `single`.","uniqueKey":"channels.additionalProperties.routing_method.oneOf.0","typeLabel":"enum\u003cstring>"},{"title":"RoutingMethod","type":"null","enum":["all","single"],"description":"Defaults to `single`.","uniqueKey":"channels.additionalProperties.routing_method.oneOf.1","typeLabel":"null"}],"uniqueKey":"channels.additionalProperties.routing_method","typeLabel":"enum\u003cstring> | null"},"if":{"oneOf":[{"type":"string","description":"JS conditional with access to data/profile.","uniqueKey":"channels.additionalProperties.if.oneOf.0","typeLabel":"string"},{"type":"null","description":"JS conditional with access to data/profile.","uniqueKey":"channels.additionalProperties.if.oneOf.1","typeLabel":"null"}],"uniqueKey":"channels.additionalProperties.if","typeLabel":"string | null"},"timeouts":{"oneOf":[{"title":"Timeouts","type":"object","properties":{"provider":{"oneOf":[{"type":"integer","uniqueKey":"channels.additionalProperties.timeouts.oneOf.0.provider.oneOf.0","typeLabel":"integer"},{"type":"null","uniqueKey":"channels.additionalProperties.timeouts.oneOf.0.provider.oneOf.1","typeLabel":"null"}],"uniqueKey":"channels.additionalProperties.timeouts.oneOf.0.provider","typeLabel":"integer | null"},"channel":{"oneOf":[{"type":"integer","uniqueKey":"channels.additionalProperties.timeouts.oneOf.0.channel.oneOf.0","typeLabel":"integer"},{"type":"null","uniqueKey":"channels.additionalProperties.timeouts.oneOf.0.channel.oneOf.1","typeLabel":"null"}],"uniqueKey":"channels.additionalProperties.timeouts.oneOf.0.channel","typeLabel":"integer | null"}},"x-stainless-naming":{"csharp":{"type_name":"ChannelTimeouts"}},"uniqueKey":"channels.additionalProperties.timeouts.oneOf.0","typeLabel":"Timeouts · object"},{"title":"Timeouts","type":"null","properties":{"provider":{"oneOf":[{"type":"integer"},{"type":"null"}]},"channel":{"oneOf":[{"type":"integer"},{"type":"null"}]}},"x-stainless-naming":{"csharp":{"type_name":"ChannelTimeouts"}},"uniqueKey":"channels.additionalProperties.timeouts.oneOf.1","typeLabel":"null"}],"uniqueKey":"channels.additionalProperties.timeouts","typeLabel":"Timeouts · object | null"},"override":{"oneOf":[{"type":"object","additionalProperties":true,"description":"Channel specific overrides.","uniqueKey":"channels.additionalProperties.override.oneOf.0","typeLabel":"object"},{"type":"null","additionalProperties":true,"description":"Channel specific overrides.","uniqueKey":"channels.additionalProperties.override.oneOf.1","typeLabel":"null"}],"uniqueKey":"channels.additionalProperties.override","typeLabel":"object | null"},"metadata":{"oneOf":[{"title":"ChannelMetadata","type":"object","properties":{"utm":{"oneOf":[{"title":"UTM","type":"object","properties":{"source":{"oneOf":[{"type":"string","uniqueKey":"channels.additionalProperties.metadata.oneOf.0.utm.oneOf.0.source.oneOf.0","typeLabel":"string"},{"type":"null","uniqueKey":"channels.additionalProperties.metadata.oneOf.0.utm.oneOf.0.source.oneOf.1","typeLabel":"null"}],"uniqueKey":"channels.additionalProperties.metadata.oneOf.0.utm.oneOf.0.source","typeLabel":"string | null"},"medium":{"oneOf":[{"type":"string","uniqueKey":"channels.additionalProperties.metadata.oneOf.0.utm.oneOf.0.medium.oneOf.0","typeLabel":"string"},{"type":"null","uniqueKey":"channels.additionalProperties.metadata.oneOf.0.utm.oneOf.0.medium.oneOf.1","typeLabel":"null"}],"uniqueKey":"channels.additionalProperties.metadata.oneOf.0.utm.oneOf.0.medium","typeLabel":"string | null"},"campaign":{"oneOf":[{"type":"string","uniqueKey":"channels.additionalProperties.metadata.oneOf.0.utm.oneOf.0.campaign.oneOf.0","typeLabel":"string"},{"type":"null","uniqueKey":"channels.additionalProperties.metadata.oneOf.0.utm.oneOf.0.campaign.oneOf.1","typeLabel":"null"}],"uniqueKey":"channels.additionalProperties.metadata.oneOf.0.utm.oneOf.0.campaign","typeLabel":"string | null"},"term":{"oneOf":[{"type":"string","uniqueKey":"channels.additionalProperties.metadata.oneOf.0.utm.oneOf.0.term.oneOf.0","typeLabel":"string"},{"type":"null","uniqueKey":"channels.additionalProperties.metadata.oneOf.0.utm.oneOf.0.term.oneOf.1","typeLabel":"null"}],"uniqueKey":"channels.additionalProperties.metadata.oneOf.0.utm.oneOf.0.term","typeLabel":"string | null"},"content":{"oneOf":[{"type":"string","uniqueKey":"channels.additionalProperties.metadata.oneOf.0.utm.oneOf.0.content.oneOf.0","typeLabel":"string"},{"type":"null","uniqueKey":"channels.additionalProperties.metadata.oneOf.0.utm.oneOf.0.content.oneOf.1","typeLabel":"null"}],"uniqueKey":"channels.additionalProperties.metadata.oneOf.0.utm.oneOf.0.content","typeLabel":"string | null"}},"uniqueKey":"channels.additionalProperties.metadata.oneOf.0.utm.oneOf.0","typeLabel":"UTM · object"},{"title":"UTM","type":"null","properties":{"source":{"oneOf":[{"type":"string"},{"type":"null"}]},"medium":{"oneOf":[{"type":"string"},{"type":"null"}]},"campaign":{"oneOf":[{"type":"string"},{"type":"null"}]},"term":{"oneOf":[{"type":"string"},{"type":"null"}]},"content":{"oneOf":[{"type":"string"},{"type":"null"}]}},"uniqueKey":"channels.additionalProperties.metadata.oneOf.0.utm.oneOf.1","typeLabel":"null"}],"uniqueKey":"channels.additionalProperties.metadata.oneOf.0.utm","typeLabel":"UTM · object | null"}},"uniqueKey":"channels.additionalProperties.metadata.oneOf.0","typeLabel":"ChannelMetadata · object"},{"title":"ChannelMetadata","type":"null","properties":{"utm":{"oneOf":[{"title":"UTM","type":"object","properties":{"source":{"oneOf":[{"type":"string"},{"type":"null"}]},"medium":{"oneOf":[{"type":"string"},{"type":"null"}]},"campaign":{"oneOf":[{"type":"string"},{"type":"null"}]},"term":{"oneOf":[{"type":"string"},{"type":"null"}]},"content":{"oneOf":[{"type":"string"},{"type":"null"}]}}},{"title":"UTM","type":"null","properties":{"source":{"oneOf":[{"type":"string"},{"type":"null"}]},"medium":{"oneOf":[{"type":"string"},{"type":"null"}]},"campaign":{"oneOf":[{"type":"string"},{"type":"null"}]},"term":{"oneOf":[{"type":"string"},{"type":"null"}]},"content":{"oneOf":[{"type":"string"},{"type":"null"}]}}}]}},"uniqueKey":"channels.additionalProperties.metadata.oneOf.1","typeLabel":"null"}],"uniqueKey":"channels.additionalProperties.metadata","typeLabel":"ChannelMetadata · object | null"}},"x-stainless-naming":{"csharp":{"type_name":"MessageChannel"}},"uniqueKey":"channels.additionalProperties","typeLabel":"Channel · object"},"description":"Per-channel delivery configuration. May be empty.","isRequired":true,"uniqueKey":"channels","typeLabel":"MessageChannels · object"},"providers":{"title":"MessageProviders","type":"object","additionalProperties":{"title":"MessageProvidersType","type":"object","properties":{"override":{"oneOf":[{"type":"object","additionalProperties":true,"description":"Provider-specific overrides.","uniqueKey":"providers.additionalProperties.override.oneOf.0","typeLabel":"object"},{"type":"null","additionalProperties":true,"description":"Provider-specific overrides.","uniqueKey":"providers.additionalProperties.override.oneOf.1","typeLabel":"null"}],"uniqueKey":"providers.additionalProperties.override","typeLabel":"object | null"},"if":{"oneOf":[{"type":"string","description":"JS conditional with access to data/profile.","uniqueKey":"providers.additionalProperties.if.oneOf.0","typeLabel":"string"},{"type":"null","description":"JS conditional with access to data/profile.","uniqueKey":"providers.additionalProperties.if.oneOf.1","typeLabel":"null"}],"uniqueKey":"providers.additionalProperties.if","typeLabel":"string | null"},"timeouts":{"oneOf":[{"type":"integer","uniqueKey":"providers.additionalProperties.timeouts.oneOf.0","typeLabel":"integer"},{"type":"null","uniqueKey":"providers.additionalProperties.timeouts.oneOf.1","typeLabel":"null"}],"uniqueKey":"providers.additionalProperties.timeouts","typeLabel":"integer | null"},"metadata":{"oneOf":[{"title":"Metadata","type":"object","properties":{"utm":{"oneOf":[{"title":"UTM","type":"object","properties":{"source":{"oneOf":[{"type":"string","uniqueKey":"providers.additionalProperties.metadata.oneOf.0.utm.oneOf.0.source.oneOf.0","typeLabel":"string"},{"type":"null","uniqueKey":"providers.additionalProperties.metadata.oneOf.0.utm.oneOf.0.source.oneOf.1","typeLabel":"null"}],"uniqueKey":"providers.additionalProperties.metadata.oneOf.0.utm.oneOf.0.source","typeLabel":"string | null"},"medium":{"oneOf":[{"type":"string","uniqueKey":"providers.additionalProperties.metadata.oneOf.0.utm.oneOf.0.medium.oneOf.0","typeLabel":"string"},{"type":"null","uniqueKey":"providers.additionalProperties.metadata.oneOf.0.utm.oneOf.0.medium.oneOf.1","typeLabel":"null"}],"uniqueKey":"providers.additionalProperties.metadata.oneOf.0.utm.oneOf.0.medium","typeLabel":"string | null"},"campaign":{"oneOf":[{"type":"string","uniqueKey":"providers.additionalProperties.metadata.oneOf.0.utm.oneOf.0.campaign.oneOf.0","typeLabel":"string"},{"type":"null","uniqueKey":"providers.additionalProperties.metadata.oneOf.0.utm.oneOf.0.campaign.oneOf.1","typeLabel":"null"}],"uniqueKey":"providers.additionalProperties.metadata.oneOf.0.utm.oneOf.0.campaign","typeLabel":"string | null"},"term":{"oneOf":[{"type":"string","uniqueKey":"providers.additionalProperties.metadata.oneOf.0.utm.oneOf.0.term.oneOf.0","typeLabel":"string"},{"type":"null","uniqueKey":"providers.additionalProperties.metadata.oneOf.0.utm.oneOf.0.term.oneOf.1","typeLabel":"null"}],"uniqueKey":"providers.additionalProperties.metadata.oneOf.0.utm.oneOf.0.term","typeLabel":"string | null"},"content":{"oneOf":[{"type":"string","uniqueKey":"providers.additionalProperties.metadata.oneOf.0.utm.oneOf.0.content.oneOf.0","typeLabel":"string"},{"type":"null","uniqueKey":"providers.additionalProperties.metadata.oneOf.0.utm.oneOf.0.content.oneOf.1","typeLabel":"null"}],"uniqueKey":"providers.additionalProperties.metadata.oneOf.0.utm.oneOf.0.content","typeLabel":"string | null"}},"uniqueKey":"providers.additionalProperties.metadata.oneOf.0.utm.oneOf.0","typeLabel":"UTM · object"},{"title":"UTM","type":"null","properties":{"source":{"oneOf":[{"type":"string"},{"type":"null"}]},"medium":{"oneOf":[{"type":"string"},{"type":"null"}]},"campaign":{"oneOf":[{"type":"string"},{"type":"null"}]},"term":{"oneOf":[{"type":"string"},{"type":"null"}]},"content":{"oneOf":[{"type":"string"},{"type":"null"}]}},"uniqueKey":"providers.additionalProperties.metadata.oneOf.0.utm.oneOf.1","typeLabel":"null"}],"uniqueKey":"providers.additionalProperties.metadata.oneOf.0.utm","typeLabel":"UTM · object | null"}},"x-stainless-naming":{"csharp":{"type_name":"ProviderMetadata"}},"uniqueKey":"providers.additionalProperties.metadata.oneOf.0","typeLabel":"Metadata · object"},{"title":"Metadata","type":"null","properties":{"utm":{"oneOf":[{"title":"UTM","type":"object","properties":{"source":{"oneOf":[{"type":"string"},{"type":"null"}]},"medium":{"oneOf":[{"type":"string"},{"type":"null"}]},"campaign":{"oneOf":[{"type":"string"},{"type":"null"}]},"term":{"oneOf":[{"type":"string"},{"type":"null"}]},"content":{"oneOf":[{"type":"string"},{"type":"null"}]}}},{"title":"UTM","type":"null","properties":{"source":{"oneOf":[{"type":"string"},{"type":"null"}]},"medium":{"oneOf":[{"type":"string"},{"type":"null"}]},"campaign":{"oneOf":[{"type":"string"},{"type":"null"}]},"term":{"oneOf":[{"type":"string"},{"type":"null"}]},"content":{"oneOf":[{"type":"string"},{"type":"null"}]}}}]}},"x-stainless-naming":{"csharp":{"type_name":"ProviderMetadata"}},"uniqueKey":"providers.additionalProperties.metadata.oneOf.1","typeLabel":"null"}],"uniqueKey":"providers.additionalProperties.metadata","typeLabel":"Metadata · object | null"}},"uniqueKey":"providers.additionalProperties","typeLabel":"MessageProvidersType · object"},"description":"Per-provider delivery configuration. May be empty.","isRequired":true,"uniqueKey":"providers","typeLabel":"MessageProviders · object"},"created":{"type":"integer","format":"int64","description":"Epoch milliseconds when the strategy was created.","isRequired":true,"uniqueKey":"created","typeLabel":"integer\u003cint64>"},"creator":{"type":"string","description":"User ID of the creator.","isRequired":true,"uniqueKey":"creator","typeLabel":"string"},"description":{"oneOf":[{"type":"string","description":"Description of the routing strategy.","uniqueKey":"description.oneOf.0","typeLabel":"string"},{"type":"null","description":"Description of the routing strategy.","uniqueKey":"description.oneOf.1","typeLabel":"null"}],"uniqueKey":"description","typeLabel":"string | null"},"tags":{"oneOf":[{"type":"array","items":{"type":"string","uniqueKey":"tags.oneOf.0.items.[INDEX]","typeLabel":"string"},"description":"Tags for categorization.","uniqueKey":"tags.oneOf.0","typeLabel":"string[]"},{"type":"null","items":{"type":"string"},"description":"Tags for categorization.","uniqueKey":"tags.oneOf.1","typeLabel":"null"}],"uniqueKey":"tags","typeLabel":"string[] | null"},"updated":{"oneOf":[{"type":"integer","format":"int64","description":"Epoch milliseconds of last update.","uniqueKey":"updated.oneOf.0","typeLabel":"integer\u003cint64>"},{"type":"null","format":"int64","description":"Epoch milliseconds of last update.","uniqueKey":"updated.oneOf.1","typeLabel":"null"}],"uniqueKey":"updated","typeLabel":"integer\u003cint64> | null"},"updater":{"oneOf":[{"type":"string","description":"User ID of the last updater.","uniqueKey":"updater.oneOf.0","typeLabel":"string"},{"type":"null","description":"User ID of the last updater.","uniqueKey":"updater.oneOf.1","typeLabel":"null"}],"uniqueKey":"updater","typeLabel":"string | null"}},"required":["id","name","routing","channels","providers","created","creator"],"uniqueKey":"","typeLabel":"RoutingStrategyGetResponse · object"},"examples":{"Example":{"title":"Example","value":{"id":"rs_01kx4h2jdafq8bk9amzvy6hbv0","name":"Example Name","description":"An example description.","tags":["string"],"routing":{"method":"all","channels":["string"]},"channels":{"channels_key":{"brand_id":"bnd_01kx4mrd0pfzw8wt7pn7p2fzag","providers":["string"],"routing_method":"all","if":"string","timeouts":{"provider":1,"channel":1},"override":{},"metadata":{"utm":{"source":"string","medium":"string","campaign":"string","term":"string","content":"string"}}}},"providers":{"providers_key":{"override":{},"if":"string","timeouts":1,"metadata":{"utm":{"source":"string","medium":"string","campaign":"string","term":"string","content":"string"}}}},"created":1,"creator":"user_123","updated":1,"updater":"user_123"}}},"exampleType":"examples"}},"exampleType":"examples"},"fade0145-522a-4086-aa71-4acabcfeabe5":{"description":"Bad Request","content":{"application/json":{"schema":{"type":"object","title":"BadRequest","required":["type","message"],"properties":{"message":{"type":"string","description":"A message describing the error that occurred.","isRequired":true,"uniqueKey":"message","typeLabel":"string"},"type":{"type":"string","enum":["invalid_request_error"],"isRequired":true,"uniqueKey":"type","typeLabel":"enum\u003cstring>"}},"uniqueKey":"","typeLabel":"BadRequest · object"},"examples":{"ValidationError":{"title":"ValidationError","value":{"type":"invalid_request_error","message":"name: Required; routing: Required"}}},"exampleType":"examples"}},"exampleType":"examples"}},"security":{"a93a4e6e-c3ff-4853-89ad-6bc218b82a5b":{"BearerAuth":{"type":"http","scheme":"bearer","scopes":[],"schemeName":"BearerAuth"}}},"servers":{"d796b094-be40-4858-8eb5-01c6e6c3e5f8":{"url":"https://api.courier.com","description":"Production"}},"processedSecurityOptions":[{"schemes":[{"scheme":{"type":"http","scheme":"bearer","scopes":[],"schemeName":"BearerAuth"},"schema":{"title":"Bearer Auth","type":"string","isRequired":true,"description":"Bearer authentication header of the form `Bearer \u003ctoken>`, where `\u003ctoken>` is your auth token.","format":"bearer","typeLabel":"string\u003cbearer>","deprecated":false},"schemeName":"BearerAuth","name":"Authorization"}],"title":"BearerAuth"}]},"originalFileLocation":"openapi-specs/openapi.documented.yml"},"subdomain":"courier-4f1f25dc","siteName":"Courier","title":"Create Routing Strategy - Courier","navMaps":{"firstHrefInVersion":{},"firstHrefInLanguage":{}},"lastModified":"2026-11-12T19:20:05.255Z","originalFileLocation":"api-reference/routing-strategies/create-routing-strategy.mdx"},"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 routing strategy. Requires a name and routing configuration at minimum. Channels and providers default to empty if omitted.\">\u003cmeta data-mint-head name=\"application-name\" content=\"Courier\">\u003cmeta data-mint-head name=\"generator\" content=\"Mintlify\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/docs/mintlify-assets/_mintlify/favicons/courier-4f1f25dc/dyGkQZT6Sxn7ts5C/_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=\"/docs/mintlify-assets/_mintlify/favicons/courier-4f1f25dc/dyGkQZT6Sxn7ts5C/_generated/favicon/apple-touch-icon.png\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/docs/mintlify-assets/_mintlify/favicons/courier-4f1f25dc/dyGkQZT6Sxn7ts5C/_generated/favicon/favicon-16x16.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/docs/mintlify-assets/_mintlify/favicons/courier-4f1f25dc/dyGkQZT6Sxn7ts5C/_generated/favicon/favicon-32x32.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/docs/mintlify-assets/_mintlify/favicons/courier-4f1f25dc/dyGkQZT6Sxn7ts5C/_generated/favicon/favicon.ico\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/docs/mintlify-assets/_mintlify/favicons/courier-4f1f25dc/dyGkQZT6Sxn7ts5C/_generated/favicon-dark/android-chrome-192x192.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/docs/mintlify-assets/_mintlify/favicons/courier-4f1f25dc/dyGkQZT6Sxn7ts5C/_generated/favicon-dark/favicon-16x16.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/docs/mintlify-assets/_mintlify/favicons/courier-4f1f25dc/dyGkQZT6Sxn7ts5C/_generated/favicon-dark/favicon-32x32.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/docs/mintlify-assets/_mintlify/favicons/courier-4f1f25dc/dyGkQZT6Sxn7ts5C/_generated/favicon-dark/favicon.ico\" media=\"(prefers-color-scheme: dark)\">\u003cmeta data-mint-head property=\"og:title\" content=\"Create Routing Strategy - Courier\">\u003cmeta data-mint-head property=\"og:description\" content=\"Create a routing strategy. Requires a name and routing configuration at minimum. Channels and providers default to empty if omitted.\">\u003cmeta data-mint-head property=\"og:site_name\" content=\"Courier\">\u003cmeta data-mint-head property=\"og:url\" content=\"https://www.courier.com/docs/api-reference/routing-strategies/create-routing-strategy\">\u003cmeta data-mint-head property=\"og:type\" content=\"website\">\u003cmeta data-mint-head property=\"og:image\" content=\"https://courier-4f1f25dc.mintlify.site/docs/_mintlify/api/og/v2?division=Routing+Strategies\u0026amp;title=Create+Routing+Strategy\u0026amp;description=Create+a+routing+strategy.+Requires+a+name+and+routing+configuration+at+minimum.+Channels+and+providers+default+to+empty+if+omitted.\u0026amp;theme=fa3857495e51528aa4594a8d\u0026amp;signature=87a1591949d902ba06b40f29f2f2bda095f4fe29b8cd59418f259c99b3db04ad\">\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 Routing Strategy - Courier\">\u003cmeta data-mint-head name=\"twitter:description\" content=\"Create a routing strategy. Requires a name and routing configuration at minimum. Channels and providers default to empty if omitted.\">\u003cmeta data-mint-head name=\"twitter:image\" content=\"https://courier-4f1f25dc.mintlify.site/docs/_mintlify/api/og/v2?division=Routing+Strategies\u0026amp;title=Create+Routing+Strategy\u0026amp;description=Create+a+routing+strategy.+Requires+a+name+and+routing+configuration+at+minimum.+Channels+and+providers+default+to+empty+if+omitted.\u0026amp;theme=fa3857495e51528aa4594a8d\u0026amp;signature=87a1591949d902ba06b40f29f2f2bda095f4fe29b8cd59418f259c99b3db04ad\">\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=\"/docs/mintlify-assets/_mintlify/favicons/courier-4f1f25dc/dyGkQZT6Sxn7ts5C/_generated/favicon/browserconfig.xml\">\u003cmeta data-mint-head name=\"apple-mobile-web-app-title\" content=\"Courier\">\u003cmeta data-mint-head name=\"msapplication-TileColor\" content=\"#7C3AED\">\u003clink data-mint-head rel=\"canonical\" href=\"https://www.courier.com/docs/api-reference/routing-strategies/create-routing-strategy\">\u003clink data-mint-head rel=\"alternate\" type=\"application/xml\" href=\"/docs/sitemap.xml\">\u003clink data-mint-head rel=\"alternate\" type=\"text/markdown\" href=\"/docs/api-reference/routing-strategies/create-routing-strategy.md\">\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@graph\":[{\"@type\":\"Organization\",\"@id\":\"https://www.courier.com/#organization\",\"name\":\"Courier\",\"url\":\"https://www.courier.com\",\"logo\":{\"@type\":\"ImageObject\",\"url\":\"https://mintcdn.com/courier-4f1f25dc/xDJPBS8EQ58X_0-v/assets/logo-light.svg?fit=max\u0026auto=format\u0026n=xDJPBS8EQ58X_0-v\u0026q=85\u0026s=2da40366f40ee5623aeabb98e65c6295\"}},{\"@type\":\"WebSite\",\"@id\":\"https://www.courier.com/docs#website\",\"name\":\"Courier\",\"url\":\"https://www.courier.com/docs\",\"publisher\":{\"@id\":\"https://www.courier.com/#organization\"}},{\"@type\":\"WebPage\",\"@id\":\"https://www.courier.com/docs/api-reference/routing-strategies/create-routing-strategy#webpage\",\"url\":\"https://www.courier.com/docs/api-reference/routing-strategies/create-routing-strategy\",\"name\":\"Create Routing Strategy\",\"description\":\"Create a routing strategy. Requires a name and routing configuration at minimum. Channels and providers default to empty if omitted.\",\"dateModified\":\"2026-11-12T19:20:05.255Z\",\"isPartOf\":{\"@id\":\"https://www.courier.com/docs#website\"},\"breadcrumb\":{\"@id\":\"https://www.courier.com/docs/api-reference/routing-strategies/create-routing-strategy#breadcrumb\"}},{\"@type\":\"BreadcrumbList\",\"@id\":\"https://www.courier.com/docs/api-reference/routing-strategies/create-routing-strategy#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Routing Strategies\",\"item\":\"https://www.courier.com/docs/api-reference/routing-strategies/list-routing-strategies\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Create Routing Strategy\",\"item\":\"https://www.courier.com/docs/api-reference/routing-strategies/create-routing-strategy\"}]},{\"@type\":[\"TechArticle\",\"APIReference\"],\"@id\":\"https://www.courier.com/docs/api-reference/routing-strategies/create-routing-strategy#apireference\",\"headline\":\"Create Routing Strategy\",\"name\":\"Create Routing Strategy\",\"description\":\"Create a routing strategy. Requires a name and routing configuration at minimum. Channels and providers default to empty if omitted.\",\"url\":\"https://www.courier.com/docs/api-reference/routing-strategies/create-routing-strategy\",\"mainEntityOfPage\":{\"@id\":\"https://www.courier.com/docs/api-reference/routing-strategies/create-routing-strategy#webpage\"},\"dateModified\":\"2026-11-12T19:20:05.255Z\",\"publisher\":{\"@id\":\"https://www.courier.com/#organization\"},\"isPartOf\":{\"@id\":\"https://www.courier.com/docs#website\"}}]}\u003c/script>","agentPointerHref":"/docs/api-reference/routing-strategies/create-routing-strategy.md","siteName":"Courier","nav":{"global":null,"tabs":[{"tab":"Docs","icon":"book","pages":[{"title":"Docs","href":"/overview"}]},{"tab":"Guides","icon":"list-check","pages":[{"title":"Guides","href":"/guides/overview"}]},{"tab":"Integrations","icon":"puzzle-piece","pages":[{"title":"Integrations","href":"/integrations/overview"}]},{"tab":"In-App","icon":"inbox","pages":[{"title":"In-App","href":"/in-app/overview"}]},{"tab":"SDKs","icon":"cube","pages":[{"title":"SDKs","href":"/sdk-libraries/sdks-overview"}]},{"tab":"API Reference","icon":"code","groups":[{"group":"Get started","icon":"rocket","pages":[{"title":"Courier API reference","sidebarTitle":"API reference","mode":"wide","href":"/reference/api-overview"}]},{"group":"Send","pages":[{"title":"Send a message","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml post /send","href":"/api-reference/send/send-a-message"}]},{"group":"Templates","pages":[{"title":"List Notification Templates","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /notifications","href":"/api-reference/templates/list-notification-templates"},{"title":"Create Notification Template","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml post /notifications","href":"/api-reference/templates/create-notification-template"},{"title":"Get Notification Template","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /notifications/{id}","href":"/api-reference/templates/get-notification-template"},{"title":"Replace Notification Template","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml put /notifications/{id}","href":"/api-reference/templates/replace-notification-template"},{"title":"Archive Notification Template","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml delete /notifications/{id}","href":"/api-reference/templates/archive-notification-template"},{"title":"List Notification Template Versions","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /notifications/{id}/versions","href":"/api-reference/templates/list-notification-template-versions"},{"title":"Publish Notification Template","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml post /notifications/{id}/publish","href":"/api-reference/templates/publish-notification-template"},{"title":"Get Notification Content","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /notifications/{id}/content","href":"/api-reference/templates/get-notification-content"},{"title":"Replace Notification Content","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml put /notifications/{id}/content","href":"/api-reference/templates/replace-notification-content"},{"title":"Replace Notification Element","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml put /notifications/{id}/elements/{elementId}","href":"/api-reference/templates/replace-notification-element"},{"title":"Replace Notification Locale","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml put /notifications/{id}/locales/{localeId}","href":"/api-reference/templates/replace-notification-locale"},{"title":"Get submission checks","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /notifications/{id}/{submissionId}/checks","href":"/api-reference/templates/get-submission-checks"},{"title":"Replace submission checks","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml put /notifications/{id}/{submissionId}/checks","href":"/api-reference/templates/replace-submission-checks"},{"title":"Cancel submission","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml delete /notifications/{id}/{submissionId}/checks","href":"/api-reference/templates/cancel-submission"},{"title":"Get Notification Template Metrics","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /notifications/{id}/metrics","href":"/api-reference/templates/get-notification-template-metrics"}]},{"group":"Brands","pages":[{"title":"List Brands","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /brands","href":"/api-reference/brands/list-brands"},{"title":"Create a new Brand","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml post /brands","href":"/api-reference/brands/create-a-new-brand"},{"title":"Get a Brand","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /brands/{brand_id}","href":"/api-reference/brands/get-a-brand"},{"title":"Replace a Brand","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml put /brands/{brand_id}","href":"/api-reference/brands/replace-a-brand"},{"title":"Delete a Brand","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml delete /brands/{brand_id}","href":"/api-reference/brands/delete-a-brand"}]},{"group":"Routing Strategies","pages":[{"title":"List Routing Strategies","description":"List routing strategies in your workspace. Returns metadata only (no routing/channels/providers content). Use GET /routing-strategies/{id} for full details.","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /routing-strategies","href":"/api-reference/routing-strategies/list-routing-strategies"},{"title":"Create Routing Strategy","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml post /routing-strategies","href":"/api-reference/routing-strategies/create-routing-strategy"},{"title":"Get Routing Strategy","description":"Returns one routing strategy by id with its name, tags, channels, and the routing rules that decide provider order and fallback.","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /routing-strategies/{id}","href":"/api-reference/routing-strategies/get-routing-strategy"},{"title":"Replace Routing Strategy","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml put /routing-strategies/{id}","href":"/api-reference/routing-strategies/replace-routing-strategy"},{"title":"Archive Routing Strategy","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml delete /routing-strategies/{id}","href":"/api-reference/routing-strategies/archive-routing-strategy"},{"title":"List notifications for a Routing Strategy","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /routing-strategies/{id}/notifications","href":"/api-reference/routing-strategies/list-notifications-for-a-routing-strategy"}]},{"group":"Journeys","pages":[{"title":"List Journeys","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /journeys","href":"/api-reference/journeys/list-journeys"},{"title":"Create a Journey","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml post /journeys","href":"/api-reference/journeys/create-a-journey"},{"title":"Cancel Journey runs","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml post /journeys/cancel","href":"/api-reference/journeys/cancel-journey-runs"},{"title":"List Journey runs","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /journeys/runs","href":"/api-reference/journeys/list-journey-runs"},{"title":"Fetch a Journey run","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /journeys/runs/{run_id}","href":"/api-reference/journeys/fetch-a-journey-run"},{"title":"List steps for a Journey run","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /journeys/runs/{run_id}/steps","href":"/api-reference/journeys/list-steps-for-a-journey-run"},{"title":"Invoke a Journey","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml post /journeys/{templateId}/invoke","href":"/api-reference/journeys/invoke-a-journey"},{"title":"Fetch a Journey by id","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /journeys/{templateId}","href":"/api-reference/journeys/fetch-a-journey-by-id"},{"title":"Replace a Journey","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml put /journeys/{templateId}","href":"/api-reference/journeys/replace-a-journey"},{"title":"Archive a Journey","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml delete /journeys/{templateId}","href":"/api-reference/journeys/archive-a-journey"},{"title":"List versions of a Journey","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /journeys/{templateId}/versions","href":"/api-reference/journeys/list-versions-of-a-journey"},{"title":"Publish a Journey","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml post /journeys/{templateId}/publish","href":"/api-reference/journeys/publish-a-journey"},{"title":"List Notification Templates scoped to a Journey","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /journeys/{templateId}/templates","href":"/api-reference/journeys/list-notification-templates-scoped-to-a-journey"},{"title":"Create a Notification Template scoped to a Journey","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml post /journeys/{templateId}/templates","href":"/api-reference/journeys/create-a-notification-template-scoped-to-a-journey"},{"title":"Fetch a Journey-scoped Notification Template by id","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /journeys/{templateId}/templates/{notificationId}","href":"/api-reference/journeys/fetch-a-journey-scoped-notification-template-by-id"},{"title":"Replace a Journey-scoped Notification Template","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml put /journeys/{templateId}/templates/{notificationId}","href":"/api-reference/journeys/replace-a-journey-scoped-notification-template"},{"title":"Archive a Journey-scoped Notification Template","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml delete /journeys/{templateId}/templates/{notificationId}","href":"/api-reference/journeys/archive-a-journey-scoped-notification-template"},{"title":"Publish a Journey-scoped Notification Template","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml post /journeys/{templateId}/templates/{notificationId}/publish","href":"/api-reference/journeys/publish-a-journey-scoped-notification-template"},{"title":"List versions of a Journey-scoped Notification Template","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /journeys/{templateId}/templates/{notificationId}/versions","href":"/api-reference/journeys/list-versions-of-a-journey-scoped-notification-template"},{"title":"Fetch the content of a Journey-scoped Notification Template","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /journeys/{templateId}/templates/{notificationId}/content","href":"/api-reference/journeys/fetch-the-content-of-a-journey-scoped-notification-template"},{"title":"Replace the content of a Journey-scoped Notification Template","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml put /journeys/{templateId}/templates/{notificationId}/content","href":"/api-reference/journeys/replace-the-content-of-a-journey-scoped-notification-template"},{"title":"Replace a locale of a Journey-scoped Notification Template","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml put /journeys/{templateId}/templates/{notificationId}/locales/{localeId}","href":"/api-reference/journeys/replace-a-locale-of-a-journey-scoped-notification-template"}]},{"group":"Broadcasts","pages":[{"title":"List Broadcasts","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /broadcasts","href":"/api-reference/broadcasts/list-broadcasts"},{"title":"Create Broadcast","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml post /broadcasts","href":"/api-reference/broadcasts/create-broadcast"},{"title":"Get Broadcast","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /broadcasts/{broadcastId}","href":"/api-reference/broadcasts/get-broadcast"},{"title":"Update Broadcast","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml put /broadcasts/{broadcastId}","href":"/api-reference/broadcasts/update-broadcast"},{"title":"Archive Broadcast","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml delete /broadcasts/{broadcastId}","href":"/api-reference/broadcasts/archive-broadcast"},{"title":"Duplicate Broadcast","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml post /broadcasts/{broadcastId}/duplicate","href":"/api-reference/broadcasts/duplicate-broadcast"},{"title":"Send Broadcast","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml post /broadcasts/{broadcastId}/send","href":"/api-reference/broadcasts/send-broadcast"},{"title":"Schedule Broadcast","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml post /broadcasts/{broadcastId}/schedule","href":"/api-reference/broadcasts/schedule-broadcast"},{"title":"Cancel Broadcast schedule","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml post /broadcasts/{broadcastId}/cancel","href":"/api-reference/broadcasts/cancel-broadcast-schedule"},{"title":"Get Broadcast content","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /broadcasts/{broadcastId}/content","href":"/api-reference/broadcasts/get-broadcast-content"},{"title":"Update Broadcast content","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml put /broadcasts/{broadcastId}/content","href":"/api-reference/broadcasts/update-broadcast-content"}]},{"group":"Previews","pages":[{"title":"List Preview Devices","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /previews/devices","href":"/api-reference/previews/list-preview-devices"},{"title":"List Device Sets","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /previews/device-sets","href":"/api-reference/previews/list-device-sets"},{"title":"Create Device Set","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml post /previews/device-sets","href":"/api-reference/previews/create-device-set"},{"title":"Get Device Set","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /previews/device-sets/{deviceSetId}","href":"/api-reference/previews/get-device-set"},{"title":"Update Device Set","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml put /previews/device-sets/{deviceSetId}","href":"/api-reference/previews/update-device-set"},{"title":"Archive Device Set","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml delete /previews/device-sets/{deviceSetId}","href":"/api-reference/previews/archive-device-set"},{"title":"List Preview Runs","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /notifications/{id}/previews/runs","href":"/api-reference/previews/list-preview-runs"},{"title":"Create Preview Run","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml post /notifications/{id}/previews/runs","href":"/api-reference/previews/create-preview-run"},{"title":"Get Preview Run","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /notifications/{id}/previews/runs/{previewRunId}","href":"/api-reference/previews/get-preview-run"}]},{"group":"User Profiles","pages":[{"title":"Get a Profile","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /profiles/{user_id}","href":"/api-reference/user-profiles/get-a-profile"},{"title":"Replace a Profile","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml put /profiles/{user_id}","href":"/api-reference/user-profiles/replace-a-profile"},{"title":"Create a Profile","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml post /profiles/{user_id}","href":"/api-reference/user-profiles/create-a-profile"},{"title":"Delete a Profile","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml delete /profiles/{user_id}","href":"/api-reference/user-profiles/delete-a-profile"},{"title":"Update a Profile","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml patch /profiles/{user_id}","href":"/api-reference/user-profiles/update-a-profile"},{"title":"Get List subscriptions","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /profiles/{user_id}/lists","href":"/api-reference/user-profiles/get-list-subscriptions"},{"title":"Subscribe to one or more Lists","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml post /profiles/{user_id}/lists","href":"/api-reference/user-profiles/subscribe-to-one-or-more-lists"},{"title":"Delete List subscriptions","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml delete /profiles/{user_id}/lists","href":"/api-reference/user-profiles/delete-list-subscriptions"}]},{"group":"Tenants","pages":[{"title":"Get a Tenant","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /tenants/{tenant_id}","href":"/api-reference/tenants/get-a-tenant"},{"title":"Create or replace a Tenant","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml put /tenants/{tenant_id}","href":"/api-reference/tenants/create-or-replace-a-tenant"},{"title":"Delete a Tenant","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml delete /tenants/{tenant_id}","href":"/api-reference/tenants/delete-a-tenant"},{"title":"List Tenants","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /tenants","href":"/api-reference/tenants/list-tenants"},{"title":"Get users in Tenant","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /tenants/{tenant_id}/users","href":"/api-reference/tenants/get-users-in-tenant"},{"title":"Create or replace default Preferences for Topic","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml put /tenants/{tenant_id}/default_preferences/items/{topic_id}","href":"/api-reference/tenants/create-or-replace-default-preferences-for-topic"},{"title":"Remove default Preferences for Topic","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml delete /tenants/{tenant_id}/default_preferences/items/{topic_id}","href":"/api-reference/tenants/remove-default-preferences-for-topic"}]},{"group":"Audiences","pages":[{"title":"Get an Audience","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /audiences/{audience_id}","href":"/api-reference/audiences/get-an-audience"},{"title":"Update an Audience","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml put /audiences/{audience_id}","href":"/api-reference/audiences/update-an-audience"},{"title":"Delete an Audience","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml delete /audiences/{audience_id}","href":"/api-reference/audiences/delete-an-audience"},{"title":"List Audience members","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /audiences/{audience_id}/members","href":"/api-reference/audiences/list-audience-members"},{"title":"List all Audiences","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /audiences","href":"/api-reference/audiences/list-all-audiences"}]},{"group":"Lists","pages":[{"title":"List Lists","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /lists","href":"/api-reference/lists/list-lists"},{"title":"Get a List","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /lists/{list_id}","href":"/api-reference/lists/get-a-list"},{"title":"Update a List","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml put /lists/{list_id}","href":"/api-reference/lists/update-a-list"},{"title":"Delete a List","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml delete /lists/{list_id}","href":"/api-reference/lists/delete-a-list"},{"title":"Restore a List","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml put /lists/{list_id}/restore","href":"/api-reference/lists/restore-a-list"},{"title":"List subscriptions for a List","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /lists/{list_id}/subscriptions","href":"/api-reference/lists/list-subscriptions-for-a-list"},{"title":"Subscribe users to a List","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml put /lists/{list_id}/subscriptions","href":"/api-reference/lists/subscribe-users-to-a-list"},{"title":"Add subscribers to a List","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml post /lists/{list_id}/subscriptions","href":"/api-reference/lists/add-subscribers-to-a-list"},{"title":"Subscribe a user Profile to a List","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml put /lists/{list_id}/subscriptions/{user_id}","href":"/api-reference/lists/subscribe-a-user-profile-to-a-list"},{"title":"Unsubscribe a user Profile from a List","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml delete /lists/{list_id}/subscriptions/{user_id}","href":"/api-reference/lists/unsubscribe-a-user-profile-from-a-list"}]},{"group":"Providers","pages":[{"title":"List Providers","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /providers","href":"/api-reference/providers/list-providers"},{"title":"Create a Provider","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml post /providers","href":"/api-reference/providers/create-a-provider"},{"title":"List available Provider types","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /providers/catalog","href":"/api-reference/providers/list-available-provider-types"},{"title":"Get a Provider","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /providers/{id}","href":"/api-reference/providers/get-a-provider"},{"title":"Update a Provider","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml put /providers/{id}","href":"/api-reference/providers/update-a-provider"},{"title":"Delete a Provider","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml delete /providers/{id}","href":"/api-reference/providers/delete-a-provider"},{"title":"Patch a Provider","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml patch /providers/{id}","href":"/api-reference/providers/patch-a-provider"}]},{"group":"Preference Topics","pages":[{"title":"List preference changes","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /preferences/logs","href":"/api-reference/preference-topics/list-preference-changes"},{"title":"Publish Preferences page","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml post /preferences/publish","href":"/api-reference/preference-topics/publish-preferences-page"},{"title":"List Preference Sections","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /preferences/sections","href":"/api-reference/preference-topics/list-preference-sections"},{"title":"Create a Preference Section","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml post /preferences/sections","href":"/api-reference/preference-topics/create-a-preference-section"},{"title":"Get a Preference Section","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /preferences/sections/{section_id}","href":"/api-reference/preference-topics/get-a-preference-section"},{"title":"Replace a Preference Section","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml put /preferences/sections/{section_id}","href":"/api-reference/preference-topics/replace-a-preference-section"},{"title":"Archive a Preference Section","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml delete /preferences/sections/{section_id}","href":"/api-reference/preference-topics/archive-a-preference-section"},{"title":"List Topics in Section","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /preferences/sections/{section_id}/topics","href":"/api-reference/preference-topics/list-topics-in-section"},{"title":"Create Topic in Section","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml post /preferences/sections/{section_id}/topics","href":"/api-reference/preference-topics/create-topic-in-section"},{"title":"Get Topic in Section","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /preferences/sections/{section_id}/topics/{topic_id}","href":"/api-reference/preference-topics/get-topic-in-section"},{"title":"Replace Topic in Section","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml put /preferences/sections/{section_id}/topics/{topic_id}","href":"/api-reference/preference-topics/replace-topic-in-section"},{"title":"Archive Topic in Section","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml delete /preferences/sections/{section_id}/topics/{topic_id}","href":"/api-reference/preference-topics/archive-topic-in-section"}]},{"group":"Digests","pages":[{"title":"Delete a topic's digest","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml delete /preferences/sections/{section_id}/topics/{topic_id}/digest","href":"/api-reference/digests/delete-a-topics-digest"},{"title":"Release a recipient's digest","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml post /preferences/sections/{section_id}/topics/{topic_id}/digest/release","href":"/api-reference/digests/release-a-recipients-digest"},{"title":"Release a digest early","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml post /digests/schedules/{schedule_id}/trigger","href":"/api-reference/digests/release-a-digest-early"},{"title":"List digest instances","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /digests/schedules/{schedule_id}/instances","href":"/api-reference/digests/list-digest-instances"}]},{"group":"User Preferences","pages":[{"title":"Get user's Preferences","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /users/{user_id}/preferences","href":"/api-reference/user-preferences/get-users-preferences"},{"title":"Replace user Preferences in bulk","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml put /users/{user_id}/preferences","href":"/api-reference/user-preferences/replace-user-preferences-in-bulk"},{"title":"Update user Preferences in bulk","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml post /users/{user_id}/preferences","href":"/api-reference/user-preferences/update-user-preferences-in-bulk"},{"title":"Get user Subscription Topic","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /users/{user_id}/preferences/{topic_id}","href":"/api-reference/user-preferences/get-user-subscription-topic"},{"title":"Update or create user Preferences for a Subscription Topic","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml put /users/{user_id}/preferences/{topic_id}","href":"/api-reference/user-preferences/update-or-create-user-preferences-for-a-subscription-topic"},{"title":"Delete user Subscription Topic","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml delete /users/{user_id}/preferences/{topic_id}","href":"/api-reference/user-preferences/delete-user-subscription-topic"}]},{"group":"Messages","pages":[{"title":"List messages","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /messages","href":"/api-reference/messages/list-messages"},{"title":"Get message","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /messages/{message_id}","href":"/api-reference/messages/get-message"},{"title":"Cancel message","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml post /messages/{message_id}/cancel","href":"/api-reference/messages/cancel-message"},{"title":"Resend message","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml post /messages/{message_id}/resend","href":"/api-reference/messages/resend-message"},{"title":"Get message history","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /messages/{message_id}/history","href":"/api-reference/messages/get-message-history"},{"title":"Get message content","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /messages/{message_id}/output","href":"/api-reference/messages/get-message-content"},{"title":"Archive message","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml put /requests/{request_id}/archive","href":"/api-reference/messages/archive-message"}]},{"group":"Device Tokens","pages":[{"title":"List tokens","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /users/{user_id}/tokens","href":"/api-reference/device-tokens/list-tokens"},{"title":"Add multiple tokens to user","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml put /users/{user_id}/tokens","href":"/api-reference/device-tokens/add-multiple-tokens-to-user"},{"title":"Get a token","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /users/{user_id}/tokens/{token}","href":"/api-reference/device-tokens/get-a-token"},{"title":"Add a token to a user","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml put /users/{user_id}/tokens/{token}","href":"/api-reference/device-tokens/add-a-token-to-a-user"},{"title":"Delete user token","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml delete /users/{user_id}/tokens/{token}","href":"/api-reference/device-tokens/delete-user-token"},{"title":"Update a token","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml patch /users/{user_id}/tokens/{token}","href":"/api-reference/device-tokens/update-a-token"}]},{"group":"Tenant Memberships","pages":[{"title":"List a user's Tenants","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /users/{user_id}/tenants","href":"/api-reference/tenant-memberships/list-a-users-tenants"},{"title":"Add a user to multiple Tenants","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml put /users/{user_id}/tenants","href":"/api-reference/tenant-memberships/add-a-user-to-multiple-tenants"},{"title":"Remove a user from all Tenants","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml delete /users/{user_id}/tenants","href":"/api-reference/tenant-memberships/remove-a-user-from-all-tenants"},{"title":"Add a user to a Tenant","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml put /users/{user_id}/tenants/{tenant_id}","href":"/api-reference/tenant-memberships/add-a-user-to-a-tenant"},{"title":"Remove user from a Tenant","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml delete /users/{user_id}/tenants/{tenant_id}","href":"/api-reference/tenant-memberships/remove-user-from-a-tenant"}]},{"group":"Tenant Templates","pages":[{"title":"Get a Template in Tenant","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /tenants/{tenant_id}/templates/{template_id}","href":"/api-reference/tenant-templates/get-a-template-in-tenant"},{"title":"Create or update a Tenant Template","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml put /tenants/{tenant_id}/templates/{template_id}","href":"/api-reference/tenant-templates/create-or-update-a-tenant-template"},{"title":"Delete a Tenant Template","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml delete /tenants/{tenant_id}/templates/{template_id}","href":"/api-reference/tenant-templates/delete-a-tenant-template"},{"title":"Publish a Tenant Template","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml post /tenants/{tenant_id}/templates/{template_id}/publish","href":"/api-reference/tenant-templates/publish-a-tenant-template"},{"title":"Get a Template version","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /tenants/{tenant_id}/templates/{template_id}/versions/{version}","href":"/api-reference/tenant-templates/get-a-template-version"},{"title":"List Templates in Tenant","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /tenants/{tenant_id}/templates","href":"/api-reference/tenant-templates/list-templates-in-tenant"}]},{"group":"Bulk","pages":[{"title":"Create a bulk job","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml post /bulk","href":"/api-reference/bulk/create-a-bulk-job"},{"title":"Get a job","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /bulk/{job_id}","href":"/api-reference/bulk/get-a-job"},{"title":"Add users","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml post /bulk/{job_id}","href":"/api-reference/bulk/add-users"},{"title":"Run a job","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml post /bulk/{job_id}/run","href":"/api-reference/bulk/run-a-job"},{"title":"Get users","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /bulk/{job_id}/users","href":"/api-reference/bulk/get-users"}]},{"group":"Automations","pages":[{"title":"List Automations","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /automations","href":"/api-reference/automations/list-automations"},{"title":"Invoke an Automation","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml post /automations/{templateId}/invoke","href":"/api-reference/automations/invoke-an-automation"},{"title":"Invoke an ad hoc Automation","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml post /automations/invoke","href":"/api-reference/automations/invoke-an-ad-hoc-automation"},{"title":"List Automation runs","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /automations/runs","href":"/api-reference/automations/list-automation-runs"},{"title":"List steps for an Automation run","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /automations/runs/{id}/steps","href":"/api-reference/automations/list-steps-for-an-automation-run"}]},{"group":"Translations","pages":[{"title":"Get a Translation","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /translations/{domain}/{locale}","href":"/api-reference/translations/get-a-translation"},{"title":"Update Translations by locale","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml put /translations/{domain}/{locale}","href":"/api-reference/translations/update-translations-by-locale"}]},{"group":"Track Events","pages":[{"title":"Track an event","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml post /inbound/courier","href":"/api-reference/track-events/track-an-event"}]},{"group":"Audit Events","pages":[{"title":"List Audit Events","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /audit-events","href":"/api-reference/audit-events/list-audit-events"},{"title":"Get an Audit Event","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml get /audit-events/{audit-event-id}","href":"/api-reference/audit-events/get-an-audit-event"}]},{"group":"Authentication","pages":[{"title":"Create a JWT","deprecated":null,"version":null,"openapi":"/openapi-specs/openapi.documented.yml post /auth/issue-token","href":"/api-reference/authentication/create-a-jwt"}]}]},{"tab":"Build with AI","icon":"microchip-ai","pages":[{"title":"Build with AI","href":"/get-started/build-with-ai"}]}]},"basePath":"","title":"Create Routing Strategy - Courier","buildId":"dpl_AHzSCQPRq6mP9FZXEa5AbDZTffie","deploymentId":"dpl_AHzSCQPRq6mP9FZXEa5AbDZTffie","dynamics":["c2aa737661","b0f84f53ff","a9bb46feb3","2b790eda92"],"chunks":["OpenApiReferenceProvider-C0w-WQJ2.js","utils-C5d2irbo.js","cloneDeep-izs3Hzxb.js","_Uint8Array-BVIqJ90l.js","isObjectLike-C8vmzPEN.js","isArray-Dcu1dQ5t.js","utils-CJr73d5s.js","toString-BX-iyh8G.js","isSymbol-CSH9U2Gm.js","addUniqueKeysToSchema-B9xqpnhe.js","snippetPresets-C6Ms_vrL.js","style-to-object-BY3JEAdk.js","v4-DIgz8zy6.js","conditional-requirements-CFM0id0Q.js","Page-DLEGoKJA.js","ApiExamples-C4vTqKLT.js","isEqual-BfaiBbcl.js","usePlaygroundInputsStore-Dvb1kse5.js","shallow-BIuit-p4.js","getApiPlaygroundDisplay-B4qYxU7P.js","CodeSnippet-DbbDcn2_.js","CodeSnippets-P3qMtezt.js","getPastedJson-rlg7qTiW.js","icon-ChyN3MIj.js","MethodPill-BDbONhDa.js","DuplicateIcon-CJlrtq8z.js","createIcon-BDOguHRU.js","DynamicMarkdown-mBxoveKr.js","SectionHeading-CAMJotVi.js","axios-vUo_bRtp.js","Markdown-BNXMbgxP.js","clsx-4BR7cppx.js","lib-DuNMoZ05.js","lib-B8HbPgcC.js","html-void-elements-mCSPHezU.js","dist-CAwBMBkB.js","katex-YMM-FMeD.js","marked.esm-CZWythHk.js","AssistantPageLink-CJogWhER.js"]}