Receiving Cascade Information

The api/cascade/get-all method is used to receive information about cascades.

Вызов метода api/cascade/get-all

To call the api/cascade/get-all method, send a POST request to the URL https://app.edna.io/api/cascade/get-all/.

If the request is successful, the method returns a response with a code of 200 an array of JSON objects [{...}, {...}, {...}] with the response parameters.

If you have blocked signatures, the response format will include information about the block.

Request Body Format

The request body contains an empty JSON object enclosed in curly braces {}.

Response Example

Example response if the request is successful and all cascades are active:

[
    {
        "id": 2563,
        "name": "wa-sms-viber",
        "status": "ACTIVE",
        "stagesCount": 3,
        "stages": [
            {
                "order": 0,
                "uuid": "05c1203a-c77b-4cb4-acf2-e8ed1de4d8221",
                "subject": {
                    "id": 16451,
                    "name": "Test_MFMSCOM-4938",
                    "subject": "Test_MFMSCOM-4938",
                    "type": "SMS",
                    "tenantId": 334,
                    "testing": false,
                    "locked": false,
                    "approveStatus": "APPROVED"
                },
                "stages": [
                    {
                        "order": 1,
                        "uuid": "55cf6d4b-2e99-4b25-8930-c81cd66bd114",
                        "decision": {
                            "type": "TTL",
                            "ttl": "00:01:00"
                        },
                        "subject": {
                            "id": 18532,
                            "name": "RETAIL2_WA_EM_temp",
                            "subject": "RETAIL2_WA_EM_temp",
                            "type": "WHATSAPP",
                            "tenantId": 334,
                            "testing": false,
                            "locked": false,
                            "approveStatus": "APPROVED"
                        },
                        "stages": [
                            {
                                "order": 2,
                                "uuid": "db80e215-2088-4782-9f73-c8f8b1e7d644",
                                "decision": {
                                    "type": "TTL",
                                    "ttl": "00:01:00"
                                },
                                "subject": {
                                    "id": 16724,
                                    "name": "RETAIL2_VIBER_EM",
                                    "subject": "RETAIL2_VIBER_EM",
                                    "type": "VIBER",
                                    "tenantId": 334,
                                    "testing": false,
                                    "locked": false,
                                    "approveStatus": "APPROVED"
                                },
                                "stages": []
                            }
                        ]
                    }
                ]
            }
        ]
    }
]

    Example response if the request is successful and the disabled cascade is returned:

    [
        {
            "id": 2533,
            "name": "whatsapp-conversation",
            "status": "DISABLED",
            "stagesCount": 1,
            "stages": [
                {
                    "order": 0,
                    "uuid": "85e891e5-c6e4-430c-a687-c5beefd270b4",
                    "subject": {
                        "id": 18532,
                        "name": "RETAIL2_WA_EM_temp",
                        "subject": "RETAIL2_WA_EM_temp",
                        "type": "WHATSAPP",
                        "tenantId": 334,
                        "testing": false,
                        "locked": false,
                        "approveStatus": "APPROVED"
                    },
                    "stages": []
                }
            ]
        }
    ]

    Response Parameters

    ParameterData typeDescription
    idlongThe cascade ID. Specified when sending messages in the cascadeId attribute.
    namestringThe cascade name specified when the cascade was created.
    statusstringCascade status. For example, ACTIVE or DISABLED.
    stagesCountstringThe number of steps in the cascade.
    stagesobject The information about cascades. The array contains a description of the composition of the cascade.
    orderlongThe sequence number of the cascade step.
    uuidstringThe step ID assigned by the system.
    decisionobject The description of the step. It can be null or contain "type": "TTL", "ttl": "00:00:40", where ttl is the time after which it is necessary to proceed to the described step if the message was not delivered in the previous step.
    subjectobject The information about the channel.
    subject.idlongThe signature ID.
    subject.namestringThe channel name specified when the channel was created.
    subject.subjectstringThe signature name.
    subject.descriptionstringThe additional information about the channel.
    subject.typestringThe channel type. For example, SMS, VIBER, WHATSAPP.
    subject.tenantIdlongYour account ID.