{% macro method_badge(method) %} {% if method.is_class_method %} CLASS METHOD {% else %} OBJECT METHOD {% endif %} {% endmacro %}

CMF RPC API

{% for class_name, class in rpc.items() %}

class TASK


{% for method_name, method in class.methods.items() %}

{{ method_badge(method) }} {{class_name}}.{{method_name}}

{{method._method.__doc__}}

Сигнатура:

{{ method.signature }}

Пример вызова:

curl -X POST -H "Content-Type: application/json" -d'{
    "jsonrpc": "2.0-fox",
    "access_token": null,
    "method": "{{class_name}}.{{method_name}}",
    "params": {% if method.is_class_method %}{}{% else %}{
        "id": 1
    }{% endif %},
    "fields": null,
    "callid": "{{ uuid4() }}"
}' {{ request.url }}
{% endfor %}
{% endfor %}