# Setting up the SDK

### **1. Add the OfferWall Unity plugin to your Unity project**

[Download](https://github.com/GreedyGame/unity-offer_wall_plugin/releases/latest) and import the latest version of OfferWall Unity Plugin from GitHub.

### **2. Configuring Publishing Settings**

* Set the minimum API level to 24 or above and the target API level to 33 or above under Edit/ProjectSettings/Player/Other Settings
* Make sure you check the below-mentioned checkboxes under Edit/ProjectSettings/Player/Publishing Settings.
  * **Custom Main Manifest**
  * **Custom Main Gradle Template**
  * **Custom Gradle Settings Template**

<figure><img src="/files/9DDbdgANBFtTwZ6yxczp" alt=""><figcaption><p>Player > Publishing settings</p></figcaption></figure>

### **3. Configuring dependencies**

Adding `mavenCentral()` as a repository in `settingsTemplate.gradle`

```groovy
pluginManagement {
    repositories {
        **ARTIFACTORYREPOSITORY**
        gradlePluginPortal()
        google()
    }
}

include ':launcher', ':unityLibrary'
**INCLUDES**

dependencyResolutionManagement {
    repositoriesMode.set(RepositoriesMode.PREFER_SETTINGS)
    repositories {
        **ARTIFACTORYREPOSITORY**
        google()
        mavenCentral() //<----------------Add this line
        flatDir {
            dirs "${project(':unityLibrary').projectDir}/libs"
        }
    }
}
```

Add the below line inside the dependencies block in your mainTemplate.gradle file

```groovy
implementation 'com.pubscale.sdkone:offerwall:1.0.7'
```

### **4. Force resolve dependencies**

**Force resolve** forces the Package Manager to resolve the project’s packages, reinstalling any altered or missing package and removing extraneous packages.

To Force resolve the dependencies, Goto Assets > External Dependency Manager > Android Resolver > Force Resolve (if the resolver did not open automatically)

<figure><img src="https://pubscale.gitbook.io/~gitbook/image?url=https%3A%2F%2F3371507213-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FaUVG0uxfukyc5xCdlEhZ%252Fuploads%252FUzYUObvgE35BpwNoljLm%252Fimage.png%3Falt%3Dmedia%26token%3Dbd15261f-4718-4073-ae62-8839fe558896&#x26;width=768&#x26;dpr=4&#x26;quality=100&#x26;sign=c95a673969eca060eea708c9fdc31002608f810ed2f72bebef304fa7c837926b" alt=""><figcaption><p>Assets > External Dependency Manager > Android Resolver > Force Resolve</p></figcaption></figure>


---

# 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://pubscale.gitbook.io/offerwall-sdk/1.0.7/unity/setting-up-the-sdk.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.
