checkout-intents 0.9.0__tar.gz → 0.10.0__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 (100) hide show
  1. checkout_intents-0.10.0/.release-please-manifest.json +3 -0
  2. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/CHANGELOG.md +11 -0
  3. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/LICENSE +1 -1
  4. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/PKG-INFO +10 -30
  5. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/README.md +9 -29
  6. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/api.md +14 -0
  7. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/pyproject.toml +1 -1
  8. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/src/checkout_intents/_client.py +38 -1
  9. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/src/checkout_intents/_version.py +1 -1
  10. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/src/checkout_intents/resources/__init__.py +14 -0
  11. checkout_intents-0.10.0/src/checkout_intents/resources/betas/__init__.py +33 -0
  12. checkout_intents-0.10.0/src/checkout_intents/resources/betas/betas.py +102 -0
  13. checkout_intents-0.10.0/src/checkout_intents/resources/betas/checkout_sessions.py +208 -0
  14. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/src/checkout_intents/types/__init__.py +1 -0
  15. checkout_intents-0.10.0/src/checkout_intents/types/betas/__init__.py +5 -0
  16. checkout_intents-0.10.0/src/checkout_intents/types/betas/checkout_session_create_params.py +62 -0
  17. checkout_intents-0.10.0/src/checkout_intents/types/checkout_session.py +16 -0
  18. checkout_intents-0.10.0/tests/api_resources/betas/__init__.py +1 -0
  19. checkout_intents-0.10.0/tests/api_resources/betas/test_checkout_sessions.py +162 -0
  20. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/tests/api_resources/test_checkout_intents.py +4 -4
  21. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/tests/test_client.py +20 -64
  22. checkout_intents-0.9.0/.release-please-manifest.json +0 -3
  23. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/.gitignore +0 -0
  24. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/CONTRIBUTING.md +0 -0
  25. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/SECURITY.md +0 -0
  26. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/bin/check-release-environment +0 -0
  27. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/bin/publish-pypi +0 -0
  28. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/examples/.keep +0 -0
  29. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/examples/complete-checkout-intent.py +0 -0
  30. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/examples/error-handling.py +0 -0
  31. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/noxfile.py +0 -0
  32. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/release-please-config.json +0 -0
  33. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/requirements-dev.lock +0 -0
  34. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/requirements.lock +0 -0
  35. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/src/checkout_intents/__init__.py +0 -0
  36. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/src/checkout_intents/_base_client.py +0 -0
  37. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/src/checkout_intents/_compat.py +0 -0
  38. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/src/checkout_intents/_constants.py +0 -0
  39. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/src/checkout_intents/_exceptions.py +0 -0
  40. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/src/checkout_intents/_files.py +0 -0
  41. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/src/checkout_intents/_models.py +0 -0
  42. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/src/checkout_intents/_qs.py +0 -0
  43. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/src/checkout_intents/_resource.py +0 -0
  44. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/src/checkout_intents/_response.py +0 -0
  45. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/src/checkout_intents/_streaming.py +0 -0
  46. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/src/checkout_intents/_types.py +0 -0
  47. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/src/checkout_intents/_utils/__init__.py +0 -0
  48. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/src/checkout_intents/_utils/_compat.py +0 -0
  49. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/src/checkout_intents/_utils/_datetime_parse.py +0 -0
  50. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/src/checkout_intents/_utils/_logs.py +0 -0
  51. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/src/checkout_intents/_utils/_proxy.py +0 -0
  52. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/src/checkout_intents/_utils/_reflection.py +0 -0
  53. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/src/checkout_intents/_utils/_resources_proxy.py +0 -0
  54. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/src/checkout_intents/_utils/_streams.py +0 -0
  55. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/src/checkout_intents/_utils/_sync.py +0 -0
  56. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/src/checkout_intents/_utils/_transform.py +0 -0
  57. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/src/checkout_intents/_utils/_typing.py +0 -0
  58. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/src/checkout_intents/_utils/_utils.py +0 -0
  59. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/src/checkout_intents/lib/.keep +0 -0
  60. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/src/checkout_intents/pagination.py +0 -0
  61. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/src/checkout_intents/py.typed +0 -0
  62. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/src/checkout_intents/resources/brands.py +0 -0
  63. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/src/checkout_intents/resources/checkout_intents.py +0 -0
  64. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/src/checkout_intents/types/base_checkout_intent.py +0 -0
  65. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/src/checkout_intents/types/brand_retrieve_response.py +0 -0
  66. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/src/checkout_intents/types/buyer.py +0 -0
  67. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/src/checkout_intents/types/buyer_param.py +0 -0
  68. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/src/checkout_intents/types/checkout_intent.py +0 -0
  69. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/src/checkout_intents/types/checkout_intent_add_payment_params.py +0 -0
  70. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/src/checkout_intents/types/checkout_intent_confirm_params.py +0 -0
  71. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/src/checkout_intents/types/checkout_intent_create_params.py +0 -0
  72. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/src/checkout_intents/types/checkout_intent_list_params.py +0 -0
  73. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/src/checkout_intents/types/checkout_intent_purchase_params.py +0 -0
  74. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/src/checkout_intents/types/money.py +0 -0
  75. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/src/checkout_intents/types/offer.py +0 -0
  76. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/src/checkout_intents/types/payment_method.py +0 -0
  77. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/src/checkout_intents/types/payment_method_param.py +0 -0
  78. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/src/checkout_intents/types/variant_selection.py +0 -0
  79. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/src/checkout_intents/types/variant_selection_param.py +0 -0
  80. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/tests/__init__.py +0 -0
  81. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/tests/api_resources/__init__.py +0 -0
  82. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/tests/api_resources/test_brands.py +0 -0
  83. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/tests/conftest.py +0 -0
  84. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/tests/sample_file.txt +0 -0
  85. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/tests/test_deepcopy.py +0 -0
  86. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/tests/test_environment_inference.py +0 -0
  87. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/tests/test_extract_files.py +0 -0
  88. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/tests/test_files.py +0 -0
  89. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/tests/test_models.py +0 -0
  90. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/tests/test_polling.py +0 -0
  91. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/tests/test_qs.py +0 -0
  92. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/tests/test_required_args.py +0 -0
  93. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/tests/test_response.py +0 -0
  94. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/tests/test_streaming.py +0 -0
  95. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/tests/test_transform.py +0 -0
  96. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/tests/test_utils/test_datetime_parse.py +0 -0
  97. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/tests/test_utils/test_proxy.py +0 -0
  98. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/tests/test_utils/test_typing.py +0 -0
  99. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/tests/utils.py +0 -0
  100. {checkout_intents-0.9.0 → checkout_intents-0.10.0}/uv.lock +0 -0
@@ -0,0 +1,3 @@
1
+ {
2
+ ".": "0.10.0"
3
+ }
@@ -1,5 +1,16 @@
1
1
  # Changelog
2
2
 
3
+ ## 0.10.0 (2026-01-06)
4
+
5
+ Full Changelog: [v0.9.0...v0.10.0](https://github.com/rye-com/checkout-intents-python/compare/v0.9.0...v0.10.0)
6
+
7
+ ### Features
8
+
9
+ * Fix Slack follow-up messages not posting to thread when initial message fails ([61f39ce](https://github.com/rye-com/checkout-intents-python/commit/61f39ce09ad720d99fb866eca1d30cd6fbe353fc))
10
+ * Improve JSDoc for checkout sessions ([dffa705](https://github.com/rye-com/checkout-intents-python/commit/dffa70546832f5f4c74ba0e1c3280a98739bc9bf))
11
+ * RYE-6466: Enrich tracked analytics context for the checkout intents api ([26ed61e](https://github.com/rye-com/checkout-intents-python/commit/26ed61e274b71f66d5c952561fe9565213aeed1b))
12
+ * Tidy API docs ([1ce6f5f](https://github.com/rye-com/checkout-intents-python/commit/1ce6f5fe5e7ca420b911b11d8bb5106e09e0ac40))
13
+
3
14
  ## 0.9.0 (2025-12-25)
4
15
 
5
16
  Full Changelog: [v0.8.0...v0.9.0](https://github.com/rye-com/checkout-intents-python/compare/v0.8.0...v0.9.0)
@@ -1,4 +1,4 @@
1
- Copyright 2025 Checkout Intents
1
+ Copyright 2026 Checkout Intents
2
2
 
3
3
  Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
4
4
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.3
2
2
  Name: checkout-intents
3
- Version: 0.9.0
3
+ Version: 0.10.0
4
4
  Summary: The official Python library for the Checkout Intents API
5
5
  Project-URL: Homepage, https://github.com/rye-com/checkout-intents-python
6
6
  Project-URL: Repository, https://github.com/rye-com/checkout-intents-python
@@ -82,7 +82,7 @@ checkout_intent = client.checkout_intents.purchase(
82
82
  "province": "NY",
83
83
  },
84
84
  payment_method={
85
- "stripe_token": "tok_visa",
85
+ "stripe_token": "tok_1RkrWWHGDlstla3f1Fc7ZrhH",
86
86
  "type": "stripe_token",
87
87
  },
88
88
  product_url="https://rye-protocol.myshopify.com/products/rye-sticker",
@@ -217,7 +217,7 @@ async def main() -> None:
217
217
  "province": "NY",
218
218
  },
219
219
  payment_method={
220
- "stripe_token": "tok_visa",
220
+ "stripe_token": "tok_1RkrWWHGDlstla3f1Fc7ZrhH",
221
221
  "type": "stripe_token",
222
222
  },
223
223
  product_url="https://rye-protocol.myshopify.com/products/rye-sticker",
@@ -270,7 +270,7 @@ async def main() -> None:
270
270
  "province": "NY",
271
271
  },
272
272
  payment_method={
273
- "stripe_token": "tok_visa",
273
+ "stripe_token": "tok_1RkrWWHGDlstla3f1Fc7ZrhH",
274
274
  "type": "stripe_token",
275
275
  },
276
276
  product_url="https://rye-protocol.myshopify.com/products/rye-sticker",
@@ -408,7 +408,7 @@ from checkout_intents import CheckoutIntents
408
408
  client = CheckoutIntents()
409
409
 
410
410
  try:
411
- client.checkout_intents.purchase(
411
+ client.checkout_intents.create(
412
412
  buyer={
413
413
  "address1": "123 Main St",
414
414
  "city": "New York",
@@ -420,10 +420,6 @@ try:
420
420
  "postal_code": "10001",
421
421
  "province": "NY",
422
422
  },
423
- payment_method={
424
- "stripe_token": "tok_visa",
425
- "type": "stripe_token",
426
- },
427
423
  product_url="https://rye-protocol.myshopify.com/products/rye-sticker",
428
424
  quantity=1,
429
425
  )
@@ -489,7 +485,7 @@ client = CheckoutIntents(
489
485
  )
490
486
 
491
487
  # Or, configure per-request:
492
- client.with_options(max_retries=5).checkout_intents.purchase(
488
+ client.with_options(max_retries=5).checkout_intents.create(
493
489
  buyer={
494
490
  "address1": "123 Main St",
495
491
  "city": "New York",
@@ -501,10 +497,6 @@ client.with_options(max_retries=5).checkout_intents.purchase(
501
497
  "postal_code": "10001",
502
498
  "province": "NY",
503
499
  },
504
- payment_method={
505
- "stripe_token": "tok_visa",
506
- "type": "stripe_token",
507
- },
508
500
  product_url="https://rye-protocol.myshopify.com/products/rye-sticker",
509
501
  quantity=1,
510
502
  )
@@ -530,7 +522,7 @@ client = CheckoutIntents(
530
522
  )
531
523
 
532
524
  # Override per-request:
533
- client.with_options(timeout=5.0).checkout_intents.purchase(
525
+ client.with_options(timeout=5.0).checkout_intents.create(
534
526
  buyer={
535
527
  "address1": "123 Main St",
536
528
  "city": "New York",
@@ -542,10 +534,6 @@ client.with_options(timeout=5.0).checkout_intents.purchase(
542
534
  "postal_code": "10001",
543
535
  "province": "NY",
544
536
  },
545
- payment_method={
546
- "stripe_token": "tok_visa",
547
- "type": "stripe_token",
548
- },
549
537
  product_url="https://rye-protocol.myshopify.com/products/rye-sticker",
550
538
  quantity=1,
551
539
  )
@@ -589,7 +577,7 @@ The "raw" Response object can be accessed by prefixing `.with_raw_response.` to
589
577
  from checkout_intents import CheckoutIntents
590
578
 
591
579
  client = CheckoutIntents()
592
- response = client.checkout_intents.with_raw_response.purchase(
580
+ response = client.checkout_intents.with_raw_response.create(
593
581
  buyer={
594
582
  "address1": "123 Main St",
595
583
  "city": "New York",
@@ -601,16 +589,12 @@ response = client.checkout_intents.with_raw_response.purchase(
601
589
  "postal_code": "10001",
602
590
  "province": "NY",
603
591
  },
604
- payment_method={
605
- "stripe_token": "tok_visa",
606
- "type": "stripe_token",
607
- },
608
592
  product_url="https://rye-protocol.myshopify.com/products/rye-sticker",
609
593
  quantity=1,
610
594
  )
611
595
  print(response.headers.get('X-My-Header'))
612
596
 
613
- checkout_intent = response.parse() # get the object that `checkout_intents.purchase()` would have returned
597
+ checkout_intent = response.parse() # get the object that `checkout_intents.create()` would have returned
614
598
  print(checkout_intent)
615
599
  ```
616
600
 
@@ -625,7 +609,7 @@ The above interface eagerly reads the full response body when you make the reque
625
609
  To stream the response body, use `.with_streaming_response` instead, which requires a context manager and only reads the response body once you call `.read()`, `.text()`, `.json()`, `.iter_bytes()`, `.iter_text()`, `.iter_lines()` or `.parse()`. In the async client, these are async methods.
626
610
 
627
611
  ```python
628
- with client.checkout_intents.with_streaming_response.purchase(
612
+ with client.checkout_intents.with_streaming_response.create(
629
613
  buyer={
630
614
  "address1": "123 Main St",
631
615
  "city": "New York",
@@ -637,10 +621,6 @@ with client.checkout_intents.with_streaming_response.purchase(
637
621
  "postal_code": "10001",
638
622
  "province": "NY",
639
623
  },
640
- payment_method={
641
- "stripe_token": "tok_visa",
642
- "type": "stripe_token",
643
- },
644
624
  product_url="https://rye-protocol.myshopify.com/products/rye-sticker",
645
625
  quantity=1,
646
626
  ) as response:
@@ -47,7 +47,7 @@ checkout_intent = client.checkout_intents.purchase(
47
47
  "province": "NY",
48
48
  },
49
49
  payment_method={
50
- "stripe_token": "tok_visa",
50
+ "stripe_token": "tok_1RkrWWHGDlstla3f1Fc7ZrhH",
51
51
  "type": "stripe_token",
52
52
  },
53
53
  product_url="https://rye-protocol.myshopify.com/products/rye-sticker",
@@ -182,7 +182,7 @@ async def main() -> None:
182
182
  "province": "NY",
183
183
  },
184
184
  payment_method={
185
- "stripe_token": "tok_visa",
185
+ "stripe_token": "tok_1RkrWWHGDlstla3f1Fc7ZrhH",
186
186
  "type": "stripe_token",
187
187
  },
188
188
  product_url="https://rye-protocol.myshopify.com/products/rye-sticker",
@@ -235,7 +235,7 @@ async def main() -> None:
235
235
  "province": "NY",
236
236
  },
237
237
  payment_method={
238
- "stripe_token": "tok_visa",
238
+ "stripe_token": "tok_1RkrWWHGDlstla3f1Fc7ZrhH",
239
239
  "type": "stripe_token",
240
240
  },
241
241
  product_url="https://rye-protocol.myshopify.com/products/rye-sticker",
@@ -373,7 +373,7 @@ from checkout_intents import CheckoutIntents
373
373
  client = CheckoutIntents()
374
374
 
375
375
  try:
376
- client.checkout_intents.purchase(
376
+ client.checkout_intents.create(
377
377
  buyer={
378
378
  "address1": "123 Main St",
379
379
  "city": "New York",
@@ -385,10 +385,6 @@ try:
385
385
  "postal_code": "10001",
386
386
  "province": "NY",
387
387
  },
388
- payment_method={
389
- "stripe_token": "tok_visa",
390
- "type": "stripe_token",
391
- },
392
388
  product_url="https://rye-protocol.myshopify.com/products/rye-sticker",
393
389
  quantity=1,
394
390
  )
@@ -454,7 +450,7 @@ client = CheckoutIntents(
454
450
  )
455
451
 
456
452
  # Or, configure per-request:
457
- client.with_options(max_retries=5).checkout_intents.purchase(
453
+ client.with_options(max_retries=5).checkout_intents.create(
458
454
  buyer={
459
455
  "address1": "123 Main St",
460
456
  "city": "New York",
@@ -466,10 +462,6 @@ client.with_options(max_retries=5).checkout_intents.purchase(
466
462
  "postal_code": "10001",
467
463
  "province": "NY",
468
464
  },
469
- payment_method={
470
- "stripe_token": "tok_visa",
471
- "type": "stripe_token",
472
- },
473
465
  product_url="https://rye-protocol.myshopify.com/products/rye-sticker",
474
466
  quantity=1,
475
467
  )
@@ -495,7 +487,7 @@ client = CheckoutIntents(
495
487
  )
496
488
 
497
489
  # Override per-request:
498
- client.with_options(timeout=5.0).checkout_intents.purchase(
490
+ client.with_options(timeout=5.0).checkout_intents.create(
499
491
  buyer={
500
492
  "address1": "123 Main St",
501
493
  "city": "New York",
@@ -507,10 +499,6 @@ client.with_options(timeout=5.0).checkout_intents.purchase(
507
499
  "postal_code": "10001",
508
500
  "province": "NY",
509
501
  },
510
- payment_method={
511
- "stripe_token": "tok_visa",
512
- "type": "stripe_token",
513
- },
514
502
  product_url="https://rye-protocol.myshopify.com/products/rye-sticker",
515
503
  quantity=1,
516
504
  )
@@ -554,7 +542,7 @@ The "raw" Response object can be accessed by prefixing `.with_raw_response.` to
554
542
  from checkout_intents import CheckoutIntents
555
543
 
556
544
  client = CheckoutIntents()
557
- response = client.checkout_intents.with_raw_response.purchase(
545
+ response = client.checkout_intents.with_raw_response.create(
558
546
  buyer={
559
547
  "address1": "123 Main St",
560
548
  "city": "New York",
@@ -566,16 +554,12 @@ response = client.checkout_intents.with_raw_response.purchase(
566
554
  "postal_code": "10001",
567
555
  "province": "NY",
568
556
  },
569
- payment_method={
570
- "stripe_token": "tok_visa",
571
- "type": "stripe_token",
572
- },
573
557
  product_url="https://rye-protocol.myshopify.com/products/rye-sticker",
574
558
  quantity=1,
575
559
  )
576
560
  print(response.headers.get('X-My-Header'))
577
561
 
578
- checkout_intent = response.parse() # get the object that `checkout_intents.purchase()` would have returned
562
+ checkout_intent = response.parse() # get the object that `checkout_intents.create()` would have returned
579
563
  print(checkout_intent)
580
564
  ```
581
565
 
@@ -590,7 +574,7 @@ The above interface eagerly reads the full response body when you make the reque
590
574
  To stream the response body, use `.with_streaming_response` instead, which requires a context manager and only reads the response body once you call `.read()`, `.text()`, `.json()`, `.iter_bytes()`, `.iter_text()`, `.iter_lines()` or `.parse()`. In the async client, these are async methods.
591
575
 
592
576
  ```python
593
- with client.checkout_intents.with_streaming_response.purchase(
577
+ with client.checkout_intents.with_streaming_response.create(
594
578
  buyer={
595
579
  "address1": "123 Main St",
596
580
  "city": "New York",
@@ -602,10 +586,6 @@ with client.checkout_intents.with_streaming_response.purchase(
602
586
  "postal_code": "10001",
603
587
  "province": "NY",
604
588
  },
605
- payment_method={
606
- "stripe_token": "tok_visa",
607
- "type": "stripe_token",
608
- },
609
589
  product_url="https://rye-protocol.myshopify.com/products/rye-sticker",
610
590
  quantity=1,
611
591
  ) as response:
@@ -23,6 +23,20 @@ Methods:
23
23
  - <code title="post /api/v1/checkout-intents/{id}/confirm">client.checkout_intents.<a href="./src/checkout_intents/resources/checkout_intents.py">confirm</a>(id, \*\*<a href="src/checkout_intents/types/checkout_intent_confirm_params.py">params</a>) -> <a href="./src/checkout_intents/types/checkout_intent.py">CheckoutIntent</a></code>
24
24
  - <code title="post /api/v1/checkout-intents/purchase">client.checkout_intents.<a href="./src/checkout_intents/resources/checkout_intents.py">purchase</a>(\*\*<a href="src/checkout_intents/types/checkout_intent_purchase_params.py">params</a>) -> <a href="./src/checkout_intents/types/checkout_intent.py">CheckoutIntent</a></code>
25
25
 
26
+ # Betas
27
+
28
+ Types:
29
+
30
+ ```python
31
+ from checkout_intents.types import CheckoutSession
32
+ ```
33
+
34
+ ## CheckoutSessions
35
+
36
+ Methods:
37
+
38
+ - <code title="post /api/v1/betas/checkout-sessions">client.betas.checkout_sessions.<a href="./src/checkout_intents/resources/betas/checkout_sessions.py">create</a>(\*\*<a href="src/checkout_intents/types/betas/checkout_session_create_params.py">params</a>) -> <a href="./src/checkout_intents/types/checkout_session.py">CheckoutSession</a></code>
39
+
26
40
  # Brands
27
41
 
28
42
  Types:
@@ -1,6 +1,6 @@
1
1
  [project]
2
2
  name = "checkout-intents"
3
- version = "0.9.0"
3
+ version = "0.10.0"
4
4
  description = "The official Python library for the Checkout Intents API"
5
5
  dynamic = ["readme"]
6
6
  license = "MIT"
@@ -31,8 +31,9 @@ from ._base_client import (
31
31
  )
32
32
 
33
33
  if TYPE_CHECKING:
34
- from .resources import brands, checkout_intents
34
+ from .resources import betas, brands, checkout_intents
35
35
  from .resources.brands import BrandsResource, AsyncBrandsResource
36
+ from .resources.betas.betas import BetasResource, AsyncBetasResource
36
37
  from .resources.checkout_intents import CheckoutIntentsResource, AsyncCheckoutIntentsResource
37
38
 
38
39
  __all__ = [
@@ -172,6 +173,12 @@ class CheckoutIntents(SyncAPIClient):
172
173
 
173
174
  return CheckoutIntentsResource(self)
174
175
 
176
+ @cached_property
177
+ def betas(self) -> BetasResource:
178
+ from .resources.betas import BetasResource
179
+
180
+ return BetasResource(self)
181
+
175
182
  @cached_property
176
183
  def brands(self) -> BrandsResource:
177
184
  from .resources.brands import BrandsResource
@@ -395,6 +402,12 @@ class AsyncCheckoutIntents(AsyncAPIClient):
395
402
 
396
403
  return AsyncCheckoutIntentsResource(self)
397
404
 
405
+ @cached_property
406
+ def betas(self) -> AsyncBetasResource:
407
+ from .resources.betas import AsyncBetasResource
408
+
409
+ return AsyncBetasResource(self)
410
+
398
411
  @cached_property
399
412
  def brands(self) -> AsyncBrandsResource:
400
413
  from .resources.brands import AsyncBrandsResource
@@ -528,6 +541,12 @@ class CheckoutIntentsWithRawResponse:
528
541
 
529
542
  return CheckoutIntentsResourceWithRawResponse(self._client.checkout_intents)
530
543
 
544
+ @cached_property
545
+ def betas(self) -> betas.BetasResourceWithRawResponse:
546
+ from .resources.betas import BetasResourceWithRawResponse
547
+
548
+ return BetasResourceWithRawResponse(self._client.betas)
549
+
531
550
  @cached_property
532
551
  def brands(self) -> brands.BrandsResourceWithRawResponse:
533
552
  from .resources.brands import BrandsResourceWithRawResponse
@@ -547,6 +566,12 @@ class AsyncCheckoutIntentsWithRawResponse:
547
566
 
548
567
  return AsyncCheckoutIntentsResourceWithRawResponse(self._client.checkout_intents)
549
568
 
569
+ @cached_property
570
+ def betas(self) -> betas.AsyncBetasResourceWithRawResponse:
571
+ from .resources.betas import AsyncBetasResourceWithRawResponse
572
+
573
+ return AsyncBetasResourceWithRawResponse(self._client.betas)
574
+
550
575
  @cached_property
551
576
  def brands(self) -> brands.AsyncBrandsResourceWithRawResponse:
552
577
  from .resources.brands import AsyncBrandsResourceWithRawResponse
@@ -566,6 +591,12 @@ class CheckoutIntentsWithStreamedResponse:
566
591
 
567
592
  return CheckoutIntentsResourceWithStreamingResponse(self._client.checkout_intents)
568
593
 
594
+ @cached_property
595
+ def betas(self) -> betas.BetasResourceWithStreamingResponse:
596
+ from .resources.betas import BetasResourceWithStreamingResponse
597
+
598
+ return BetasResourceWithStreamingResponse(self._client.betas)
599
+
569
600
  @cached_property
570
601
  def brands(self) -> brands.BrandsResourceWithStreamingResponse:
571
602
  from .resources.brands import BrandsResourceWithStreamingResponse
@@ -585,6 +616,12 @@ class AsyncCheckoutIntentsWithStreamedResponse:
585
616
 
586
617
  return AsyncCheckoutIntentsResourceWithStreamingResponse(self._client.checkout_intents)
587
618
 
619
+ @cached_property
620
+ def betas(self) -> betas.AsyncBetasResourceWithStreamingResponse:
621
+ from .resources.betas import AsyncBetasResourceWithStreamingResponse
622
+
623
+ return AsyncBetasResourceWithStreamingResponse(self._client.betas)
624
+
588
625
  @cached_property
589
626
  def brands(self) -> brands.AsyncBrandsResourceWithStreamingResponse:
590
627
  from .resources.brands import AsyncBrandsResourceWithStreamingResponse
@@ -1,4 +1,4 @@
1
1
  # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
2
 
3
3
  __title__ = "checkout_intents"
4
- __version__ = "0.9.0" # x-release-please-version
4
+ __version__ = "0.10.0" # x-release-please-version
@@ -1,5 +1,13 @@
1
1
  # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
2
 
3
+ from .betas import (
4
+ BetasResource,
5
+ AsyncBetasResource,
6
+ BetasResourceWithRawResponse,
7
+ AsyncBetasResourceWithRawResponse,
8
+ BetasResourceWithStreamingResponse,
9
+ AsyncBetasResourceWithStreamingResponse,
10
+ )
3
11
  from .brands import (
4
12
  BrandsResource,
5
13
  AsyncBrandsResource,
@@ -24,6 +32,12 @@ __all__ = [
24
32
  "AsyncCheckoutIntentsResourceWithRawResponse",
25
33
  "CheckoutIntentsResourceWithStreamingResponse",
26
34
  "AsyncCheckoutIntentsResourceWithStreamingResponse",
35
+ "BetasResource",
36
+ "AsyncBetasResource",
37
+ "BetasResourceWithRawResponse",
38
+ "AsyncBetasResourceWithRawResponse",
39
+ "BetasResourceWithStreamingResponse",
40
+ "AsyncBetasResourceWithStreamingResponse",
27
41
  "BrandsResource",
28
42
  "AsyncBrandsResource",
29
43
  "BrandsResourceWithRawResponse",
@@ -0,0 +1,33 @@
1
+ # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ from .betas import (
4
+ BetasResource,
5
+ AsyncBetasResource,
6
+ BetasResourceWithRawResponse,
7
+ AsyncBetasResourceWithRawResponse,
8
+ BetasResourceWithStreamingResponse,
9
+ AsyncBetasResourceWithStreamingResponse,
10
+ )
11
+ from .checkout_sessions import (
12
+ CheckoutSessionsResource,
13
+ AsyncCheckoutSessionsResource,
14
+ CheckoutSessionsResourceWithRawResponse,
15
+ AsyncCheckoutSessionsResourceWithRawResponse,
16
+ CheckoutSessionsResourceWithStreamingResponse,
17
+ AsyncCheckoutSessionsResourceWithStreamingResponse,
18
+ )
19
+
20
+ __all__ = [
21
+ "CheckoutSessionsResource",
22
+ "AsyncCheckoutSessionsResource",
23
+ "CheckoutSessionsResourceWithRawResponse",
24
+ "AsyncCheckoutSessionsResourceWithRawResponse",
25
+ "CheckoutSessionsResourceWithStreamingResponse",
26
+ "AsyncCheckoutSessionsResourceWithStreamingResponse",
27
+ "BetasResource",
28
+ "AsyncBetasResource",
29
+ "BetasResourceWithRawResponse",
30
+ "AsyncBetasResourceWithRawResponse",
31
+ "BetasResourceWithStreamingResponse",
32
+ "AsyncBetasResourceWithStreamingResponse",
33
+ ]
@@ -0,0 +1,102 @@
1
+ # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ from __future__ import annotations
4
+
5
+ from ..._compat import cached_property
6
+ from ..._resource import SyncAPIResource, AsyncAPIResource
7
+ from .checkout_sessions import (
8
+ CheckoutSessionsResource,
9
+ AsyncCheckoutSessionsResource,
10
+ CheckoutSessionsResourceWithRawResponse,
11
+ AsyncCheckoutSessionsResourceWithRawResponse,
12
+ CheckoutSessionsResourceWithStreamingResponse,
13
+ AsyncCheckoutSessionsResourceWithStreamingResponse,
14
+ )
15
+
16
+ __all__ = ["BetasResource", "AsyncBetasResource"]
17
+
18
+
19
+ class BetasResource(SyncAPIResource):
20
+ @cached_property
21
+ def checkout_sessions(self) -> CheckoutSessionsResource:
22
+ return CheckoutSessionsResource(self._client)
23
+
24
+ @cached_property
25
+ def with_raw_response(self) -> BetasResourceWithRawResponse:
26
+ """
27
+ This property can be used as a prefix for any HTTP method call to return
28
+ the raw response object instead of the parsed content.
29
+
30
+ For more information, see https://www.github.com/rye-com/checkout-intents-python#accessing-raw-response-data-eg-headers
31
+ """
32
+ return BetasResourceWithRawResponse(self)
33
+
34
+ @cached_property
35
+ def with_streaming_response(self) -> BetasResourceWithStreamingResponse:
36
+ """
37
+ An alternative to `.with_raw_response` that doesn't eagerly read the response body.
38
+
39
+ For more information, see https://www.github.com/rye-com/checkout-intents-python#with_streaming_response
40
+ """
41
+ return BetasResourceWithStreamingResponse(self)
42
+
43
+
44
+ class AsyncBetasResource(AsyncAPIResource):
45
+ @cached_property
46
+ def checkout_sessions(self) -> AsyncCheckoutSessionsResource:
47
+ return AsyncCheckoutSessionsResource(self._client)
48
+
49
+ @cached_property
50
+ def with_raw_response(self) -> AsyncBetasResourceWithRawResponse:
51
+ """
52
+ This property can be used as a prefix for any HTTP method call to return
53
+ the raw response object instead of the parsed content.
54
+
55
+ For more information, see https://www.github.com/rye-com/checkout-intents-python#accessing-raw-response-data-eg-headers
56
+ """
57
+ return AsyncBetasResourceWithRawResponse(self)
58
+
59
+ @cached_property
60
+ def with_streaming_response(self) -> AsyncBetasResourceWithStreamingResponse:
61
+ """
62
+ An alternative to `.with_raw_response` that doesn't eagerly read the response body.
63
+
64
+ For more information, see https://www.github.com/rye-com/checkout-intents-python#with_streaming_response
65
+ """
66
+ return AsyncBetasResourceWithStreamingResponse(self)
67
+
68
+
69
+ class BetasResourceWithRawResponse:
70
+ def __init__(self, betas: BetasResource) -> None:
71
+ self._betas = betas
72
+
73
+ @cached_property
74
+ def checkout_sessions(self) -> CheckoutSessionsResourceWithRawResponse:
75
+ return CheckoutSessionsResourceWithRawResponse(self._betas.checkout_sessions)
76
+
77
+
78
+ class AsyncBetasResourceWithRawResponse:
79
+ def __init__(self, betas: AsyncBetasResource) -> None:
80
+ self._betas = betas
81
+
82
+ @cached_property
83
+ def checkout_sessions(self) -> AsyncCheckoutSessionsResourceWithRawResponse:
84
+ return AsyncCheckoutSessionsResourceWithRawResponse(self._betas.checkout_sessions)
85
+
86
+
87
+ class BetasResourceWithStreamingResponse:
88
+ def __init__(self, betas: BetasResource) -> None:
89
+ self._betas = betas
90
+
91
+ @cached_property
92
+ def checkout_sessions(self) -> CheckoutSessionsResourceWithStreamingResponse:
93
+ return CheckoutSessionsResourceWithStreamingResponse(self._betas.checkout_sessions)
94
+
95
+
96
+ class AsyncBetasResourceWithStreamingResponse:
97
+ def __init__(self, betas: AsyncBetasResource) -> None:
98
+ self._betas = betas
99
+
100
+ @cached_property
101
+ def checkout_sessions(self) -> AsyncCheckoutSessionsResourceWithStreamingResponse:
102
+ return AsyncCheckoutSessionsResourceWithStreamingResponse(self._betas.checkout_sessions)