Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

How to fetch existing Scenario Keys

Status
titleGET
https://xxxxxxx.api.infobip.com/omni/1/scenarios

Status
colourYellow
titleAUTH
Provide as BASIC AUTH a valid username and password for the account

The expected answer is similar to the following

Code Block
{
    "scenarios": [
        {
            "key": "F16AF5B911111111115DE2CAF0687",
            "name": "PreShared",
            "flow": [
                {
                    "from": "4470000000",
                    "channel": "WHATSAPP"
                }
            ],
            "default": true
        }
    ]
}

How to create a new Scenario Key

...

Status
colourRed
titlePOST
https://xxxxx.api.infobip.com/omni/1/scenarios

Status
colourYellow
titleAUTH
Provide as BASIC AUTH a valid username and password for the account

Payload to post

Code Block
{
  "name":"Name cliente",
  "flow": [
    {
      "from": "441234560000",
      "channel": "WHATSAPP"
    }
  ],
  "default": true
}	
Info

The telephone number is prefixed with the international country prefix without 00 or +

Expected answer

Code Block
{
    "scenarios": [
        {
            "key": "F16AF5B911111111115DE2CAF0687",
            "name": "Name cliente",
            "flow": [
                {
                    "from": "4470000000",
                    "channel": "WHATSAPP"
                }
            ],
            "default": true
        }
    ]
}