@markee_team/sdk 0.1.0-alpha.2 → 0.1.0-alpha.4
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 +57 -37
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -2,12 +2,12 @@
|
|
|
2
2
|
|
|
3
3
|
An ESM JavaScript SDK with a self-contained, Shadow DOM modal and an optional React entry point. The SDK knows the Markee API endpoint; the host only supplies its placement and, optionally, its current wallet provider. No Alchemy, Redis, Privy, or bridge-provider key belongs in the consuming app.
|
|
4
4
|
|
|
5
|
-
This is an experimental `0.1.0-alpha.
|
|
5
|
+
This is an experimental `0.1.0-alpha.4` release for wallet-funded For Sale and For Rent flows. Hosted card checkout and incoming cross-chain funding are not included.
|
|
6
6
|
|
|
7
7
|
Install the alpha:
|
|
8
8
|
|
|
9
9
|
```sh
|
|
10
|
-
npm install @markee_team/sdk@
|
|
10
|
+
npm install @markee_team/sdk@latest
|
|
11
11
|
```
|
|
12
12
|
|
|
13
13
|
Use React 18 or 19 for the optional React entry point. The plain JavaScript entry point does not require React. Both TypeScript bundler and NodeNext resolution are supported.
|
|
@@ -143,41 +143,61 @@ No API URL configuration is required. This alpha uses the Markee staging API at
|
|
|
143
143
|
|
|
144
144
|
## LLM implementation prompt
|
|
145
145
|
|
|
146
|
-
Copy this prompt into your coding assistant.
|
|
146
|
+
Copy this prompt into your coding assistant. It gathers missing requirements before implementing the integration.
|
|
147
147
|
|
|
148
148
|
```text
|
|
149
|
-
Integrate @markee_team/sdk@
|
|
150
|
-
follow its existing framework, styling, and wallet patterns.
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
149
|
+
Integrate @markee_team/sdk@latest into this app. Inspect the codebase first and
|
|
150
|
+
follow its existing framework, styling, and wallet patterns. Read the installed
|
|
151
|
+
package README and types for current capabilities.
|
|
152
|
+
|
|
153
|
+
Before implementing, ask me to create my leaderboard on Markee at
|
|
154
|
+
https://www.markee.xyz/create-a-markee, then provide its resulting Markee page link.
|
|
155
|
+
If I already have a leaderboard, ask for that link instead; do not create a duplicate.
|
|
156
|
+
Example link format:
|
|
157
|
+
https://www.markee.xyz/markee/0x6ceBC87DE40519Fa52fc40a1d49f16FF968bb439
|
|
158
|
+
Never silently substitute a demo board. Wait for my link before wiring the placement.
|
|
159
|
+
|
|
160
|
+
Extract the board address from the /markee/<address> path. Validate the Markee URL
|
|
161
|
+
and the address (0x followed by 40 hexadecimal characters). Markee website boards
|
|
162
|
+
currently use Base, chain ID 8453. Verify the board through the SDK snapshot API;
|
|
163
|
+
if verification fails, explain the error and ask for a corrected link.
|
|
164
|
+
|
|
165
|
+
Do not ask me to choose For Sale or For Rent in the host app. That choice is made
|
|
166
|
+
when creating the leaderboard on Markee. The API returns strategy and the SDK
|
|
167
|
+
adapts the modal automatically. Do not add a strategy prop, toggle, or hardcoded mode.
|
|
168
|
+
|
|
169
|
+
Ask only the remaining unanswered requirements in one concise group:
|
|
170
|
+
- Where should Markee appear, what opens the modal, and what should the button say?
|
|
171
|
+
- Should it reuse the app's existing wallet or use SDK wallet discovery? Inspect
|
|
172
|
+
existing connectors first; do not add a second wallet context or install a new
|
|
173
|
+
connector without agreement.
|
|
174
|
+
- Should the modal match the app theme or use specific colors, font, radius, and
|
|
175
|
+
light/dark/system mode?
|
|
176
|
+
- What should happen after a confirmed transaction: notification, refresh,
|
|
177
|
+
navigation, or callback? Are there additional mobile/accessibility requirements?
|
|
178
|
+
|
|
179
|
+
Then implement the agreed scope:
|
|
180
|
+
1. Install @markee_team/sdk@latest. No API URL or Markee API key is required.
|
|
181
|
+
Do not create an API proxy or add RPC/database credentials.
|
|
182
|
+
2. Use placement = { kind: 'board', chainId: 8453, address: extractedAddress }.
|
|
183
|
+
Use new MarkeeClient().snapshot(placement) to verify the board and read strategy,
|
|
184
|
+
name, minimum, and other metadata. The modal performs its own snapshot loading;
|
|
185
|
+
do not recreate that loading or strategy logic in the host app.
|
|
186
|
+
3. For React, use MarkeeModal from @markee_team/sdk/react in a client component
|
|
187
|
+
with open, onClose, and placement. Otherwise use createMarkee() from
|
|
188
|
+
@markee_team/sdk, then open({ placement }); close it on teardown.
|
|
189
|
+
4. If a host wallet exists, pass its selected EIP-1193 provider through the wallet
|
|
190
|
+
adapter. For ConnectKit/wagmi use the active connector. Resolve connect after
|
|
191
|
+
selection, reject cancellation, and do not silently switch wallet providers.
|
|
192
|
+
Otherwise omit wallet and use SDK wallet discovery.
|
|
193
|
+
5. Apply theme options while preserving the built-in modal layout. Handle onEvent
|
|
194
|
+
if needed; show success only for a confirmed event. Let the SDK manage review,
|
|
195
|
+
network switching, submission, and verification.
|
|
196
|
+
6. Verify build/types, loading of the supplied board, automatic strategy selection,
|
|
197
|
+
open/close behavior, theme, and wallet reuse. Do not sign or send transactions
|
|
198
|
+
during automated verification. Report changed files, checks, and limitations.
|
|
199
|
+
|
|
200
|
+
Check the installed release's limitations before promising features. This release
|
|
201
|
+
uses Markee's staging backend and supports wallet-funded flows; card checkout and
|
|
202
|
+
incoming bridging are not yet available. Transactions use real funds.
|
|
183
203
|
```
|