# NamiCampaign

The campaign object represents the live campaigns configured in the Nami Control Center that are available to the device after all campaign filtering and ordering rules are applied.

{% tabs %}
{% tab title="Swift" %}

```swift
@objc public class NamiCampaign : NSObject, Codable, Identifiable {
    public var id: String { rule }
    public var rule: String
    public var segment: String
    public var paywall : String
    public var type: NamiCampaignRuleType = .unknown
    public var value: String?
}
```

{% endtab %}

{% tab title="Kotlin" %}

```kotlin
class NamiCampaign(
     val paywall: String,
     val segment: String,
     val type: NamiCampaignRuleType,
     val value: String?
)
```

{% endtab %}

{% tab title="Flutter" %}

```dart
class NamiCampaign {
  final String paywall;
  final String segment;
  final NamiCampaignRuleType type;
  final String? value;
}
```

{% endtab %}

{% tab title="React Native" %}

```jsx
export type NamiCampaign = {
  id: string;
  rule: string;
  segment: string;
  paywall: string;
  type: NamiCampaignRuleType;
  value?: string | null;
};
```

{% endtab %}

{% tab title="Unity" %}

```cpp
public class NamiCampaign
    {
        /// <summary> iOS only </summary>
        public string Id { get; private set; }

        /// <summary> iOS only </summary>
        public string Rule { get; private set; }

        public string Paywall { get; private set; }

        public string Segment { get; private set; }

        /// <summary> Android only </summary>
        public NamiCampaignRuleType Type { get; private set; }

        public string Value { get; private set; }
    }
```

{% endtab %}
{% endtabs %}


---

# 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.namiml.com/sdk-reference/namicampaignmanager/namicampaign.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.
