Index of every page on this site: llms.txt
All skills
scopuly avatar

/scopuly-wallet

@e7fa94e
Run it yourself

Integrate or troubleshoot the Scopuly Stellar wallet in a browser dApp using its Provider API or Stellar Wallets Kit. Use for wallet connection, transaction signing, SEP-53 messages, Soroban authorization signatures, and account or network changes on Scopuly Mobile and the paired browser extension.

  • 6 files
  • 26 KB
  • Updated 2 months ago
  • GitHub
Use this Skill: https://skilld.dev/gh/scopuly/scopuly-skills/scopuly-wallet

Nothing lands on disk. Nothing to clean up.

Fork this Skill

Edit a local copy. It keeps the author and licence.

SKILL.md

≈79 tokens for metadata: the name and description. ≈1.4k when used: this file. ≈2.9k more on demand in 3 files.

Description uses 4.0% of example budget

Before choosing a Skill, your Agent reads its name and description. All available Skills share that space.

  • A shorter description leaves more room for other Skills. This entry exceeds our 1% size suggestion.

In our Claude Code example, all Skill names and descriptions share 8,000 characters. This Skill uses ≈316 characters, or 4.0%.

The 1% threshold is a size suggestion. Longer descriptions can still fit.

Your model, settings, and other Skills decide how much text your Agent can read.

Example settings and source

The example uses a 200k-token context and default Claude Code settings. The count includes the name, description, separators, and when_to_use when present. Codex also counts local file paths.

Skit's source and limits: Codex 0.160.1, Claude Code 2.1.292.

Scopuly Wallet Integration

Build against the public Scopuly provider. Keep the application's existing framework and wallet-selection flow. If it already uses Stellar Wallets Kit, use that integration rather than adding a second connection manager.

Choose the integration

Existing application Use
Scopuly-specific connection or direct provider integration @scopuly/signer-extension-api@0.3.3; provider lifecycle
Stellar Wallets Kit The built-in Scopuly module; SWK 2.7 integration
Soroban authorization or message verification Signing formats and boundaries

The provider is injected as window.scopuly in Scopuly Mobile's dApp browser and by the paired browser extension. The npm API is a typed wrapper; installing it does not inject a wallet. An ordinary mobile browser does not automatically have a provider.

Use browser-only initialization in SSR applications. Check isScopuly === true and platform === "mobile" || platform === "extension". If injection is delayed, listen for scopuly#initialized, use a bounded wait and remove the listener. Do not overwrite another wallet's window.stellar.provider.

Implement the flow

  1. Detect availability without prompting. Call requestAccess() from the user's Connect action. Access is scoped to the dApp origin.
  2. Read the selected address and networkPassphrase. Compare the wallet's network with the application's intended network. getNetwork() reports state; it does not switch the wallet.
  3. Subscribe to onChange(). Invalidate cached account, network, prepared XDR and pending results when the connection changes. Unsubscribe on disposal.
  4. Build or simulate the operation for the intended network. Immediately before signing, confirm the account and network still match. Pass both address and networkPassphrase explicitly.
  5. Handle rejected promises and resolved { error } results. Check required result fields before reporting success. Error -4 means user rejection; do not retry it automatically.
  6. Verify the returned signer and signature where the application consumes the signed result. Treat a signed transaction, a submitted transaction and confirmed settlement as separate states.

The tested wallet helper implements connection invalidation, result checks, duplicate-request protection, SEP-53 verification and signed-XDR verification. It uses @scopuly/signer-extension-api@0.3.3, @stellar/stellar-sdk@17.0.0 and buffer@6.0.3. Copy it only if it fits the application; do not replace an existing wallet architecture unnecessarily.

Signing contract

Method Input Result
signTransaction Base64 transaction-envelope XDR signedTxXdr; use submit: false for sign-only flows
signAndSubmitTransaction Base64 transaction-envelope XDR status, optional hash and signed XDR; pending is not settlement
signMessage UTF-8 string signedMessage: 64-byte Ed25519 signature encoded as hex
signAuthEntry Base64 HashIdPreimage XDR for Soroban authorization signedAuthEntry: raw 64-byte Ed25519 signature encoded as base64

Despite its name, signAuthEntry does not take a full SorobanAuthorizationEntry or return a signed XDR entry. Do not interchange its base64 signature with the hex message signature. Read signing.md before implementing these paths.

Scopuly signs through its approval UI. Do not request a secret key or seed phrase, invent a server signing endpoint, or add unattended signing. Signing options do not include derivation paths, custom submission URLs, or an API to switch networks. A provider-based integration does not need a WalletConnect/Reown project ID.

For sign-only transactions, return the verified XDR to the caller. Submit only when the requested application flow includes submission. After a timeout, reconcile the original transaction hash before offering another payment; a timeout is not evidence of failure.

reportX402Receipt attaches a verified receipt to wallet activity; it does not make a payment. This skill covers the wallet signing boundary, not an x402 merchant implementation, MPP sessions, autonomous agents or spending policies. Use the Stellar payment skill for protocol-specific work.

Verify the integration

Exercise: missing provider, delayed injection, explicit connection, approved and rejected signing, account/network change during a request, malformed output, and listener cleanup. Verify layouts on mobile and desktop. Use Testnet for transaction examples; never substitute Mainnet when Testnet is unavailable.

The repository's connect-and-sign example and device checklist provide reproducible checks. Report simulated-provider tests separately from real-device results.

Sources and compatibility

Checked against the published Provider API 0.3.3 and SWK 2.7.0, 2026-09-30. Pin versions in runnable examples; check newer releases before updating guidance.

Source: SKILL.md on GitHub

skilld matched fixed text patterns in SKILL.md and file names. Patterns miss obfuscated code.

skilld run checks every file with the same patterns. It asks for approval before it loads a Skill with a behavior marked Needs approval.

No third-party reports yet.

Signed by skilld at e7fa94e. This ties the file your Agent reads to that commit on GitHub. It does not review the instructions.

Last checked against GitHub last month.

Steadyupdated 2 months ago
metadata
{
  "author": "Scopuly",
  "version": "0.1.0"
}

README badge

README badge for scopuly/scopuly-skills