@@ -159,6 +159,7 @@ with Polar() as polar:
159159 " key" : False ,
160160 " key1" : False ,
161161 },
162+ external_customer_id = None ,
162163 customer_external_id = " <id>" ,
163164 products = [
164165 polar_sdk.CheckoutProduct(
@@ -172,14 +173,7 @@ with Polar() as polar:
172173 is_archived = True ,
173174 organization_id = " <value>" ,
174175 prices = [
175- polar_sdk.LegacyRecurringProductPriceFree(
176- created_at = parse_datetime(" 2023-09-13T08:36:46.434Z" ),
177- modified_at = parse_datetime(" 2023-10-05T12:55:46.428Z" ),
178- id = " <value>" ,
179- is_archived = False ,
180- product_id = " <value>" ,
181- recurring_interval = polar_sdk.SubscriptionRecurringInterval.MONTH ,
182- ),
176+ polar_sdk.LegacyRecurringProductPriceFree(),
183177 ],
184178 benefits = [],
185179 medias = [
@@ -251,37 +245,9 @@ with Polar() as polar:
251245 is_archived = False ,
252246 organization_id = " <value>" ,
253247 prices = [
254- polar_sdk.ProductPriceFixed(
255- created_at = parse_datetime(" 2024-05-02T18:25:33.974Z" ),
256- modified_at = parse_datetime(" 2025-02-06T12:55:07.640Z" ),
257- id = " <value>" ,
258- is_archived = False ,
259- product_id = " <value>" ,
260- type = polar_sdk.ProductPriceType.RECURRING ,
261- recurring_interval = polar_sdk.SubscriptionRecurringInterval.MONTH ,
262- price_currency = " <value>" ,
263- price_amount = 115799 ,
264- ),
265- polar_sdk.LegacyRecurringProductPriceCustom(
266- created_at = parse_datetime(" 2025-07-31T12:54:47.590Z" ),
267- modified_at = parse_datetime(" 2023-01-11T22:31:47.320Z" ),
268- id = " <value>" ,
269- is_archived = True ,
270- product_id = " <value>" ,
271- recurring_interval = polar_sdk.SubscriptionRecurringInterval.MONTH ,
272- price_currency = " <value>" ,
273- minimum_amount = 203013 ,
274- maximum_amount = None ,
275- preset_amount = 119260 ,
276- ),
277- polar_sdk.LegacyRecurringProductPriceFree(
278- created_at = parse_datetime(" 2024-04-06T18:48:21.449Z" ),
279- modified_at = None ,
280- id = " <value>" ,
281- is_archived = True ,
282- product_id = " <value>" ,
283- recurring_interval = polar_sdk.SubscriptionRecurringInterval.YEAR ,
284- ),
248+ polar_sdk.LegacyRecurringProductPriceCustom(),
249+ polar_sdk.LegacyRecurringProductPriceCustom(),
250+ polar_sdk.ProductPriceMeteredUnit(),
285251 ],
286252 benefits = [
287253 polar_sdk.BenefitPublic(
@@ -307,14 +273,7 @@ with Polar() as polar:
307273 ],
308274 medias = [],
309275 ),
310- product_price = polar_sdk.LegacyRecurringProductPriceFree(
311- created_at = parse_datetime(" 2025-12-30T03:22:33.818Z" ),
312- modified_at = parse_datetime(" 2025-07-13T15:35:24.219Z" ),
313- id = " <value>" ,
314- is_archived = False ,
315- product_id = " <value>" ,
316- recurring_interval = polar_sdk.SubscriptionRecurringInterval.YEAR ,
317- ),
276+ product_price = polar_sdk.ProductPriceMeteredUnit(),
318277 discount = polar_sdk.CheckoutDiscountPercentageRepeatDuration(
319278 duration = polar_sdk.DiscountDuration.REPEATING ,
320279 duration_in_months = 470604 ,
@@ -442,6 +401,7 @@ async def main():
442401 " key" : False ,
443402 " key1" : False ,
444403 },
404+ external_customer_id = None ,
445405 customer_external_id = " <id>" ,
446406 products = [
447407 polar_sdk.CheckoutProduct(
@@ -455,23 +415,7 @@ async def main():
455415 is_archived = True ,
456416 organization_id = " <value>" ,
457417 prices = [
458- polar_sdk.ProductPriceMeteredUnit(
459- created_at = parse_datetime(" 2023-12-22T12:14:26.730Z" ),
460- modified_at = parse_datetime(" 2023-08-19T20:45:43.750Z" ),
461- id = " <value>" ,
462- is_archived = True ,
463- product_id = " <value>" ,
464- type = polar_sdk.ProductPriceType.RECURRING ,
465- recurring_interval = polar_sdk.SubscriptionRecurringInterval.YEAR ,
466- price_currency = " <value>" ,
467- unit_amount = " <value>" ,
468- cap_amount = 217361 ,
469- meter_id = " <value>" ,
470- meter = polar_sdk.ProductPriceMeter(
471- id = " <value>" ,
472- name = " <value>" ,
473- ),
474- ),
418+ polar_sdk.LegacyRecurringProductPriceFree(),
475419 ],
476420 benefits = [],
477421 medias = [
@@ -543,45 +487,9 @@ async def main():
543487 is_archived = False ,
544488 organization_id = " <value>" ,
545489 prices = [
546- polar_sdk.ProductPriceMeteredUnit(
547- created_at = parse_datetime(" 2024-08-14T07:06:25.139Z" ),
548- modified_at = parse_datetime(" 2025-03-27T15:59:30.223Z" ),
549- id = " <value>" ,
550- is_archived = True ,
551- product_id = " <value>" ,
552- type = polar_sdk.ProductPriceType.RECURRING ,
553- recurring_interval = polar_sdk.SubscriptionRecurringInterval.YEAR ,
554- price_currency = " <value>" ,
555- unit_amount = " <value>" ,
556- cap_amount = 1655 ,
557- meter_id = " <value>" ,
558- meter = polar_sdk.ProductPriceMeter(
559- id = " <value>" ,
560- name = " <value>" ,
561- ),
562- ),
563- polar_sdk.LegacyRecurringProductPriceCustom(
564- created_at = parse_datetime(" 2024-08-02T17:12:30.950Z" ),
565- modified_at = None ,
566- id = " <value>" ,
567- is_archived = False ,
568- product_id = " <value>" ,
569- recurring_interval = polar_sdk.SubscriptionRecurringInterval.MONTH ,
570- price_currency = " <value>" ,
571- minimum_amount = 503938 ,
572- maximum_amount = 590205 ,
573- preset_amount = 329003 ,
574- ),
575- polar_sdk.LegacyRecurringProductPriceFixed(
576- created_at = parse_datetime(" 2024-07-20T01:39:43.676Z" ),
577- modified_at = parse_datetime(" 2025-09-16T11:22:24.287Z" ),
578- id = " <value>" ,
579- is_archived = False ,
580- product_id = " <value>" ,
581- recurring_interval = polar_sdk.SubscriptionRecurringInterval.YEAR ,
582- price_currency = " <value>" ,
583- price_amount = 862607 ,
584- ),
490+ polar_sdk.ProductPriceFixed(),
491+ polar_sdk.ProductPriceMeteredUnit(),
492+ polar_sdk.ProductPriceCustom(),
585493 ],
586494 benefits = [
587495 polar_sdk.BenefitPublic(
@@ -607,19 +515,7 @@ async def main():
607515 ],
608516 medias = [],
609517 ),
610- product_price = polar_sdk.ProductPriceCustom(
611- created_at = parse_datetime(" 2023-08-10T00:19:46.209Z" ),
612- modified_at = parse_datetime(" 2024-03-20T15:17:56.967Z" ),
613- id = " <value>" ,
614- is_archived = False ,
615- product_id = " <value>" ,
616- type = polar_sdk.ProductPriceType.ONE_TIME ,
617- recurring_interval = polar_sdk.SubscriptionRecurringInterval.YEAR ,
618- price_currency = " <value>" ,
619- minimum_amount = 861966 ,
620- maximum_amount = 196630 ,
621- preset_amount = None ,
622- ),
518+ product_price = polar_sdk.LegacyRecurringProductPriceFixed(),
623519 discount = polar_sdk.CheckoutDiscountPercentageRepeatDuration(
624520 duration = polar_sdk.DiscountDuration.REPEATING ,
625521 duration_in_months = 470604 ,
0 commit comments