Files
fin-tracker/app/packages/api_client/doc/CashflowApi.md
T
Dmitry 90ba198c2a chore(app): сгенерированный Dart-клиент из OpenAPI
openapi-generator-cli -g dart-dio. Генерируется, но коммитится: CI ловит дрейф
openapi/openapi.json, а приложение собирается без запуска генератора.
Пересобирается через just gen-client после любого изменения роутов.
2026-09-18 13:44:09 +03:00

142 lines
3.5 KiB
Markdown

# fintracker_api.api.CashflowApi
## Load the API package
```dart
import 'package:fintracker_api/api.dart';
```
All URIs are relative to *http://localhost*
Method | HTTP request | Description
------------- | ------------- | -------------
[**cashflowMonthly**](CashflowApi.md#cashflowmonthly) | **GET** /api/v1/cashflow/monthly | Monthly
[**cashflowRunway**](CashflowApi.md#cashflowrunway) | **GET** /api/v1/runway | Runway
[**cashflowSpending**](CashflowApi.md#cashflowspending) | **GET** /api/v1/spending/categories | Spending
# **cashflowMonthly**
> List<CashFlowMonth> cashflowMonthly(months)
Monthly
The last `months` months, oldest first.
### Example
```dart
import 'package:fintracker_api/api.dart';
final api = FintrackerApi().getCashflowApi();
final int months = 56; // int |
try {
final response = api.cashflowMonthly(months);
print(response);
} on DioException catch (e) {
print('Exception when calling CashflowApi->cashflowMonthly: $e\n');
}
```
### Parameters
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**months** | **int**| | [optional] [default to 12]
### Return type
[**List&lt;CashFlowMonth&gt;**](CashFlowMonth.md)
### Authorization
[HTTPBearer](../README.md#HTTPBearer)
### HTTP request headers
- **Content-Type**: Not defined
- **Accept**: application/json, application/problem+json
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
# **cashflowRunway**
> RunwayOut cashflowRunway()
Runway
How many months the liquid reserve covers; null before the first refresh.
### Example
```dart
import 'package:fintracker_api/api.dart';
final api = FintrackerApi().getCashflowApi();
try {
final response = api.cashflowRunway();
print(response);
} on DioException catch (e) {
print('Exception when calling CashflowApi->cashflowRunway: $e\n');
}
```
### Parameters
This endpoint does not need any parameter.
### Return type
[**RunwayOut**](RunwayOut.md)
### Authorization
[HTTPBearer](../README.md#HTTPBearer)
### HTTP request headers
- **Content-Type**: Not defined
- **Accept**: application/json, application/problem+json
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
# **cashflowSpending**
> List<SpendingRow> cashflowSpending(month)
Spending
Expenses of one month by category, largest first.
### Example
```dart
import 'package:fintracker_api/api.dart';
final api = FintrackerApi().getCashflowApi();
final String month = month_example; // String | YYYY-MM; defaults to the latest month
try {
final response = api.cashflowSpending(month);
print(response);
} on DioException catch (e) {
print('Exception when calling CashflowApi->cashflowSpending: $e\n');
}
```
### Parameters
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**month** | **String**| YYYY-MM; defaults to the latest month | [optional]
### Return type
[**List&lt;SpendingRow&gt;**](SpendingRow.md)
### Authorization
[HTTPBearer](../README.md#HTTPBearer)
### HTTP request headers
- **Content-Type**: Not defined
- **Accept**: application/json, application/problem+json
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)