@playthecut/agent 0.2.1 → 0.2.3
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 +1 -1
- package/api.md +1 -1
- package/docs/agents.md +1 -1
- package/docs/api.md +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -50,7 +50,7 @@ A delegate names the account with `smartWallet` in the query, because the signat
|
|
|
50
50
|
|
|
51
51
|
These stay on a Privy session: `POST /api/auth/session`, `POST /api/auth/sync-wallets`, delegate install and revoke, and `/api/admin`. Public sport, event, and field routes stay unsigned. `AGENT` is a player type. It is not staff, so an agent signature on an admin route is rejected and an agent cannot create a public contest.
|
|
52
52
|
|
|
53
|
-
`keyid` is `
|
|
53
|
+
`keyid` is `eip155:<chainId>:0x<signer>`, with the signer address lowercase. The chain is `8453` or `84532` and must equal `chainId` on the request. `created` and `expires` are unix seconds. `expires - created` is at most one hour. `nonce` is a single-use ASCII string of at most 128 bytes. The server stores `(keyid, nonce)` until `expires`.
|
|
54
54
|
|
|
55
55
|
The signer is the delegate address, or the smart wallet when the user signs. A signature over a changed method, path, query, or body is rejected.
|
|
56
56
|
|
package/api.md
CHANGED
|
@@ -21,7 +21,7 @@ A lineup roster is `candidates` on every request and response. A write is an ord
|
|
|
21
21
|
| `privy` | Privy bearer only. |
|
|
22
22
|
| `staff` | Privy bearer and `userType` `ADMIN` or `SUPER_ADMIN`. |
|
|
23
23
|
|
|
24
|
-
Player routes accept either a Privy bearer token or an [ERC-8128](https://erc8128.org) HTTP message signature. The headers are `Signature-Input` and `Signature`, plus `Content-Digest` when the request has a body. Sending both credentials is `400`. The signer is an active delegate for the signed `smartWallet` query, or the wallet verified with ERC-1271 when that query is omitted. `user.address` is the wallet. `keyid` is `
|
|
24
|
+
Player routes accept either a Privy bearer token or an [ERC-8128](https://erc8128.org) HTTP message signature. The headers are `Signature-Input` and `Signature`, plus `Content-Digest` when the request has a body. Sending both credentials is `400`. The signer is an active delegate for the signed `smartWallet` query, or the wallet verified with ERC-1271 when that query is omitted. `user.address` is the wallet. `keyid` is `eip155:<chainId>:0x<signer>` (lowercase address) and its chain must equal `X-Cut-Chain-Id` when that header is present (`8453` or `84532`). The signature is Request-Bound and Non-Replayable: `created` and `expires` are at most one hour apart, and `(keyid, nonce)` is consumed until `expires`.
|
|
25
25
|
|
|
26
26
|
`AGENT` is a player type. It is not staff.
|
|
27
27
|
|
package/docs/agents.md
CHANGED
|
@@ -50,7 +50,7 @@ A delegate names the account with `smartWallet` in the query, because the signat
|
|
|
50
50
|
|
|
51
51
|
These stay on a Privy session: `POST /api/auth/session`, `POST /api/auth/sync-wallets`, delegate install and revoke, and `/api/admin`. Public sport, event, and field routes stay unsigned. `AGENT` is a player type. It is not staff, so an agent signature on an admin route is rejected and an agent cannot create a public contest.
|
|
52
52
|
|
|
53
|
-
`keyid` is `
|
|
53
|
+
`keyid` is `eip155:<chainId>:0x<signer>`, with the signer address lowercase. The chain is `8453` or `84532` and must equal `chainId` on the request. `created` and `expires` are unix seconds. `expires - created` is at most one hour. `nonce` is a single-use ASCII string of at most 128 bytes. The server stores `(keyid, nonce)` until `expires`.
|
|
54
54
|
|
|
55
55
|
The signer is the delegate address, or the smart wallet when the user signs. A signature over a changed method, path, query, or body is rejected.
|
|
56
56
|
|
package/docs/api.md
CHANGED
|
@@ -21,7 +21,7 @@ A lineup roster is `candidates` on every request and response. A write is an ord
|
|
|
21
21
|
| `privy` | Privy bearer only. |
|
|
22
22
|
| `staff` | Privy bearer and `userType` `ADMIN` or `SUPER_ADMIN`. |
|
|
23
23
|
|
|
24
|
-
Player routes accept either a Privy bearer token or an [ERC-8128](https://erc8128.org) HTTP message signature. The headers are `Signature-Input` and `Signature`, plus `Content-Digest` when the request has a body. Sending both credentials is `400`. The signer is an active delegate for the signed `smartWallet` query, or the wallet verified with ERC-1271 when that query is omitted. `user.address` is the wallet. `keyid` is `
|
|
24
|
+
Player routes accept either a Privy bearer token or an [ERC-8128](https://erc8128.org) HTTP message signature. The headers are `Signature-Input` and `Signature`, plus `Content-Digest` when the request has a body. Sending both credentials is `400`. The signer is an active delegate for the signed `smartWallet` query, or the wallet verified with ERC-1271 when that query is omitted. `user.address` is the wallet. `keyid` is `eip155:<chainId>:0x<signer>` (lowercase address) and its chain must equal `X-Cut-Chain-Id` when that header is present (`8453` or `84532`). The signature is Request-Bound and Non-Replayable: `created` and `expires` are at most one hour apart, and `(keyid, nonce)` is consumed until `expires`.
|
|
25
25
|
|
|
26
26
|
`AGENT` is a player type. It is not staff.
|
|
27
27
|
|