Skip to main content
Skip table of contents

Connect to Cloudaware CMDB API using Connected App with OAuth 2.0 Client Credentials Flow

This article explains how to configure a connected app using OAuth 2.0 Client Credentials Flow for Cloudaware CMDB API access.

Prerequisites

Contact your dedicated technical account manager or tam@cloudaware.com to enable the App Manager feature for your Cloudaware account. Once the feature is enabled, proceed with the setup.

Set up the app

  1. Log in to Cloudaware → Setup:

    CMDB - Connected App - setup.png

  2. in a Quick Find bar, type App Manager and select 'App manager' under Apps:

    CMDB - Connected App - Quick Find bar.png

  3. Click New Connected App → select 'Create a Connected App' → click Continue

    CMDB - Connected App - new connected app.png

  4. Specify a name and a contact email for the connected app. The API name will be auto-populated.

  5. Under API (Enable OAuth Settings), check the box for 'Enable OAuth Settings'. Paste http://localhost:1717/OauthRedirect in the Callback URL field. 

    CMDB - Connected App - enable OAuth settings.png

  6. Select the following OAuth Scopes:
    Manage user data via APIs (api)
    Perform requests at any time (refresh_token, offline_access)

    CMDB - Connected App - select OAuth scopes.png

  7. Uncheck the check box 'Require Proof Key for Code Exchange (PKCE) Extension for Supported Authorization Flows' if it is not required.

  8. Check the box for 'Enable Client Credentials Flow'. Click OK in the popup window. Scroll down and click Save.

  9. A message will appear informing that the changes may take some time to be applied. Click Continue to be redirected to the New Connected App page.

  10. Click Manage Consumer Details.

    CMDB - Connected App - manage consumer details.png

  11. Check your email to get the code required to verify your identity.

  12. Copy & save Consumer Key and Consumer Secret. These credentials should be used as client_id and client_secret in authorization API requests to obtain an access token.


    Click the link 'Back to Manage Connected Apps'.

  13. Click ManageEdit Policies:

    CMDB - Connected App - manage the connected app.png

    CMDB - Connected App - edit policies.png

  14. Under the section 'Client Credentials Flow' in '(Run As)', click on the magnifying glass icon:

    CMDB - Connected App - client credential flow.png


    In a popup window, select a preferred user* using the list of users or a search bar:

    CMDB - Connected App - select the running user.png

This user is considered to be a 'running' user of the connected app. The API will respect the permissions of the specified Cloudaware User while processing the requests. 

  1. Once the popup window is closed, get back to the Edit Policies page. Scroll down and click Save

JavaScript errors detected

Please note, these errors can depend on your browser setup.

If this problem persists, please contact our support.