{"_id":"585b90226020160f0046acaa","__v":0,"category":{"_id":"582dc59ee1b8692300c0dd03","__v":0,"project":"54eb50e5615ffc1900305a16","version":"54eb63b859b1172100334fae","sync":{"url":"","isSync":false},"reference":false,"createdAt":"2016-11-17T14:58:38.431Z","from_sync":false,"order":15,"slug":"line","title":"LINE messaging"},"user":"57a98d832242630e00cc8df7","version":{"_id":"54eb63b859b1172100334fae","project":"54eb50e5615ffc1900305a16","forked_from":"54eb63a1867e1917009b711d","__v":27,"createdAt":"2015-02-23T17:30:32.501Z","releaseDate":"2015-02-23T17:30:32.501Z","categories":["54eb63b959b1172100334faf","54eb63b959b1172100334fb0","54eb63b959b1172100334fb1","54eb63b959b1172100334fb2","54ed8dd4ab373e2300f50eae","54ed99b2ab373e2300f50ede","55153a6de68daa2f00cff838","551546edbc466623002afe72","5515472ac28d6125001b8884","55154749c28d6125001b8885","555d9b4106dfec0d00d38ea7","5613e06e433e5735007c7708","5624bbb785a31117001c5403","56669e857cc81e0d00253f8e","568b8d837a42220d00498311","56a632277ef6620d00e2f18a","56d8147c3eb4dd0b00201aac","57a9ce2fac6db30e000d7efd","57a9cf4e944ea60e00dc3f74","58172386715dce0f00da4aa0","582dc59ee1b8692300c0dd03","589b19b4fec2730f0082e040","58b04a023529383900a759b5","58b92d1598157a0f004869bf","592e7685c58275000f20174f","59392839e376d4002f8a0474","59393064e376d4002f8a05a1","5947ae0d4005e2000f3a4fec","594a74df1d1de5001ab3517a","5954bc387a147f001b918915"],"is_deprecated":false,"is_hidden":false,"is_beta":false,"is_stable":true,"codename":"","version_clean":"1.0.0","version":"1"},"project":"54eb50e5615ffc1900305a16","parentDoc":null,"updates":[],"next":{"pages":[],"description":""},"createdAt":"2016-12-22T08:34:42.086Z","link_external":false,"link_url":"","githubsync":"","sync_unique":"","hidden":false,"api":{"examples":{"codes":[{"name":"","code":"POST /line/1/single HTTP/1.1\nHost: api.infobip.com\nAuthorization: Basic QWxhZGRpbjpvcGVuIHNlc2FtZQ==\nContent-Type: application/json\nAccept: application/json\n\n{  \n  \"from\":\"8F0792F86035A9F4290821F1EE6BC06A\",\n  \"to\":\"aaaaaaaa-aaaa-aaaa-aaaa-aaaaaaaaaaaa\",\n  \"message\": {\n    \"type\":\"TEXT\",\n    \"text\":\"Hello, World!\"\n  }\n}","language":"json"}]},"method":"post","results":{"codes":[{"status":200,"language":"json","code":"{\n  \"to\": \"aaaaaaaa-aaaa-aaaa-aaaa-aaaaaaaaaaaa\",\n  \"messageCount\": 1,\n  \"messageId\": \"bbbbbbbb-bbbb-bbbb-bbbb-bbbbbbbbbbbb\",\n  \"status\": {\n    \"groupId\": 1,\n    \"groupName\": \"PENDING\",\n    \"id\": 7,\n    \"name\": \"PENDING_ENROUTE\",\n    \"description\": \"Message sent to next instance\"\n  }\n}","name":""},{"status":400,"language":"json","code":"{\n  \"requestError\": {\n    \"serviceException\": {\n      \"messageId\": \"BAD_REQUEST\",\n      \"text\": \"Bad request\"\n    }\n  }\n}","name":""},{"code":"{\n  \"requestError\": {\n    \"serviceException\": {\n      \"messageId\": \"UNAUTHORIZED\",\n      \"text\": \"Invalid login details\"\n    }\n  }\n}","language":"json","status":401}]},"settings":"554860d6d2c8410d006c215e","auth":"required","params":[{"_id":"55155f2abc466623002afe8b","ref":"","in":"body","required":true,"desc":"Application key you are using to send messages.","default":"","type":"string","name":"from"},{"_id":"55155f2abc466623002afe8a","ref":"","in":"body","required":true,"desc":"User key or a phone number.","default":"","type":"string","name":"to"},{"_id":"55155f2abc466623002afe89","ref":"","in":"body","required":true,"desc":"Message object.","default":"","type":"object","name":"message"}],"url":"/line/:version/single"},"isReference":false,"order":1,"body":"# Request Format\n[block:parameters]\n{\n  \"data\": {\n    \"h-0\": \"Property name\",\n    \"h-1\": \"Type\",\n    \"0-0\": \"from\",\n    \"1-0\": \"to\",\n    \"2-0\": \"message\",\n    \"0-1\": \"String\",\n    \"1-1\": \"String\",\n    \"2-1\": \"Object\",\n    \"0-2\": \"Application key you are using to send messages.\",\n    \"1-2\": \"User key.\",\n    \"2-2\": \"Message object.\",\n    \"h-2\": \"Description\"\n  },\n  \"cols\": 3,\n  \"rows\": 3\n}\n[/block]\n## Message Object\n\nSupported message objects are text, image, video, audio, location, imagemap and template.\n\n\n### Text Message\n[block:parameters]\n{\n  \"data\": {\n    \"0-0\": \"type\",\n    \"0-1\": \"String\",\n    \"0-2\": \"Constant value - \\\"TEXT\\\".\",\n    \"1-0\": \"text\",\n    \"1-1\": \"String\",\n    \"1-2\": \"Text of the message.\",\n    \"h-0\": \"Property name\",\n    \"h-1\": \"Type\",\n    \"h-2\": \"Description\"\n  },\n  \"cols\": 3,\n  \"rows\": 2\n}\n[/block]\n\n[block:code]\n{\n  \"codes\": [\n    {\n      \"code\": \"POST /line/1/single HTTP/1.1\\nHost: api.infobip.com\\nAuthorization: Basic QWxhZGRpbjpvcGVuIHNlc2FtZQ==\\nContent-Type: application/json\\nAccept: application/json\\n\\n{  \\n  \\\"from\\\":\\\"8F0792F86035A9F4290821F1EE6BC06A\\\",\\n  \\\"to\\\":\\\"aaaaaaaa-aaaa-aaaa-aaaa-aaaaaaaaaaaa\\\",\\n  \\\"message\\\": {\\n    \\\"type\\\":\\\"TEXT\\\",\\n    \\\"text\\\":\\\"Hello, World!\\\"\\n  }\\n}\",\n      \"language\": \"json\"\n    }\n  ]\n}\n[/block]\n### Image Message\n[block:parameters]\n{\n  \"data\": {\n    \"h-0\": \"Property name\",\n    \"h-1\": \"Type\",\n    \"h-2\": \"Description\",\n    \"0-0\": \"type\",\n    \"0-1\": \"String\",\n    \"0-2\": \"Constant value - \\\"IMAGE\\\".\",\n    \"1-0\": \"url\",\n    \"1-1\": \"String\",\n    \"1-2\": \"URL of the image.\",\n    \"2-0\": \"thumbnailUrl\",\n    \"2-1\": \"String\",\n    \"2-2\": \"URL of the image thumbnail.\"\n  },\n  \"cols\": 3,\n  \"rows\": 3\n}\n[/block]\n\n[block:code]\n{\n  \"codes\": [\n    {\n      \"code\": \"POST /line/1/single HTTP/1.1\\nHost: api.infobip.com\\nAuthorization: Basic QWxhZGRpbjpvcGVuIHNlc2FtZQ==\\nContent-Type: application/json\\nAccept: application/json\\n\\n{  \\n  \\\"from\\\":\\\"8F0792F86035A9F4290821F1EE6BC06A\\\",\\n  \\\"to\\\":\\\"aaaaaaaa-aaaa-aaaa-aaaa-aaaaaaaaaaaa\\\",\\n  \\\"message\\\": {\\n    \\\"type\\\":\\\"IMAGE\\\",\\n    \\\"url\\\":\\\"https://example.com/original.jpg\\\",\\n    \\\"thumbnailUrl\\\":\\\"https://example.com/preview.jpg\\\"\\n  }\\n}\",\n      \"language\": \"json\"\n    }\n  ]\n}\n[/block]\n### Video Message\n[block:parameters]\n{\n  \"data\": {\n    \"0-0\": \"type\",\n    \"0-1\": \"String\",\n    \"0-2\": \"Constant value - \\\"VIDEO\\\".\",\n    \"1-0\": \"url\",\n    \"1-1\": \"String\",\n    \"1-2\": \"URL of the video.\",\n    \"2-0\": \"thumbnailUrl\",\n    \"2-1\": \"String\",\n    \"2-2\": \"URL of the video thumbnail.\",\n    \"h-0\": \"Property name\",\n    \"h-1\": \"Type\",\n    \"h-2\": \"Description\"\n  },\n  \"cols\": 3,\n  \"rows\": 3\n}\n[/block]\n\n[block:code]\n{\n  \"codes\": [\n    {\n      \"code\": \"POST /line/1/single HTTP/1.1\\nHost: api.infobip.com\\nAuthorization: Basic QWxhZGRpbjpvcGVuIHNlc2FtZQ==\\nContent-Type: application/json\\nAccept: application/json\\n\\n{  \\n  \\\"from\\\":\\\"8F0792F86035A9F4290821F1EE6BC06A\\\",\\n  \\\"to\\\":\\\"aaaaaaaa-aaaa-aaaa-aaaa-aaaaaaaaaaaa\\\",\\n  \\\"message\\\": {\\n    \\\"type\\\":\\\"VIDEO\\\",\\n    \\\"url\\\":\\\"https://example.com/original.mp4\\\",\\n    \\\"thumbnailUrl\\\":\\\"https://example.com/preview.jpg\\\",\\n  }\\n}\",\n      \"language\": \"json\"\n    }\n  ]\n}\n[/block]\n### Audio Message\n[block:parameters]\n{\n  \"data\": {\n    \"0-0\": \"type\",\n    \"0-1\": \"String\",\n    \"1-1\": \"String\",\n    \"2-1\": \"Number\",\n    \"0-2\": \"Constant value - \\\"AUDIO\\\".\",\n    \"1-0\": \"url\",\n    \"2-0\": \"duration\",\n    \"1-2\": \"URL of the audio.\",\n    \"2-2\": \"Duration of audio (in milliseconds).\",\n    \"h-0\": \"Property name\",\n    \"h-1\": \"Type\",\n    \"h-2\": \"Description\"\n  },\n  \"cols\": 3,\n  \"rows\": 3\n}\n[/block]\n\n[block:code]\n{\n  \"codes\": [\n    {\n      \"code\": \"POST /line/1/single HTTP/1.1\\nHost: api.infobip.com\\nAuthorization: Basic QWxhZGRpbjpvcGVuIHNlc2FtZQ==\\nContent-Type: application/json\\nAccept: application/json\\n\\n{  \\n  \\\"from\\\":\\\"8F0792F86035A9F4290821F1EE6BC06A\\\",\\n  \\\"to\\\":\\\"aaaaaaaa-aaaa-aaaa-aaaa-aaaaaaaaaaaa\\\",\\n  \\\"message\\\": {\\n    \\\"type\\\":\\\"AUDIO\\\",\\n    \\\"url\\\":\\\"https://example.com/original.m4a\\\",\\n    \\\"duration\\\":240000\\n  }\\n}\",\n      \"language\": \"json\"\n    }\n  ]\n}\n[/block]\n### Location Message\n[block:parameters]\n{\n  \"data\": {\n    \"0-0\": \"type\",\n    \"0-1\": \"String\",\n    \"0-2\": \"Constant value - \\\"LOCATION\\\"\",\n    \"1-0\": \"title\",\n    \"1-1\": \"String\",\n    \"h-0\": \"Property name\",\n    \"h-1\": \"Type\",\n    \"h-2\": \"Description\",\n    \"1-2\": \"Location title\",\n    \"2-0\": \"address\",\n    \"2-1\": \"String\",\n    \"2-2\": \"Location address\",\n    \"3-0\": \"latitude\",\n    \"3-1\": \"number\",\n    \"4-0\": \"longitude\",\n    \"4-1\": \"number\",\n    \"3-2\": \"Location latitude\",\n    \"4-2\": \"Location longitude\"\n  },\n  \"cols\": 3,\n  \"rows\": 5\n}\n[/block]\n\n[block:code]\n{\n  \"codes\": [\n    {\n      \"code\": \"POST /line/1/single HTTP/1.1\\nHost: api.infobip.com\\nAuthorization: Basic QWxhZGRpbjpvcGVuIHNlc2FtZQ==\\nContent-Type: application/json\\nAccept: application/json\\n\\n{  \\n  \\\"from\\\":\\\"8F0792F86035A9F4290821F1EE6BC06A\\\",\\n  \\\"to\\\":\\\"aaaaaaaa-aaaa-aaaa-aaaa-aaaaaaaaaaaa\\\",\\n  \\\"message\\\": {\\n    \\\"type\\\":\\\"LOCATION\\\",\\n    \\\"title\\\":\\\"Eiffel Tower\\\",\\n    \\\"address\\\": \\\"Champ de Mars, 5 Avenue Anatole France, 75007 Paris, France\\\",\\n    \\\"latitude\\\": 48.85837,\\n    \\\"longitude\\\": 2.294481\\n  }\\n}\",\n      \"language\": \"json\"\n    }\n  ]\n}\n[/block]\n### Sticker Message\n[block:parameters]\n{\n  \"data\": {\n    \"h-0\": \"Property name\",\n    \"h-1\": \"Type\",\n    \"h-2\": \"Description\",\n    \"0-0\": \"type\",\n    \"0-1\": \"String\",\n    \"0-2\": \"Constant value - \\\"STICKER\\\"\",\n    \"1-0\": \"packageId\",\n    \"2-0\": \"stickerId\",\n    \"1-1\": \"String\",\n    \"2-1\": \"String\",\n    \"1-2\": \"Id of the sticker package\",\n    \"2-2\": \"Id of the sticker\"\n  },\n  \"cols\": 3,\n  \"rows\": 3\n}\n[/block]\n\n[block:code]\n{\n  \"codes\": [\n    {\n      \"code\": \"POST /line/1/single HTTP/1.1\\nHost: api.infobip.com\\nAuthorization: Basic QWxhZGRpbjpvcGVuIHNlc2FtZQ==\\nContent-Type: application/json\\nAccept: application/json\\n\\n{  \\n  \\\"from\\\":\\\"8F0792F86035A9F4290821F1EE6BC06A\\\",\\n  \\\"to\\\":\\\"aaaaaaaa-aaaa-aaaa-aaaa-aaaaaaaaaaaa\\\",\\n  \\\"message\\\": {\\n    \\\"type\\\":\\\"STICKER\\\",\\n    \\\"packageId\\\": \\\"1\\\",\\n    \\\"stickerId\\\": \\\"1\\\"\\n  }\\n}\",\n      \"language\": \"json\"\n    }\n  ]\n}\n[/block]\n### Imagemap Message\n[block:parameters]\n{\n  \"data\": {\n    \"0-0\": \"type\",\n    \"1-0\": \"baseUrl\",\n    \"2-0\": \"altText\",\n    \"3-0\": \"baseSize.width\",\n    \"4-0\": \"baseSize\",\n    \"5-0\": \"actions\",\n    \"h-0\": \"Property name\",\n    \"h-1\": \"Type\",\n    \"h-2\": \"Description\",\n    \"0-1\": \"String\",\n    \"0-2\": \"Constant value - \\\"IMAGEMAP\\\"\",\n    \"1-1\": \"String\",\n    \"1-2\": \"Base URL that will have image size appended\",\n    \"2-1\": \"String\",\n    \"2-2\": \"Alternative text\",\n    \"3-1\": \"number\",\n    \"3-2\": \"Width of the base image\",\n    \"4-1\": \"number\",\n    \"4-2\": \"Height of the base image\",\n    \"5-1\": \"array\",\n    \"5-2\": \"Array of imagemap actions\"\n  },\n  \"cols\": 3,\n  \"rows\": 6\n}\n[/block]\n#### Imagemap - Area\n\n[block:parameters]\n{\n  \"data\": {\n    \"h-0\": \"Property name\",\n    \"h-1\": \"Type\",\n    \"h-2\": \"Description\",\n    \"0-0\": \"x\",\n    \"1-0\": \"y\",\n    \"2-0\": \"width\",\n    \"3-0\": \"height\",\n    \"0-1\": \"number\",\n    \"1-1\": \"number\",\n    \"2-1\": \"number\",\n    \"3-1\": \"number\",\n    \"0-2\": \"X coordinate of the action box\",\n    \"1-2\": \"Y coordinate of the action box\",\n    \"2-2\": \"Width of the action box\",\n    \"3-2\": \"Height of the action box\"\n  },\n  \"cols\": 3,\n  \"rows\": 4\n}\n[/block]\n#### Imagemap - URI action\n[block:parameters]\n{\n  \"data\": {\n    \"h-0\": \"Property name\",\n    \"h-1\": \"Type\",\n    \"h-2\": \"Description\",\n    \"0-0\": \"type\",\n    \"0-1\": \"String\",\n    \"0-2\": \"Constant value - 'URI'\",\n    \"1-0\": \"linkUri\",\n    \"1-1\": \"String\",\n    \"1-2\": \"Link to open on action\",\n    \"2-0\": \"area\",\n    \"2-1\": \"Area[]\",\n    \"2-2\": \"Array of action box areas\"\n  },\n  \"cols\": 3,\n  \"rows\": 3\n}\n[/block]\n#### Imagemap - MESSAGE action\n\n[block:parameters]\n{\n  \"data\": {\n    \"h-0\": \"Property name\",\n    \"h-1\": \"Type\",\n    \"h-2\": \"Description\",\n    \"0-0\": \"type\",\n    \"0-1\": \"String\",\n    \"0-2\": \"Constant value - 'MESSAGE'\",\n    \"1-0\": \"text\",\n    \"1-1\": \"String\",\n    \"1-2\": \"Message to send on action\",\n    \"2-0\": \"area\",\n    \"2-1\": \"Area[]\",\n    \"2-2\": \"Array of action box areas\"\n  },\n  \"cols\": 3,\n  \"rows\": 3\n}\n[/block]\n\n[block:code]\n{\n  \"codes\": [\n    {\n      \"code\": \"POST /line/1/single HTTP/1.1\\nHost: api.infobip.com\\nAuthorization: Basic QWxhZGRpbjpvcGVuIHNlc2FtZQ==\\nContent-Type: application/json\\nAccept: application/json\\n\\n{  \\n  \\\"from\\\":\\\"8F0792F86035A9F4290821F1EE6BC06A\\\",\\n  \\\"to\\\":\\\"aaaaaaaa-aaaa-aaaa-aaaa-aaaaaaaaaaaa\\\",\\n  \\\"message\\\": {\\n    \\\"type\\\":\\\"IMAGEMAP\\\",\\n    \\\"baseUrl\\\":\\\"https://example.url/base\\\",\\n    \\\"altText\\\": \\\"Alternative text\\\",\\n    \\\"baseSize\\\": {\\n      \\\"width\\\": 1040,\\n      \\\"height\\\": 1040\\n    },\\n    \\\"actions\\\": [\\n      {\\n        \\\"type\\\": \\\"URI\\\",\\n        \\\"linkUri\\\": \\\"https://example.url/link\\\",\\n        \\\"area\\\": {\\n          \\\"x\\\": 0,\\n          \\\"y\\\": 0,\\n          \\\"width\\\": 520,\\n          \\\"height\\\": 1040\\n        }\\n      },\\n      {\\n        \\\"type\\\": \\\"MESSAGE\\\",\\n        \\\"text\\\": \\\"Message text\\\",\\n        \\\"area\\\": {\\n          \\\"x\\\": 520,\\n          \\\"y\\\": 0,\\n          \\\"width\\\": 520,\\n          \\\"height\\\": 1040\\n        }\\n      }\\n    ]\\n  }\\n}\",\n      \"language\": \"json\"\n    }\n  ]\n}\n[/block]\n### Template message\n[block:parameters]\n{\n  \"data\": {\n    \"h-0\": \"Property name\",\n    \"h-1\": \"Type\",\n    \"h-2\": \"Description\",\n    \"0-0\": \"type\",\n    \"0-1\": \"String\",\n    \"0-2\": \"Constant value - 'TEMPLATE'\",\n    \"1-0\": \"altText\",\n    \"1-1\": \"String\",\n    \"1-2\": \"Alternative text\",\n    \"2-0\": \"template\",\n    \"2-1\": \"object\",\n    \"2-2\": \"Template specification - buttons, confirm or carousel\"\n  },\n  \"cols\": 3,\n  \"rows\": 3\n}\n[/block]\n\n#### Template actions - POSTBACK action\n[block:parameters]\n{\n  \"data\": {\n    \"h-0\": \"Property name\",\n    \"h-1\": \"Type\",\n    \"h-2\": \"Description\",\n    \"0-0\": \"type\",\n    \"1-0\": \"label\",\n    \"2-0\": \"data\",\n    \"0-2\": \"Constant value - 'POSTBACK'\",\n    \"1-2\": \"Action label\",\n    \"2-2\": \"Action data\",\n    \"0-1\": \"String\",\n    \"1-1\": \"String\",\n    \"2-1\": \"String\"\n  },\n  \"cols\": 3,\n  \"rows\": 3\n}\n[/block]\n#### Template actions - MESSAGE action\n[block:parameters]\n{\n  \"data\": {\n    \"h-0\": \"Property name\",\n    \"h-1\": \"Type\",\n    \"h-2\": \"Description\",\n    \"0-0\": \"type\",\n    \"1-0\": \"label\",\n    \"2-0\": \"text\",\n    \"0-2\": \"Constant value - 'MESSAGE'\",\n    \"1-2\": \"Action label\",\n    \"2-2\": \"Action text\",\n    \"0-1\": \"String\",\n    \"1-1\": \"String\",\n    \"2-1\": \"String\"\n  },\n  \"cols\": 3,\n  \"rows\": 3\n}\n[/block]\n#### Template actions - URI action\n[block:parameters]\n{\n  \"data\": {\n    \"h-0\": \"Property name\",\n    \"h-1\": \"Type\",\n    \"h-2\": \"Description\",\n    \"0-0\": \"type\",\n    \"1-0\": \"label\",\n    \"2-0\": \"uri\",\n    \"0-2\": \"Constant value - 'URI'\",\n    \"1-2\": \"Action label\",\n    \"2-2\": \"Action URI\",\n    \"0-1\": \"String\",\n    \"1-1\": \"String\",\n    \"2-1\": \"String\"\n  },\n  \"cols\": 3,\n  \"rows\": 3\n}\n[/block]\n\n#### Template - BUTTONS template\n[block:parameters]\n{\n  \"data\": {\n    \"0-0\": \"type\",\n    \"1-0\": \"thumbnailImageUrl\",\n    \"2-0\": \"title\",\n    \"3-0\": \"text\",\n    \"4-0\": \"actions\",\n    \"0-1\": \"String\",\n    \"0-2\": \"Constant value - 'BUTTONS'\",\n    \"1-1\": \"String\",\n    \"2-1\": \"String\",\n    \"3-1\": \"String\",\n    \"4-1\": \"array\",\n    \"4-2\": \"Template actions\",\n    \"1-2\": \"Buttons template thumbnail image\",\n    \"2-2\": \"Buttons template title\",\n    \"3-2\": \"Buttons template text\",\n    \"h-0\": \"Property name\",\n    \"h-1\": \"Type\",\n    \"h-2\": \"Description\"\n  },\n  \"cols\": 3,\n  \"rows\": 5\n}\n[/block]\n\n[block:code]\n{\n  \"codes\": [\n    {\n      \"code\": \"POST /line/1/single HTTP/1.1\\nHost: api.infobip.com\\nAuthorization: Basic QWxhZGRpbjpvcGVuIHNlc2FtZQ==\\nContent-Type: application/json\\nAccept: application/json\\n\\n{\\n    \\\"from\\\":\\\"8F0792F86035A9F4290821F1EE6BC06A\\\",\\n  \\t\\\"to\\\":\\\"aaaaaaaa-aaaa-aaaa-aaaa-aaaaaaaaaaaa\\\",\\n    \\\"message\\\": {\\n    \\t\\\"type\\\":\\\"TEMPLATE\\\",\\n    \\t\\\"altText\\\": \\\"Alternative text\\\",\\n    \\t\\\"template\\\": {\\n    \\t\\t\\\"type\\\": \\\"BUTTONS\\\",\\n    \\t\\t\\\"thumbnailImageUrl\\\": \\\"https://example.com/thumbnail\\\",\\n    \\t\\t\\\"title\\\": \\\"Title\\\",\\n    \\t\\t\\\"text\\\": \\\"Text\\\",\\n    \\t\\t\\\"actions\\\": [\\n\\t\\t\\t\\t{\\n\\t\\t\\t\\t\\t\\\"type\\\": \\\"POSTBACK\\\",\\n\\t\\t\\t\\t\\t\\\"label\\\": \\\"Postback action\\\",\\n\\t\\t\\t\\t\\t\\\"data\\\": \\\"Postback action data\\\"\\n\\t\\t\\t\\t},\\n\\t\\t\\t\\t{\\n\\t\\t\\t\\t\\t\\\"type\\\": \\\"MESSAGE\\\",\\n\\t\\t\\t\\t\\t\\\"label\\\": \\\"Message action\\\",\\n\\t\\t\\t\\t\\t\\\"text\\\": \\\"Message action text\\\"\\n\\t\\t\\t\\t},\\n\\t\\t\\t\\t{\\n\\t\\t\\t\\t\\t\\\"type\\\": \\\"URI\\\",\\n\\t\\t\\t\\t\\t\\\"label\\\": \\\"Uri message action\\\",\\n\\t\\t\\t\\t\\t\\\"uri\\\": \\\"http://infobip.com\\\"\\n\\t\\t\\t\\t}\\n    \\t\\t]\\n    \\t}\\n    }\\n}\",\n      \"language\": \"json\"\n    }\n  ]\n}\n[/block]\n#### Template - CONFIRM template\n[block:parameters]\n{\n  \"data\": {\n    \"h-0\": \"Property name\",\n    \"h-1\": \"Type\",\n    \"h-2\": \"Description\",\n    \"0-0\": \"type\",\n    \"0-1\": \"String\",\n    \"0-2\": \"Constant value - 'BUTTONS'\",\n    \"1-0\": \"text\",\n    \"1-1\": \"String\",\n    \"1-2\": \"Confirm template text\",\n    \"2-0\": \"actions\",\n    \"2-1\": \"array\",\n    \"2-2\": \"Template actions\"\n  },\n  \"cols\": 3,\n  \"rows\": 3\n}\n[/block]\n\n[block:code]\n{\n  \"codes\": [\n    {\n      \"code\": \"POST /line/1/single HTTP/1.1\\nHost: api.infobip.com\\nAuthorization: Basic QWxhZGRpbjpvcGVuIHNlc2FtZQ==\\nContent-Type: application/json\\nAccept: application/json\\n\\n{\\n    \\\"from\\\":\\\"8F0792F86035A9F4290821F1EE6BC06A\\\",\\n  \\t\\\"to\\\":\\\"aaaaaaaa-aaaa-aaaa-aaaa-aaaaaaaaaaaa\\\",\\n    \\\"message\\\": {\\n    \\t\\\"type\\\":\\\"TEMPLATE\\\",\\n    \\t\\\"altText\\\": \\\"Alternative text\\\",\\n    \\t\\\"template\\\": {\\n    \\t\\t\\\"type\\\": \\\"CONFIRM\\\",\\n    \\t\\t\\\"text\\\": \\\"Do you want to confirm something?\\\",\\n    \\t\\t\\\"actions\\\": [\\n\\t\\t\\t\\t{\\n\\t\\t\\t\\t\\t\\\"type\\\": \\\"MESSAGE\\\",\\n\\t\\t\\t\\t\\t\\\"label\\\": \\\"Yes\\\",\\n\\t\\t\\t\\t\\t\\\"text\\\": \\\"You have confirmed!\\\"\\n\\t\\t\\t\\t},\\n\\t\\t\\t\\t{\\n\\t\\t\\t\\t\\t\\\"type\\\": \\\"MESSAGE\\\",\\n\\t\\t\\t\\t\\t\\\"label\\\": \\\"No\\\",\\n\\t\\t\\t\\t\\t\\\"text\\\": \\\"You didn't confirm!\\\"\\n\\t\\t\\t\\t}\\n    \\t\\t]\\n    \\t}\\n    }\\n}\",\n      \"language\": \"json\"\n    }\n  ]\n}\n[/block]\n#### Template - CAROUSEL template\n[block:parameters]\n{\n  \"data\": {\n    \"h-0\": \"Property name\",\n    \"h-1\": \"Type\",\n    \"h-2\": \"Description\",\n    \"0-0\": \"type\",\n    \"0-1\": \"String\",\n    \"0-2\": \"Constant value - 'CAROUSEL'\",\n    \"1-0\": \"columns\",\n    \"1-1\": \"array\",\n    \"1-2\": \"Carousel columns\"\n  },\n  \"cols\": 3,\n  \"rows\": 2\n}\n[/block]\n#### Carousel template - Column\n\n[block:parameters]\n{\n  \"data\": {\n    \"h-0\": \"Property name\",\n    \"h-1\": \"Type\",\n    \"h-2\": \"Description\",\n    \"0-0\": \"thumbnailImageUrl\",\n    \"0-1\": \"String\",\n    \"0-2\": \"Carousel column thumbnail image\",\n    \"1-0\": \"title\",\n    \"2-0\": \"text\",\n    \"1-1\": \"String\",\n    \"2-1\": \"String\",\n    \"1-2\": \"Carousel column title\",\n    \"2-2\": \"Carousel column text\",\n    \"3-0\": \"actions\",\n    \"3-1\": \"array\",\n    \"3-2\": \"Carousel column actions\"\n  },\n  \"cols\": 3,\n  \"rows\": 4\n}\n[/block]\n\n[block:code]\n{\n  \"codes\": [\n    {\n      \"code\": \"POST /line/1/single HTTP/1.1\\nHost: api.infobip.com\\nAuthorization: Basic QWxhZGRpbjpvcGVuIHNlc2FtZQ==\\nContent-Type: application/json\\nAccept: application/json\\n\\n{\\n    \\\"from\\\":\\\"8F0792F86035A9F4290821F1EE6BC06A\\\",\\n  \\t\\\"to\\\":\\\"aaaaaaaa-aaaa-aaaa-aaaa-aaaaaaaaaaaa\\\",\\n    \\\"message\\\": {\\n      \\\"type\\\":\\\"TEMPLATE\\\",\\n      \\\"altText\\\": \\\"Alternative text\\\",\\n      \\\"template\\\": {\\n    \\t  \\\"type\\\": \\\"CAROUSEL\\\",\\n    \\t  \\\"columns\\\": [\\n          {\\n    \\t\\t\\t\\t\\\"thumbnailImageUrl\\\": \\\"https://example.com/thumbnail_1\\\",\\n    \\t\\t\\t\\t\\\"title\\\": \\\"Carousel column title\\\",\\n    \\t\\t\\t\\t\\\"text\\\": \\\"Carousel column text\\\",\\n    \\t\\t\\t\\t\\\"actions\\\": [{\\n\\t\\t\\t\\t\\t\\t\\t\\\"type\\\": \\\"MESSAGE\\\",\\n\\t\\t\\t\\t\\t\\t\\t\\\"label\\\": \\\"Label\\\",\\n\\t\\t\\t\\t\\t\\t\\t\\\"text\\\": \\\"Text\\\"\\n\\t\\t\\t\\t\\t\\t}]\\n    \\t\\t\\t},\\n    \\t\\t\\t{\\n    \\t\\t\\t\\t\\\"thumbnailImageUrl\\\": \\\"https://example.com/thumbnail_2\\\",\\n    \\t\\t\\t\\t\\\"title\\\": \\\"Carousel column title\\\",\\n    \\t\\t\\t\\t\\\"text\\\": \\\"Carousel column text\\\",\\n    \\t\\t\\t\\t\\\"actions\\\": [{\\n\\t\\t\\t\\t\\t\\t\\t\\\"type\\\": \\\"MESSAGE\\\",\\n\\t\\t\\t\\t\\t\\t\\t\\\"label\\\": \\\"Label\\\",\\n\\t\\t\\t\\t\\t\\t\\t\\\"text\\\": \\\"Text\\\"\\n\\t\\t\\t\\t\\t\\t}]\\n    \\t\\t\\t}\\n    \\t\\t]\\n    \\t}\\n    }\\n}\",\n      \"language\": \"text\"\n    }\n  ]\n}\n[/block]\n# Response format\n\nOn success, the response header HTTP status code will be `200 OK` and the message will be sent.\n\nIf you try to send the message without authorization, you will receive a `401 Unauthorized` error.\n\nOn an incorrectly formatted request, the HTTP status code will be `400 Bad Request`.","excerpt":"This method allows you to send a single message.","slug":"send-single-line-message-api","type":"endpoint","title":"Send LINE message"}

postSend LINE message

This method allows you to send a single message.

Definition

{{ api_url }}{{ page_api_url }}

Parameters

Body Params

from:
required
string
Application key you are using to send messages.
to:
required
string
User key or a phone number.
message:
required
object
Message object.

Examples


Result Format


Documentation

# Request Format [block:parameters] { "data": { "h-0": "Property name", "h-1": "Type", "0-0": "from", "1-0": "to", "2-0": "message", "0-1": "String", "1-1": "String", "2-1": "Object", "0-2": "Application key you are using to send messages.", "1-2": "User key.", "2-2": "Message object.", "h-2": "Description" }, "cols": 3, "rows": 3 } [/block] ## Message Object Supported message objects are text, image, video, audio, location, imagemap and template. ### Text Message [block:parameters] { "data": { "0-0": "type", "0-1": "String", "0-2": "Constant value - \"TEXT\".", "1-0": "text", "1-1": "String", "1-2": "Text of the message.", "h-0": "Property name", "h-1": "Type", "h-2": "Description" }, "cols": 3, "rows": 2 } [/block] [block:code] { "codes": [ { "code": "POST /line/1/single HTTP/1.1\nHost: api.infobip.com\nAuthorization: Basic QWxhZGRpbjpvcGVuIHNlc2FtZQ==\nContent-Type: application/json\nAccept: application/json\n\n{ \n \"from\":\"8F0792F86035A9F4290821F1EE6BC06A\",\n \"to\":\"aaaaaaaa-aaaa-aaaa-aaaa-aaaaaaaaaaaa\",\n \"message\": {\n \"type\":\"TEXT\",\n \"text\":\"Hello, World!\"\n }\n}", "language": "json" } ] } [/block] ### Image Message [block:parameters] { "data": { "h-0": "Property name", "h-1": "Type", "h-2": "Description", "0-0": "type", "0-1": "String", "0-2": "Constant value - \"IMAGE\".", "1-0": "url", "1-1": "String", "1-2": "URL of the image.", "2-0": "thumbnailUrl", "2-1": "String", "2-2": "URL of the image thumbnail." }, "cols": 3, "rows": 3 } [/block] [block:code] { "codes": [ { "code": "POST /line/1/single HTTP/1.1\nHost: api.infobip.com\nAuthorization: Basic QWxhZGRpbjpvcGVuIHNlc2FtZQ==\nContent-Type: application/json\nAccept: application/json\n\n{ \n \"from\":\"8F0792F86035A9F4290821F1EE6BC06A\",\n \"to\":\"aaaaaaaa-aaaa-aaaa-aaaa-aaaaaaaaaaaa\",\n \"message\": {\n \"type\":\"IMAGE\",\n \"url\":\"https://example.com/original.jpg\",\n \"thumbnailUrl\":\"https://example.com/preview.jpg\"\n }\n}", "language": "json" } ] } [/block] ### Video Message [block:parameters] { "data": { "0-0": "type", "0-1": "String", "0-2": "Constant value - \"VIDEO\".", "1-0": "url", "1-1": "String", "1-2": "URL of the video.", "2-0": "thumbnailUrl", "2-1": "String", "2-2": "URL of the video thumbnail.", "h-0": "Property name", "h-1": "Type", "h-2": "Description" }, "cols": 3, "rows": 3 } [/block] [block:code] { "codes": [ { "code": "POST /line/1/single HTTP/1.1\nHost: api.infobip.com\nAuthorization: Basic QWxhZGRpbjpvcGVuIHNlc2FtZQ==\nContent-Type: application/json\nAccept: application/json\n\n{ \n \"from\":\"8F0792F86035A9F4290821F1EE6BC06A\",\n \"to\":\"aaaaaaaa-aaaa-aaaa-aaaa-aaaaaaaaaaaa\",\n \"message\": {\n \"type\":\"VIDEO\",\n \"url\":\"https://example.com/original.mp4\",\n \"thumbnailUrl\":\"https://example.com/preview.jpg\",\n }\n}", "language": "json" } ] } [/block] ### Audio Message [block:parameters] { "data": { "0-0": "type", "0-1": "String", "1-1": "String", "2-1": "Number", "0-2": "Constant value - \"AUDIO\".", "1-0": "url", "2-0": "duration", "1-2": "URL of the audio.", "2-2": "Duration of audio (in milliseconds).", "h-0": "Property name", "h-1": "Type", "h-2": "Description" }, "cols": 3, "rows": 3 } [/block] [block:code] { "codes": [ { "code": "POST /line/1/single HTTP/1.1\nHost: api.infobip.com\nAuthorization: Basic QWxhZGRpbjpvcGVuIHNlc2FtZQ==\nContent-Type: application/json\nAccept: application/json\n\n{ \n \"from\":\"8F0792F86035A9F4290821F1EE6BC06A\",\n \"to\":\"aaaaaaaa-aaaa-aaaa-aaaa-aaaaaaaaaaaa\",\n \"message\": {\n \"type\":\"AUDIO\",\n \"url\":\"https://example.com/original.m4a\",\n \"duration\":240000\n }\n}", "language": "json" } ] } [/block] ### Location Message [block:parameters] { "data": { "0-0": "type", "0-1": "String", "0-2": "Constant value - \"LOCATION\"", "1-0": "title", "1-1": "String", "h-0": "Property name", "h-1": "Type", "h-2": "Description", "1-2": "Location title", "2-0": "address", "2-1": "String", "2-2": "Location address", "3-0": "latitude", "3-1": "number", "4-0": "longitude", "4-1": "number", "3-2": "Location latitude", "4-2": "Location longitude" }, "cols": 3, "rows": 5 } [/block] [block:code] { "codes": [ { "code": "POST /line/1/single HTTP/1.1\nHost: api.infobip.com\nAuthorization: Basic QWxhZGRpbjpvcGVuIHNlc2FtZQ==\nContent-Type: application/json\nAccept: application/json\n\n{ \n \"from\":\"8F0792F86035A9F4290821F1EE6BC06A\",\n \"to\":\"aaaaaaaa-aaaa-aaaa-aaaa-aaaaaaaaaaaa\",\n \"message\": {\n \"type\":\"LOCATION\",\n \"title\":\"Eiffel Tower\",\n \"address\": \"Champ de Mars, 5 Avenue Anatole France, 75007 Paris, France\",\n \"latitude\": 48.85837,\n \"longitude\": 2.294481\n }\n}", "language": "json" } ] } [/block] ### Sticker Message [block:parameters] { "data": { "h-0": "Property name", "h-1": "Type", "h-2": "Description", "0-0": "type", "0-1": "String", "0-2": "Constant value - \"STICKER\"", "1-0": "packageId", "2-0": "stickerId", "1-1": "String", "2-1": "String", "1-2": "Id of the sticker package", "2-2": "Id of the sticker" }, "cols": 3, "rows": 3 } [/block] [block:code] { "codes": [ { "code": "POST /line/1/single HTTP/1.1\nHost: api.infobip.com\nAuthorization: Basic QWxhZGRpbjpvcGVuIHNlc2FtZQ==\nContent-Type: application/json\nAccept: application/json\n\n{ \n \"from\":\"8F0792F86035A9F4290821F1EE6BC06A\",\n \"to\":\"aaaaaaaa-aaaa-aaaa-aaaa-aaaaaaaaaaaa\",\n \"message\": {\n \"type\":\"STICKER\",\n \"packageId\": \"1\",\n \"stickerId\": \"1\"\n }\n}", "language": "json" } ] } [/block] ### Imagemap Message [block:parameters] { "data": { "0-0": "type", "1-0": "baseUrl", "2-0": "altText", "3-0": "baseSize.width", "4-0": "baseSize", "5-0": "actions", "h-0": "Property name", "h-1": "Type", "h-2": "Description", "0-1": "String", "0-2": "Constant value - \"IMAGEMAP\"", "1-1": "String", "1-2": "Base URL that will have image size appended", "2-1": "String", "2-2": "Alternative text", "3-1": "number", "3-2": "Width of the base image", "4-1": "number", "4-2": "Height of the base image", "5-1": "array", "5-2": "Array of imagemap actions" }, "cols": 3, "rows": 6 } [/block] #### Imagemap - Area [block:parameters] { "data": { "h-0": "Property name", "h-1": "Type", "h-2": "Description", "0-0": "x", "1-0": "y", "2-0": "width", "3-0": "height", "0-1": "number", "1-1": "number", "2-1": "number", "3-1": "number", "0-2": "X coordinate of the action box", "1-2": "Y coordinate of the action box", "2-2": "Width of the action box", "3-2": "Height of the action box" }, "cols": 3, "rows": 4 } [/block] #### Imagemap - URI action [block:parameters] { "data": { "h-0": "Property name", "h-1": "Type", "h-2": "Description", "0-0": "type", "0-1": "String", "0-2": "Constant value - 'URI'", "1-0": "linkUri", "1-1": "String", "1-2": "Link to open on action", "2-0": "area", "2-1": "Area[]", "2-2": "Array of action box areas" }, "cols": 3, "rows": 3 } [/block] #### Imagemap - MESSAGE action [block:parameters] { "data": { "h-0": "Property name", "h-1": "Type", "h-2": "Description", "0-0": "type", "0-1": "String", "0-2": "Constant value - 'MESSAGE'", "1-0": "text", "1-1": "String", "1-2": "Message to send on action", "2-0": "area", "2-1": "Area[]", "2-2": "Array of action box areas" }, "cols": 3, "rows": 3 } [/block] [block:code] { "codes": [ { "code": "POST /line/1/single HTTP/1.1\nHost: api.infobip.com\nAuthorization: Basic QWxhZGRpbjpvcGVuIHNlc2FtZQ==\nContent-Type: application/json\nAccept: application/json\n\n{ \n \"from\":\"8F0792F86035A9F4290821F1EE6BC06A\",\n \"to\":\"aaaaaaaa-aaaa-aaaa-aaaa-aaaaaaaaaaaa\",\n \"message\": {\n \"type\":\"IMAGEMAP\",\n \"baseUrl\":\"https://example.url/base\",\n \"altText\": \"Alternative text\",\n \"baseSize\": {\n \"width\": 1040,\n \"height\": 1040\n },\n \"actions\": [\n {\n \"type\": \"URI\",\n \"linkUri\": \"https://example.url/link\",\n \"area\": {\n \"x\": 0,\n \"y\": 0,\n \"width\": 520,\n \"height\": 1040\n }\n },\n {\n \"type\": \"MESSAGE\",\n \"text\": \"Message text\",\n \"area\": {\n \"x\": 520,\n \"y\": 0,\n \"width\": 520,\n \"height\": 1040\n }\n }\n ]\n }\n}", "language": "json" } ] } [/block] ### Template message [block:parameters] { "data": { "h-0": "Property name", "h-1": "Type", "h-2": "Description", "0-0": "type", "0-1": "String", "0-2": "Constant value - 'TEMPLATE'", "1-0": "altText", "1-1": "String", "1-2": "Alternative text", "2-0": "template", "2-1": "object", "2-2": "Template specification - buttons, confirm or carousel" }, "cols": 3, "rows": 3 } [/block] #### Template actions - POSTBACK action [block:parameters] { "data": { "h-0": "Property name", "h-1": "Type", "h-2": "Description", "0-0": "type", "1-0": "label", "2-0": "data", "0-2": "Constant value - 'POSTBACK'", "1-2": "Action label", "2-2": "Action data", "0-1": "String", "1-1": "String", "2-1": "String" }, "cols": 3, "rows": 3 } [/block] #### Template actions - MESSAGE action [block:parameters] { "data": { "h-0": "Property name", "h-1": "Type", "h-2": "Description", "0-0": "type", "1-0": "label", "2-0": "text", "0-2": "Constant value - 'MESSAGE'", "1-2": "Action label", "2-2": "Action text", "0-1": "String", "1-1": "String", "2-1": "String" }, "cols": 3, "rows": 3 } [/block] #### Template actions - URI action [block:parameters] { "data": { "h-0": "Property name", "h-1": "Type", "h-2": "Description", "0-0": "type", "1-0": "label", "2-0": "uri", "0-2": "Constant value - 'URI'", "1-2": "Action label", "2-2": "Action URI", "0-1": "String", "1-1": "String", "2-1": "String" }, "cols": 3, "rows": 3 } [/block] #### Template - BUTTONS template [block:parameters] { "data": { "0-0": "type", "1-0": "thumbnailImageUrl", "2-0": "title", "3-0": "text", "4-0": "actions", "0-1": "String", "0-2": "Constant value - 'BUTTONS'", "1-1": "String", "2-1": "String", "3-1": "String", "4-1": "array", "4-2": "Template actions", "1-2": "Buttons template thumbnail image", "2-2": "Buttons template title", "3-2": "Buttons template text", "h-0": "Property name", "h-1": "Type", "h-2": "Description" }, "cols": 3, "rows": 5 } [/block] [block:code] { "codes": [ { "code": "POST /line/1/single HTTP/1.1\nHost: api.infobip.com\nAuthorization: Basic QWxhZGRpbjpvcGVuIHNlc2FtZQ==\nContent-Type: application/json\nAccept: application/json\n\n{\n \"from\":\"8F0792F86035A9F4290821F1EE6BC06A\",\n \t\"to\":\"aaaaaaaa-aaaa-aaaa-aaaa-aaaaaaaaaaaa\",\n \"message\": {\n \t\"type\":\"TEMPLATE\",\n \t\"altText\": \"Alternative text\",\n \t\"template\": {\n \t\t\"type\": \"BUTTONS\",\n \t\t\"thumbnailImageUrl\": \"https://example.com/thumbnail\",\n \t\t\"title\": \"Title\",\n \t\t\"text\": \"Text\",\n \t\t\"actions\": [\n\t\t\t\t{\n\t\t\t\t\t\"type\": \"POSTBACK\",\n\t\t\t\t\t\"label\": \"Postback action\",\n\t\t\t\t\t\"data\": \"Postback action data\"\n\t\t\t\t},\n\t\t\t\t{\n\t\t\t\t\t\"type\": \"MESSAGE\",\n\t\t\t\t\t\"label\": \"Message action\",\n\t\t\t\t\t\"text\": \"Message action text\"\n\t\t\t\t},\n\t\t\t\t{\n\t\t\t\t\t\"type\": \"URI\",\n\t\t\t\t\t\"label\": \"Uri message action\",\n\t\t\t\t\t\"uri\": \"http://infobip.com\"\n\t\t\t\t}\n \t\t]\n \t}\n }\n}", "language": "json" } ] } [/block] #### Template - CONFIRM template [block:parameters] { "data": { "h-0": "Property name", "h-1": "Type", "h-2": "Description", "0-0": "type", "0-1": "String", "0-2": "Constant value - 'BUTTONS'", "1-0": "text", "1-1": "String", "1-2": "Confirm template text", "2-0": "actions", "2-1": "array", "2-2": "Template actions" }, "cols": 3, "rows": 3 } [/block] [block:code] { "codes": [ { "code": "POST /line/1/single HTTP/1.1\nHost: api.infobip.com\nAuthorization: Basic QWxhZGRpbjpvcGVuIHNlc2FtZQ==\nContent-Type: application/json\nAccept: application/json\n\n{\n \"from\":\"8F0792F86035A9F4290821F1EE6BC06A\",\n \t\"to\":\"aaaaaaaa-aaaa-aaaa-aaaa-aaaaaaaaaaaa\",\n \"message\": {\n \t\"type\":\"TEMPLATE\",\n \t\"altText\": \"Alternative text\",\n \t\"template\": {\n \t\t\"type\": \"CONFIRM\",\n \t\t\"text\": \"Do you want to confirm something?\",\n \t\t\"actions\": [\n\t\t\t\t{\n\t\t\t\t\t\"type\": \"MESSAGE\",\n\t\t\t\t\t\"label\": \"Yes\",\n\t\t\t\t\t\"text\": \"You have confirmed!\"\n\t\t\t\t},\n\t\t\t\t{\n\t\t\t\t\t\"type\": \"MESSAGE\",\n\t\t\t\t\t\"label\": \"No\",\n\t\t\t\t\t\"text\": \"You didn't confirm!\"\n\t\t\t\t}\n \t\t]\n \t}\n }\n}", "language": "json" } ] } [/block] #### Template - CAROUSEL template [block:parameters] { "data": { "h-0": "Property name", "h-1": "Type", "h-2": "Description", "0-0": "type", "0-1": "String", "0-2": "Constant value - 'CAROUSEL'", "1-0": "columns", "1-1": "array", "1-2": "Carousel columns" }, "cols": 3, "rows": 2 } [/block] #### Carousel template - Column [block:parameters] { "data": { "h-0": "Property name", "h-1": "Type", "h-2": "Description", "0-0": "thumbnailImageUrl", "0-1": "String", "0-2": "Carousel column thumbnail image", "1-0": "title", "2-0": "text", "1-1": "String", "2-1": "String", "1-2": "Carousel column title", "2-2": "Carousel column text", "3-0": "actions", "3-1": "array", "3-2": "Carousel column actions" }, "cols": 3, "rows": 4 } [/block] [block:code] { "codes": [ { "code": "POST /line/1/single HTTP/1.1\nHost: api.infobip.com\nAuthorization: Basic QWxhZGRpbjpvcGVuIHNlc2FtZQ==\nContent-Type: application/json\nAccept: application/json\n\n{\n \"from\":\"8F0792F86035A9F4290821F1EE6BC06A\",\n \t\"to\":\"aaaaaaaa-aaaa-aaaa-aaaa-aaaaaaaaaaaa\",\n \"message\": {\n \"type\":\"TEMPLATE\",\n \"altText\": \"Alternative text\",\n \"template\": {\n \t \"type\": \"CAROUSEL\",\n \t \"columns\": [\n {\n \t\t\t\t\"thumbnailImageUrl\": \"https://example.com/thumbnail_1\",\n \t\t\t\t\"title\": \"Carousel column title\",\n \t\t\t\t\"text\": \"Carousel column text\",\n \t\t\t\t\"actions\": [{\n\t\t\t\t\t\t\t\"type\": \"MESSAGE\",\n\t\t\t\t\t\t\t\"label\": \"Label\",\n\t\t\t\t\t\t\t\"text\": \"Text\"\n\t\t\t\t\t\t}]\n \t\t\t},\n \t\t\t{\n \t\t\t\t\"thumbnailImageUrl\": \"https://example.com/thumbnail_2\",\n \t\t\t\t\"title\": \"Carousel column title\",\n \t\t\t\t\"text\": \"Carousel column text\",\n \t\t\t\t\"actions\": [{\n\t\t\t\t\t\t\t\"type\": \"MESSAGE\",\n\t\t\t\t\t\t\t\"label\": \"Label\",\n\t\t\t\t\t\t\t\"text\": \"Text\"\n\t\t\t\t\t\t}]\n \t\t\t}\n \t\t]\n \t}\n }\n}", "language": "text" } ] } [/block] # Response format On success, the response header HTTP status code will be `200 OK` and the message will be sent. If you try to send the message without authorization, you will receive a `401 Unauthorized` error. On an incorrectly formatted request, the HTTP status code will be `400 Bad Request`.