Skip to content

/AWS1/IF_BDO=>UPDATEOAUTH2CREDPROVIDER()

About UpdateOauth2CredentialProvider

Updates an existing OAuth2 credential provider.

Method Signature

IMPORTING

Required arguments:

iv_name TYPE /AWS1/BDOCREDPROVIDERNAME /AWS1/BDOCREDPROVIDERNAME

The name of the OAuth2 credential provider to update.

iv_credentialprovidervendor TYPE /AWS1/BDOCREDPVDRVENDORTYPE /AWS1/BDOCREDPVDRVENDORTYPE

The vendor of the OAuth2 credential provider.

io_oauth2providerconfiginput TYPE REF TO /AWS1/CL_BDOOAUTH2PVDRCFGINPUT /AWS1/CL_BDOOAUTH2PVDRCFGINPUT

The configuration input for the OAuth2 provider.

RETURNING

oo_output TYPE REF TO /aws1/cl_bdoupdo2credpvdrrsp /AWS1/CL_BDOUPDO2CREDPVDRRSP

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->/aws1/if_bdo~updateoauth2credprovider(
  io_oauth2providerconfiginput = new /aws1/cl_bdooauth2pvdrcfginput(
    io_customoauth2pvdrconfig = new /aws1/cl_bdocusto2pvdrcfginput(
      io_oauthdiscovery = new /aws1/cl_bdooauth2discovery(
        io_authservermetadata = new /aws1/cl_bdooauth2authsrvmet(
          it_responsetypes = VALUE /aws1/cl_bdoresponselisttype_w=>tt_responselisttype(
            ( new /aws1/cl_bdoresponselisttype_w( |string| ) )
          )
          iv_authorizationendpoint = |string|
          iv_issuer = |string|
          iv_tokenendpoint = |string|
        )
        iv_discoveryurl = |string|
      )
      iv_clientid = |string|
      iv_clientsecret = |string|
    )
    io_githuboauth2pvdrconfig = new /aws1/cl_bdogito2pvdrcfginput(
      iv_clientid = |string|
      iv_clientsecret = |string|
    )
    io_googleoauth2pvdrconfig = new /aws1/cl_bdogoogo2pvdrcfginput(
      iv_clientid = |string|
      iv_clientsecret = |string|
    )
    io_msftoauth2providerconfig = new /aws1/cl_bdomsfto2pvdrcfginput(
      iv_clientid = |string|
      iv_clientsecret = |string|
    )
    io_sforceoauth2pvdrconfig = new /aws1/cl_bdosforceo2pvdrcfginp(
      iv_clientid = |string|
      iv_clientsecret = |string|
    )
    io_slackoauth2providerconfig = new /aws1/cl_bdoslacko2pvdrcfginp(
      iv_clientid = |string|
      iv_clientsecret = |string|
    )
  )
  iv_credentialprovidervendor = |string|
  iv_name = |string|
).

This is an example of reading all possible response values

lo_result = lo_result.
IF lo_result IS NOT INITIAL.
  lo_secret = lo_result->get_clientsecretarn( ).
  IF lo_secret IS NOT INITIAL.
    lv_secretarn = lo_secret->get_secretarn( ).
  ENDIF.
  lv_credentialprovidername = lo_result->get_name( ).
  lv_credentialprovidervendo = lo_result->get_credentialprovidervendor( ).
  lv_credentialproviderarnty = lo_result->get_credentialproviderarn( ).
  lo_oauth2providerconfigout = lo_result->get_oauth2pvdrconfigoutput( ).
  IF lo_oauth2providerconfigout IS NOT INITIAL.
    lo_customoauth2providercon = lo_oauth2providerconfigout->get_customoauth2pvdrconfig( ).
    IF lo_customoauth2providercon IS NOT INITIAL.
      lo_oauth2discovery = lo_customoauth2providercon->get_oauthdiscovery( ).
      IF lo_oauth2discovery IS NOT INITIAL.
        lv_discoveryurltype = lo_oauth2discovery->get_discoveryurl( ).
        lo_oauth2authorizationserv = lo_oauth2discovery->get_authservermetadata( ).
        IF lo_oauth2authorizationserv IS NOT INITIAL.
          lv_issuerurltype = lo_oauth2authorizationserv->get_issuer( ).
          lv_authorizationendpointty = lo_oauth2authorizationserv->get_authorizationendpoint( ).
          lv_tokenendpointtype = lo_oauth2authorizationserv->get_tokenendpoint( ).
          LOOP AT lo_oauth2authorizationserv->get_responsetypes( ) into lo_row.
            lo_row_1 = lo_row.
            IF lo_row_1 IS NOT INITIAL.
              lv_responsetype = lo_row_1->get_value( ).
            ENDIF.
          ENDLOOP.
        ENDIF.
      ENDIF.
    ENDIF.
    lo_googleoauth2providercon = lo_oauth2providerconfigout->get_googleoauth2pvdrconfig( ).
    IF lo_googleoauth2providercon IS NOT INITIAL.
      lo_oauth2discovery = lo_googleoauth2providercon->get_oauthdiscovery( ).
      IF lo_oauth2discovery IS NOT INITIAL.
        lv_discoveryurltype = lo_oauth2discovery->get_discoveryurl( ).
        lo_oauth2authorizationserv = lo_oauth2discovery->get_authservermetadata( ).
        IF lo_oauth2authorizationserv IS NOT INITIAL.
          lv_issuerurltype = lo_oauth2authorizationserv->get_issuer( ).
          lv_authorizationendpointty = lo_oauth2authorizationserv->get_authorizationendpoint( ).
          lv_tokenendpointtype = lo_oauth2authorizationserv->get_tokenendpoint( ).
          LOOP AT lo_oauth2authorizationserv->get_responsetypes( ) into lo_row.
            lo_row_1 = lo_row.
            IF lo_row_1 IS NOT INITIAL.
              lv_responsetype = lo_row_1->get_value( ).
            ENDIF.
          ENDLOOP.
        ENDIF.
      ENDIF.
    ENDIF.
    lo_githuboauth2providercon = lo_oauth2providerconfigout->get_githuboauth2pvdrconfig( ).
    IF lo_githuboauth2providercon IS NOT INITIAL.
      lo_oauth2discovery = lo_githuboauth2providercon->get_oauthdiscovery( ).
      IF lo_oauth2discovery IS NOT INITIAL.
        lv_discoveryurltype = lo_oauth2discovery->get_discoveryurl( ).
        lo_oauth2authorizationserv = lo_oauth2discovery->get_authservermetadata( ).
        IF lo_oauth2authorizationserv IS NOT INITIAL.
          lv_issuerurltype = lo_oauth2authorizationserv->get_issuer( ).
          lv_authorizationendpointty = lo_oauth2authorizationserv->get_authorizationendpoint( ).
          lv_tokenendpointtype = lo_oauth2authorizationserv->get_tokenendpoint( ).
          LOOP AT lo_oauth2authorizationserv->get_responsetypes( ) into lo_row.
            lo_row_1 = lo_row.
            IF lo_row_1 IS NOT INITIAL.
              lv_responsetype = lo_row_1->get_value( ).
            ENDIF.
          ENDLOOP.
        ENDIF.
      ENDIF.
    ENDIF.
    lo_slackoauth2providerconf = lo_oauth2providerconfigout->get_slackoauth2pvdrconfig( ).
    IF lo_slackoauth2providerconf IS NOT INITIAL.
      lo_oauth2discovery = lo_slackoauth2providerconf->get_oauthdiscovery( ).
      IF lo_oauth2discovery IS NOT INITIAL.
        lv_discoveryurltype = lo_oauth2discovery->get_discoveryurl( ).
        lo_oauth2authorizationserv = lo_oauth2discovery->get_authservermetadata( ).
        IF lo_oauth2authorizationserv IS NOT INITIAL.
          lv_issuerurltype = lo_oauth2authorizationserv->get_issuer( ).
          lv_authorizationendpointty = lo_oauth2authorizationserv->get_authorizationendpoint( ).
          lv_tokenendpointtype = lo_oauth2authorizationserv->get_tokenendpoint( ).
          LOOP AT lo_oauth2authorizationserv->get_responsetypes( ) into lo_row.
            lo_row_1 = lo_row.
            IF lo_row_1 IS NOT INITIAL.
              lv_responsetype = lo_row_1->get_value( ).
            ENDIF.
          ENDLOOP.
        ENDIF.
      ENDIF.
    ENDIF.
    lo_salesforceoauth2provide = lo_oauth2providerconfigout->get_sforceoauth2pvdrconfig( ).
    IF lo_salesforceoauth2provide IS NOT INITIAL.
      lo_oauth2discovery = lo_salesforceoauth2provide->get_oauthdiscovery( ).
      IF lo_oauth2discovery IS NOT INITIAL.
        lv_discoveryurltype = lo_oauth2discovery->get_discoveryurl( ).
        lo_oauth2authorizationserv = lo_oauth2discovery->get_authservermetadata( ).
        IF lo_oauth2authorizationserv IS NOT INITIAL.
          lv_issuerurltype = lo_oauth2authorizationserv->get_issuer( ).
          lv_authorizationendpointty = lo_oauth2authorizationserv->get_authorizationendpoint( ).
          lv_tokenendpointtype = lo_oauth2authorizationserv->get_tokenendpoint( ).
          LOOP AT lo_oauth2authorizationserv->get_responsetypes( ) into lo_row.
            lo_row_1 = lo_row.
            IF lo_row_1 IS NOT INITIAL.
              lv_responsetype = lo_row_1->get_value( ).
            ENDIF.
          ENDLOOP.
        ENDIF.
      ENDIF.
    ENDIF.
    lo_microsoftoauth2provider = lo_oauth2providerconfigout->get_msftoauth2providerconfig( ).
    IF lo_microsoftoauth2provider IS NOT INITIAL.
      lo_oauth2discovery = lo_microsoftoauth2provider->get_oauthdiscovery( ).
      IF lo_oauth2discovery IS NOT INITIAL.
        lv_discoveryurltype = lo_oauth2discovery->get_discoveryurl( ).
        lo_oauth2authorizationserv = lo_oauth2discovery->get_authservermetadata( ).
        IF lo_oauth2authorizationserv IS NOT INITIAL.
          lv_issuerurltype = lo_oauth2authorizationserv->get_issuer( ).
          lv_authorizationendpointty = lo_oauth2authorizationserv->get_authorizationendpoint( ).
          lv_tokenendpointtype = lo_oauth2authorizationserv->get_tokenendpoint( ).
          LOOP AT lo_oauth2authorizationserv->get_responsetypes( ) into lo_row.
            lo_row_1 = lo_row.
            IF lo_row_1 IS NOT INITIAL.
              lv_responsetype = lo_row_1->get_value( ).
            ENDIF.
          ENDLOOP.
        ENDIF.
      ENDIF.
    ENDIF.
  ENDIF.
  lv_timestamp = lo_result->get_createdtime( ).
  lv_timestamp = lo_result->get_lastupdatedtime( ).
ENDIF.