Skip to content

Commit

Permalink
Support posting maintenance ticket comments through Connect (#136)
Browse files Browse the repository at this point in the history
Co-authored-by: Michael Liao <>
  • Loading branch information
mikeliao authored Mar 20, 2023
1 parent 5b45dd6 commit c150cb9
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 1 deletion.
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,12 @@

The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/)
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
## [4.28.0] - 2023-03-17

## Changed

- Added `create_ticket_comment` to allow posting ticket Comments through Connect

## [4.27.3] - 2023-02-24

## Changed
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

setup(
name='VacasaConnect',
version='4.27.3',
version='4.28.0',
description='A Python 3.6+ SDK for the connect.vacasa.com API.',
packages=['vacasa.connect'],
url='https://github.com/Vacasa/python-vacasa-connect-sdk',
Expand Down
11 changes: 11 additions & 0 deletions vacasa/connect/connect.py
Original file line number Diff line number Diff line change
Expand Up @@ -2133,6 +2133,17 @@ def create_ticket(self, payload: dict):
json={'data': {'type': 'ticket', 'attributes': payload}}

return self._post(url, json=json, headers=headers).json()

def create_ticket_comment(self, payload: dict):
"""
creates a ticket comment
"""

url = f"{self.endpoint}/v1/ticket-comments"
headers = self._headers()
json={'data': {'type': 'ticket-comment', 'attributes': payload}}

return self._post(url, json=json, headers=headers).json()


def _trip_protection_to_integer(trip_protection: bool) -> int:
Expand Down

0 comments on commit c150cb9

Please sign in to comment.