{
    "extension": {
        "name": "credit",
        "version": "0.1",
        "status": [
            "This extension is used internally by the broker and plugins. ",
            "It is NOT intended to be used by regular clients over the ",
            "network. This extension is subject to change without notice; ",
            "hence you are strongly discouraged from building clients ",
            "which use it."],
        "copyright": [
            "Copyright (C) 2008-2016 Pivotal Software, Inc, Inc.\n",
            "\n",
            "Permission is hereby granted, free of charge, to any person\n",
            "obtaining a copy of this file (the \"Software\"), to deal in the\n",
            "Software without restriction, including without limitation the \n",
            "rights to use, copy, modify, merge, publish, distribute, \n",
            "sublicense, and/or sell copies of the Software, and to permit \n",
            "persons to whom the Software is furnished to do so, subject to \n",
            "the following conditions:\n",
            "\n",
            "The above copyright notice and this permission notice shall be\n",
            "included in all copies or substantial portions of the Software.\n",
            "\n",
            "THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND,\n",
            "EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES\n",
            "OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND\n",
            "NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT\n",
            "HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,\n",
            "WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING\n",
            "FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR\n",
            "OTHER DEALINGS IN THE SOFTWARE.\n"]
    },

    "classes": [
        {
            "id": 60,
            "methods": [{"id": 200,
                         "arguments": [{"type": "shortstr", "name": "consumer-tag", "default-value": ""},
                                       {"type": "long", "name": "credit"},
                                       {"type": "bit", "name": "drain"}],
                         "name": "credit",
                         "synchronous" : true},
                        {"id": 201,
                         "arguments": [{"type": "long", "name": "available"}],
                         "name": "credit-ok"},
                        {"id": 202,
                         "arguments": [{"type": "shortstr", "name": "consumer-tag", "default-value": ""},
                                       {"type": "long", "name": "credit-drained"}],
                         "name": "credit-drained"}],
            "name": "basic"
        }
    ]
}
