Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion recipes/server-wallets/alchemy-smart-wallets.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -395,7 +395,7 @@ Since the private key lives inside Magic's TEE (Trusted Execution Environment),
| Endpoint | Purpose |
|----------|---------|
| `POST /v1/wallet` | Get or create an EOA wallet |
| `POST /v1/wallet/sign/data` | Sign a raw hash (used for EIP-191 and EIP-712) |
| `POST /v1/wallet/sign/data` | Sign a hash, sent with its message or typed data as `transaction_data` (used for EIP-191 and EIP-712) |
| `POST /v1/wallet/sign/eip7702` | Sign an EIP-7702 authorization |

***
Expand Down
12 changes: 4 additions & 8 deletions uoa/api-reference/wallet-operations.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -44,16 +44,12 @@ curl -X POST 'https://uoa-server.magic.xyz/wallet/sign' \

### Request Parameters

<ParamField body="raw_data_hash" type="string">
A `0x`-prefixed hex hash to sign directly. Provide either this or `message`.
</ParamField>

<ParamField body="message" type="string">
A plain text message to hash (keccak256) and sign. Provide either this or `raw_data_hash`.
<ParamField body="message" type="string" required>
A plain text message to sign. It is signed as an EIP-191 (`personal_sign`) message over its UTF-8 bytes, so you can verify it with standard tools such as ethers' `verifyMessage`.
</ParamField>

<Warning>
You must provide `raw_data_hash` or `message`. If both are provided, `raw_data_hash` is signed.
Signing a bare hash is not supported. A request with `raw_data_hash` and no `message` returns `400`.
</Warning>

### Response Fields
Expand All @@ -67,7 +63,7 @@ The hex-encoded signature.
</ResponseField>

<ResponseField name="raw_data_hash" type="string">
The hash that was signed.
The EIP-191 hash of `message` that was signed.
</ResponseField>

<ResponseField name="app_user_id" type="string">
Expand Down
Loading