/AWS1/IF_QQA=>GETLIBRARYITEM()¶
About GetLibraryItem¶
Retrieves details about a library item for an Amazon Q App, including its metadata, categories, ratings, and usage statistics.
Method Signature¶
METHODS /AWS1/IF_QQA~GETLIBRARYITEM
IMPORTING
!IV_INSTANCEID TYPE /AWS1/QQAINSTANCEID OPTIONAL
!IV_LIBRARYITEMID TYPE /AWS1/QQAUUID OPTIONAL
!IV_APPID TYPE /AWS1/QQAUUID OPTIONAL
RETURNING
VALUE(OO_OUTPUT) TYPE REF TO /aws1/cl_qqagetlibraryitemout
RAISING
/AWS1/CX_QQAACCESSDENIEDEX
/AWS1/CX_QQAINTERNALSERVEREX
/AWS1/CX_QQARESOURCENOTFOUNDEX
/AWS1/CX_QQATHROTTLINGEX
/AWS1/CX_QQAUNAUTHORIZEDEX
/AWS1/CX_QQAVALIDATIONEX
/AWS1/CX_QQACLIENTEXC
/AWS1/CX_QQASERVEREXC
/AWS1/CX_RT_TECHNICAL_GENERIC
/AWS1/CX_RT_SERVICE_GENERIC.
IMPORTING¶
Required arguments:¶
iv_instanceid TYPE /AWS1/QQAINSTANCEID /AWS1/QQAINSTANCEID¶
The unique identifier of the Amazon Q Business application environment instance.
iv_libraryitemid TYPE /AWS1/QQAUUID /AWS1/QQAUUID¶
The unique identifier of the library item to retrieve.
Optional arguments:¶
iv_appid TYPE /AWS1/QQAUUID /AWS1/QQAUUID¶
The unique identifier of the Amazon Q App associated with the library item.
RETURNING¶
oo_output TYPE REF TO /aws1/cl_qqagetlibraryitemout /AWS1/CL_QQAGETLIBRARYITEMOUT¶
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->getlibraryitem(
iv_appid = |string|
iv_instanceid = |string|
iv_libraryitemid = |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_libraryitemid( ).
lv_uuid = lo_result->get_appid( ).
lv_appversion = lo_result->get_appversion( ).
LOOP AT lo_result->get_categories( ) into lo_row.
lo_row_1 = lo_row.
IF lo_row_1 IS NOT INITIAL.
lv_uuid = lo_row_1->get_id( ).
lv_string = lo_row_1->get_title( ).
lv_string = lo_row_1->get_color( ).
lv_integer = lo_row_1->get_appcount( ).
ENDIF.
ENDLOOP.
lv_string = lo_result->get_status( ).
lv_qappstimestamp = lo_result->get_createdat( ).
lv_string = lo_result->get_createdby( ).
lv_qappstimestamp = lo_result->get_updatedat( ).
lv_string = lo_result->get_updatedby( ).
lv_integer = lo_result->get_ratingcount( ).
lv_boolean = lo_result->get_isratedbyuser( ).
lv_integer = lo_result->get_usercount( ).
lv_boolean = lo_result->get_isverified( ).
ENDIF.
Retrieve a library item¶
Retrieve a library item
DATA(lo_result) = lo_client->getlibraryitem(
iv_instanceid = |0b95c9c4-89cc-4aa8-9aae-aa91cbec699f|
iv_libraryitemid = |18cbebaa-196a-4aa5-a840-88d548e07f8f|
).