Typical Partnership integration example

This provides the step-by-step details of a typical integration using the page widget and SSO.

Recommendation: Start new projects by referring to Getting started with API v2 and the New Relic REST API v2 examples. Also, begin migrating any of your API v1 scripts to their v2 equivalent.

Account creation and value storage

Using the accounts/create endpoint, create an account, subscription and user.

From the payload, extract and store the account values. Typically you will create a new table in your accounts database and associate the record containing this information with your user record. The values used in this scenario include data-access-key, id, and license-key. You may want to store additional values.

Deploying the agent

New Relic highly recommends automatically deploying the agents for your customers if your architecture and choice of languages permit. Our experience is that even the best documented and easiest user deployment of the agent results in only a 75% success rate. Auto-deploying the agent for your customers eliminates this dropout.

Whether your intention is to auto-deploy or allow the user to do so, the license key from the account creation payload is required for this operation. If you are planning a manual deploy, it is helpful to make the license key easily available to your users. This is a convenience for your users. The key is available by logging into the account.

Deploying the page widget with SSO

Using the data access key from the newly created account and the user's email, along with the partnership shared secret and timestamp, create a digest that can be transformed into an SHA-2 hash. The elements are assembled into the widget URL.

Note: As a standard security measure for data collection, New Relic requires that your application server supports SHA-2 (256-bit). SHA-1 is not supported.

For more help

If you need more help, check out these support and learning resources: