The following examples shall be transformed to UML.
@startuml
title Weather API
actor "bob : User" as bob
participant "node0 : Webserver" as node0
participant ": WeatherAPI"
actor "alice : User" as alice
bob -> node0: getWeather(location='Augsburg')
node0 -> ": WeatherAPI" : getWeatherData(long=48.360455, lat=10.901283)
node0 <<-- ": WeatherAPI" : getWeatherData(validFor: 2000) : 'sunny'
bob <<-- node0: getWeather : 'sunny'
alice -> node0: getWeather(location='München')
alice <<-- node0: getWeather : 'sunny'
@enduml
@startuml
participant "key1 : Key"
participant "lock : Lock" as lock
key1 ->> lock: unlock()
lock -> key1 : getKey()
lock <<-- key1 : getKey: 'bew8n4ci2l4nvuy8'
lock -> lock: validateKey('bew8n4ci2l4nvuy8')
lock -->> lock: validateKey: true
lock ->> lock: open()
@enduml