@layers/amba-core-wasm 1.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +44 -0
- package/package.json +42 -0
- package/pkg/amba_core.d.ts +262 -0
- package/pkg/amba_core.js +1575 -0
- package/pkg/amba_core_bg.wasm +0 -0
- package/pkg/amba_core_bg.wasm.d.ts +107 -0
package/README.md
ADDED
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
# @layers/amba-core-wasm
|
|
2
|
+
|
|
3
|
+
The amba SDK's Rust core compiled to WebAssembly. Internal package — applications consume one of the friendlier wrappers:
|
|
4
|
+
|
|
5
|
+
| If you're targeting… | Use |
|
|
6
|
+
| -------------------------------- | --------------------------- |
|
|
7
|
+
| Browser | `@layers/amba-web` |
|
|
8
|
+
| Node.js | `@layers/amba-node` |
|
|
9
|
+
| React Native (Expo Go + bare RN) | `@layers/amba-react-native` |
|
|
10
|
+
| Expo with config plugin | `@layers/amba-expo` |
|
|
11
|
+
| Any other JS runtime | this package, directly |
|
|
12
|
+
|
|
13
|
+
## Direct usage
|
|
14
|
+
|
|
15
|
+
```ts
|
|
16
|
+
import init, { AmbaCoreWasm } from "@layers/amba-core-wasm";
|
|
17
|
+
|
|
18
|
+
await init(); // load the .wasm binary
|
|
19
|
+
|
|
20
|
+
const core = AmbaCoreWasm.init(
|
|
21
|
+
JSON.stringify({
|
|
22
|
+
api_key: "amba_pk_…",
|
|
23
|
+
sdk_platform: "web",
|
|
24
|
+
sdk_wrapper_version: "custom/1.0.0",
|
|
25
|
+
}),
|
|
26
|
+
window.fetch.bind(window),
|
|
27
|
+
);
|
|
28
|
+
|
|
29
|
+
await core.track("app_opened", JSON.stringify({ source: "deep_link" }));
|
|
30
|
+
const user = await core.signInAnonymously();
|
|
31
|
+
console.log(user);
|
|
32
|
+
```
|
|
33
|
+
|
|
34
|
+
## Source
|
|
35
|
+
|
|
36
|
+
The Rust source lives at `core/` in this monorepo. To rebuild after Rust changes:
|
|
37
|
+
|
|
38
|
+
```bash
|
|
39
|
+
pnpm --filter @layers/amba-core-wasm run build
|
|
40
|
+
```
|
|
41
|
+
|
|
42
|
+
## License
|
|
43
|
+
|
|
44
|
+
MIT.
|
package/package.json
ADDED
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@layers/amba-core-wasm",
|
|
3
|
+
"version": "1.0.0",
|
|
4
|
+
"description": "amba SDK Rust core compiled to WASM. Consumed by @layers/amba-web, @layers/amba-node, @layers/amba-react-native.",
|
|
5
|
+
"type": "module",
|
|
6
|
+
"main": "./pkg/amba_core.js",
|
|
7
|
+
"types": "./pkg/amba_core.d.ts",
|
|
8
|
+
"exports": {
|
|
9
|
+
".": {
|
|
10
|
+
"types": "./pkg/amba_core.d.ts",
|
|
11
|
+
"import": "./pkg/amba_core.js"
|
|
12
|
+
},
|
|
13
|
+
"./wasm": "./pkg/amba_core_bg.wasm"
|
|
14
|
+
},
|
|
15
|
+
"files": [
|
|
16
|
+
"pkg/amba_core.js",
|
|
17
|
+
"pkg/amba_core_bg.wasm",
|
|
18
|
+
"pkg/amba_core.d.ts",
|
|
19
|
+
"pkg/amba_core_bg.wasm.d.ts",
|
|
20
|
+
"README.md"
|
|
21
|
+
],
|
|
22
|
+
"sideEffects": [
|
|
23
|
+
"./pkg/snippets/*"
|
|
24
|
+
],
|
|
25
|
+
"license": "MIT",
|
|
26
|
+
"repository": {
|
|
27
|
+
"type": "git",
|
|
28
|
+
"url": "https://github.com/layers/amba-sdks.git",
|
|
29
|
+
"directory": "packages/core-wasm"
|
|
30
|
+
},
|
|
31
|
+
"publishConfig": {
|
|
32
|
+
"access": "public"
|
|
33
|
+
},
|
|
34
|
+
"engines": {
|
|
35
|
+
"node": ">=20.0.0"
|
|
36
|
+
},
|
|
37
|
+
"scripts": {
|
|
38
|
+
"build": "cd ../../core && wasm-pack build --target web --out-name amba_core --out-dir ../packages/core-wasm/pkg",
|
|
39
|
+
"build:bundler": "cd ../../core && wasm-pack build --target bundler --out-name amba_core --out-dir ../packages/core-wasm/pkg-bundler",
|
|
40
|
+
"build:nodejs": "cd ../../core && wasm-pack build --target nodejs --out-name amba_core --out-dir ../packages/core-wasm/pkg-node"
|
|
41
|
+
}
|
|
42
|
+
}
|
|
@@ -0,0 +1,262 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
|
|
4
|
+
/**
|
|
5
|
+
* JS-callable opaque handle to [`AmbaCore`].
|
|
6
|
+
*
|
|
7
|
+
* The JS side instantiates it via `AmbaCoreWasm.init(configJson, fetchFn)`
|
|
8
|
+
* and stashes it for the lifetime of the page.
|
|
9
|
+
*/
|
|
10
|
+
export class AmbaCoreWasm {
|
|
11
|
+
private constructor();
|
|
12
|
+
free(): void;
|
|
13
|
+
[Symbol.dispose](): void;
|
|
14
|
+
achievementsGetAll(): Promise<any>;
|
|
15
|
+
achievementsGetProgress(): Promise<any>;
|
|
16
|
+
aiAnthropicMessages(request_json: string): Promise<any>;
|
|
17
|
+
anonymousId(): string;
|
|
18
|
+
appUserId(): string | undefined;
|
|
19
|
+
catalogList(): Promise<any>;
|
|
20
|
+
challengesClaim(id: string): Promise<any>;
|
|
21
|
+
challengesGet(id: string): Promise<any>;
|
|
22
|
+
challengesGetActive(): Promise<any>;
|
|
23
|
+
challengesGetProgress(id: string): Promise<any>;
|
|
24
|
+
collectionsDelete(collection: string, id: string): Promise<any>;
|
|
25
|
+
collectionsFind(collection: string, options_json: string): Promise<any>;
|
|
26
|
+
collectionsFindOne(collection: string, id: string): Promise<any>;
|
|
27
|
+
collectionsInsert(collection: string, row_json: string): Promise<any>;
|
|
28
|
+
collectionsUpdate(collection: string, id: string, set_json: string): Promise<any>;
|
|
29
|
+
configFetch(): Promise<any>;
|
|
30
|
+
contentCreateItem(channel: string, item_json: string): Promise<any>;
|
|
31
|
+
contentGetItem(id: string): Promise<any>;
|
|
32
|
+
/**
|
|
33
|
+
* `channel` is optional; `limit` caps results per page; `cursor` is
|
|
34
|
+
* the server-issued opaque pagination token. Mirror the TS wrapper
|
|
35
|
+
* signature: getLibrary(channel?, { limit?, cursor? }).
|
|
36
|
+
*/
|
|
37
|
+
contentGetLibrary(channel?: string | null, limit?: number | null, cursor?: string | null): Promise<any>;
|
|
38
|
+
/**
|
|
39
|
+
* `channel` is optional; when omitted, FFI defaults to `"default"` so
|
|
40
|
+
* single-channel apps can call `Amba.content.getToday()` without args.
|
|
41
|
+
*/
|
|
42
|
+
contentGetToday(channel?: string | null): Promise<any>;
|
|
43
|
+
contentUpdateItem(id: string, state_json: string): Promise<any>;
|
|
44
|
+
currenciesGetBalance(): Promise<any>;
|
|
45
|
+
currenciesGetTransactions(currency_key: string): Promise<any>;
|
|
46
|
+
deepLinksCreate(params_json: string): Promise<any>;
|
|
47
|
+
deepLinksGet(short_code: string): Promise<any>;
|
|
48
|
+
entitlementsHas(name: string): Promise<any>;
|
|
49
|
+
entitlementsList(): Promise<any>;
|
|
50
|
+
feedsGetActivity(feed?: string | null, cursor?: string | null): Promise<any>;
|
|
51
|
+
flagsFetch(): Promise<any>;
|
|
52
|
+
friendsBlockUser(user_id: string): Promise<any>;
|
|
53
|
+
friendsGetFriends(): Promise<any>;
|
|
54
|
+
friendsGetList(): Promise<any>;
|
|
55
|
+
friendsRemoveBlock(friendship_id: string): Promise<any>;
|
|
56
|
+
friendsUnblockUser(user_id: string): Promise<any>;
|
|
57
|
+
groupsCreate(params_json: string): Promise<any>;
|
|
58
|
+
groupsDelete(id: string): Promise<any>;
|
|
59
|
+
groupsGet(id: string): Promise<any>;
|
|
60
|
+
groupsGetMembers(id: string): Promise<any>;
|
|
61
|
+
groupsInvite(id: string, user_id: string): Promise<any>;
|
|
62
|
+
groupsJoin(id: string): Promise<any>;
|
|
63
|
+
groupsLeave(id: string): Promise<any>;
|
|
64
|
+
groupsUpdate(id: string, patch_json: string): Promise<any>;
|
|
65
|
+
/**
|
|
66
|
+
* Initialize the SDK.
|
|
67
|
+
*
|
|
68
|
+
* `config_json`: JSON-stringified `AmbaConfig` (api_key, base_url,
|
|
69
|
+
* sdk_platform, sdk_wrapper_version, consent_required, debug).
|
|
70
|
+
*
|
|
71
|
+
* `fetch_fn`: a JS function `(url, init) => Promise<Response>`
|
|
72
|
+
* matching the global `fetch` signature. The wrapper passes
|
|
73
|
+
* `window.fetch.bind(window)` or a server-side polyfill.
|
|
74
|
+
*/
|
|
75
|
+
static init(config_json: string, fetch_fn: Function): AmbaCoreWasm;
|
|
76
|
+
inventoryConsume(request_json: string): Promise<any>;
|
|
77
|
+
inventoryGetItem(id: string): Promise<any>;
|
|
78
|
+
inventoryGetItems(): Promise<any>;
|
|
79
|
+
inventoryPurchase(request_json: string): Promise<any>;
|
|
80
|
+
isAuthenticated(): boolean;
|
|
81
|
+
leaderboardsGet(key: string): Promise<any>;
|
|
82
|
+
leaderboardsGetEntries(key: string, limit?: number | null): Promise<any>;
|
|
83
|
+
leaderboardsGetMyRank(key: string): Promise<any>;
|
|
84
|
+
me(): Promise<any>;
|
|
85
|
+
messagingGetConversations(): Promise<any>;
|
|
86
|
+
messagingGetMessage(id: string): Promise<any>;
|
|
87
|
+
messagingSendMessage(request_json: string): Promise<any>;
|
|
88
|
+
moderationGetReportStatus(id: string): Promise<any>;
|
|
89
|
+
moderationReportContent(request_json: string): Promise<any>;
|
|
90
|
+
moderationReportUser(request_json: string): Promise<any>;
|
|
91
|
+
onboardingComplete(): Promise<any>;
|
|
92
|
+
onboardingGetStatus(): Promise<any>;
|
|
93
|
+
onboardingNextStep(payload_json: string): Promise<any>;
|
|
94
|
+
onboardingSkipStep(): Promise<any>;
|
|
95
|
+
pushGetTokens(): Promise<any>;
|
|
96
|
+
pushRegister(token: string, platform: string, bundle_id?: string | null): Promise<any>;
|
|
97
|
+
pushSubscribe(topic: string): Promise<any>;
|
|
98
|
+
pushUnregister(token: string): Promise<any>;
|
|
99
|
+
pushUnsubscribe(topic: string): Promise<any>;
|
|
100
|
+
referralsClaimReferral(code: string): Promise<any>;
|
|
101
|
+
referralsCreate(code?: string | null, max_uses?: number | null): Promise<any>;
|
|
102
|
+
referralsGetReferralCode(): Promise<any>;
|
|
103
|
+
refreshSession(): Promise<any>;
|
|
104
|
+
reviewsCreate(params_json: string): Promise<any>;
|
|
105
|
+
reviewsDelete(id: string): Promise<any>;
|
|
106
|
+
reviewsList(target_type: string, target_id: string): Promise<any>;
|
|
107
|
+
reviewsUpdate(id: string, patch_json: string): Promise<any>;
|
|
108
|
+
rolesGetMyRoles(): Promise<any>;
|
|
109
|
+
rolesHasPermission(permission: string): Promise<any>;
|
|
110
|
+
setDebug(enabled: boolean): void;
|
|
111
|
+
signInAnonymously(): Promise<any>;
|
|
112
|
+
signInWithEmail(email: string, password: string): Promise<any>;
|
|
113
|
+
signInWithSocial(provider: string, id_token: string): Promise<any>;
|
|
114
|
+
signOut(rotate_anonymous_id: boolean): Promise<any>;
|
|
115
|
+
signUpWithEmail(email: string, password: string): Promise<any>;
|
|
116
|
+
storageCommit(upload_id: string, asset_id: string): Promise<any>;
|
|
117
|
+
storagePresign(bucket: string, filename: string, mime_type: string, size_bytes: number, retention_days?: number | null): Promise<any>;
|
|
118
|
+
storesGetPurchaseOptions(store_key: string): Promise<any>;
|
|
119
|
+
storesList(): Promise<any>;
|
|
120
|
+
storesPurchase(store_key: string, purchase_option_id: string, receipt_json: string): Promise<any>;
|
|
121
|
+
streaksGetAll(): Promise<any>;
|
|
122
|
+
streaksQualify(streak_key: string): Promise<any>;
|
|
123
|
+
/**
|
|
124
|
+
* Track an event. Returns a Promise that resolves to undefined on success.
|
|
125
|
+
*/
|
|
126
|
+
track(event: string, properties_json?: string | null): Promise<any>;
|
|
127
|
+
xpClaim(grant_key: string): Promise<any>;
|
|
128
|
+
xpGetBalance(): Promise<any>;
|
|
129
|
+
xpGetHistory(limit?: number | null): Promise<any>;
|
|
130
|
+
}
|
|
131
|
+
|
|
132
|
+
export type InitInput = RequestInfo | URL | Response | BufferSource | WebAssembly.Module;
|
|
133
|
+
|
|
134
|
+
export interface InitOutput {
|
|
135
|
+
readonly memory: WebAssembly.Memory;
|
|
136
|
+
readonly __wbg_ambacorewasm_free: (a: number, b: number) => void;
|
|
137
|
+
readonly ambacorewasm_achievementsGetAll: (a: number) => number;
|
|
138
|
+
readonly ambacorewasm_achievementsGetProgress: (a: number) => number;
|
|
139
|
+
readonly ambacorewasm_aiAnthropicMessages: (a: number, b: number, c: number) => number;
|
|
140
|
+
readonly ambacorewasm_anonymousId: (a: number, b: number) => void;
|
|
141
|
+
readonly ambacorewasm_appUserId: (a: number, b: number) => void;
|
|
142
|
+
readonly ambacorewasm_catalogList: (a: number) => number;
|
|
143
|
+
readonly ambacorewasm_challengesClaim: (a: number, b: number, c: number) => number;
|
|
144
|
+
readonly ambacorewasm_challengesGet: (a: number, b: number, c: number) => number;
|
|
145
|
+
readonly ambacorewasm_challengesGetActive: (a: number) => number;
|
|
146
|
+
readonly ambacorewasm_challengesGetProgress: (a: number, b: number, c: number) => number;
|
|
147
|
+
readonly ambacorewasm_collectionsDelete: (a: number, b: number, c: number, d: number, e: number) => number;
|
|
148
|
+
readonly ambacorewasm_collectionsFind: (a: number, b: number, c: number, d: number, e: number) => number;
|
|
149
|
+
readonly ambacorewasm_collectionsFindOne: (a: number, b: number, c: number, d: number, e: number) => number;
|
|
150
|
+
readonly ambacorewasm_collectionsInsert: (a: number, b: number, c: number, d: number, e: number) => number;
|
|
151
|
+
readonly ambacorewasm_collectionsUpdate: (a: number, b: number, c: number, d: number, e: number, f: number, g: number) => number;
|
|
152
|
+
readonly ambacorewasm_configFetch: (a: number) => number;
|
|
153
|
+
readonly ambacorewasm_contentCreateItem: (a: number, b: number, c: number, d: number, e: number) => number;
|
|
154
|
+
readonly ambacorewasm_contentGetItem: (a: number, b: number, c: number) => number;
|
|
155
|
+
readonly ambacorewasm_contentGetLibrary: (a: number, b: number, c: number, d: number, e: number, f: number) => number;
|
|
156
|
+
readonly ambacorewasm_contentGetToday: (a: number, b: number, c: number) => number;
|
|
157
|
+
readonly ambacorewasm_contentUpdateItem: (a: number, b: number, c: number, d: number, e: number) => number;
|
|
158
|
+
readonly ambacorewasm_currenciesGetBalance: (a: number) => number;
|
|
159
|
+
readonly ambacorewasm_currenciesGetTransactions: (a: number, b: number, c: number) => number;
|
|
160
|
+
readonly ambacorewasm_deepLinksCreate: (a: number, b: number, c: number) => number;
|
|
161
|
+
readonly ambacorewasm_deepLinksGet: (a: number, b: number, c: number) => number;
|
|
162
|
+
readonly ambacorewasm_entitlementsHas: (a: number, b: number, c: number) => number;
|
|
163
|
+
readonly ambacorewasm_entitlementsList: (a: number) => number;
|
|
164
|
+
readonly ambacorewasm_feedsGetActivity: (a: number, b: number, c: number, d: number, e: number) => number;
|
|
165
|
+
readonly ambacorewasm_flagsFetch: (a: number) => number;
|
|
166
|
+
readonly ambacorewasm_friendsBlockUser: (a: number, b: number, c: number) => number;
|
|
167
|
+
readonly ambacorewasm_friendsGetFriends: (a: number) => number;
|
|
168
|
+
readonly ambacorewasm_friendsGetList: (a: number) => number;
|
|
169
|
+
readonly ambacorewasm_friendsRemoveBlock: (a: number, b: number, c: number) => number;
|
|
170
|
+
readonly ambacorewasm_friendsUnblockUser: (a: number, b: number, c: number) => number;
|
|
171
|
+
readonly ambacorewasm_groupsCreate: (a: number, b: number, c: number) => number;
|
|
172
|
+
readonly ambacorewasm_groupsDelete: (a: number, b: number, c: number) => number;
|
|
173
|
+
readonly ambacorewasm_groupsGet: (a: number, b: number, c: number) => number;
|
|
174
|
+
readonly ambacorewasm_groupsGetMembers: (a: number, b: number, c: number) => number;
|
|
175
|
+
readonly ambacorewasm_groupsInvite: (a: number, b: number, c: number, d: number, e: number) => number;
|
|
176
|
+
readonly ambacorewasm_groupsJoin: (a: number, b: number, c: number) => number;
|
|
177
|
+
readonly ambacorewasm_groupsLeave: (a: number, b: number, c: number) => number;
|
|
178
|
+
readonly ambacorewasm_groupsUpdate: (a: number, b: number, c: number, d: number, e: number) => number;
|
|
179
|
+
readonly ambacorewasm_init: (a: number, b: number, c: number, d: number) => void;
|
|
180
|
+
readonly ambacorewasm_inventoryConsume: (a: number, b: number, c: number) => number;
|
|
181
|
+
readonly ambacorewasm_inventoryGetItem: (a: number, b: number, c: number) => number;
|
|
182
|
+
readonly ambacorewasm_inventoryGetItems: (a: number) => number;
|
|
183
|
+
readonly ambacorewasm_inventoryPurchase: (a: number, b: number, c: number) => number;
|
|
184
|
+
readonly ambacorewasm_isAuthenticated: (a: number) => number;
|
|
185
|
+
readonly ambacorewasm_leaderboardsGet: (a: number, b: number, c: number) => number;
|
|
186
|
+
readonly ambacorewasm_leaderboardsGetEntries: (a: number, b: number, c: number, d: number) => number;
|
|
187
|
+
readonly ambacorewasm_leaderboardsGetMyRank: (a: number, b: number, c: number) => number;
|
|
188
|
+
readonly ambacorewasm_me: (a: number) => number;
|
|
189
|
+
readonly ambacorewasm_messagingGetConversations: (a: number) => number;
|
|
190
|
+
readonly ambacorewasm_messagingGetMessage: (a: number, b: number, c: number) => number;
|
|
191
|
+
readonly ambacorewasm_messagingSendMessage: (a: number, b: number, c: number) => number;
|
|
192
|
+
readonly ambacorewasm_moderationGetReportStatus: (a: number, b: number, c: number) => number;
|
|
193
|
+
readonly ambacorewasm_moderationReportContent: (a: number, b: number, c: number) => number;
|
|
194
|
+
readonly ambacorewasm_moderationReportUser: (a: number, b: number, c: number) => number;
|
|
195
|
+
readonly ambacorewasm_onboardingComplete: (a: number) => number;
|
|
196
|
+
readonly ambacorewasm_onboardingGetStatus: (a: number) => number;
|
|
197
|
+
readonly ambacorewasm_onboardingNextStep: (a: number, b: number, c: number) => number;
|
|
198
|
+
readonly ambacorewasm_onboardingSkipStep: (a: number) => number;
|
|
199
|
+
readonly ambacorewasm_pushGetTokens: (a: number) => number;
|
|
200
|
+
readonly ambacorewasm_pushRegister: (a: number, b: number, c: number, d: number, e: number, f: number, g: number) => number;
|
|
201
|
+
readonly ambacorewasm_pushSubscribe: (a: number, b: number, c: number) => number;
|
|
202
|
+
readonly ambacorewasm_pushUnregister: (a: number, b: number, c: number) => number;
|
|
203
|
+
readonly ambacorewasm_pushUnsubscribe: (a: number, b: number, c: number) => number;
|
|
204
|
+
readonly ambacorewasm_referralsClaimReferral: (a: number, b: number, c: number) => number;
|
|
205
|
+
readonly ambacorewasm_referralsCreate: (a: number, b: number, c: number, d: number) => number;
|
|
206
|
+
readonly ambacorewasm_referralsGetReferralCode: (a: number) => number;
|
|
207
|
+
readonly ambacorewasm_refreshSession: (a: number) => number;
|
|
208
|
+
readonly ambacorewasm_reviewsCreate: (a: number, b: number, c: number) => number;
|
|
209
|
+
readonly ambacorewasm_reviewsDelete: (a: number, b: number, c: number) => number;
|
|
210
|
+
readonly ambacorewasm_reviewsList: (a: number, b: number, c: number, d: number, e: number) => number;
|
|
211
|
+
readonly ambacorewasm_reviewsUpdate: (a: number, b: number, c: number, d: number, e: number) => number;
|
|
212
|
+
readonly ambacorewasm_rolesGetMyRoles: (a: number) => number;
|
|
213
|
+
readonly ambacorewasm_rolesHasPermission: (a: number, b: number, c: number) => number;
|
|
214
|
+
readonly ambacorewasm_setDebug: (a: number, b: number) => void;
|
|
215
|
+
readonly ambacorewasm_signInAnonymously: (a: number) => number;
|
|
216
|
+
readonly ambacorewasm_signInWithEmail: (a: number, b: number, c: number, d: number, e: number) => number;
|
|
217
|
+
readonly ambacorewasm_signInWithSocial: (a: number, b: number, c: number, d: number, e: number) => number;
|
|
218
|
+
readonly ambacorewasm_signOut: (a: number, b: number) => number;
|
|
219
|
+
readonly ambacorewasm_signUpWithEmail: (a: number, b: number, c: number, d: number, e: number) => number;
|
|
220
|
+
readonly ambacorewasm_storageCommit: (a: number, b: number, c: number, d: number, e: number) => number;
|
|
221
|
+
readonly ambacorewasm_storagePresign: (a: number, b: number, c: number, d: number, e: number, f: number, g: number, h: number, i: number) => number;
|
|
222
|
+
readonly ambacorewasm_storesGetPurchaseOptions: (a: number, b: number, c: number) => number;
|
|
223
|
+
readonly ambacorewasm_storesList: (a: number) => number;
|
|
224
|
+
readonly ambacorewasm_storesPurchase: (a: number, b: number, c: number, d: number, e: number, f: number, g: number) => number;
|
|
225
|
+
readonly ambacorewasm_streaksGetAll: (a: number) => number;
|
|
226
|
+
readonly ambacorewasm_streaksQualify: (a: number, b: number, c: number) => number;
|
|
227
|
+
readonly ambacorewasm_track: (a: number, b: number, c: number, d: number, e: number) => number;
|
|
228
|
+
readonly ambacorewasm_xpClaim: (a: number, b: number, c: number) => number;
|
|
229
|
+
readonly ambacorewasm_xpGetBalance: (a: number) => number;
|
|
230
|
+
readonly ambacorewasm_xpGetHistory: (a: number, b: number) => number;
|
|
231
|
+
readonly __wasm_bindgen_func_elem_2351: (a: number, b: number, c: number, d: number) => void;
|
|
232
|
+
readonly __wasm_bindgen_func_elem_2347: (a: number, b: number, c: number, d: number) => void;
|
|
233
|
+
readonly __wasm_bindgen_func_elem_2351_96: (a: number, b: number, c: number, d: number) => void;
|
|
234
|
+
readonly __wbindgen_export: (a: number, b: number) => number;
|
|
235
|
+
readonly __wbindgen_export2: (a: number, b: number, c: number, d: number) => number;
|
|
236
|
+
readonly __wbindgen_export3: (a: number) => void;
|
|
237
|
+
readonly __wbindgen_export4: (a: number, b: number) => void;
|
|
238
|
+
readonly __wbindgen_add_to_stack_pointer: (a: number) => number;
|
|
239
|
+
readonly __wbindgen_export5: (a: number, b: number, c: number) => void;
|
|
240
|
+
}
|
|
241
|
+
|
|
242
|
+
export type SyncInitInput = BufferSource | WebAssembly.Module;
|
|
243
|
+
|
|
244
|
+
/**
|
|
245
|
+
* Instantiates the given `module`, which can either be bytes or
|
|
246
|
+
* a precompiled `WebAssembly.Module`.
|
|
247
|
+
*
|
|
248
|
+
* @param {{ module: SyncInitInput }} module - Passing `SyncInitInput` directly is deprecated.
|
|
249
|
+
*
|
|
250
|
+
* @returns {InitOutput}
|
|
251
|
+
*/
|
|
252
|
+
export function initSync(module: { module: SyncInitInput } | SyncInitInput): InitOutput;
|
|
253
|
+
|
|
254
|
+
/**
|
|
255
|
+
* If `module_or_path` is {RequestInfo} or {URL}, makes a request and
|
|
256
|
+
* for everything else, calls `WebAssembly.instantiate` directly.
|
|
257
|
+
*
|
|
258
|
+
* @param {{ module_or_path: InitInput | Promise<InitInput> }} module_or_path - Passing `InitInput` directly is deprecated.
|
|
259
|
+
*
|
|
260
|
+
* @returns {Promise<InitOutput>}
|
|
261
|
+
*/
|
|
262
|
+
export default function __wbg_init (module_or_path?: { module_or_path: InitInput | Promise<InitInput> } | InitInput | Promise<InitInput>): Promise<InitOutput>;
|