Skip to content

Api Gateway  >  Operations  >  import_documentation_parts

import_documentation_parts

Operation

import_documentation_parts async

import_documentation_parts(input: ImportDocumentationPartsInput, plugins: list[Plugin] | None = None) -> ImportDocumentationPartsOutput

Imports documentation parts

Parameters:

Name Type Description Default
input ImportDocumentationPartsInput

An instance of ImportDocumentationPartsInput.

required
plugins list[Plugin] | None

A list of callables that modify the configuration dynamically. Changes made by these plugins only apply for the duration of the operation execution and will not affect any other operation invocations.

None

Returns:

Type Description
ImportDocumentationPartsOutput

An instance of ImportDocumentationPartsOutput.

Input

ImportDocumentationPartsInput dataclass

Import documentation parts from an external (e.g., OpenAPI) definition file.

Attributes

body class-attribute instance-attribute
body: bytes | None = None

Raw byte array representing the to-be-imported documentation parts. To import from an OpenAPI file, this is a JSON object.

fail_on_warnings class-attribute instance-attribute
fail_on_warnings: bool = False

A query parameter to specify whether to rollback the documentation importation (true) or not (false) when a warning is encountered. The default value is false.

mode class-attribute instance-attribute
mode: PutMode | None = None

A query parameter to indicate whether to overwrite (overwrite) any existing DocumentationParts definition or to merge (merge) the new definition into the existing one. The default value is merge.

rest_api_id class-attribute instance-attribute
rest_api_id: str | None = None

The string identifier of the associated RestApi.

Output

ImportDocumentationPartsOutput dataclass

A collection of the imported DocumentationPart identifiers.

Attributes

ids class-attribute instance-attribute
ids: list[str] | None = None

A list of the returned documentation part identifiers.

warnings class-attribute instance-attribute
warnings: list[str] | None = None

A list of warning messages reported during import of documentation parts.