2929from ..lib .polling_async import async_poll_until
3030from ..types .blueprint_view import BlueprintView
3131from ..types .blueprint_preview_view import BlueprintPreviewView
32- from ..types .inspection_source_param import InspectionSourceParam
3332from ..types .blueprint_build_logs_list_view import BlueprintBuildLogsListView
3433from ..types .shared_params .launch_parameters import LaunchParameters
3534from ..types .shared_params .code_mount_parameters import CodeMountParameters
@@ -72,11 +71,16 @@ def with_streaming_response(self) -> BlueprintsResourceWithStreamingResponse:
7271 def create (
7372 self ,
7473 * ,
75- inspection_source : InspectionSourceParam ,
7674 name : str ,
75+ base_blueprint_id : Optional [str ] | Omit = omit ,
76+ base_blueprint_name : Optional [str ] | Omit = omit ,
77+ build_args : Optional [Dict [str , str ]] | Omit = omit ,
78+ code_mounts : Optional [Iterable [CodeMountParameters ]] | Omit = omit ,
79+ dockerfile : Optional [str ] | Omit = omit ,
7780 file_mounts : Optional [Dict [str , str ]] | Omit = omit ,
7881 launch_parameters : Optional [LaunchParameters ] | Omit = omit ,
7982 metadata : Optional [Dict [str , str ]] | Omit = omit ,
83+ services : Optional [Iterable [blueprint_create_params .Service ]] | Omit = omit ,
8084 system_setup_commands : Optional [SequenceNotStr [str ]] | Omit = omit ,
8185 # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
8286 # The extra values given here take precedence over values defined on the client or passed to this method.
@@ -86,23 +90,40 @@ def create(
8690 timeout : float | httpx .Timeout | None | NotGiven = not_given ,
8791 idempotency_key : str | None = None ,
8892 ) -> BlueprintView :
89- """
90- Starts build of custom defined container Blueprint using a RepositoryConnection
91- Inspection as a source container specification.
93+ """Starts build of custom defined container Blueprint.
9294
93- Args:
94- inspection_source: (Optional) Use a RepositoryInspection a source of a Blueprint build. The
95- Dockerfile will be automatically created based on the RepositoryInspection
96- contents .
95+ The Blueprint will begin in
96+ the 'provisioning' step and transition to the 'building' step once it is
97+ selected off the build queue., Upon build complete it will transition to
98+ 'building_complete' if the build is successful .
9799
100+ Args:
98101 name: Name of the Blueprint.
99102
103+ base_blueprint_id: (Optional) ID of previously built blueprint to use as a base blueprint for this
104+ build.
105+
106+ base_blueprint_name: (Optional) Name of previously built blueprint to use as a base blueprint for
107+ this build. When set, this will load the latest successfully built Blueprint
108+ with the given name. Only one of (base_blueprint_id, base_blueprint_name) should
109+ be specified.
110+
111+ build_args: (Optional) Arbitrary Docker build args to pass during build.
112+
113+ code_mounts: A list of code mounts to be included in the Blueprint.
114+
115+ dockerfile: Dockerfile contents to be used to build the Blueprint.
116+
100117 file_mounts: (Optional) Map of paths and file contents to write before setup.
101118
102119 launch_parameters: Parameters to configure your Devbox at launch time.
103120
104121 metadata: (Optional) User defined metadata for the Blueprint.
105122
123+ services: (Optional) List of containerized services to include in the Blueprint. These
124+ services will be pre-pulled during the build phase for optimized startup
125+ performance.
126+
106127 system_setup_commands: A list of commands to run to set up your system.
107128
108129 extra_headers: Send extra headers
@@ -119,11 +140,16 @@ def create(
119140 "/v1/blueprints" ,
120141 body = maybe_transform (
121142 {
122- "inspection_source" : inspection_source ,
123143 "name" : name ,
144+ "base_blueprint_id" : base_blueprint_id ,
145+ "base_blueprint_name" : base_blueprint_name ,
146+ "build_args" : build_args ,
147+ "code_mounts" : code_mounts ,
148+ "dockerfile" : dockerfile ,
124149 "file_mounts" : file_mounts ,
125150 "launch_parameters" : launch_parameters ,
126151 "metadata" : metadata ,
152+ "services" : services ,
127153 "system_setup_commands" : system_setup_commands ,
128154 },
129155 blueprint_create_params .BlueprintCreateParams ,
@@ -570,11 +596,16 @@ def with_streaming_response(self) -> AsyncBlueprintsResourceWithStreamingRespons
570596 async def create (
571597 self ,
572598 * ,
573- inspection_source : InspectionSourceParam ,
574599 name : str ,
600+ base_blueprint_id : Optional [str ] | Omit = omit ,
601+ base_blueprint_name : Optional [str ] | Omit = omit ,
602+ build_args : Optional [Dict [str , str ]] | Omit = omit ,
603+ code_mounts : Optional [Iterable [CodeMountParameters ]] | Omit = omit ,
604+ dockerfile : Optional [str ] | Omit = omit ,
575605 file_mounts : Optional [Dict [str , str ]] | Omit = omit ,
576606 launch_parameters : Optional [LaunchParameters ] | Omit = omit ,
577607 metadata : Optional [Dict [str , str ]] | Omit = omit ,
608+ services : Optional [Iterable [blueprint_create_params .Service ]] | Omit = omit ,
578609 system_setup_commands : Optional [SequenceNotStr [str ]] | Omit = omit ,
579610 # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
580611 # The extra values given here take precedence over values defined on the client or passed to this method.
@@ -584,23 +615,40 @@ async def create(
584615 timeout : float | httpx .Timeout | None | NotGiven = not_given ,
585616 idempotency_key : str | None = None ,
586617 ) -> BlueprintView :
587- """
588- Starts build of custom defined container Blueprint using a RepositoryConnection
589- Inspection as a source container specification.
618+ """Starts build of custom defined container Blueprint.
590619
591- Args:
592- inspection_source: (Optional) Use a RepositoryInspection a source of a Blueprint build. The
593- Dockerfile will be automatically created based on the RepositoryInspection
594- contents .
620+ The Blueprint will begin in
621+ the 'provisioning' step and transition to the 'building' step once it is
622+ selected off the build queue., Upon build complete it will transition to
623+ 'building_complete' if the build is successful .
595624
625+ Args:
596626 name: Name of the Blueprint.
597627
628+ base_blueprint_id: (Optional) ID of previously built blueprint to use as a base blueprint for this
629+ build.
630+
631+ base_blueprint_name: (Optional) Name of previously built blueprint to use as a base blueprint for
632+ this build. When set, this will load the latest successfully built Blueprint
633+ with the given name. Only one of (base_blueprint_id, base_blueprint_name) should
634+ be specified.
635+
636+ build_args: (Optional) Arbitrary Docker build args to pass during build.
637+
638+ code_mounts: A list of code mounts to be included in the Blueprint.
639+
640+ dockerfile: Dockerfile contents to be used to build the Blueprint.
641+
598642 file_mounts: (Optional) Map of paths and file contents to write before setup.
599643
600644 launch_parameters: Parameters to configure your Devbox at launch time.
601645
602646 metadata: (Optional) User defined metadata for the Blueprint.
603647
648+ services: (Optional) List of containerized services to include in the Blueprint. These
649+ services will be pre-pulled during the build phase for optimized startup
650+ performance.
651+
604652 system_setup_commands: A list of commands to run to set up your system.
605653
606654 extra_headers: Send extra headers
@@ -617,11 +665,16 @@ async def create(
617665 "/v1/blueprints" ,
618666 body = await async_maybe_transform (
619667 {
620- "inspection_source" : inspection_source ,
621668 "name" : name ,
669+ "base_blueprint_id" : base_blueprint_id ,
670+ "base_blueprint_name" : base_blueprint_name ,
671+ "build_args" : build_args ,
672+ "code_mounts" : code_mounts ,
673+ "dockerfile" : dockerfile ,
622674 "file_mounts" : file_mounts ,
623675 "launch_parameters" : launch_parameters ,
624676 "metadata" : metadata ,
677+ "services" : services ,
625678 "system_setup_commands" : system_setup_commands ,
626679 },
627680 blueprint_create_params .BlueprintCreateParams ,
0 commit comments