Configure the Oracle Primavera Cloud Connections

This accelerator delivers two connections that are required for connecting with Oracle Primavera Cloud through Oracle Integration:

  • OPC Adapter
  • OPC Rest API

Note:

This accelerator uses the Oracle Primavera Cloud Adapter where supported. For functionality not currently exposed by the Oracle Primavera Cloud Adapter, the accelerator uses the standard REST Adapter with Oracle Primavera Cloud REST endpoints.

OPC Adapter Connection

This connection uses the Oracle Primavera Cloud Adapter.

  1. In the Connections section, click Actions Actions icon on the connection, then select Edit.
  2. In the Properties section, do the following:
    1. In the Connection URL field, enter the URL of your Oracle Primavera Cloud instance.

      For example: https://primavera.oraclecloud.com

  3. In the Security section, do the following:
    1. Select the Security policy you want to use: Oracle Primavera Cloud Login or OAuth using JWT User Assertion.
    2. If you select Oracle Primavera Cloud Login, enter the login credentials (user name and password) of your Oracle Primavera Cloud account, or an Oracle Primavera Cloud integration user account.
  4. Click Test to ensure that your connection is successfully configured.
    A message confirms if your test is successful.
  5. Click Save. If prompted, click Save again.
  6. To return to the project workspace, click Go back Back icon.

OPC Rest API Connection

This connection uses the standard REST Adapter.

  1. In the Connections section, click Actions Actions icon on the connection, then select Edit.
  2. In the Properties section, do the following:
    1. In the Connection Type field, select REST API Base URL.
    2. In the Connection URL field, enter the URL of your Oracle Primavera Cloud REST API instance.

      For example:

      https://primavera.oraclecloud.com/api/restapi/

      Note:

      You must include /api/restapi/ in the URL.
  3. In the Security section, do the following:
    1. In the Security policy field, select OAuth Custom Two Legged Flow.
    2. In the Access Token Request field, enter the access token request in the following format:
      -X POST "https://<SERVER_URL>/primediscovery/apitoken/request?scope=http://<SERVER_URL>/api" \
        -H "Authorization: Basic <Base64-encoded-username-and-password>" \
        -d "grant_type=client_credentials"

      Where:

      • <SERVER_URL> is the base URL of your Oracle Primavera Cloud instance (for example, primavera.oraclecloud.com)
      • <Base64-encoded-username-and-password> is the encoded user name and password value of your integration user. See Prepare Base64-Encoded Credentials.

      Note:

      The scope value must reference the application's context root (scope=http://<SERVER_URL>/api) and must always be http (not https).
  4. In the Optional security section, enter values for these fields in the following format:
    • $access_token = access_token
    • $expiry = expires_in
    • $token_type = token_type
    • $access_token_usage (required) =
    -H Authorization: ${token_type} ${access_token} \
    -H x-prime-tenant:<PRIME_TENANT_NAME> \
    -H x-prime-identity-app:<PRIME_IDENTITY_APP> \
    -H x-prime-tenant-code:<PRIME_TENANT_CODE> \
    -H x-prime-region:<PRIME_REGION> \
    -H userId:<USER_ID>

    Note:

    • The values for these headers come from your Oracle Primavera Cloud tenancy context.
    • x-prime-region and userId may be optional depending on your environment.
  5. Click Test to ensure that your connection is successfully configured.
    A message confirms if your test is successful.
  6. Click Save. If prompted, click Save again.
  7. To return to the project workspace, click Go back Back icon.