Skip to content

/AWS1/IF_BDO=>CREATECONSENTPORTAL()

About CreateConsentPortal

Creates a new consent portal.

Method Signature

METHODS /AWS1/IF_BDO~CREATECONSENTPORTAL
  IMPORTING
    !IV_EXECUTIONROLEARN TYPE /AWS1/BDOEXECUTIONROLEARNTYPE OPTIONAL
    !IO_IDPCONFIG TYPE REF TO /AWS1/CL_BDOCONSENTPORTLIDPCFG OPTIONAL
    !IV_NAME TYPE /AWS1/BDOCONSENTPORTALNAMETYPE OPTIONAL
    !IT_SOURCES TYPE /AWS1/CL_BDOCONSENTPORTALSRC=>TT_CONSENTPORTALSOURCES OPTIONAL
    !IV_DESCRIPTION TYPE /AWS1/BDOCONSENTPORTALDESCTYPE OPTIONAL
    !IT_TAGS TYPE /AWS1/CL_BDOTAGSMAP_W=>TT_TAGSMAP OPTIONAL
  RETURNING
    VALUE(OO_OUTPUT) TYPE REF TO /aws1/cl_bdocreconsentportlrsp
  RAISING
    /AWS1/CX_BDOACCESSDENIEDEX
    /AWS1/CX_BDOCONFLICTEXCEPTION
    /AWS1/CX_BDOINTERNALSERVEREX
    /AWS1/CX_BDORESOURCENOTFOUNDEX
    /AWS1/CX_BDOSERVICEQUOTAEXCDEX
    /AWS1/CX_BDOTHROTTLINGEX
    /AWS1/CX_BDOUNAUTHORIZEDEX
    /AWS1/CX_BDOVALIDATIONEX
    /AWS1/CX_BDOCLIENTEXC
    /AWS1/CX_BDOSERVEREXC
    /AWS1/CX_RT_TECHNICAL_GENERIC
    /AWS1/CX_RT_SERVICE_GENERIC.

IMPORTING

Required arguments:

iv_executionrolearn TYPE /AWS1/BDOEXECUTIONROLEARNTYPE /AWS1/BDOEXECUTIONROLEARNTYPE

The Amazon Resource Name (ARN) of the IAM role that the consent portal assumes to access the resources defined in its sources.

io_idpconfig TYPE REF TO /AWS1/CL_BDOCONSENTPORTLIDPCFG /AWS1/CL_BDOCONSENTPORTLIDPCFG

The identity provider configuration that the consent portal uses to authenticate end users.

iv_name TYPE /AWS1/BDOCONSENTPORTALNAMETYPE /AWS1/BDOCONSENTPORTALNAMETYPE

The name of the consent portal. The name must be unique within your account.

it_sources TYPE /AWS1/CL_BDOCONSENTPORTALSRC=>TT_CONSENTPORTALSOURCES TT_CONSENTPORTALSOURCES

The resources served by the consent portal. Currently, we only support type agentcore-gateway.

Optional arguments:

iv_description TYPE /AWS1/BDOCONSENTPORTALDESCTYPE /AWS1/BDOCONSENTPORTALDESCTYPE

The description of the consent portal.

it_tags TYPE /AWS1/CL_BDOTAGSMAP_W=>TT_TAGSMAP TT_TAGSMAP

A map of tag keys and values to assign to the consent portal. Tags enable you to categorize your resources in different ways, for example, by purpose, owner, or environment.

RETURNING

oo_output TYPE REF TO /aws1/cl_bdocreconsentportlrsp /AWS1/CL_BDOCRECONSENTPORTLRSP

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->createconsentportal(
  io_idpconfig = new /aws1/cl_bdoconsentportlidpcfg(
    it_scopes = VALUE /aws1/cl_bdoalwdscopestype_w=>tt_allowedscopestype(
      ( new /aws1/cl_bdoalwdscopestype_w( |string| ) )
    )
    iv_audience = |string|
    iv_credentialproviderarn = |string|
  )
  it_sources = VALUE /aws1/cl_bdoconsentportalsrc=>tt_consentportalsources(
    (
      new /aws1/cl_bdoconsentportalsrc(
        iv_identifier = |string|
        iv_type = |string|
      )
    )
  )
  it_tags = VALUE /aws1/cl_bdotagsmap_w=>tt_tagsmap(
    (
      VALUE /aws1/cl_bdotagsmap_w=>ts_tagsmap_maprow(
        key = |string|
        value = new /aws1/cl_bdotagsmap_w( |string| )
      )
    )
  )
  iv_description = |string|
  iv_executionrolearn = |string|
  iv_name = |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_sources( ) into lo_row.
    lo_row_1 = lo_row.
    IF lo_row_1 IS NOT INITIAL.
      lv_consentportalsourceiden = lo_row_1->get_identifier( ).
      lv_consentportalsourcetype = lo_row_1->get_type( ).
    ENDIF.
  ENDLOOP.
  lv_consentportalarntype = lo_result->get_consentportalarn( ).
  lv_consentportalidtype = lo_result->get_consentportalid( ).
  lv_timestamp = lo_result->get_createdat( ).
  lv_consentportaldescriptio = lo_result->get_description( ).
  lv_executionrolearntype = lo_result->get_executionrolearn( ).
  lo_consentportalidpconfig = lo_result->get_idpconfig( ).
  IF lo_consentportalidpconfig IS NOT INITIAL.
    lv_oauth2credentialprovide = lo_consentportalidpconfig->get_credentialproviderarn( ).
    LOOP AT lo_consentportalidpconfig->get_scopes( ) into lo_row_2.
      lo_row_3 = lo_row_2.
      IF lo_row_3 IS NOT INITIAL.
        lv_allowedscopetype = lo_row_3->get_value( ).
      ENDIF.
    ENDLOOP.
    lv_allowedaudiencetype = lo_consentportalidpconfig->get_audience( ).
  ENDIF.
  lv_consentportalnametype = lo_result->get_name( ).
  lv_portalurltype = lo_result->get_portalurl( ).
  lv_consentportalstatus = lo_result->get_status( ).
  lv_statusreasontype = lo_result->get_statusreason( ).
  lv_timestamp = lo_result->get_updatedat( ).
ENDIF.