ATTESTA API

Due to the asyncheronous nature of many ATTESTA communication features use of client-driven protocols, like commonly used HTTP calls, is not effective. The server side often needs to inform the client that some action should be taken. Most eveident cases are receiving communicatinos from other states or contract state changes. This is why this API uses farcall RPC over such channels as a plain TCP socket or websocket.

This way, every API call is a function call over RPC, that always takes a hash of names parameters as an argument (using FARCALL agreements), that could be empty, and always return hash of results, that could be empty, or null. In other words, no API call receives unnamed arguments and returns scalar values or arrays.

Documentation sample

API methods are defined in code blocks like:

 some_call( param_name: <type>[, optional_param: <type>] ) 
    -> { return_param_name1: default_value[, opional_return_param_name: <type> }