Skip to content

Commit

Permalink
Merge pull request #80 from ynab/gen-1.71.0
Browse files Browse the repository at this point in the history
Generate latest from spec version 1.72.0
  • Loading branch information
bradymholt committed Jul 11, 2024
2 parents eb47e1b + c23e84f commit 11045f0
Show file tree
Hide file tree
Showing 32 changed files with 1,192 additions and 24 deletions.
6 changes: 6 additions & 0 deletions .openapi-generator/FILES
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,7 @@ docs/PayeesApi.md
docs/PayeesResponse.md
docs/PayeesResponseData.md
docs/PostAccountWrapper.md
docs/PostScheduledTransactionWrapper.md
docs/PostTransactionsWrapper.md
docs/PutTransactionWrapper.md
docs/SaveAccount.md
Expand All @@ -72,13 +73,15 @@ docs/SaveMonthCategory.md
docs/SavePayee.md
docs/SavePayeeResponse.md
docs/SavePayeeResponseData.md
docs/SaveScheduledTransaction.md
docs/SaveSubTransaction.md
docs/SaveTransactionWithIdOrImportId.md
docs/SaveTransactionWithOptionalFields.md
docs/SaveTransactionsResponse.md
docs/SaveTransactionsResponseData.md
docs/ScheduledSubTransaction.md
docs/ScheduledTransactionDetail.md
docs/ScheduledTransactionFrequency.md
docs/ScheduledTransactionResponse.md
docs/ScheduledTransactionResponseData.md
docs/ScheduledTransactionSummary.md
Expand Down Expand Up @@ -169,6 +172,7 @@ lib/ynab/models/payee_response_data.rb
lib/ynab/models/payees_response.rb
lib/ynab/models/payees_response_data.rb
lib/ynab/models/post_account_wrapper.rb
lib/ynab/models/post_scheduled_transaction_wrapper.rb
lib/ynab/models/post_transactions_wrapper.rb
lib/ynab/models/put_transaction_wrapper.rb
lib/ynab/models/save_account.rb
Expand All @@ -179,13 +183,15 @@ lib/ynab/models/save_month_category.rb
lib/ynab/models/save_payee.rb
lib/ynab/models/save_payee_response.rb
lib/ynab/models/save_payee_response_data.rb
lib/ynab/models/save_scheduled_transaction.rb
lib/ynab/models/save_sub_transaction.rb
lib/ynab/models/save_transaction_with_id_or_import_id.rb
lib/ynab/models/save_transaction_with_optional_fields.rb
lib/ynab/models/save_transactions_response.rb
lib/ynab/models/save_transactions_response_data.rb
lib/ynab/models/scheduled_sub_transaction.rb
lib/ynab/models/scheduled_transaction_detail.rb
lib/ynab/models/scheduled_transaction_frequency.rb
lib/ynab/models/scheduled_transaction_response.rb
lib/ynab/models/scheduled_transaction_response_data.rb
lib/ynab/models/scheduled_transaction_summary.rb
Expand Down
2 changes: 1 addition & 1 deletion .openapi-generator/VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
7.6.0
7.7.0
2 changes: 1 addition & 1 deletion Gemfile.lock
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
PATH
remote: .
specs:
ynab (3.1.0)
ynab (3.2.0)
typhoeus (~> 1.0, >= 1.0.1)

GEM
Expand Down
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,7 @@ The following methods are available in this library.
| **Transactions** | [transactions.get_transactions(budget_id)](https://github.com/ynab/ynab-sdk-ruby/blob/master/docs/TransactionsApi.md#get_transactions) | Returns budget transactions |
| | [transactions.get_transactions_by_account(budget_id, account_id)](https://github.com/ynab/ynab-sdk-ruby/blob/master/docs/TransactionsApi.md#get_transactions_by_account) | Returns all transactions for a specified account |
| | [transactions.get_transactions_by_category(budget_id, category_id)](https://github.com/ynab/ynab-sdk-ruby/blob/master/docs/TransactionsApi.md#get_transactions_by_category) | Returns all transactions for a specified category |
| | [transactions.get_transactions_by_month(budget_id, month)](https://github.com/ynab/ynab-sdk-ruby/blob/master/docs/TransactionsApi.md#get_transactions_by_month) | Returns all transactions for a specified month |
| | [transactions.get_transaction_by_id(budget_id, transaction_id)](https://github.com/ynab/ynab-sdk-ruby/blob/master/docs/TransactionsApi.md#get_transaction_by_id) | Returns a single transaction |
| | [transactions.create_transaction(budget_id, data)](https://github.com/ynab/ynab-sdk-ruby/blob/master/docs/TransactionsApi.md#create_transaction) | Creates a single transaction |
| | [transactions.create_transactions(budget_id, data)](https://github.com/ynab/ynab-sdk-ruby/blob/master/docs/TransactionsApi.md#create_transaction) | Creates multiple transactions |
Expand All @@ -77,6 +78,7 @@ The following methods are available in this library.
| | [transactions.import_transactions(budget_id)](https://github.com/ynab/ynab-sdk-ruby/blob/master/docs/TransactionsApi.md#import_transactions) | Imports transactions |
| **Scheduled Transactions** | [scheduled_transactions.get_scheduled_transactions(budget_id)](https://github.com/ynab/ynab-sdk-ruby/blob/master/docs/ScheduledTransactionsApi.md#get_scheduled_transactions) | Returns all scheduled transactions |
| | [scheduled_transactions.get_scheduled_transaction_by_id(budget_id, scheduled_transaction_id)](https://github.com/ynab/ynab-sdk-ruby/blob/master/docs/ScheduledTransactionsApi.md#get_scheduled_transaction_by_id) | Returns a single scheduled transaction |
| | [scheduled_transactions.create_scheduled_transaction(budget_id, data)](https://github.com/ynab/ynab-sdk-ruby/blob/master/docs/ScheduledTransactionsApi.md#create_scheduled_transaction) | Creates a single scheduled transaction |

## License

Expand Down
4 changes: 1 addition & 3 deletions Rakefile
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,6 @@ end

task :default => [:spec]

REQUIRED_RUBY_VERSION = ">= 3.3"

desc "Run OpenAPI Generator to update the client from the spec"
task :generate do
spec_filename = 'open_api_spec.yaml'
Expand All @@ -22,7 +20,7 @@ task :generate do
# Remove existing generated files to ensure old files are not included in the gem
sh "rm -r docs/ lib/ynab/models/"
# Generate the client
sh "openapi-generator generate -i ./#{spec_filename} -g ruby --additional-properties=gemRequiredRubyVersion='#{REQUIRED_RUBY_VERSION}' -c config.json -t ./templates -o ./"
sh "openapi-generator generate -i ./#{spec_filename} -g ruby -c config.yaml -o ./"
end

task :get_current_version do
Expand Down
11 changes: 11 additions & 0 deletions config.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
gemName: ynab
moduleName: YNAB
gemSummary: YNAB API Client for Ruby
gemDescription: Ruby gem wrapper for the YNAB API. API documentation available at https://api.ynab.com.
gemHomepage: https://github.com/ynab/ynab-sdk-ruby
gemLicense: Apache-2.0
gemAuthor: YNAB
gemAuthorEmail: api@ynab.com
templateDir: ./templates
additionalProperties:
gemRequiredRubyVersion: ">= 3.3"
2 changes: 1 addition & 1 deletion docs/ExistingTransaction.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
| **account_id** | **String** | | [optional] |
| **date** | **Date** | The transaction date in ISO format (e.g. 2016-12-01). Future dates (scheduled transactions) are not permitted. Split transaction dates cannot be changed and if a different date is supplied it will be ignored. | [optional] |
| **amount** | **Integer** | The transaction amount in milliunits format. Split transaction amounts cannot be changed and if a different amount is supplied it will be ignored. | [optional] |
| **payee_id** | **String** | The payee for the transaction. To create a transfer between two accounts, use the account transfer payee pointing to the target account. Account transfer payees are specified as `tranfer_payee_id` on the account resource. | [optional] |
| **payee_id** | **String** | The payee for the transaction. To create a transfer between two accounts, use the account transfer payee pointing to the target account. Account transfer payees are specified as `transfer_payee_id` on the account resource. | [optional] |
| **payee_name** | **String** | The payee name. If a `payee_name` value is provided and `payee_id` has a null value, the `payee_name` value will be used to resolve the payee by either (1) a matching payee rename rule (only if `import_id` is also specified) or (2) a payee with the same name or (3) creation of a new payee. | [optional] |
| **category_id** | **String** | The category for the transaction. To configure a split transaction, you can specify null for `category_id` and provide a `subtransactions` array as part of the transaction object. If an existing transaction is a split, the `category_id` cannot be changed. Credit Card Payment categories are not permitted and will be ignored if supplied. | [optional] |
| **memo** | **String** | | [optional] |
Expand Down
2 changes: 1 addition & 1 deletion docs/NewTransaction.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
| **account_id** | **String** | | [optional] |
| **date** | **Date** | The transaction date in ISO format (e.g. 2016-12-01). Future dates (scheduled transactions) are not permitted. Split transaction dates cannot be changed and if a different date is supplied it will be ignored. | [optional] |
| **amount** | **Integer** | The transaction amount in milliunits format. Split transaction amounts cannot be changed and if a different amount is supplied it will be ignored. | [optional] |
| **payee_id** | **String** | The payee for the transaction. To create a transfer between two accounts, use the account transfer payee pointing to the target account. Account transfer payees are specified as `tranfer_payee_id` on the account resource. | [optional] |
| **payee_id** | **String** | The payee for the transaction. To create a transfer between two accounts, use the account transfer payee pointing to the target account. Account transfer payees are specified as `transfer_payee_id` on the account resource. | [optional] |
| **payee_name** | **String** | The payee name. If a `payee_name` value is provided and `payee_id` has a null value, the `payee_name` value will be used to resolve the payee by either (1) a matching payee rename rule (only if `import_id` is also specified) or (2) a payee with the same name or (3) creation of a new payee. | [optional] |
| **category_id** | **String** | The category for the transaction. To configure a split transaction, you can specify null for `category_id` and provide a `subtransactions` array as part of the transaction object. If an existing transaction is a split, the `category_id` cannot be changed. Credit Card Payment categories are not permitted and will be ignored if supplied. | [optional] |
| **memo** | **String** | | [optional] |
Expand Down
8 changes: 8 additions & 0 deletions docs/PostScheduledTransactionWrapper.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
# YNAB::PostScheduledTransactionWrapper

## Properties

| Name | Type | Description | Notes |
| ---- | ---- | ----------- | ----- |
| **scheduled_transaction** | [**SaveScheduledTransaction**](SaveScheduledTransaction.md) | | |

16 changes: 16 additions & 0 deletions docs/SaveScheduledTransaction.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
# YNAB::SaveScheduledTransaction

## Properties

| Name | Type | Description | Notes |
| ---- | ---- | ----------- | ----- |
| **account_id** | **String** | | |
| **date** | **Date** | The scheduled transaction date in ISO format (e.g. 2016-12-01). | |
| **amount** | **Integer** | The scheduled transaction amount in milliunits format. | [optional] |
| **payee_id** | **String** | The payee for the scheduled transaction. To create a transfer between two accounts, use the account transfer payee pointing to the target account. Account transfer payees are specified as `transfer_payee_id` on the account resource. | [optional] |
| **payee_name** | **String** | The payee name for the the scheduled transaction. If a `payee_name` value is provided and `payee_id` has a null value, the `payee_name` value will be used to resolve the payee by either (1) a payee with the same name or (2) creation of a new payee. | [optional] |
| **category_id** | **String** | The category for the scheduled transaction. Credit Card Payment categories are not permitted. Creating a split scheduled transaction is not currently supported. | [optional] |
| **memo** | **String** | | [optional] |
| **flag_color** | [**TransactionFlagColor**](TransactionFlagColor.md) | | [optional] |
| **frequency** | [**ScheduledTransactionFrequency**](ScheduledTransactionFrequency.md) | | [optional] |

2 changes: 1 addition & 1 deletion docs/SaveTransactionWithIdOrImportId.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
| **account_id** | **String** | | [optional] |
| **date** | **Date** | The transaction date in ISO format (e.g. 2016-12-01). Future dates (scheduled transactions) are not permitted. Split transaction dates cannot be changed and if a different date is supplied it will be ignored. | [optional] |
| **amount** | **Integer** | The transaction amount in milliunits format. Split transaction amounts cannot be changed and if a different amount is supplied it will be ignored. | [optional] |
| **payee_id** | **String** | The payee for the transaction. To create a transfer between two accounts, use the account transfer payee pointing to the target account. Account transfer payees are specified as `tranfer_payee_id` on the account resource. | [optional] |
| **payee_id** | **String** | The payee for the transaction. To create a transfer between two accounts, use the account transfer payee pointing to the target account. Account transfer payees are specified as `transfer_payee_id` on the account resource. | [optional] |
| **payee_name** | **String** | The payee name. If a `payee_name` value is provided and `payee_id` has a null value, the `payee_name` value will be used to resolve the payee by either (1) a matching payee rename rule (only if `import_id` is also specified) or (2) a payee with the same name or (3) creation of a new payee. | [optional] |
| **category_id** | **String** | The category for the transaction. To configure a split transaction, you can specify null for `category_id` and provide a `subtransactions` array as part of the transaction object. If an existing transaction is a split, the `category_id` cannot be changed. Credit Card Payment categories are not permitted and will be ignored if supplied. | [optional] |
| **memo** | **String** | | [optional] |
Expand Down
2 changes: 1 addition & 1 deletion docs/SaveTransactionWithOptionalFields.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
| **account_id** | **String** | | [optional] |
| **date** | **Date** | The transaction date in ISO format (e.g. 2016-12-01). Future dates (scheduled transactions) are not permitted. Split transaction dates cannot be changed and if a different date is supplied it will be ignored. | [optional] |
| **amount** | **Integer** | The transaction amount in milliunits format. Split transaction amounts cannot be changed and if a different amount is supplied it will be ignored. | [optional] |
| **payee_id** | **String** | The payee for the transaction. To create a transfer between two accounts, use the account transfer payee pointing to the target account. Account transfer payees are specified as `tranfer_payee_id` on the account resource. | [optional] |
| **payee_id** | **String** | The payee for the transaction. To create a transfer between two accounts, use the account transfer payee pointing to the target account. Account transfer payees are specified as `transfer_payee_id` on the account resource. | [optional] |
| **payee_name** | **String** | The payee name. If a `payee_name` value is provided and `payee_id` has a null value, the `payee_name` value will be used to resolve the payee by either (1) a matching payee rename rule (only if `import_id` is also specified) or (2) a payee with the same name or (3) creation of a new payee. | [optional] |
| **category_id** | **String** | The category for the transaction. To configure a split transaction, you can specify null for `category_id` and provide a `subtransactions` array as part of the transaction object. If an existing transaction is a split, the `category_id` cannot be changed. Credit Card Payment categories are not permitted and will be ignored if supplied. | [optional] |
| **memo** | **String** | | [optional] |
Expand Down
7 changes: 7 additions & 0 deletions docs/ScheduledTransactionFrequency.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# YNAB::ScheduledTransactionFrequency

## Properties

| Name | Type | Description | Notes |
| ---- | ---- | ----------- | ----- |

21 changes: 21 additions & 0 deletions docs/ScheduledTransactionsApi.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,31 @@ All URIs are relative to *https://api.ynab.com/v1*

| Method | HTTP request | Description |
| ------ | ------------ | ----------- |
| [**create_scheduled_transaction**](ScheduledTransactionsApi.md#create_scheduled_transaction) | **POST** /budgets/{budget_id}/scheduled_transactions | Create a single scheduled transaction |
| [**get_scheduled_transaction_by_id**](ScheduledTransactionsApi.md#get_scheduled_transaction_by_id) | **GET** /budgets/{budget_id}/scheduled_transactions/{scheduled_transaction_id} | Single scheduled transaction |
| [**get_scheduled_transactions**](ScheduledTransactionsApi.md#get_scheduled_transactions) | **GET** /budgets/{budget_id}/scheduled_transactions | List scheduled transactions |


## create_scheduled_transaction

> <ScheduledTransactionResponse> create_scheduled_transaction(budget_id, data)
Create a single scheduled transaction

Creates a single scheduled transaction.

### Parameters

| Name | Type | Description | Notes |
| ---- | ---- | ----------- | ----- |
| **budget_id** | **String** | The id of the budget. \&quot;last-used\&quot; can be used to specify the last used budget and \&quot;default\&quot; can be used if default budget selection is enabled (see: https://api.ynab.com/#oauth-default-budget). | |
| **data** | [**PostScheduledTransactionWrapper**](PostScheduledTransactionWrapper.md) | The scheduled transaction to create | |

### Return type

[**ScheduledTransactionResponse**](ScheduledTransactionResponse.md)


## get_scheduled_transaction_by_id

> <ScheduledTransactionResponse> get_scheduled_transaction_by_id(budget_id, scheduled_transaction_id)
Expand Down
Loading

0 comments on commit 11045f0

Please sign in to comment.