# setIntegrationAttributes

Sets integration attributes for third-party analytics and attribution providers.

> **Info**

This method was introduced in version 4.8.1. It allows you to set attributes for third-party integrations like Amplitude, Mixpanel, and other analytics platforms.



Purpose [#purpose]

Sets integration attributes that are sent to Superwall's servers and can be used for analytics and attribution tracking with third-party providers.

Signature [#signature]

```swift
public func setIntegrationAttributes(_ props: [IntegrationAttribute: String?])
```

Parameters [#parameters]

<TypeTable
  type="{
  props: {
    type: &#x22;[IntegrationAttribute: String?]&#x22;,
    description: &#x22;A dictionary mapping integration attribute keys to their values. Use `nil` to remove an attribute.&#x22;,
    required: true,
  },
}"
/>

Returns / State [#returns--state]

This method returns `Void`. The attributes are stored and sent to Superwall's servers.

Usage [#usage]

Set integration attributes:

```swift
Superwall.shared.setIntegrationAttributes([
  .amplitudeUserId: "user123",
  .mixpanelDistinctId: "distinct456",
  .firebaseInstallationId: "abc123",
  .custom("myCustomKey"): "customValue"
])
```

Remove an attribute by setting it to `nil`:

```swift
Superwall.shared.setIntegrationAttributes([
  .amplitudeUserId: nil  // Removes the amplitudeUserId attribute
])
```

Access current integration attributes:

```swift
let attributes = Superwall.shared.integrationAttributes
print("Current attributes: \(attributes)")
```

IntegrationAttribute Types [#integrationattribute-types]

Common integration attributes include:

* `.amplitudeUserId` - Amplitude user ID
* `.mixpanelDistinctId` - Mixpanel distinct ID
* `.firebaseInstallationId` - Firebase installation ID (4.10.8+)
* `.appstackId` - Appstack identifier (4.12.11+)
* `.custom(String)` - Custom attribute key

Related [#related]

* [`integrationAttributes`](/docs/ios/sdk-reference/integrationAttributes) - Get current integration attributes
* [`Superwall.shared.integrationAttributes`](/docs/ios/sdk-reference/Superwall#integrationattributes) - Published property for integration attributes