|
71 | 71 | ] |
72 | 72 | } |
73 | 73 | }, |
| 74 | + "/v1/accounts/credit/{id}": { |
| 75 | + "post": { |
| 76 | + "summary": "litcli: `accounts creditaccount`\nCreditAccount increases the balance of an existing account in the account\ndatabase.", |
| 77 | + "operationId": "Accounts_CreditAccount", |
| 78 | + "responses": { |
| 79 | + "200": { |
| 80 | + "description": "A successful response.", |
| 81 | + "schema": { |
| 82 | + "$ref": "#/definitions/litrpcAccount" |
| 83 | + } |
| 84 | + }, |
| 85 | + "default": { |
| 86 | + "description": "An unexpected error response.", |
| 87 | + "schema": { |
| 88 | + "$ref": "#/definitions/rpcStatus" |
| 89 | + } |
| 90 | + } |
| 91 | + }, |
| 92 | + "parameters": [ |
| 93 | + { |
| 94 | + "name": "id", |
| 95 | + "description": "The ID of the account to update. Either the ID or the label must be set.", |
| 96 | + "in": "path", |
| 97 | + "required": true, |
| 98 | + "type": "string" |
| 99 | + }, |
| 100 | + { |
| 101 | + "name": "body", |
| 102 | + "in": "body", |
| 103 | + "required": true, |
| 104 | + "schema": { |
| 105 | + "$ref": "#/definitions/AccountsCreditAccountBody" |
| 106 | + } |
| 107 | + } |
| 108 | + ], |
| 109 | + "tags": [ |
| 110 | + "Accounts" |
| 111 | + ] |
| 112 | + } |
| 113 | + }, |
| 114 | + "/v1/accounts/debit/{id}": { |
| 115 | + "post": { |
| 116 | + "summary": "litcli: `accounts debitaccount`\nDebitAccount decreases the balance of an existing account in the account\ndatabase.", |
| 117 | + "operationId": "Accounts_DebitAccount", |
| 118 | + "responses": { |
| 119 | + "200": { |
| 120 | + "description": "A successful response.", |
| 121 | + "schema": { |
| 122 | + "$ref": "#/definitions/litrpcAccount" |
| 123 | + } |
| 124 | + }, |
| 125 | + "default": { |
| 126 | + "description": "An unexpected error response.", |
| 127 | + "schema": { |
| 128 | + "$ref": "#/definitions/rpcStatus" |
| 129 | + } |
| 130 | + } |
| 131 | + }, |
| 132 | + "parameters": [ |
| 133 | + { |
| 134 | + "name": "id", |
| 135 | + "description": "The ID of the account to update. Either the ID or the label must be set.", |
| 136 | + "in": "path", |
| 137 | + "required": true, |
| 138 | + "type": "string" |
| 139 | + }, |
| 140 | + { |
| 141 | + "name": "body", |
| 142 | + "in": "body", |
| 143 | + "required": true, |
| 144 | + "schema": { |
| 145 | + "$ref": "#/definitions/AccountsDebitAccountBody" |
| 146 | + } |
| 147 | + } |
| 148 | + ], |
| 149 | + "tags": [ |
| 150 | + "Accounts" |
| 151 | + ] |
| 152 | + } |
| 153 | + }, |
74 | 154 | "/v1/accounts/{id}": { |
75 | 155 | "delete": { |
76 | 156 | "summary": "litcli: `accounts remove`\nRemoveAccount removes the given account from the account database.", |
|
150 | 230 | } |
151 | 231 | }, |
152 | 232 | "definitions": { |
| 233 | + "AccountsCreditAccountBody": { |
| 234 | + "type": "object", |
| 235 | + "properties": { |
| 236 | + "label": { |
| 237 | + "type": "string", |
| 238 | + "description": "The label of the account to update. If an account has no label, then the ID\nmust be used instead." |
| 239 | + }, |
| 240 | + "amount": { |
| 241 | + "type": "string", |
| 242 | + "format": "uint64", |
| 243 | + "description": "The amount by which the account's balance should be updated." |
| 244 | + } |
| 245 | + } |
| 246 | + }, |
| 247 | + "AccountsDebitAccountBody": { |
| 248 | + "type": "object", |
| 249 | + "properties": { |
| 250 | + "label": { |
| 251 | + "type": "string", |
| 252 | + "description": "The label of the account to update. If an account has no label, then the ID\nmust be used instead." |
| 253 | + }, |
| 254 | + "amount": { |
| 255 | + "type": "string", |
| 256 | + "format": "uint64", |
| 257 | + "description": "The amount by which the account's balance should be updated." |
| 258 | + } |
| 259 | + } |
| 260 | + }, |
153 | 261 | "AccountsUpdateAccountBody": { |
154 | 262 | "type": "object", |
155 | 263 | "properties": { |
|
0 commit comments