Skip to content

Commit 01e52b1

Browse files
authored
Merge pull request #18 from video-db/feat/add-billing
Feat/add billing
2 parents 588f6e8 + b98a5a3 commit 01e52b1

File tree

4 files changed

+16
-14
lines changed

4 files changed

+16
-14
lines changed

.github/pull_request_template.md

-7
Original file line numberDiff line numberDiff line change
@@ -15,10 +15,3 @@ Describe the purpose of this pull request.
1515
Describe any testing steps that have been taken or are necessary.
1616
Make sure to take in account any existing code change that require some feature to be re-tested.
1717

18-
19-
**Checklist:**
20-
- [ ] Code follows project coding standards
21-
- [ ] Tests have been added or updated
22-
- [ ] Code Review
23-
- [ ] Manual test after merge
24-
- [ ] All checks passed

videodb/__init__.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@
2424

2525
logger: logging.Logger = logging.getLogger("videodb")
2626

27-
__version__ = "0.1.1"
27+
__version__ = "0.1.2"
2828
__author__ = "videodb"
2929

3030
__all__ = [

videodb/_constants.py

+9-6
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,9 @@ class ApiPath:
4848
workflow = "workflow"
4949
timeline = "timeline"
5050
delete = "delete"
51+
billing = "billing"
52+
usage = "usage"
53+
invoices = "invoices"
5154

5255

5356
class Status:
@@ -76,12 +79,12 @@ class SubtitleAlignment:
7679
bottom_left = 1
7780
bottom_center = 2
7881
bottom_right = 3
79-
middle_left = 4
80-
middle_center = 5
81-
middle_right = 6
82-
top_left = 7
83-
top_center = 8
84-
top_right = 9
82+
middle_left = 9
83+
middle_center = 10
84+
middle_right = 11
85+
top_left = 5
86+
top_center = 6
87+
top_right = 7
8588

8689

8790
@dataclass

videodb/client.py

+6
Original file line numberDiff line numberDiff line change
@@ -84,6 +84,12 @@ def update_collection(self, id: str, name: str, description: str) -> Collection:
8484
collection_data.get("description"),
8585
)
8686

87+
def check_usage(self) -> dict:
88+
return self.get(path=f"{ApiPath.billing}/{ApiPath.usage}")
89+
90+
def get_invoices(self) -> List[dict]:
91+
return self.get(path=f"{ApiPath.billing}/{ApiPath.invoices}")
92+
8793
def upload(
8894
self,
8995
file_path: str = None,

0 commit comments

Comments
 (0)