Skip to main content

documentation_versions

Creates, updates, deletes or gets a documentation_version resource or lists documentation_versions in a region

Overview

Namedocumentation_versions
TypeResource
DescriptionThe AWS::ApiGateway::DocumentationVersion resource creates a snapshot of the documentation for an API. For more information, see [Representation of API Documentation in API Gateway](https://docs.aws.amazon.com/apigateway/latest/developerguide/api-gateway-documenting-api-content-representation.html) in the *API Gateway Developer Guide*.
Idaws.apigateway.documentation_versions

Fields

NameDatatypeDescription
descriptionstringA description about the new documentation snapshot.
documentation_versionstringThe version identifier of the to-be-updated documentation version.
rest_api_idstringThe string identifier of the associated RestApi.
regionstringAWS region.

Methods

NameAccessible byRequired Params
create_resourceINSERTDocumentationVersion, RestApiId, region
delete_resourceDELETEdata__Identifier, region
update_resourceUPDATEdata__Identifier, data__PatchDocument, region
list_resourcesSELECTregion
get_resourceSELECTdata__Identifier, region

SELECT examples

Gets all documentation_versions in a region.

SELECT
region,
description,
documentation_version,
rest_api_id
FROM aws.apigateway.documentation_versions
WHERE region = 'us-east-1';

Gets all properties from an individual documentation_version.

SELECT
region,
description,
documentation_version,
rest_api_id
FROM aws.apigateway.documentation_versions
WHERE region = 'us-east-1' AND data__Identifier = '<DocumentationVersion>|<RestApiId>';

INSERT example

Use the following StackQL query and manifest file to create a new documentation_version resource, using stack-deploy.

/*+ create */
INSERT INTO aws.apigateway.documentation_versions (
DocumentationVersion,
RestApiId,
region
)
SELECT
'{{ DocumentationVersion }}',
'{{ RestApiId }}',
'{{ region }}';

DELETE example

/*+ delete */
DELETE FROM aws.apigateway.documentation_versions
WHERE data__Identifier = '<DocumentationVersion|RestApiId>'
AND region = 'us-east-1';

Permissions

To operate on the documentation_versions resource, the following permissions are required:

Create

apigateway:GET,
apigateway:POST

Read

apigateway:GET

Update

apigateway:GET,
apigateway:PATCH

Delete

apigateway:DELETE

List

apigateway:GET