ynab 2.9.0 → 3.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +51 -43
- package/dist/apis/AccountsApi.d.ts +12 -12
- package/dist/apis/AccountsApi.js +38 -28
- package/dist/apis/CategoriesApi.d.ts +68 -25
- package/dist/apis/CategoriesApi.js +176 -46
- package/dist/apis/DeprecatedApi.js +17 -7
- package/dist/apis/MoneyMovementsApi.d.ts +67 -0
- package/dist/apis/MoneyMovementsApi.js +194 -0
- package/dist/apis/MonthsApi.d.ts +16 -16
- package/dist/apis/MonthsApi.js +38 -28
- package/dist/apis/PayeeLocationsApi.d.ts +12 -12
- package/dist/apis/PayeeLocationsApi.js +38 -28
- package/dist/apis/PayeesApi.d.ts +10 -10
- package/dist/apis/PayeesApi.js +36 -26
- package/dist/apis/PlansApi.d.ts +53 -0
- package/dist/apis/{BudgetsApi.js → PlansApi.js} +50 -40
- package/dist/apis/ScheduledTransactionsApi.d.ts +20 -20
- package/dist/apis/ScheduledTransactionsApi.js +52 -42
- package/dist/apis/TransactionsApi.d.ts +49 -49
- package/dist/apis/TransactionsApi.js +99 -89
- package/dist/apis/UserApi.d.ts +2 -2
- package/dist/apis/UserApi.js +19 -9
- package/dist/apis/index.d.ts +2 -1
- package/dist/apis/index.js +2 -1
- package/dist/browser/ynab.js +1 -1
- package/dist/esm/apis/AccountsApi.d.ts +12 -12
- package/dist/esm/apis/AccountsApi.js +23 -23
- package/dist/esm/apis/CategoriesApi.d.ts +68 -25
- package/dist/esm/apis/CategoriesApi.js +228 -42
- package/dist/esm/apis/DeprecatedApi.js +2 -2
- package/dist/esm/apis/MoneyMovementsApi.d.ts +67 -0
- package/dist/esm/apis/MoneyMovementsApi.js +302 -0
- package/dist/esm/apis/MonthsApi.d.ts +16 -16
- package/dist/esm/apis/MonthsApi.js +23 -23
- package/dist/esm/apis/PayeeLocationsApi.d.ts +12 -12
- package/dist/esm/apis/PayeeLocationsApi.js +23 -23
- package/dist/esm/apis/PayeesApi.d.ts +10 -10
- package/dist/esm/apis/PayeesApi.js +21 -21
- package/dist/esm/apis/PlansApi.d.ts +53 -0
- package/dist/esm/apis/{BudgetsApi.js → PlansApi.js} +38 -38
- package/dist/esm/apis/ScheduledTransactionsApi.d.ts +20 -20
- package/dist/esm/apis/ScheduledTransactionsApi.js +37 -37
- package/dist/esm/apis/TransactionsApi.d.ts +49 -49
- package/dist/esm/apis/TransactionsApi.js +84 -84
- package/dist/esm/apis/UserApi.d.ts +2 -2
- package/dist/esm/apis/UserApi.js +4 -4
- package/dist/esm/apis/index.d.ts +2 -1
- package/dist/esm/apis/index.js +2 -1
- package/dist/esm/index.d.ts +3 -3
- package/dist/esm/index.js +5 -5
- package/dist/esm/models/Account.d.ts +6 -6
- package/dist/esm/models/Category.d.ts +16 -4
- package/dist/esm/models/Category.js +4 -0
- package/dist/esm/models/CategoryGroupWithCategories.d.ts +1 -1
- package/dist/esm/models/CurrencyFormat.d.ts +1 -1
- package/dist/esm/models/DateFormat.d.ts +1 -1
- package/dist/esm/models/ExistingCategory.d.ts +51 -0
- package/dist/esm/models/ExistingCategory.js +45 -0
- package/dist/esm/models/ExistingTransaction.d.ts +4 -4
- package/dist/esm/models/HybridTransaction.d.ts +12 -12
- package/dist/esm/models/MoneyMovement.d.ts +75 -0
- package/dist/esm/models/MoneyMovement.js +57 -0
- package/dist/esm/models/MoneyMovementGroup.d.ts +51 -0
- package/dist/esm/models/MoneyMovementGroup.js +51 -0
- package/dist/esm/models/MoneyMovementGroupsResponse.d.ts +28 -0
- package/dist/esm/models/MoneyMovementGroupsResponse.js +40 -0
- package/dist/esm/models/MoneyMovementGroupsResponseData.d.ts +34 -0
- package/dist/esm/models/MoneyMovementGroupsResponseData.js +44 -0
- package/dist/esm/models/MoneyMovementsResponse.d.ts +28 -0
- package/dist/esm/models/{BudgetSettingsResponse.js → MoneyMovementsResponse.js} +11 -11
- package/dist/esm/models/MoneyMovementsResponseData.d.ts +34 -0
- package/dist/esm/models/MoneyMovementsResponseData.js +44 -0
- package/dist/esm/models/MonthDetail.d.ts +4 -4
- package/dist/esm/models/MonthSummary.d.ts +1 -1
- package/dist/esm/models/NewCategory.d.ts +51 -0
- package/dist/esm/models/NewCategory.js +45 -0
- package/dist/esm/models/NewTransaction.d.ts +4 -4
- package/dist/esm/models/PatchCategoryGroupWrapper.d.ts +28 -0
- package/dist/esm/models/PatchCategoryGroupWrapper.js +40 -0
- package/dist/esm/models/PatchCategoryWrapper.d.ts +3 -3
- package/dist/esm/models/PatchCategoryWrapper.js +3 -3
- package/dist/{models/BudgetDetail.d.ts → esm/models/PlanDetail.d.ts} +30 -30
- package/dist/esm/models/{BudgetDetail.js → PlanDetail.js} +8 -8
- package/dist/esm/models/PlanDetailResponse.d.ts +28 -0
- package/dist/esm/models/PlanDetailResponse.js +40 -0
- package/dist/esm/models/PlanDetailResponseData.d.ts +34 -0
- package/dist/esm/models/{BudgetDetailResponseData.js → PlanDetailResponseData.js} +11 -11
- package/dist/esm/models/PlanSettings.d.ts +35 -0
- package/dist/esm/models/{BudgetSettings.js → PlanSettings.js} +8 -8
- package/dist/esm/models/PlanSettingsResponse.d.ts +28 -0
- package/dist/esm/models/{BudgetDetailResponse.js → PlanSettingsResponse.js} +11 -11
- package/dist/esm/models/PlanSettingsResponseData.d.ts +28 -0
- package/dist/esm/models/PlanSettingsResponseData.js +40 -0
- package/dist/esm/models/PlanSummary.d.ts +72 -0
- package/dist/esm/models/{BudgetSummary.js → PlanSummary.js} +8 -8
- package/dist/esm/models/PlanSummaryResponse.d.ts +28 -0
- package/dist/esm/models/PlanSummaryResponse.js +40 -0
- package/dist/esm/models/PlanSummaryResponseData.d.ts +34 -0
- package/dist/esm/models/PlanSummaryResponseData.js +42 -0
- package/dist/esm/models/PostCategoryGroupWrapper.d.ts +28 -0
- package/dist/esm/models/PostCategoryGroupWrapper.js +40 -0
- package/dist/esm/models/PostCategoryWrapper.d.ts +28 -0
- package/dist/esm/models/PostCategoryWrapper.js +40 -0
- package/dist/esm/models/SaveCategory.d.ts +7 -1
- package/dist/esm/models/SaveCategory.js +2 -0
- package/dist/esm/models/SaveCategoryGroup.d.ts +27 -0
- package/dist/esm/models/SaveCategoryGroup.js +39 -0
- package/dist/esm/models/SaveCategoryGroupResponse.d.ts +28 -0
- package/dist/esm/models/SaveCategoryGroupResponse.js +40 -0
- package/dist/esm/models/SaveCategoryGroupResponseData.d.ts +34 -0
- package/dist/esm/models/SaveCategoryGroupResponseData.js +44 -0
- package/dist/esm/models/SaveMonthCategory.d.ts +1 -1
- package/dist/esm/models/SaveTransactionWithIdOrImportId.d.ts +4 -4
- package/dist/esm/models/ScheduledTransactionDetail.d.ts +6 -6
- package/dist/esm/models/ScheduledTransactionSummary.d.ts +1 -1
- package/dist/esm/models/TransactionDetail.d.ts +11 -11
- package/dist/esm/models/TransactionFlagColor.d.ts +1 -0
- package/dist/esm/models/TransactionFlagColor.js +2 -1
- package/dist/esm/models/TransactionResponseData.d.ts +6 -0
- package/dist/esm/models/TransactionResponseData.js +4 -0
- package/dist/esm/models/TransactionSummary.d.ts +1 -1
- package/dist/esm/models/index.d.ts +23 -9
- package/dist/esm/models/index.js +23 -9
- package/dist/esm/runtime.js +3 -3
- package/dist/index.d.ts +3 -3
- package/dist/index.js +22 -12
- package/dist/models/Account.d.ts +6 -6
- package/dist/models/Account.js +5 -6
- package/dist/models/AccountResponse.js +5 -6
- package/dist/models/AccountResponseData.js +5 -6
- package/dist/models/AccountType.js +6 -6
- package/dist/models/AccountsResponse.js +5 -6
- package/dist/models/AccountsResponseData.js +5 -6
- package/dist/models/BulkResponse.js +5 -6
- package/dist/models/BulkResponseData.js +5 -6
- package/dist/models/BulkResponseDataBulk.js +5 -6
- package/dist/models/BulkTransactions.js +5 -6
- package/dist/models/CategoriesResponse.js +5 -6
- package/dist/models/CategoriesResponseData.js +5 -6
- package/dist/models/Category.d.ts +16 -4
- package/dist/models/Category.js +10 -6
- package/dist/models/CategoryGoalType.js +4 -5
- package/dist/models/CategoryGroup.js +5 -6
- package/dist/models/CategoryGroupWithCategories.d.ts +1 -1
- package/dist/models/CategoryGroupWithCategories.js +5 -6
- package/dist/models/CategoryGroupWithCategoriesAllOf.js +4 -5
- package/dist/models/CategoryResponse.js +5 -6
- package/dist/models/CategoryResponseData.js +5 -6
- package/dist/models/CurrencyFormat.d.ts +1 -1
- package/dist/models/CurrencyFormat.js +5 -6
- package/dist/models/DateFormat.d.ts +1 -1
- package/dist/models/DateFormat.js +5 -6
- package/dist/models/ErrorDetail.js +5 -6
- package/dist/models/ErrorResponse.js +5 -6
- package/dist/models/ExistingCategory.d.ts +51 -0
- package/dist/models/ExistingCategory.js +51 -0
- package/dist/models/ExistingTransaction.d.ts +4 -4
- package/dist/models/ExistingTransaction.js +5 -6
- package/dist/models/HybridTransaction.d.ts +12 -12
- package/dist/models/HybridTransaction.js +6 -6
- package/dist/models/HybridTransactionAllOf.js +5 -5
- package/dist/models/HybridTransactionsResponse.js +5 -6
- package/dist/models/HybridTransactionsResponseData.js +5 -6
- package/dist/models/MoneyMovement.d.ts +75 -0
- package/dist/models/MoneyMovement.js +63 -0
- package/dist/models/MoneyMovementGroup.d.ts +51 -0
- package/dist/models/MoneyMovementGroup.js +57 -0
- package/dist/models/MoneyMovementGroupsResponse.d.ts +28 -0
- package/dist/models/MoneyMovementGroupsResponse.js +46 -0
- package/dist/models/MoneyMovementGroupsResponseData.d.ts +34 -0
- package/dist/models/MoneyMovementGroupsResponseData.js +50 -0
- package/dist/models/MoneyMovementsResponse.d.ts +28 -0
- package/dist/models/MoneyMovementsResponse.js +46 -0
- package/dist/models/MoneyMovementsResponseData.d.ts +34 -0
- package/dist/models/MoneyMovementsResponseData.js +50 -0
- package/dist/models/MonthDetail.d.ts +4 -4
- package/dist/models/MonthDetail.js +5 -6
- package/dist/models/MonthDetailAllOf.js +4 -5
- package/dist/models/MonthDetailResponse.js +5 -6
- package/dist/models/MonthDetailResponseData.js +5 -6
- package/dist/models/MonthSummariesResponse.js +5 -6
- package/dist/models/MonthSummariesResponseData.js +5 -6
- package/dist/models/MonthSummary.d.ts +1 -1
- package/dist/models/MonthSummary.js +5 -6
- package/dist/models/NewCategory.d.ts +51 -0
- package/dist/models/NewCategory.js +51 -0
- package/dist/models/NewTransaction.d.ts +4 -4
- package/dist/models/NewTransaction.js +5 -6
- package/dist/models/PatchCategoryGroupWrapper.d.ts +28 -0
- package/dist/models/PatchCategoryGroupWrapper.js +46 -0
- package/dist/models/PatchCategoryWrapper.d.ts +3 -3
- package/dist/models/PatchCategoryWrapper.js +8 -9
- package/dist/models/PatchMonthCategoryWrapper.js +5 -6
- package/dist/models/PatchPayeeWrapper.js +5 -6
- package/dist/models/PatchTransactionsWrapper.js +5 -6
- package/dist/models/Payee.js +5 -6
- package/dist/models/PayeeLocation.js +5 -6
- package/dist/models/PayeeLocationResponse.js +5 -6
- package/dist/models/PayeeLocationResponseData.js +5 -6
- package/dist/models/PayeeLocationsResponse.js +5 -6
- package/dist/models/PayeeLocationsResponseData.js +5 -6
- package/dist/models/PayeeResponse.js +5 -6
- package/dist/models/PayeeResponseData.js +5 -6
- package/dist/models/PayeesResponse.js +5 -6
- package/dist/models/PayeesResponseData.js +5 -6
- package/dist/{esm/models/BudgetDetail.d.ts → models/PlanDetail.d.ts} +30 -30
- package/dist/models/{BudgetDetail.js → PlanDetail.js} +13 -14
- package/dist/models/PlanDetailResponse.d.ts +28 -0
- package/dist/models/PlanDetailResponse.js +46 -0
- package/dist/models/PlanDetailResponseData.d.ts +34 -0
- package/dist/models/PlanDetailResponseData.js +50 -0
- package/dist/models/PlanSettings.d.ts +35 -0
- package/dist/models/{BudgetSettings.js → PlanSettings.js} +13 -14
- package/dist/models/PlanSettingsResponse.d.ts +28 -0
- package/dist/models/PlanSettingsResponse.js +46 -0
- package/dist/models/PlanSettingsResponseData.d.ts +28 -0
- package/dist/models/PlanSettingsResponseData.js +46 -0
- package/dist/models/PlanSummary.d.ts +72 -0
- package/dist/models/{BudgetSummary.js → PlanSummary.js} +13 -14
- package/dist/models/PlanSummaryResponse.d.ts +28 -0
- package/dist/models/PlanSummaryResponse.js +46 -0
- package/dist/models/PlanSummaryResponseData.d.ts +34 -0
- package/dist/models/PlanSummaryResponseData.js +48 -0
- package/dist/models/PostAccountWrapper.js +5 -6
- package/dist/models/PostCategoryGroupWrapper.d.ts +28 -0
- package/dist/models/PostCategoryGroupWrapper.js +46 -0
- package/dist/models/PostCategoryWrapper.d.ts +28 -0
- package/dist/models/PostCategoryWrapper.js +46 -0
- package/dist/models/PostScheduledTransactionWrapper.js +5 -6
- package/dist/models/PostTransactionsWrapper.js +5 -6
- package/dist/models/PutScheduledTransactionWrapper.js +5 -6
- package/dist/models/PutTransactionWrapper.js +5 -6
- package/dist/models/SaveAccount.js +5 -6
- package/dist/models/SaveCategory.d.ts +7 -1
- package/dist/models/SaveCategory.js +7 -6
- package/dist/models/SaveCategoryGroup.d.ts +27 -0
- package/dist/models/SaveCategoryGroup.js +45 -0
- package/dist/models/SaveCategoryGroupResponse.d.ts +28 -0
- package/dist/models/SaveCategoryGroupResponse.js +46 -0
- package/dist/models/SaveCategoryGroupResponseData.d.ts +34 -0
- package/dist/models/SaveCategoryGroupResponseData.js +50 -0
- package/dist/models/SaveCategoryResponse.js +5 -6
- package/dist/models/SaveCategoryResponseData.js +5 -6
- package/dist/models/SaveMonthCategory.d.ts +1 -1
- package/dist/models/SaveMonthCategory.js +5 -6
- package/dist/models/SavePayee.js +5 -6
- package/dist/models/SavePayeeResponse.js +5 -6
- package/dist/models/SavePayeeResponseData.js +5 -6
- package/dist/models/SaveScheduledTransaction.js +5 -6
- package/dist/models/SaveSubTransaction.js +5 -6
- package/dist/models/SaveTransaction.js +4 -5
- package/dist/models/SaveTransactionWithId.js +4 -5
- package/dist/models/SaveTransactionWithIdAllOf.js +4 -5
- package/dist/models/SaveTransactionWithIdOrImportId.d.ts +4 -4
- package/dist/models/SaveTransactionWithIdOrImportId.js +5 -6
- package/dist/models/SaveTransactionWithOptionalFields.js +5 -6
- package/dist/models/SaveTransactionWithOptionalFieldsFlagColor.js +4 -5
- package/dist/models/SaveTransactionsResponse.js +5 -6
- package/dist/models/SaveTransactionsResponseData.js +5 -6
- package/dist/models/ScheduledSubTransaction.js +5 -6
- package/dist/models/ScheduledTransactionDetail.d.ts +6 -6
- package/dist/models/ScheduledTransactionDetail.js +6 -6
- package/dist/models/ScheduledTransactionDetailAllOf.js +4 -5
- package/dist/models/ScheduledTransactionFrequency.js +6 -6
- package/dist/models/ScheduledTransactionResponse.js +5 -6
- package/dist/models/ScheduledTransactionResponseData.js +5 -6
- package/dist/models/ScheduledTransactionSummary.d.ts +1 -1
- package/dist/models/ScheduledTransactionSummary.js +6 -6
- package/dist/models/ScheduledTransactionSummaryFlagColor.js +4 -5
- package/dist/models/ScheduledTransactionsResponse.js +5 -6
- package/dist/models/ScheduledTransactionsResponseData.js +5 -6
- package/dist/models/SubTransaction.js +5 -6
- package/dist/models/TransactionClearedStatus.js +6 -6
- package/dist/models/TransactionDetail.d.ts +11 -11
- package/dist/models/TransactionDetail.js +6 -6
- package/dist/models/TransactionDetailAllOf.js +4 -5
- package/dist/models/TransactionFlagColor.d.ts +1 -0
- package/dist/models/TransactionFlagColor.js +8 -7
- package/dist/models/TransactionResponse.js +5 -6
- package/dist/models/TransactionResponseData.d.ts +6 -0
- package/dist/models/TransactionResponseData.js +9 -6
- package/dist/models/TransactionSummary.d.ts +1 -1
- package/dist/models/TransactionSummary.js +6 -6
- package/dist/models/TransactionSummaryDebtTransactionType.js +4 -5
- package/dist/models/TransactionsImportResponse.js +5 -6
- package/dist/models/TransactionsImportResponseData.js +5 -6
- package/dist/models/TransactionsResponse.js +5 -6
- package/dist/models/TransactionsResponseData.js +5 -6
- package/dist/models/User.js +5 -6
- package/dist/models/UserResponse.js +5 -6
- package/dist/models/UserResponseData.js +5 -6
- package/dist/models/index.d.ts +23 -9
- package/dist/models/index.js +23 -9
- package/dist/runtime.js +5 -5
- package/package.json +7 -8
- package/dist/apis/BudgetsApi.d.ts +0 -53
- package/dist/esm/apis/BudgetsApi.d.ts +0 -53
- package/dist/esm/models/BudgetDetailAllOf.d.ts +0 -95
- package/dist/esm/models/BudgetDetailAllOf.js +0 -71
- package/dist/esm/models/BudgetDetailResponse.d.ts +0 -28
- package/dist/esm/models/BudgetDetailResponseData.d.ts +0 -34
- package/dist/esm/models/BudgetSettings.d.ts +0 -35
- package/dist/esm/models/BudgetSettingsResponse.d.ts +0 -28
- package/dist/esm/models/BudgetSettingsResponseData.d.ts +0 -28
- package/dist/esm/models/BudgetSettingsResponseData.js +0 -40
- package/dist/esm/models/BudgetSummary.d.ts +0 -72
- package/dist/esm/models/BudgetSummaryResponse.d.ts +0 -28
- package/dist/esm/models/BudgetSummaryResponse.js +0 -40
- package/dist/esm/models/BudgetSummaryResponseData.d.ts +0 -34
- package/dist/esm/models/BudgetSummaryResponseData.js +0 -42
- package/dist/models/BudgetDetailAllOf.d.ts +0 -95
- package/dist/models/BudgetDetailAllOf.js +0 -78
- package/dist/models/BudgetDetailResponse.d.ts +0 -28
- package/dist/models/BudgetDetailResponse.js +0 -47
- package/dist/models/BudgetDetailResponseData.d.ts +0 -34
- package/dist/models/BudgetDetailResponseData.js +0 -51
- package/dist/models/BudgetSettings.d.ts +0 -35
- package/dist/models/BudgetSettingsResponse.d.ts +0 -28
- package/dist/models/BudgetSettingsResponse.js +0 -47
- package/dist/models/BudgetSettingsResponseData.d.ts +0 -28
- package/dist/models/BudgetSettingsResponseData.js +0 -47
- package/dist/models/BudgetSummary.d.ts +0 -72
- package/dist/models/BudgetSummaryResponse.d.ts +0 -28
- package/dist/models/BudgetSummaryResponse.js +0 -47
- package/dist/models/BudgetSummaryResponseData.d.ts +0 -34
- package/dist/models/BudgetSummaryResponseData.js +0 -49
package/README.md
CHANGED
|
@@ -59,7 +59,7 @@ Using the "latest" tag will result in a 302 redirect to the latest version tag s
|
|
|
59
59
|
## Usage
|
|
60
60
|
|
|
61
61
|
To use this client, you must
|
|
62
|
-
[obtain an access token](https://api.ynab.com/#authentication
|
|
62
|
+
[obtain an access token](https://api.ynab.com/#authentication) from
|
|
63
63
|
the [Account Settings](https://app.ynab.com/settings) area of the YNAB web
|
|
64
64
|
application.
|
|
65
65
|
|
|
@@ -69,10 +69,10 @@ const accessToken = "b43439eaafe2_this_is_fake_b43439eaafe2";
|
|
|
69
69
|
const ynabAPI = new ynab.API(accessToken);
|
|
70
70
|
|
|
71
71
|
(async function() {
|
|
72
|
-
const
|
|
73
|
-
const
|
|
74
|
-
for (let
|
|
75
|
-
console.log(`
|
|
72
|
+
const plansResponse = await ynabAPI.plans.getPlans();
|
|
73
|
+
const plans = plansResponse.data.budgets;
|
|
74
|
+
for (let plan of plans) {
|
|
75
|
+
console.log(`Plan Name: ${plan.name}`);
|
|
76
76
|
}
|
|
77
77
|
})();
|
|
78
78
|
```
|
|
@@ -87,9 +87,9 @@ const ynab = require("ynab");
|
|
|
87
87
|
const accessToken = "invalid_token";
|
|
88
88
|
const ynabAPI = new ynab.API(accessToken);
|
|
89
89
|
|
|
90
|
-
const
|
|
91
|
-
.
|
|
92
|
-
.then(
|
|
90
|
+
const plansResponse = ynabAPI.plans
|
|
91
|
+
.getPlans()
|
|
92
|
+
.then(plansResponse => {
|
|
93
93
|
// Won't get here because an error will be thrown
|
|
94
94
|
})
|
|
95
95
|
.catch(e => {
|
|
@@ -123,40 +123,48 @@ The following methods are available in this library.
|
|
|
123
123
|
| | Method | Description |
|
|
124
124
|
|----------------------------|----------------------------------------------------------------------------------------------------------------------------------------------------------------|-------------------------------------------------------|
|
|
125
125
|
| **User** | [user.getUser()](https://github.com/ynab/ynab-sdk-js/blob/main/dist/apis/UserApi.d.ts) | Returns authenticated user information |
|
|
126
|
-
| **
|
|
127
|
-
| | [
|
|
128
|
-
| | [
|
|
129
|
-
| **Accounts** | [accounts.getAccounts(
|
|
130
|
-
| | [accounts.getAccountById(
|
|
131
|
-
|
|
|
132
|
-
|
|
|
133
|
-
| | [categories.
|
|
134
|
-
| | [categories.
|
|
135
|
-
| | [categories.
|
|
136
|
-
|
|
|
137
|
-
| | [
|
|
138
|
-
|
|
|
139
|
-
| | [
|
|
140
|
-
|
|
|
141
|
-
|
|
|
142
|
-
| | [
|
|
143
|
-
| **
|
|
144
|
-
| | [
|
|
145
|
-
| | [
|
|
146
|
-
|
|
|
147
|
-
| | [
|
|
148
|
-
|
|
|
149
|
-
| | [
|
|
150
|
-
| | [
|
|
151
|
-
| | [
|
|
152
|
-
|
|
|
153
|
-
| | [transactions.
|
|
154
|
-
| | [transactions.
|
|
155
|
-
|
|
|
156
|
-
| | [
|
|
157
|
-
| | [
|
|
158
|
-
| | [
|
|
159
|
-
| | [
|
|
126
|
+
| **Plans** | [plans.getPlans()](https://github.com/ynab/ynab-sdk-js/blob/main/dist/apis/PlansApi.d.ts) | Returns plans list with summary information |
|
|
127
|
+
| | [plans.getPlanById(plan_id)](https://github.com/ynab/ynab-sdk-js/blob/main/dist/apis/PlansApi.d.ts) | Returns a single plan with all related entities |
|
|
128
|
+
| | [plans.getPlanSettingsById(plan_id)](https://github.com/ynab/ynab-sdk-js/blob/main/dist/apis/PlansApi.d.ts) | Returns settings for a plan |
|
|
129
|
+
| **Accounts** | [accounts.getAccounts(plan_id)](https://github.com/ynab/ynab-sdk-js/blob/main/dist/apis/AccountsApi.d.ts) | Returns all accounts |
|
|
130
|
+
| | [accounts.getAccountById(plan_id, account_id)](https://github.com/ynab/ynab-sdk-js/blob/main/dist/apis/AccountsApi.d.ts) | Returns a single account |
|
|
131
|
+
| | [accounts.createAccount(plan_id, data)](https://github.com/ynab/ynab-sdk-js/blob/main/dist/apis/AccountsApi.d.ts) | Creates a new account |
|
|
132
|
+
| **Categories** | [categories.getCategories(plan_id)](https://github.com/ynab/ynab-sdk-js/blob/main/dist/apis/CategoriesApi.d.ts) | Returns all categories grouped by category group. |
|
|
133
|
+
| | [categories.getCategoryById(plan_id, category_id)](https://github.com/ynab/ynab-sdk-js/blob/main/dist/apis/CategoriesApi.d.ts) | Returns a single category |
|
|
134
|
+
| | [categories.getMonthCategoryById(plan_id, month, category_id)](https://github.com/ynab/ynab-sdk-js/blob/main/dist/apis/CategoriesApi.d.ts) | Returns a single category for a specific plan month |
|
|
135
|
+
| | [categories.createCategory(plan_id, data)](https://github.com/ynab/ynab-sdk-js/blob/main/dist/apis/CategoriesApi.d.ts) | Creates a new category |
|
|
136
|
+
| | [categories.updateCategory(plan_id, category_id, category)](https://github.com/ynab/ynab-sdk-js/blob/main/dist/apis/CategoriesApi.d.ts) | Update a category |
|
|
137
|
+
| | [categories.updateMonthCategory(plan_id, month, category_id, month_category)](https://github.com/ynab/ynab-sdk-js/blob/main/dist/apis/CategoriesApi.d.ts) | Update a category for a specific month |
|
|
138
|
+
| | [categories.createCategoryGroup(plan_id, data)](https://github.com/ynab/ynab-sdk-js/blob/main/dist/apis/CategoriesApi.d.ts) | Creates a new category group |
|
|
139
|
+
| | [categories.updateCategoryGroup(plan_id, category_group_id, data)](https://github.com/ynab/ynab-sdk-js/blob/main/dist/apis/CategoriesApi.d.ts) | Update a category group |
|
|
140
|
+
| **Payees** | [payees.getPayees(plan_id)](https://github.com/ynab/ynab-sdk-js/blob/main/dist/apis/PayeesApi.d.ts) | Returns all payees |
|
|
141
|
+
| | [payees.getPayeeById(plan_id, payee_id)](https://github.com/ynab/ynab-sdk-js/blob/main/dist/apis/PayeesApi.d.ts) | Returns a single payee |
|
|
142
|
+
| | [payees.updatePayee(plan_id, payee_id, data)](https://github.com/ynab/ynab-sdk-js/blob/main/dist/apis/PayeesApi.d.ts) | Update a payee |
|
|
143
|
+
| **Payee Locations** | [payee_locations.getPayeeLocations(plan_id)](https://github.com/ynab/ynab-sdk-js/blob/main/dist/apis/PayeeLocationsApi.d.ts) | Returns all payee locations |
|
|
144
|
+
| | [payee_locations.getPayeeLocationById(plan_id, payee_location_id)](https://github.com/ynab/ynab-sdk-js/blob/main/dist/apis/PayeeLocationsApi.d.ts) | Returns a single payee location |
|
|
145
|
+
| | [payee_locations.getPayeeLocationsByPayee(plan_id, payee_id)](https://github.com/ynab/ynab-sdk-js/blob/main/dist/apis/PayeeLocationsApi.d.ts) | Returns all payee locations for the specified payee |
|
|
146
|
+
| **Months** | [months.getPlanMonths(plan_id)](https://github.com/ynab/ynab-sdk-js/blob/main/dist/apis/MonthsApi.d.ts) | Returns all plan months |
|
|
147
|
+
| | [months.getPlanMonth(plan_id, month)](https://github.com/ynab/ynab-sdk-js/blob/main/dist/apis/MonthsApi.d.ts) | Returns a single plan month |
|
|
148
|
+
| **Money Movements** | [money_movements.getMoneyMovements(plan_id)](https://github.com/ynab/ynab-sdk-js/blob/main/dist/apis/MoneyMovementsApi.d.ts) | Returns all money movements |
|
|
149
|
+
| | [money_movements.getMoneyMovementsByMonth(plan_id, month)](https://github.com/ynab/ynab-sdk-js/blob/main/dist/apis/MoneyMovementsApi.d.ts) | Returns all money movements for a specific month |
|
|
150
|
+
| | [money_movements.getMoneyMovementGroups(plan_id)](https://github.com/ynab/ynab-sdk-js/blob/main/dist/apis/MoneyMovementsApi.d.ts) | Returns all money movement groups |
|
|
151
|
+
| | [money_movements.getMoneyMovementGroupsByMonth(plan_id, month)](https://github.com/ynab/ynab-sdk-js/blob/main/dist/apis/MoneyMovementsApi.d.ts) | Returns all money movement groups for a specific month|
|
|
152
|
+
| **Transactions** | [transactions.getTransactions(plan_id)](https://github.com/ynab/ynab-sdk-js/blob/main/dist/apis/TransactionsApi.d.ts) | Returns plan transactions, excluding any pending |
|
|
153
|
+
| | [transactions.getTransactionsByAccount(plan_id, account_id)](https://github.com/ynab/ynab-sdk-js/blob/main/dist/apis/TransactionsApi.d.ts) | Returns all transactions for a specified account |
|
|
154
|
+
| | [transactions.getTransactionsByCategory(plan_id, category_id)](https://github.com/ynab/ynab-sdk-js/blob/main/dist/apis/TransactionsApi.d.ts) | Returns all transactions for a specified category |
|
|
155
|
+
| | [transactions.getTransactionsByPayee(plan_id, payee_id)](https://github.com/ynab/ynab-sdk-js/blob/main/dist/apis/TransactionsApi.d.ts) | Returns all transactions for a specified payee |
|
|
156
|
+
| | [transactions.getTransactionsByMonth(plan_id, month)](https://github.com/ynab/ynab-sdk-js/blob/main/dist/apis/TransactionsApi.d.ts) | Returns all transactions for a specified month |
|
|
157
|
+
| | [transactions.getTransactionById(plan_id, transaction_id)](https://github.com/ynab/ynab-sdk-js/blob/main/dist/apis/TransactionsApi.d.ts) | Returns a single transaction |
|
|
158
|
+
| | [transactions.createTransaction(plan_id, data)](https://github.com/ynab/ynab-sdk-js/blob/main/dist/apis/TransactionsApi.d.ts) | Creates a single transaction or multiple transactions |
|
|
159
|
+
| | [transactions.updateTransaction(plan_id, transaction_id, data)](https://github.com/ynab/ynab-sdk-js/blob/main/dist/apis/TransactionsApi.d.ts) | Updates a single transaction |
|
|
160
|
+
| | [transactions.updateTransactions(plan_id, data)](https://github.com/ynab/ynab-sdk-js/blob/main/dist/apis/TransactionsApi.d.ts) | Updates multiple transactions |
|
|
161
|
+
| | [transactions.deleteTransaction(plan_id, transaction_id)](https://github.com/ynab/ynab-sdk-js/blob/main/dist/apis/TransactionsApi.d.ts) | Deletes a transaction |
|
|
162
|
+
| | [transactions.importTransactions(plan_id)](https://github.com/ynab/ynab-sdk-js/blob/main/dist/apis/TransactionsApi.d.ts) | Imports transactions |
|
|
163
|
+
| **Scheduled Transactions** | [scheduled_transactions.getScheduledTransactions(plan_id)](https://github.com/ynab/ynab-sdk-js/blob/main/dist/apis/ScheduledTransactionsApi.d.ts) | Returns all scheduled transactions |
|
|
164
|
+
| | [scheduled_transactions.getScheduledTransactionById(plan_id, scheduled_transaction_id)](https://github.com/ynab/ynab-sdk-js/blob/main/dist/apis/ScheduledTransactionsApi.d.ts) | Returns a single scheduled transaction |
|
|
165
|
+
| | [scheduled_transactions.createScheduledTransaction(plan_id, data)](https://github.com/ynab/ynab-sdk-js/blob/main/dist/apis/ScheduledTransactionsApi.d.ts) | Creates a single scheduled transaction |
|
|
166
|
+
| | [scheduled_transactions.updateScheduledTransaction(plan_id, scheduled_transaction_id, data)](https://github.com/ynab/ynab-sdk-js/blob/main/dist/apis/ScheduledTransactionsApi.d.ts) | Updates a single scheduled transaction |
|
|
167
|
+
| | [scheduled_transactions.deleteScheduledTransaction(plan_id, scheduled_transaction_id)](https://github.com/ynab/ynab-sdk-js/blob/main/dist/apis/ScheduledTransactionsApi.d.ts) | Deletes a scheduled transaction |
|
|
160
168
|
|
|
161
169
|
### Utilities
|
|
162
170
|
|
|
@@ -181,6 +189,6 @@ The version of this client is defined in the `package.json` file and follows [se
|
|
|
181
189
|
|
|
182
190
|
## License
|
|
183
191
|
|
|
184
|
-
Copyright (c) 2022
|
|
192
|
+
Copyright (c) 2022 YNAB
|
|
185
193
|
|
|
186
194
|
Licensed under the Apache-2.0 license
|
|
@@ -7,15 +7,15 @@
|
|
|
7
7
|
import * as runtime from '../runtime';
|
|
8
8
|
import type { AccountResponse, AccountsResponse, PostAccountWrapper } from '../models/index';
|
|
9
9
|
export interface CreateAccountRequest {
|
|
10
|
-
|
|
10
|
+
planId: string;
|
|
11
11
|
data: PostAccountWrapper;
|
|
12
12
|
}
|
|
13
13
|
export interface GetAccountByIdRequest {
|
|
14
|
-
|
|
14
|
+
planId: string;
|
|
15
15
|
accountId: string;
|
|
16
16
|
}
|
|
17
17
|
export interface GetAccountsRequest {
|
|
18
|
-
|
|
18
|
+
planId: string;
|
|
19
19
|
lastKnowledgeOfServer?: number;
|
|
20
20
|
}
|
|
21
21
|
/**
|
|
@@ -24,32 +24,32 @@ export interface GetAccountsRequest {
|
|
|
24
24
|
export declare class AccountsApi extends runtime.BaseAPI {
|
|
25
25
|
/**
|
|
26
26
|
* Creates a new account
|
|
27
|
-
* Create
|
|
27
|
+
* Create an account
|
|
28
28
|
*/
|
|
29
29
|
createAccountRaw(requestParameters: CreateAccountRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<AccountResponse>>;
|
|
30
30
|
/**
|
|
31
31
|
* Creates a new account
|
|
32
|
-
* Create
|
|
32
|
+
* Create an account
|
|
33
33
|
*/
|
|
34
|
-
createAccount(
|
|
34
|
+
createAccount(planId: string, data: PostAccountWrapper, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<AccountResponse>;
|
|
35
35
|
/**
|
|
36
36
|
* Returns a single account
|
|
37
|
-
*
|
|
37
|
+
* Get an account
|
|
38
38
|
*/
|
|
39
39
|
getAccountByIdRaw(requestParameters: GetAccountByIdRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<AccountResponse>>;
|
|
40
40
|
/**
|
|
41
41
|
* Returns a single account
|
|
42
|
-
*
|
|
42
|
+
* Get an account
|
|
43
43
|
*/
|
|
44
|
-
getAccountById(
|
|
44
|
+
getAccountById(planId: string, accountId: string, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<AccountResponse>;
|
|
45
45
|
/**
|
|
46
46
|
* Returns all accounts
|
|
47
|
-
*
|
|
47
|
+
* Get all accounts
|
|
48
48
|
*/
|
|
49
49
|
getAccountsRaw(requestParameters: GetAccountsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<AccountsResponse>>;
|
|
50
50
|
/**
|
|
51
51
|
* Returns all accounts
|
|
52
|
-
*
|
|
52
|
+
* Get all accounts
|
|
53
53
|
*/
|
|
54
|
-
getAccounts(
|
|
54
|
+
getAccounts(planId: string, lastKnowledgeOfServer?: number, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<AccountsResponse>;
|
|
55
55
|
}
|
package/dist/apis/AccountsApi.js
CHANGED
|
@@ -23,13 +23,23 @@ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (
|
|
|
23
23
|
}) : function(o, v) {
|
|
24
24
|
o["default"] = v;
|
|
25
25
|
});
|
|
26
|
-
var __importStar = (this && this.__importStar) || function (
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
};
|
|
26
|
+
var __importStar = (this && this.__importStar) || (function () {
|
|
27
|
+
var ownKeys = function(o) {
|
|
28
|
+
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
29
|
+
var ar = [];
|
|
30
|
+
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
31
|
+
return ar;
|
|
32
|
+
};
|
|
33
|
+
return ownKeys(o);
|
|
34
|
+
};
|
|
35
|
+
return function (mod) {
|
|
36
|
+
if (mod && mod.__esModule) return mod;
|
|
37
|
+
var result = {};
|
|
38
|
+
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
39
|
+
__setModuleDefault(result, mod);
|
|
40
|
+
return result;
|
|
41
|
+
};
|
|
42
|
+
})();
|
|
33
43
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
34
44
|
exports.AccountsApi = void 0;
|
|
35
45
|
const runtime = __importStar(require("../runtime"));
|
|
@@ -40,11 +50,11 @@ const index_1 = require("../models/index");
|
|
|
40
50
|
class AccountsApi extends runtime.BaseAPI {
|
|
41
51
|
/**
|
|
42
52
|
* Creates a new account
|
|
43
|
-
* Create
|
|
53
|
+
* Create an account
|
|
44
54
|
*/
|
|
45
55
|
async createAccountRaw(requestParameters, initOverrides) {
|
|
46
|
-
if (requestParameters.
|
|
47
|
-
throw new runtime.RequiredError('
|
|
56
|
+
if (requestParameters.planId === null || requestParameters.planId === undefined) {
|
|
57
|
+
throw new runtime.RequiredError('planId', 'Required parameter requestParameters.planId was null or undefined when calling createAccount.');
|
|
48
58
|
}
|
|
49
59
|
if (requestParameters.data === null || requestParameters.data === undefined) {
|
|
50
60
|
throw new runtime.RequiredError('data', 'Required parameter requestParameters.data was null or undefined when calling createAccount.');
|
|
@@ -61,7 +71,7 @@ class AccountsApi extends runtime.BaseAPI {
|
|
|
61
71
|
}
|
|
62
72
|
}
|
|
63
73
|
const response = await this.request({
|
|
64
|
-
path: `/budgets/{
|
|
74
|
+
path: `/budgets/{plan_id}/accounts`.replace(`{${"plan_id"}}`, encodeURIComponent(String(requestParameters.planId))),
|
|
65
75
|
method: 'POST',
|
|
66
76
|
headers: headerParameters,
|
|
67
77
|
query: queryParameters,
|
|
@@ -71,19 +81,19 @@ class AccountsApi extends runtime.BaseAPI {
|
|
|
71
81
|
}
|
|
72
82
|
/**
|
|
73
83
|
* Creates a new account
|
|
74
|
-
* Create
|
|
84
|
+
* Create an account
|
|
75
85
|
*/
|
|
76
|
-
async createAccount(
|
|
77
|
-
const response = await this.createAccountRaw({
|
|
86
|
+
async createAccount(planId, data, initOverrides) {
|
|
87
|
+
const response = await this.createAccountRaw({ planId: planId, data: data }, initOverrides);
|
|
78
88
|
return await response.value();
|
|
79
89
|
}
|
|
80
90
|
/**
|
|
81
91
|
* Returns a single account
|
|
82
|
-
*
|
|
92
|
+
* Get an account
|
|
83
93
|
*/
|
|
84
94
|
async getAccountByIdRaw(requestParameters, initOverrides) {
|
|
85
|
-
if (requestParameters.
|
|
86
|
-
throw new runtime.RequiredError('
|
|
95
|
+
if (requestParameters.planId === null || requestParameters.planId === undefined) {
|
|
96
|
+
throw new runtime.RequiredError('planId', 'Required parameter requestParameters.planId was null or undefined when calling getAccountById.');
|
|
87
97
|
}
|
|
88
98
|
if (requestParameters.accountId === null || requestParameters.accountId === undefined) {
|
|
89
99
|
throw new runtime.RequiredError('accountId', 'Required parameter requestParameters.accountId was null or undefined when calling getAccountById.');
|
|
@@ -99,7 +109,7 @@ class AccountsApi extends runtime.BaseAPI {
|
|
|
99
109
|
}
|
|
100
110
|
}
|
|
101
111
|
const response = await this.request({
|
|
102
|
-
path: `/budgets/{
|
|
112
|
+
path: `/budgets/{plan_id}/accounts/{account_id}`.replace(`{${"plan_id"}}`, encodeURIComponent(String(requestParameters.planId))).replace(`{${"account_id"}}`, encodeURIComponent(String(requestParameters.accountId))),
|
|
103
113
|
method: 'GET',
|
|
104
114
|
headers: headerParameters,
|
|
105
115
|
query: queryParameters,
|
|
@@ -108,19 +118,19 @@ class AccountsApi extends runtime.BaseAPI {
|
|
|
108
118
|
}
|
|
109
119
|
/**
|
|
110
120
|
* Returns a single account
|
|
111
|
-
*
|
|
121
|
+
* Get an account
|
|
112
122
|
*/
|
|
113
|
-
async getAccountById(
|
|
114
|
-
const response = await this.getAccountByIdRaw({
|
|
123
|
+
async getAccountById(planId, accountId, initOverrides) {
|
|
124
|
+
const response = await this.getAccountByIdRaw({ planId: planId, accountId: accountId }, initOverrides);
|
|
115
125
|
return await response.value();
|
|
116
126
|
}
|
|
117
127
|
/**
|
|
118
128
|
* Returns all accounts
|
|
119
|
-
*
|
|
129
|
+
* Get all accounts
|
|
120
130
|
*/
|
|
121
131
|
async getAccountsRaw(requestParameters, initOverrides) {
|
|
122
|
-
if (requestParameters.
|
|
123
|
-
throw new runtime.RequiredError('
|
|
132
|
+
if (requestParameters.planId === null || requestParameters.planId === undefined) {
|
|
133
|
+
throw new runtime.RequiredError('planId', 'Required parameter requestParameters.planId was null or undefined when calling getAccounts.');
|
|
124
134
|
}
|
|
125
135
|
const queryParameters = {};
|
|
126
136
|
if (requestParameters.lastKnowledgeOfServer !== undefined) {
|
|
@@ -136,7 +146,7 @@ class AccountsApi extends runtime.BaseAPI {
|
|
|
136
146
|
}
|
|
137
147
|
}
|
|
138
148
|
const response = await this.request({
|
|
139
|
-
path: `/budgets/{
|
|
149
|
+
path: `/budgets/{plan_id}/accounts`.replace(`{${"plan_id"}}`, encodeURIComponent(String(requestParameters.planId))),
|
|
140
150
|
method: 'GET',
|
|
141
151
|
headers: headerParameters,
|
|
142
152
|
query: queryParameters,
|
|
@@ -145,10 +155,10 @@ class AccountsApi extends runtime.BaseAPI {
|
|
|
145
155
|
}
|
|
146
156
|
/**
|
|
147
157
|
* Returns all accounts
|
|
148
|
-
*
|
|
158
|
+
* Get all accounts
|
|
149
159
|
*/
|
|
150
|
-
async getAccounts(
|
|
151
|
-
const response = await this.getAccountsRaw({
|
|
160
|
+
async getAccounts(planId, lastKnowledgeOfServer, initOverrides) {
|
|
161
|
+
const response = await this.getAccountsRaw({ planId: planId, lastKnowledgeOfServer: lastKnowledgeOfServer }, initOverrides);
|
|
152
162
|
return await response.value();
|
|
153
163
|
}
|
|
154
164
|
}
|
|
@@ -5,27 +5,40 @@
|
|
|
5
5
|
* Generated by: OpenAPI Generator (https://openapi-generator.tech)
|
|
6
6
|
*/
|
|
7
7
|
import * as runtime from '../runtime';
|
|
8
|
-
import type { CategoriesResponse, CategoryResponse, PatchCategoryWrapper, PatchMonthCategoryWrapper, SaveCategoryResponse } from '../models/index';
|
|
8
|
+
import type { CategoriesResponse, CategoryResponse, PatchCategoryGroupWrapper, PatchCategoryWrapper, PatchMonthCategoryWrapper, PostCategoryGroupWrapper, PostCategoryWrapper, SaveCategoryGroupResponse, SaveCategoryResponse } from '../models/index';
|
|
9
|
+
export interface CreateCategoryRequest {
|
|
10
|
+
planId: string;
|
|
11
|
+
data: PostCategoryWrapper;
|
|
12
|
+
}
|
|
13
|
+
export interface CreateCategoryGroupRequest {
|
|
14
|
+
planId: string;
|
|
15
|
+
data: PostCategoryGroupWrapper;
|
|
16
|
+
}
|
|
9
17
|
export interface GetCategoriesRequest {
|
|
10
|
-
|
|
18
|
+
planId: string;
|
|
11
19
|
lastKnowledgeOfServer?: number;
|
|
12
20
|
}
|
|
13
21
|
export interface GetCategoryByIdRequest {
|
|
14
|
-
|
|
22
|
+
planId: string;
|
|
15
23
|
categoryId: string;
|
|
16
24
|
}
|
|
17
25
|
export interface GetMonthCategoryByIdRequest {
|
|
18
|
-
|
|
26
|
+
planId: string;
|
|
19
27
|
month: string;
|
|
20
28
|
categoryId: string;
|
|
21
29
|
}
|
|
22
30
|
export interface UpdateCategoryRequest {
|
|
23
|
-
|
|
31
|
+
planId: string;
|
|
24
32
|
categoryId: string;
|
|
25
33
|
data: PatchCategoryWrapper;
|
|
26
34
|
}
|
|
35
|
+
export interface UpdateCategoryGroupRequest {
|
|
36
|
+
planId: string;
|
|
37
|
+
categoryGroupId: string;
|
|
38
|
+
data: PatchCategoryGroupWrapper;
|
|
39
|
+
}
|
|
27
40
|
export interface UpdateMonthCategoryRequest {
|
|
28
|
-
|
|
41
|
+
planId: string;
|
|
29
42
|
month: string;
|
|
30
43
|
categoryId: string;
|
|
31
44
|
data: PatchMonthCategoryWrapper;
|
|
@@ -35,35 +48,55 @@ export interface UpdateMonthCategoryRequest {
|
|
|
35
48
|
*/
|
|
36
49
|
export declare class CategoriesApi extends runtime.BaseAPI {
|
|
37
50
|
/**
|
|
38
|
-
*
|
|
39
|
-
*
|
|
51
|
+
* Creates a new category
|
|
52
|
+
* Create a category
|
|
53
|
+
*/
|
|
54
|
+
createCategoryRaw(requestParameters: CreateCategoryRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<SaveCategoryResponse>>;
|
|
55
|
+
/**
|
|
56
|
+
* Creates a new category
|
|
57
|
+
* Create a category
|
|
58
|
+
*/
|
|
59
|
+
createCategory(planId: string, data: PostCategoryWrapper, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<SaveCategoryResponse>;
|
|
60
|
+
/**
|
|
61
|
+
* Creates a new category group
|
|
62
|
+
* Create a category group
|
|
63
|
+
*/
|
|
64
|
+
createCategoryGroupRaw(requestParameters: CreateCategoryGroupRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<SaveCategoryGroupResponse>>;
|
|
65
|
+
/**
|
|
66
|
+
* Creates a new category group
|
|
67
|
+
* Create a category group
|
|
68
|
+
*/
|
|
69
|
+
createCategoryGroup(planId: string, data: PostCategoryGroupWrapper, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<SaveCategoryGroupResponse>;
|
|
70
|
+
/**
|
|
71
|
+
* Returns all categories grouped by category group. Amounts (assigned, activity, available, etc.) are specific to the current plan month (UTC).
|
|
72
|
+
* Get all categories
|
|
40
73
|
*/
|
|
41
74
|
getCategoriesRaw(requestParameters: GetCategoriesRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<CategoriesResponse>>;
|
|
42
75
|
/**
|
|
43
|
-
* Returns all categories grouped by category group. Amounts (
|
|
44
|
-
*
|
|
76
|
+
* Returns all categories grouped by category group. Amounts (assigned, activity, available, etc.) are specific to the current plan month (UTC).
|
|
77
|
+
* Get all categories
|
|
45
78
|
*/
|
|
46
|
-
getCategories(
|
|
79
|
+
getCategories(planId: string, lastKnowledgeOfServer?: number, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<CategoriesResponse>;
|
|
47
80
|
/**
|
|
48
|
-
* Returns a single category. Amounts (
|
|
49
|
-
*
|
|
81
|
+
* Returns a single category. Amounts (assigned, activity, available, etc.) are specific to the current plan month (UTC).
|
|
82
|
+
* Get a category
|
|
50
83
|
*/
|
|
51
84
|
getCategoryByIdRaw(requestParameters: GetCategoryByIdRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<CategoryResponse>>;
|
|
52
85
|
/**
|
|
53
|
-
* Returns a single category. Amounts (
|
|
54
|
-
*
|
|
86
|
+
* Returns a single category. Amounts (assigned, activity, available, etc.) are specific to the current plan month (UTC).
|
|
87
|
+
* Get a category
|
|
55
88
|
*/
|
|
56
|
-
getCategoryById(
|
|
89
|
+
getCategoryById(planId: string, categoryId: string, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<CategoryResponse>;
|
|
57
90
|
/**
|
|
58
|
-
* Returns a single category for a specific
|
|
59
|
-
*
|
|
91
|
+
* Returns a single category for a specific plan month. Amounts (assigned, activity, available, etc.) are specific to the current plan month (UTC).
|
|
92
|
+
* Get a category for a specific plan month
|
|
60
93
|
*/
|
|
61
94
|
getMonthCategoryByIdRaw(requestParameters: GetMonthCategoryByIdRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<CategoryResponse>>;
|
|
62
95
|
/**
|
|
63
|
-
* Returns a single category for a specific
|
|
64
|
-
*
|
|
96
|
+
* Returns a single category for a specific plan month. Amounts (assigned, activity, available, etc.) are specific to the current plan month (UTC).
|
|
97
|
+
* Get a category for a specific plan month
|
|
65
98
|
*/
|
|
66
|
-
getMonthCategoryById(
|
|
99
|
+
getMonthCategoryById(planId: string, month: string, categoryId: string, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<CategoryResponse>;
|
|
67
100
|
/**
|
|
68
101
|
* Update a category
|
|
69
102
|
* Update a category
|
|
@@ -73,15 +106,25 @@ export declare class CategoriesApi extends runtime.BaseAPI {
|
|
|
73
106
|
* Update a category
|
|
74
107
|
* Update a category
|
|
75
108
|
*/
|
|
76
|
-
updateCategory(
|
|
109
|
+
updateCategory(planId: string, categoryId: string, data: PatchCategoryWrapper, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<SaveCategoryResponse>;
|
|
110
|
+
/**
|
|
111
|
+
* Update a category group
|
|
112
|
+
* Update a category group
|
|
113
|
+
*/
|
|
114
|
+
updateCategoryGroupRaw(requestParameters: UpdateCategoryGroupRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<SaveCategoryGroupResponse>>;
|
|
115
|
+
/**
|
|
116
|
+
* Update a category group
|
|
117
|
+
* Update a category group
|
|
118
|
+
*/
|
|
119
|
+
updateCategoryGroup(planId: string, categoryGroupId: string, data: PatchCategoryGroupWrapper, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<SaveCategoryGroupResponse>;
|
|
77
120
|
/**
|
|
78
|
-
* Update a category for a specific month. Only `budgeted` amount can be updated.
|
|
121
|
+
* Update a category for a specific month. Only `budgeted` (assigned) amount can be updated.
|
|
79
122
|
* Update a category for a specific month
|
|
80
123
|
*/
|
|
81
124
|
updateMonthCategoryRaw(requestParameters: UpdateMonthCategoryRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<SaveCategoryResponse>>;
|
|
82
125
|
/**
|
|
83
|
-
* Update a category for a specific month. Only `budgeted` amount can be updated.
|
|
126
|
+
* Update a category for a specific month. Only `budgeted` (assigned) amount can be updated.
|
|
84
127
|
* Update a category for a specific month
|
|
85
128
|
*/
|
|
86
|
-
updateMonthCategory(
|
|
129
|
+
updateMonthCategory(planId: string, month: string, categoryId: string, data: PatchMonthCategoryWrapper, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<SaveCategoryResponse>;
|
|
87
130
|
}
|