syncsdk 0.2.0__tar.gz → 0.2.1__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 (66) hide show
  1. {syncsdk-0.2.0 → syncsdk-0.2.1}/PKG-INFO +34 -10
  2. {syncsdk-0.2.0 → syncsdk-0.2.1}/README.md +33 -9
  3. {syncsdk-0.2.0 → syncsdk-0.2.1}/pyproject.toml +1 -1
  4. {syncsdk-0.2.0 → syncsdk-0.2.1}/src/sync/core/client_wrapper.py +2 -2
  5. {syncsdk-0.2.0 → syncsdk-0.2.1}/src/sync/__init__.py +0 -0
  6. {syncsdk-0.2.0 → syncsdk-0.2.1}/src/sync/batch/__init__.py +0 -0
  7. {syncsdk-0.2.0 → syncsdk-0.2.1}/src/sync/batch/client.py +0 -0
  8. {syncsdk-0.2.0 → syncsdk-0.2.1}/src/sync/batch/raw_client.py +0 -0
  9. {syncsdk-0.2.0 → syncsdk-0.2.1}/src/sync/client.py +0 -0
  10. {syncsdk-0.2.0 → syncsdk-0.2.1}/src/sync/common/__init__.py +0 -0
  11. {syncsdk-0.2.0 → syncsdk-0.2.1}/src/sync/common/errors/__init__.py +0 -0
  12. {syncsdk-0.2.0 → syncsdk-0.2.1}/src/sync/common/errors/bad_request_error.py +0 -0
  13. {syncsdk-0.2.0 → syncsdk-0.2.1}/src/sync/common/errors/internal_server_error.py +0 -0
  14. {syncsdk-0.2.0 → syncsdk-0.2.1}/src/sync/common/errors/not_found_error.py +0 -0
  15. {syncsdk-0.2.0 → syncsdk-0.2.1}/src/sync/common/errors/payment_required_error.py +0 -0
  16. {syncsdk-0.2.0 → syncsdk-0.2.1}/src/sync/common/errors/too_many_requests_error.py +0 -0
  17. {syncsdk-0.2.0 → syncsdk-0.2.1}/src/sync/common/errors/unauthorized_error.py +0 -0
  18. {syncsdk-0.2.0 → syncsdk-0.2.1}/src/sync/common/types/__init__.py +0 -0
  19. {syncsdk-0.2.0 → syncsdk-0.2.1}/src/sync/common/types/active_speaker.py +0 -0
  20. {syncsdk-0.2.0 → syncsdk-0.2.1}/src/sync/common/types/audio.py +0 -0
  21. {syncsdk-0.2.0 → syncsdk-0.2.1}/src/sync/common/types/batch_id.py +0 -0
  22. {syncsdk-0.2.0 → syncsdk-0.2.1}/src/sync/common/types/batch_metrics.py +0 -0
  23. {syncsdk-0.2.0 → syncsdk-0.2.1}/src/sync/common/types/batch_response.py +0 -0
  24. {syncsdk-0.2.0 → syncsdk-0.2.1}/src/sync/common/types/batch_status.py +0 -0
  25. {syncsdk-0.2.0 → syncsdk-0.2.1}/src/sync/common/types/create_batch_response.py +0 -0
  26. {syncsdk-0.2.0 → syncsdk-0.2.1}/src/sync/common/types/create_generation_dto.py +0 -0
  27. {syncsdk-0.2.0 → syncsdk-0.2.1}/src/sync/common/types/eleven_labs.py +0 -0
  28. {syncsdk-0.2.0 → syncsdk-0.2.1}/src/sync/common/types/estimated_generation_cost.py +0 -0
  29. {syncsdk-0.2.0 → syncsdk-0.2.1}/src/sync/common/types/generation.py +0 -0
  30. {syncsdk-0.2.0 → syncsdk-0.2.1}/src/sync/common/types/generation_error.py +0 -0
  31. {syncsdk-0.2.0 → syncsdk-0.2.1}/src/sync/common/types/generation_error_message.py +0 -0
  32. {syncsdk-0.2.0 → syncsdk-0.2.1}/src/sync/common/types/generation_id.py +0 -0
  33. {syncsdk-0.2.0 → syncsdk-0.2.1}/src/sync/common/types/generation_options.py +0 -0
  34. {syncsdk-0.2.0 → syncsdk-0.2.1}/src/sync/common/types/generation_status.py +0 -0
  35. {syncsdk-0.2.0 → syncsdk-0.2.1}/src/sync/common/types/input.py +0 -0
  36. {syncsdk-0.2.0 → syncsdk-0.2.1}/src/sync/common/types/model.py +0 -0
  37. {syncsdk-0.2.0 → syncsdk-0.2.1}/src/sync/common/types/segment_frames.py +0 -0
  38. {syncsdk-0.2.0 → syncsdk-0.2.1}/src/sync/common/types/segment_secs.py +0 -0
  39. {syncsdk-0.2.0 → syncsdk-0.2.1}/src/sync/common/types/sync_mode.py +0 -0
  40. {syncsdk-0.2.0 → syncsdk-0.2.1}/src/sync/common/types/tts.py +0 -0
  41. {syncsdk-0.2.0 → syncsdk-0.2.1}/src/sync/common/types/tts_provider_config.py +0 -0
  42. {syncsdk-0.2.0 → syncsdk-0.2.1}/src/sync/common/types/validation_response.py +0 -0
  43. {syncsdk-0.2.0 → syncsdk-0.2.1}/src/sync/common/types/video.py +0 -0
  44. {syncsdk-0.2.0 → syncsdk-0.2.1}/src/sync/core/__init__.py +0 -0
  45. {syncsdk-0.2.0 → syncsdk-0.2.1}/src/sync/core/api_error.py +0 -0
  46. {syncsdk-0.2.0 → syncsdk-0.2.1}/src/sync/core/datetime_utils.py +0 -0
  47. {syncsdk-0.2.0 → syncsdk-0.2.1}/src/sync/core/file.py +0 -0
  48. {syncsdk-0.2.0 → syncsdk-0.2.1}/src/sync/core/http_client.py +0 -0
  49. {syncsdk-0.2.0 → syncsdk-0.2.1}/src/sync/core/http_response.py +0 -0
  50. {syncsdk-0.2.0 → syncsdk-0.2.1}/src/sync/core/jsonable_encoder.py +0 -0
  51. {syncsdk-0.2.0 → syncsdk-0.2.1}/src/sync/core/pydantic_utilities.py +0 -0
  52. {syncsdk-0.2.0 → syncsdk-0.2.1}/src/sync/core/query_encoder.py +0 -0
  53. {syncsdk-0.2.0 → syncsdk-0.2.1}/src/sync/core/remove_none_from_dict.py +0 -0
  54. {syncsdk-0.2.0 → syncsdk-0.2.1}/src/sync/core/request_options.py +0 -0
  55. {syncsdk-0.2.0 → syncsdk-0.2.1}/src/sync/core/serialization.py +0 -0
  56. {syncsdk-0.2.0 → syncsdk-0.2.1}/src/sync/core/unchecked_base_model.py +0 -0
  57. {syncsdk-0.2.0 → syncsdk-0.2.1}/src/sync/environment.py +0 -0
  58. {syncsdk-0.2.0 → syncsdk-0.2.1}/src/sync/generations/__init__.py +0 -0
  59. {syncsdk-0.2.0 → syncsdk-0.2.1}/src/sync/generations/client.py +0 -0
  60. {syncsdk-0.2.0 → syncsdk-0.2.1}/src/sync/generations/raw_client.py +0 -0
  61. {syncsdk-0.2.0 → syncsdk-0.2.1}/src/sync/py.typed +0 -0
  62. {syncsdk-0.2.0 → syncsdk-0.2.1}/src/sync/version.py +0 -0
  63. {syncsdk-0.2.0 → syncsdk-0.2.1}/src/sync/webhooks/__init__.py +0 -0
  64. {syncsdk-0.2.0 → syncsdk-0.2.1}/src/sync/webhooks/types/__init__.py +0 -0
  65. {syncsdk-0.2.0 → syncsdk-0.2.1}/src/sync/webhooks/types/generation_notification.py +0 -0
  66. {syncsdk-0.2.0 → syncsdk-0.2.1}/src/sync/webhooks/types/webhook_status.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: syncsdk
3
- Version: 0.2.0
3
+ Version: 0.2.1
4
4
  Summary:
5
5
  Requires-Python: >=3.8,<4.0
6
6
  Classifier: Intended Audience :: Developers
@@ -33,7 +33,7 @@ The Sync Python library provides convenient access to the Sync API from Python.
33
33
 
34
34
  ## Documentation
35
35
 
36
- API reference documentation is available [here](https://sync.docs.buildwithfern.com/api-reference).
36
+ API reference documentation is available [here](https://docs.sync.so/api-reference).
37
37
 
38
38
  ## Installation
39
39
 
@@ -43,7 +43,7 @@ pip install syncsdk
43
43
 
44
44
  ## Reference
45
45
 
46
- A full reference for this library is available [here](https://github.com/synchronicity-labs/sync-python-sdk/blob/HEAD/./reference.md).
46
+ A full reference for this library is available [here](./reference.md).
47
47
 
48
48
  ## Usage
49
49
 
@@ -51,12 +51,24 @@ Instantiate and use the client with the following:
51
51
 
52
52
  ```python
53
53
  from sync import Sync
54
+ from sync.common import Audio, GenerationOptions, Video
54
55
 
55
56
  client = Sync(
56
57
  api_key="YOUR_API_KEY",
57
58
  )
58
- client.batch.create(
59
- dry_run=True,
59
+ client.generations.create(
60
+ input=[
61
+ Video(
62
+ url="https://assets.sync.so/docs/example-video.mp4",
63
+ ),
64
+ Audio(
65
+ url="https://assets.sync.so/docs/example-audio.wav",
66
+ ),
67
+ ],
68
+ model="lipsync-2",
69
+ options=GenerationOptions(
70
+ sync_mode="loop",
71
+ ),
60
72
  )
61
73
  ```
62
74
 
@@ -68,6 +80,7 @@ The SDK also exports an `async` client so that you can make non-blocking calls t
68
80
  import asyncio
69
81
 
70
82
  from sync import AsyncSync
83
+ from sync.common import Audio, GenerationOptions, Video
71
84
 
72
85
  client = AsyncSync(
73
86
  api_key="YOUR_API_KEY",
@@ -75,8 +88,19 @@ client = AsyncSync(
75
88
 
76
89
 
77
90
  async def main() -> None:
78
- await client.batch.create(
79
- dry_run=True,
91
+ await client.generations.create(
92
+ input=[
93
+ Video(
94
+ url="https://assets.sync.so/docs/example-video.mp4",
95
+ ),
96
+ Audio(
97
+ url="https://assets.sync.so/docs/example-audio.wav",
98
+ ),
99
+ ],
100
+ model="lipsync-2",
101
+ options=GenerationOptions(
102
+ sync_mode="loop",
103
+ ),
80
104
  )
81
105
 
82
106
 
@@ -92,7 +116,7 @@ will be thrown.
92
116
  from sync.core.api_error import ApiError
93
117
 
94
118
  try:
95
- client.batch.create(...)
119
+ client.generations.create(...)
96
120
  except ApiError as e:
97
121
  print(e.status_code)
98
122
  print(e.body)
@@ -115,7 +139,7 @@ A request is deemed retryable when any of the following HTTP status codes is ret
115
139
  Use the `max_retries` request option to configure this behavior.
116
140
 
117
141
  ```python
118
- client.batch.create(..., request_options={
142
+ client.generations.create(..., request_options={
119
143
  "max_retries": 1
120
144
  })
121
145
  ```
@@ -135,7 +159,7 @@ client = Sync(
135
159
 
136
160
 
137
161
  # Override timeout for a specific method
138
- client.batch.create(..., request_options={
162
+ client.generations.create(..., request_options={
139
163
  "timeout_in_seconds": 1
140
164
  })
141
165
  ```
@@ -7,7 +7,7 @@ The Sync Python library provides convenient access to the Sync API from Python.
7
7
 
8
8
  ## Documentation
9
9
 
10
- API reference documentation is available [here](https://sync.docs.buildwithfern.com/api-reference).
10
+ API reference documentation is available [here](https://docs.sync.so/api-reference).
11
11
 
12
12
  ## Installation
13
13
 
@@ -17,7 +17,7 @@ pip install syncsdk
17
17
 
18
18
  ## Reference
19
19
 
20
- A full reference for this library is available [here](https://github.com/synchronicity-labs/sync-python-sdk/blob/HEAD/./reference.md).
20
+ A full reference for this library is available [here](./reference.md).
21
21
 
22
22
  ## Usage
23
23
 
@@ -25,12 +25,24 @@ Instantiate and use the client with the following:
25
25
 
26
26
  ```python
27
27
  from sync import Sync
28
+ from sync.common import Audio, GenerationOptions, Video
28
29
 
29
30
  client = Sync(
30
31
  api_key="YOUR_API_KEY",
31
32
  )
32
- client.batch.create(
33
- dry_run=True,
33
+ client.generations.create(
34
+ input=[
35
+ Video(
36
+ url="https://assets.sync.so/docs/example-video.mp4",
37
+ ),
38
+ Audio(
39
+ url="https://assets.sync.so/docs/example-audio.wav",
40
+ ),
41
+ ],
42
+ model="lipsync-2",
43
+ options=GenerationOptions(
44
+ sync_mode="loop",
45
+ ),
34
46
  )
35
47
  ```
36
48
 
@@ -42,6 +54,7 @@ The SDK also exports an `async` client so that you can make non-blocking calls t
42
54
  import asyncio
43
55
 
44
56
  from sync import AsyncSync
57
+ from sync.common import Audio, GenerationOptions, Video
45
58
 
46
59
  client = AsyncSync(
47
60
  api_key="YOUR_API_KEY",
@@ -49,8 +62,19 @@ client = AsyncSync(
49
62
 
50
63
 
51
64
  async def main() -> None:
52
- await client.batch.create(
53
- dry_run=True,
65
+ await client.generations.create(
66
+ input=[
67
+ Video(
68
+ url="https://assets.sync.so/docs/example-video.mp4",
69
+ ),
70
+ Audio(
71
+ url="https://assets.sync.so/docs/example-audio.wav",
72
+ ),
73
+ ],
74
+ model="lipsync-2",
75
+ options=GenerationOptions(
76
+ sync_mode="loop",
77
+ ),
54
78
  )
55
79
 
56
80
 
@@ -66,7 +90,7 @@ will be thrown.
66
90
  from sync.core.api_error import ApiError
67
91
 
68
92
  try:
69
- client.batch.create(...)
93
+ client.generations.create(...)
70
94
  except ApiError as e:
71
95
  print(e.status_code)
72
96
  print(e.body)
@@ -89,7 +113,7 @@ A request is deemed retryable when any of the following HTTP status codes is ret
89
113
  Use the `max_retries` request option to configure this behavior.
90
114
 
91
115
  ```python
92
- client.batch.create(..., request_options={
116
+ client.generations.create(..., request_options={
93
117
  "max_retries": 1
94
118
  })
95
119
  ```
@@ -109,7 +133,7 @@ client = Sync(
109
133
 
110
134
 
111
135
  # Override timeout for a specific method
112
- client.batch.create(..., request_options={
136
+ client.generations.create(..., request_options={
113
137
  "timeout_in_seconds": 1
114
138
  })
115
139
  ```
@@ -3,7 +3,7 @@ name = "syncsdk"
3
3
 
4
4
  [tool.poetry]
5
5
  name = "syncsdk"
6
- version = "0.2.0"
6
+ version = "0.2.1"
7
7
  description = ""
8
8
  readme = "README.md"
9
9
  authors = []
@@ -14,10 +14,10 @@ class BaseClientWrapper:
14
14
 
15
15
  def get_headers(self) -> typing.Dict[str, str]:
16
16
  headers: typing.Dict[str, str] = {
17
- "User-Agent": "syncsdk/0.2.0",
17
+ "User-Agent": "syncsdk/0.2.1",
18
18
  "X-Fern-Language": "Python",
19
19
  "X-Fern-SDK-Name": "syncsdk",
20
- "X-Fern-SDK-Version": "0.2.0",
20
+ "X-Fern-SDK-Version": "0.2.1",
21
21
  }
22
22
  headers["x-api-key"] = self.api_key
23
23
  return headers
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes