start_q_app_session
async
¶
start_q_app_session(
instance_id: InstanceId,
app_id: UUID,
app_version: AppVersion,
*,
config_overrides: Optional[AsyncQAppsClientConfig] = None,
initial_values: Optional[CardValueList] = None,
session_id: Optional[str] = None,
tags: Optional[TagMap] = None,
) -> StartQAppSessionOutput
Starts a new session for an Amazon Q App, allowing inputs to be provided and the app to be run.
Each Q App session will be condensed into a single conversation in the web experience.
Parameters:
-
instance_id(InstanceId) –The unique identifier of the Amazon Q Business application environment instance.
-
app_id(UUID) –The unique identifier of the Q App to start a session for.
-
app_version(AppVersion) –The version of the Q App to use for the session.
-
initial_values(Optional[CardValueList], default:None) –Optional initial input values to provide for the Q App session.
-
session_id(Optional[str], default:None) –The unique identifier of the a Q App session.
-
tags(Optional[TagMap], default:None) –Optional tags to associate with the new Q App session.
Raises:
-
AccessDeniedException–The client is not authorized to perform the requested operation.
-
InternalServerException–An internal service error occurred while processing the request.
-
ResourceNotFoundException–The requested resource could not be found.
-
ServiceQuotaExceededException–The requested operation could not be completed because it would exceed the service's quota or limit.
-
ThrottlingException–The requested operation could not be completed because too many requests were sent at once. Wait a bit and try again later.
-
UnauthorizedException–The client is not authenticated or authorized to perform the requested operation.
-
ValidationException–The input failed to satisfy the constraints specified by the service.
-
UnknownServiceError–The service returned an error code this client does not model.
Examples:
Start a session for an Amazon Q App using version 1, passing in initial values for one card
>>> await client.start_q_app_session(instance_id='4cc5e4c2-d2a2-4188-a114-9ca125b4aedc', app_id='65e7dce7-226a-47f9-b689-22850becef89', app_version=1, initial_values=[{'cardId': '6fb5b404-3b7b-48a4-8a8b-56406922a606', 'value': 'What is the circumference of Earth?'}])
Source code in docs_src/capo_qapps/_services/async_q_apps.py
1820 1821 1822 1823 1824 1825 1826 1827 1828 1829 1830 1831 1832 1833 1834 1835 1836 1837 1838 1839 1840 1841 1842 1843 1844 1845 1846 1847 1848 1849 1850 1851 1852 1853 1854 1855 1856 1857 1858 1859 1860 1861 1862 1863 1864 1865 1866 1867 1868 1869 1870 1871 1872 1873 1874 1875 1876 1877 1878 1879 1880 1881 1882 1883 1884 1885 1886 1887 1888 1889 1890 1891 1892 1893 1894 1895 | |