Skip to main content
Every public member of the com.appstack.unity-sdk UPM package. For installation and integration guidance, see the Unity SDK guide. Current stable release: 1.6.0, published 16 September 2026. See the changelog for everything that changed.

AppstackSDK

A static class in the Appstack.Unity namespace. Calls are synchronous unless noted; DeleteUserData() returns a Task and GetAttributionParams() is callback-based.
Every method logs and rethrows on failure, so wrap calls in a try/catch if a native error should not propagate into your game loop.

Configure()

Starts the SDK. Must be called before any other SDK method.
string
required
Your app’s Appstack API key, from the dashboard under app settings.
int
default:"1"
Console verbosity, descending: 0 DEBUG, 1 INFO, 2 WARN, 3 ERROR. iOS has no dedicated WARN tier, so 2 behaves like 3 there.
string
default:"null"
Your identifier for the signed-in user, when known at startup.

SetCustomerUserId()

Sets the customer user ID after Configure(), for example once a login reveals it. A repeat Configure() is a no-op, so it cannot be used to change the ID. Safe to call at any time; last write wins.
string
required
Your identifier for the signed-in user. Set it as soon as it is known, and at least one event has to follow for it to take effect.

SendEvent()

Sends an event. Throws ArgumentException when eventType is CUSTOM and eventName is missing, or when a parameter value cannot be represented as JSON.
EventType
required
The event to send. See EventType.
string
default:"null"
The event name. Required for EventType.CUSTOM, ignored for standard events.
Dictionary<string, object>
default:"null"
JSON-compatible parameters. Supports strings, booleans, finite numbers, nulls, nested string-keyed dictionaries, and arrays. For revenue events send revenue and currency.

GetAppstackId()

Returns the Appstack ID for the current install.
string
The install’s Appstack ID.

IsSdkDisabled()

Whether the SDK is disabled, for example because the API key is invalid.
bool
true when the SDK is disabled.

GetAttributionParams()

Fetches attribution parameters asynchronously, via callbacks. Exactly one of onSuccess or onError fires. Throws ArgumentNullException when onSuccess is null.
Action<Dictionary<string, object>>
required
Called with the attribution parameters.
Action<string>
default:"null"
Called with an error message if the request fails.
On iOS, onSuccess receives the reserved appstack_match_status key alongside the attribution parameters, so an organic install, a skipped match, and a failed request can be told apart rather than all arriving as an empty result. Android does not report the key yet.
Parses an Appstack standard Universal Link or App Link delivered by Application.absoluteURL or Application.deepLinkActivated. Safe to call before Configure(). Throws ArgumentException when url is empty or allowedHosts contains a blank hostname.
string
required
The tapped link.
string[]
default:"null"
Hosts to accept. Omit to accept any host.
AppstackLinkResult
The parsed link, or null when the URL is not a recognised Appstack link.

EnableAppleAdsAttribution()

Starts Apple Search Ads attribution. iOS only, and a no-op on Android.

DeleteUserData()

Permanently deletes this install’s Appstack data, for GDPR and privacy requests. The task completes after the native request finishes.
Task
Completes when deletion finishes.

Types

AppstackLinkResult

A tapped link, parsed entirely from the URL. Properties are read-only to callers.
The Appstack deep link ID.
Dictionary<string, string>
Query parameters parsed off the tapped URL.
string
The URL that was handled.

EventType

Standard attribution events. Values follow the SNAKE_CASE convention used by mobile measurement partners. Where two names are synonymous, both are provided for compatibility with existing integrations.
INSTALL is tracked by the SDK itself. You do not need to send it.