Create a Primavera Cloud Data Service REST Connection

Before building an integration, you must create a connection with Primavera Cloud Data Service using the REST adapter.

To create a Primavera Cloud Data Service REST connection:

  1. In the navigation pane, select Design, then Connections.
  2. Click Create.
  3. In the Create Connection panel, select the REST adapter.

    Note: To find the adapter, scroll through the list or enter a partial or full name in the Search field.

  4. Enter the information that describes this connection:

    Field

    Value

    Name

    PDS Connection

    Identifier

    PDS_CONNECTION

    (Note: The identifier is automatically added. If you modify the identifier, do not include blank spaces.)

    Role

    Trigger and Invoke

  5. Click Create.

    Your connection is created. You are now ready to configure connection details, such as connection properties, security policies, and login credentials.

  6. On the connection properties page, complete the following:
    1. In the Properties section, complete the following fields:
      1. From the Connection Type drop-down list, select REST API Base URL.
      2. In the Connection URL field, specify your Primavera Cloud Data Service URL, for example, https://primavera.oraclecloud.com/data/rest.
    2. In the Security section, complete the following fields:
      1. From the Security policy drop-down list, select OAuth Custom Two-Legged Flow.
  7. In the Access Token Request field, enter the OAuth access token generation request for accessing the API.
    X POST -H "Content-Type: application/x-www-form-urlencoded" -H "Authorization: Basic <base64 encoded code>" -d 'grant_type=client_credentials' https://primavera.oraclecloud.com/primediscovery/apitoken/request?scope=http://primavera.oraclecloud.com/dataPOST -H "Content-Type: application/x-www-form-urlencoded" -H "Authorization: Basic <base64 encoded code>" -d 'grant_type=client_credentials'
    

    Notes:

    • Use a base64 converter to generate the authcode. For example, you can use: https://base64.guru/converter.
    • Enter the input in your base64 converter in the username.password format. For example, testuser@oracle.com:Primavera@1.
  8. Expand the Optional security section, and complete the following fields:
    1. In the Refresh Token Request field, enter NA.
    2. In the access_token field, enter access.[tT]oken.
    3. In the refresh_token field, enter refersh.[tT]oken.
    4. In the expiry field, enter expires_in.
    5. In the token_type field, enter token.?[tT]ype.
    6. In the access_token_usage field, enter the following:
    -H Authorization: Bearer ${access_token} -H x-prime-tenant: <tenant-id> -H x-prime-identity-app: <tenant-appid> -H x-prime-tenant-code: <tenant-code> -H x-prime-region: <region>
    

    Note: Update the x-prime-tenant, x-prime-identity-app, x-prime-tenant-code, x-prime-region values before setting the access_token_usage value.

  9. On the page title bar, click Test.

    The test starts automatically and validates the inputs you provided for the connection. You will get a notification if the test was successful.

  10. Click Save.


Last Published Tuesday, November 28, 2023