{"componentChunkName":"component---src-templates-docs-js","path":"/whatsapp/messaging/without_template/text","result":{"data":{"site":{"siteMetadata":{"title":"broadcaster","docsLocation":"https://github.com","docsLocationType":"github","editable":false}},"mdx":{"fields":{"id":"afd2844c-a9a0-52ec-90a4-68d92b3ee7f2","title":"Text messages","slug":"/whatsapp/messaging/without_template/text"},"body":"function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }\n\nfunction _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }\n\nfunction _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }\n\n/* @jsx mdx */\nvar _frontmatter = {\n  \"title\": \"Text messages\",\n  \"order\": 1\n};\nvar layoutProps = {\n  _frontmatter: _frontmatter\n};\nvar MDXLayout = \"wrapper\";\nreturn function MDXContent(_ref) {\n  var components = _ref.components,\n      props = _objectWithoutProperties(_ref, [\"components\"]);\n\n  return mdx(MDXLayout, _extends({}, layoutProps, props, {\n    components: components,\n    mdxType: \"MDXLayout\"\n  }), mdx(\"blockquote\", null, mdx(\"p\", {\n    parentName: \"blockquote\"\n  }, mdx(\"strong\", {\n    parentName: \"p\"\n  }, \"Integration summary\")), mdx(\"ul\", {\n    parentName: \"blockquote\"\n  }, mdx(\"li\", {\n    parentName: \"ul\"\n  }, mdx(\"strong\", {\n    parentName: \"li\"\n  }, \"Endpoint:\"), \" \", mdx(\"inlineCode\", {\n    parentName: \"li\"\n  }, \"POST https://{{url}}/whatsapp-bsp-api-endpoint-ws/services/v1/messaging\")), mdx(\"li\", {\n    parentName: \"ul\"\n  }, mdx(\"strong\", {\n    parentName: \"li\"\n  }, \"Token:\"), \" messaging token, in the \", mdx(\"inlineCode\", {\n    parentName: \"li\"\n  }, \"Authorization: Bearer {{wa-msg-api-token}}\"), \" header (\", mdx(\"a\", {\n    href: \"/whatsapp/authentication_token\"\n  }, \"how to generate it\"), \")\"), mdx(\"li\", {\n    parentName: \"ul\"\n  }, mdx(\"strong\", {\n    parentName: \"li\"\n  }, \"Common fields:\"), \" \", mdx(\"inlineCode\", {\n    parentName: \"li\"\n  }, \"from\"), \", \", mdx(\"inlineCode\", {\n    parentName: \"li\"\n  }, \"to\"), \" (phone number or BSUID) and \", mdx(\"inlineCode\", {\n    parentName: \"li\"\n  }, \"type\"), \" (\", mdx(\"a\", {\n    href: \"/whatsapp/messaging/http#h-commonfields\"\n  }, \"details\"), \")\"), mdx(\"li\", {\n    parentName: \"ul\"\n  }, mdx(\"strong\", {\n    parentName: \"li\"\n  }, mdx(\"inlineCode\", {\n    parentName: \"strong\"\n  }, \"type\"), \" values on this page:\"), \" \", mdx(\"inlineCode\", {\n    parentName: \"li\"\n  }, \"\\\"text\\\"\")), mdx(\"li\", {\n    parentName: \"ul\"\n  }, mdx(\"strong\", {\n    parentName: \"li\"\n  }, \"Response:\"), \" the same for every message (\", mdx(\"a\", {\n    href: \"/whatsapp/messaging/http#h-response\"\n  }, \"see response\"), \")\"))), mdx(\"p\", null, \"Free-form text messages, with or without a URL preview. All are sent with \", mdx(\"a\", {\n    href: \"/whatsapp/messaging/http\"\n  }, \"POST /v1/messaging\"), \"; headers, common fields and the response are in \", mdx(\"a\", {\n    href: \"/whatsapp/messaging/http\"\n  }, \"HTTP connection\"), \".\"), mdx(\"section\", {\n    \"id\": \"text\"\n  }, mdx(\"h2\", {\n    parentName: \"section\"\n  }, \"Text\"), mdx(\"p\", {\n    parentName: \"section\"\n  }, \"Sends a text message. The \", mdx(\"inlineCode\", {\n    parentName: \"p\"\n  }, \"type\"), \" field must be \\\"text\\\".\")), mdx(\"section\", {\n    \"id\": \"text--body\"\n  }, mdx(\"h3\", {\n    parentName: \"section\"\n  }, \"Body\"), mdx(\"p\", {\n    parentName: \"section\"\n  }, \"Fields for \", mdx(\"strong\", {\n    parentName: \"p\"\n  }, \"Text\"), \", in addition to the \", mdx(\"a\", {\n    href: \"/whatsapp/messaging/http#h-commonfields\"\n  }, \"common fields\"), \":\"), mdx(\"table\", {\n    parentName: \"section\"\n  }, mdx(\"thead\", {\n    parentName: \"table\"\n  }, mdx(\"tr\", {\n    parentName: \"thead\"\n  }, mdx(\"th\", {\n    parentName: \"tr\",\n    \"align\": null\n  }, \"Name\"), mdx(\"th\", {\n    parentName: \"tr\",\n    \"align\": null\n  }, \"Description\"), mdx(\"th\", {\n    parentName: \"tr\",\n    \"align\": null\n  }, \"Type\"), mdx(\"th\", {\n    parentName: \"tr\",\n    \"align\": null\n  }, \"Requirements\"))), mdx(\"tbody\", {\n    parentName: \"table\"\n  }, mdx(\"tr\", {\n    parentName: \"tbody\"\n  }, mdx(\"td\", {\n    parentName: \"tr\",\n    \"align\": null\n  }, \"text\"), mdx(\"td\", {\n    parentName: \"tr\",\n    \"align\": null\n  }, \"Message text.\"), mdx(\"td\", {\n    parentName: \"tr\",\n    \"align\": null\n  }, \"String\"), mdx(\"td\", {\n    parentName: \"tr\",\n    \"align\": null\n  }, mdx(\"ul\", null, mdx(\"li\", null, \"Required.\"), mdx(\"li\", null, \"Maximum length: 4096 characters.\"))))))), mdx(\"section\", {\n    \"id\": \"text--example\"\n  }, mdx(\"h3\", {\n    parentName: \"section\"\n  }, \"Example\"), mdx(\"p\", {\n    parentName: \"section\"\n  }, \"Complete \", mdx(\"strong\", {\n    parentName: \"p\"\n  }, \"Text\"), \" example (HTTP request and JSON body):\"), mdx(\"p\", {\n    parentName: \"section\"\n  }, mdx(\"strong\", {\n    parentName: \"p\"\n  }, \"HTTP request\")), mdx(\"pre\", {\n    parentName: \"section\"\n  }, mdx(\"code\", {\n    parentName: \"pre\",\n    \"className\": \"language-bash\"\n  }, \"curl -X POST 'https://{{url}}/whatsapp-bsp-api-endpoint-ws/services/v1/messaging' \\\\\\n-H 'Authorization: Bearer {{wa-msg-api-token}}' \\\\\\n-H 'Content-Type: application/json' \\\\\\n-d '{\\n    \\\"from\\\": \\\"5215500000001\\\",\\n    \\\"to\\\": \\\"5215500000002\\\",\\n    \\\"type\\\": \\\"text\\\",\\n    \\\"text\\\": \\\"~Strikethrough text~ \\\\n _Italic text_ \\\\n *Bold text* \\\\n Emojis \\uD83D\\uDE0B\\\"\\n}'\\n\")), mdx(\"p\", {\n    parentName: \"section\"\n  }, mdx(\"strong\", {\n    parentName: \"p\"\n  }, \"Body\")), mdx(\"pre\", {\n    parentName: \"section\"\n  }, mdx(\"code\", {\n    parentName: \"pre\",\n    \"className\": \"language-json\"\n  }, \"{\\n    \\\"from\\\": \\\"5215500000001\\\",\\n    \\\"to\\\": \\\"5215500000002\\\",\\n    \\\"type\\\": \\\"text\\\",\\n    \\\"text\\\": \\\"~Strikethrough text~ \\\\n _Italic text_ \\\\n *Bold text* \\\\n Emojis \\uD83D\\uDE0B\\\"\\n}\\n\")), mdx(\"br\", null), mdx(\"hr\", {\n    parentName: \"section\"\n  })), mdx(\"section\", {\n    \"id\": \"textwithurlpreview\"\n  }, mdx(\"h2\", {\n    parentName: \"section\"\n  }, \"Text with URL preview\"), mdx(\"p\", {\n    parentName: \"section\"\n  }, \"Sends a text message with a preview of the URL it contains. The \", mdx(\"inlineCode\", {\n    parentName: \"p\"\n  }, \"type\"), \" field must be \\\"text\\\".\")), mdx(\"section\", {\n    \"id\": \"textwithurlpreview--body\"\n  }, mdx(\"h3\", {\n    parentName: \"section\"\n  }, \"Body\"), mdx(\"p\", {\n    parentName: \"section\"\n  }, \"Fields for \", mdx(\"strong\", {\n    parentName: \"p\"\n  }, \"Text with URL preview\"), \", in addition to the \", mdx(\"a\", {\n    href: \"/whatsapp/messaging/http#h-commonfields\"\n  }, \"common fields\"), \":\"), mdx(\"table\", {\n    parentName: \"section\"\n  }, mdx(\"thead\", {\n    parentName: \"table\"\n  }, mdx(\"tr\", {\n    parentName: \"thead\"\n  }, mdx(\"th\", {\n    parentName: \"tr\",\n    \"align\": null\n  }, \"Name\"), mdx(\"th\", {\n    parentName: \"tr\",\n    \"align\": null\n  }, \"Description\"), mdx(\"th\", {\n    parentName: \"tr\",\n    \"align\": null\n  }, \"Type\"), mdx(\"th\", {\n    parentName: \"tr\",\n    \"align\": null\n  }, \"Requirements\"))), mdx(\"tbody\", {\n    parentName: \"table\"\n  }, mdx(\"tr\", {\n    parentName: \"tbody\"\n  }, mdx(\"td\", {\n    parentName: \"tr\",\n    \"align\": null\n  }, \"text\"), mdx(\"td\", {\n    parentName: \"tr\",\n    \"align\": null\n  }, \"Message text.\"), mdx(\"td\", {\n    parentName: \"tr\",\n    \"align\": null\n  }, \"String\"), mdx(\"td\", {\n    parentName: \"tr\",\n    \"align\": null\n  }, mdx(\"ul\", null, mdx(\"li\", null, \"Required.\"), mdx(\"li\", null, \"Maximum length: 4096 characters.\")))), mdx(\"tr\", {\n    parentName: \"tbody\"\n  }, mdx(\"td\", {\n    parentName: \"tr\",\n    \"align\": null\n  }, \"preview_url\"), mdx(\"td\", {\n    parentName: \"tr\",\n    \"align\": null\n  }, mdx(\"inlineCode\", {\n    parentName: \"td\"\n  }, \"true\"), \" to show a preview of the first URL in \", mdx(\"inlineCode\", {\n    parentName: \"td\"\n  }, \"text\"), \". Default \", mdx(\"inlineCode\", {\n    parentName: \"td\"\n  }, \"false\"), \".\"), mdx(\"td\", {\n    parentName: \"tr\",\n    \"align\": null\n  }, \"Boolean\"), mdx(\"td\", {\n    parentName: \"tr\",\n    \"align\": null\n  }, \"Optional.\"))))), mdx(\"section\", {\n    \"id\": \"textwithurlpreview--example\"\n  }, mdx(\"h3\", {\n    parentName: \"section\"\n  }, \"Example\"), mdx(\"p\", {\n    parentName: \"section\"\n  }, \"Complete \", mdx(\"strong\", {\n    parentName: \"p\"\n  }, \"Text with URL preview\"), \" example (HTTP request and JSON body):\"), mdx(\"p\", {\n    parentName: \"section\"\n  }, mdx(\"strong\", {\n    parentName: \"p\"\n  }, \"HTTP request\")), mdx(\"pre\", {\n    parentName: \"section\"\n  }, mdx(\"code\", {\n    parentName: \"pre\",\n    \"className\": \"language-bash\"\n  }, \"curl -X POST 'https://{{url}}/whatsapp-bsp-api-endpoint-ws/services/v1/messaging' \\\\\\n-H 'Authorization: Bearer {{wa-msg-api-token}}' \\\\\\n-H 'Content-Type: application/json' \\\\\\n-d '{\\n    \\\"from\\\": \\\"5215500000001\\\",\\n    \\\"to\\\": \\\"5215500000002\\\",\\n    \\\"type\\\": \\\"text\\\",\\n    \\\"text\\\": \\\"https://www.ejemplo.com\\\",\\n    \\\"preview_url\\\": true\\n}'\\n\")), mdx(\"p\", {\n    parentName: \"section\"\n  }, mdx(\"strong\", {\n    parentName: \"p\"\n  }, \"Body\")), mdx(\"pre\", {\n    parentName: \"section\"\n  }, mdx(\"code\", {\n    parentName: \"pre\",\n    \"className\": \"language-json\"\n  }, \"{\\n    \\\"from\\\": \\\"5215500000001\\\",\\n    \\\"to\\\": \\\"5215500000002\\\",\\n    \\\"type\\\": \\\"text\\\",\\n    \\\"text\\\": \\\"https://www.ejemplo.com\\\",\\n    \\\"preview_url\\\": true\\n}\\n\")), mdx(\"br\", null), mdx(\"hr\", {\n    parentName: \"section\"\n  })), mdx(\"section\", {\n    \"id\": \"textwithbsuid\"\n  }, mdx(\"h2\", {\n    parentName: \"section\"\n  }, \"Text with BSUID\"), mdx(\"p\", {\n    parentName: \"section\"\n  }, \"Send the message to the user's BSUID in the \", mdx(\"inlineCode\", {\n    parentName: \"p\"\n  }, \"to\"), \" field. See \", mdx(\"a\", {\n    href: \"/whatsapp/receive_notifications#h-usernamesandbsuid\"\n  }, \"Usernames and BSUID\"), \".\"), mdx(\"p\", {\n    parentName: \"section\"\n  }, \"Uses the same fields as \", mdx(\"a\", {\n    href: \"#h-text\"\n  }, \"Text\"), \"; the \", mdx(\"inlineCode\", {\n    parentName: \"p\"\n  }, \"type\"), \" field must be \\\"text\\\".\")), mdx(\"section\", {\n    \"id\": \"textwithbsuid--example\"\n  }, mdx(\"h3\", {\n    parentName: \"section\"\n  }, \"Example\"), mdx(\"p\", {\n    parentName: \"section\"\n  }, \"Complete \", mdx(\"strong\", {\n    parentName: \"p\"\n  }, \"Text with BSUID\"), \" example (HTTP request and JSON body):\"), mdx(\"p\", {\n    parentName: \"section\"\n  }, mdx(\"strong\", {\n    parentName: \"p\"\n  }, \"HTTP request\")), mdx(\"pre\", {\n    parentName: \"section\"\n  }, mdx(\"code\", {\n    parentName: \"pre\",\n    \"className\": \"language-bash\"\n  }, \"curl --location 'https://{{url}}/whatsapp-bsp-api-endpoint-ws/services/v1/messaging' \\\\\\n-H 'Authorization: Bearer {{wa-msg-api-token}}' \\\\\\n-H 'Content-Type: application/json' \\\\\\n-d '{\\n    \\\"from\\\": \\\"5215500000001\\\",\\n    \\\"to\\\": \\\"US.13491208655302741918\\\",\\n    \\\"type\\\": \\\"text\\\",\\n    \\\"text\\\": \\\"Hello\\\"\\n}'\\n\")), mdx(\"br\", null), mdx(\"hr\", {\n    parentName: \"section\"\n  })));\n}\n;\nMDXContent.isMDXComponent = true;","tableOfContents":{"items":[{"url":"#text","title":"Text","items":[{"url":"#body","title":"Body"},{"url":"#example","title":"Example"}]},{"url":"#text-with-url-preview","title":"Text with URL preview","items":[{"url":"#body-1","title":"Body"},{"url":"#example-1","title":"Example"}]},{"url":"#text-with-bsuid","title":"Text with BSUID","items":[{"url":"#example-2","title":"Example"}]}]},"timeToRead":1,"parent":{"__typename":"File","relativePath":"whatsapp/messaging/without_template/text.md","fields":{"gitLogLatestAuthorName":"Irais Aguirre","gitLogLatestAuthorEmail":"irais.aguirre@conceptomovil.com","gitLogLatestDate":"6 hours ago"}},"frontmatter":{"metaTitle":null,"showMetadata":null,"editable":null,"showPreviousNext":null,"showToc":null}},"gitBranch":{"name":"20211019-2FACTOR_AUTH"},"gitCommit":{"hash":"9713e1925aeb8cad930f91b6bf05d0b5937b2bb5","date":"2026-11-13 06:39"}},"pageContext":{"id":"afd2844c-a9a0-52ec-90a4-68d92b3ee7f2"}},"staticQueryHashes":["12478684","12478684","2882937274","2882937274","353167761","353167761"]}