/AWS1/IF_QQC=>UPDATEAIPROMPT()¶
About UpdateAIPrompt¶
Updates an AI Prompt.
Method Signature¶
METHODS /AWS1/IF_QQC~UPDATEAIPROMPT
IMPORTING
!IV_CLIENTTOKEN TYPE /AWS1/QQCCLIENTTOKEN OPTIONAL
!IV_ASSISTANTID TYPE /AWS1/QQCUUIDORARN OPTIONAL
!IV_AIPROMPTID TYPE /AWS1/QQCUUIDORARNOREITHERWQ00 OPTIONAL
!IV_VISIBILITYSTATUS TYPE /AWS1/QQCVISIBILITYSTATUS OPTIONAL
!IO_TEMPLATECONFIGURATION TYPE REF TO /AWS1/CL_QQCAIPROMPTTMPLCONF OPTIONAL
!IV_DESCRIPTION TYPE /AWS1/QQCDESCRIPTION OPTIONAL
!IV_MODELID TYPE /AWS1/QQCAIPROMPTMODELID OPTIONAL
RETURNING
VALUE(OO_OUTPUT) TYPE REF TO /aws1/cl_qqcupdateaipromptrsp
RAISING
/AWS1/CX_QQCACCESSDENIEDEX
/AWS1/CX_QQCCONFLICTEXCEPTION
/AWS1/CX_QQCRESOURCENOTFOUNDEX
/AWS1/CX_QQCTHROTTLINGEX
/AWS1/CX_QQCUNAUTHORIZEDEX
/AWS1/CX_QQCVALIDATIONEX
/AWS1/CX_QQCCLIENTEXC
/AWS1/CX_QQCSERVEREXC
/AWS1/CX_RT_TECHNICAL_GENERIC
/AWS1/CX_RT_SERVICE_GENERIC.
IMPORTING¶
Required arguments:¶
iv_assistantid TYPE /AWS1/QQCUUIDORARN /AWS1/QQCUUIDORARN¶
The identifier of the Amazon Q in Connect assistant. Can be either the ID or the ARN. URLs cannot contain the ARN.
iv_aipromptid TYPE /AWS1/QQCUUIDORARNOREITHERWQ00 /AWS1/QQCUUIDORARNOREITHERWQ00¶
The identifier of the Amazon Q in Connect AI Prompt.
iv_visibilitystatus TYPE /AWS1/QQCVISIBILITYSTATUS /AWS1/QQCVISIBILITYSTATUS¶
The visibility status of the Amazon Q in Connect AI prompt.
Optional arguments:¶
iv_clienttoken TYPE /AWS1/QQCCLIENTTOKEN /AWS1/QQCCLIENTTOKEN¶
A unique, case-sensitive identifier that you provide to ensure the idempotency of the request. If not provided, the Amazon Web Services SDK populates this field. For more information about idempotency, see Making retries safe with idempotent APIs..
io_templateconfiguration TYPE REF TO /AWS1/CL_QQCAIPROMPTTMPLCONF /AWS1/CL_QQCAIPROMPTTMPLCONF¶
The configuration of the prompt template for this AI Prompt.
iv_description TYPE /AWS1/QQCDESCRIPTION /AWS1/QQCDESCRIPTION¶
The description of the Amazon Q in Connect AI Prompt.
iv_modelid TYPE /AWS1/QQCAIPROMPTMODELID /AWS1/QQCAIPROMPTMODELID¶
The identifier of the model used for this AI Prompt.
For information about which models are supported in each Amazon Web Services Region, see Supported models for system/custom prompts.
RETURNING¶
oo_output TYPE REF TO /aws1/cl_qqcupdateaipromptrsp /AWS1/CL_QQCUPDATEAIPROMPTRSP¶
Domain /AWS1/RT_ACCOUNT_ID Primitive Type NUMC
Examples¶
Syntax Example¶
This is an example of the syntax for calling the method. It includes every possible argument and initializes every possible value. The data provided is not necessarily semantically accurate (for example the value "string" may be provided for something that is intended to be an instance ID, or in some cases two arguments may be mutually exclusive). The syntax shows the ABAP syntax for creating the various data structures.
DATA(lo_result) = lo_client->updateaiprompt(
io_templateconfiguration = new /aws1/cl_qqcaiprompttmplconf( new /aws1/cl_qqctxtfullaiprompte00( |string| ) )
iv_aipromptid = |string|
iv_assistantid = |string|
iv_clienttoken = |string|
iv_description = |string|
iv_modelid = |string|
iv_visibilitystatus = |string|
).
This is an example of reading all possible response values
lo_result = lo_result.
IF lo_result IS NOT INITIAL.
lo_aipromptdata = lo_result->get_aiprompt( ).
IF lo_aipromptdata IS NOT INITIAL.
lv_uuid = lo_aipromptdata->get_assistantid( ).
lv_arn = lo_aipromptdata->get_assistantarn( ).
lv_uuid = lo_aipromptdata->get_aipromptid( ).
lv_arn = lo_aipromptdata->get_aipromptarn( ).
lv_name = lo_aipromptdata->get_name( ).
lv_aiprompttype = lo_aipromptdata->get_type( ).
lv_aiprompttemplatetype = lo_aipromptdata->get_templatetype( ).
lv_aipromptmodelidentifier = lo_aipromptdata->get_modelid( ).
lv_aipromptapiformat = lo_aipromptdata->get_apiformat( ).
lo_aiprompttemplateconfigu = lo_aipromptdata->get_templateconfiguration( ).
IF lo_aiprompttemplateconfigu IS NOT INITIAL.
lo_textfullaipromptedittem = lo_aiprompttemplateconfigu->get_txtfullaipromptedittmp00( ).
IF lo_textfullaipromptedittem IS NOT INITIAL.
lv_textaiprompt = lo_textfullaipromptedittem->get_text( ).
ENDIF.
ENDIF.
lv_timestamp = lo_aipromptdata->get_modifiedtime( ).
lv_description = lo_aipromptdata->get_description( ).
lv_visibilitystatus = lo_aipromptdata->get_visibilitystatus( ).
LOOP AT lo_aipromptdata->get_tags( ) into ls_row.
lv_key = ls_row-key.
lo_value = ls_row-value.
IF lo_value IS NOT INITIAL.
lv_tagvalue = lo_value->get_value( ).
ENDIF.
ENDLOOP.
lv_origin = lo_aipromptdata->get_origin( ).
lv_status = lo_aipromptdata->get_status( ).
ENDIF.
ENDIF.