> ## Documentation Index
> Fetch the complete documentation index at: https://docs.permutive.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Magnite

> Integrate with Magnite SSP for real-time cohort activation

export const NoBadge = () => {
  return <span style={{
    display: 'inline-block',
    padding: '0.125rem 0.5rem',
    borderRadius: '0.25rem',
    fontSize: '0.625rem',
    background: '#F7D0E2',
    color: '#1A1A1A',
    fontWeight: '500'
  }}>
      No
    </span>;
};

export const YesBadge = () => {
  return <span style={{
    display: 'inline-block',
    padding: '0.125rem 0.5rem',
    borderRadius: '0.25rem',
    fontSize: '0.625rem',
    background: '#C7E8F9',
    color: '#1A1A1A',
    fontWeight: '500'
  }}>
      Yes
    </span>;
};

export const BadgeRowCenter = ({label, children}) => {
  return <div style={{
    display: 'flex',
    justifyContent: 'space-between',
    alignItems: 'center',
    marginBottom: '0.5rem'
  }}>
      <span style={{
    fontSize: '0.625rem',
    color: '#6b7280',
    textTransform: 'uppercase',
    fontWeight: '500',
    letterSpacing: '0.05em'
  }}>
        {label}
      </span>
      {children}
    </div>;
};

export const BadgeRow = ({label, children}) => {
  return <div style={{
    display: 'flex',
    justifyContent: 'space-between',
    alignItems: 'flex-start',
    marginBottom: '0.5rem'
  }}>
      <span style={{
    fontSize: '0.625rem',
    color: '#6b7280',
    textTransform: 'uppercase',
    fontWeight: '500',
    letterSpacing: '0.05em'
  }}>
        {label}
      </span>
      {children}
    </div>;
};

export const BadgeContainer = ({children}) => {
  return <div style={{
    display: 'flex',
    gap: '0.25rem',
    flexWrap: 'wrap',
    justifyContent: 'flex-end',
    minWidth: '0',
    flex: '1'
  }}>
      {children}
    </div>;
};

export const ProductRequiredBadge = ({product}) => {
  const getBadgeStyle = product => {
    switch (product) {
      case 'Core Platform':
        return {
          background: '#CB88FC',
          color: '#1A1A1A'
        };
        --purple;
      case 'Routing':
        return {
          background: '#CB88FC',
          color: '#1A1A1A'
        };
        --purple;
      case 'Contextual':
        return {
          background: '#CB88FC',
          color: '#1A1A1A'
        };
        --purple;
      default:
        return {
          background: '#A7B3D9',
          color: '#1A1A1A'
        };
        --haze;
    }
  };
  const style = getBadgeStyle(product);
  return <span style={{
    display: 'inline-block',
    padding: '0.125rem 0.375rem',
    borderRadius: '0.25rem',
    fontSize: '0.625rem',
    background: style.background,
    color: style.color,
    fontWeight: '500'
  }}>
      {product}
    </span>;
};

export const SdkRequiredBadge = ({required}) => {
  const getBadgeStyle = required => {
    switch (required) {
      case 'Yes':
        return {
          background: '#C7E8F9',
          color: '#1A1A1A'
        };
        --blue;
      case 'No':
        return {
          background: '#F7D0E2',
          color: '#1A1A1A'
        };
        --pink;
      default:
        return {
          background: '#A7B3D9',
          color: '#1A1A1A'
        };
        --haze;
    }
  };
  const style = getBadgeStyle(required);
  return <span style={{
    display: 'inline-block',
    padding: '0.125rem 0.375rem',
    borderRadius: '0.25rem',
    fontSize: '0.625rem',
    background: style.background,
    color: style.color,
    fontWeight: '500'
  }}>
      {required}
    </span>;
};

export const CapabilityBadge = ({capability}) => {
  const getBadgeStyle = capability => {
    switch (capability) {
      case 'Event Collection':
        return {
          background: '#EFDFC8',
          color: '#1A1A1A'
        };
        --clay;
      case 'Cohort Activation':
        return {
          background: '#EFDFC8',
          color: '#1A1A1A'
        };
        --clay;
      case 'Campaign Optimization':
        return {
          background: '#EFDFC8',
          color: '#1A1A1A'
        };
        --clay;
      case 'Identity Signal':
        return {
          background: '#EFDFC8',
          color: '#1A1A1A'
        };
        --clay;
      case 'Contextual Signal':
        return {
          background: '#EFDFC8',
          color: '#1A1A1A'
        };
        --clay;
      case 'Connectivity':
        return {
          background: '#EFDFC8',
          color: '#1A1A1A'
        };
        --clay;
      case 'Routing':
        return {
          background: '#EFDFC8',
          color: '#1A1A1A'
        };
        --clay;
      case 'Data Collaboration':
        return {
          background: '#EFDFC8',
          color: '#1A1A1A'
        };
        --clay;
      default:
        return {
          background: '#A7B3D9',
          color: '#1A1A1A'
        };
        --haze;
    }
  };
  const style = getBadgeStyle(capability);
  return <span style={{
    display: 'inline-block',
    padding: '0.125rem 0.375rem',
    borderRadius: '0.25rem',
    fontSize: '0.625rem',
    background: style.background,
    color: style.color,
    fontWeight: '500',
    whiteSpace: 'nowrap'
  }}>
      {capability}
    </span>;
};

export const EnvironmentBadge = ({environment}) => {
  const getBadgeStyle = environment => {
    switch (environment) {
      case 'Web':
        return {
          background: '#F9C1A8',
          color: '#1A1A1A'
        };
        --peach;
      case 'iOS':
        return {
          background: '#F9C1A8',
          color: '#1A1A1A'
        };
        --peach;
      case 'Android':
        return {
          background: '#F9C1A8',
          color: '#1A1A1A'
        };
        --peach;
      case 'CTV':
        return {
          background: '#F9C1A8',
          color: '#1A1A1A'
        };
        --peach;
      case 'API Direct':
        return {
          background: '#F9C1A8',
          color: '#1A1A1A'
        };
        --peach;
      default:
        return {
          background: '#A7B3D9',
          color: '#1A1A1A'
        };
        --haze;
    }
  };
  const style = getBadgeStyle(environment);
  return <span style={{
    display: 'inline-block',
    padding: '0.125rem 0.375rem',
    borderRadius: '0.25rem',
    fontSize: '0.625rem',
    background: style.background,
    color: style.color,
    fontWeight: '500',
    whiteSpace: 'nowrap'
  }}>
      {environment}
    </span>;
};

export const DirectionBadge = ({direction}) => {
  const getBadgeStyle = direction => {
    switch (direction) {
      case 'Bidirectional':
        return {
          background: '#FA8784',
          color: '#1A1A1A'
        };
        --tomato;
      case 'Destination':
        return {
          background: '#FA8784',
          color: '#1A1A1A'
        };
        --tomato;
      case 'Source':
        return {
          background: '#FA8784',
          color: '#1A1A1A'
        };
        --tomato;
      default:
        return {
          background: '#A7B3D9',
          color: '#1A1A1A'
        };
        --haze;
    }
  };
  const style = getBadgeStyle(direction);
  return <span style={{
    display: 'inline-block',
    padding: '0.125rem 0.375rem',
    borderRadius: '0.25rem',
    fontSize: '0.625rem',
    background: style.background,
    color: style.color,
    fontWeight: '500'
  }}>
      {direction}
    </span>;
};

<Card title="">
  <div style={{ display: "flex", alignItems: "center", marginBottom: "1rem" }}>
    <div style={{ width: '32px', height: '32px', marginRight: '0.75rem', display: 'flex', alignItems: 'center', justifyContent: 'center', flexShrink: 0 }}>
      <img src="https://mintcdn.com/permutive/pNhz39ducTVcQczh/images/integrations/logos/magnite.svg?fit=max&auto=format&n=pNhz39ducTVcQczh&q=85&s=8bf91dd1dfd891eadcae622a4ee10a38" alt="Magnite" style={{ maxWidth: '32px', maxHeight: '32px', display: 'block' }} width="400" height="400" data-path="images/integrations/logos/magnite.svg" />
    </div>

    <h3
      style={{
    margin: 0,
    fontSize: "1.125rem",
    fontWeight: "600",
  }}
    >
      Magnite
    </h3>
  </div>

  <div style={{ marginBottom: "1rem" }}>
    <BadgeRowCenter label="Direction">
      <DirectionBadge direction="Destination" />
    </BadgeRowCenter>

    <BadgeRowCenter label="Environment">
      <BadgeContainer>
        <EnvironmentBadge environment="Web" />
      </BadgeContainer>
    </BadgeRowCenter>

    <BadgeRowCenter label="Capability">
      <BadgeContainer>
        <CapabilityBadge capability="Cohort Activation" />
      </BadgeContainer>
    </BadgeRowCenter>

    <BadgeRowCenter label="SDK Required">
      <SdkRequiredBadge required="Yes" />
    </BadgeRowCenter>

    <BadgeRowCenter label="Product(s) Required">
      <ProductRequiredBadge product="Core Platform" />
    </BadgeRowCenter>
  </div>

  <p
    style={{
  margin: 0,
  fontSize: "0.875rem",
  color: "#6b7280",
  lineHeight: "1.5",
}}
  >
    Magnite is a leading independent sell-side advertising platform that helps
    publishers maximize revenue through programmatic advertising.
  </p>
</Card>

<CardGroup cols={2}>
  <Card title="Setup" href="#setup" icon="gear" />

  <Card title="Troubleshooting" href="#troubleshooting" icon="wrench" />
</CardGroup>

## Overview

Magnite (formerly Rubicon Project) is a leading independent sell-side advertising platform that enables publishers to maximize their advertising revenue through programmatic channels. Our integration with Magnite SSP allows you to activate your Permutive cohorts in real-time for targeting on Magnite's supply-side platform.

This integration is a Destination:

* **Destination:** Permutive cohorts can be activated and synced with Magnite SSP in real-time, enabling advertisers to target your audiences programmatically.

Use cases include:

* **Cookie-less audience activation at scale:** Activate Permutive Custom Cohort signals programmatically via the bidstream without reliance on third-party cookies, enabling addressable reach across all users
* **Private Marketplace (PMP) deals:** Use Custom Cohorts to create premium, curated inventory packages for direct buyer relationships
* **Maximize programmatic yield:** Make Permutive Custom Cohorts available through Magnite's ad exchange to increase competition and drive higher CPMs

**Cohort Support:**

* ✅ **Custom Cohorts** - Publisher-defined audiences created in the Permutive dashboard
* ❌ **Standard Cohorts** - Not currently supported
* ❌ **Curation Cohorts** - Not currently supported
* ❌ **Data Clean Room Cohorts** - Not currently supported

<Note>
  The Magnite SSP integration currently only supports Custom Cohort signals. If you are interested in activating Standard, Curation, or Data Clean Room cohorts to Magnite, please reach out to your Customer Success Manager to discuss this use case.
</Note>

## Environment Compatibility

| Environment    | Supported    | Notes         |
| -------------- | ------------ | ------------- |
| **Web**        | <YesBadge /> | --            |
| **iOS**        | <NoBadge />  | Not supported |
| **Android**    | <NoBadge />  | Not supported |
| **CTV**        | <NoBadge />  | Not supported |
| **API Direct** | <NoBadge />  | Not supported |

## Prerequisites

* **Magnite SSP Account** - You must have an active Magnite SSP account
* **Magnite Publisher ID** - Your Magnite SSP Account ID (required for API authentication)
* **Permutive SDK** - The Permutive Web SDK must be deployed on your site
* **Prebid.js with Permutive RTD Module** - Prebid.js must be configured with the Permutive Real-Time Data (RTD) module to pass cohort data to Magnite
* **Bidder Adapter** - The [`rubicon`](https://docs.prebid.org/dev-docs/bidders/rubicon.html) bidder adapter must be configured in your Prebid.js setup (this is the bidder code for Magnite)

## Setup

<Tabs>
  <Tab title="Primary Setup Steps">
    <Steps>
      <Step title="Enable in Permutive Dashboard">
        You must enable the Magnite SSP integration in the Permutive Dashboard, if this has not already been done.

        In the Permutive dashboard, navigate to your workspace's integrations page. Click *Add Integration* and select *Magnite SSP*. You will be prompted to enter your **Magnite Publisher ID** (your Magnite SSP Account ID).

        This Publisher ID is used to authenticate with the Magnite API and tells Permutive which Magnite account to create and manage segments in. When you activate cohorts, Permutive uses this ID to make server-side API calls to the Magnite Segment Management API on your behalf.

        <Note>The integration may also be listed as "Rubicon SSP" in some areas of the dashboard, as Magnite was formerly known as Rubicon Project.</Note>
      </Step>

      <Step title="Configure Cohort Activations">
        Once the integration is enabled, you can configure individual cohorts for activation to Magnite SSP.

        Navigate to the cohort you wish to activate, and toggle the Magnite SSP activation to *On*. When you enable this activation, Permutive will automatically create the corresponding segment in your Magnite SSP account using the Magnite Segment Management API.
      </Step>

      <Step title="Verify Setup">
        After activating a cohort, verify that the segment has been created successfully in your Magnite SSP dashboard and that cohort data is being passed in bid requests.

        **Verify segment creation:**
        In your Magnite SSP account, navigate to your segment management section. You should see segments created by Permutive, typically with names corresponding to your cohort IDs or names.

        **Verify bid request data:**
        Use the [Professor Prebid Chrome extension](https://chromewebstore.google.com/detail/professor-prebid/kdnllijdimhbledmfdbljampcdphcbdc) to inspect bid requests:

        1. Check local storage for the `_prubicons` key (Custom Cohorts)
        2. Find Magnite (`rubicon`) bidder requests in Professor Prebid
        3. Verify that the ORTB2 object contains Permutive cohort data in `ortb2.user.data` and `ortb2.user.keywords`

        <Note>It may take a few minutes for segments to appear in the Magnite UI and for cohort membership to populate after initial page load.</Note>
      </Step>
    </Steps>
  </Tab>

  <Tab title="Web">
    ### Integrate with Prebid.js

    The Magnite SSP integration works through the Permutive Real-Time Data (RTD) module in Prebid.js. The module reads Custom Cohort data from local storage (set by the Permutive SDK) and attaches it to bid requests as first-party data following OpenRTB 2.x conventions.

    #### Configuration

    In your Prebid.js configuration, include the Permutive RTD module:

    ```javascript theme={"dark"}
    pbjs.setConfig({
      realTimeData: {
        dataProviders: [
          {
            name: "permutive",
            waitForIt: true,
            params: {
              maxSegs: 500,
            },
          },
        ],
      },
    });
    ```

    #### How it Works

    The Magnite SSP integration operates through a two-step process:

    **1. Segment Pre-Creation (Server-Side)**

    When you activate a Custom Cohort in Permutive, segments are created in your Magnite account via the Segment Management API. This pre-creation step is necessary because Magnite needs to register each segment ID and map it to a meaningful segment name before it can be used for targeting. This ensures that when Magnite receives bid requests containing segment IDs, it can recognize them and make them available to buyers (DSPs) for targeting.

    **2. Local Storage Cohort Exposure**

    The Permutive Web SDK exposes Custom Cohort signals via local storage:

    * **Custom Cohorts**: Stored in the `_prubicons` local storage key

    **3. Real-Time Bid Enrichment (Client-Side)**

    The Permutive RTD module acts as a bridge between the Permutive Web SDK and Prebid.js:

    1. The Permutive RTD module reads Custom Cohort IDs from local storage (`_prubicons`)
    2. Cohort data is attached to the ORTB2 object in bid requests for Magnite
    3. The module updates two locations:
       * `ortb2.user.data` – adds a data provider entry for `permutive` with the list of cohort IDs in the `segment` field
       * `ortb2.user.keywords` – adds a keyword group called `permutive` containing the list of cohort IDs
    4. Magnite receives cohort targeting data in the bid request and makes it available to demand partners (DSPs) for real-time targeting

    #### Consent

    While Permutive is listed as a TCF vendor (ID: 361), Permutive does not typically obtain vendor consent from the TCF, but instead relies on publisher purpose consents. Publishers wishing to use TCF vendor consent instead can add 361 to their CMP and set `params.enforceVendorConsent` to `true`:

    ```javascript theme={"dark"}
    pbjs.setConfig({
      realTimeData: {
        dataProviders: [{
          name: 'permutive',
          params: {
            enforceVendorConsent: true  // Require TCF vendor consent for Permutive (ID: 361)
          }
        }]
      }
    })
    ```

    For more details on Prebid.js configuration, see the [Prebid.js documentation](https://docs.prebid.org/dev-docs/modules/permutiveRtdProvider.html).
  </Tab>
</Tabs>

## Data Types

The Magnite SSP integration is a destination-only integration focused on cohort activation. Permutive does not collect event data from Magnite SSP.

When Custom Cohorts are activated to Magnite, the following data is transmitted via the Prebid.js bidstream:

<AccordionGroup>
  <Accordion title="ORTB2 Signal Locations">
    Permutive passes Custom Cohort data to Magnite SSP via the ORTB2 object in Prebid.js bid requests:

    | ORTB2 Location                        | Cohort Types   |
    | ------------------------------------- | -------------- |
    | `ortb2.user.data` (name: `permutive`) | Custom Cohorts |
    | `ortb2.user.keywords` (`permutive`)   | Custom Cohorts |

    <Note>Standard, Curation, and DCR cohorts are not currently supported for Magnite and will not appear in bid requests.</Note>
  </Accordion>

  <Accordion title="Local Storage Keys">
    The Permutive Web SDK exposes cohort data via local storage, which the Permutive RTD module reads to populate bid requests.

    <ResponseField name="_prubicons" type="array">
      Local storage key containing Custom Cohort IDs for Magnite.
    </ResponseField>
  </Accordion>

  <Accordion title="Segments (Server-Side)">
    Permutive creates and manages segments in your Magnite SSP account via the
    Magnite Segment Management API. Each activated Custom Cohort is represented as a
    segment in Magnite.

    <ResponseField name="segment_id" type="string">
      The unique identifier for the segment in Magnite, typically corresponding
      to the Permutive cohort ID.
    </ResponseField>

    <ResponseField name="segment_name" type="string">
      The name of the segment as it appears in Magnite, typically matching the
      cohort name in Permutive.
    </ResponseField>
  </Accordion>
</AccordionGroup>

## Troubleshooting

<AccordionGroup>
  <Accordion title="Segments not appearing in Magnite UI">
    If you've activated a Custom Cohort in Permutive but don't see the corresponding segment in your Magnite SSP account:

    * Verify that the Magnite SSP integration is properly enabled in your Permutive Dashboard with the correct Magnite Publisher ID
    * Check that you have the correct permissions in your Magnite account to view segments
    * Ensure there are no special characters in your cohort names, as these can cause issues with segment creation
    * Wait a few minutes, as there may be a delay between activation in Permutive and segment creation in Magnite

    If the issue persists, contact Permutive Support with your cohort ID and workspace details.
  </Accordion>

  <Accordion title="Cohort data not appearing in bid requests">
    If Permutive Custom Cohorts aren't being passed to Magnite in your bid requests:

    * Verify that the Permutive RTD module is properly configured in your Prebid.js setup
    * Confirm that the Permutive SDK is loading correctly on your pages
    * Use browser developer tools to inspect local storage and verify that the `_prubicons` key contains cohort data
    * Check your Prebid.js console logs for any errors related to the Permutive RTD module
    * Use the [Professor Prebid Chrome extension](https://chromewebstore.google.com/detail/professor-prebid/kdnllijdimhbledmfdbljampcdphcbdc) to inspect ORTB2 data being sent to Magnite bid requests

    <Note>If you see cohort data in local storage but not in bid requests, verify that your Prebid.js configuration includes `waitForIt: true` for the Permutive RTD module.</Note>
  </Accordion>

  <Accordion title="Empty _prubicons local storage key">
    If the `_prubicons` local storage key is empty or missing:

    * Verify that Custom Cohorts have been activated in the Permutive dashboard with Magnite SSP enabled
    * Check that users actually qualify for the activated cohorts based on cohort definitions
    * Ensure the Permutive SDK is loading before Prebid.js attempts to read cohort data
    * Verify that third-party cookies and local storage are not blocked by browser settings or extensions
    * Check the browser console for any Permutive SDK errors during page load
  </Accordion>

  <Accordion title="Unable to enable Magnite SSP integration">
    If you see an error when trying to enable the Magnite SSP integration in the Permutive Dashboard:

    * Verify that you have the necessary permissions in your Permutive workspace
    * Ensure your workspace has the correct product entitlements to use SSP activations
    * Verify that your Magnite Publisher ID is correct
    * Contact Permutive Support if you believe you should have access but are unable to enable the integration
  </Accordion>

  <Accordion title="GDPR/consent issues blocking cohort signals">
    In GDPR regions, consent management may affect cohort data transmission:

    * **Note:** Permutive is a TCF vendor (ID: 361), but by default relies on publisher purpose consents rather than TCF vendor consent
    * If you've enabled `params.enforceVendorConsent: true`, verify that Permutive (vendor ID 361) is added to your CMP and consent is being collected
    * Verify that your Consent Management Platform (CMP) is properly configured and Permutive has consent to process user data
    * Check that the Permutive SDK is receiving consent signals correctly
    * Ensure Prebid.js is configured to respect consent signals and only pass data when consent is granted
  </Accordion>
</AccordionGroup>

## Changelog

<Info>
  For detailed changelog information, visit our
  [Changelog](https://changelog.permutive.com/).
</Info>
