Skip to content

/AWS1/IF_BDC=>LISTMEMORYEXTRACTIONJOBS()

About ListMemoryExtractionJobs

Lists all long-term memory extraction jobs that are eligible to be started with optional filtering.

To use this operation, you must have the bedrock-agentcore:ListMemoryExtractionJobs permission.

Method Signature

METHODS /AWS1/IF_BDC~LISTMEMORYEXTRACTIONJOBS
  IMPORTING
    !IV_MEMORYID TYPE /AWS1/BDCMEMORYID OPTIONAL
    !IV_MAXRESULTS TYPE /AWS1/BDCINTEGER OPTIONAL
    !IO_FILTER TYPE REF TO /AWS1/CL_BDCEXTJOBFILTERINPUT OPTIONAL
    !IV_NEXTTOKEN TYPE /AWS1/BDCPAGINATIONTOKEN OPTIONAL
  RETURNING
    VALUE(OO_OUTPUT) TYPE REF TO /aws1/cl_bdclistmemextjobsout
  RAISING
    /AWS1/CX_BDCACCESSDENIEDEX
    /AWS1/CX_BDCRESOURCENOTFOUNDEX
    /AWS1/CX_BDCSERVICEEXCEPTION
    /AWS1/CX_BDCSERVICEQUOTAEXCDEX
    /AWS1/CX_BDCTHROTTLEDEXCEPTION
    /AWS1/CX_BDCVALIDATIONEX
    /AWS1/CX_BDCCLIENTEXC
    /AWS1/CX_BDCSERVEREXC
    /AWS1/CX_RT_TECHNICAL_GENERIC
    /AWS1/CX_RT_SERVICE_GENERIC.

IMPORTING

Required arguments:

iv_memoryid TYPE /AWS1/BDCMEMORYID /AWS1/BDCMEMORYID

The unique identifier of the memory to list extraction jobs for.

Optional arguments:

iv_maxresults TYPE /AWS1/BDCINTEGER /AWS1/BDCINTEGER

The maximum number of results to return in a single call. The default value is 20.

io_filter TYPE REF TO /AWS1/CL_BDCEXTJOBFILTERINPUT /AWS1/CL_BDCEXTJOBFILTERINPUT

Filter criteria to apply when listing extraction jobs.

iv_nexttoken TYPE /AWS1/BDCPAGINATIONTOKEN /AWS1/BDCPAGINATIONTOKEN

The token for the next set of results. Use the value returned in the previous response in the next request to retrieve the next set of results.

RETURNING

oo_output TYPE REF TO /aws1/cl_bdclistmemextjobsout /AWS1/CL_BDCLISTMEMEXTJOBSOUT

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->listmemoryextractionjobs(
  io_filter = new /aws1/cl_bdcextjobfilterinput(
    iv_actorid = |string|
    iv_sessionid = |string|
    iv_status = |string|
    iv_strategyid = |string|
  )
  iv_maxresults = 123
  iv_memoryid = |string|
  iv_nexttoken = |string|
).

This is an example of reading all possible response values

lo_result = lo_result.
IF lo_result IS NOT INITIAL.
  LOOP AT lo_result->get_jobs( ) into lo_row.
    lo_row_1 = lo_row.
    IF lo_row_1 IS NOT INITIAL.
      lv_string = lo_row_1->get_jobid( ).
      lo_extractionjobmessages = lo_row_1->get_messages( ).
      IF lo_extractionjobmessages IS NOT INITIAL.
        LOOP AT lo_extractionjobmessages->get_messageslist( ) into lo_row_2.
          lo_row_3 = lo_row_2.
          IF lo_row_3 IS NOT INITIAL.
            lv_string = lo_row_3->get_eventid( ).
            lv_integer = lo_row_3->get_messageindex( ).
          ENDIF.
        ENDLOOP.
      ENDIF.
      lv_extractionjobstatus = lo_row_1->get_status( ).
      lv_string = lo_row_1->get_failurereason( ).
      lv_string = lo_row_1->get_strategyid( ).
      lv_string = lo_row_1->get_sessionid( ).
      lv_string = lo_row_1->get_actorid( ).
    ENDIF.
  ENDLOOP.
  lv_paginationtoken = lo_result->get_nexttoken( ).
ENDIF.