@@ -65,6 +65,9 @@ def build_request(
6565 tools: Tools to apply to the products. Order defines
6666 the toolchain order of operatations.
6767
68+ Raises:
69+ planet.specs.SpecificationException: If order_type is not a valid
70+ order type.
6871 '''
6972 details = {
7073 'name' : name ,
@@ -106,6 +109,11 @@ def product(
106109 fallback_bundle: In case product_bundle not having
107110 all asset types available, which would result in failed
108111 delivery, try a fallback bundle
112+
113+ Raises:
114+ planet.specs.SpecificationException: If bundle or fallback bundle
115+ are not valid bundles or if item_type is not valid for the given
116+ bundle or fallback bundle.
109117 '''
110118 product_bundle = specs .validate_bundle (product_bundle )
111119 item_type = specs .validate_item_type (item_type , product_bundle )
@@ -171,6 +179,9 @@ def delivery(
171179 archive file that is received. Uses the template variables
172180 {{name}} and {{order_id}}. e.g. "{{name}}_{{order_id}}.zip".
173181 cloud_config: Cloud delivery configuration.
182+
183+ Raises:
184+ planet.specs.SpecificationException: If archive_type is not valid.
174185 '''
175186 if archive_type :
176187 archive_type = specs .validate_archive_type (archive_type )
@@ -302,6 +313,10 @@ def _tool(name: str, parameters: dict) -> dict:
302313 Parameters:
303314 name: Tool name.
304315 parameters: Tool parameters.
316+
317+ Raises:
318+ planet.specs.SpecificationException: If name is not the name of a valid
319+ Orders API tool.
305320 '''
306321 name = specs .validate_tool (name )
307322 return {name : parameters }
@@ -356,7 +371,12 @@ def file_format_tool(file_format: str) -> dict:
356371
357372 Parameters:
358373 file_format: The format of the tool output. Either 'COG' or 'PL_NITF'.
374+
375+ Raises:
376+ planet.specs.SpecificationException: If file_format is not one of
377+ 'COG' or 'PL_NITF'
359378 '''
379+ file_format = specs .validate_file_format (file_format )
360380 return _tool ('file_format' , {'format' : file_format })
361381
362382
0 commit comments