/AWS1/IF_BDZ=>PUTINVOCATIONSTEP()¶
About PutInvocationStep¶
Add an invocation step to an invocation in a session. An invocation step stores fine-grained state checkpoints, including text and images, for each interaction. For more information about sessions, see Store and retrieve conversation history and context with Amazon Bedrock sessions.
Related APIs:
Method Signature¶
METHODS /AWS1/IF_BDZ~PUTINVOCATIONSTEP
IMPORTING
!IV_SESSIONIDENTIFIER TYPE /AWS1/BDZSESSIONIDENTIFIER OPTIONAL
!IV_INVOCATIONIDENTIFIER TYPE /AWS1/BDZINVOCATIONIDENTIFIER OPTIONAL
!IV_INVOCATIONSTEPTIME TYPE /AWS1/BDZDATETIMESTAMP OPTIONAL
!IO_PAYLOAD TYPE REF TO /AWS1/CL_BDZINVCSTEPPAYLOAD OPTIONAL
!IV_INVOCATIONSTEPID TYPE /AWS1/BDZUUID OPTIONAL
RETURNING
VALUE(OO_OUTPUT) TYPE REF TO /aws1/cl_bdzputinvcsteprsp
RAISING
/AWS1/CX_BDZACCESSDENIEDEX
/AWS1/CX_BDZCONFLICTEXCEPTION
/AWS1/CX_BDZINTERNALSERVEREX
/AWS1/CX_BDZRESOURCENOTFOUNDEX
/AWS1/CX_BDZSERVICEQUOTAEXCDEX
/AWS1/CX_BDZTHROTTLINGEX
/AWS1/CX_BDZVALIDATIONEX
/AWS1/CX_BDZCLIENTEXC
/AWS1/CX_BDZSERVEREXC
/AWS1/CX_RT_TECHNICAL_GENERIC
/AWS1/CX_RT_SERVICE_GENERIC.
IMPORTING¶
Required arguments:¶
iv_sessionidentifier TYPE /AWS1/BDZSESSIONIDENTIFIER /AWS1/BDZSESSIONIDENTIFIER¶
The unique identifier for the session to add the invocation step to. You can specify either the session's
sessionIdor its Amazon Resource Name (ARN).
iv_invocationidentifier TYPE /AWS1/BDZINVOCATIONIDENTIFIER /AWS1/BDZINVOCATIONIDENTIFIER¶
The unique identifier (in UUID format) of the invocation to add the invocation step to.
iv_invocationsteptime TYPE /AWS1/BDZDATETIMESTAMP /AWS1/BDZDATETIMESTAMP¶
The timestamp for when the invocation step occurred.
io_payload TYPE REF TO /AWS1/CL_BDZINVCSTEPPAYLOAD /AWS1/CL_BDZINVCSTEPPAYLOAD¶
The payload for the invocation step, including text and images for the interaction.
Optional arguments:¶
iv_invocationstepid TYPE /AWS1/BDZUUID /AWS1/BDZUUID¶
The unique identifier of the invocation step in UUID format.
RETURNING¶
oo_output TYPE REF TO /aws1/cl_bdzputinvcsteprsp /AWS1/CL_BDZPUTINVCSTEPRSP¶
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->putinvocationstep(
io_payload = new /aws1/cl_bdzinvcsteppayload(
it_contentblocks = VALUE /aws1/cl_bdzbedrocksesscontblk=>tt_bedrocksessioncontentblocks(
(
new /aws1/cl_bdzbedrocksesscontblk(
io_image = new /aws1/cl_bdzimageblock(
io_source = new /aws1/cl_bdzimagesource(
io_s3location = new /aws1/cl_bdzs3location( |string| )
iv_bytes = '5347567362473873563239796247513D'
)
iv_format = |string|
)
iv_text = |string|
)
)
)
)
iv_invocationidentifier = |string|
iv_invocationstepid = |string|
iv_invocationsteptime = '20150101000000.0000000'
iv_sessionidentifier = |string|
).
This is an example of reading all possible response values
lo_result = lo_result.
IF lo_result IS NOT INITIAL.
lv_uuid = lo_result->get_invocationstepid( ).
ENDIF.