Description

This function lists the external authentication links to the current cPanel account.

Examples 


https://hostname.example.com:2083/cpsess##########/execute/ExternalAuthentication/get_authn_links

$cpanel = new CPANEL(); // Connect to cPanel - only do this once.
 
// Lists the external authentication links to the current account.
$list_external_links = $cpanel->uapi(
    'ExternalAuthentication', 'get_authn_links'
);

 

my $cpliveapi = Cpanel::LiveAPI->new(); # Connect to cPanel - only do this once.
 
# lists the external authentication links to the current account.
my $list_external_links = $cpliveapi->uapi(
    'ExternalAuthentication', 'get_authn_links'
);

 

<!-- lists the external authentication links to the current account. -->
[% data = execute( 'ExternalAuthentication', 'get_authn_links' ); %]

 

uapi --user=username ExternalAuthentication get_authn_links

{  
   "messages":null,
   "errors":null,
   "status":1,
   "metadata":{  

   },
   "data":[  
      {  
         "preferred_username":"username@gmail.com",
         "link_time":1443124604,
         "subject_unique_identifier":"123456789012345678901",
         "provider_protocol":"openid_connect",
         "provider_id":"google"
      },
      {  
         "preferred_username":"username@gmail.com",
         "link_time":1443124604,
         "subject_unique_identifier":"123456789012345678901",
         "provider_protocol":"openid_connect",
         "provider_id":"google"
      }
   ]
}

   

Parameters

This function does not accept parameters.

Returns

ReturnTypeDescriptionPossible ValuesExample

preferred_username

string

The preferred username of the account on the identity provider.

A valid string.username@gmail.com

link_time

integer

When the user linked their account to the identity provider.

A valid integer in Unix time.1443124604

subject_unique_identifier

integer

The unique identifier for the user at the identity provider.

A valid integer.123456789012345678901

provider_protocol

string

The identity provider's protocol.

A valid string.openid_connect

provider_id

string

The system's unique key for the identity provider.

A valid string.google