@markee_team/sdk 0.1.0-alpha.21 → 0.1.0-alpha.23
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 +17 -0
- package/dist/client.d.ts +2 -1
- package/dist/index.js +3 -3
- package/dist/modal.d.ts +8 -0
- package/dist/react.js +3 -3
- package/dist/types.d.ts +18 -0
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -325,3 +325,20 @@ feature with the server-only `FLAG_SDK_PAY_IN_MARKEE` environment variable, whic
|
|
|
325
325
|
defaults to false. Only `true`, together with the required checkout configuration,
|
|
326
326
|
enables it. Integrating apps do not need to provide a flag or API key. Connected
|
|
327
327
|
wallet payments remain available independently.
|
|
328
|
+
|
|
329
|
+
### Automatic message moderation
|
|
330
|
+
|
|
331
|
+
When enabled by Markee, create/edit forms warn if a message matches the automatic profanity
|
|
332
|
+
filter. Authors can edit or explicitly continue; publication may still be hidden. A passing
|
|
333
|
+
message edit clears an automatic flag, while manual flags require moderator action.
|
|
334
|
+
|
|
335
|
+
`await client.checkMessage(message)` exposes the same draft check for custom interfaces. It
|
|
336
|
+
returns `enabled`, `state`, `contentHash`, `engine`, `policyVersion`, and optional `reason`.
|
|
337
|
+
Treat `unavailable` as unknown, never as a pass. Names are not automatically checked.
|
|
338
|
+
The standard modal handles these warnings for React and vanilla JavaScript integrations.
|
|
339
|
+
No API key or moderation configuration is required in the host app.
|
|
340
|
+
|
|
341
|
+
Snapshots retain `entry.moderated` (`false`, `true`, or `null`) and can additionally include
|
|
342
|
+
`entry.moderation` with the state and reason. Hide unavailable and flagged content and do not
|
|
343
|
+
record views for it. A moderator's false-positive exception on Markee applies only on Markee;
|
|
344
|
+
it does not change SDK visibility. This optional backend feature is disabled by default.
|
package/dist/client.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { Action, Address, AdminOperation, AdminResult, Authorization, BridgeStatus, ClaimQuote, EIP1193Provider, Hex, Placement, PreparedAction, SDKOptions, Snapshot, SiteVerification, TransactionResult } from './types.js';
|
|
1
|
+
import type { MessageCheck, Action, Address, AdminOperation, AdminResult, Authorization, BridgeStatus, ClaimQuote, EIP1193Provider, Hex, Placement, PreparedAction, SDKOptions, Snapshot, SiteVerification, TransactionResult } from './types.js';
|
|
2
2
|
/** Markee-hosted API used by integrations unless overridden for local development. */
|
|
3
3
|
export declare const DEFAULT_MARKEE_API_URL = "https://staging.markee.xyz/api/sdk/v1";
|
|
4
4
|
export declare class MarkeeError extends Error {
|
|
@@ -67,6 +67,7 @@ export declare class MarkeeClient {
|
|
|
67
67
|
kind: 'gardens-community';
|
|
68
68
|
}>): AdminResult | null;
|
|
69
69
|
bridgeStatus(protocol: ClaimQuote['bridgeProtocol'], hash: Hex, fromChainId: number, toChainId: number): Promise<BridgeStatus>;
|
|
70
|
+
checkMessage(message: string): Promise<MessageCheck>;
|
|
70
71
|
recordView(address: Address, message: string, url?: string): Promise<{
|
|
71
72
|
counted: boolean;
|
|
72
73
|
totalViews: number;
|