LexModelsV2 / Client / list_bot_versions
list_bot_versions#
- LexModelsV2.Client.list_bot_versions(**kwargs)#
Gets information about all of the versions of a bot.
The
ListBotVersions
operation returns a summary of each version of a bot. For example, if a bot has three numbered versions, theListBotVersions
operation returns for summaries, one for each numbered version and one for theDRAFT
version.The
ListBotVersions
operation always returns at least one version, theDRAFT
version.See also: AWS API Documentation
Request Syntax
response = client.list_bot_versions( botId='string', sortBy={ 'attribute': 'BotVersion', 'order': 'Ascending'|'Descending' }, maxResults=123, nextToken='string' )
- Parameters:
botId (string) –
[REQUIRED]
The identifier of the bot to list versions for.
sortBy (dict) –
Specifies sorting parameters for the list of versions. You can specify that the list be sorted by version name in either ascending or descending order.
attribute (string) – [REQUIRED]
The attribute to use to sort the list of versions.
order (string) – [REQUIRED]
The order to sort the list. You can specify ascending or descending order.
maxResults (integer) – The maximum number of versions to return in each page of results. If there are fewer results than the max page size, only the actual number of results are returned.
nextToken (string) – If the response to the
ListBotVersion
operation contains more results than specified in themaxResults
parameter, a token is returned in the response. Use that token in thenextToken
parameter to return the next page of results.
- Return type:
dict
- Returns:
Response Syntax
{ 'botId': 'string', 'botVersionSummaries': [ { 'botName': 'string', 'botVersion': 'string', 'description': 'string', 'botStatus': 'Creating'|'Available'|'Inactive'|'Deleting'|'Failed'|'Versioning'|'Importing'|'Updating', 'creationDateTime': datetime(2015, 1, 1) }, ], 'nextToken': 'string' }
Response Structure
(dict) –
botId (string) –
The identifier of the bot to list versions for.
botVersionSummaries (list) –
Summary information for the bot versions that meet the filter criteria specified in the request. The length of the list is specified in the
maxResults
parameter of the request. If there are more versions available, thenextToken
field contains a token to get the next page of results.(dict) –
Summary information about a bot version returned by the ListBotVersions operation.
botName (string) –
The name of the bot associated with the version.
botVersion (string) –
The numeric version of the bot, or
DRAFT
to indicate that this is the version of the bot that can be updated..description (string) –
The description of the version.
botStatus (string) –
The status of the bot. When the status is available, the version of the bot is ready for use.
creationDateTime (datetime) –
A timestamp of the date and time that the version was created.
nextToken (string) –
A token that indicates whether there are more results to return in a response to the
ListBotVersions
operation. If thenextToken
field is present, you send the contents as thenextToken
parameter of aListBotAliases
operation request to get the next page of results.
Exceptions
LexModelsV2.Client.exceptions.ThrottlingException
LexModelsV2.Client.exceptions.ServiceQuotaExceededException
LexModelsV2.Client.exceptions.ValidationException
LexModelsV2.Client.exceptions.InternalServerException