dub 0.27.1__py3-none-any.whl → 0.27.3__py3-none-any.whl

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 (38) hide show
  1. dub/_version.py +3 -3
  2. dub/models/components/__init__.py +41 -2
  3. dub/models/components/analyticstriggers.py +2 -0
  4. dub/models/components/clickevent.py +92 -47
  5. dub/models/components/commissioncreatedevent.py +281 -0
  6. dub/models/components/leadcreatedevent.py +66 -21
  7. dub/models/components/leadevent.py +126 -48
  8. dub/models/components/linkclickedevent.py +66 -21
  9. dub/models/components/linkschema.py +26 -20
  10. dub/models/components/linkwebhookevent.py +33 -21
  11. dub/models/components/partnerenrolledevent.py +207 -80
  12. dub/models/components/salecreatedevent.py +66 -21
  13. dub/models/components/saleevent.py +206 -122
  14. dub/models/components/webhookevent.py +6 -0
  15. dub/models/errors/__init__.py +3 -2
  16. dub/models/operations/__init__.py +71 -2
  17. dub/models/operations/bulkcreatelinks.py +25 -25
  18. dub/models/operations/bulkupdatelinks.py +25 -25
  19. dub/models/operations/createlink.py +25 -25
  20. dub/models/operations/createpartner.py +207 -80
  21. dub/models/operations/getlinks.py +2 -2
  22. dub/models/operations/getlinkscount.py +2 -2
  23. dub/models/operations/listcommissions.py +169 -8
  24. dub/models/operations/listevents.py +48 -20
  25. dub/models/operations/listpartners.py +516 -0
  26. dub/models/operations/retrieveanalytics.py +48 -20
  27. dub/models/operations/retrievelinks.py +6 -6
  28. dub/models/operations/tracksale.py +1 -0
  29. dub/models/operations/updatecommission.py +169 -8
  30. dub/models/operations/updatelink.py +25 -25
  31. dub/models/operations/upsertlink.py +25 -25
  32. dub/partners.py +262 -0
  33. dub/sdk.py +1 -1
  34. dub/utils/__init__.py +3 -2
  35. {dub-0.27.1.dist-info → dub-0.27.3.dist-info}/METADATA +3 -2
  36. {dub-0.27.1.dist-info → dub-0.27.3.dist-info}/RECORD +38 -36
  37. {dub-0.27.1.dist-info → dub-0.27.3.dist-info}/LICENSE +0 -0
  38. {dub-0.27.1.dist-info → dub-0.27.3.dist-info}/WHEEL +0 -0
@@ -840,8 +840,6 @@ class LinkWebhookEventLinkTypedDict(TypedDict):
840
840
  geo: Nullable[LinkWebhookEventGeoTypedDict]
841
841
  r"""Geo targeting information for the short link in JSON format `{[COUNTRY]: https://example.com }`. Learn more: https://d.to/geo"""
842
842
  public_stats: bool
843
- tag_id: Nullable[str]
844
- r"""The unique ID of the tag assigned to the short link. This field is deprecated – use `tags` instead."""
845
843
  tags: Nullable[List[TagSchemaTypedDict]]
846
844
  r"""The tags assigned to the short link."""
847
845
  folder_id: Nullable[str]
@@ -872,18 +870,22 @@ class LinkWebhookEventLinkTypedDict(TypedDict):
872
870
  last_clicked: str
873
871
  created_at: str
874
872
  updated_at: str
873
+ tag_id: Nullable[str]
874
+ r"""Deprecated: Use `tags` instead. The unique ID of the tag assigned to the short link."""
875
875
  project_id: str
876
- r"""The project ID of the short link. This field is deprecated – use `workspaceId` instead."""
876
+ r"""Deprecated: Use `workspaceId` instead. The project ID of the short link."""
877
877
  test_variants: NotRequired[Nullable[List[LinkWebhookEventTestVariantsTypedDict]]]
878
878
  r"""An array of A/B test URLs and the percentage of traffic to send to each URL."""
879
879
  clicks: NotRequired[float]
880
880
  r"""The number of clicks on the short link."""
881
881
  leads: NotRequired[float]
882
- r"""The number of leads the short links has generated."""
882
+ r"""The number of leads the short link has generated."""
883
+ conversions: NotRequired[float]
884
+ r"""The number of leads that converted to paying customers."""
883
885
  sales: NotRequired[float]
884
- r"""The number of sales the short links has generated."""
886
+ r"""The total number of sales (includes recurring sales) generated by the short link."""
885
887
  sale_amount: NotRequired[float]
886
- r"""The total dollar amount of sales the short links has generated (in cents)."""
888
+ r"""The total dollar value of sales (in cents) generated by the short link."""
887
889
 
888
890
 
889
891
  class LinkWebhookEventLink(BaseModel):
@@ -950,15 +952,6 @@ class LinkWebhookEventLink(BaseModel):
950
952
 
951
953
  public_stats: Annotated[bool, pydantic.Field(alias="publicStats")]
952
954
 
953
- tag_id: Annotated[
954
- Nullable[str],
955
- pydantic.Field(
956
- deprecated="warning: ** DEPRECATED ** - This will be removed in a future release, please migrate away from it as soon as possible.",
957
- alias="tagId",
958
- ),
959
- ]
960
- r"""The unique ID of the tag assigned to the short link. This field is deprecated – use `tags` instead."""
961
-
962
955
  tags: Nullable[List[TagSchema]]
963
956
  r"""The tags assigned to the short link."""
964
957
 
@@ -1007,6 +1000,15 @@ class LinkWebhookEventLink(BaseModel):
1007
1000
 
1008
1001
  updated_at: Annotated[str, pydantic.Field(alias="updatedAt")]
1009
1002
 
1003
+ tag_id: Annotated[
1004
+ Nullable[str],
1005
+ pydantic.Field(
1006
+ deprecated="warning: ** DEPRECATED ** - This will be removed in a future release, please migrate away from it as soon as possible.",
1007
+ alias="tagId",
1008
+ ),
1009
+ ]
1010
+ r"""Deprecated: Use `tags` instead. The unique ID of the tag assigned to the short link."""
1011
+
1010
1012
  project_id: Annotated[
1011
1013
  str,
1012
1014
  pydantic.Field(
@@ -1014,7 +1016,7 @@ class LinkWebhookEventLink(BaseModel):
1014
1016
  alias="projectId",
1015
1017
  ),
1016
1018
  ]
1017
- r"""The project ID of the short link. This field is deprecated – use `workspaceId` instead."""
1019
+ r"""Deprecated: Use `workspaceId` instead. The project ID of the short link."""
1018
1020
 
1019
1021
  test_variants: Annotated[
1020
1022
  OptionalNullable[List[LinkWebhookEventTestVariants]],
@@ -1026,17 +1028,27 @@ class LinkWebhookEventLink(BaseModel):
1026
1028
  r"""The number of clicks on the short link."""
1027
1029
 
1028
1030
  leads: Optional[float] = 0
1029
- r"""The number of leads the short links has generated."""
1031
+ r"""The number of leads the short link has generated."""
1032
+
1033
+ conversions: Optional[float] = 0
1034
+ r"""The number of leads that converted to paying customers."""
1030
1035
 
1031
1036
  sales: Optional[float] = 0
1032
- r"""The number of sales the short links has generated."""
1037
+ r"""The total number of sales (includes recurring sales) generated by the short link."""
1033
1038
 
1034
1039
  sale_amount: Annotated[Optional[float], pydantic.Field(alias="saleAmount")] = 0
1035
- r"""The total dollar amount of sales the short links has generated (in cents)."""
1040
+ r"""The total dollar value of sales (in cents) generated by the short link."""
1036
1041
 
1037
1042
  @model_serializer(mode="wrap")
1038
1043
  def serialize_model(self, handler):
1039
- optional_fields = ["testVariants", "clicks", "leads", "sales", "saleAmount"]
1044
+ optional_fields = [
1045
+ "testVariants",
1046
+ "clicks",
1047
+ "leads",
1048
+ "conversions",
1049
+ "sales",
1050
+ "saleAmount",
1051
+ ]
1040
1052
  nullable_fields = [
1041
1053
  "externalId",
1042
1054
  "tenantId",
@@ -1051,7 +1063,6 @@ class LinkWebhookEventLink(BaseModel):
1051
1063
  "ios",
1052
1064
  "android",
1053
1065
  "geo",
1054
- "tagId",
1055
1066
  "tags",
1056
1067
  "folderId",
1057
1068
  "comments",
@@ -1064,6 +1075,7 @@ class LinkWebhookEventLink(BaseModel):
1064
1075
  "testStartedAt",
1065
1076
  "testCompletedAt",
1066
1077
  "userId",
1078
+ "tagId",
1067
1079
  ]
1068
1080
  null_default_fields = []
1069
1081
 
@@ -39,11 +39,11 @@ class PartnerEnrolledEventLinkTypedDict(TypedDict):
39
39
  clicks: NotRequired[float]
40
40
  r"""The number of clicks on the short link."""
41
41
  leads: NotRequired[float]
42
- r"""The number of leads the short links has generated."""
42
+ r"""The number of leads the short link has generated."""
43
43
  sales: NotRequired[float]
44
- r"""The number of sales the short links has generated."""
44
+ r"""The total number of sales (includes recurring sales) generated by the short link."""
45
45
  sale_amount: NotRequired[float]
46
- r"""The total dollar amount of sales the short links has generated (in cents)."""
46
+ r"""The total dollar value of sales (in cents) generated by the short link."""
47
47
 
48
48
 
49
49
  class PartnerEnrolledEventLink(BaseModel):
@@ -66,13 +66,24 @@ class PartnerEnrolledEventLink(BaseModel):
66
66
  r"""The number of clicks on the short link."""
67
67
 
68
68
  leads: Optional[float] = 0
69
- r"""The number of leads the short links has generated."""
69
+ r"""The number of leads the short link has generated."""
70
70
 
71
71
  sales: Optional[float] = 0
72
- r"""The number of sales the short links has generated."""
72
+ r"""The total number of sales (includes recurring sales) generated by the short link."""
73
73
 
74
74
  sale_amount: Annotated[Optional[float], pydantic.Field(alias="saleAmount")] = 0
75
- r"""The total dollar amount of sales the short links has generated (in cents)."""
75
+ r"""The total dollar value of sales (in cents) generated by the short link."""
76
+
77
+
78
+ class BannedReason(str, Enum):
79
+ r"""If the partner was banned from the program, this is the reason for the ban."""
80
+
81
+ TOS_VIOLATION = "tos_violation"
82
+ INAPPROPRIATE_CONTENT = "inappropriate_content"
83
+ FAKE_TRAFFIC = "fake_traffic"
84
+ FRAUD = "fraud"
85
+ SPAM = "spam"
86
+ BRAND_ABUSE = "brand_abuse"
76
87
 
77
88
 
78
89
  class PartnerEnrolledEventDataTypedDict(TypedDict):
@@ -86,50 +97,68 @@ class PartnerEnrolledEventDataTypedDict(TypedDict):
86
97
  r"""The partner's avatar image."""
87
98
  country: Nullable[str]
88
99
  r"""The partner's country (required for tax purposes)."""
89
- website: Nullable[str]
90
- r"""The partner's website URL (including the https protocol)."""
91
- youtube: Nullable[str]
92
- r"""The partner's YouTube channel username (e.g. `johndoe`)."""
93
- twitter: Nullable[str]
94
- r"""The partner's Twitter username (e.g. `johndoe`)."""
95
- linkedin: Nullable[str]
96
- r"""The partner's LinkedIn username (e.g. `johndoe`)."""
97
- instagram: Nullable[str]
98
- r"""The partner's Instagram username (e.g. `johndoe`)."""
99
- tiktok: Nullable[str]
100
- r"""The partner's TikTok username (e.g. `johndoe`)."""
101
100
  paypal_email: Nullable[str]
102
101
  r"""The partner's PayPal email (for receiving payouts via PayPal)."""
103
102
  stripe_connect_id: Nullable[str]
104
103
  r"""The partner's Stripe Connect ID (for receiving payouts via Stripe)."""
105
104
  payouts_enabled_at: Nullable[str]
106
105
  r"""The date when the partner enabled payouts."""
106
+ partner_id: str
107
+ r"""The partner's unique ID on Dub."""
108
+ tenant_id: Nullable[str]
109
+ r"""The partner's unique ID within your database. Can be useful for associating the partner with a user in your database and retrieving/update their data in the future."""
110
+ program_id: str
111
+ r"""The program's unique ID on Dub."""
107
112
  created_at: str
108
- r"""The date when the partner was created on Dub."""
109
113
  status: Status
110
114
  r"""The status of the partner's enrollment in the program."""
111
- program_id: str
112
- r"""The program's unique ID on Dub."""
113
- tenant_id: Nullable[str]
114
- r"""The partner's unique ID within your database. Can be useful for associating the partner with a user in your database and retrieving/update their data in the future."""
115
115
  links: Nullable[List[PartnerEnrolledEventLinkTypedDict]]
116
116
  r"""The partner's referral links in this program."""
117
117
  description: NotRequired[Nullable[str]]
118
118
  r"""A brief description of the partner and their background."""
119
+ total_commissions: NotRequired[float]
120
+ r"""The total commissions paid to the partner for their referrals. Defaults to 0 if `includeExpandedFields` is false."""
121
+ click_reward_id: NotRequired[Nullable[str]]
122
+ lead_reward_id: NotRequired[Nullable[str]]
123
+ sale_reward_id: NotRequired[Nullable[str]]
124
+ discount_id: NotRequired[Nullable[str]]
125
+ application_id: NotRequired[Nullable[str]]
126
+ r"""If the partner submitted an application to join the program, this is the ID of the application."""
127
+ banned_at: NotRequired[Nullable[str]]
128
+ r"""If the partner was banned from the program, this is the date of the ban."""
129
+ banned_reason: NotRequired[Nullable[BannedReason]]
130
+ r"""If the partner was banned from the program, this is the reason for the ban."""
119
131
  clicks: NotRequired[float]
120
- r"""The total number of clicks on the partner's links."""
132
+ r"""The total number of clicks on the partner's links. Defaults to 0 if `includeExpandedFields` is false."""
121
133
  leads: NotRequired[float]
122
- r"""The total number of leads generated by the partner's links."""
134
+ r"""The total number of leads generated by the partner's links. Defaults to 0 if `includeExpandedFields` is false."""
123
135
  sales: NotRequired[float]
124
- r"""The total number of sales generated by the partner's links."""
136
+ r"""The total number of sales generated by the partner's links. Defaults to 0 if `includeExpandedFields` is false."""
125
137
  sale_amount: NotRequired[float]
126
- r"""The total amount of sales (in cents) generated by the partner's links."""
127
- total_commissions: NotRequired[float]
128
- r"""The total commissions paid to the partner for their referrals."""
138
+ r"""The total amount of sales (in cents) generated by the partner's links. Defaults to 0 if `includeExpandedFields` is false."""
129
139
  net_revenue: NotRequired[float]
130
- r"""The total net revenue generated by the partner."""
131
- earnings: NotRequired[float]
132
- r"""DEPRECATED: The total earnings/commissions accrued by the partner's links."""
140
+ r"""The total net revenue generated by the partner. Defaults to 0 if `includeExpandedFields` is false."""
141
+ website: NotRequired[Nullable[str]]
142
+ r"""The partner's website URL (including the https protocol)."""
143
+ website_txt_record: NotRequired[Nullable[str]]
144
+ website_verified_at: NotRequired[Nullable[str]]
145
+ youtube: NotRequired[Nullable[str]]
146
+ r"""The partner's YouTube channel username (e.g. `johndoe`)."""
147
+ youtube_verified_at: NotRequired[Nullable[str]]
148
+ youtube_subscriber_count: NotRequired[Nullable[float]]
149
+ youtube_view_count: NotRequired[Nullable[float]]
150
+ twitter: NotRequired[Nullable[str]]
151
+ r"""The partner's Twitter username (e.g. `johndoe`)."""
152
+ twitter_verified_at: NotRequired[Nullable[str]]
153
+ linkedin: NotRequired[Nullable[str]]
154
+ r"""The partner's LinkedIn username (e.g. `johndoe`)."""
155
+ linkedin_verified_at: NotRequired[Nullable[str]]
156
+ instagram: NotRequired[Nullable[str]]
157
+ r"""The partner's Instagram username (e.g. `johndoe`)."""
158
+ instagram_verified_at: NotRequired[Nullable[str]]
159
+ tiktok: NotRequired[Nullable[str]]
160
+ r"""The partner's TikTok username (e.g. `johndoe`)."""
161
+ tiktok_verified_at: NotRequired[Nullable[str]]
133
162
 
134
163
 
135
164
  class PartnerEnrolledEventData(BaseModel):
@@ -148,24 +177,6 @@ class PartnerEnrolledEventData(BaseModel):
148
177
  country: Nullable[str]
149
178
  r"""The partner's country (required for tax purposes)."""
150
179
 
151
- website: Nullable[str]
152
- r"""The partner's website URL (including the https protocol)."""
153
-
154
- youtube: Nullable[str]
155
- r"""The partner's YouTube channel username (e.g. `johndoe`)."""
156
-
157
- twitter: Nullable[str]
158
- r"""The partner's Twitter username (e.g. `johndoe`)."""
159
-
160
- linkedin: Nullable[str]
161
- r"""The partner's LinkedIn username (e.g. `johndoe`)."""
162
-
163
- instagram: Nullable[str]
164
- r"""The partner's Instagram username (e.g. `johndoe`)."""
165
-
166
- tiktok: Nullable[str]
167
- r"""The partner's TikTok username (e.g. `johndoe`)."""
168
-
169
180
  paypal_email: Annotated[Nullable[str], pydantic.Field(alias="paypalEmail")]
170
181
  r"""The partner's PayPal email (for receiving payouts via PayPal)."""
171
182
 
@@ -177,17 +188,19 @@ class PartnerEnrolledEventData(BaseModel):
177
188
  ]
178
189
  r"""The date when the partner enabled payouts."""
179
190
 
180
- created_at: Annotated[str, pydantic.Field(alias="createdAt")]
181
- r"""The date when the partner was created on Dub."""
191
+ partner_id: Annotated[str, pydantic.Field(alias="partnerId")]
192
+ r"""The partner's unique ID on Dub."""
182
193
 
183
- status: Status
184
- r"""The status of the partner's enrollment in the program."""
194
+ tenant_id: Annotated[Nullable[str], pydantic.Field(alias="tenantId")]
195
+ r"""The partner's unique ID within your database. Can be useful for associating the partner with a user in your database and retrieving/update their data in the future."""
185
196
 
186
197
  program_id: Annotated[str, pydantic.Field(alias="programId")]
187
198
  r"""The program's unique ID on Dub."""
188
199
 
189
- tenant_id: Annotated[Nullable[str], pydantic.Field(alias="tenantId")]
190
- r"""The partner's unique ID within your database. Can be useful for associating the partner with a user in your database and retrieving/update their data in the future."""
200
+ created_at: Annotated[str, pydantic.Field(alias="createdAt")]
201
+
202
+ status: Status
203
+ r"""The status of the partner's enrollment in the program."""
191
204
 
192
205
  links: Nullable[List[PartnerEnrolledEventLink]]
193
206
  r"""The partner's referral links in this program."""
@@ -195,62 +208,176 @@ class PartnerEnrolledEventData(BaseModel):
195
208
  description: OptionalNullable[str] = UNSET
196
209
  r"""A brief description of the partner and their background."""
197
210
 
211
+ total_commissions: Annotated[
212
+ Optional[float], pydantic.Field(alias="totalCommissions")
213
+ ] = 0
214
+ r"""The total commissions paid to the partner for their referrals. Defaults to 0 if `includeExpandedFields` is false."""
215
+
216
+ click_reward_id: Annotated[
217
+ OptionalNullable[str], pydantic.Field(alias="clickRewardId")
218
+ ] = UNSET
219
+
220
+ lead_reward_id: Annotated[
221
+ OptionalNullable[str], pydantic.Field(alias="leadRewardId")
222
+ ] = UNSET
223
+
224
+ sale_reward_id: Annotated[
225
+ OptionalNullable[str], pydantic.Field(alias="saleRewardId")
226
+ ] = UNSET
227
+
228
+ discount_id: Annotated[
229
+ OptionalNullable[str], pydantic.Field(alias="discountId")
230
+ ] = UNSET
231
+
232
+ application_id: Annotated[
233
+ OptionalNullable[str], pydantic.Field(alias="applicationId")
234
+ ] = UNSET
235
+ r"""If the partner submitted an application to join the program, this is the ID of the application."""
236
+
237
+ banned_at: Annotated[OptionalNullable[str], pydantic.Field(alias="bannedAt")] = (
238
+ UNSET
239
+ )
240
+ r"""If the partner was banned from the program, this is the date of the ban."""
241
+
242
+ banned_reason: Annotated[
243
+ OptionalNullable[BannedReason], pydantic.Field(alias="bannedReason")
244
+ ] = UNSET
245
+ r"""If the partner was banned from the program, this is the reason for the ban."""
246
+
198
247
  clicks: Optional[float] = 0
199
- r"""The total number of clicks on the partner's links."""
248
+ r"""The total number of clicks on the partner's links. Defaults to 0 if `includeExpandedFields` is false."""
200
249
 
201
250
  leads: Optional[float] = 0
202
- r"""The total number of leads generated by the partner's links."""
251
+ r"""The total number of leads generated by the partner's links. Defaults to 0 if `includeExpandedFields` is false."""
203
252
 
204
253
  sales: Optional[float] = 0
205
- r"""The total number of sales generated by the partner's links."""
254
+ r"""The total number of sales generated by the partner's links. Defaults to 0 if `includeExpandedFields` is false."""
206
255
 
207
256
  sale_amount: Annotated[Optional[float], pydantic.Field(alias="saleAmount")] = 0
208
- r"""The total amount of sales (in cents) generated by the partner's links."""
209
-
210
- total_commissions: Annotated[
211
- Optional[float], pydantic.Field(alias="totalCommissions")
212
- ] = 0
213
- r"""The total commissions paid to the partner for their referrals."""
257
+ r"""The total amount of sales (in cents) generated by the partner's links. Defaults to 0 if `includeExpandedFields` is false."""
214
258
 
215
259
  net_revenue: Annotated[Optional[float], pydantic.Field(alias="netRevenue")] = 0
216
- r"""The total net revenue generated by the partner."""
260
+ r"""The total net revenue generated by the partner. Defaults to 0 if `includeExpandedFields` is false."""
217
261
 
218
- earnings: Annotated[
219
- Optional[float],
220
- pydantic.Field(
221
- deprecated="warning: ** DEPRECATED ** - This will be removed in a future release, please migrate away from it as soon as possible."
222
- ),
223
- ] = 0
224
- r"""DEPRECATED: The total earnings/commissions accrued by the partner's links."""
262
+ website: OptionalNullable[str] = UNSET
263
+ r"""The partner's website URL (including the https protocol)."""
264
+
265
+ website_txt_record: Annotated[
266
+ OptionalNullable[str], pydantic.Field(alias="websiteTxtRecord")
267
+ ] = UNSET
268
+
269
+ website_verified_at: Annotated[
270
+ OptionalNullable[str], pydantic.Field(alias="websiteVerifiedAt")
271
+ ] = UNSET
272
+
273
+ youtube: OptionalNullable[str] = UNSET
274
+ r"""The partner's YouTube channel username (e.g. `johndoe`)."""
275
+
276
+ youtube_verified_at: Annotated[
277
+ OptionalNullable[str], pydantic.Field(alias="youtubeVerifiedAt")
278
+ ] = UNSET
279
+
280
+ youtube_subscriber_count: Annotated[
281
+ OptionalNullable[float], pydantic.Field(alias="youtubeSubscriberCount")
282
+ ] = UNSET
283
+
284
+ youtube_view_count: Annotated[
285
+ OptionalNullable[float], pydantic.Field(alias="youtubeViewCount")
286
+ ] = UNSET
287
+
288
+ twitter: OptionalNullable[str] = UNSET
289
+ r"""The partner's Twitter username (e.g. `johndoe`)."""
290
+
291
+ twitter_verified_at: Annotated[
292
+ OptionalNullable[str], pydantic.Field(alias="twitterVerifiedAt")
293
+ ] = UNSET
294
+
295
+ linkedin: OptionalNullable[str] = UNSET
296
+ r"""The partner's LinkedIn username (e.g. `johndoe`)."""
297
+
298
+ linkedin_verified_at: Annotated[
299
+ OptionalNullable[str], pydantic.Field(alias="linkedinVerifiedAt")
300
+ ] = UNSET
301
+
302
+ instagram: OptionalNullable[str] = UNSET
303
+ r"""The partner's Instagram username (e.g. `johndoe`)."""
304
+
305
+ instagram_verified_at: Annotated[
306
+ OptionalNullable[str], pydantic.Field(alias="instagramVerifiedAt")
307
+ ] = UNSET
308
+
309
+ tiktok: OptionalNullable[str] = UNSET
310
+ r"""The partner's TikTok username (e.g. `johndoe`)."""
311
+
312
+ tiktok_verified_at: Annotated[
313
+ OptionalNullable[str], pydantic.Field(alias="tiktokVerifiedAt")
314
+ ] = UNSET
225
315
 
226
316
  @model_serializer(mode="wrap")
227
317
  def serialize_model(self, handler):
228
318
  optional_fields = [
229
319
  "description",
320
+ "totalCommissions",
321
+ "clickRewardId",
322
+ "leadRewardId",
323
+ "saleRewardId",
324
+ "discountId",
325
+ "applicationId",
326
+ "bannedAt",
327
+ "bannedReason",
230
328
  "clicks",
231
329
  "leads",
232
330
  "sales",
233
331
  "saleAmount",
234
- "totalCommissions",
235
332
  "netRevenue",
236
- "earnings",
333
+ "website",
334
+ "websiteTxtRecord",
335
+ "websiteVerifiedAt",
336
+ "youtube",
337
+ "youtubeVerifiedAt",
338
+ "youtubeSubscriberCount",
339
+ "youtubeViewCount",
340
+ "twitter",
341
+ "twitterVerifiedAt",
342
+ "linkedin",
343
+ "linkedinVerifiedAt",
344
+ "instagram",
345
+ "instagramVerifiedAt",
346
+ "tiktok",
347
+ "tiktokVerifiedAt",
237
348
  ]
238
349
  nullable_fields = [
239
350
  "email",
240
351
  "image",
241
352
  "description",
242
353
  "country",
354
+ "paypalEmail",
355
+ "stripeConnectId",
356
+ "payoutsEnabledAt",
357
+ "tenantId",
358
+ "links",
359
+ "clickRewardId",
360
+ "leadRewardId",
361
+ "saleRewardId",
362
+ "discountId",
363
+ "applicationId",
364
+ "bannedAt",
365
+ "bannedReason",
243
366
  "website",
367
+ "websiteTxtRecord",
368
+ "websiteVerifiedAt",
244
369
  "youtube",
370
+ "youtubeVerifiedAt",
371
+ "youtubeSubscriberCount",
372
+ "youtubeViewCount",
245
373
  "twitter",
374
+ "twitterVerifiedAt",
246
375
  "linkedin",
376
+ "linkedinVerifiedAt",
247
377
  "instagram",
378
+ "instagramVerifiedAt",
248
379
  "tiktok",
249
- "paypalEmail",
250
- "stripeConnectId",
251
- "payoutsEnabledAt",
252
- "tenantId",
253
- "links",
380
+ "tiktokVerifiedAt",
254
381
  ]
255
382
  null_default_fields = []
256
383