Skip to Content
  • Docs
  • API
  • Stream
  • LN Markets
REST API
Get account GETGet unused Bitcoin address GETGenerate new Bitcoin address POSTGet notifications GETMark notifications as read PUT
Account

Get account

REST API

LN Markets offers a REST API to integrate with your program or trading bot.

Get unused Bitcoin address GET

Get your most recently generated Bitcoin deposit address that has not received a deposit yet. If you have none, a new one is generated in the format of…

GET/accountPrivate

Get your account: id, username, balance, synthetic USD balance, fee tier, email and linking public key.

Permissions: account:read

Response Body

OK

application/json
  1. response
  1. response
  2. …
username*string

Username of the user

Lengthlength <= 64
syntheticUsdBalance*number

Synthetic USD balance of the user (in dollars)

balance*number

Balance of the user

feeTier*integer

Fee tier of the user

Range-2147483648 <= value <= 2147483647
email*|

Email of the user

id*string

Unique identifier for this account

linkingPublicKey*|

Public key of the user

import { createHttpClient } from '@ln-markets/sdk/rest/v3'const client = createHttpClient({  key: 'your-key',  secret: 'your-secret',  passphrase: 'your-passphrase',})const result = await client.account.get()
{  "username": "satoshi",  "syntheticUsdBalance": 1337,  "balance": 69420,  "feeTier": 1,  "email": null,  "id": "1602a190-9dc0-48ff-9fb9-4b62f7270007",  "linkingPublicKey": "037b7c2587f823de3c62a639369b8c939bfb8f0bd40df58e9c1b6df63bcc88df4f"}
import { createHttpClient } from '@ln-markets/sdk/rest/v3'

const client = createHttpClient({
  key: 'your-key',
  secret: 'your-secret',
  passphrase: 'your-passphrase',
})

const result = await client.account.get()
{
  "username": "satoshi",
  "syntheticUsdBalance": 1337,
  "balance": 69420,
  "feeTier": 1,
  "email": null,
  "id": "1602a190-9dc0-48ff-9fb9-4b62f7270007",
  "linkingPublicKey": "037b7c2587f823de3c62a639369b8c939bfb8f0bd40df58e9c1b6df63bcc88df4f"
}