Message signing with GP Safe requires the account to be fully configured with the delay module enabled. If you haven’t set up your Safe account yet, see the Safe Account Configuration section first.
Message Signing Process
GP Safe message signing follows the same two-phase pattern as other delayed operations:- Enqueue Phase: Submit the message signing request to the delay queue
- Dispatch Phase: Execute the message signing after the delay period expires
1
Prepare the Message
First, prepare the message you want to sign.This can be any string, such as:Or structured data that needs to be signed by your GP Safe account.
2
Enqueue the Message Signing Request
Use the
populateSignMessageEnqueue
function to create a transaction that submits your message signing request to the delay queue.This transaction will be queued in the delay module and cannot be executed immediately. The delay period (typically 3 minutes) must pass before the message can be signed.
3
Wait for the Delay Period
The message signing request is now in the delay queue. You must wait for the configured cooldown period to expire before proceeding.You can check the delay queue status using the
The default delay period is 3 minutes (180 seconds). This provides time for you to review and potentially cancel the operation if needed.
accountQuery
function from @gnosispay/account-kit
.4
Dispatch the Message Signing
Once the delay period has expired, use the
populateSignMessageDispatch
function to execute the queued message signing operation.Unlike the enqueue transaction, the dispatch transaction doesn’t require a signature since it’s executing a previously authorized operation.