fastpix-python 1.1.3__tar.gz → 1.1.4__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 (272) hide show
  1. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/CHANGELOG.md +30 -1
  2. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/PKG-INFO +5 -5
  3. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/README.md +4 -4
  4. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/_version.py +2 -2
  5. fastpix_python-1.1.4/fastpix_python/basesdk.py +314 -0
  6. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/dimensions.py +45 -41
  7. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/drm_configurations.py +84 -152
  8. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/errors/__init__.py +1 -2
  9. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/errors/validationerrorresponse.py +35 -28
  10. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/errors.py +25 -21
  11. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/fastpix.yaml +6 -6
  12. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/httpclient.py +6 -6
  13. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/in_video_ai_features.py +134 -282
  14. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/input_video.py +116 -144
  15. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/live_playback.py +113 -228
  16. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/manage_live_stream.py +264 -602
  17. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/manage_videos.py +436 -1082
  18. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/metrics.py +85 -81
  19. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/__init__.py +1006 -641
  20. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/default_error.py +10 -8
  21. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/errordetails.py +4 -4
  22. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/get_data_viewlist_current_views_gettimeseriesviewsop.py +4 -4
  23. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/list_playback_idsop.py +25 -20
  24. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/list_video_viewsop.py +4 -4
  25. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/metricsbreakdowndetails.py +4 -4
  26. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/metricsoveralldatadetails.py +4 -4
  27. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/metricstimeseriesdatadetails.py +4 -4
  28. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/toperrordetails.py +4 -4
  29. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/update_domain_restrictionsop.py +15 -12
  30. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/update_user_agent_restrictionsop.py +15 -12
  31. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/views.py +12 -12
  32. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/viewslist.py +4 -4
  33. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/playback.py +155 -262
  34. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/playlist.py +252 -546
  35. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/sdk.py +3 -4
  36. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/signing_keys.py +138 -276
  37. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/simulcast_stream.py +143 -314
  38. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/start_live_stream.py +25 -21
  39. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/views_sdk.py +149 -314
  40. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python.egg-info/PKG-INFO +5 -5
  41. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/pyproject.toml +1 -1
  42. fastpix_python-1.1.3/fastpix_python/basesdk.py +0 -368
  43. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/CONTRIBUTING.md +0 -0
  44. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/LICENSE +0 -0
  45. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/MANIFEST.in +0 -0
  46. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/USAGE.md +0 -0
  47. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/__init__.py +0 -0
  48. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/_hooks/__init__.py +0 -0
  49. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/_hooks/sdkhooks.py +0 -0
  50. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/_hooks/types.py +0 -0
  51. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/errors/badrequest_error.py +0 -0
  52. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/errors/duplicatemp4support_error.py +0 -0
  53. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/errors/duplicatereferenceiderrorresponse.py +0 -0
  54. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/errors/enable_live_streamop.py +0 -0
  55. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/errors/fastpixdefaulterror.py +0 -0
  56. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/errors/fastpixerror.py +0 -0
  57. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/errors/forbidden_error.py +0 -0
  58. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/errors/forbiddenresponse_error.py +0 -0
  59. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/errors/invalidpermission_error.py +0 -0
  60. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/errors/invalidplaylistidresponse_error.py +0 -0
  61. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/errors/livenotfounderror.py +0 -0
  62. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/errors/mediaclipnotfound_error.py +0 -0
  63. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/errors/medianotfound_error.py +0 -0
  64. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/errors/mediaorplaybacknotfound_error.py +0 -0
  65. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/errors/no_response_error.py +0 -0
  66. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/errors/notfounderror.py +0 -0
  67. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/errors/notfounderrorplaybackid.py +0 -0
  68. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/errors/notfounderrorsimulcast.py +0 -0
  69. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/errors/responsevalidationerror.py +0 -0
  70. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/errors/signingkeynotfounderror.py +0 -0
  71. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/errors/simulcastunavailable_error.py +0 -0
  72. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/errors/streamalreadydisablederror.py +0 -0
  73. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/errors/streamalreadyenablederror.py +0 -0
  74. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/errors/trackduplicaterequest_error.py +0 -0
  75. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/errors/trialplanrestrictionerror.py +0 -0
  76. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/errors/unauthorized_error.py +0 -0
  77. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/errors/unauthorizedresponse_error.py +0 -0
  78. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/errors/viewnotfound_error.py +0 -0
  79. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/accesspolicy.py +0 -0
  80. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/add_media_to_playlistop.py +0 -0
  81. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/add_media_trackop.py +0 -0
  82. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/addtrackrequest.py +0 -0
  83. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/addtrackresponse.py +0 -0
  84. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/audioinput.py +0 -0
  85. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/badrequest_error.py +0 -0
  86. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/basicaccesspolicy.py +0 -0
  87. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/browsernamedimensiondetails.py +0 -0
  88. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/cancel_uploadop.py +0 -0
  89. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/change_media_order_in_playlistop.py +0 -0
  90. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/chaptersresponse.py +0 -0
  91. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/complete_live_streamop.py +0 -0
  92. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/create_media_playback_idop.py +0 -0
  93. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/create_playbackid_of_streamop.py +0 -0
  94. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/create_simulcast_of_streamop.py +0 -0
  95. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/createlivestreamrequest.py +0 -0
  96. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/createmediarequest.py +0 -0
  97. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/createmediaresponse.py +0 -0
  98. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/createmediasuccessresponse.py +0 -0
  99. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/createplaylistrequest.py +0 -0
  100. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/createresponse.py +0 -0
  101. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/createsigningkeyresponsedto.py +0 -0
  102. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/datapagination.py +0 -0
  103. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/daterange.py +0 -0
  104. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/delete_a_playlistop.py +0 -0
  105. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/delete_live_streamop.py +0 -0
  106. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/delete_media_from_playlistop.py +0 -0
  107. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/delete_media_playback_idop.py +0 -0
  108. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/delete_media_trackop.py +0 -0
  109. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/delete_mediaop.py +0 -0
  110. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/delete_playbackid_of_streamop.py +0 -0
  111. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/delete_signing_keyop.py +0 -0
  112. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/delete_simulcast_of_streamop.py +0 -0
  113. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/deletesigningkeyresponse.py +0 -0
  114. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/direct_upload_video_mediaop.py +0 -0
  115. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/directupload.py +0 -0
  116. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/directuploadresponse.py +0 -0
  117. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/disable_live_streamop.py +0 -0
  118. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/domainrestrictions.py +0 -0
  119. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/drmidresponse.py +0 -0
  120. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/duplicatemp4support_error.py +0 -0
  121. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/duplicatereferenceiderrorresponse.py +0 -0
  122. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/enable_live_streamop.py +0 -0
  123. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/fielderror.py +0 -0
  124. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/forbidden_error.py +0 -0
  125. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/forbiddenresponse_error.py +0 -0
  126. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/generate_subtitle_trackop.py +0 -0
  127. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/generatetrackresponse.py +0 -0
  128. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/get_all_playlistsop.py +0 -0
  129. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/get_all_streamsop.py +0 -0
  130. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/get_data_viewlist_current_views_filterop.py +0 -0
  131. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/get_live_stream_by_idop.py +0 -0
  132. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/get_live_stream_playback_idop.py +0 -0
  133. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/get_live_stream_viewer_count_by_idop.py +0 -0
  134. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/get_media_clipsop.py +0 -0
  135. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/get_mediaop.py +0 -0
  136. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/get_playback_idop.py +0 -0
  137. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/get_playlist_by_idop.py +0 -0
  138. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/get_signing_key_by_idop.py +0 -0
  139. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/get_specific_simulcast_of_streamop.py +0 -0
  140. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/get_timeseries_dataop.py +0 -0
  141. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/get_video_view_detailsop.py +0 -0
  142. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/getallplaylistsresponse.py +0 -0
  143. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/getallsigningkeyresponse.py +0 -0
  144. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/getallsigningkeyresponsedto.py +0 -0
  145. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/getcreatelivestreamresponsedto.py +0 -0
  146. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/getdrmconfigurationbyidop.py +0 -0
  147. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/getdrmconfigurationop.py +0 -0
  148. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/getpublicpemusingsigningkeyidresponsedto.py +0 -0
  149. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/getstreamsresponse.py +0 -0
  150. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/invalidpermission_error.py +0 -0
  151. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/invalidplaylistidresponse_error.py +0 -0
  152. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/languagecode.py +0 -0
  153. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/list_breakdown_valuesop.py +0 -0
  154. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/list_by_top_contentop.py +0 -0
  155. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/list_comparison_valuesop.py +0 -0
  156. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/list_dimensionsop.py +0 -0
  157. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/list_errorsop.py +0 -0
  158. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/list_filter_values_for_dimensionop.py +0 -0
  159. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/list_live_clipsop.py +0 -0
  160. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/list_mediaop.py +0 -0
  161. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/list_overall_valuesop.py +0 -0
  162. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/list_signing_keysop.py +0 -0
  163. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/list_uploadsop.py +0 -0
  164. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/livenotfounderror.py +0 -0
  165. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/livestreamdeleteresponse.py +0 -0
  166. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/livestreamgetresponse.py +0 -0
  167. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/livestreampagination.py +0 -0
  168. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/livestreamresponsedto.py +0 -0
  169. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/media.py +0 -0
  170. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/mediacancelresponse.py +0 -0
  171. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/mediaclipnotfound_error.py +0 -0
  172. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/mediaclipresponse.py +0 -0
  173. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/mediaidsrequest.py +0 -0
  174. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/medianotfound_error.py +0 -0
  175. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/mediaorplaybacknotfound_error.py +0 -0
  176. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/mediatype.py +0 -0
  177. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/metricscomparisondetails.py +0 -0
  178. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/metricsoverallmetadatadetails.py +0 -0
  179. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/metricstimeseriesmetadatadetails.py +0 -0
  180. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/moderationresponse.py +0 -0
  181. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/namedentitiesresponse.py +0 -0
  182. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/notfounderror.py +0 -0
  183. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/notfounderrorplaybackid.py +0 -0
  184. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/notfounderrorsimulcast.py +0 -0
  185. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/pagination.py +0 -0
  186. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/patchlivestreamrequest.py +0 -0
  187. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/patchresponsedata.py +0 -0
  188. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/patchresponsedto.py +0 -0
  189. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/playbackid.py +0 -0
  190. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/playbackidrequest.py +0 -0
  191. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/playbackidresponse.py +0 -0
  192. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/playbackidsuccessresponse.py +0 -0
  193. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/playbacksettings.py +0 -0
  194. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/playlistbyidresponse.py +0 -0
  195. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/playlistcreatedresponse.py +0 -0
  196. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/playlistcreatedschema.py +0 -0
  197. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/playlistitem.py +0 -0
  198. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/playlistorder.py +0 -0
  199. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/policyaction.py +0 -0
  200. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/retrievemediainputinfoop.py +0 -0
  201. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/security.py +0 -0
  202. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/signingkeynotfounderror.py +0 -0
  203. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/signingkeyworkspacedto.py +0 -0
  204. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/simulcastdeleteresponse.py +0 -0
  205. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/simulcastrequest.py +0 -0
  206. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/simulcastresponse.py +0 -0
  207. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/simulcastunavailable_error.py +0 -0
  208. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/simulcastupdaterequest.py +0 -0
  209. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/simulcastupdateresponse.py +0 -0
  210. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/singingkeyspagination.py +0 -0
  211. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/sortorder.py +0 -0
  212. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/srtplaybackresponse.py +0 -0
  213. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/streamalreadydisablederror.py +0 -0
  214. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/streamalreadyenablederror.py +0 -0
  215. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/subtitleinput.py +0 -0
  216. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/successresponse.py +0 -0
  217. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/summaryresponse.py +0 -0
  218. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/track.py +0 -0
  219. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/trackduplicaterequest_error.py +0 -0
  220. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/tracksubtitlesgeneraterequest.py +0 -0
  221. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/trialplanrestrictionerror.py +0 -0
  222. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/unauthorized_error.py +0 -0
  223. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/unauthorizedresponse_error.py +0 -0
  224. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/update_a_playlistop.py +0 -0
  225. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/update_live_streamop.py +0 -0
  226. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/update_media_chaptersop.py +0 -0
  227. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/update_media_moderationop.py +0 -0
  228. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/update_media_named_entitiesop.py +0 -0
  229. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/update_media_summaryop.py +0 -0
  230. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/update_media_trackop.py +0 -0
  231. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/update_specific_simulcast_of_streamop.py +0 -0
  232. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/updated_mediaop.py +0 -0
  233. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/updated_mp4supportop.py +0 -0
  234. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/updated_source_accessop.py +0 -0
  235. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/updateplaylistrequest.py +0 -0
  236. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/updatetrackrequest.py +0 -0
  237. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/updatetrackresponse.py +0 -0
  238. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/useragentrestrictions.py +0 -0
  239. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/videoinput.py +0 -0
  240. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/viewnotfound_error.py +0 -0
  241. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/viewsbytopcontentdetails.py +0 -0
  242. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/viewscountresponse.py +0 -0
  243. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/models/watermarkinput.py +0 -0
  244. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/py.typed +0 -0
  245. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/sdkconfiguration.py +0 -0
  246. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/types/__init__.py +0 -0
  247. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/types/basemodel.py +0 -0
  248. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/utils/__init__.py +0 -0
  249. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/utils/annotations.py +0 -0
  250. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/utils/datetimes.py +0 -0
  251. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/utils/enums.py +0 -0
  252. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/utils/eventstreaming.py +0 -0
  253. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/utils/forms.py +0 -0
  254. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/utils/headers.py +0 -0
  255. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/utils/logger.py +0 -0
  256. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/utils/metadata.py +0 -0
  257. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/utils/queryparams.py +0 -0
  258. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/utils/requestbodies.py +0 -0
  259. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/utils/retries.py +0 -0
  260. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/utils/security.py +0 -0
  261. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/utils/serializers.py +0 -0
  262. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/utils/unmarshal_json_response.py +0 -0
  263. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/utils/url.py +0 -0
  264. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python/utils/values.py +0 -0
  265. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python.egg-info/SOURCES.txt +0 -0
  266. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python.egg-info/dependency_links.txt +0 -0
  267. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python.egg-info/requires.txt +0 -0
  268. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/fastpix_python.egg-info/top_level.txt +0 -0
  269. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/py.typed +0 -0
  270. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/requirements.txt +0 -0
  271. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/setup.cfg +0 -0
  272. {fastpix_python-1.1.3 → fastpix_python-1.1.4}/setup.py +0 -0
@@ -3,6 +3,35 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
 
5
5
 
6
+ ---
7
+
8
+ ## [1.1.4]
9
+
10
+ ### Changed
11
+ - **SDK version bump: `1.1.3` → `1.1.4`.**
12
+ A maintenance release that aligns the SDK's internal version identifiers and
13
+ applies behaviour-preserving code-quality cleanup. It contains no functional,
14
+ API, or behavioural changes and is fully backward compatible with `1.1.3`.
15
+
16
+ Updated identifiers:
17
+ - `__version__` / package version — now reports `1.1.4` (the internal
18
+ identifiers were previously lagging at `1.0.1`; they are now aligned with
19
+ the package version).
20
+ - `User-Agent` header — outbound requests now identify as
21
+ `fastpix-sdk/python 1.1.4`.
22
+
23
+ Maintainability:
24
+ - Internal static-analysis (SonarQube) cleanup across the SDK, samples, and
25
+ test harness — bundled request-builder parameters, shared response-handling
26
+ helpers, duplicated string literals extracted into constants, and nested
27
+ conditionals merged. No public-surface impact.
28
+
29
+ ### Compatibility
30
+ - No changes to public types, method signatures, request/response models,
31
+ default server URLs, hooks, or retry logic.
32
+ - No action required for existing integrations — upgrade the dependency and
33
+ re-run `pip install --upgrade fastpix_python`.
34
+
6
35
  ---
7
36
 
8
37
  ## [1.1.3]
@@ -23,7 +52,7 @@ All FastPix-owned hosts, API endpoints, and documentation links are being moved
23
52
  What this means for users of `fastpix_python`:
24
53
 
25
54
  - **If you rely on SDK defaults**, no code change is required. The default `server_url` in this release points at `https://api.fastpix.com/v1/`, so bumping to `1.1.3` and re-running `pip install --upgrade fastpix_python` is enough.
26
- - **If you have an explicit `server_url` override** (e.g. `Fastpixpython(server_url="https://api.fastpix.io/v1/")`), change it to `https://api.fastpix.com/v1/`.
55
+ - **If you have an explicit `server_url` override** (e.g. `Fastpix(server_url="https://api.fastpix.io/v1/")`), change it to `https://api.fastpix.com/v1/`.
27
56
  - **If your application code references FastPix asset URLs directly** — playback URLs (`stream.fastpix.io/...`), image CDN (`images.fastpix.io/...`), dashboard deep links, or doc links in your own README — update them to the `.com` equivalents before the `.io` hosts are decommissioned.
28
57
  - We strongly recommend upgrading **every official FastPix SDK** in your stack to its latest release as part of the same change — every SDK is being rolled out with the same migration.
29
58
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: fastpix_python
3
- Version: 1.1.3
3
+ Version: 1.1.4
4
4
  Summary: Python Client SDK Generated by fastpix.
5
5
  Home-page: https://github.com/FastPix/fastpix-python
6
6
  Author: FastPix
@@ -209,7 +209,7 @@ Comprehensive Python SDK for FastPix platform integration with full API coverage
209
209
 
210
210
  Upload, manage, and transform video content with comprehensive media management capabilities.
211
211
 
212
- For detailed documentation, see [FastPix Video on Demand Overview](https://fastpix.com/docs/get-started/overview).
212
+ For detailed documentation, see [FastPix Video on Demand Overview](https://fastpix.com/docs/video-on-demand-api/overview).
213
213
 
214
214
  #### Input Video
215
215
  - [Create from URL](https://github.com/FastPix/fastpix-python/blob/feature/fixed-missing-parameters/docs/sdks/inputvideo/README.md#create_from_url) - Upload video content from external URL
@@ -257,7 +257,7 @@ For detailed documentation, see [FastPix Video on Demand Overview](https://fastp
257
257
 
258
258
  Stream, manage, and transform live video content with real-time broadcasting capabilities.
259
259
 
260
- For detailed documentation, see [FastPix Live Stream Overview](https://fastpix.com/docs/get-started/live-overview).
260
+ For detailed documentation, see [FastPix Live Stream Overview](https://fastpix.com/docs/live-stream-api/overview).
261
261
 
262
262
  #### Start Live Stream
263
263
  - [Create Stream](https://github.com/FastPix/fastpix-python/blob/feature/fixed-missing-parameters/docs/sdks/startlivestream/README.md#create_stream) - Initialize new live streaming session with DVR mode support
@@ -288,7 +288,7 @@ For detailed documentation, see [FastPix Live Stream Overview](https://fastpix.c
288
288
 
289
289
  Monitor video performance and quality with comprehensive analytics and real-time metrics.
290
290
 
291
- For detailed documentation, see [FastPix Video Data Overview](https://fastpix.com/docs/concepts/what-video-data-do-we-capture).
291
+ For detailed documentation, see [FastPix Video Data Overview](https://fastpix.com/docs/video-data-api/overview).
292
292
 
293
293
  #### Metrics
294
294
  - [List Breakdown Values](https://github.com/FastPix/fastpix-python/blob/feature/fixed-missing-parameters/docs/sdks/metrics/README.md#list_breakdown_values) - Get detailed breakdown of metrics by dimension
@@ -666,6 +666,6 @@ We value community contributions and feedback. Feel free to submit pull requests
666
666
 
667
667
  ## Detailed Usage
668
668
 
669
- For comprehensive understanding of each API's functionality, including detailed request and response specifications, parameter descriptions, and additional examples, please refer to the [FastPix API Reference](https://fastpix.com/docs/video-security/secure-media-access-with-jwts).
669
+ For comprehensive understanding of each API's functionality, including detailed request and response specifications, parameter descriptions, and additional examples, please refer to the [FastPix API Reference](https://fastpix.com/docs/product-os-api/overview).
670
670
 
671
671
  The API reference offers complete documentation for all available endpoints and features, enabling developers to integrate and leverage FastPix APIs effectively.
@@ -190,7 +190,7 @@ Comprehensive Python SDK for FastPix platform integration with full API coverage
190
190
 
191
191
  Upload, manage, and transform video content with comprehensive media management capabilities.
192
192
 
193
- For detailed documentation, see [FastPix Video on Demand Overview](https://fastpix.com/docs/get-started/overview).
193
+ For detailed documentation, see [FastPix Video on Demand Overview](https://fastpix.com/docs/video-on-demand-api/overview).
194
194
 
195
195
  #### Input Video
196
196
  - [Create from URL](https://github.com/FastPix/fastpix-python/blob/feature/fixed-missing-parameters/docs/sdks/inputvideo/README.md#create_from_url) - Upload video content from external URL
@@ -238,7 +238,7 @@ For detailed documentation, see [FastPix Video on Demand Overview](https://fastp
238
238
 
239
239
  Stream, manage, and transform live video content with real-time broadcasting capabilities.
240
240
 
241
- For detailed documentation, see [FastPix Live Stream Overview](https://fastpix.com/docs/get-started/live-overview).
241
+ For detailed documentation, see [FastPix Live Stream Overview](https://fastpix.com/docs/live-stream-api/overview).
242
242
 
243
243
  #### Start Live Stream
244
244
  - [Create Stream](https://github.com/FastPix/fastpix-python/blob/feature/fixed-missing-parameters/docs/sdks/startlivestream/README.md#create_stream) - Initialize new live streaming session with DVR mode support
@@ -269,7 +269,7 @@ For detailed documentation, see [FastPix Live Stream Overview](https://fastpix.c
269
269
 
270
270
  Monitor video performance and quality with comprehensive analytics and real-time metrics.
271
271
 
272
- For detailed documentation, see [FastPix Video Data Overview](https://fastpix.com/docs/concepts/what-video-data-do-we-capture).
272
+ For detailed documentation, see [FastPix Video Data Overview](https://fastpix.com/docs/video-data-api/overview).
273
273
 
274
274
  #### Metrics
275
275
  - [List Breakdown Values](https://github.com/FastPix/fastpix-python/blob/feature/fixed-missing-parameters/docs/sdks/metrics/README.md#list_breakdown_values) - Get detailed breakdown of metrics by dimension
@@ -647,6 +647,6 @@ We value community contributions and feedback. Feel free to submit pull requests
647
647
 
648
648
  ## Detailed Usage
649
649
 
650
- For comprehensive understanding of each API's functionality, including detailed request and response specifications, parameter descriptions, and additional examples, please refer to the [FastPix API Reference](https://fastpix.com/docs/video-security/secure-media-access-with-jwts).
650
+ For comprehensive understanding of each API's functionality, including detailed request and response specifications, parameter descriptions, and additional examples, please refer to the [FastPix API Reference](https://fastpix.com/docs/product-os-api/overview).
651
651
 
652
652
  The API reference offers complete documentation for all available endpoints and features, enabling developers to integrate and leverage FastPix APIs effectively.
@@ -3,10 +3,10 @@
3
3
  import importlib.metadata
4
4
 
5
5
  __title__: str = "fastpix_python"
6
- __version__: str = "1.0.1"
6
+ __version__: str = "1.1.4"
7
7
  __openapi_doc_version__: str = "1.0.0"
8
8
  __gen_version__: str = "2.723.4"
9
- __user_agent__: str = "fastpix-sdk/python 1.0.1 2.723.4 1.0.1 fastpix_python"
9
+ __user_agent__: str = "fastpix-sdk/python 1.1.4 2.723.4 1.1.4 fastpix_python"
10
10
 
11
11
  try:
12
12
  if __package__ is not None:
@@ -0,0 +1,314 @@
1
+ """Code generated by fastpix (https://fastpix.com). DO NOT EDIT."""
2
+
3
+ from .sdkconfiguration import SDKConfiguration
4
+ from . import errors, models, utils
5
+ from ._hooks import (
6
+ AfterErrorContext,
7
+ AfterSuccessContext,
8
+ BeforeRequestContext,
9
+ )
10
+ from .utils import RetryConfig, SerializedRequestBody, get_body_content
11
+ from dataclasses import dataclass
12
+ import httpx
13
+ from typing import Any, Callable, List, Mapping, Optional, Tuple
14
+ from urllib.parse import parse_qs, urlparse
15
+
16
+
17
+ _LOG_REQUEST_EXCEPTION = "Request Exception"
18
+
19
+
20
+ @dataclass
21
+ class BuildRequestData:
22
+ """Bundles the inputs used to build an HTTP request.
23
+
24
+ Grouping these into a single object keeps the request-builder method
25
+ signatures compact while preserving the exact same set of inputs.
26
+ """
27
+
28
+ method: str
29
+ path: str
30
+ base_url: Optional[str]
31
+ url_variables: Any
32
+ request: Any
33
+ request_body_required: bool
34
+ request_has_path_params: bool
35
+ request_has_query_params: bool
36
+ user_agent_header: str
37
+ accept_header_value: str
38
+ _globals: Any = None
39
+ security: Any = None
40
+ timeout_ms: Optional[int] = None
41
+ get_serialized_body: Optional[
42
+ Callable[[], Optional[SerializedRequestBody]]
43
+ ] = None
44
+ url_override: Optional[str] = None
45
+ http_headers: Optional[Mapping[str, str]] = None
46
+
47
+
48
+ class BaseSDK:
49
+ sdk_configuration: SDKConfiguration
50
+ parent_ref: Optional[object] = None
51
+ """
52
+ Reference to the root SDK instance, if any. This will prevent it from
53
+ being garbage collected while there are active streams.
54
+ """
55
+
56
+ def __init__(
57
+ self,
58
+ sdk_config: SDKConfiguration,
59
+ parent_ref: Optional[object] = None,
60
+ ) -> None:
61
+ self.sdk_configuration = sdk_config
62
+ self.parent_ref = parent_ref
63
+
64
+ def _get_url(self, base_url, url_variables):
65
+ sdk_url, sdk_variables = self.sdk_configuration.get_server_details()
66
+
67
+ if base_url is None:
68
+ base_url = sdk_url
69
+
70
+ if url_variables is None:
71
+ url_variables = sdk_variables
72
+
73
+ return utils.template_url(base_url, url_variables)
74
+
75
+ def _build_request_async(self, data: BuildRequestData) -> httpx.Request:
76
+ client = self.sdk_configuration.async_client
77
+ return self._build_request_with_client(client, data)
78
+
79
+ def _build_request(self, data: BuildRequestData) -> httpx.Request:
80
+ client = self.sdk_configuration.client
81
+ return self._build_request_with_client(client, data)
82
+
83
+ def _build_url_and_query(
84
+ self,
85
+ url_override,
86
+ base_url,
87
+ url_variables,
88
+ path,
89
+ request,
90
+ _globals,
91
+ request_has_path_params,
92
+ request_has_query_params,
93
+ ):
94
+ if url_override is not None:
95
+ # Pick up the query parameter from the override so they can be
96
+ # preserved when building the request later on (necessary as of
97
+ # httpx 0.28).
98
+ parsed_override = urlparse(str(url_override))
99
+ return url_override, parse_qs(
100
+ parsed_override.query, keep_blank_values=True
101
+ )
102
+
103
+ url = utils.generate_url(
104
+ self._get_url(base_url, url_variables),
105
+ path,
106
+ request if request_has_path_params else None,
107
+ _globals if request_has_path_params else None,
108
+ )
109
+ query_params = utils.get_query_params(
110
+ request if request_has_query_params else None,
111
+ _globals if request_has_query_params else None,
112
+ )
113
+ return url, query_params
114
+
115
+ def _apply_security(self, headers, query_params, security):
116
+ if security is not None and callable(security):
117
+ security = security()
118
+ security = utils.get_security_from_env(security, models.Security)
119
+ if security is not None:
120
+ security_headers, security_query_params = utils.get_security(security)
121
+ headers = {**headers, **security_headers}
122
+ query_params = {**query_params, **security_query_params}
123
+ return headers, query_params
124
+
125
+ def _serialize_request_body(self, get_serialized_body, request_body_required):
126
+ serialized_request_body = SerializedRequestBody()
127
+ if get_serialized_body is None:
128
+ return serialized_request_body
129
+
130
+ rb = get_serialized_body()
131
+ if request_body_required and rb is None:
132
+ raise ValueError("request body is required")
133
+ if rb is not None:
134
+ serialized_request_body = rb
135
+ return serialized_request_body
136
+
137
+ def _build_request_with_client(
138
+ self, client, data: BuildRequestData
139
+ ) -> httpx.Request:
140
+ url, query_params = self._build_url_and_query(
141
+ data.url_override,
142
+ data.base_url,
143
+ data.url_variables,
144
+ data.path,
145
+ data.request,
146
+ data._globals,
147
+ data.request_has_path_params,
148
+ data.request_has_query_params,
149
+ )
150
+
151
+ headers = utils.get_headers(data.request, data._globals)
152
+ headers["Accept"] = data.accept_header_value
153
+ headers[data.user_agent_header] = self.sdk_configuration.user_agent
154
+
155
+ headers, query_params = self._apply_security(
156
+ headers, query_params, data.security
157
+ )
158
+
159
+ serialized_request_body = self._serialize_request_body(
160
+ data.get_serialized_body, data.request_body_required
161
+ )
162
+
163
+ if (
164
+ serialized_request_body.media_type is not None
165
+ and serialized_request_body.media_type
166
+ not in (
167
+ "multipart/form-data",
168
+ "multipart/mixed",
169
+ )
170
+ ):
171
+ headers["content-type"] = serialized_request_body.media_type
172
+
173
+ if data.http_headers is not None:
174
+ for header, value in data.http_headers.items():
175
+ headers[header] = value
176
+
177
+ timeout = data.timeout_ms / 1000 if data.timeout_ms is not None else None
178
+
179
+ return client.build_request(
180
+ data.method,
181
+ url,
182
+ params=query_params,
183
+ content=serialized_request_body.content,
184
+ data=serialized_request_body.data,
185
+ files=serialized_request_body.files,
186
+ headers=headers,
187
+ timeout=timeout,
188
+ )
189
+
190
+ @staticmethod
191
+ def _log_request(logger, req):
192
+ logger.debug(
193
+ "Request:\nMethod: %s\nURL: %s\nHeaders: %s\nBody: %s",
194
+ req.method,
195
+ req.url,
196
+ req.headers,
197
+ get_body_content(req),
198
+ )
199
+
200
+ def _handle_response(
201
+ self, http_res, hook_ctx, error_status_codes, stream, hooks, logger
202
+ ):
203
+ if http_res is None:
204
+ logger.debug("Raising no response SDK error")
205
+ raise errors.NoResponseError("No response received")
206
+
207
+ logger.debug(
208
+ "Response:\nStatus Code: %s\nURL: %s\nHeaders: %s\nBody: %s",
209
+ http_res.status_code,
210
+ http_res.url,
211
+ http_res.headers,
212
+ "<streaming response>" if stream else http_res.text,
213
+ )
214
+
215
+ if not utils.match_status_codes(error_status_codes, http_res.status_code):
216
+ return http_res
217
+
218
+ result, err = hooks.after_error(AfterErrorContext(hook_ctx), http_res, None)
219
+ if err is not None:
220
+ logger.debug(_LOG_REQUEST_EXCEPTION, exc_info=True)
221
+ raise err
222
+ if result is not None:
223
+ return result
224
+
225
+ logger.debug("Raising unexpected SDK error")
226
+ raise errors.FastpixDefaultError("Unexpected error occurred", http_res)
227
+
228
+ def do_request(
229
+ self,
230
+ hook_ctx,
231
+ request,
232
+ error_status_codes,
233
+ stream=False,
234
+ retry_config: Optional[Tuple[RetryConfig, List[str]]] = None,
235
+ ) -> httpx.Response:
236
+ client = self.sdk_configuration.client
237
+ logger = self.sdk_configuration.debug_logger
238
+
239
+ hooks = self.sdk_configuration.__dict__["_hooks"]
240
+
241
+ def do():
242
+ http_res = None
243
+ try:
244
+ req = hooks.before_request(BeforeRequestContext(hook_ctx), request)
245
+ self._log_request(logger, req)
246
+
247
+ if client is None:
248
+ raise ValueError("client is required")
249
+
250
+ http_res = client.send(req, stream=stream)
251
+ except Exception as e:
252
+ _, e = hooks.after_error(AfterErrorContext(hook_ctx), None, e)
253
+ if e is not None:
254
+ logger.debug(_LOG_REQUEST_EXCEPTION, exc_info=True)
255
+ raise e
256
+
257
+ return self._handle_response(
258
+ http_res, hook_ctx, error_status_codes, stream, hooks, logger
259
+ )
260
+
261
+ if retry_config is not None:
262
+ http_res = utils.retry(do, utils.Retries(retry_config[0], retry_config[1]))
263
+ else:
264
+ http_res = do()
265
+
266
+ if not utils.match_status_codes(error_status_codes, http_res.status_code):
267
+ http_res = hooks.after_success(AfterSuccessContext(hook_ctx), http_res)
268
+
269
+ return http_res
270
+
271
+ async def do_request_async(
272
+ self,
273
+ hook_ctx,
274
+ request,
275
+ error_status_codes,
276
+ stream=False,
277
+ retry_config: Optional[Tuple[RetryConfig, List[str]]] = None,
278
+ ) -> httpx.Response:
279
+ client = self.sdk_configuration.async_client
280
+ logger = self.sdk_configuration.debug_logger
281
+
282
+ hooks = self.sdk_configuration.__dict__["_hooks"]
283
+
284
+ async def do():
285
+ http_res = None
286
+ try:
287
+ req = hooks.before_request(BeforeRequestContext(hook_ctx), request)
288
+ self._log_request(logger, req)
289
+
290
+ if client is None:
291
+ raise ValueError("client is required")
292
+
293
+ http_res = await client.send(req, stream=stream)
294
+ except Exception as e:
295
+ _, e = hooks.after_error(AfterErrorContext(hook_ctx), None, e)
296
+ if e is not None:
297
+ logger.debug(_LOG_REQUEST_EXCEPTION, exc_info=True)
298
+ raise e
299
+
300
+ return self._handle_response(
301
+ http_res, hook_ctx, error_status_codes, stream, hooks, logger
302
+ )
303
+
304
+ if retry_config is not None:
305
+ http_res = await utils.retry_async(
306
+ do, utils.Retries(retry_config[0], retry_config[1])
307
+ )
308
+ else:
309
+ http_res = await do()
310
+
311
+ if not utils.match_status_codes(error_status_codes, http_res.status_code):
312
+ http_res = hooks.after_success(AfterSuccessContext(hook_ctx), http_res)
313
+
314
+ return http_res