66
77import httpx
88
9- from ..types import blueprint_list_params , blueprint_create_params , blueprint_preview_params
9+ from ..types import (
10+ blueprint_list_params ,
11+ blueprint_create_params ,
12+ blueprint_preview_params ,
13+ blueprint_list_public_params ,
14+ )
1015from .._types import NOT_GIVEN , Body , Query , Headers , NotGiven
1116from .._utils import maybe_transform , async_maybe_transform
1217from .._compat import cached_property
@@ -349,6 +354,57 @@ def delete(
349354 cast_to = object ,
350355 )
351356
357+ def list_public (
358+ self ,
359+ * ,
360+ limit : int | NotGiven = NOT_GIVEN ,
361+ name : str | NotGiven = NOT_GIVEN ,
362+ starting_after : str | NotGiven = NOT_GIVEN ,
363+ # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
364+ # The extra values given here take precedence over values defined on the client or passed to this method.
365+ extra_headers : Headers | None = None ,
366+ extra_query : Query | None = None ,
367+ extra_body : Body | None = None ,
368+ timeout : float | httpx .Timeout | None | NotGiven = NOT_GIVEN ,
369+ ) -> SyncBlueprintsCursorIDPage [BlueprintView ]:
370+ """
371+ List all public Blueprints that are available to all users.
372+
373+ Args:
374+ limit: The limit of items to return. Default is 20.
375+
376+ name: Filter by name
377+
378+ starting_after: Load the next page of data starting after the item with the given ID.
379+
380+ extra_headers: Send extra headers
381+
382+ extra_query: Add additional query parameters to the request
383+
384+ extra_body: Add additional JSON properties to the request
385+
386+ timeout: Override the client-level default timeout for this request, in seconds
387+ """
388+ return self ._get_api_list (
389+ "/v1/blueprints/list_public" ,
390+ page = SyncBlueprintsCursorIDPage [BlueprintView ],
391+ options = make_request_options (
392+ extra_headers = extra_headers ,
393+ extra_query = extra_query ,
394+ extra_body = extra_body ,
395+ timeout = timeout ,
396+ query = maybe_transform (
397+ {
398+ "limit" : limit ,
399+ "name" : name ,
400+ "starting_after" : starting_after ,
401+ },
402+ blueprint_list_public_params .BlueprintListPublicParams ,
403+ ),
404+ ),
405+ model = BlueprintView ,
406+ )
407+
352408 def logs (
353409 self ,
354410 id : str ,
@@ -769,6 +825,57 @@ async def delete(
769825 cast_to = object ,
770826 )
771827
828+ def list_public (
829+ self ,
830+ * ,
831+ limit : int | NotGiven = NOT_GIVEN ,
832+ name : str | NotGiven = NOT_GIVEN ,
833+ starting_after : str | NotGiven = NOT_GIVEN ,
834+ # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
835+ # The extra values given here take precedence over values defined on the client or passed to this method.
836+ extra_headers : Headers | None = None ,
837+ extra_query : Query | None = None ,
838+ extra_body : Body | None = None ,
839+ timeout : float | httpx .Timeout | None | NotGiven = NOT_GIVEN ,
840+ ) -> AsyncPaginator [BlueprintView , AsyncBlueprintsCursorIDPage [BlueprintView ]]:
841+ """
842+ List all public Blueprints that are available to all users.
843+
844+ Args:
845+ limit: The limit of items to return. Default is 20.
846+
847+ name: Filter by name
848+
849+ starting_after: Load the next page of data starting after the item with the given ID.
850+
851+ extra_headers: Send extra headers
852+
853+ extra_query: Add additional query parameters to the request
854+
855+ extra_body: Add additional JSON properties to the request
856+
857+ timeout: Override the client-level default timeout for this request, in seconds
858+ """
859+ return self ._get_api_list (
860+ "/v1/blueprints/list_public" ,
861+ page = AsyncBlueprintsCursorIDPage [BlueprintView ],
862+ options = make_request_options (
863+ extra_headers = extra_headers ,
864+ extra_query = extra_query ,
865+ extra_body = extra_body ,
866+ timeout = timeout ,
867+ query = maybe_transform (
868+ {
869+ "limit" : limit ,
870+ "name" : name ,
871+ "starting_after" : starting_after ,
872+ },
873+ blueprint_list_public_params .BlueprintListPublicParams ,
874+ ),
875+ ),
876+ model = BlueprintView ,
877+ )
878+
772879 async def logs (
773880 self ,
774881 id : str ,
@@ -898,6 +1005,9 @@ def __init__(self, blueprints: BlueprintsResource) -> None:
8981005 self .delete = to_raw_response_wrapper (
8991006 blueprints .delete ,
9001007 )
1008+ self .list_public = to_raw_response_wrapper (
1009+ blueprints .list_public ,
1010+ )
9011011 self .logs = to_raw_response_wrapper (
9021012 blueprints .logs ,
9031013 )
@@ -922,6 +1032,9 @@ def __init__(self, blueprints: AsyncBlueprintsResource) -> None:
9221032 self .delete = async_to_raw_response_wrapper (
9231033 blueprints .delete ,
9241034 )
1035+ self .list_public = async_to_raw_response_wrapper (
1036+ blueprints .list_public ,
1037+ )
9251038 self .logs = async_to_raw_response_wrapper (
9261039 blueprints .logs ,
9271040 )
@@ -946,6 +1059,9 @@ def __init__(self, blueprints: BlueprintsResource) -> None:
9461059 self .delete = to_streamed_response_wrapper (
9471060 blueprints .delete ,
9481061 )
1062+ self .list_public = to_streamed_response_wrapper (
1063+ blueprints .list_public ,
1064+ )
9491065 self .logs = to_streamed_response_wrapper (
9501066 blueprints .logs ,
9511067 )
@@ -970,6 +1086,9 @@ def __init__(self, blueprints: AsyncBlueprintsResource) -> None:
9701086 self .delete = async_to_streamed_response_wrapper (
9711087 blueprints .delete ,
9721088 )
1089+ self .list_public = async_to_streamed_response_wrapper (
1090+ blueprints .list_public ,
1091+ )
9731092 self .logs = async_to_streamed_response_wrapper (
9741093 blueprints .logs ,
9751094 )
0 commit comments