@farcaster/frame-core 0.2.0 → 0.3.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/dist/index.d.ts +153 -10
- package/dist/index.js +18 -33
- package/esm/index.d.ts +153 -10
- package/esm/index.js +17 -10
- package/esm/tsconfig.tsbuildinfo +1 -1
- package/package.json +6 -8
- package/src/index.ts +50 -10
- package/dist/actions/AddMiniApp.d.ts +0 -36
- package/dist/actions/AddMiniApp.js +0 -57
- package/dist/actions/ComposeCast.d.ts +0 -37
- package/dist/actions/ComposeCast.js +0 -2
- package/dist/actions/Haptics.d.ts +0 -5
- package/dist/actions/Haptics.js +0 -2
- package/dist/actions/Ready.d.ts +0 -13
- package/dist/actions/Ready.js +0 -6
- package/dist/actions/SendToken.d.ts +0 -48
- package/dist/actions/SendToken.js +0 -2
- package/dist/actions/SignIn.d.ts +0 -55
- package/dist/actions/SignIn.js +0 -47
- package/dist/actions/SwapToken.d.ts +0 -46
- package/dist/actions/SwapToken.js +0 -2
- package/dist/actions/ViewCast.d.ts +0 -25
- package/dist/actions/ViewCast.js +0 -2
- package/dist/actions/ViewProfile.d.ts +0 -4
- package/dist/actions/ViewProfile.js +0 -2
- package/dist/actions/ViewToken.d.ts +0 -4
- package/dist/actions/ViewToken.js +0 -2
- package/dist/actions/index.d.ts +0 -10
- package/dist/actions/index.js +0 -46
- package/dist/back.d.ts +0 -13
- package/dist/back.js +0 -6
- package/dist/context.d.ts +0 -94
- package/dist/context.js +0 -2
- package/dist/errors.d.ts +0 -13
- package/dist/errors.js +0 -12
- package/dist/internal/types.d.ts +0 -8
- package/dist/internal/types.js +0 -2
- package/dist/manifest.d.ts +0 -107
- package/dist/manifest.js +0 -2
- package/dist/schemas/embeds.d.ts +0 -243
- package/dist/schemas/embeds.js +0 -32
- package/dist/schemas/events.d.ts +0 -131
- package/dist/schemas/events.js +0 -25
- package/dist/schemas/index.d.ts +0 -5
- package/dist/schemas/index.js +0 -21
- package/dist/schemas/manifest.d.ts +0 -348
- package/dist/schemas/manifest.js +0 -114
- package/dist/schemas/notifications.d.ts +0 -60
- package/dist/schemas/notifications.js +0 -23
- package/dist/schemas/shared.d.ts +0 -40
- package/dist/schemas/shared.js +0 -83
- package/dist/solana.d.ts +0 -72
- package/dist/solana.js +0 -15
- package/dist/solanaWire.d.ts +0 -3
- package/dist/solanaWire.js +0 -84
- package/dist/types.d.ts +0 -87
- package/dist/types.js +0 -41
- package/dist/wallet/ethereum.d.ts +0 -47
- package/dist/wallet/ethereum.js +0 -2
- package/dist/wallet/index.d.ts +0 -1
- package/dist/wallet/index.js +0 -37
- package/esm/actions/AddMiniApp.d.ts +0 -36
- package/esm/actions/AddMiniApp.js +0 -19
- package/esm/actions/ComposeCast.d.ts +0 -37
- package/esm/actions/ComposeCast.js +0 -1
- package/esm/actions/Haptics.d.ts +0 -5
- package/esm/actions/Haptics.js +0 -1
- package/esm/actions/Ready.d.ts +0 -13
- package/esm/actions/Ready.js +0 -3
- package/esm/actions/SendToken.d.ts +0 -48
- package/esm/actions/SendToken.js +0 -1
- package/esm/actions/SignIn.d.ts +0 -55
- package/esm/actions/SignIn.js +0 -10
- package/esm/actions/SwapToken.d.ts +0 -46
- package/esm/actions/SwapToken.js +0 -1
- package/esm/actions/ViewCast.d.ts +0 -25
- package/esm/actions/ViewCast.js +0 -1
- package/esm/actions/ViewProfile.d.ts +0 -4
- package/esm/actions/ViewProfile.js +0 -1
- package/esm/actions/ViewToken.d.ts +0 -4
- package/esm/actions/ViewToken.js +0 -1
- package/esm/actions/index.d.ts +0 -10
- package/esm/actions/index.js +0 -10
- package/esm/back.d.ts +0 -13
- package/esm/back.js +0 -3
- package/esm/context.d.ts +0 -94
- package/esm/context.js +0 -1
- package/esm/errors.d.ts +0 -13
- package/esm/errors.js +0 -8
- package/esm/internal/types.d.ts +0 -8
- package/esm/internal/types.js +0 -1
- package/esm/manifest.d.ts +0 -107
- package/esm/manifest.js +0 -1
- package/esm/schemas/embeds.d.ts +0 -243
- package/esm/schemas/embeds.js +0 -28
- package/esm/schemas/events.d.ts +0 -131
- package/esm/schemas/events.js +0 -22
- package/esm/schemas/index.d.ts +0 -5
- package/esm/schemas/index.js +0 -5
- package/esm/schemas/manifest.d.ts +0 -348
- package/esm/schemas/manifest.js +0 -111
- package/esm/schemas/notifications.d.ts +0 -60
- package/esm/schemas/notifications.js +0 -20
- package/esm/schemas/shared.d.ts +0 -40
- package/esm/schemas/shared.js +0 -79
- package/esm/solana.d.ts +0 -72
- package/esm/solana.js +0 -11
- package/esm/solanaWire.d.ts +0 -3
- package/esm/solanaWire.js +0 -80
- package/esm/types.d.ts +0 -87
- package/esm/types.js +0 -23
- package/esm/wallet/ethereum.d.ts +0 -47
- package/esm/wallet/ethereum.js +0 -1
- package/esm/wallet/index.d.ts +0 -1
- package/esm/wallet/index.js +0 -1
- package/src/actions/AddMiniApp.ts +0 -51
- package/src/actions/ComposeCast.ts +0 -44
- package/src/actions/Haptics.ts +0 -9
- package/src/actions/Ready.ts +0 -15
- package/src/actions/SendToken.ts +0 -57
- package/src/actions/SignIn.ts +0 -67
- package/src/actions/SwapToken.ts +0 -54
- package/src/actions/ViewCast.ts +0 -27
- package/src/actions/ViewProfile.ts +0 -5
- package/src/actions/ViewToken.ts +0 -5
- package/src/actions/index.ts +0 -10
- package/src/back.ts +0 -15
- package/src/context.ts +0 -117
- package/src/errors.ts +0 -21
- package/src/internal/types.ts +0 -20
- package/src/manifest.ts +0 -120
- package/src/schemas/embeds.ts +0 -44
- package/src/schemas/events.ts +0 -41
- package/src/schemas/index.ts +0 -5
- package/src/schemas/manifest.ts +0 -125
- package/src/schemas/notifications.ts +0 -33
- package/src/schemas/shared.ts +0 -109
- package/src/solana.ts +0 -108
- package/src/solanaWire.ts +0 -120
- package/src/types.ts +0 -155
- package/src/wallet/ethereum.ts +0 -65
- package/src/wallet/index.ts +0 -1
|
@@ -1,348 +0,0 @@
|
|
|
1
|
-
import { z } from 'zod';
|
|
2
|
-
export declare const domainFrameConfigSchema: z.ZodEffects<z.ZodObject<{
|
|
3
|
-
version: z.ZodUnion<[z.ZodLiteral<"0.0.0">, z.ZodLiteral<"0.0.1">, z.ZodLiteral<"1">, z.ZodLiteral<"next">]>;
|
|
4
|
-
name: z.ZodString;
|
|
5
|
-
iconUrl: z.ZodString;
|
|
6
|
-
homeUrl: z.ZodString;
|
|
7
|
-
/** deprecated, set ogImageUrl instead */
|
|
8
|
-
imageUrl: z.ZodOptional<z.ZodString>;
|
|
9
|
-
/** deprecated, will rely on fc:frame meta tag */
|
|
10
|
-
buttonTitle: z.ZodOptional<z.ZodString>;
|
|
11
|
-
splashImageUrl: z.ZodOptional<z.ZodString>;
|
|
12
|
-
splashBackgroundColor: z.ZodOptional<z.ZodString>;
|
|
13
|
-
webhookUrl: z.ZodOptional<z.ZodString>;
|
|
14
|
-
/** see: https://github.com/farcasterxyz/miniapps/discussions/191 */
|
|
15
|
-
subtitle: z.ZodOptional<z.ZodEffects<z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>, string, string>>;
|
|
16
|
-
description: z.ZodOptional<z.ZodEffects<z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>, string, string>>;
|
|
17
|
-
screenshotUrls: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
18
|
-
primaryCategory: z.ZodOptional<z.ZodEnum<["games", "social", "finance", "utility", "productivity", "health-fitness", "news-media", "music", "shopping", "education", "developer-tools", "entertainment", "art-creativity"]>>;
|
|
19
|
-
tags: z.ZodOptional<z.ZodArray<z.ZodEffects<z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>, string, string>, "many">>;
|
|
20
|
-
heroImageUrl: z.ZodOptional<z.ZodString>;
|
|
21
|
-
tagline: z.ZodOptional<z.ZodEffects<z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>, string, string>>;
|
|
22
|
-
ogTitle: z.ZodOptional<z.ZodEffects<z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>, string, string>>;
|
|
23
|
-
ogDescription: z.ZodOptional<z.ZodEffects<z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>, string, string>>;
|
|
24
|
-
ogImageUrl: z.ZodOptional<z.ZodString>;
|
|
25
|
-
/** see: https://github.com/farcasterxyz/miniapps/discussions/204 */
|
|
26
|
-
noindex: z.ZodOptional<z.ZodBoolean>;
|
|
27
|
-
/** see https://github.com/farcasterxyz/miniapps/discussions/256 */
|
|
28
|
-
requiredChains: z.ZodOptional<z.ZodEffects<z.ZodArray<z.ZodEnum<["eip155:1", "eip155:8453", "eip155:42161", "eip155:421614", "eip155:84532", "eip155:666666666", "eip155:100", "eip155:10", "eip155:11155420", "eip155:137", "eip155:11155111", "eip155:7777777", "eip155:130", "eip155:10143", "eip155:42220", "solana:5eykt4UsFv8P8NJdTREpY1vzqKqZKvdp"]>, "many">, ("eip155:1" | "eip155:8453" | "eip155:42161" | "eip155:421614" | "eip155:84532" | "eip155:666666666" | "eip155:100" | "eip155:10" | "eip155:11155420" | "eip155:137" | "eip155:11155111" | "eip155:7777777" | "eip155:130" | "eip155:10143" | "eip155:42220" | "solana:5eykt4UsFv8P8NJdTREpY1vzqKqZKvdp")[], ("eip155:1" | "eip155:8453" | "eip155:42161" | "eip155:421614" | "eip155:84532" | "eip155:666666666" | "eip155:100" | "eip155:10" | "eip155:11155420" | "eip155:137" | "eip155:11155111" | "eip155:7777777" | "eip155:130" | "eip155:10143" | "eip155:42220" | "solana:5eykt4UsFv8P8NJdTREpY1vzqKqZKvdp")[]>>;
|
|
29
|
-
requiredCapabilities: z.ZodOptional<z.ZodEffects<z.ZodArray<z.ZodEnum<["wallet.getEthereumProvider", "wallet.getSolanaProvider", "actions.ready", "actions.openUrl", "actions.close", "actions.setPrimaryButton", "actions.addMiniApp", "actions.signIn", "actions.viewCast", "actions.viewProfile", "actions.composeCast", "actions.viewToken", "actions.sendToken", "actions.swapToken", "haptics.impactOccurred", "haptics.notificationOccurred", "haptics.selectionChanged", "back"]>, "many">, ("wallet.getEthereumProvider" | "wallet.getSolanaProvider" | "actions.ready" | "actions.openUrl" | "actions.close" | "actions.setPrimaryButton" | "actions.addMiniApp" | "actions.signIn" | "actions.viewCast" | "actions.viewProfile" | "actions.composeCast" | "actions.viewToken" | "actions.sendToken" | "actions.swapToken" | "haptics.impactOccurred" | "haptics.notificationOccurred" | "haptics.selectionChanged" | "back")[], ("wallet.getEthereumProvider" | "wallet.getSolanaProvider" | "actions.ready" | "actions.openUrl" | "actions.close" | "actions.setPrimaryButton" | "actions.addMiniApp" | "actions.signIn" | "actions.viewCast" | "actions.viewProfile" | "actions.composeCast" | "actions.viewToken" | "actions.sendToken" | "actions.swapToken" | "haptics.impactOccurred" | "haptics.notificationOccurred" | "haptics.selectionChanged" | "back")[]>>;
|
|
30
|
-
/** see https://github.com/farcasterxyz/miniapps/discussions/158 */
|
|
31
|
-
/** Documentation will be added once this feature is finalized. */
|
|
32
|
-
castShareUrl: z.ZodOptional<z.ZodString>;
|
|
33
|
-
/** Canonical domain for the frame application */
|
|
34
|
-
canonicalDomain: z.ZodOptional<z.ZodEffects<z.ZodEffects<z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>, string, string>, string, string>>;
|
|
35
|
-
}, "strip", z.ZodTypeAny, {
|
|
36
|
-
name: string;
|
|
37
|
-
version: "1" | "next" | "0.0.0" | "0.0.1";
|
|
38
|
-
iconUrl: string;
|
|
39
|
-
homeUrl: string;
|
|
40
|
-
splashImageUrl?: string | undefined;
|
|
41
|
-
splashBackgroundColor?: string | undefined;
|
|
42
|
-
imageUrl?: string | undefined;
|
|
43
|
-
buttonTitle?: string | undefined;
|
|
44
|
-
webhookUrl?: string | undefined;
|
|
45
|
-
subtitle?: string | undefined;
|
|
46
|
-
description?: string | undefined;
|
|
47
|
-
screenshotUrls?: string[] | undefined;
|
|
48
|
-
primaryCategory?: "games" | "social" | "finance" | "utility" | "productivity" | "health-fitness" | "news-media" | "music" | "shopping" | "education" | "developer-tools" | "entertainment" | "art-creativity" | undefined;
|
|
49
|
-
tags?: string[] | undefined;
|
|
50
|
-
heroImageUrl?: string | undefined;
|
|
51
|
-
tagline?: string | undefined;
|
|
52
|
-
ogTitle?: string | undefined;
|
|
53
|
-
ogDescription?: string | undefined;
|
|
54
|
-
ogImageUrl?: string | undefined;
|
|
55
|
-
noindex?: boolean | undefined;
|
|
56
|
-
requiredChains?: ("eip155:1" | "eip155:8453" | "eip155:42161" | "eip155:421614" | "eip155:84532" | "eip155:666666666" | "eip155:100" | "eip155:10" | "eip155:11155420" | "eip155:137" | "eip155:11155111" | "eip155:7777777" | "eip155:130" | "eip155:10143" | "eip155:42220" | "solana:5eykt4UsFv8P8NJdTREpY1vzqKqZKvdp")[] | undefined;
|
|
57
|
-
requiredCapabilities?: ("wallet.getEthereumProvider" | "wallet.getSolanaProvider" | "actions.ready" | "actions.openUrl" | "actions.close" | "actions.setPrimaryButton" | "actions.addMiniApp" | "actions.signIn" | "actions.viewCast" | "actions.viewProfile" | "actions.composeCast" | "actions.viewToken" | "actions.sendToken" | "actions.swapToken" | "haptics.impactOccurred" | "haptics.notificationOccurred" | "haptics.selectionChanged" | "back")[] | undefined;
|
|
58
|
-
castShareUrl?: string | undefined;
|
|
59
|
-
canonicalDomain?: string | undefined;
|
|
60
|
-
}, {
|
|
61
|
-
name: string;
|
|
62
|
-
version: "1" | "next" | "0.0.0" | "0.0.1";
|
|
63
|
-
iconUrl: string;
|
|
64
|
-
homeUrl: string;
|
|
65
|
-
splashImageUrl?: string | undefined;
|
|
66
|
-
splashBackgroundColor?: string | undefined;
|
|
67
|
-
imageUrl?: string | undefined;
|
|
68
|
-
buttonTitle?: string | undefined;
|
|
69
|
-
webhookUrl?: string | undefined;
|
|
70
|
-
subtitle?: string | undefined;
|
|
71
|
-
description?: string | undefined;
|
|
72
|
-
screenshotUrls?: string[] | undefined;
|
|
73
|
-
primaryCategory?: "games" | "social" | "finance" | "utility" | "productivity" | "health-fitness" | "news-media" | "music" | "shopping" | "education" | "developer-tools" | "entertainment" | "art-creativity" | undefined;
|
|
74
|
-
tags?: string[] | undefined;
|
|
75
|
-
heroImageUrl?: string | undefined;
|
|
76
|
-
tagline?: string | undefined;
|
|
77
|
-
ogTitle?: string | undefined;
|
|
78
|
-
ogDescription?: string | undefined;
|
|
79
|
-
ogImageUrl?: string | undefined;
|
|
80
|
-
noindex?: boolean | undefined;
|
|
81
|
-
requiredChains?: ("eip155:1" | "eip155:8453" | "eip155:42161" | "eip155:421614" | "eip155:84532" | "eip155:666666666" | "eip155:100" | "eip155:10" | "eip155:11155420" | "eip155:137" | "eip155:11155111" | "eip155:7777777" | "eip155:130" | "eip155:10143" | "eip155:42220" | "solana:5eykt4UsFv8P8NJdTREpY1vzqKqZKvdp")[] | undefined;
|
|
82
|
-
requiredCapabilities?: ("wallet.getEthereumProvider" | "wallet.getSolanaProvider" | "actions.ready" | "actions.openUrl" | "actions.close" | "actions.setPrimaryButton" | "actions.addMiniApp" | "actions.signIn" | "actions.viewCast" | "actions.viewProfile" | "actions.composeCast" | "actions.viewToken" | "actions.sendToken" | "actions.swapToken" | "haptics.impactOccurred" | "haptics.notificationOccurred" | "haptics.selectionChanged" | "back")[] | undefined;
|
|
83
|
-
castShareUrl?: string | undefined;
|
|
84
|
-
canonicalDomain?: string | undefined;
|
|
85
|
-
}>, {
|
|
86
|
-
name: string;
|
|
87
|
-
version: "1" | "next" | "0.0.0" | "0.0.1";
|
|
88
|
-
iconUrl: string;
|
|
89
|
-
homeUrl: string;
|
|
90
|
-
splashImageUrl?: string | undefined;
|
|
91
|
-
splashBackgroundColor?: string | undefined;
|
|
92
|
-
imageUrl?: string | undefined;
|
|
93
|
-
buttonTitle?: string | undefined;
|
|
94
|
-
webhookUrl?: string | undefined;
|
|
95
|
-
subtitle?: string | undefined;
|
|
96
|
-
description?: string | undefined;
|
|
97
|
-
screenshotUrls?: string[] | undefined;
|
|
98
|
-
primaryCategory?: "games" | "social" | "finance" | "utility" | "productivity" | "health-fitness" | "news-media" | "music" | "shopping" | "education" | "developer-tools" | "entertainment" | "art-creativity" | undefined;
|
|
99
|
-
tags?: string[] | undefined;
|
|
100
|
-
heroImageUrl?: string | undefined;
|
|
101
|
-
tagline?: string | undefined;
|
|
102
|
-
ogTitle?: string | undefined;
|
|
103
|
-
ogDescription?: string | undefined;
|
|
104
|
-
ogImageUrl?: string | undefined;
|
|
105
|
-
noindex?: boolean | undefined;
|
|
106
|
-
requiredChains?: ("eip155:1" | "eip155:8453" | "eip155:42161" | "eip155:421614" | "eip155:84532" | "eip155:666666666" | "eip155:100" | "eip155:10" | "eip155:11155420" | "eip155:137" | "eip155:11155111" | "eip155:7777777" | "eip155:130" | "eip155:10143" | "eip155:42220" | "solana:5eykt4UsFv8P8NJdTREpY1vzqKqZKvdp")[] | undefined;
|
|
107
|
-
requiredCapabilities?: ("wallet.getEthereumProvider" | "wallet.getSolanaProvider" | "actions.ready" | "actions.openUrl" | "actions.close" | "actions.setPrimaryButton" | "actions.addMiniApp" | "actions.signIn" | "actions.viewCast" | "actions.viewProfile" | "actions.composeCast" | "actions.viewToken" | "actions.sendToken" | "actions.swapToken" | "haptics.impactOccurred" | "haptics.notificationOccurred" | "haptics.selectionChanged" | "back")[] | undefined;
|
|
108
|
-
castShareUrl?: string | undefined;
|
|
109
|
-
canonicalDomain?: string | undefined;
|
|
110
|
-
}, {
|
|
111
|
-
name: string;
|
|
112
|
-
version: "1" | "next" | "0.0.0" | "0.0.1";
|
|
113
|
-
iconUrl: string;
|
|
114
|
-
homeUrl: string;
|
|
115
|
-
splashImageUrl?: string | undefined;
|
|
116
|
-
splashBackgroundColor?: string | undefined;
|
|
117
|
-
imageUrl?: string | undefined;
|
|
118
|
-
buttonTitle?: string | undefined;
|
|
119
|
-
webhookUrl?: string | undefined;
|
|
120
|
-
subtitle?: string | undefined;
|
|
121
|
-
description?: string | undefined;
|
|
122
|
-
screenshotUrls?: string[] | undefined;
|
|
123
|
-
primaryCategory?: "games" | "social" | "finance" | "utility" | "productivity" | "health-fitness" | "news-media" | "music" | "shopping" | "education" | "developer-tools" | "entertainment" | "art-creativity" | undefined;
|
|
124
|
-
tags?: string[] | undefined;
|
|
125
|
-
heroImageUrl?: string | undefined;
|
|
126
|
-
tagline?: string | undefined;
|
|
127
|
-
ogTitle?: string | undefined;
|
|
128
|
-
ogDescription?: string | undefined;
|
|
129
|
-
ogImageUrl?: string | undefined;
|
|
130
|
-
noindex?: boolean | undefined;
|
|
131
|
-
requiredChains?: ("eip155:1" | "eip155:8453" | "eip155:42161" | "eip155:421614" | "eip155:84532" | "eip155:666666666" | "eip155:100" | "eip155:10" | "eip155:11155420" | "eip155:137" | "eip155:11155111" | "eip155:7777777" | "eip155:130" | "eip155:10143" | "eip155:42220" | "solana:5eykt4UsFv8P8NJdTREpY1vzqKqZKvdp")[] | undefined;
|
|
132
|
-
requiredCapabilities?: ("wallet.getEthereumProvider" | "wallet.getSolanaProvider" | "actions.ready" | "actions.openUrl" | "actions.close" | "actions.setPrimaryButton" | "actions.addMiniApp" | "actions.signIn" | "actions.viewCast" | "actions.viewProfile" | "actions.composeCast" | "actions.viewToken" | "actions.sendToken" | "actions.swapToken" | "haptics.impactOccurred" | "haptics.notificationOccurred" | "haptics.selectionChanged" | "back")[] | undefined;
|
|
133
|
-
castShareUrl?: string | undefined;
|
|
134
|
-
canonicalDomain?: string | undefined;
|
|
135
|
-
}>;
|
|
136
|
-
export declare const domainManifestSchema: z.ZodObject<{
|
|
137
|
-
accountAssociation: z.ZodObject<{
|
|
138
|
-
header: z.ZodString;
|
|
139
|
-
payload: z.ZodString;
|
|
140
|
-
signature: z.ZodString;
|
|
141
|
-
}, "strip", z.ZodTypeAny, {
|
|
142
|
-
header: string;
|
|
143
|
-
payload: string;
|
|
144
|
-
signature: string;
|
|
145
|
-
}, {
|
|
146
|
-
header: string;
|
|
147
|
-
payload: string;
|
|
148
|
-
signature: string;
|
|
149
|
-
}>;
|
|
150
|
-
frame: z.ZodOptional<z.ZodEffects<z.ZodObject<{
|
|
151
|
-
version: z.ZodUnion<[z.ZodLiteral<"0.0.0">, z.ZodLiteral<"0.0.1">, z.ZodLiteral<"1">, z.ZodLiteral<"next">]>;
|
|
152
|
-
name: z.ZodString;
|
|
153
|
-
iconUrl: z.ZodString;
|
|
154
|
-
homeUrl: z.ZodString;
|
|
155
|
-
/** deprecated, set ogImageUrl instead */
|
|
156
|
-
imageUrl: z.ZodOptional<z.ZodString>;
|
|
157
|
-
/** deprecated, will rely on fc:frame meta tag */
|
|
158
|
-
buttonTitle: z.ZodOptional<z.ZodString>;
|
|
159
|
-
splashImageUrl: z.ZodOptional<z.ZodString>;
|
|
160
|
-
splashBackgroundColor: z.ZodOptional<z.ZodString>;
|
|
161
|
-
webhookUrl: z.ZodOptional<z.ZodString>;
|
|
162
|
-
/** see: https://github.com/farcasterxyz/miniapps/discussions/191 */
|
|
163
|
-
subtitle: z.ZodOptional<z.ZodEffects<z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>, string, string>>;
|
|
164
|
-
description: z.ZodOptional<z.ZodEffects<z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>, string, string>>;
|
|
165
|
-
screenshotUrls: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
166
|
-
primaryCategory: z.ZodOptional<z.ZodEnum<["games", "social", "finance", "utility", "productivity", "health-fitness", "news-media", "music", "shopping", "education", "developer-tools", "entertainment", "art-creativity"]>>;
|
|
167
|
-
tags: z.ZodOptional<z.ZodArray<z.ZodEffects<z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>, string, string>, "many">>;
|
|
168
|
-
heroImageUrl: z.ZodOptional<z.ZodString>;
|
|
169
|
-
tagline: z.ZodOptional<z.ZodEffects<z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>, string, string>>;
|
|
170
|
-
ogTitle: z.ZodOptional<z.ZodEffects<z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>, string, string>>;
|
|
171
|
-
ogDescription: z.ZodOptional<z.ZodEffects<z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>, string, string>>;
|
|
172
|
-
ogImageUrl: z.ZodOptional<z.ZodString>;
|
|
173
|
-
/** see: https://github.com/farcasterxyz/miniapps/discussions/204 */
|
|
174
|
-
noindex: z.ZodOptional<z.ZodBoolean>;
|
|
175
|
-
/** see https://github.com/farcasterxyz/miniapps/discussions/256 */
|
|
176
|
-
requiredChains: z.ZodOptional<z.ZodEffects<z.ZodArray<z.ZodEnum<["eip155:1", "eip155:8453", "eip155:42161", "eip155:421614", "eip155:84532", "eip155:666666666", "eip155:100", "eip155:10", "eip155:11155420", "eip155:137", "eip155:11155111", "eip155:7777777", "eip155:130", "eip155:10143", "eip155:42220", "solana:5eykt4UsFv8P8NJdTREpY1vzqKqZKvdp"]>, "many">, ("eip155:1" | "eip155:8453" | "eip155:42161" | "eip155:421614" | "eip155:84532" | "eip155:666666666" | "eip155:100" | "eip155:10" | "eip155:11155420" | "eip155:137" | "eip155:11155111" | "eip155:7777777" | "eip155:130" | "eip155:10143" | "eip155:42220" | "solana:5eykt4UsFv8P8NJdTREpY1vzqKqZKvdp")[], ("eip155:1" | "eip155:8453" | "eip155:42161" | "eip155:421614" | "eip155:84532" | "eip155:666666666" | "eip155:100" | "eip155:10" | "eip155:11155420" | "eip155:137" | "eip155:11155111" | "eip155:7777777" | "eip155:130" | "eip155:10143" | "eip155:42220" | "solana:5eykt4UsFv8P8NJdTREpY1vzqKqZKvdp")[]>>;
|
|
177
|
-
requiredCapabilities: z.ZodOptional<z.ZodEffects<z.ZodArray<z.ZodEnum<["wallet.getEthereumProvider", "wallet.getSolanaProvider", "actions.ready", "actions.openUrl", "actions.close", "actions.setPrimaryButton", "actions.addMiniApp", "actions.signIn", "actions.viewCast", "actions.viewProfile", "actions.composeCast", "actions.viewToken", "actions.sendToken", "actions.swapToken", "haptics.impactOccurred", "haptics.notificationOccurred", "haptics.selectionChanged", "back"]>, "many">, ("wallet.getEthereumProvider" | "wallet.getSolanaProvider" | "actions.ready" | "actions.openUrl" | "actions.close" | "actions.setPrimaryButton" | "actions.addMiniApp" | "actions.signIn" | "actions.viewCast" | "actions.viewProfile" | "actions.composeCast" | "actions.viewToken" | "actions.sendToken" | "actions.swapToken" | "haptics.impactOccurred" | "haptics.notificationOccurred" | "haptics.selectionChanged" | "back")[], ("wallet.getEthereumProvider" | "wallet.getSolanaProvider" | "actions.ready" | "actions.openUrl" | "actions.close" | "actions.setPrimaryButton" | "actions.addMiniApp" | "actions.signIn" | "actions.viewCast" | "actions.viewProfile" | "actions.composeCast" | "actions.viewToken" | "actions.sendToken" | "actions.swapToken" | "haptics.impactOccurred" | "haptics.notificationOccurred" | "haptics.selectionChanged" | "back")[]>>;
|
|
178
|
-
/** see https://github.com/farcasterxyz/miniapps/discussions/158 */
|
|
179
|
-
/** Documentation will be added once this feature is finalized. */
|
|
180
|
-
castShareUrl: z.ZodOptional<z.ZodString>;
|
|
181
|
-
/** Canonical domain for the frame application */
|
|
182
|
-
canonicalDomain: z.ZodOptional<z.ZodEffects<z.ZodEffects<z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>, string, string>, string, string>>;
|
|
183
|
-
}, "strip", z.ZodTypeAny, {
|
|
184
|
-
name: string;
|
|
185
|
-
version: "1" | "next" | "0.0.0" | "0.0.1";
|
|
186
|
-
iconUrl: string;
|
|
187
|
-
homeUrl: string;
|
|
188
|
-
splashImageUrl?: string | undefined;
|
|
189
|
-
splashBackgroundColor?: string | undefined;
|
|
190
|
-
imageUrl?: string | undefined;
|
|
191
|
-
buttonTitle?: string | undefined;
|
|
192
|
-
webhookUrl?: string | undefined;
|
|
193
|
-
subtitle?: string | undefined;
|
|
194
|
-
description?: string | undefined;
|
|
195
|
-
screenshotUrls?: string[] | undefined;
|
|
196
|
-
primaryCategory?: "games" | "social" | "finance" | "utility" | "productivity" | "health-fitness" | "news-media" | "music" | "shopping" | "education" | "developer-tools" | "entertainment" | "art-creativity" | undefined;
|
|
197
|
-
tags?: string[] | undefined;
|
|
198
|
-
heroImageUrl?: string | undefined;
|
|
199
|
-
tagline?: string | undefined;
|
|
200
|
-
ogTitle?: string | undefined;
|
|
201
|
-
ogDescription?: string | undefined;
|
|
202
|
-
ogImageUrl?: string | undefined;
|
|
203
|
-
noindex?: boolean | undefined;
|
|
204
|
-
requiredChains?: ("eip155:1" | "eip155:8453" | "eip155:42161" | "eip155:421614" | "eip155:84532" | "eip155:666666666" | "eip155:100" | "eip155:10" | "eip155:11155420" | "eip155:137" | "eip155:11155111" | "eip155:7777777" | "eip155:130" | "eip155:10143" | "eip155:42220" | "solana:5eykt4UsFv8P8NJdTREpY1vzqKqZKvdp")[] | undefined;
|
|
205
|
-
requiredCapabilities?: ("wallet.getEthereumProvider" | "wallet.getSolanaProvider" | "actions.ready" | "actions.openUrl" | "actions.close" | "actions.setPrimaryButton" | "actions.addMiniApp" | "actions.signIn" | "actions.viewCast" | "actions.viewProfile" | "actions.composeCast" | "actions.viewToken" | "actions.sendToken" | "actions.swapToken" | "haptics.impactOccurred" | "haptics.notificationOccurred" | "haptics.selectionChanged" | "back")[] | undefined;
|
|
206
|
-
castShareUrl?: string | undefined;
|
|
207
|
-
canonicalDomain?: string | undefined;
|
|
208
|
-
}, {
|
|
209
|
-
name: string;
|
|
210
|
-
version: "1" | "next" | "0.0.0" | "0.0.1";
|
|
211
|
-
iconUrl: string;
|
|
212
|
-
homeUrl: string;
|
|
213
|
-
splashImageUrl?: string | undefined;
|
|
214
|
-
splashBackgroundColor?: string | undefined;
|
|
215
|
-
imageUrl?: string | undefined;
|
|
216
|
-
buttonTitle?: string | undefined;
|
|
217
|
-
webhookUrl?: string | undefined;
|
|
218
|
-
subtitle?: string | undefined;
|
|
219
|
-
description?: string | undefined;
|
|
220
|
-
screenshotUrls?: string[] | undefined;
|
|
221
|
-
primaryCategory?: "games" | "social" | "finance" | "utility" | "productivity" | "health-fitness" | "news-media" | "music" | "shopping" | "education" | "developer-tools" | "entertainment" | "art-creativity" | undefined;
|
|
222
|
-
tags?: string[] | undefined;
|
|
223
|
-
heroImageUrl?: string | undefined;
|
|
224
|
-
tagline?: string | undefined;
|
|
225
|
-
ogTitle?: string | undefined;
|
|
226
|
-
ogDescription?: string | undefined;
|
|
227
|
-
ogImageUrl?: string | undefined;
|
|
228
|
-
noindex?: boolean | undefined;
|
|
229
|
-
requiredChains?: ("eip155:1" | "eip155:8453" | "eip155:42161" | "eip155:421614" | "eip155:84532" | "eip155:666666666" | "eip155:100" | "eip155:10" | "eip155:11155420" | "eip155:137" | "eip155:11155111" | "eip155:7777777" | "eip155:130" | "eip155:10143" | "eip155:42220" | "solana:5eykt4UsFv8P8NJdTREpY1vzqKqZKvdp")[] | undefined;
|
|
230
|
-
requiredCapabilities?: ("wallet.getEthereumProvider" | "wallet.getSolanaProvider" | "actions.ready" | "actions.openUrl" | "actions.close" | "actions.setPrimaryButton" | "actions.addMiniApp" | "actions.signIn" | "actions.viewCast" | "actions.viewProfile" | "actions.composeCast" | "actions.viewToken" | "actions.sendToken" | "actions.swapToken" | "haptics.impactOccurred" | "haptics.notificationOccurred" | "haptics.selectionChanged" | "back")[] | undefined;
|
|
231
|
-
castShareUrl?: string | undefined;
|
|
232
|
-
canonicalDomain?: string | undefined;
|
|
233
|
-
}>, {
|
|
234
|
-
name: string;
|
|
235
|
-
version: "1" | "next" | "0.0.0" | "0.0.1";
|
|
236
|
-
iconUrl: string;
|
|
237
|
-
homeUrl: string;
|
|
238
|
-
splashImageUrl?: string | undefined;
|
|
239
|
-
splashBackgroundColor?: string | undefined;
|
|
240
|
-
imageUrl?: string | undefined;
|
|
241
|
-
buttonTitle?: string | undefined;
|
|
242
|
-
webhookUrl?: string | undefined;
|
|
243
|
-
subtitle?: string | undefined;
|
|
244
|
-
description?: string | undefined;
|
|
245
|
-
screenshotUrls?: string[] | undefined;
|
|
246
|
-
primaryCategory?: "games" | "social" | "finance" | "utility" | "productivity" | "health-fitness" | "news-media" | "music" | "shopping" | "education" | "developer-tools" | "entertainment" | "art-creativity" | undefined;
|
|
247
|
-
tags?: string[] | undefined;
|
|
248
|
-
heroImageUrl?: string | undefined;
|
|
249
|
-
tagline?: string | undefined;
|
|
250
|
-
ogTitle?: string | undefined;
|
|
251
|
-
ogDescription?: string | undefined;
|
|
252
|
-
ogImageUrl?: string | undefined;
|
|
253
|
-
noindex?: boolean | undefined;
|
|
254
|
-
requiredChains?: ("eip155:1" | "eip155:8453" | "eip155:42161" | "eip155:421614" | "eip155:84532" | "eip155:666666666" | "eip155:100" | "eip155:10" | "eip155:11155420" | "eip155:137" | "eip155:11155111" | "eip155:7777777" | "eip155:130" | "eip155:10143" | "eip155:42220" | "solana:5eykt4UsFv8P8NJdTREpY1vzqKqZKvdp")[] | undefined;
|
|
255
|
-
requiredCapabilities?: ("wallet.getEthereumProvider" | "wallet.getSolanaProvider" | "actions.ready" | "actions.openUrl" | "actions.close" | "actions.setPrimaryButton" | "actions.addMiniApp" | "actions.signIn" | "actions.viewCast" | "actions.viewProfile" | "actions.composeCast" | "actions.viewToken" | "actions.sendToken" | "actions.swapToken" | "haptics.impactOccurred" | "haptics.notificationOccurred" | "haptics.selectionChanged" | "back")[] | undefined;
|
|
256
|
-
castShareUrl?: string | undefined;
|
|
257
|
-
canonicalDomain?: string | undefined;
|
|
258
|
-
}, {
|
|
259
|
-
name: string;
|
|
260
|
-
version: "1" | "next" | "0.0.0" | "0.0.1";
|
|
261
|
-
iconUrl: string;
|
|
262
|
-
homeUrl: string;
|
|
263
|
-
splashImageUrl?: string | undefined;
|
|
264
|
-
splashBackgroundColor?: string | undefined;
|
|
265
|
-
imageUrl?: string | undefined;
|
|
266
|
-
buttonTitle?: string | undefined;
|
|
267
|
-
webhookUrl?: string | undefined;
|
|
268
|
-
subtitle?: string | undefined;
|
|
269
|
-
description?: string | undefined;
|
|
270
|
-
screenshotUrls?: string[] | undefined;
|
|
271
|
-
primaryCategory?: "games" | "social" | "finance" | "utility" | "productivity" | "health-fitness" | "news-media" | "music" | "shopping" | "education" | "developer-tools" | "entertainment" | "art-creativity" | undefined;
|
|
272
|
-
tags?: string[] | undefined;
|
|
273
|
-
heroImageUrl?: string | undefined;
|
|
274
|
-
tagline?: string | undefined;
|
|
275
|
-
ogTitle?: string | undefined;
|
|
276
|
-
ogDescription?: string | undefined;
|
|
277
|
-
ogImageUrl?: string | undefined;
|
|
278
|
-
noindex?: boolean | undefined;
|
|
279
|
-
requiredChains?: ("eip155:1" | "eip155:8453" | "eip155:42161" | "eip155:421614" | "eip155:84532" | "eip155:666666666" | "eip155:100" | "eip155:10" | "eip155:11155420" | "eip155:137" | "eip155:11155111" | "eip155:7777777" | "eip155:130" | "eip155:10143" | "eip155:42220" | "solana:5eykt4UsFv8P8NJdTREpY1vzqKqZKvdp")[] | undefined;
|
|
280
|
-
requiredCapabilities?: ("wallet.getEthereumProvider" | "wallet.getSolanaProvider" | "actions.ready" | "actions.openUrl" | "actions.close" | "actions.setPrimaryButton" | "actions.addMiniApp" | "actions.signIn" | "actions.viewCast" | "actions.viewProfile" | "actions.composeCast" | "actions.viewToken" | "actions.sendToken" | "actions.swapToken" | "haptics.impactOccurred" | "haptics.notificationOccurred" | "haptics.selectionChanged" | "back")[] | undefined;
|
|
281
|
-
castShareUrl?: string | undefined;
|
|
282
|
-
canonicalDomain?: string | undefined;
|
|
283
|
-
}>>;
|
|
284
|
-
}, "strip", z.ZodTypeAny, {
|
|
285
|
-
accountAssociation: {
|
|
286
|
-
header: string;
|
|
287
|
-
payload: string;
|
|
288
|
-
signature: string;
|
|
289
|
-
};
|
|
290
|
-
frame?: {
|
|
291
|
-
name: string;
|
|
292
|
-
version: "1" | "next" | "0.0.0" | "0.0.1";
|
|
293
|
-
iconUrl: string;
|
|
294
|
-
homeUrl: string;
|
|
295
|
-
splashImageUrl?: string | undefined;
|
|
296
|
-
splashBackgroundColor?: string | undefined;
|
|
297
|
-
imageUrl?: string | undefined;
|
|
298
|
-
buttonTitle?: string | undefined;
|
|
299
|
-
webhookUrl?: string | undefined;
|
|
300
|
-
subtitle?: string | undefined;
|
|
301
|
-
description?: string | undefined;
|
|
302
|
-
screenshotUrls?: string[] | undefined;
|
|
303
|
-
primaryCategory?: "games" | "social" | "finance" | "utility" | "productivity" | "health-fitness" | "news-media" | "music" | "shopping" | "education" | "developer-tools" | "entertainment" | "art-creativity" | undefined;
|
|
304
|
-
tags?: string[] | undefined;
|
|
305
|
-
heroImageUrl?: string | undefined;
|
|
306
|
-
tagline?: string | undefined;
|
|
307
|
-
ogTitle?: string | undefined;
|
|
308
|
-
ogDescription?: string | undefined;
|
|
309
|
-
ogImageUrl?: string | undefined;
|
|
310
|
-
noindex?: boolean | undefined;
|
|
311
|
-
requiredChains?: ("eip155:1" | "eip155:8453" | "eip155:42161" | "eip155:421614" | "eip155:84532" | "eip155:666666666" | "eip155:100" | "eip155:10" | "eip155:11155420" | "eip155:137" | "eip155:11155111" | "eip155:7777777" | "eip155:130" | "eip155:10143" | "eip155:42220" | "solana:5eykt4UsFv8P8NJdTREpY1vzqKqZKvdp")[] | undefined;
|
|
312
|
-
requiredCapabilities?: ("wallet.getEthereumProvider" | "wallet.getSolanaProvider" | "actions.ready" | "actions.openUrl" | "actions.close" | "actions.setPrimaryButton" | "actions.addMiniApp" | "actions.signIn" | "actions.viewCast" | "actions.viewProfile" | "actions.composeCast" | "actions.viewToken" | "actions.sendToken" | "actions.swapToken" | "haptics.impactOccurred" | "haptics.notificationOccurred" | "haptics.selectionChanged" | "back")[] | undefined;
|
|
313
|
-
castShareUrl?: string | undefined;
|
|
314
|
-
canonicalDomain?: string | undefined;
|
|
315
|
-
} | undefined;
|
|
316
|
-
}, {
|
|
317
|
-
accountAssociation: {
|
|
318
|
-
header: string;
|
|
319
|
-
payload: string;
|
|
320
|
-
signature: string;
|
|
321
|
-
};
|
|
322
|
-
frame?: {
|
|
323
|
-
name: string;
|
|
324
|
-
version: "1" | "next" | "0.0.0" | "0.0.1";
|
|
325
|
-
iconUrl: string;
|
|
326
|
-
homeUrl: string;
|
|
327
|
-
splashImageUrl?: string | undefined;
|
|
328
|
-
splashBackgroundColor?: string | undefined;
|
|
329
|
-
imageUrl?: string | undefined;
|
|
330
|
-
buttonTitle?: string | undefined;
|
|
331
|
-
webhookUrl?: string | undefined;
|
|
332
|
-
subtitle?: string | undefined;
|
|
333
|
-
description?: string | undefined;
|
|
334
|
-
screenshotUrls?: string[] | undefined;
|
|
335
|
-
primaryCategory?: "games" | "social" | "finance" | "utility" | "productivity" | "health-fitness" | "news-media" | "music" | "shopping" | "education" | "developer-tools" | "entertainment" | "art-creativity" | undefined;
|
|
336
|
-
tags?: string[] | undefined;
|
|
337
|
-
heroImageUrl?: string | undefined;
|
|
338
|
-
tagline?: string | undefined;
|
|
339
|
-
ogTitle?: string | undefined;
|
|
340
|
-
ogDescription?: string | undefined;
|
|
341
|
-
ogImageUrl?: string | undefined;
|
|
342
|
-
noindex?: boolean | undefined;
|
|
343
|
-
requiredChains?: ("eip155:1" | "eip155:8453" | "eip155:42161" | "eip155:421614" | "eip155:84532" | "eip155:666666666" | "eip155:100" | "eip155:10" | "eip155:11155420" | "eip155:137" | "eip155:11155111" | "eip155:7777777" | "eip155:130" | "eip155:10143" | "eip155:42220" | "solana:5eykt4UsFv8P8NJdTREpY1vzqKqZKvdp")[] | undefined;
|
|
344
|
-
requiredCapabilities?: ("wallet.getEthereumProvider" | "wallet.getSolanaProvider" | "actions.ready" | "actions.openUrl" | "actions.close" | "actions.setPrimaryButton" | "actions.addMiniApp" | "actions.signIn" | "actions.viewCast" | "actions.viewProfile" | "actions.composeCast" | "actions.viewToken" | "actions.sendToken" | "actions.swapToken" | "haptics.impactOccurred" | "haptics.notificationOccurred" | "haptics.selectionChanged" | "back")[] | undefined;
|
|
345
|
-
castShareUrl?: string | undefined;
|
|
346
|
-
canonicalDomain?: string | undefined;
|
|
347
|
-
} | undefined;
|
|
348
|
-
}>;
|
package/dist/schemas/manifest.js
DELETED
|
@@ -1,114 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.domainManifestSchema = exports.domainFrameConfigSchema = void 0;
|
|
4
|
-
const zod_1 = require("zod");
|
|
5
|
-
const types_ts_1 = require("../types.js");
|
|
6
|
-
const shared_ts_1 = require("./shared.js");
|
|
7
|
-
const primaryCategorySchema = zod_1.z.enum([
|
|
8
|
-
'games',
|
|
9
|
-
'social',
|
|
10
|
-
'finance',
|
|
11
|
-
'utility',
|
|
12
|
-
'productivity',
|
|
13
|
-
'health-fitness',
|
|
14
|
-
'news-media',
|
|
15
|
-
'music',
|
|
16
|
-
'shopping',
|
|
17
|
-
'education',
|
|
18
|
-
'developer-tools',
|
|
19
|
-
'entertainment',
|
|
20
|
-
'art-creativity',
|
|
21
|
-
]);
|
|
22
|
-
const chainList = [
|
|
23
|
-
'eip155:1', // Ethereum mainnet
|
|
24
|
-
'eip155:8453', // Base mainnet
|
|
25
|
-
'eip155:42161', // Arbitrum One
|
|
26
|
-
'eip155:421614', // Arbitrum Sepolia
|
|
27
|
-
'eip155:84532', // Base Sepolia
|
|
28
|
-
'eip155:666666666', // Degen
|
|
29
|
-
'eip155:100', // Gnosis
|
|
30
|
-
'eip155:10', // Optimism
|
|
31
|
-
'eip155:11155420', // Optimism Sepolia
|
|
32
|
-
'eip155:137', // Polygon
|
|
33
|
-
'eip155:11155111', // Ethereum Sepolia
|
|
34
|
-
'eip155:7777777', // Zora
|
|
35
|
-
'eip155:130', // Unichain
|
|
36
|
-
'eip155:10143', // Monad testnet
|
|
37
|
-
'eip155:42220', // Celo
|
|
38
|
-
'solana:5eykt4UsFv8P8NJdTREpY1vzqKqZKvdp', // Solana
|
|
39
|
-
];
|
|
40
|
-
function removeArrayDuplicates(arr) {
|
|
41
|
-
const set = new Set(arr);
|
|
42
|
-
return Array.from(set);
|
|
43
|
-
}
|
|
44
|
-
exports.domainFrameConfigSchema = zod_1.z
|
|
45
|
-
.object({
|
|
46
|
-
// 0.0.0 and 0.0.1 are not technically part of the spec but kept for
|
|
47
|
-
// backwards compatibility. next should always resolve to the most recent
|
|
48
|
-
// schema version.
|
|
49
|
-
version: zod_1.z.union([
|
|
50
|
-
zod_1.z.literal('0.0.0'),
|
|
51
|
-
zod_1.z.literal('0.0.1'),
|
|
52
|
-
zod_1.z.literal('1'),
|
|
53
|
-
zod_1.z.literal('next'),
|
|
54
|
-
]),
|
|
55
|
-
name: shared_ts_1.frameNameSchema,
|
|
56
|
-
iconUrl: shared_ts_1.secureUrlSchema,
|
|
57
|
-
homeUrl: shared_ts_1.secureUrlSchema,
|
|
58
|
-
/** deprecated, set ogImageUrl instead */
|
|
59
|
-
imageUrl: shared_ts_1.secureUrlSchema.optional(),
|
|
60
|
-
/** deprecated, will rely on fc:frame meta tag */
|
|
61
|
-
buttonTitle: shared_ts_1.buttonTitleSchema.optional(),
|
|
62
|
-
splashImageUrl: shared_ts_1.secureUrlSchema.optional(),
|
|
63
|
-
splashBackgroundColor: shared_ts_1.hexColorSchema.optional(),
|
|
64
|
-
webhookUrl: shared_ts_1.secureUrlSchema.optional(),
|
|
65
|
-
/** see: https://github.com/farcasterxyz/miniapps/discussions/191 */
|
|
66
|
-
subtitle: (0, shared_ts_1.createSimpleStringSchema)({ max: 30 }).optional(),
|
|
67
|
-
description: (0, shared_ts_1.createSimpleStringSchema)({ max: 170 }).optional(),
|
|
68
|
-
screenshotUrls: zod_1.z.array(shared_ts_1.secureUrlSchema).max(3).optional(),
|
|
69
|
-
primaryCategory: primaryCategorySchema.optional(),
|
|
70
|
-
tags: zod_1.z
|
|
71
|
-
.array((0, shared_ts_1.createSimpleStringSchema)({ max: 20, noSpaces: true }))
|
|
72
|
-
.max(5)
|
|
73
|
-
.optional(),
|
|
74
|
-
heroImageUrl: shared_ts_1.secureUrlSchema.optional(),
|
|
75
|
-
tagline: (0, shared_ts_1.createSimpleStringSchema)({ max: 30 }).optional(),
|
|
76
|
-
ogTitle: (0, shared_ts_1.createSimpleStringSchema)({ max: 30 }).optional(),
|
|
77
|
-
ogDescription: (0, shared_ts_1.createSimpleStringSchema)({ max: 100 }).optional(),
|
|
78
|
-
ogImageUrl: shared_ts_1.secureUrlSchema.optional(),
|
|
79
|
-
/** see: https://github.com/farcasterxyz/miniapps/discussions/204 */
|
|
80
|
-
noindex: zod_1.z.boolean().optional(),
|
|
81
|
-
/** see https://github.com/farcasterxyz/miniapps/discussions/256 */
|
|
82
|
-
requiredChains: zod_1.z
|
|
83
|
-
.array(zod_1.z.enum(chainList))
|
|
84
|
-
.transform(removeArrayDuplicates)
|
|
85
|
-
.optional(),
|
|
86
|
-
requiredCapabilities: zod_1.z
|
|
87
|
-
.array(zod_1.z.enum(types_ts_1.miniAppHostCapabilityList))
|
|
88
|
-
.transform(removeArrayDuplicates)
|
|
89
|
-
.optional(),
|
|
90
|
-
/** see https://github.com/farcasterxyz/miniapps/discussions/158 */
|
|
91
|
-
/** Documentation will be added once this feature is finalized. */
|
|
92
|
-
castShareUrl: shared_ts_1.secureUrlSchema.optional(),
|
|
93
|
-
/** Canonical domain for the frame application */
|
|
94
|
-
canonicalDomain: shared_ts_1.domainSchema.optional(),
|
|
95
|
-
})
|
|
96
|
-
.refine((data) => {
|
|
97
|
-
if (data.castShareUrl === undefined)
|
|
98
|
-
return true;
|
|
99
|
-
try {
|
|
100
|
-
const homeUrlDomain = new URL(data.homeUrl).hostname;
|
|
101
|
-
const castShareUrlDomain = new URL(data.castShareUrl).hostname;
|
|
102
|
-
return homeUrlDomain === castShareUrlDomain;
|
|
103
|
-
}
|
|
104
|
-
catch {
|
|
105
|
-
return false;
|
|
106
|
-
}
|
|
107
|
-
}, {
|
|
108
|
-
message: 'castShareUrl must have the same domain as homeUrl',
|
|
109
|
-
path: ['castShareUrl'],
|
|
110
|
-
});
|
|
111
|
-
exports.domainManifestSchema = zod_1.z.object({
|
|
112
|
-
accountAssociation: shared_ts_1.encodedJsonFarcasterSignatureSchema,
|
|
113
|
-
frame: exports.domainFrameConfigSchema.optional(),
|
|
114
|
-
});
|
|
@@ -1,60 +0,0 @@
|
|
|
1
|
-
import { z } from 'zod';
|
|
2
|
-
export declare const notificationDetailsSchema: z.ZodObject<{
|
|
3
|
-
url: z.ZodString;
|
|
4
|
-
token: z.ZodString;
|
|
5
|
-
}, "strip", z.ZodTypeAny, {
|
|
6
|
-
url: string;
|
|
7
|
-
token: string;
|
|
8
|
-
}, {
|
|
9
|
-
url: string;
|
|
10
|
-
token: string;
|
|
11
|
-
}>;
|
|
12
|
-
export type FrameNotificationDetails = z.infer<typeof notificationDetailsSchema>;
|
|
13
|
-
export declare const sendNotificationRequestSchema: z.ZodObject<{
|
|
14
|
-
notificationId: z.ZodString;
|
|
15
|
-
title: z.ZodString;
|
|
16
|
-
body: z.ZodString;
|
|
17
|
-
targetUrl: z.ZodString;
|
|
18
|
-
tokens: z.ZodArray<z.ZodString, "many">;
|
|
19
|
-
}, "strip", z.ZodTypeAny, {
|
|
20
|
-
title: string;
|
|
21
|
-
notificationId: string;
|
|
22
|
-
body: string;
|
|
23
|
-
targetUrl: string;
|
|
24
|
-
tokens: string[];
|
|
25
|
-
}, {
|
|
26
|
-
title: string;
|
|
27
|
-
notificationId: string;
|
|
28
|
-
body: string;
|
|
29
|
-
targetUrl: string;
|
|
30
|
-
tokens: string[];
|
|
31
|
-
}>;
|
|
32
|
-
export type SendNotificationRequest = z.infer<typeof sendNotificationRequestSchema>;
|
|
33
|
-
export declare const sendNotificationResponseSchema: z.ZodObject<{
|
|
34
|
-
result: z.ZodObject<{
|
|
35
|
-
successfulTokens: z.ZodArray<z.ZodString, "many">;
|
|
36
|
-
invalidTokens: z.ZodArray<z.ZodString, "many">;
|
|
37
|
-
rateLimitedTokens: z.ZodArray<z.ZodString, "many">;
|
|
38
|
-
}, "strip", z.ZodTypeAny, {
|
|
39
|
-
successfulTokens: string[];
|
|
40
|
-
invalidTokens: string[];
|
|
41
|
-
rateLimitedTokens: string[];
|
|
42
|
-
}, {
|
|
43
|
-
successfulTokens: string[];
|
|
44
|
-
invalidTokens: string[];
|
|
45
|
-
rateLimitedTokens: string[];
|
|
46
|
-
}>;
|
|
47
|
-
}, "strip", z.ZodTypeAny, {
|
|
48
|
-
result: {
|
|
49
|
-
successfulTokens: string[];
|
|
50
|
-
invalidTokens: string[];
|
|
51
|
-
rateLimitedTokens: string[];
|
|
52
|
-
};
|
|
53
|
-
}, {
|
|
54
|
-
result: {
|
|
55
|
-
successfulTokens: string[];
|
|
56
|
-
invalidTokens: string[];
|
|
57
|
-
rateLimitedTokens: string[];
|
|
58
|
-
};
|
|
59
|
-
}>;
|
|
60
|
-
export type SendNotificationResponse = z.infer<typeof sendNotificationResponseSchema>;
|
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.sendNotificationResponseSchema = exports.sendNotificationRequestSchema = exports.notificationDetailsSchema = void 0;
|
|
4
|
-
const zod_1 = require("zod");
|
|
5
|
-
const shared_ts_1 = require("./shared.js");
|
|
6
|
-
exports.notificationDetailsSchema = zod_1.z.object({
|
|
7
|
-
url: zod_1.z.string(),
|
|
8
|
-
token: zod_1.z.string(),
|
|
9
|
-
});
|
|
10
|
-
exports.sendNotificationRequestSchema = zod_1.z.object({
|
|
11
|
-
notificationId: zod_1.z.string().max(128),
|
|
12
|
-
title: zod_1.z.string().max(32),
|
|
13
|
-
body: zod_1.z.string().max(128),
|
|
14
|
-
targetUrl: shared_ts_1.secureUrlSchema,
|
|
15
|
-
tokens: zod_1.z.string().array().max(100),
|
|
16
|
-
});
|
|
17
|
-
exports.sendNotificationResponseSchema = zod_1.z.object({
|
|
18
|
-
result: zod_1.z.object({
|
|
19
|
-
successfulTokens: zod_1.z.array(zod_1.z.string()),
|
|
20
|
-
invalidTokens: zod_1.z.array(zod_1.z.string()),
|
|
21
|
-
rateLimitedTokens: zod_1.z.array(zod_1.z.string()),
|
|
22
|
-
}),
|
|
23
|
-
});
|
package/dist/schemas/shared.d.ts
DELETED
|
@@ -1,40 +0,0 @@
|
|
|
1
|
-
import { z } from 'zod';
|
|
2
|
-
export declare const createSimpleStringSchema: ({ max, noSpaces, }?: {
|
|
3
|
-
max?: number;
|
|
4
|
-
noSpaces?: boolean;
|
|
5
|
-
}) => z.ZodEffects<z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>, string, string>;
|
|
6
|
-
export declare const secureUrlSchema: z.ZodString;
|
|
7
|
-
export declare const frameNameSchema: z.ZodString;
|
|
8
|
-
export declare const buttonTitleSchema: z.ZodString;
|
|
9
|
-
export declare const caip19TokenSchema: z.ZodString;
|
|
10
|
-
export declare const hexColorSchema: z.ZodString;
|
|
11
|
-
export declare const domainSchema: z.ZodEffects<z.ZodEffects<z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>, string, string>, string, string>;
|
|
12
|
-
export declare const aspectRatioSchema: z.ZodUnion<[z.ZodLiteral<"1:1">, z.ZodLiteral<"3:2">]>;
|
|
13
|
-
export declare const encodedJsonFarcasterSignatureSchema: z.ZodObject<{
|
|
14
|
-
header: z.ZodString;
|
|
15
|
-
payload: z.ZodString;
|
|
16
|
-
signature: z.ZodString;
|
|
17
|
-
}, "strip", z.ZodTypeAny, {
|
|
18
|
-
header: string;
|
|
19
|
-
payload: string;
|
|
20
|
-
signature: string;
|
|
21
|
-
}, {
|
|
22
|
-
header: string;
|
|
23
|
-
payload: string;
|
|
24
|
-
signature: string;
|
|
25
|
-
}>;
|
|
26
|
-
export type EncodedJsonFarcasterSignatureSchema = z.infer<typeof encodedJsonFarcasterSignatureSchema>;
|
|
27
|
-
export declare const jsonFarcasterSignatureHeaderSchema: z.ZodObject<{
|
|
28
|
-
fid: z.ZodNumber;
|
|
29
|
-
type: z.ZodLiteral<"app_key">;
|
|
30
|
-
key: z.ZodString;
|
|
31
|
-
}, "strip", z.ZodTypeAny, {
|
|
32
|
-
type: "app_key";
|
|
33
|
-
fid: number;
|
|
34
|
-
key: string;
|
|
35
|
-
}, {
|
|
36
|
-
type: "app_key";
|
|
37
|
-
fid: number;
|
|
38
|
-
key: string;
|
|
39
|
-
}>;
|
|
40
|
-
export type JsonFarcasterSignatureHeaderSchema = z.infer<typeof jsonFarcasterSignatureHeaderSchema>;
|