You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
A Farcaster Message represents an action taken by a user.
Messages are atomic updates that add or remove content from the network. For example, a user can make a new cast by generating a CastAdd message and remove it with a CastRemove message. See the protocol spec for more information on how messages work.
Messages are protobufs which are converted by @farcaster/hub-nodejs into the Typescript types documented below. Each message is signed by a key pair that is provably controlled by the user. Some messages must be signed by the Ethereum address that controls the user's fid on-chain while other messages must be signed by an EdDSA key pair known as a Signer, which is authorized to act on behalf of the Ethereum address. The protocol specification defines the message types as:
Message
Action
SignerAdd
Add a new Ed25519 key pair that can sign messages for a user
SignerRemove
Remove an existing Ed25519 key pair and all messages signed by it
UserDataAdd
Update some metadata about a user (e.g. Display Name)
CastAdd
Add a new Cast
CastRemove
Remove an existing cast
ReactionAdd
Add a Reaction to an existing item (e.g. like a cast)
ReactionRemove
Remove an existing Reaction from an existing item
VerificationAddEthAddress
Add a signed message verifying that a user owns an Ethereum address
VerificationRemove
Remove a previously added verification message
Message<Data>
A generic container which holds the contents of the message(MessageData) and metadata to authenticate it.
Alternative to using the data field. Contains the serialized MessageData bytes, on which you can calculate the hash and signature. Use this field instead of data if you are using another programing language or protobuf encoding scheme. Optional.
MessageData<Body,Type>
A container which holds common properties like fid, network, timestamp and type along with properties specific to the type.
Due to a quirk of how gRPC compiles types to TypeScript, MessageData has many optional body containers (e.g. signerAddBody) with an implicit guarantee that one specific body will be present for a given type value.