bird amb routing-rules create
Usage
Przykład kodu
bird amb routing-rules create [flags]Description
Create an Apple Messages for Business routing rule
Creates a routing rule for one of your Apple Messages for Business brands. Set is_default to make it the rule that catches a conversation matching nothing else. A business can have only one default rule, and creating a second while one exists returns a 409.
Build the request from flags, a JSON AMBRoutingRuleCreate body via --body-file ("-" reads
stdin), or both — a flag overrides the matching body field. Run --example to
print a ready-to-edit body, or --dry-run to print the resolved request without
sending it.
Examples
Przykład kodu
# print the body shape (no credentials needed)
bird amb routing-rules create --example
# the body it prints:Przykład kodu
{
"business_id": "abz_01krdgeqcxet5s7t44vh8rt9mg",
"is_default": false,
"match_intent_id": "order_status",
"match_kind": "intent",
"precedence": 10,
"queue": "billing"
}Options
Request
| Name | Description |
|---|---|
| --body-file | Read the JSON request body from this file; "-" reads stdin |
| --example | Print a complete example request body, then exit |
| --dry-run | Print the resolved request without sending it, then exit |
| --idempotency-key | Deduplication key; a retry with the same key won't act twice |
Options
| Name | Description |
|---|---|
| --business-id | The Apple Messages for Business brand this rule belongs to. (required; or in --body-file) |
| --match-kind | What a routing rule matches against the entry point that started the conversation. - intent matches on the entry point's intent alone: match_intent_id is set and match_group_id is null. - group matches on the entry point's group alone: match_group_id is set and match_intent_id is null. - both matches only when the entry point carries the given intent and the given group together, so match_intent_id and match_group_id are both set. There are two match fields rather than one because both needs to carry an intent and a group at once. Possible values: intent, group, both. (required; or in --body-file) |
| --match-intent-id | The entry point intent to match, as sent in Apple's intentID. Required when match_kind is intent or both, and rejected when it is group. |
| --match-group-id | The entry point group to match, as sent in Apple's groupID. Required when match_kind is group or both, and rejected when it is intent. |
| --queue | The queue a matching conversation is filed into. Your console lists whichever values your rules use. (required; or in --body-file) |
| --precedence <n> | Evaluation order among this business's rules. The highest-precedence rule a conversation matches wins. Omit it to default to 0. |
| --is-default | Set to make this the rule that catches a conversation matching nothing else. A business can have only one; creating a second while one exists returns a 409. |
| --response-schema | Print the fields this command returns, then exit |
Related
| Name | Description |
|---|---|
| bird amb routing-rules delete | Delete an Apple Messages for Business routing rule |
| bird amb routing-rules get | Get an Apple Messages for Business routing rule |
| bird amb routing-rules list | List Apple Messages for Business routing rules |
| bird amb routing-rules update | Update an Apple Messages for Business routing rule |
Powiązane zasoby
Kontynuuj z dokumentacją, przewodnikami i przykładami dotyczącymi tego tematu. Zasoby są w języku angielskim.
Zrozum koncepcjęShould I use a Bird SDK or call the API directly?Podążaj ścieżką naukiBuild your first integrationPrzewodnik wdrożeniowySend your first email
Uzyskaj brief wdrożeniowy