Skip to content

Commit

Permalink
(feat) update the SDK according to the openapi spec (#44)
Browse files Browse the repository at this point in the history
(feat) update the SDK according to the openapi spec
  • Loading branch information
xavierlacot authored Aug 17, 2023
1 parent 369d47d commit 28ee5f7
Show file tree
Hide file tree
Showing 272 changed files with 1,827 additions and 1,117 deletions.
40 changes: 23 additions & 17 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,40 +1,46 @@
# Changes between versions

## 6.3.0 (2023-08-17)

* updated the SDK based on the latest spec updates - see jolicode/harvest-openapi-generator#27 in #44
* updated the spec according to the current documentation
* fixed several definitions

## 6.2.0 (2023-04-19)

* upgrade to `janephp/open-api` 7.4
* updated the SDK based on the latest [spec updates](jolicode/harvest-openapi-generator#26) in #43
* updated the SDK based on the latest spec updates - see jolicode/harvest-openapi-generator#26 in #43
* support for the newly introduced pagination cursors
* updated descriptions according to the docs
* add `TimeReportsResult.weekly_capacity` and `TimeReportsResult.avatar_url`
* bump the minimum required PHP version

## 6.1.0 (2022-11-12)

* updated the SDK based on the latest [spec updates](jolicode/harvest-openapi-generator#22) in #41
* updated the SDK based on the latest spec updates - see jolicode/harvest-openapi-generator#22 in #41
* add support for `User.access_roles` as defined in https://help.getharvest.com/api-v2/users-api/users/users/#access-roles
* remove the now non-working `User.is_admin` and `User.is_project_manager` booleans
* add management of users assigned team mates, as defined in https://help.getharvest.com/api-v2/users-api/users/teammates/
* add the ability to retrieve message subject and body for specific invoices as defined in https://help.getharvest.com/api-v2/invoices-api/invoices/invoice-messages/#retrieve-invoice-message-subject-and-body-for-specific-invoice

## 6.0.0 (2022-08-04)

* upgrade to `janephp/open-api` 7.3
* drop support for PHP <7.4
* updated the SDK based on the latest [spec updates](jolicode/harvest-openapi-generator#20)
* updated the SDK based on the latest spec updates - see jolicode/harvest-openapi-generator#20
* added `Company.currency_code_display` and `Company.currency_symbol_display`
* several fields of the `User` object have disappeared, due to the [API changes introduced in March](https://www.getharvest.com/blog/new-flexible-permissions#:~:text=The%20API%20has%20been%20updated%20to%20align%20with%20the%20new%20permissions%20features.).
## 5.2.0 (2022-01-10)

* upgraded `janephp/open-api` from 6.3 to 7.1 - thanks @jdrieghe
* added support for Symfony 6
* updated the SDK based on the latest [spec updates](jolicode/harvest-openapi-generator#19)
* updated the SDK based on the latest spec updates - see jolicode/harvest-openapi-generator#19
* added support for `User.telephone`

## 5.1.0 (2021-08-03)

* updated the SDK based on the latest [spec updates](jolicode/harvest-openapi-generator#18)
* updated the SDK based on the latest spec updates - see jolicode/harvest-openapi-generator#18
* added `date_format` on the `Company` model
* added `hours_without_timer` and `external_reference/account_id` in the `TaskAssignment` model

Expand Down Expand Up @@ -101,26 +107,26 @@
* added the `Invoice` `recurring_invoice_id` attribute

## 2.0.0 (2019-10-28)
* Upgrade Jane to 4.5 https://github.com/janephp/janephp/releases/tag/v4.5.3, the new generated classes have better PHPDoc​
* Generate PSR-18 client instead of HttPlug client
* Support for cost and billable rates
* Removed the telephone property from the user model
* Added statement_key in the Client properties

* Upgrade Jane to 4.5 https://github.com/janephp/janephp/releases/tag/v4.5.3, the new generated classes have better PHPDoc​
* Generate PSR-18 client instead of HttPlug client
* Support for cost and billable rates
* Removed the telephone property from the user model
* Added statement_key in the Client properties

## 1.1.0 (2019-04-01)

* Support HTTPlug 2
* Support HTTPlug 2

## 1.0.2 (2019-01-24)

* support null values for nested objects or values (jane-openapi strict mode false)
* changed `quantity` types to `float` instead of `integer`
* support null values for nested objects or values (jane-openapi strict mode false)
* changed `quantity` types to `float` instead of `integer`

## 1.0.1 (2019-01-22)

* Fixed the `deleteTimeEntryExternalReference` endpoint operationId
* Fixed the `deleteTimeEntryExternalReference` endpoint operationId

## 1.0.0 (2019-01-21)

* Initial release
* Initial release
53 changes: 47 additions & 6 deletions Resources/harvest-openapi.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -253,8 +253,9 @@ components:
nullable: true
include_link_to_client_invoice:
type: boolean
description: 'Whether to include a link to the client invoice in the message body. Not used when thank_you is true.'
description: 'DEPRECATED This will be true when payment_options are assigned to the invoice and false when there are no payment_options.'
nullable: true
deprecated: true
attach_pdf:
type: boolean
description: 'Whether to attach the invoice PDF to the message email.'
Expand Down Expand Up @@ -515,6 +516,16 @@ components:
type: string
description: 'The timeframe in which the invoice should be paid. Options: upon receipt, net 15, net 30, net 45, net 60, or custom.'
nullable: true
payment_options:
type: array
description: 'The list of payment options enabled for the invoice. Options: [ach, credit_card, paypal]'
nullable: true
items:
type: string
enum:
- ach
- credit_card
- paypal
sent_at:
type: string
description: 'Date and time the invoice was sent.'
Expand Down Expand Up @@ -1152,7 +1163,6 @@ components:
type: integer
description: 'Unique ID for the time entry.'
nullable: true
format: int32
spent_date:
type: string
description: 'Date of the time entry.'
Expand Down Expand Up @@ -1619,7 +1629,7 @@ components:
url: 'https://help.getharvest.com/api-v2/users-api/users/teammates/#the-teammate-object'
properties:
id:
type: int
type: integer
description: 'Unique ID for the teammate'
nullable: true
first_name:
Expand Down Expand Up @@ -6130,6 +6140,8 @@ paths:
created_at: '2017-06-27T16:27:16Z'
updated_at: '2017-08-23T22:25:59Z'
currency: EUR
payment_options:
- credit_card
client:
id: 5735776
name: '123 Industries'
Expand Down Expand Up @@ -6338,6 +6350,8 @@ paths:
created_at: '2017-06-27T16:34:24Z'
updated_at: '2017-06-27T16:34:24Z'
currency: USD
payment_options:
- credit_card
client:
id: 5735774
name: 'ABC Corp'
Expand Down Expand Up @@ -6430,6 +6444,16 @@ paths:
type: string
description: 'The timeframe in which the invoice should be paid. Defaults to custom. Options: upon receipt, net 15, net 30, net 45, net 60, or custom.'
nullable: true
payment_options:
type: array
description: 'The payment options available to pay the invoice. Your account must be configured with the appropriate options under Settings > Integrations > Online payment to assign them. Options: [ach, credit_card, paypal]'
nullable: true
items:
type: string
enum:
- ach
- credit_card
- paypal
line_items_import:
type: object
description: 'An line items import object'
Expand Down Expand Up @@ -6481,7 +6505,7 @@ paths:
description: 'If set to true, a PDF containing an expense report with receipts will be attached to the invoice. Defaults to false.'
retainer_id:
type: integer
description: 'The ID of the retainer you want to add funds to with this invoice. Note: retainers cannot be fully used (created, drawn against, closed, etc.) via the API at this time. The only avaiable action is to add funds.'
description: 'The ID of the retainer you want to add funds to with this invoice. Note: retainers cannot be fully used (created, drawn against, closed, etc.) via the API at this time. The only available action is to add funds.'
nullable: true
format: int32
line_items:
Expand Down Expand Up @@ -6595,6 +6619,8 @@ paths:
created_at: '2017-06-27T16:24:30Z'
updated_at: '2017-06-27T16:24:57Z'
currency: USD
payment_options:
- credit_card
client:
id: 5735776
name: '123 Industries'
Expand Down Expand Up @@ -6678,6 +6704,8 @@ paths:
created_at: '2017-06-27T16:34:24Z'
updated_at: '2017-06-27T16:36:33Z'
currency: USD
payment_options:
- credit_card
client:
id: 5735774
name: 'ABC Corp'
Expand Down Expand Up @@ -6782,6 +6810,16 @@ paths:
type: string
description: 'The timeframe in which the invoice should be paid. Options: upon receipt, net 15, net 30, net 45, or net 60.'
nullable: true
payment_options:
type: array
description: 'The payment options available to pay the invoice. Your account must be configured with the appropriate options under Settings > Integrations > Online payment to assign them. Options: [ach, credit_card, paypal]'
nullable: true
items:
type: string
enum:
- ach
- credit_card
- paypal
line_items:
type: array
description: 'Array of line item parameters'
Expand Down Expand Up @@ -7029,8 +7067,9 @@ paths:
nullable: true
include_link_to_client_invoice:
type: boolean
description: 'If set to true, a link to the client invoice URL will be included in the message email. Defaults to false. Ignored when thank_you is set to true.'
description: 'DEPRECATED A link to the client invoice URL will be automatically included in the message email if payment_options have been assigned to the invoice. Setting to true will be ignored. Setting to false will clear all payment_options on the invoice.'
nullable: true
deprecated: true
attach_pdf:
type: boolean
description: 'If set to true, a PDF of the invoice will be attached to the message email. Defaults to false.'
Expand Down Expand Up @@ -12800,8 +12839,10 @@ paths:
type: object
properties:
teammate_ids:
type: 'array of user ids'
type: array
description: 'Full list of user IDs to be assigned to the Manager.'
nullable: true
items:
type: string
required:
- teammate_ids
3 changes: 3 additions & 0 deletions doc/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -104,6 +104,7 @@ Instead of the `listClients()` method above, you can use all of these methods:
* `updateInvoice()`
* `listMessagesForInvoice()`
* `createInvoiceMessage()`
* `retrieveInvoiceMessageSubjectAndBodyForSpecificInvoice()`
* `deleteInvoiceMessage()`
* `listPaymentsForInvoice()`
* `createInvoicePayment()`
Expand Down Expand Up @@ -175,6 +176,8 @@ Instead of the `listClients()` method above, you can use all of these methods:
* `createCostRate()`
* `retrieveCostRate()`
* `listActiveProjectAssignments()`
* `listAssignedTeammatesForSpecificUser()`
* `updateUserAssignedTeammates()`

## Examples

Expand Down
Loading

0 comments on commit 28ee5f7

Please sign in to comment.