← Hive AxylCONTENT HISTORY
WHAT CHANGED
Update to Hive Axyl
Snapshot Oct 24, 2026 · 13:42 UTC · version 2.1.0
Collection source: downloaded plugin package.
First saved snapshot
No earlier snapshot is available to establish a change.
Save Hive Axyl and check future changes in Following.
Up to 10 plugins free · no card required.
Compare saved observations
Download comparison JSONFull technical diff · 0 changed fields
Full snapshot data
{
"description": "Implements user-requested Hive Axyl logout in Unity, including outcome-specific local cleanup, stored credentials and protection against clearing a replacement session. Does not implement account withdrawal, provider sign-out or automatic cleanup after login failure.",
"included_files": [],
"name": "axyl-logout",
"skill_md_contents": "---\nname: axyl-logout\ndescription: \"Implements user-requested Hive Axyl logout in Unity, including outcome-specific local cleanup, stored credentials and protection against clearing a replacement session. Does not implement account withdrawal, provider sign-out or automatic cleanup after login failure.\"\nlicense: Apache-2.0\nmetadata:\n author: Com2uS Platform Corporation\n sdk-version: 1.0.0\n engine: Unity 6000.0+\n---\n\n# Log out the intended Axyl session\n\nA user-requested logout of the current player. The Installed SDK and SDK results\nsections below apply to every step; Push settings and account binding applies when\nthe app uses push.\n\n**Inputs:** the live session the user asked to end.\n**App owns:** coordination with login and refresh, storage, push policy and result types.\n\n## Flow\n\n1. Resolve `IAuthService` and `ISessionManager` and require the target live session.\n A missing service, no session or cancellation before the call ends here with\n nothing cleared; it is not a logout `Failure`.\n2. If the app detaches push on logout, dispatch the detach first under this account\n (see Logout and account switch below) and keep its outcome separate.\n3. Capture the target session, then call\n `auth.LogoutPlayerAsync(new ApiCallContext { Token = ct })` once.\n4. Apply the returned result; cancellation after a returned `Success` does not undo it:\n\n| `AuthLogoutPlayerResult` | Local state |\n|---|---|\n| `Success` | Clear the target session and its stored credentials; server invalidation confirmed |\n| `Failure` with `Problem.Code == HiveErrorCode.Cancelled` | Keep; the caller withdrew the request |\n| Other `Failure` | Clear the target's local state for this explicit logout; report server invalidation as unconfirmed |\n| `GuestSignoutBlocked`, `TerminateService`, `PlayerNotFound` or another typed refusal | Keep; never bypass the server's refusal |\n| Unknown | Keep |\n\n5. Before `session.ClearSession()` or deleting storage, confirm the target is still\n the current session. Never erase a newer sign-in; a refresh that changed the token\n needs reconciliation, not blind deletion. One cleanup owner handles\n `OnSessionExpired` (raised by `ClearSession`), storage deletion and in-flight\n snapshot writes.\n6. Report the server outcome, local cleanup and any replacement separately. A\n storage deletion failure means a restart may still log in automatically.\n\nThe recipe keeps local state on a technical failure; follow the SDK policy above.\nThat cleanup applies only to an explicit logout, not to a failed login, account\nwithdrawal or shutdown. `GuestSignoutBlocked` protects a guest's last recovery path.\nProvider sessions (Apple, Google, Steam) are not signed out.\n\n## Verify\n\n- [ ] Success and a network failure clear only the target; cancellation, typed\n refusals and unknown results keep everything.\n- [ ] A login completing during the request, a refresh during logout and a late\n snapshot write never lose the newer session.\n- [ ] A storage deletion failure is reported rather than hidden by memory cleanup.\n- [ ] With push: the detach runs under the original account before logout, and a\n detach accepted before an Auth refusal is reported as split state.\n\n<!-- axyl-shared: core/installed-sdk.md -->\n\n## Installed SDK\n\n- Read `Packages/manifest.json`, the lock file and each resolved `package.json`.\n All `com.com2usplatform.hiveaxyl.*` packages must be the same release (UPM does\n not enforce this); `com.hive.axyl.*` packages are a release before 1.0.0-rc.9.\n- The installed SDK wins for APIs, types and contracts. If its release differs\n from this skill's `sdk-version`, apply a step only after its fields, result\n variants, platform support and failure behaviour match; otherwise stop at that\n step and report what is missing. Never change the installed version.\n- The app owns UI, storage, the device key and orchestration. Sample and recipe\n classes are not SDK APIs.\n\n<!-- /axyl-shared -->\n\n<!-- axyl-shared: core/results.md -->\n\n## SDK results\n\nMatch each call's concrete result and read `Success.Data` only after checking the\nfields the next step needs. The markers live in `Hive.Axyl.Contracts.Result`.\n\n| Result | Handling |\n|---|---|\n| `IUserCanceledOutcome` | The user dismissed OS or provider UI: stop this attempt quietly |\n| `IUnknownOutcome` | Keep `Code` and `RawJson`; never treat it as a known refusal or a success |\n| `IUntypedProblem` | Technical failure in `Problem` (`HiveError`): network, timeout or caller `Cancelled` |\n| Other typed variant | Only that call's documented meaning |\n\nPass `new ApiCallContext { Token = ct }` and check cancellation before each\nfollow-up call; a request cancelled in flight may still have taken effect. Never\nbranch on HTTP status, exception text or raw bodies, and never log tokens or\ncredentials.\n\n<!-- /axyl-shared -->\n\n<!-- axyl-shared: core/push-management.md -->\n\n## Push settings and account binding\n\nUse `Hive.Axyl.Push.IPushService` with the account's authenticated session and the\ndevice token actually registered; a login access token is not a device token. The\nrecipes do not compose these calls: the coordination below is the app's design.\n\n| Change | Call with `new ApiCallContext { Token = ct }` |\n|---|---|\n| Language | `PatchTokenLanguageAsync(new PatchTokenLanguageRequest { Token = deviceToken, Language = language }, ctx)` |\n| Consent | `PatchTokenAgreementAsync(new PatchTokenAgreementRequest { Token = deviceToken, Agreement = new Agreement { Info = info, Advertise = advertise, Night = night } }, ctx)` |\n| Player binding | `DetachTokenIdentifierAsync(new DetachTokenIdentifierRequest { Token = deviceToken }, ctx)` |\n\nEach result has `Success`, `ResourceNotInScope`, `InvalidSubject`, unknown and\n`Failure` variants. `Success` means the server accepted the change asynchronously,\nnot that it was applied or that delivery changed. Keep the latest desired state\nafter a failure; a typed refusal is no reason to resend it unchanged.\n\n- `Language` is a defined `LanguageCode`, never `Unspecified`.\n- The consent patch replaces the whole `Agreement`; `Night = true` requires\n `Advertise = true`. Consent comes from app policy, never from OS permission.\n- A new registration or token uses the full `UpsertTokenAsync`; a patch changes one\n setting of a known registration. Run patches and upserts through one app-owned\n update flow that carries account, token and the latest full state, so an old\n result never marks a newer token synchronized. Client ordering does not prove\n server apply order after a timeout.\n\n### Logout and account switch\n\nWhether logout detaches the player binding, and whether a detach failure blocks\nlogout, is app policy: reuse it or ask the app developer, never add it silently.\n\n| Policy | Boundary |\n|---|---|\n| Detach on logout | Capture the player and device token, pause queued upserts, and dispatch the detach while that account is still authenticated, before Auth logout; then apply the app's failure policy and the logout result |\n| Keep the binding | The token keeps targeting that player; login alone does not rebind it, and an app rebind upserts with the new account and its consent |\n\nDetach removes only the player ID from the registration: it does not delete the\ntoken, revoke OS permission, reset consent or recall queued notifications. Never\nsend one account's cleanup as another, or retry it with an invalidated token. If the\ndetach succeeds but Auth logout is refused or cancelled, report that split state;\nnever rebind automatically or call it a rollback.\n\n<!-- /axyl-shared -->\n"
}SHA-256 of public snapshot: 12e600e6f2f34bf7b040cbf2b98306026a7417c1dd3ceb2e79dfda39a71c0b4a