@@ -174,7 +174,7 @@ with Polar() as polar:
174174 prices = [
175175 polar_sdk.LegacyRecurringProductPriceFree(
176176 created_at = parse_datetime(" 2023-09-13T08:36:46.434Z" ),
177- modified_at = parse_datetime(" 2023-09-14T02:01:27.394Z " ),
177+ modified_at = parse_datetime(" 2023-10-05T12:55:46.428Z " ),
178178 id = " <value>" ,
179179 is_archived = False ,
180180 product_id = " <value>" ,
@@ -251,42 +251,37 @@ with Polar() as polar:
251251 is_archived = False ,
252252 organization_id = " <value>" ,
253253 prices = [
254- polar_sdk.ProductPriceCustom(
255- created_at = parse_datetime(" 2025-03-15T14:26:53.109Z" ),
256- modified_at = parse_datetime(" 2023-12-28T10:30:56.042Z" ),
257- id = " <value>" ,
258- is_archived = False ,
259- product_id = " <value>" ,
260- type = polar_sdk.ProductPriceType.ONE_TIME ,
261- recurring_interval = polar_sdk.SubscriptionRecurringInterval.YEAR ,
262- price_currency = " <value>" ,
263- minimum_amount = 700309 ,
264- maximum_amount = 631188 ,
265- preset_amount = 968968 ,
266- ),
267254 polar_sdk.ProductPriceFixed(
268- created_at = parse_datetime(" 2023 -05-07T21:58:39.365Z " ),
269- modified_at = parse_datetime(" 2024-04-23T21:54:44.503Z " ),
255+ created_at = parse_datetime(" 2024 -05-02T18:25:33.974Z " ),
256+ modified_at = parse_datetime(" 2025-02-06T12:55:07.640Z " ),
270257 id = " <value>" ,
271258 is_archived = False ,
272259 product_id = " <value>" ,
273- type = polar_sdk.ProductPriceType.ONE_TIME ,
274- recurring_interval = polar_sdk.SubscriptionRecurringInterval.YEAR ,
260+ type = polar_sdk.ProductPriceType.RECURRING ,
261+ recurring_interval = polar_sdk.SubscriptionRecurringInterval.MONTH ,
275262 price_currency = " <value>" ,
276- price_amount = 275553 ,
263+ price_amount = 115799 ,
277264 ),
278265 polar_sdk.LegacyRecurringProductPriceCustom(
279- created_at = parse_datetime(" 2023-08-08T15:45:51.732Z " ),
280- modified_at = parse_datetime(" 2024 -01-18T11:16:03.208Z " ),
266+ created_at = parse_datetime(" 2025-07-31T12:54:47.590Z " ),
267+ modified_at = parse_datetime(" 2023 -01-11T22:31:47.320Z " ),
281268 id = " <value>" ,
282- is_archived = False ,
269+ is_archived = True ,
283270 product_id = " <value>" ,
284271 recurring_interval = polar_sdk.SubscriptionRecurringInterval.MONTH ,
285272 price_currency = " <value>" ,
286- minimum_amount = 49018 ,
287- maximum_amount = 322400 ,
273+ minimum_amount = 203013 ,
274+ maximum_amount = None ,
288275 preset_amount = 119260 ,
289276 ),
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+ ),
290285 ],
291286 benefits = [
292287 polar_sdk.BenefitPublic(
@@ -313,12 +308,12 @@ with Polar() as polar:
313308 medias = [],
314309 ),
315310 product_price = polar_sdk.LegacyRecurringProductPriceFree(
316- created_at = parse_datetime(" 2024-04-06T18:48:21.449Z " ),
317- modified_at = parse_datetime(" 2023-02-22T08:13:16.795Z " ),
311+ created_at = parse_datetime(" 2025-12-30T03:22:33.818Z " ),
312+ modified_at = parse_datetime(" 2025-07-13T15:35:24.219Z " ),
318313 id = " <value>" ,
319314 is_archived = False ,
320315 product_id = " <value>" ,
321- recurring_interval = polar_sdk.SubscriptionRecurringInterval.MONTH ,
316+ recurring_interval = polar_sdk.SubscriptionRecurringInterval.YEAR ,
322317 ),
323318 discount = polar_sdk.CheckoutDiscountPercentageRepeatDuration(
324319 duration = polar_sdk.DiscountDuration.REPEATING ,
@@ -460,18 +455,22 @@ async def main():
460455 is_archived = True ,
461456 organization_id = " <value>" ,
462457 prices = [
463- polar_sdk.ProductPriceCustom (
464- created_at = parse_datetime(" 2025-11-30T03:33:51.498Z " ),
465- modified_at = parse_datetime(" 2025-12-30T03:22:33.818Z " ),
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 " ),
466461 id = " <value>" ,
467- is_archived = False ,
462+ is_archived = True ,
468463 product_id = " <value>" ,
469464 type = polar_sdk.ProductPriceType.RECURRING ,
470465 recurring_interval = polar_sdk.SubscriptionRecurringInterval.YEAR ,
471466 price_currency = " <value>" ,
472- minimum_amount = 707018 ,
473- maximum_amount = 818126 ,
474- preset_amount = 919230 ,
467+ unit_amount = " <value>" ,
468+ cap_amount = 217361 ,
469+ meter_id = " <value>" ,
470+ meter = polar_sdk.ProductPriceMeter(
471+ id = " <value>" ,
472+ name = " <value>" ,
473+ ),
475474 ),
476475 ],
477476 benefits = [],
@@ -544,46 +543,44 @@ async def main():
544543 is_archived = False ,
545544 organization_id = " <value>" ,
546545 prices = [
547- polar_sdk.ProductPriceFixed(
548- created_at = parse_datetime(" 2025-07-23T17:21:51.405Z" ),
549- modified_at = parse_datetime(" 2023-08-19T20:45:43.750Z" ),
550- id = " <value>" ,
551- is_archived = False ,
552- product_id = " <value>" ,
553- type = polar_sdk.ProductPriceType.ONE_TIME ,
554- recurring_interval = polar_sdk.SubscriptionRecurringInterval.YEAR ,
555- price_currency = " <value>" ,
556- price_amount = 343341 ,
557- ),
558546 polar_sdk.ProductPriceMeteredUnit(
559- created_at = parse_datetime(" 2023 -08-27T05:27:45.548Z " ),
560- modified_at = parse_datetime(" 2024-10-10T19:54:32.262Z " ),
547+ created_at = parse_datetime(" 2024 -08-14T07:06:25.139Z " ),
548+ modified_at = parse_datetime(" 2025-03-27T15:59:30.223Z " ),
561549 id = " <value>" ,
562- is_archived = False ,
550+ is_archived = True ,
563551 product_id = " <value>" ,
564552 type = polar_sdk.ProductPriceType.RECURRING ,
565553 recurring_interval = polar_sdk.SubscriptionRecurringInterval.YEAR ,
566554 price_currency = " <value>" ,
567555 unit_amount = " <value>" ,
568- cap_amount = 307323 ,
556+ cap_amount = 1655 ,
569557 meter_id = " <value>" ,
570558 meter = polar_sdk.ProductPriceMeter(
571559 id = " <value>" ,
572560 name = " <value>" ,
573561 ),
574562 ),
575- polar_sdk.ProductPriceCustom(
576- created_at = parse_datetime(" 2024-11-01T10:50:02.209Z" ),
577- modified_at = parse_datetime(" 2025-01-10T17:02:02.724Z" ),
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" ),
578578 id = " <value>" ,
579579 is_archived = False ,
580580 product_id = " <value>" ,
581- type = polar_sdk.ProductPriceType.RECURRING ,
582581 recurring_interval = polar_sdk.SubscriptionRecurringInterval.YEAR ,
583582 price_currency = " <value>" ,
584- minimum_amount = 1655 ,
585- maximum_amount = 296598 ,
586- preset_amount = 138362 ,
583+ price_amount = 862607 ,
587584 ),
588585 ],
589586 benefits = [
@@ -611,17 +608,17 @@ async def main():
611608 medias = [],
612609 ),
613610 product_price = polar_sdk.ProductPriceCustom(
614- created_at = parse_datetime(" 2025-12-06T17:46:23.813Z " ),
615- modified_at = parse_datetime(" 2024-05-28T21:42:41.690Z " ),
611+ created_at = parse_datetime(" 2023-08-10T00:19:46.209Z " ),
612+ modified_at = parse_datetime(" 2024-03-20T15:17:56.967Z " ),
616613 id = " <value>" ,
617614 is_archived = False ,
618615 product_id = " <value>" ,
619616 type = polar_sdk.ProductPriceType.ONE_TIME ,
620617 recurring_interval = polar_sdk.SubscriptionRecurringInterval.YEAR ,
621618 price_currency = " <value>" ,
622- minimum_amount = 323388 ,
623- maximum_amount = 590205 ,
624- preset_amount = 785567 ,
619+ minimum_amount = 861966 ,
620+ maximum_amount = 196630 ,
621+ preset_amount = None ,
625622 ),
626623 discount = polar_sdk.CheckoutDiscountPercentageRepeatDuration(
627624 duration = polar_sdk.DiscountDuration.REPEATING ,
@@ -954,7 +951,7 @@ with Polar(
954951 access_token = " <YOUR_BEARER_TOKEN_HERE>" ,
955952) as polar:
956953
957- res = polar.organizations.list(,
954+ res = polar.organizations.list(page = 1 , limit = 10 ,
958955 RetryConfig(" backoff" , BackoffStrategy(1 , 50 , 1.1 , 100 ), False ))
959956
960957 while res is not None :
@@ -975,7 +972,7 @@ with Polar(
975972 access_token = " <YOUR_BEARER_TOKEN_HERE>" ,
976973) as polar:
977974
978- res = polar.organizations.list()
975+ res = polar.organizations.list(page = 1 , limit = 10 )
979976
980977 while res is not None :
981978 # Handle items
@@ -1018,7 +1015,7 @@ with Polar(
10181015 res = None
10191016 try :
10201017
1021- res = polar.organizations.list()
1018+ res = polar.organizations.list(page = 1 , limit = 10 )
10221019
10231020 while res is not None :
10241021 # Handle items
@@ -1057,7 +1054,7 @@ with Polar(
10571054 access_token = " <YOUR_BEARER_TOKEN_HERE>" ,
10581055) as polar:
10591056
1060- res = polar.organizations.list()
1057+ res = polar.organizations.list(page = 1 , limit = 10 )
10611058
10621059 while res is not None :
10631060 # Handle items
@@ -1078,7 +1075,7 @@ with Polar(
10781075 access_token = " <YOUR_BEARER_TOKEN_HERE>" ,
10791076) as polar:
10801077
1081- res = polar.organizations.list()
1078+ res = polar.organizations.list(page = 1 , limit = 10 )
10821079
10831080 while res is not None :
10841081 # Handle items
@@ -1189,7 +1186,7 @@ with Polar(
11891186 access_token = " <YOUR_BEARER_TOKEN_HERE>" ,
11901187) as polar:
11911188
1192- res = polar.organizations.list()
1189+ res = polar.organizations.list(page = 1 , limit = 10 )
11931190
11941191 while res is not None :
11951192 # Handle items
@@ -1210,7 +1207,7 @@ with Polar() as polar:
12101207
12111208 res = polar.customer_portal.benefit_grants.list(security = polar_sdk.CustomerPortalBenefitGrantsListSecurity(
12121209 customer_session = " <YOUR_BEARER_TOKEN_HERE>" ,
1213- ), organization_id = " 1dbfc517-0bbf-4301-9ba8-555ca42b9737 " )
1210+ ), organization_id = None , page = 1 , limit = 10 )
12141211
12151212 while res is not None :
12161213 # Handle items
@@ -1278,7 +1275,7 @@ with Polar(
12781275 access_token = " <YOUR_BEARER_TOKEN_HERE>" ,
12791276) as polar:
12801277
1281- res = polar.organizations.list()
1278+ res = polar.organizations.list(page = 1 , limit = 10 )
12821279
12831280 while res is not None :
12841281 # Handle items
0 commit comments