Fork me on GitHub

Template helloworldstate@0.8.0

Clause Ergo ^0.9.1 b7fafd957988d8b1ecb4ab7f64703f6a2873e1cc30a41a23f8e66eef737f4929

This is the stateful Hello World of Accord Protocol Templates. Executing the clause will simply echo back the text that occurs after the string `Hello` prepended to text that is passed in the request along with the number of times the clause has been called.

Download Archive Open in Template Studio

Hello World State

This is the stateful Hello World of Accord Protocol Templates. Executing the clause will simply echo back the text that occurs after the string Hello prepended to text that is passed in the request along with the number of times the clause has been called.

Sample

Name of the person to greet: "Fred Blogs".
Thank you!
                

Model Dependencies

Technical Integration

Please refer to the Cicero documentation for details and examples of how to integrate a call to a Cicero template into your application.

View the Latest code for this template on on GitHub.

Sample Instance

{
    "$class": "org.accordproject.helloworldstate.HelloWorldClause",
    "clauseId": "844e59d0-3bc0-4af8-9e78-01bbf8c5d87f",
    "name": "Fred Blogs"
}

State Types

Type Sample JSON
org.accordproject.helloworldstate.HelloWorldState
{
    "$class": "org.accordproject.helloworldstate.HelloWorldState",
    "counter": 6.95,
    "stateId": "5e2e4951-dd3f-11e8-a95c-95b9dbcf241c"
}

Request Types

Type Sample JSON
org.accordproject.cicero.runtime.Request
{
    "$class": "org.accordproject.cicero.runtime.Request",
    "transactionId": "5e2e2240-dd3f-11e8-a95c-95b9dbcf241c",
    "timestamp": "2018-10-31T19:01:26.756Z"
}
org.accordproject.helloworldstate.MyRequest
{
    "$class": "org.accordproject.helloworldstate.MyRequest",
    "input": "Irure duis ipsum.",
    "transactionId": "5e2e2241-dd3f-11e8-a95c-95b9dbcf241c",
    "timestamp": "2018-10-31T19:01:26.756Z"
}

Response Types

Type Sample JSON
org.accordproject.cicero.runtime.Response
{
    "$class": "org.accordproject.cicero.runtime.Response",
    "transactionId": "5e2e2242-dd3f-11e8-a95c-95b9dbcf241c",
    "timestamp": "2018-10-31T19:01:26.756Z"
}
org.accordproject.helloworldstate.MyResponse
{
    "$class": "org.accordproject.helloworldstate.MyResponse",
    "output": "Eiusmod cillum dolore minim.",
    "transactionId": "5e2e2243-dd3f-11e8-a95c-95b9dbcf241c",
    "timestamp": "2018-10-31T19:01:26.756Z"
}

Events Types

Type Sample JSON
org.accordproject.base.Event
{
    "abstract": "this is an abstract type"
}