Skip to content

Commit

Permalink
Merge pull request #37 from ripe-tech/jc/4702-general-order-chat
Browse files Browse the repository at this point in the history
feat: general order chat methods
  • Loading branch information
joamag authored Mar 23, 2022
2 parents 1045c09 + 2125fde commit 641471f
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 0 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
* Entire bulk order module for feature parity with JS SDK
* Pylint config and pylint command to the CI environment
* Added new methods `video` and `video_thumbnail` that return a video and video thumbnail related to a given mode, video name and customization - [ripe-white/#996](https://github.com/ripe-tech/ripe-white/issues/996)
* General order chat methods - [ripe-core/#4702](https://github.com/ripe-tech/ripe-core/issues/4702)

### Changed

Expand Down
20 changes: 20 additions & 0 deletions src/ripe/order.py
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,26 @@ def log_order(self, number):
contents = self.get(url)
return contents

def chat_order(self, number):
url = self.base_url + "orders/%d/chat" % number
contents = self.get(url)
return contents

def chat_lines_order(self, number, *args, **kwargs):
url = self.base_url + "orders/%d/chat/lines" % number
contents = self.get(url, **kwargs)
return contents

def chat_lines_count_order(self, number):
url = self.base_url + "orders/%d/chat/lines/count" % number
contents = self.get(url)
return contents

def chat_create_line_order(self, number, content):
url = self.base_url + "orders/%d/chat/lines/count" % number
contents = self.post(url, data_j = content)
return contents

def states_order(self, number):
url = self.base_url + "orders/%d/states" % number
contents = self.get(url)
Expand Down

0 comments on commit 641471f

Please sign in to comment.