Kihagyás

Scenario API V1

WsScenarioAPI WSDL letöltése

List scenario definitions

Szcenárió definíciók lekérése.

Web service API

Kérés

Név Típus Leírás
requestMeta RequestMeta_V1 A kérés metaadatai.
includeDeleted Boolean Törölt elemek mutatása.
name String A definíció neve.
description String A definíció leírása.
nameOrDescription String A definíció neve vagy leírása.

Válasz

Név Típus Leírás
status ResponseStatus_V1 A válasz státusza.
params Param_V1 [ ] Egyéb paraméterek listája.
definitions ScenarioDef_V1 [ ] A megtalált definíciók.
count Integer Találatok száma.

Minta

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
                  xmlns:scen="http://scenario.api.hammy.dbx.hu/">
    <soapenv:Header/>
    <soapenv:Body>
        <scen:listScenarioDefinitions>
            <request>
                <includeDeleted>false</includeDeleted>
                <requestMeta>
                    <clientHashKey>221d316146c591897238</clientHashKey>
                </requestMeta>
            </request>
        </scen:listScenarioDefinitions>
    </soapenv:Body>
</soapenv:Envelope>
<S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/">
    <S:Body>
        <ns2:listScenarioDefinitionsResponse
                xmlns:ns2="http://scenario.api.hammy.dbx.hu/">
            <response>
                <count>4</count>
                <definitions>
                    <description>s111223</description>
                    <name>S12</name>
                    <uuid>74e10fb2-9aed-430d-ad57-6423d2333c24</uuid>
                </definitions>
                <definitions>
                    <description>desc2</description>
                    <name>S02</name>
                    <uuid>0fd05e6b-cb63-4519-b9b3-5c97717109a9</uuid>
                </definitions>
                <definitions>
                    <description>desc2</description>
                    <name>S03</name>
                    <uuid>0fd05e6b-cb63-4519-b9b3-5c9771710933</uuid>
                </definitions>
                <definitions>
                    <description>desc</description>
                    <name>S04</name>
                    <uuid>0fd05e6b-cb63-4519-b9b3-5c97717109a1</uuid>
                </definitions>
                <status>
                    <code>0</code>
                    <messages/>
                </status>
            </response>
        </ns2:listScenarioDefinitionsResponse>
    </S:Body>
</S:Envelope>

REST API

REST API Info

Kérés

GET hammy/json/scenario/v1/scenarioDefinitions

Paraméter Típus Leírás
limit Integer A keresési találatok maximális száma.
offset Integer A találati lista kezdete.
sort String Rendezés.
clientHashKey String A hívó kliens azonosítója.
userName String A felhasználó neve.
params Param_V1 [ ] Egyéb meta adatok.
includeDeleted Boolean Törölt elemek mutatása.
name String A definíció neve.
description String A definíció leírása.
nameOrDescription String A definíció neve vagy leírása.

Válasz

Név Típus Leírás
meta JListMeta1 A válaszhoz tartozó metaadatok.
list JScenarioDef1 [ ] A megtalált definíciók.

Minta

GET /hammy/json/scenario/v1/scenarioDefinitions
Authorization: JWT {{jwtToken}}
X-Client-Hash-Key: {{clientHashKey}}
X-User-Name: {{userName}}
Content-Type: application/vnd.api+json

Query params:
-------------------------
includeDeleted={{true|false|null}}
HTTP/1.1 200 OK
Content-Type: application/vnd.api+json

{
  "data": [
    {
      "type": "scenarioDefinitions",
      "id": "0fd05e6b-cb63-4519-b9b3-5c97717109a9",
      "attributes": {
        "name": "S02",
        "description": "desc2"
      }
    },
    {
      "type": "scenarioDefinitions",
      "id": "0fd05e6b-cb63-4519-b9b3-5c97717109a1",
      "attributes": {
        "name": "S04",
        "description": "desc"
      }
    }
  ],
  "meta": {
    "total": 2,
    "params": [],
    "responseStatus": {
      "code": 0,
      "messages": []
    }
  }
}

Create scenario definition

Szcenárió definíció létrehozása.

Web service API

Kérés

Név Típus Leírás
requestMeta RequestMeta_V1 A kérés metaadatai.
definition ScenarioDef_V1 A szcenárió definíció paraméterei.

Válasz

Név Típus Leírás
status ResponseStatus_V1 A válasz státusza.
params Param_V1 [ ] Egyéb paraméterek listája.
definition ScenarioDef_V1 A létrehozott szcenárió.

Minta

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
                  xmlns:scen="http://scenario.api.hammy.dbx.hu/">
    <soapenv:Header/>
    <soapenv:Body>
        <scen:createScenarioDef>
            <request>
                <definition>
                    <description>desc</description>
                    <name>S11</name>
                    <uuid>0fd05e6b-cb63-4519-b9b3-5c97717109a9</uuid>
                </definition>
                <requestMeta>
                    <clientHashKey>221d316146c591897238</clientHashKey>
                    <userName>username</userName>
                </requestMeta>
            </request>
        </scen:createScenarioDef>
    </soapenv:Body>
</soapenv:Envelope>
<S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/">
    <S:Body>
        <ns2:createScenarioDefResponse
                xmlns:ns2="http://scenario.api.hammy.dbx.hu/">
            <response>
                <definition>
                    <description>desc</description>
                    <name>S11</name>
                    <uuid>74e10fb2-9aed-430d-ad57-6423d2333c24</uuid>
                </definition>
                <status>
                    <code>0</code>
                    <messages/>
                </status>
            </response>
        </ns2:createScenarioDefResponse>
    </S:Body>
</S:Envelope>

REST API

REST API Info

Kérés

POST hammy/json/scenario/v1/scenarioDefinitions

body: JScenarioDef1

Válasz

Típus Leírás
JScenarioDef1 A létrehozott definíció.

Minta

POST /hammy/json/scenario/v1/scenarioDefinitions
Authorization: JWT {{jwtToken}}
X-Client-Hash-Key: {{clientHashKey}}
X-User-Name: {{userName}}
Content-Type: application/vnd.api+json

{
    "data": {
        "type": "scenarioDefinitions",
        "id": "0fd05e6b-cb63-4519-b9b3-5c97717109a9",
        "attributes": {
            "name": "S02",
            "description": "desc2"
        }
    },
    "included": []
}

Modify scenario definition

Szcenárió definíció módosítása.

Web service API

Kérés

Név Típus Leírás
requestMeta RequestMeta_V1 A kérés metaadatai.
definition ScenarioDef_V1 A módosítandó definíció.

Válasz

Név Típus Leírás
status ResponseStatus_V1 A válasz státusza.
params Param_V1 [ ] Egyéb paraméterek listája.
definition ScenarioDef_V1 A módosított szcenárió.

Minta

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
                  xmlns:scen="http://scenario.api.hammy.dbx.hu/">
    <soapenv:Header/>
    <soapenv:Body>
        <scen:modifyScenarioDef>
            <request>
                <definition>
                    <description>s111223</description>
                    <name>S12</name>
                    <uuid>74e10fb2-9aed-430d-ad57-6423d2333c24</uuid>
                </definition>
                <requestMeta>
                    <clientHashKey>221d316146c591897238</clientHashKey>
                    <userName>username</userName>
                </requestMeta>
            </request>
        </scen:modifyScenarioDef>
    </soapenv:Body>
</soapenv:Envelope>
<S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/">
    <S:Body>
        <ns2:modifyScenarioDefResponse
                xmlns:ns2="http://scenario.api.hammy.dbx.hu/">
            <response>
                <definition>
                    <description>s111223</description>
                    <name>S12</name>
                    <uuid>74e10fb2-9aed-430d-ad57-6423d2333c24</uuid>
                </definition>
                <status>
                    <code>0</code>
                    <messages/>
                </status>
            </response>
        </ns2:modifyScenarioDefResponse>
    </S:Body>
</S:Envelope>

REST API

REST API Info

Kérés

PUT hammy/json/scenario/v1/scenarioDefinitions/{{definitionUuid}}

body: JScenarioDef1

path

Név Típus Leírás
definitionUuid String A módosítandó definíció azonosítója.

Válasz

Típus Leírás
JScenarioDef1 A létrehozott definíció.

Minta

PUT /hammy/json/scenario/v1/scenarioDefinitions/{definitionUuid}
Authorization: JWT {{jwtToken}}
X-Client-Hash-Key: {{clientHashKey}}
X-User-Name: {{userName}}
Content-Type: application/vnd.api+json

{
    "data": {
        "type": "scenarioDefinitions",
        "id": "0fd05e6b-cb63-4519-b9b3-5c97717109a9",
        "attributes": {
            "name": "S02",
            "description": "desc2"
        }
    },
    "included": []
}

Delete scenario definition

Szcenárió definíció törlése.

A törlés funkció kétféle módon működik:

  • Ha egy definíció még nem példányosodott (nincs belőle scenario táblában példány), akkor minden adatával együtt fizikailag töröljük az adatbázisból.
  • Amennyiben már példányosodott, abban az esetben a scenario_defs táblában a deleted_at oszlop töltődik, de fizikailag nem töröljük az adatbázisból.

Web service API

Kérés

Név Típus Leírás
requestMeta RequestMeta_V1 A kérés metaadatai.
definitionUuid String A törlendő definíció UUID-ja.

Válasz

Név Típus Leírás
status ResponseStatus_V1 A válasz státusza.
params Param_V1 [ ] Egyéb paraméterek listája.
definition ScenarioDef_V1 A törölt szcenárió.

Minta

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
                  xmlns:scen="http://scenario.api.hammy.dbx.hu/">
    <soapenv:Header/>
    <soapenv:Body>
        <scen:deleteScenarioDef>
            <request>
                <definitionUuid>0fd05e6b-cb63-4519-b9b3-5c97717109a1</definitionUuid>
                <requestMeta>
                    <clientHashKey>221d316146c591897238</clientHashKey>
                </requestMeta>
            </request>
        </scen:deleteScenarioDef>
    </soapenv:Body>
</soapenv:Envelope>
<S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/">
    <S:Body>
        <ns2:deleteScenarioDefResponse xmlns:ns2="http://scenario.api.hammy.dbx.hu/">
            <response>                
                <status>
                    <code>0</code>
                    <messages/>
                </status>
            </response>
        </ns2:deleteScenarioDefResponse>
    </S:Body>
</S:Envelope>

REST API

REST API Info

Kérés

DELETE hammy/json/scenario/v1/scenarioDefinitions/{{definitionUuid}}

path

Név Típus Leírás
definitionUuid String A törlendő definíció azonosítója.

Válasz

Típus Leírás
JScenarioDef1 A törölt definíció.

Minta

DELETE /hammy/json/scenario/v1/scenarioDefinitions/{definitionUuid}
Authorization: JWT {{jwtToken}}
X-Client-Hash-Key: {{clientHashKey}}
X-User-Name: {{userName}}

List scenario definition versions

Szcenárió definícióhoz tartozó verziók listázása.

Web service API

Kérés

Név Típus Leírás
requestMeta RequestMeta_V1 A kérés metaadatai.
definitionUuid String A definíció UUID-ja.

Válasz

Név Típus Leírás
status ResponseStatus_V1 A válasz státusza.
params Param_V1 [ ] Egyéb paraméterek listája.
versions ScenarioDefVersion_V1 [ ] A definíció verziói.
count Integer A találatok száma.

Minta


REST API

REST API Info

Kérés

GET hammy/json/scenario/v1/scenarioDefinitions/{definitionUuid}/versions

path

Név Típus Leírás
definitionUuid String A törlendő definíció azonosítója.

GET hammy/json/scenario/v1/scenarioVersions

Paraméter Típus Leírás
limit Integer A keresési találatok maximális száma.
offset Integer A találati lista kezdete.
sort String Rendezés.
clientHashKey String A hívó kliens azonosítója.
userName String A felhasználó neve.
params Param_V1 [ ] Egyéb meta adatok.
definitionUuid String Az adott definíció azonosítója.

Válasz

Név Típus Leírás
meta JListMeta1 A válaszhoz tartozó metaadatok.
list JScenarioDefVersion1 [ ] A megtalált verziók.

Minta

GET /hammy/json/scenario/v1/scenarioDefinitions/{definitionUuid}/versions
vagy GET /hammy/json/scenario/v1/scenarioVersions?definitionUuid={definitionUuid}
Authorization: JWT {{jwtToken}}
X-Client-Hash-Key: {{clientHashKey}}
X-User-Name: {{userName}}
HTTP/1.1 200 OK
Content-Type: application/vnd.api+json

{
  "data": [
    {
      "type": "scenarioVersions",
      "id": "aafcfd78-4c94-4e35-af9e-af7a54d844ea",
      "attributes": {
        "version": 1,
        "status": "DRAFT"
      },
      "relationships": {
        "nodeDefinitions": {
          "data": [
            {
              "type": "scenarioNodeDefinitions",
              "id": "811e3162-f951-4b58-a753-fd0e00815b4a"
            },
            {
              "type": "scenarioNodeDefinitions",
              "id": "da1069f1-02ea-4b03-a1a4-44ab8acacf2a"
            },
            {
              "type": "scenarioNodeDefinitions",
              "id": "111e3162-f951-4b58-a753-fd0e00815b4b"
            }
          ]
        }
      }
    }
  ],
  "included": [
    {
      "type": "scenarioEventDefinitions",
      "id": "3d900089-6226-4483-98e0-365a9f42c134",
      "attributes": {
        "eventName": "ENTITY_SENT",
        "parentNodeDefUuid": "111e3162-f951-4b58-a753-fd0e00815b4b"
      }
    },
    {
      "type": "scenarioNodeDefinitions",
      "id": "da1069f1-02ea-4b03-a1a4-44ab8acacf2a",
      "attributes": {
        "entry": true,
        "nodeType": "SEND",
        "messageType": "TEST.MAIL",
        "channel": "EMAIL"
      },
      "relationships": {
        "eventDefinitions": {
          "data": [
            {
              "type": "scenarioEventDefinitions",
              "id": "131dd584-4388-41f0-bf0c-9fca8bf16d8a"
            },
            {
              "type": "scenarioEventDefinitions",
              "id": "131dd584-4388-41f0-bf0c-9fca8bf16d7a"
            }
          ]
        }
      }
    },
    {
      "type": "scenarioEventDefinitions",
      "id": "131dd584-4388-41f0-bf0c-9fca8bf16d8a",
      "attributes": {
        "eventName": "EMAIL_BOUNCED",
        "parentNodeDefUuid": "da1069f1-02ea-4b03-a1a4-44ab8acacf2a"
      }
    },
    {
      "type": "scenarioEventDefinitions",
      "id": "131dd584-4388-41f0-bf0c-9fca8bf16d7a",
      "attributes": {
        "eventName": "ENTITY_SENT",
        "eventNodeDefUuid": "811e3162-f951-4b58-a753-fd0e00815b4a",
        "parentNodeDefUuid": "da1069f1-02ea-4b03-a1a4-44ab8acacf2a"
      }
    },
    {
      "type": "scenarioNodeDefinitions",
      "id": "811e3162-f951-4b58-a753-fd0e00815b4a",
      "attributes": {
        "entry": false,
        "nodeType": "WAIT",
        "timeout": 5,
        "timeoutUnit": "MINUTES"
      },
      "relationships": {
        "eventDefinitions": {
          "data": []
        }
      }
    },
    {
      "type": "scenarioNodeDefinitions",
      "id": "111e3162-f951-4b58-a753-fd0e00815b4b",
      "attributes": {
        "entry": false,
        "nodeType": "SEND",
        "messageType": "TEST.SMS",
        "channel": "SMS"
      },
      "relationships": {
        "eventDefinitions": {
          "data": [
            {
              "type": "scenarioEventDefinitions",
              "id": "3d900089-6226-4483-98e0-365a9f42c134"
            }
          ]
        }
      }
    }
  ],
  "meta": {
    "total": 1,
    "params": [],
    "responseStatus": {
      "code": 0,
      "messages": []
    }
  }
}

Show scenario definition version

Adott szcenárió definíció verziójának lekérése.

REST API

Ez a szolgáltatás jelenleg csak REST API-n keresztül elérhető.

REST API

REST API Info

Kérés

GET hammy/json/scenario/v1/scenarioVersions/{{versionUuid}}

path

Név Típus Leírás
versionUuid String A verzió UUID-ja.

Válasz

Típus Leírás
JScenarioDefVersion1 [ ] A megtalált verziók.

Minta

GET /hammy/json/scenario/v1/scenarioVersions/{{versionUuid}}
Authorization: JWT {{jwtToken}}
X-Client-Hash-Key: {{clientHashKey}}
X-User-Name: {{userName}}

GET /hammy/json/scenario/v1/scenarioVersions/8524c088-0390-463c-9ae9-929bd938668e
HTTP/1.1 200 OK
Content-Type: application/vnd.api+json

{
  "data": {
    "type": "scenarioVersions",
    "id": "8524c088-0390-463c-9ae9-929bd938668e",
    "attributes": {
      "definitionUuid": "5a6dd487-56ef-4396-a2e2-f29b1ef970ea",
      "version": 2,
      "status": "ACTUAL"
    },
    "relationships": {
      "nodeDefinitions": {
        "data": [
          {
            "type": "scenarioNodeDefinitions",
            "id": "ccf7f91f-ec69-4d3a-9575-166d2c4fb12a"
          },
          {
            "type": "scenarioNodeDefinitions",
            "id": "ad5dbb03-c580-46df-b95b-4a208cce5afc"
          },
          {
            "type": "scenarioNodeDefinitions",
            "id": "5c01b66e-57db-4603-8a73-6cc0cf794472"
          }
        ]
      }
    }
  },
  "included": [
    {
      "type": "scenarioEventDefinitions",
      "id": "ac40ed1b-f426-4146-89dd-9a3a792efed5",
      "attributes": {
        "eventName": "LINK_CLICKED",
        "eventParam": "ffc3eb3b-db23-42df-98c2-e22cbf5ee5c4",
        "eventNodeDefUuid": "ccf7f91f-ec69-4d3a-9575-166d2c4fb12a",
        "parentNodeDefUuid": "5c01b66e-57db-4603-8a73-6cc0cf794472"
      }
    },
    {
      "type": "scenarioEventDefinitions",
      "id": "f6a46d27-1713-472b-b617-71e3490f7eb6",
      "attributes": {
        "eventName": "ENTITY_SENT",
        "parentNodeDefUuid": "ad5dbb03-c580-46df-b95b-4a208cce5afc"
      }
    },
    {
      "type": "scenarioNodeDefinitions",
      "id": "5c01b66e-57db-4603-8a73-6cc0cf794472",
      "attributes": {
        "entry": false,
        "nodeType": "WAIT",
        "timeout": 12,
        "timeoutUnit": "DAYS"
      },
      "relationships": {
        "eventDefinitions": {
          "data": [
            {
              "type": "scenarioEventDefinitions",
              "id": "ac40ed1b-f426-4146-89dd-9a3a792efed5"
            }
          ]
        }
      }
    },
    {
      "type": "scenarioEventDefinitions",
      "id": "3b57cf59-5704-4412-9d3b-a8cd5d925a60",
      "attributes": {
        "eventName": "ENTITY_SENT",
        "parentNodeDefUuid": "ad5dbb03-c580-46df-b95b-4a208cce5afc"
      }
    },
    {
      "type": "scenarioNodeDefinitions",
      "id": "ad5dbb03-c580-46df-b95b-4a208cce5afc",
      "attributes": {
        "entry": true,
        "nodeType": "SEND",
        "messageType": "TEST.MAIL",
        "channel": "EMAIL"
      },
      "relationships": {
        "eventDefinitions": {
          "data": [
            {
              "type": "scenarioEventDefinitions",
              "id": "525978aa-9ffa-494e-855a-4ad3cce23cce"
            },
            {
              "type": "scenarioEventDefinitions",
              "id": "f6a46d27-1713-472b-b617-71e3490f7eb6"
            },
            {
              "type": "scenarioEventDefinitions",
              "id": "3b57cf59-5704-4412-9d3b-a8cd5d925a60"
            }
          ]
        }
      }
    },
    {
      "type": "scenarioNodeDefinitions",
      "id": "ccf7f91f-ec69-4d3a-9575-166d2c4fb12a",
      "attributes": {
        "entry": false,
        "nodeType": "ARCHIVE"
      },
      "relationships": {
        "eventDefinitions": {
          "data": []
        }
      }
    },
    {
      "type": "scenarioEventDefinitions",
      "id": "525978aa-9ffa-494e-855a-4ad3cce23cce",
      "attributes": {
        "eventName": "ENTITY_SENT",
        "eventNodeDefUuid": "5c01b66e-57db-4603-8a73-6cc0cf794472",
        "parentNodeDefUuid": "ad5dbb03-c580-46df-b95b-4a208cce5afc"
      }
    }
  ],
  "meta": {
    "params": [],
    "responseStatus": {
      "code": 0,
      "messages": []
    }
  }
}

Create scenario definition version

Szcenárió definícióhoz tartozó verzió létrehozása.

Web service API

Kérés

Név Típus Leírás
requestMeta RequestMeta_V1 A kérés metaadatai.
versionData ScenarioDefVersion_V1 A létrehozandó verzió.

Válasz

Név Típus Leírás
status ResponseStatus_V1 A válasz státusza.
params Param_V1 [ ] Egyéb paraméterek listája.
versionData ScenarioDefVersion_V1 A létrehozott verzió.

Minta


REST API

REST API Info

Kérés

POST hammy/json/scenario/v1/scenarioVersions

body: JScenarioDefVersion1

Válasz

Típus Leírás
JScenarioDefVersion1 A létrehozott verzió.

Minta

POST /hammy/json/scenario/v1/scenarioVersions
Authorization: JWT {{jwtToken}}
X-Client-Hash-Key: {{clientHashKey}}
X-User-Name: {{userName}}
Content-Type: application/vnd.api+json

{
    "data": {
        "type": "scenarioVersions",
        "id": "aafcfd78-4c94-4e35-af9e-af7a54d844ea",
        "attributes": {
            "definitionUuid": "0fd05e6b-cb63-4519-b9b3-5c97717109a9",
            "version": 1,
            "status": "DRAFT"
        },
        "relationships": {
            "nodeDefinitions": {
                "data": [
                    {
                        "type": "scenarioNodeDefinitions",
                        "id": "da1069f1-02ea-4b03-a1a4-44ab8acacf2a"
                    },
                    {
                        "type": "scenarioNodeDefinitions",
                        "id": "811e3162-f951-4b58-a753-fd0e00815b4a"
                    }
                ]
            }
        }
    },
    "included": [
        {
            "type": "scenarioEventDefinitions",
            "id": "131dd584-4388-41f0-bf0c-9fca8bf16d7a",
            "attributes": {
                "eventName": "ENTITY_SENT",
                "eventNodeDefUuid": "811e3162-f951-4b58-a753-fd0e00815b4a",
                "parentNodeDefUuid": "da1069f1-02ea-4b03-a1a4-44ab8acacf2a"
            }
        },
        {
            "type": "scenarioEventDefinitions",
            "id": "131dd584-4388-41f0-bf0c-9fca8bf16d8a",
            "attributes": {
                "eventName": "EMAIL_BOUNCED",
                "parentNodeDefUuid": "da1069f1-02ea-4b03-a1a4-44ab8acacf2a"
            }
        },
        {
            "type": "scenarioNodeDefinitions",
            "id": "da1069f1-02ea-4b03-a1a4-44ab8acacf2a",
            "attributes": {
                "entry": true,
                "nodeType": "SEND",
                "channel": "EMAIL",
                "messageType": "TEST.MAIL"
            },
            "relationships": {
                "eventDefinitions": {
                    "data": [
                        {
                            "type": "scenarioEventDefinitions",
                            "id": "131dd584-4388-41f0-bf0c-9fca8bf16d7a"
                        },
                        {
                            "type": "scenarioEventDefinitions",
                            "id": "131dd584-4388-41f0-bf0c-9fca8bf16d8a"
                        }
                    ]
                }
            }
        },
        {
            "type": "scenarioNodeDefinitions",
            "id": "811e3162-f951-4b58-a753-fd0e00815b4a",
            "attributes": {
                "entry": false,
                "nodeType": "WAIT",
                "timeout": "5",
                "timeoutUnit": "MINUTES"
            },
            "relationships": {
                "eventDefinitions": {
                    "data": []
                }
            }
        }
    ]
}

Modify scenario definition version

Szcenárió definícióhoz tartozó verzió módosítása.

Web service API

Kérés

Név Típus Leírás
requestMeta RequestMeta_V1 A kérés metaadatai.
versionData ScenarioDefVersion_V1 A módosítandó verzió.

Válasz

Név Típus Leírás
status ResponseStatus_V1 A válasz státusza.
params Param_V1 [ ] Egyéb paraméterek listája.
versionData ScenarioDefVersion_V1 A módosított verzió.

Minta


REST API

REST API Info

Kérés

PUT hammy/json/scenario/v1/scenarioVersions/{{versionUuid}}

body: JScenarioDefVersion1

Válasz

Típus Leírás
JScenarioDefVersion1 A módosított verzió.

Minta

PUT /hammy/json/scenario/v1/scenarioVersions/{{versionUuid}}

Headers:
-------------------------
X-Client-Hash-Key: {{clientHashKey}}
X-User-Name: {{userName}}
Content-Type: application/vnd.api+json

{
    "data": {
        "type": "scenarioVersions",
        "id": "aafcfd78-4c94-4e35-af9e-af7a54d844ea",
        "attributes": {
            "definitionUuid": "0fd05e6b-cb63-4519-b9b3-5c97717109a9",
            "version": 1,
            "status": "DRAFT"
        },
        "relationships": {
            "nodeDefinitions": {
                "data": [
                    {
                        "type": "scenarioNodeDefinitions",
                        "id": "da1069f1-02ea-4b03-a1a4-44ab8acacf2a"
                    },
                    {
                        "type": "scenarioNodeDefinitions",
                        "id": "811e3162-f951-4b58-a753-fd0e00815b4a"
                    }
                ]
            }
        }
    },
    "included": [
        {
            "type": "scenarioEventDefinitions",
            "id": "131dd584-4388-41f0-bf0c-9fca8bf16d7a",
            "attributes": {
                "eventName": "ENTITY_SENT",
                "eventNodeDefUuid": "811e3162-f951-4b58-a753-fd0e00815b4a",
                "parentNodeDefUuid": "da1069f1-02ea-4b03-a1a4-44ab8acacf2a"
            }
        },
        {
            "type": "scenarioEventDefinitions",
            "id": "131dd584-4388-41f0-bf0c-9fca8bf16d8a",
            "attributes": {
                "eventName": "EMAIL_BOUNCED",
                "parentNodeDefUuid": "da1069f1-02ea-4b03-a1a4-44ab8acacf2a"
            }
        },
        {
            "type": "scenarioNodeDefinitions",
            "id": "da1069f1-02ea-4b03-a1a4-44ab8acacf2a",
            "attributes": {
                "entry": true,
                "nodeType": "SEND",
                "channel": "EMAIL",
                "messageType": "TEST.MAIL"
            },
            "relationships": {
                "eventDefinitions": {
                    "data": [
                        {
                            "type": "scenarioEventDefinitions",
                            "id": "131dd584-4388-41f0-bf0c-9fca8bf16d7a"
                        },
                        {
                            "type": "scenarioEventDefinitions",
                            "id": "131dd584-4388-41f0-bf0c-9fca8bf16d8a"
                        }
                    ]
                }
            }
        },
        {
            "type": "scenarioNodeDefinitions",
            "id": "811e3162-f951-4b58-a753-fd0e00815b4a",
            "attributes": {
                "entry": false,
                "nodeType": "WAIT",
                "timeout": "5",
                "timeoutUnit": "MINUTES"
            },
            "relationships": {
                "eventDefinitions": {
                    "data": []
                }
            }
        }
    ]
}

Activate scenario definition version

Egy adott szcenárió verzió élesítése.

Web service API

Kérés

Név Típus Leírás
requestMeta RequestMeta_V1 A kérés metaadatai.
versionUuid String Az élesítendő verzió UUID-ja.

Válasz

Név Típus Leírás
status ResponseStatus_V1 A válasz státusza.
params Param_V1 [ ] Egyéb paraméterek listája.
versionData ScenarioDefVersion_V1 Az élesített verzió.

Minta

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
                  xmlns:scen="http://scenario.api.hammy.dbx.hu/">
    <soapenv:Header/>
    <soapenv:Body>
        <scen:activateScenarioDefVersion>
            <request>
                <requestMeta>
                    <clientHashKey>123</clientHashKey>
                    <userName></userName>
                </requestMeta>
                <versionUuid>aafcfd78-4c94-4e35-af9e-af7a54d844e8</versionUuid>
            </request>
        </scen:activateScenarioDefVersion>
    </soapenv:Body>
</soapenv:Envelope>
<S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/">
    <S:Body>
        <ns2:activateScenarioDefVersionResponse xmlns:ns2="http://scenario.api.hammy.dbx.hu/">
            <response>
                <status>
                    <code>0</code>
                    <messages/>
                </status>
                <versionData>
                    <nodeDefinitions>
                        <channel>SMS</channel>
                        <entry>true</entry>
                        <eventDefinitions>
                            <eventName>ENTITY_SENT</eventName>
                            <parentNodeDefUuid>da1069f1-02ea-4b03-a1a4-44ab8acacf28</parentNodeDefUuid>
                            <uuid>e90aff36-aa82-4068-a165-69a62e224572</uuid>
                        </eventDefinitions>

                        <messageType>TEST.SMS</messageType>
                        <nodeType>SEND</nodeType>
                        <uuid>da1069f1-02ea-4b03-a1a4-44ab8acacf28</uuid>
                    </nodeDefinitions>
                    <nodeDefinitions>
                        <entry>false</entry>
                        <nodeType>WAIT</nodeType>
                        <timeout>5</timeout>
                        <timeoutUnit>MINUTES</timeoutUnit>
                        <uuid>811e3162-f951-4b58-a753-fd0e00815b48</uuid>
                    </nodeDefinitions>
                    <nodeDefinitions>
                        <channel>EMAIL</channel>
                        <entry>false</entry>
                        <eventDefinitions>
                            <eventName>EMAIL_BOUNCED</eventName>
                            <parentNodeDefUuid>da1069f1-02ea-4b03-a1a4-44ab8acacf10</parentNodeDefUuid>
                            <uuid>131dd584-4388-41f0-bf0c-9fca8bf16d88</uuid>
                        </eventDefinitions>
                        <eventDefinitions>
                            <eventName>ENTITY_SENT</eventName>
                            <eventNodeDefUuid>811e3162-f951-4b58-a753-fd0e00815b48</eventNodeDefUuid>
                            <parentNodeDefUuid>da1069f1-02ea-4b03-a1a4-44ab8acacf10</parentNodeDefUuid>
                            <uuid>131dd584-4388-41f0-bf0c-9fca8bf16d78</uuid>
                        </eventDefinitions>
                        <messageType>TEST.MAIL</messageType>
                        <nodeType>SEND</nodeType>
                        <uuid>da1069f1-02ea-4b03-a1a4-44ab8acacf10</uuid>
                    </nodeDefinitions>
                    <status>ACTUAL</status>
                    <uuid>aafcfd78-4c94-4e35-af9e-af7a54d844e8</uuid>
                    <version>1</version>
                </versionData>
            </response>
        </ns2:activateScenarioDefVersionResponse>
    </S:Body>
</S:Envelope>

REST API

REST API Info

Kérés

POST hammy/json/scenario/v1/scenarioVersions/{{versionUuid}}/activate

Válasz

Típus Leírás
JScenarioDefVersion1 Az élesített verzió.

Minta

POST /hammy/json/scenario/v1/scenarioVersions/{versionUuid}/activate
Authorization: JWT {{jwtToken}}
X-Client-Hash-Key: {{clientHashKey}}
X-User-Name: {{userName}}
HTTP/1.1 200 OK
Content-Type: application/vnd.api+json

{
  "data": {
    "type": "scenarioVersions",
    "id": "aafcfd78-4c94-4e35-af9e-af7a54d844e8",
    "attributes": {
      "version": 1,
      "status": "ACTUAL"
    },
    "relationships": {
      "nodeDefinitions": {
        "data": [
          {
            "type": "scenarioNodeDefinitions",
            "id": "da1069f1-02ea-4b03-a1a4-44ab8acacf28"
          },
          {
            "type": "scenarioNodeDefinitions",
            "id": "811e3162-f951-4b58-a753-fd0e00815b48"
          },
          {
            "type": "scenarioNodeDefinitions",
            "id": "da1069f1-02ea-4b03-a1a4-44ab8acacf10"
          }
        ]
      }
    }
  },
  "included": [
    {
      "type": "scenarioNodeDefinitions",
      "id": "811e3162-f951-4b58-a753-fd0e00815b48",
      "attributes": {
        "entry": false,
        "nodeType": "WAIT",
        "timeout": 5,
        "timeoutUnit": "MINUTES"
      },
      "relationships": {
        "eventDefinitions": {
          "data": []
        }
      }
    },
    {
      "type": "scenarioNodeDefinitions",
      "id": "da1069f1-02ea-4b03-a1a4-44ab8acacf28",
      "attributes": {
        "entry": true,
        "nodeType": "SEND",
        "messageType": "TEST.SMS",
        "channel": "SMS"
      },
      "relationships": {
        "eventDefinitions": {
          "data": [
            {
              "type": "scenarioEventDefinitions",
              "id": "e90aff36-aa82-4068-a165-69a62e224572"
            },
            {
              "type": "scenarioEventDefinitions",
              "id": "131dd584-4388-41f0-bf0c-9fca8bf16d78"
            }
          ]
        }
      }
    },
    {
      "type": "scenarioEventDefinitions",
      "id": "131dd584-4388-41f0-bf0c-9fca8bf16d88",
      "attributes": {
        "eventName": "EMAIL_BOUNCED",
        "parentNodeDefUuid": "da1069f1-02ea-4b03-a1a4-44ab8acacf10"
      }
    },
    {
      "type": "scenarioEventDefinitions",
      "id": "131dd584-4388-41f0-bf0c-9fca8bf16d78",
      "attributes": {
        "eventName": "ENTITY_SENT",
        "eventNodeDefUuid": "811e3162-f951-4b58-a753-fd0e00815b48",
        "parentNodeDefUuid": "da1069f1-02ea-4b03-a1a4-44ab8acacf28"
      }
    },
    {
      "type": "scenarioEventDefinitions",
      "id": "e90aff36-aa82-4068-a165-69a62e224572",
      "attributes": {
        "eventName": "ENTITY_SENT",
        "parentNodeDefUuid": "da1069f1-02ea-4b03-a1a4-44ab8acacf28"
      }
    },
    {
      "type": "scenarioNodeDefinitions",
      "id": "da1069f1-02ea-4b03-a1a4-44ab8acacf10",
      "attributes": {
        "entry": false,
        "nodeType": "SEND",
        "messageType": "TEST.MAIL",
        "channel": "EMAIL"
      },
      "relationships": {
        "eventDefinitions": {
          "data": [
            {
              "type": "scenarioEventDefinitions",
              "id": "131dd584-4388-41f0-bf0c-9fca8bf16d88"
            }
          ]
        }
      }
    }
  ],
  "meta": {
    "params": [],
    "responseStatus": {
      "code": 0,
      "messages": []
    }
  }
}

Get scenario definition version stats

Szcenárió definíció verziójának statisztikája.

Web service API

Kérés

xml root: scenarioVersionStatsRequest

Név Típus Leírás
versionUuid String A verzió UUID-ja.
fromDate Date A keresési időszak alsó határa.
toDate Date A keresési időszak felső határa.

Válasz

Név Típus Leírás
status ResponseStatus_V1 A válasz státusza.
params Param_V1 [ ] Egyéb paraméterek listája.
scenarioVersionDefUuid String A verzió UUID-ja.
nodeStats ScenarioNodeStat_V1 [ ] A node-ok statisztikái.
eventStats ScenarioEventStat_V1 [ ] Az események statisztikái.

Minta


REST API

REST API Info

Kérés

GET hammy/json/scenario/v1/scenarioVersions/{{versionUuid}}/stats"

path

Név Típus Leírás
versionUuid String A verzió UUID-ja.
Paraméter Típus Leírás
requestMeta JRequestMeta_V1 A kérés metaadatai.
versionUuid String A verzió UUID-ja.
fromDate Date A keresési időszak alsó határa.
toDate Date A keresési időszak felső határa.

Válasz

Név Típus Leírás
meta JMeta1 Metaadatok.
scenarioVersionDefUuid String A verzió UUID-ja.
nodeStats ScenarioNodeStat_V1 [ ] A node-ok statisztikái.
eventStats ScenarioEventStat_V1 [ ] Az események statisztikái.

Minta


Show message scenario

Szcenárió keresése üzenet alapján.

REST API

Ez a szolgáltatás jelenleg csak REST API-n keresztül elérhető.

REST API

REST API Info

Kérés

GET hammy/json/scenario/v1/messages/{{messageUuid}}

path

Név Típus Leírás
messageUuid String Az üzenet UUID-ja.

Válasz

Típus Leírás
JScenario1 A megtalált szcenárió.

Minta

GET /hammy/json/scenario/v1/messages/{{messageUuid}}
Authorization: JWT {{jwtToken}}
X-Client-Hash-Key: {{clientHashKey}}
X-User-Name: {{userName}}

Query params:
-------------------------
messageUuid={{A szcenárióban fában érintett "akármelyik" message uuid-ra működik}}

GET /hammy/json/scenario/v1/messages/501d707e-8ec1-4cef-be07-61931afb230f
HTTP/1.1 200 OK
Content-Type: application/vnd.api+json

{
  "meta": {
    "responseStatus": {
      "code": 0,
      "messages": []
    },
    "params": []
  },
  "uuid": "f8eed551-04aa-4173-b331-3ac238c648d3",
  "scenarioDefVersionUuid": "8c5dab84-8474-4b08-8c08-a5233a93a713",
  "status": "COMPLETED",
  "createdAt": "2021-06-29T22:02:13.467+0200",
  "finishedAt": "2021-06-29T22:05:02.660+0200",
  "nodes": [
    {
      "uuid": "e4b3e584-dc7b-4cd5-be33-0df82cd660ae",
      "nodeDefUuid": "b6067f2e-2fba-4a27-b0d6-cacce9cbbf0e",
      "messageUuid": "da46a920-5b07-4215-b1a2-6acb45e9ea21",
      "status": "COMPLETED",
      "enteredAt": "2021-06-29T22:02:15.263+0200",
      "leftAt": "2021-06-29T22:05:01.118+0200",
      "timeout": "2021-06-29T22:04:15.265+0200",
      "scenarioEvents": [
        {
          "uuid": "7a27bdea-7a11-45e1-a4ef-9275b6a6be87",
          "scenarioEventDefUuid": "fa220f15-9948-4d9b-b5b1-5b29cf8f81d9"
        }
      ]
    },
    {
      "uuid": "040622ec-2e41-420d-9958-047fe156479e",
      "nodeDefUuid": "7ad303b2-fbbd-442a-9c09-de4910328387",
      "messageUuid": "4f057d0f-acc8-48c2-b45e-4f51fdc589ba",
      "status": "COMPLETED",
      "enteredAt": "2021-06-29T22:05:00.446+0200",
      "leftAt": "2021-06-29T22:05:02.457+0200",
      "scenarioEvents": [
        {
          "uuid": "af249983-3d11-46e7-89d9-800e0668f485",
          "scenarioEventDefUuid": "eb435da5-487b-414f-9785-12b068a38cf5"
        }
      ]
    },
    {
      "uuid": "ff36d74a-779f-4ed9-bdf7-a7224e24857b",
      "nodeDefUuid": "455b119e-3ee5-4cdf-8369-de78b8421581",
      "messageUuid": "4f057d0f-acc8-48c2-b45e-4f51fdc589ba",
      "status": "COMPLETED",
      "enteredAt": "2021-06-29T22:05:02.533+0200",
      "leftAt": "2021-06-29T22:05:02.660+0200",
      "scenarioEvents": [
        {
          "uuid": "64aaa72d-395e-412d-aaca-9d5289aaeaad",
          "scenarioEventDefUuid": "5b5bed39-08a7-4edb-a8d1-40204d5de9ae"
        }
      ]
    },
    {
      "uuid": "af3d629f-d5cb-4401-adf1-240f806ec7c2",
      "nodeDefUuid": "ff2922a2-4d5d-4fea-acfc-af4eaa3881cd",
      "messageUuid": "da46a920-5b07-4215-b1a2-6acb45e9ea21",
      "status": "COMPLETED",
      "enteredAt": "2021-06-29T22:02:13.537+0200",
      "leftAt": "2021-06-29T22:02:15.227+0200",
      "scenarioEvents": []
    }
  ]
}

Export scenario definition

Szcenárió definíció exportálása.

REST API

Ez a szolgáltatás jelenleg csak REST API-n keresztül elérhető.

REST API

REST API Info

Kérés

GET hammy/json/scenario/v1/scenarioDefinitions/{{definitionUuid}}/export

path

Név Típus Leírás
definitionUuid String A definíció UUID-ja.
Paraméter Típus Leírás
targetApiVersion Integer Cél API verzió.

Válasz

application/octet-stream

Név Típus Leírás
meta JMeta1 Metaadatok.
targetApiVersion Integer Cél API verzió.
scenarioDef JScenarioDefWithVersions1 Az exportált szcenárió definíció.
cgParamList CGParam_V1 [ ] Paraméterek listája.

Minta


Import scenario definition

Szcenárió definíció importálása.

REST API

Ez a szolgáltatás jelenleg csak REST API-n keresztül elérhető.

REST API

REST API Info

Kérés

PUT hammy/json/scenario/v1/scenarioDefinitions/import

multipart/form-data kérés.

Multipart név Tartalom Leírás
import_data application/octet-stream Az importálandó definíció tartalma.

Válasz

Név Típus Leírás
meta JMeta1 Metaadatok.

Minta