Bwok on Nostr: # BTC USD btc_usd = [from your node] # Price of the product in USD. product_usd = ...
# BTC USD
btc_usd = [from your node]
# Price of the product in USD.
product_usd = 15.00
# Convert to sats
product_sats = (product_usd / btc_usd) * 100000000
# Format price to display with commas at hundreds place and sats units
product_sats_label = format(round(product_sats), ',') + " sats"
Published at
2024-06-25 03:57:35Event JSON
{
"id": "44948b6d50c521f221b61a366183e600d6f05ec6fd4057dd3ed4e52912e7c39c",
"pubkey": "dee97518077808091745015441953ad814c22d4eaeaba6996385a3d7dc3d191e",
"created_at": 1719287855,
"kind": 1,
"tags": [
[
"e",
"fcf5a8f5f062427c3b1044cf4a6448ff0f5ceb8a7f36e474746d49fb04f0668a",
"",
"root"
],
[
"p",
"50a9326de0b1aed1b364bf02affc4129fe320e27438e471acbb0605c81ab87bb"
]
],
"content": "# BTC USD\nbtc_usd = [from your node]\n\n# Price of the product in USD.\nproduct_usd = 15.00\n\n# Convert to sats\nproduct_sats = (product_usd / btc_usd) * 100000000\n\n# Format price to display with commas at hundreds place and sats units\nproduct_sats_label = format(round(product_sats), ',') + \" sats\"\n",
"sig": "6c0b533bd4994ecb229b0d30860d65d6cfc2e0c2a514a8b0c7baf7da993342c19aa9fe055a8da24a173395bcbab38a9e424902566f344ebb47495ea846333fcb"
}