Authenticate User for Embedding with OpenID Authentication

{ authenticateUserEmbedOPENID }

Generates a Pyramid access authentication token for embedding using OpenID parameter map



  • API Section: /API2/auth
  • API Version: 2.0
  • From Release: 2020.20
  • Can be used by Non-admin accounts
  • Method operates via POST actions only.
  • Input Parameters



    Object Type


    The user credentials for authentication by OpenID parameter map.

    Output Response

    Successful Result Code


    Description of Response Type

    The response is the security token as a base64 string. It is usually stored in a cookie.


    The security token is a string that needs to be added to a cookie on the third party host page for any embedded content to ensure the access is authorized. The assumption is that the user has already authenticated via OPENID in the hosting application before attempting to authenticate into Pyramid.

    Authenticate User for Embedding with OpenID:

    This example demonstrates how to authenticate a user for embedding using OpenID.

    // URL of the Pyramid installation and the path to the API 2.0 REST methods
    var pyramidURL = "";
    // Domain of the Pyramid installation
    var domainName = "YOUR_DOMAIN"
    // The response from the OpenId authentication
    var openIdToken = "YOUR_OPEN_ID_TOKEN(RESPONSE)";
          function getAuthToken() {
            var URL = pyramidURL + "/auth/authenticateUserEmbedOPENID";
            var credentials = {
              data: {
                        parameterMap: {
                            id_token: openIdToken,
                            state: "preferred_username",
                        domain: domainName,
            fetch(URL, {
              method: "POST",
              credentials: "include",
              body: JSON.stringify(credentials),
              .then((response) => response.text())
              .then((token) => console.log("fetch: " + token));