Wallet
Read your Lightning addresses, link your wallet, and stop receiving at an address.
| Operation | Request |
|---|---|
| Read your Lightning addresses | GET /v1/device/lightning-address |
| Prove your wallet controls this address | PUT /v1/device/lightning-address |
| Stop receiving at your address | DELETE /v1/device/lightning-address |
| Request a challenge to link your wallet | POST /v1/device/lightning-address/challenge |
Read your Lightning addresses
GET /v1/device/lightning-address · getDeviceLightningAddresses
Uses your current account session. Wallet signatures are made locally; never send recovery words or private keys. Responses are not cached.
Sign-in: a bearer credential in the Authorization header.
appBearer: A WorkOS access JWT, live app sess_ session, or oa_sk_ sign-in key. Account-bound oak_ keys are accepted only where the operation declares them and their scopes permit it. API cookies are ignored.
Response
200 — The current address state or a challenge to link your wallet.
Type: object
Errors
| Status | Meaning | Body |
|---|---|---|
| 400 | Check the request and wallet signature. | |
| 401 | Log in again to continue. | |
| 409 | Refresh the address revision and try again. | |
| 503 | Receiving is unavailable or has not been configured. |
Example
curl 'https://api.openagents.com/v1/device/lightning-address' \
-H "Authorization: Bearer $OPENAGENTS_TOKEN"
In the Rust SDK
Prove your wallet controls this address
PUT /v1/device/lightning-address · enrollDeviceLightningAddress
Uses your current account session. Wallet signatures are made locally; never send recovery words or private keys. Responses are not cached.
Sign-in: a bearer credential in the Authorization header.
appBearer: A WorkOS access JWT, live app sess_ session, or oa_sk_ sign-in key. Account-bound oak_ keys are accepted only where the operation declares them and their scopes permit it. API cookies are ignored.
Request body
Content type: application/json
Type: object
| Field | Type | Required | Description |
|---|---|---|---|
challenge | string | Yes | |
pubkey | string | Yes | |
signature | string | Yes |
Response
200 — The current address state or a challenge to link your wallet.
Type: object
Errors
| Status | Meaning | Body |
|---|---|---|
| 400 | Check the request and wallet signature. | |
| 401 | Log in again to continue. | |
| 409 | Refresh the address revision and try again. | |
| 503 | Receiving is unavailable or has not been configured. |
Example
curl -X PUT 'https://api.openagents.com/v1/device/lightning-address' \
-H "Authorization: Bearer $OPENAGENTS_TOKEN" \
-H 'Content-Type: application/json' \
-d '{
"challenge": "string",
"pubkey": "string",
"signature": "string"
}'
In the Rust SDK
Stop receiving at your address
DELETE /v1/device/lightning-address · disableDeviceLightningAddress
Uses your current account session. Wallet signatures are made locally; never send recovery words or private keys. Responses are not cached.
Sign-in: a bearer credential in the Authorization header.
appBearer: A WorkOS access JWT, live app sess_ session, or oa_sk_ sign-in key. Account-bound oak_ keys are accepted only where the operation declares them and their scopes permit it. API cookies are ignored.
Request body
Content type: application/json
Type: object
| Field | Type | Required | Description |
|---|---|---|---|
name | string | Yes | |
expected_revision | integer | Yes |
Response
200 — The current address state or a challenge to link your wallet.
Type: object
Errors
| Status | Meaning | Body |
|---|---|---|
| 400 | Check the request and wallet signature. | |
| 401 | Log in again to continue. | |
| 409 | Refresh the address revision and try again. | |
| 503 | Receiving is unavailable or has not been configured. |
Example
curl -X DELETE 'https://api.openagents.com/v1/device/lightning-address' \
-H "Authorization: Bearer $OPENAGENTS_TOKEN" \
-H 'Content-Type: application/json' \
-d '{
"name": "string",
"expected_revision": 1
}'
In the Rust SDK
Request a challenge to link your wallet
POST /v1/device/lightning-address/challenge · challengeDeviceLightningAddress
Uses your current account session. Wallet signatures are made locally; never send recovery words or private keys. Responses are not cached.
Sign-in: a bearer credential in the Authorization header.
appBearer: A WorkOS access JWT, live app sess_ session, or oa_sk_ sign-in key. Account-bound oak_ keys are accepted only where the operation declares them and their scopes permit it. API cookies are ignored.
Request body
Content type: application/json
Type: object
| Field | Type | Required | Description |
|---|---|---|---|
expected_revision | integer | Yes |
Response
200 — The current address state or a challenge to link your wallet.
Type: object
Errors
| Status | Meaning | Body |
|---|---|---|
| 400 | Check the request and wallet signature. | |
| 401 | Log in again to continue. | |
| 409 | Refresh the address revision and try again. | |
| 503 | Receiving is unavailable or has not been configured. |
Example
curl -X POST 'https://api.openagents.com/v1/device/lightning-address/challenge' \
-H "Authorization: Bearer $OPENAGENTS_TOKEN" \
-H 'Content-Type: application/json' \
-d '{
"expected_revision": 0
}'