# Piano Analytics (Pull)

## Piano Analytics & AB Tasty <a href="#h_01jaz9h1hd45n84af2rcynsyez" id="h_01jaz9h1hd45n84af2rcynsyez"></a>

[Piano Analytics](https://piano.io/) is a part of the Piano Suite, a comprehensive software package designed to help businesses optimize their digital experience. Piano Analytics is specifically designed to help companies measure their content performance and understand user behavior across platforms. With its real-time data visualization, granular reporting, and advanced segmentation capabilities, Piano Analytics has become a popular choice for media organizations.

The Piano Analytics allows you to receive the audiences collected in Piano Analytics and to use them to create audiences within AB Tasty. Thus, the Piano Analytics integration process is taking place on both interfaces.

An audience in Piano Analytics is any subset of users based on a particular criterion defined by you. For further information on how to use audiences, please refer to the [Piano Analytics documentation](https://support.piano.io/hc/en-us/articles/4465700752530-New-segmentation-engine)

## Integration <a href="#h_01jaz9pgqhsnyzy2mw9rrkmqbm" id="h_01jaz9pgqhsnyzy2mw9rrkmqbm"></a>

### Requirements <a href="#h_01jaz9ndwsqw7s7j030v77h5vs" id="h_01jaz9ndwsqw7s7j030v77h5vs"></a>

To make sure the integration runs without any problem, you **must** have Piano Analytics integrated into your website.

On the console (on the browser), you can check with the following commands:

```
window.pianoAnalytics 
```

![](https://2350286830-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F6Yw9IRJ6KbbucQPwZUCZ%2Fuploads%2Fgit-blob-819007b645347b381563c149619b9152f3132b7d%2Ffe1b5b3880af6ef1b316eec4b67c4df1.png?alt=media)

### Creating an AB tasty property <a href="#h_01j1ad3hzpgsj64g09nj2fkpvc" id="h_01j1ad3hzpgsj64g09nj2fkpvc"></a>

1. Go to your data Management interface.

![](https://2350286830-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F6Yw9IRJ6KbbucQPwZUCZ%2Fuploads%2Fgit-blob-7259b0d54509346c9fe6075bcddaadb05f8e854d%2F28534f1378cec9e021ced9bd714eb5f5.png?alt=media)

2. Create a new property

* Display name: you can enter what you want, but we suggest “ABTastyId”
* Description: enter the description you want (for example: Pull Integration Piano <> AB tasty)
* Property key: abtasty\_visitor\_id (you must enter this exact key). If you change it, the connection between Piano and AB tasty won’t work anymore
* Categories: choose “User”
* Configuration
  * Status: choose “Validated”
  * Type: choose “String”
* Scope: choose “Visit”

![](https://2350286830-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F6Yw9IRJ6KbbucQPwZUCZ%2Fuploads%2Fgit-blob-e0b5f5dbcdabedb7ce71f24a64934287f5afdf44%2F4ea27273363ff6c3c81932018c2728c8.png?alt=media)

### Enabling the integration on Piano Analytics <a href="#id-01jaz9r3rgtktpvpzr59mwaryd" id="id-01jaz9r3rgtktpvpzr59mwaryd"></a>

To enable integration on Piano, follow the steps below inside the Piano Analytics app:

1. Go to your Profile > API keys. Enter a name and a description.

![](https://2350286830-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F6Yw9IRJ6KbbucQPwZUCZ%2Fuploads%2Fgit-blob-132eb69a5e3c7bfde5085b72f068cd318d5dc082%2F6c726506504eec280d87c0c40dc66e2b.png?alt=media)

2. Once the API key is generated, you have one Access Key and one secret key. Please copy both, you will need them later.
3. Go back to your piano Analytics dashboard. Inside the URL, you have one field “site” with a value. Example:

![](https://2350286830-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F6Yw9IRJ6KbbucQPwZUCZ%2Fuploads%2Fgit-blob-4ca324369a8ec99259b2ed8152ce7ba18b109177%2Fe408074e5b8e7479168817df0ed08072.png?alt=media)

Please copy the value of “site”. For example, here the value is: [**636937**](https://explorer.atinternet-solutions.com/core/#/overview/overview/010101?period.shortcut=yesterday\&period.granularity=3\&site=636937\&graph.options.defaultlist=minmax\&graph.options.comparisonlist=nocomparison\&graph.options.eventloglist=eventlog\&isIgnoreNullProperties=true)

An integration API key is a unique key that allows a third-party tool to communicate with your specific AB Tasty account i.e., send data to your account.

### Enabling the integration on AB Tasty <a href="#h_01hks9w170wf33xznpkj6y0fr2" id="h_01hks9w170wf33xznpkj6y0fr2"></a>

![](https://2350286830-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F6Yw9IRJ6KbbucQPwZUCZ%2Fuploads%2Fgit-blob-8bb896bf924d518a4af021a65fc4de12e68130e0%2F706b16b927cb86ec84b17351e56a945a.png?alt=media)

To enable the integration on AB Tasty, follow the steps below:

1. Access **Integrations > Integration Hub > Pull**.
2. Search for and select **Piano Analytics**.
3. Click **Setup connector.**
4. Give a name to your connector so you can easily retrieve it.

![](https://2350286830-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F6Yw9IRJ6KbbucQPwZUCZ%2Fuploads%2Fgit-blob-8094d912b0c4edf23c8c7ae8b52b16cb00f2caa9%2F6e46683d841e4cebc19c1208e0841871.png?alt=media)

5. **API Key**: paste the API key using the following format (official documentation [here](https://support.piano.io/hc/en-us/articles/4466006444306-API-Keys#CreateanAPIKey))

accessKey\_secretKey

6. **Site Id**: paste the siteID you have copied earlier

Piano Analytics is now set up. No other action is required here. This will allow AB Tasty to display the audiences that will be sent by Piano Analytics.

## Configuration <a href="#h_01jaz9zzhjavx9ydaaj1299p8p" id="h_01jaz9zzhjavx9ydaaj1299p8p"></a>

Once you have activated and configured an integration, you can retrieve your segment traits in the segment builder (available when you create a new segment).&#x20;

<figure><img src="https://2350286830-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F6Yw9IRJ6KbbucQPwZUCZ%2Fuploads%2Fgit-blob-4dccc9042dd3d732226bf95e0ae9f379a25d11fb%2F425a90fc97417bacb30f7c302b84c8e9.png?alt=media" alt="" width="563"><figcaption></figcaption></figure>

Audiences or traits generated by your integrations are all to be found under the criteria group **EXTERNAL DATA**.\
For each integration, you will have a corresponding item that you can drag and drop to use.\
For global information on how to build a targeting segment, please refer to [how to create a segment](https://docs.abtasty.com/web-experimentation-and-personalization/targeting-step/how-to-create-a-segment-who-section).

For an audience to be available in the segment builder it must not be empty, meaning that we have to identify at least one user belonging to that audience. Once a user is identified, the audience will appear in the segment builder.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.abtasty.com/integrations/pull-integrations/piano-analytics-pull.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
