karakeep-python-api 1.2.0__tar.gz → 1.2.2__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (18) hide show
  1. {karakeep_python_api-1.2.0/karakeep_python_api.egg-info → karakeep_python_api-1.2.2}/PKG-INFO +2 -2
  2. {karakeep_python_api-1.2.0 → karakeep_python_api-1.2.2}/karakeep_python_api/__main__.py +6 -1
  3. {karakeep_python_api-1.2.0 → karakeep_python_api-1.2.2}/karakeep_python_api/karakeep_api.py +1 -1
  4. {karakeep_python_api-1.2.0 → karakeep_python_api-1.2.2}/karakeep_python_api/openapi_reference.json +154 -3
  5. {karakeep_python_api-1.2.0 → karakeep_python_api-1.2.2/karakeep_python_api.egg-info}/PKG-INFO +2 -2
  6. {karakeep_python_api-1.2.0 → karakeep_python_api-1.2.2}/karakeep_python_api.egg-info/requires.txt +1 -1
  7. {karakeep_python_api-1.2.0 → karakeep_python_api-1.2.2}/setup.py +2 -2
  8. {karakeep_python_api-1.2.0 → karakeep_python_api-1.2.2}/LICENSE +0 -0
  9. {karakeep_python_api-1.2.0 → karakeep_python_api-1.2.2}/MANIFEST.in +0 -0
  10. {karakeep_python_api-1.2.0 → karakeep_python_api-1.2.2}/README.md +0 -0
  11. {karakeep_python_api-1.2.0 → karakeep_python_api-1.2.2}/karakeep_python_api/__init__.py +0 -0
  12. {karakeep_python_api-1.2.0 → karakeep_python_api-1.2.2}/karakeep_python_api/datatypes.py +0 -0
  13. {karakeep_python_api-1.2.0 → karakeep_python_api-1.2.2}/karakeep_python_api.egg-info/SOURCES.txt +0 -0
  14. {karakeep_python_api-1.2.0 → karakeep_python_api-1.2.2}/karakeep_python_api.egg-info/dependency_links.txt +0 -0
  15. {karakeep_python_api-1.2.0 → karakeep_python_api-1.2.2}/karakeep_python_api.egg-info/entry_points.txt +0 -0
  16. {karakeep_python_api-1.2.0 → karakeep_python_api-1.2.2}/karakeep_python_api.egg-info/top_level.txt +0 -0
  17. {karakeep_python_api-1.2.0 → karakeep_python_api-1.2.2}/setup.cfg +0 -0
  18. {karakeep_python_api-1.2.0 → karakeep_python_api-1.2.2}/tests/test_karakeep_api.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: karakeep_python_api
3
- Version: 1.2.0
3
+ Version: 1.2.2
4
4
  Summary: Community python client for the Karakeep API.
5
5
  Home-page: https://github.com/thiswillbeyourgithub/karakeep_python_api/
6
6
  License: GPLv3
@@ -12,7 +12,7 @@ Requires-Python: >=3.9
12
12
  Description-Content-Type: text/markdown
13
13
  License-File: LICENSE
14
14
  Requires-Dist: requests>=2.32.3
15
- Requires-Dist: loguru
15
+ Requires-Dist: loguru>=0.7.3
16
16
  Requires-Dist: pydantic>=2.0
17
17
  Requires-Dist: click>=8.0
18
18
  Provides-Extra: dev
@@ -80,7 +80,6 @@ shared_options = [
80
80
  "-v",
81
81
  is_flag=True,
82
82
  default=False,
83
- envvar="KARAKEEP_PYTHON_API_VERBOSE",
84
83
  help="Enable verbose logging.",
85
84
  ),
86
85
  click.option(
@@ -185,6 +184,12 @@ def cli(
185
184
  "The URL must include the API path, e.g., 'https://your-instance.com/api/v1/'."
186
185
  )
187
186
 
187
+ # Handle verbose environment variable manually since Click's is_flag=True + envvar
188
+ # treats any non-empty value (including "false") as True
189
+ if not verbose: # Only check env var if not already set via CLI flag
190
+ env_verbose = os.environ.get("KARAKEEP_PYTHON_API_VERBOSE", "").lower()
191
+ verbose = env_verbose in ("true", "1", "yes")
192
+
188
193
  # Store common API parameters in the context for commands to use
189
194
  ctx.obj["API_ENDPOINT"] = resolved_api_endpoint # Store the resolved endpoint
190
195
  ctx.obj["API_KEY"] = resolved_api_key # Store the resolved key
@@ -85,7 +85,7 @@ class KarakeepAPI:
85
85
  """
86
86
 
87
87
  # Version reflects the client library version, updated by bumpver
88
- VERSION: str = "1.2.0"
88
+ VERSION: str = "1.2.2"
89
89
 
90
90
  def __init__(
91
91
  self,
@@ -174,6 +174,10 @@
174
174
  "type": "string",
175
175
  "nullable": true
176
176
  },
177
+ "contentAssetId": {
178
+ "type": "string",
179
+ "nullable": true
180
+ },
177
181
  "crawledAt": {
178
182
  "type": "string",
179
183
  "nullable": true
@@ -291,6 +295,7 @@
291
295
  "assetType": {
292
296
  "type": "string",
293
297
  "enum": [
298
+ "linkHtmlContent",
294
299
  "screenshot",
295
300
  "assetScreenshot",
296
301
  "bannerImage",
@@ -1551,6 +1556,7 @@
1551
1556
  "assetType": {
1552
1557
  "type": "string",
1553
1558
  "enum": [
1559
+ "linkHtmlContent",
1554
1560
  "screenshot",
1555
1561
  "assetScreenshot",
1556
1562
  "bannerImage",
@@ -1584,6 +1590,7 @@
1584
1590
  "assetType": {
1585
1591
  "type": "string",
1586
1592
  "enum": [
1593
+ "linkHtmlContent",
1587
1594
  "screenshot",
1588
1595
  "assetScreenshot",
1589
1596
  "bannerImage",
@@ -2321,8 +2328,7 @@
2321
2328
  "type": "object",
2322
2329
  "properties": {
2323
2330
  "name": {
2324
- "type": "string",
2325
- "minLength": 1
2331
+ "type": "string"
2326
2332
  }
2327
2333
  },
2328
2334
  "required": [
@@ -3039,6 +3045,145 @@
3039
3045
  },
3040
3046
  "numHighlights": {
3041
3047
  "type": "number"
3048
+ },
3049
+ "bookmarksByType": {
3050
+ "type": "object",
3051
+ "properties": {
3052
+ "link": {
3053
+ "type": "number"
3054
+ },
3055
+ "text": {
3056
+ "type": "number"
3057
+ },
3058
+ "asset": {
3059
+ "type": "number"
3060
+ }
3061
+ },
3062
+ "required": [
3063
+ "link",
3064
+ "text",
3065
+ "asset"
3066
+ ]
3067
+ },
3068
+ "topDomains": {
3069
+ "type": "array",
3070
+ "items": {
3071
+ "type": "object",
3072
+ "properties": {
3073
+ "domain": {
3074
+ "type": "string"
3075
+ },
3076
+ "count": {
3077
+ "type": "number"
3078
+ }
3079
+ },
3080
+ "required": [
3081
+ "domain",
3082
+ "count"
3083
+ ]
3084
+ },
3085
+ "maxItems": 10
3086
+ },
3087
+ "totalAssetSize": {
3088
+ "type": "number"
3089
+ },
3090
+ "assetsByType": {
3091
+ "type": "array",
3092
+ "items": {
3093
+ "type": "object",
3094
+ "properties": {
3095
+ "type": {
3096
+ "type": "string"
3097
+ },
3098
+ "count": {
3099
+ "type": "number"
3100
+ },
3101
+ "totalSize": {
3102
+ "type": "number"
3103
+ }
3104
+ },
3105
+ "required": [
3106
+ "type",
3107
+ "count",
3108
+ "totalSize"
3109
+ ]
3110
+ }
3111
+ },
3112
+ "bookmarkingActivity": {
3113
+ "type": "object",
3114
+ "properties": {
3115
+ "thisWeek": {
3116
+ "type": "number"
3117
+ },
3118
+ "thisMonth": {
3119
+ "type": "number"
3120
+ },
3121
+ "thisYear": {
3122
+ "type": "number"
3123
+ },
3124
+ "byHour": {
3125
+ "type": "array",
3126
+ "items": {
3127
+ "type": "object",
3128
+ "properties": {
3129
+ "hour": {
3130
+ "type": "number"
3131
+ },
3132
+ "count": {
3133
+ "type": "number"
3134
+ }
3135
+ },
3136
+ "required": [
3137
+ "hour",
3138
+ "count"
3139
+ ]
3140
+ }
3141
+ },
3142
+ "byDayOfWeek": {
3143
+ "type": "array",
3144
+ "items": {
3145
+ "type": "object",
3146
+ "properties": {
3147
+ "day": {
3148
+ "type": "number"
3149
+ },
3150
+ "count": {
3151
+ "type": "number"
3152
+ }
3153
+ },
3154
+ "required": [
3155
+ "day",
3156
+ "count"
3157
+ ]
3158
+ }
3159
+ }
3160
+ },
3161
+ "required": [
3162
+ "thisWeek",
3163
+ "thisMonth",
3164
+ "thisYear",
3165
+ "byHour",
3166
+ "byDayOfWeek"
3167
+ ]
3168
+ },
3169
+ "tagUsage": {
3170
+ "type": "array",
3171
+ "items": {
3172
+ "type": "object",
3173
+ "properties": {
3174
+ "name": {
3175
+ "type": "string"
3176
+ },
3177
+ "count": {
3178
+ "type": "number"
3179
+ }
3180
+ },
3181
+ "required": [
3182
+ "name",
3183
+ "count"
3184
+ ]
3185
+ },
3186
+ "maxItems": 10
3042
3187
  }
3043
3188
  },
3044
3189
  "required": [
@@ -3047,7 +3192,13 @@
3047
3192
  "numArchived",
3048
3193
  "numTags",
3049
3194
  "numLists",
3050
- "numHighlights"
3195
+ "numHighlights",
3196
+ "bookmarksByType",
3197
+ "topDomains",
3198
+ "totalAssetSize",
3199
+ "assetsByType",
3200
+ "bookmarkingActivity",
3201
+ "tagUsage"
3051
3202
  ]
3052
3203
  }
3053
3204
  }
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: karakeep_python_api
3
- Version: 1.2.0
3
+ Version: 1.2.2
4
4
  Summary: Community python client for the Karakeep API.
5
5
  Home-page: https://github.com/thiswillbeyourgithub/karakeep_python_api/
6
6
  License: GPLv3
@@ -12,7 +12,7 @@ Requires-Python: >=3.9
12
12
  Description-Content-Type: text/markdown
13
13
  License-File: LICENSE
14
14
  Requires-Dist: requests>=2.32.3
15
- Requires-Dist: loguru
15
+ Requires-Dist: loguru>=0.7.3
16
16
  Requires-Dist: pydantic>=2.0
17
17
  Requires-Dist: click>=8.0
18
18
  Provides-Extra: dev
@@ -1,5 +1,5 @@
1
1
  requests>=2.32.3
2
- loguru
2
+ loguru>=0.7.3
3
3
  pydantic>=2.0
4
4
  click>=8.0
5
5
 
@@ -7,7 +7,7 @@ with open("README.md", "r") as readme:
7
7
 
8
8
  setup(
9
9
  name="karakeep_python_api",
10
- version="1.2.0",
10
+ version="1.2.2",
11
11
  description="Community python client for the Karakeep API.", # Simplified description
12
12
  long_description=long_description,
13
13
  long_description_content_type="text/markdown",
@@ -33,7 +33,7 @@ setup(
33
33
  python_requires=">=3.9",
34
34
  install_requires=[
35
35
  "requests >= 2.32.3",
36
- "loguru",
36
+ "loguru >= 0.7.3",
37
37
  "pydantic >= 2.0", # For data validation and modeling based on datatypes.py
38
38
  "click >= 8.0", # For the CLI
39
39
  ],