lbry-sdk/docs/api.json
2020-10-10 13:02:38 -04:00

5201 lines
No EOL
505 KiB
JSON

{
"main": {
"doc": "Ungrouped commands.",
"commands": [
{
"name": "ffmpeg_find",
"description": "Get ffmpeg installation information",
"arguments": [],
"returns": "(dict) Dictionary of ffmpeg information\n {\n 'available': (bool) found ffmpeg,\n 'which': (str) path to ffmpeg,\n 'analyze_audio_volume': (bool) should ffmpeg analyze audio\n }",
"examples": []
},
{
"name": "get",
"description": "Download stream from a LBRY name.",
"arguments": [
{
"name": "uri",
"type": "str",
"description": "uri of the content to download",
"is_required": false
},
{
"name": "file_name",
"type": "str",
"description": "specified name for the downloaded file, overrides the stream file name",
"is_required": false
},
{
"name": "download_directory",
"type": "str",
"description": "full path to the directory to download into",
"is_required": false
},
{
"name": "timeout",
"type": "int",
"description": "download timeout in number of seconds",
"is_required": false
},
{
"name": "save_file",
"type": "bool",
"description": "save the file to the downloads directory",
"is_required": false
},
{
"name": "wallet_id",
"type": "str",
"description": "wallet to check for claim purchase reciepts",
"is_required": false
}
],
"returns": " {\n \"streaming_url\": \"(str) url to stream the file using range requests\",\n \"completed\": \"(bool) true if download is completed\",\n \"file_name\": \"(str) name of file\",\n \"download_directory\": \"(str) download directory\",\n \"points_paid\": \"(float) credit paid to download file\",\n \"stopped\": \"(bool) true if download is stopped\",\n \"stream_hash\": \"(str) stream hash of file\",\n \"stream_name\": \"(str) stream name\",\n \"suggested_file_name\": \"(str) suggested file name\",\n \"sd_hash\": \"(str) sd hash of file\",\n \"download_path\": \"(str) download path of file\",\n \"mime_type\": \"(str) mime type of file\",\n \"key\": \"(str) key attached to file\",\n \"total_bytes_lower_bound\": \"(int) lower bound file size in bytes\",\n \"total_bytes\": \"(int) file upper bound size in bytes\",\n \"written_bytes\": \"(int) written size in bytes\",\n \"blobs_completed\": \"(int) number of fully downloaded blobs\",\n \"blobs_in_stream\": \"(int) total blobs on stream\",\n \"blobs_remaining\": \"(int) total blobs remaining to download\",\n \"status\": \"(str) downloader status\",\n \"claim_id\": \"(str) None if claim is not found else the claim id\",\n \"txid\": \"(str) None if claim is not found else the transaction id\",\n \"nout\": \"(int) None if claim is not found else the transaction output index\",\n \"outpoint\": \"(str) None if claim is not found else the tx and output\",\n \"metadata\": \"(dict) None if claim is not found else the claim metadata\",\n \"channel_claim_id\": \"(str) None if claim is not found or not signed\",\n \"channel_name\": \"(str) None if claim is not found or not signed\",\n \"claim_name\": \"(str) None if claim is not found else the claim name\",\n \"reflector_progress\": \"(int) reflector upload progress, 0 to 100\",\n \"uploading_to_reflector\": \"(bool) set to True when currently uploading to reflector\"\n }",
"examples": [
{
"title": "Get a file",
"curl": "curl -d'{\"method\": \"get\", \"params\": {\"uri\": \"astream#03d4002f8c09c4fac675ff2b3bb41bd6b3136f1b\"}}' http://localhost:5279/",
"lbrynet": "lbrynet get astream#03d4002f8c09c4fac675ff2b3bb41bd6b3136f1b",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"get\", \"params\": {\"uri\": \"astream#03d4002f8c09c4fac675ff2b3bb41bd6b3136f1b\"}}).json()",
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"added_on\": 1602347143,\n \"blobs_completed\": 1,\n \"blobs_in_stream\": 1,\n \"blobs_remaining\": 0,\n \"channel_claim_id\": \"2c20835e4289fe13bc88249efa4d20c2246b29d7\",\n \"channel_name\": \"@channel\",\n \"claim_id\": \"03d4002f8c09c4fac675ff2b3bb41bd6b3136f1b\",\n \"claim_name\": \"astream\",\n \"completed\": true,\n \"confirmations\": 3,\n \"content_fee\": null,\n \"download_directory\": \"/tmp/tmpi0ftuq_m\",\n \"download_path\": \"/tmp/tmpi0ftuq_m/tmpoqm09_cn\",\n \"file_name\": \"tmpoqm09_cn\",\n \"height\": 214,\n \"is_fully_reflected\": false,\n \"key\": \"4c7ff8e062dc8e3101d7a3a17806a66b\",\n \"metadata\": {\n \"source\": {\n \"hash\": \"fdbd8e75a67f29f701a4e040385e2e23986303ea10239211af907fcbb83578b3e417cb71ce646efd0819dd8c088de1bd\",\n \"media_type\": \"application/octet-stream\",\n \"name\": \"tmpoqm09_cn\",\n \"sd_hash\": \"f5dd1bd0df88ccbc2f016abaad0b3ffde5e87508dc7af1d964d51736fa260c5f25f2af741573d6bbd59ff458c554972b\",\n \"size\": \"11\"\n },\n \"stream_type\": \"binary\"\n },\n \"mime_type\": \"application/octet-stream\",\n \"nout\": 0,\n \"outpoint\": \"455ab61c9819a88dd7b0e7421251fc7883f0c9bafe790049db6e9716149e8e5e:0\",\n \"points_paid\": 0.0,\n \"protobuf\": \"01d7296b24c2204dfa9e2488bc13fe89425e83202c5adece9151b63be0b469b1230fcb3a108605f48e7b2c1d5b886d7d6737c93580ed7021901fdf627559f3dc724be3f50c66bc375956cccff2e91f74d9e839c0070a90010a8d010a30fdbd8e75a67f29f701a4e040385e2e23986303ea10239211af907fcbb83578b3e417cb71ce646efd0819dd8c088de1bd120b746d706f716d30395f636e180b22186170706c69636174696f6e2f6f637465742d73747265616d3230f5dd1bd0df88ccbc2f016abaad0b3ffde5e87508dc7af1d964d51736fa260c5f25f2af741573d6bbd59ff458c554972b\",\n \"purchase_receipt\": null,\n \"reflector_progress\": 0,\n \"sd_hash\": \"f5dd1bd0df88ccbc2f016abaad0b3ffde5e87508dc7af1d964d51736fa260c5f25f2af741573d6bbd59ff458c554972b\",\n \"status\": \"finished\",\n \"stopped\": true,\n \"stream_hash\": \"6719038b2faab800f1bc7a967ff6e23213db9447bea46effe25bdebf302098d581e4a3fbbe34b75dcd29f3dbe7f5a266\",\n \"stream_name\": \"tmpoqm09_cn\",\n \"streaming_url\": \"http://localhost:5280/stream/f5dd1bd0df88ccbc2f016abaad0b3ffde5e87508dc7af1d964d51736fa260c5f25f2af741573d6bbd59ff458c554972b\",\n \"suggested_file_name\": \"tmpoqm09_cn\",\n \"timestamp\": 1602347164,\n \"total_bytes\": 16,\n \"total_bytes_lower_bound\": 0,\n \"txid\": \"455ab61c9819a88dd7b0e7421251fc7883f0c9bafe790049db6e9716149e8e5e\",\n \"uploading_to_reflector\": false,\n \"written_bytes\": 11\n }\n}"
}
]
},
{
"name": "publish",
"description": "Create or replace a stream claim at a given name (use 'stream create/update' for more control).",
"arguments": [
{
"name": "name",
"type": "str",
"description": "name of the content (can only consist of a-z A-Z 0-9 and -(dash))",
"is_required": true
},
{
"name": "bid",
"type": "decimal",
"description": "amount to back the claim",
"is_required": false
},
{
"name": "file_path",
"type": "str",
"description": "path to file to be associated with name.",
"is_required": false
},
{
"name": "validate_file",
"type": "bool",
"description": "validate that the video container and encodings match common web browser support or that optimization succeeds if specified. FFmpeg is required",
"is_required": false
},
{
"name": "optimize_file",
"type": "bool",
"description": "transcode the video & audio if necessary to ensure common web browser support. FFmpeg is required",
"is_required": false
},
{
"name": "fee_currency",
"type": "string",
"description": "specify fee currency",
"is_required": false
},
{
"name": "fee_amount",
"type": "decimal",
"description": "content download fee",
"is_required": false
},
{
"name": "fee_address",
"type": "str",
"description": "address where to send fee payments, will use value from --claim_address if not provided",
"is_required": false
},
{
"name": "title",
"type": "str",
"description": "title of the publication",
"is_required": false
},
{
"name": "description",
"type": "str",
"description": "description of the publication",
"is_required": false
},
{
"name": "author",
"type": "str",
"description": "author of the publication. The usage for this field is not the same as for channels. The author field is used to credit an author who is not the publisher and is not represented by the channel. For example, a pdf file of 'The Odyssey' has an author of 'Homer' but may by published to a channel such as '@classics', or to no channel at all",
"is_required": false
},
{
"name": "tags",
"type": "list",
"description": "add content tags",
"is_required": false
},
{
"name": "languages",
"type": "list",
"description": "languages used by the channel, using RFC 5646 format, eg: for English `--languages=en` for Spanish (Spain) `--languages=es-ES` for Spanish (Mexican) `--languages=es-MX` for Chinese (Simplified) `--languages=zh-Hans` for Chinese (Traditional) `--languages=zh-Hant`",
"is_required": false
},
{
"name": "locations",
"type": "list",
"description": "locations relevant to the stream, consisting of 2 letter `country` code and a `state`, `city` and a postal `code` along with a `latitude` and `longitude`. for JSON RPC: pass a dictionary with aforementioned attributes as keys, eg: ... \"locations\": [{'country': 'US', 'state': 'NH'}] ... for command line: pass a colon delimited list with values in the following order: \"COUNTRY:STATE:CITY:CODE:LATITUDE:LONGITUDE\" making sure to include colon for blank values, for example to provide only the city: ... --locations=\"::Manchester\" with all values set: ... --locations=\"US:NH:Manchester:03101:42.990605:-71.460989\" optionally, you can just pass the \"LATITUDE:LONGITUDE\": ... --locations=\"42.990605:-71.460989\" finally, you can also pass JSON string of dictionary on the command line as you would via JSON RPC ... --locations=\"{'country': 'US', 'state': 'NH'}\"",
"is_required": false
},
{
"name": "license",
"type": "str",
"description": "publication license",
"is_required": false
},
{
"name": "license_url",
"type": "str",
"description": "publication license url",
"is_required": false
},
{
"name": "thumbnail_url",
"type": "str",
"description": "thumbnail url",
"is_required": false
},
{
"name": "release_time",
"type": "int",
"description": "original public release of content, seconds since UNIX epoch",
"is_required": false
},
{
"name": "width",
"type": "int",
"description": "image/video width, automatically calculated from media file",
"is_required": false
},
{
"name": "height",
"type": "int",
"description": "image/video height, automatically calculated from media file",
"is_required": false
},
{
"name": "duration",
"type": "int",
"description": "audio/video duration in seconds, automatically calculated",
"is_required": false
},
{
"name": "channel_id",
"type": "str",
"description": "claim id of the publisher channel",
"is_required": false
},
{
"name": "channel_name",
"type": "str",
"description": "name of publisher channel",
"is_required": false
},
{
"name": "channel_account_id",
"type": "str",
"description": "one or more account ids for accounts to look in for channel certificates, defaults to all accounts.",
"is_required": false
},
{
"name": "account_id",
"type": "str",
"description": "account to use for holding the transaction",
"is_required": false
},
{
"name": "wallet_id",
"type": "str",
"description": "restrict operation to specific wallet",
"is_required": false
},
{
"name": "funding_account_ids",
"type": "list",
"description": "ids of accounts to fund this transaction",
"is_required": false
},
{
"name": "claim_address",
"type": "str",
"description": "address where the claim is sent to, if not specified it will be determined automatically from the account",
"is_required": false
},
{
"name": "preview",
"type": "bool",
"description": "do not broadcast the transaction",
"is_required": false
},
{
"name": "blocking",
"type": "bool",
"description": "wait until transaction is in mempool",
"is_required": false
}
],
"returns": " {\n \"txid\": \"hash of transaction in hex\",\n \"height\": \"block where transaction was recorded\",\n \"inputs\": [\n {\n \"txid\": \"hash of transaction in hex\",\n \"nout\": \"position in the transaction\",\n \"height\": \"block where transaction was recorded\",\n \"amount\": \"value of the txo as a decimal\",\n \"address\": \"address of who can spend the txo\",\n \"confirmations\": \"number of confirmed blocks\",\n \"is_change\": \"payment to change address, only available when it can be determined\",\n \"is_received\": \"true if txo was sent from external account to this account\",\n \"is_spent\": \"true if txo is spent\",\n \"is_mine\": \"payment to one of your accounts, only available when it can be determined\",\n \"type\": \"one of 'claim', 'support' or 'purchase'\",\n \"name\": \"when type is 'claim' or 'support', this is the claim name\",\n \"claim_id\": \"when type is 'claim', 'support' or 'purchase', this is the claim id\",\n \"claim_op\": \"when type is 'claim', this determines if it is 'create' or 'update'\",\n \"value\": \"when type is 'claim' or 'support' with payload, this is the decoded protobuf payload\",\n \"value_type\": \"determines the type of the 'value' field: 'channel', 'stream', etc\",\n \"protobuf\": \"hex encoded raw protobuf version of 'value' field\",\n \"permanent_url\": \"when type is 'claim' or 'support', this is the long permanent claim URL\",\n \"claim\": \"for purchase outputs only, metadata of purchased claim\",\n \"reposted_claim\": \"for repost claims only, metadata of claim being reposted\",\n \"signing_channel\": \"for signed claims only, metadata of signing channel\",\n \"is_channel_signature_valid\": \"for signed claims only, whether signature is valid\",\n \"purchase_receipt\": \"metadata for the purchase transaction associated with this claim\"\n }\n ],\n \"outputs\": [\n {\n \"txid\": \"hash of transaction in hex\",\n \"nout\": \"position in the transaction\",\n \"height\": \"block where transaction was recorded\",\n \"amount\": \"value of the txo as a decimal\",\n \"address\": \"address of who can spend the txo\",\n \"confirmations\": \"number of confirmed blocks\",\n \"is_change\": \"payment to change address, only available when it can be determined\",\n \"is_received\": \"true if txo was sent from external account to this account\",\n \"is_spent\": \"true if txo is spent\",\n \"is_mine\": \"payment to one of your accounts, only available when it can be determined\",\n \"type\": \"one of 'claim', 'support' or 'purchase'\",\n \"name\": \"when type is 'claim' or 'support', this is the claim name\",\n \"claim_id\": \"when type is 'claim', 'support' or 'purchase', this is the claim id\",\n \"claim_op\": \"when type is 'claim', this determines if it is 'create' or 'update'\",\n \"value\": \"when type is 'claim' or 'support' with payload, this is the decoded protobuf payload\",\n \"value_type\": \"determines the type of the 'value' field: 'channel', 'stream', etc\",\n \"protobuf\": \"hex encoded raw protobuf version of 'value' field\",\n \"permanent_url\": \"when type is 'claim' or 'support', this is the long permanent claim URL\",\n \"claim\": \"for purchase outputs only, metadata of purchased claim\",\n \"reposted_claim\": \"for repost claims only, metadata of claim being reposted\",\n \"signing_channel\": \"for signed claims only, metadata of signing channel\",\n \"is_channel_signature_valid\": \"for signed claims only, whether signature is valid\",\n \"purchase_receipt\": \"metadata for the purchase transaction associated with this claim\"\n }\n ],\n \"total_input\": \"sum of inputs as a decimal\",\n \"total_output\": \"sum of outputs, sans fee, as a decimal\",\n \"total_fee\": \"fee amount\",\n \"hex\": \"entire transaction encoded in hex\"\n }",
"examples": [
{
"title": "Publish a file",
"curl": "curl -d'{\"method\": \"publish\", \"params\": {\"name\": \"a-new-stream\", \"bid\": \"1.0\", \"file_path\": \"/tmp/tmp1lqawwh6\", \"validate_file\": false, \"optimize_file\": false, \"tags\": [], \"languages\": [], \"locations\": [], \"channel_account_id\": [], \"funding_account_ids\": [], \"preview\": false, \"blocking\": false}}' http://localhost:5279/",
"lbrynet": "lbrynet publish a-new-stream --bid=1.0 --file_path=/tmp/tmp1lqawwh6",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"publish\", \"params\": {\"name\": \"a-new-stream\", \"bid\": \"1.0\", \"file_path\": \"/tmp/tmp1lqawwh6\", \"validate_file\": false, \"optimize_file\": false, \"tags\": [], \"languages\": [], \"locations\": [], \"channel_account_id\": [], \"funding_account_ids\": [], \"preview\": false, \"blocking\": false}}).json()",
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"height\": -2,\n \"hex\": \"0100000001ed4ed8fb84080c7b633d679f92d4286b05790a55f0976e1949197545f6cc610d010000006b483045022100bacc195ecd57d8f4fc5774542cb92ce9fec7c9369b314967338f9f52c10e1d8a0220018c8d97d57eb4faec2eaba60482b8d1066d17d3b6e7e3b7c22b36e3af33a126012103c7659bbbe345116221702d06f9d702355240f1b93efd0dd61d9107b6ec2f1be3ffffffff0200e1f50500000000bfb50c612d6e65772d73747265616d4c94000a90010a8d010a30fdbd8e75a67f29f701a4e040385e2e23986303ea10239211af907fcbb83578b3e417cb71ce646efd0819dd8c088de1bd120b746d70316c716177776836180b22186170706c69636174696f6e2f6f637465742d73747265616d32302cb8f1f95805af6f490d11a35248909a25ccf2f0304f8c58a1b76a8edd6e016dba7587da059c1322c481fcfb5859be4e6d7576a91451a7a0658e232c7efaf816224e16447f8e09f33288ace0b46217000000001976a9149ecfc9cd786d152fb1d734584231f10d357433e688ac00000000\",\n \"inputs\": [\n {\n \"address\": \"mpW1iYzQqMxFqphUGRf5WH5qE4TwbEaLYW\",\n \"amount\": \"4.947555\",\n \"confirmations\": 4,\n \"height\": 215,\n \"nout\": 1,\n \"timestamp\": 1602347164,\n \"txid\": \"0d61ccf645751949196e97f0550a79056b28d4929f673d637b0c0884fbd84eed\",\n \"type\": \"payment\"\n }\n ],\n \"outputs\": [\n {\n \"address\": \"mnxhqVKhui8nTy4Tnh482mJZkE9buh1Kyc\",\n \"amount\": \"1.0\",\n \"claim_id\": \"039ca47b10c13f9142cd0e9f275d9defa2259345\",\n \"claim_op\": \"create\",\n \"confirmations\": -2,\n \"height\": -2,\n \"meta\": {},\n \"name\": \"a-new-stream\",\n \"normalized_name\": \"a-new-stream\",\n \"nout\": 0,\n \"permanent_url\": \"lbry://a-new-stream#039ca47b10c13f9142cd0e9f275d9defa2259345\",\n \"timestamp\": null,\n \"txid\": \"a234311a403bf53c5b59f34256cbf477f9c778b6622980297129a2f2e4ef8090\",\n \"type\": \"claim\",\n \"value\": {\n \"source\": {\n \"hash\": \"fdbd8e75a67f29f701a4e040385e2e23986303ea10239211af907fcbb83578b3e417cb71ce646efd0819dd8c088de1bd\",\n \"media_type\": \"application/octet-stream\",\n \"name\": \"tmp1lqawwh6\",\n \"sd_hash\": \"2cb8f1f95805af6f490d11a35248909a25ccf2f0304f8c58a1b76a8edd6e016dba7587da059c1322c481fcfb5859be4e\",\n \"size\": \"11\"\n },\n \"stream_type\": \"binary\"\n },\n \"value_type\": \"stream\"\n },\n {\n \"address\": \"muzfykGZvSDahDdruKm3Ukeeu3Y4HXpTYv\",\n \"amount\": \"3.923448\",\n \"confirmations\": -2,\n \"height\": -2,\n \"nout\": 1,\n \"timestamp\": null,\n \"txid\": \"a234311a403bf53c5b59f34256cbf477f9c778b6622980297129a2f2e4ef8090\",\n \"type\": \"payment\"\n }\n ],\n \"total_fee\": \"0.024107\",\n \"total_input\": \"4.947555\",\n \"total_output\": \"4.923448\",\n \"txid\": \"a234311a403bf53c5b59f34256cbf477f9c778b6622980297129a2f2e4ef8090\"\n }\n}"
}
]
},
{
"name": "resolve",
"description": "Get the claim that a URL refers to.",
"arguments": [
{
"name": "urls",
"type": "str, list",
"description": "one or more urls to resolve",
"is_required": false
},
{
"name": "wallet_id",
"type": "str",
"description": "wallet to check for claim purchase reciepts",
"is_required": false
},
{
"name": "new_sdk_server",
"type": "str",
"description": "URL of the new SDK server (EXPERIMENTAL)",
"is_required": false
},
{
"name": "include_purchase_receipt",
"type": "bool",
"description": "lookup and include a receipt if this wallet has purchased the claim being resolved",
"is_required": false
},
{
"name": "include_is_my_output",
"type": "bool",
"description": "lookup and include a boolean indicating if claim being resolved is yours",
"is_required": false
},
{
"name": "include_sent_supports",
"type": "bool",
"description": "lookup and sum the total amount of supports you've made to this claim",
"is_required": false
},
{
"name": "include_sent_tips",
"type": "bool",
"description": "lookup and sum the total amount of tips you've made to this claim (only makes sense when claim is not yours)",
"is_required": false
},
{
"name": "include_received_tips",
"type": "bool",
"description": "lookup and sum the total amount of tips you've received to this claim (only makes sense when claim is yours)",
"is_required": false
}
],
"returns": "Dictionary of results, keyed by url\n '<url>': {\n If a resolution error occurs:\n 'error': Error message\n\n If the url resolves to a channel or a claim in a channel:\n 'certificate': {\n 'address': (str) claim address,\n 'amount': (float) claim amount,\n 'effective_amount': (float) claim amount including supports,\n 'claim_id': (str) claim id,\n 'claim_sequence': (int) claim sequence number (or -1 if unknown),\n 'decoded_claim': (bool) whether or not the claim value was decoded,\n 'height': (int) claim height,\n 'confirmations': (int) claim depth,\n 'timestamp': (int) timestamp of the block that included this claim tx,\n 'has_signature': (bool) included if decoded_claim\n 'name': (str) claim name,\n 'permanent_url': (str) permanent url of the certificate claim,\n 'supports: (list) list of supports [{'txid': (str) txid,\n 'nout': (int) nout,\n 'amount': (float) amount}],\n 'txid': (str) claim txid,\n 'nout': (str) claim nout,\n 'signature_is_valid': (bool), included if has_signature,\n 'value': ClaimDict if decoded, otherwise hex string\n }\n\n If the url resolves to a channel:\n 'claims_in_channel': (int) number of claims in the channel,\n\n If the url resolves to a claim:\n 'claim': {\n 'address': (str) claim address,\n 'amount': (float) claim amount,\n 'effective_amount': (float) claim amount including supports,\n 'claim_id': (str) claim id,\n 'claim_sequence': (int) claim sequence number (or -1 if unknown),\n 'decoded_claim': (bool) whether or not the claim value was decoded,\n 'height': (int) claim height,\n 'depth': (int) claim depth,\n 'has_signature': (bool) included if decoded_claim\n 'name': (str) claim name,\n 'permanent_url': (str) permanent url of the claim,\n 'channel_name': (str) channel name if claim is in a channel\n 'supports: (list) list of supports [{'txid': (str) txid,\n 'nout': (int) nout,\n 'amount': (float) amount}]\n 'txid': (str) claim txid,\n 'nout': (str) claim nout,\n 'signature_is_valid': (bool), included if has_signature,\n 'value': ClaimDict if decoded, otherwise hex string\n }\n }",
"examples": [
{
"title": "Resolve a claim",
"curl": "curl -d'{\"method\": \"resolve\", \"params\": {\"urls\": [\"astream#03d4002f8c09c4fac675ff2b3bb41bd6b3136f1b\"], \"include_purchase_receipt\": false, \"include_is_my_output\": false, \"include_sent_supports\": false, \"include_sent_tips\": false, \"include_received_tips\": false}}' http://localhost:5279/",
"lbrynet": "lbrynet resolve astream#03d4002f8c09c4fac675ff2b3bb41bd6b3136f1b",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"resolve\", \"params\": {\"urls\": [\"astream#03d4002f8c09c4fac675ff2b3bb41bd6b3136f1b\"], \"include_purchase_receipt\": false, \"include_is_my_output\": false, \"include_sent_supports\": false, \"include_sent_tips\": false, \"include_received_tips\": false}}).json()",
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"astream#03d4002f8c09c4fac675ff2b3bb41bd6b3136f1b\": {\n \"address\": \"muo3EZhx8VQtZsscvKLVCS2nk8tPeGSUKC\",\n \"amount\": \"1.0\",\n \"canonical_url\": \"lbry://@channel#2/astream#0\",\n \"claim_id\": \"03d4002f8c09c4fac675ff2b3bb41bd6b3136f1b\",\n \"claim_op\": \"update\",\n \"confirmations\": 3,\n \"height\": 214,\n \"is_channel_signature_valid\": true,\n \"meta\": {\n \"activation_height\": 213,\n \"creation_height\": 213,\n \"creation_timestamp\": 1602347164,\n \"effective_amount\": \"1.0\",\n \"expiration_height\": 263187,\n \"is_controlling\": true,\n \"reposted\": 0,\n \"support_amount\": \"0.0\",\n \"take_over_height\": 213,\n \"trending_global\": 0.0,\n \"trending_group\": 0,\n \"trending_local\": 0.0,\n \"trending_mixed\": 0.0\n },\n \"name\": \"astream\",\n \"normalized_name\": \"astream\",\n \"nout\": 0,\n \"permanent_url\": \"lbry://astream#03d4002f8c09c4fac675ff2b3bb41bd6b3136f1b\",\n \"short_url\": \"lbry://astream#0\",\n \"signing_channel\": {\n \"address\": \"mth8FNCBtmx5M92AtxUpWigDPaB1g2xNpZ\",\n \"amount\": \"1.0\",\n \"canonical_url\": \"lbry://@channel#2\",\n \"claim_id\": \"2c20835e4289fe13bc88249efa4d20c2246b29d7\",\n \"claim_op\": \"update\",\n \"confirmations\": 7,\n \"has_signing_key\": false,\n \"height\": 210,\n \"meta\": {\n \"activation_height\": 209,\n \"claims_in_channel\": 1,\n \"creation_height\": 209,\n \"creation_timestamp\": 1602347163,\n \"effective_amount\": \"1.0\",\n \"expiration_height\": 263183,\n \"is_controlling\": true,\n \"reposted\": 0,\n \"support_amount\": \"0.0\",\n \"take_over_height\": 209,\n \"trending_global\": 0.0,\n \"trending_group\": 0,\n \"trending_local\": 0.0,\n \"trending_mixed\": 0.0\n },\n \"name\": \"@channel\",\n \"normalized_name\": \"@channel\",\n \"nout\": 0,\n \"permanent_url\": \"lbry://@channel#2c20835e4289fe13bc88249efa4d20c2246b29d7\",\n \"short_url\": \"lbry://@channel#2\",\n \"timestamp\": 1602347163,\n \"txid\": \"db52235e2719bd2fe4e04d0c2de3c527fc84365f980fd5ce147a8d5725eb427c\",\n \"type\": \"claim\",\n \"value\": {\n \"public_key\": \"3056301006072a8648ce3d020106052b8104000a03420004bb438060971d65dfccc532c2c72357b802057d458a9143c2f863461ba8f5f79a512b770a19b80717467e0d0366e8097d3cf803a91609a2827d0701d6562e5a88\",\n \"public_key_id\": \"msagyzG92X562roXPRfSYQkmoNWzMYtZd8\",\n \"title\": \"New Channel\"\n },\n \"value_type\": \"channel\"\n },\n \"timestamp\": 1602347164,\n \"txid\": \"455ab61c9819a88dd7b0e7421251fc7883f0c9bafe790049db6e9716149e8e5e\",\n \"type\": \"claim\",\n \"value\": {\n \"source\": {\n \"hash\": \"fdbd8e75a67f29f701a4e040385e2e23986303ea10239211af907fcbb83578b3e417cb71ce646efd0819dd8c088de1bd\",\n \"media_type\": \"application/octet-stream\",\n \"name\": \"tmpoqm09_cn\",\n \"sd_hash\": \"f5dd1bd0df88ccbc2f016abaad0b3ffde5e87508dc7af1d964d51736fa260c5f25f2af741573d6bbd59ff458c554972b\",\n \"size\": \"11\"\n },\n \"stream_type\": \"binary\"\n },\n \"value_type\": \"stream\"\n }\n }\n}"
}
]
},
{
"name": "routing_table_get",
"description": "Get DHT routing information",
"arguments": [],
"returns": "(dict) dictionary containing routing and peer information\n {\n \"buckets\": {\n <bucket index>: [\n {\n \"address\": (str) peer address,\n \"udp_port\": (int) peer udp port,\n \"tcp_port\": (int) peer tcp port,\n \"node_id\": (str) peer node id,\n }\n ]\n },\n \"node_id\": (str) the local dht node id\n }",
"examples": []
},
{
"name": "status",
"description": "Get daemon status",
"arguments": [],
"returns": "(dict) lbrynet-daemon status\n {\n 'installation_id': (str) installation id - base58,\n 'is_running': (bool),\n 'skipped_components': (list) [names of skipped components (str)],\n 'startup_status': { Does not include components which have been skipped\n 'blob_manager': (bool),\n 'blockchain_headers': (bool),\n 'database': (bool),\n 'dht': (bool),\n 'exchange_rate_manager': (bool),\n 'hash_announcer': (bool),\n 'peer_protocol_server': (bool),\n 'file_manager': (bool),\n 'libtorrent_component': (bool),\n 'upnp': (bool),\n 'wallet': (bool),\n },\n 'connection_status': {\n 'code': (str) connection status code,\n 'message': (str) connection status message\n },\n 'blockchain_headers': {\n 'downloading_headers': (bool),\n 'download_progress': (float) 0-100.0\n },\n 'wallet': {\n 'connected': (str) host and port of the connected spv server,\n 'blocks': (int) local blockchain height,\n 'blocks_behind': (int) remote_height - local_height,\n 'best_blockhash': (str) block hash of most recent block,\n 'is_encrypted': (bool),\n 'is_locked': (bool),\n 'connected_servers': (list) [\n {\n 'host': (str) server hostname,\n 'port': (int) server port,\n 'latency': (int) milliseconds\n }\n ],\n },\n 'libtorrent_component': {\n 'running': (bool) libtorrent was detected and started successfully,\n },\n 'dht': {\n 'node_id': (str) lbry dht node id - hex encoded,\n 'peers_in_routing_table': (int) the number of peers in the routing table,\n },\n 'blob_manager': {\n 'finished_blobs': (int) number of finished blobs in the blob manager,\n 'connections': {\n 'incoming_bps': {\n <source ip and tcp port>: (int) bytes per second received,\n },\n 'outgoing_bps': {\n <destination ip and tcp port>: (int) bytes per second sent,\n },\n 'total_outgoing_mps': (float) megabytes per second sent,\n 'total_incoming_mps': (float) megabytes per second received,\n 'time': (float) timestamp\n }\n },\n 'hash_announcer': {\n 'announce_queue_size': (int) number of blobs currently queued to be announced\n },\n 'file_manager': {\n 'managed_files': (int) count of files in the stream manager,\n },\n 'upnp': {\n 'aioupnp_version': (str),\n 'redirects': {\n <TCP | UDP>: (int) external_port,\n },\n 'gateway': (str) manufacturer and model,\n 'dht_redirect_set': (bool),\n 'peer_redirect_set': (bool),\n 'external_ip': (str) external ip address,\n }\n }",
"examples": [
{
"title": "Get status",
"curl": "curl -d'{\"method\": \"status\", \"params\": {}}' http://localhost:5279/",
"lbrynet": "lbrynet status",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"status\", \"params\": {}}).json()",
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"blob_manager\": {\n \"connections\": {\n \"incoming_bps\": {},\n \"max_incoming_mbs\": 0.0,\n \"max_outgoing_mbs\": 0.0,\n \"outgoing_bps\": {},\n \"total_incoming_mbs\": 0.0,\n \"total_outgoing_mbs\": 0.0,\n \"total_received\": 0,\n \"total_sent\": 0\n },\n \"finished_blobs\": 0\n },\n \"connection_status\": {\n \"code\": \"network_connection\",\n \"message\": \"Your internet connection appears to have been interrupted\"\n },\n \"ffmpeg_status\": {\n \"analyze_audio_volume\": true,\n \"available\": true,\n \"which\": \"/usr/bin/ffmpeg\"\n },\n \"file_manager\": {\n \"managed_files\": 0\n },\n \"installation_id\": \"9fwEs1bvRyFsZut5FXiodUYkMNXx2iVpXCJsVA6Zj458cHt5sjExuA1WjLfV3LbbJc\",\n \"is_running\": true,\n \"skipped_components\": [\n \"dht\",\n \"upnp\",\n \"hash_announcer\",\n \"peer_protocol_server\"\n ],\n \"startup_status\": {\n \"blob_manager\": true,\n \"database\": true,\n \"exchange_rate_manager\": true,\n \"file_manager\": true,\n \"libtorrent_component\": true,\n \"wallet\": true,\n \"wallet_server_payments\": true\n },\n \"wallet\": {\n \"available_servers\": 1,\n \"best_blockhash\": \"4704f19c74b47c2c3b3fd282067ae5c1ee333acda3f914af32bda6883d45a986\",\n \"blocks\": 206,\n \"blocks_behind\": 0,\n \"connected\": \"127.0.0.1:50002\",\n \"connected_features\": {\n \"daily_fee\": \"0\",\n \"description\": \"\",\n \"donation_address\": \"\",\n \"genesis_hash\": \"6e3fcf1299d4ec5d79c3a4c91d624a4acf9e2e173d95a1a0504f677669687556\",\n \"hash_function\": \"sha256\",\n \"hosts\": {},\n \"payment_address\": \"\",\n \"protocol_max\": \"0.99.0\",\n \"protocol_min\": \"0.54.0\",\n \"pruning\": null,\n \"server_version\": \"0.82.0\",\n \"trending_algorithm\": \"zscore\"\n },\n \"headers_synchronization_progress\": 100,\n \"known_servers\": 1,\n \"servers\": [\n {\n \"availability\": true,\n \"host\": \"localhost\",\n \"latency\": 0.019847268995363265,\n \"port\": 50002\n }\n ]\n },\n \"wallet_server_payments\": {\n \"max_fee\": \"0.0\",\n \"running\": false\n }\n }\n}"
}
]
},
{
"name": "stop",
"description": "Stop lbrynet API server.",
"arguments": [],
"returns": "(string) Shutdown message",
"examples": []
},
{
"name": "version",
"description": "Get lbrynet API server version information",
"arguments": [],
"returns": "(dict) Dictionary of lbry version information\n {\n 'processor': (str) processor type,\n 'python_version': (str) python version,\n 'platform': (str) platform string,\n 'os_release': (str) os release string,\n 'os_system': (str) os name,\n 'version': (str) lbrynet version,\n 'build': (str) \"dev\" | \"qa\" | \"rc\" | \"release\",\n }",
"examples": [
{
"title": "Get version",
"curl": "curl -d'{\"method\": \"version\", \"params\": {}}' http://localhost:5279/",
"lbrynet": "lbrynet version",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"version\", \"params\": {}}).json()",
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"build\": \"dev\",\n \"desktop\": \"GNOME\",\n \"distro\": {\n \"codename\": \"xenial\",\n \"id\": \"ubuntu\",\n \"like\": \"debian\",\n \"version\": \"16.04\",\n \"version_parts\": {\n \"build_number\": \"\",\n \"major\": \"16\",\n \"minor\": \"04\"\n }\n },\n \"lbrynet_version\": \"0.82.0\",\n \"os_release\": \"4.4.0-116-generic\",\n \"os_system\": \"Linux\",\n \"platform\": \"Linux-4.4.0-116-generic-x86_64-with-Ubuntu-16.04-xenial\",\n \"processor\": \"x86_64\",\n \"python_version\": \"3.7.5\",\n \"version\": \"0.82.0\"\n }\n}"
}
]
}
]
},
"account": {
"doc": "Create, modify and inspect wallet accounts.",
"commands": [
{
"name": "account_add",
"description": "Add a previously created account from a seed, private key or public key (read-only).\nSpecify --single_key for single address or vanity address accounts.",
"arguments": [
{
"name": "account_name",
"type": "str",
"description": "name of the account to add",
"is_required": true
},
{
"name": "seed",
"type": "str",
"description": "seed to generate new account from",
"is_required": false
},
{
"name": "private_key",
"type": "str",
"description": "private key for new account",
"is_required": false
},
{
"name": "public_key",
"type": "str",
"description": "public key for new account",
"is_required": false
},
{
"name": "single_key",
"type": "bool",
"description": "create single key account, default is multi-key",
"is_required": false
},
{
"name": "wallet_id",
"type": "str",
"description": "restrict operation to specific wallet",
"is_required": false
}
],
"returns": " {\n \"id\": \"account_id\",\n \"is_default\": \"this account is used by default\",\n \"ledger\": \"name of crypto currency and network\",\n \"name\": \"optional account name\",\n \"seed\": \"human friendly words from which account can be recreated\",\n \"encrypted\": \"if account is encrypted\",\n \"private_key\": \"extended private key\",\n \"public_key\": \"extended public key\",\n \"address_generator\": \"settings for generating addresses\",\n \"modified_on\": \"date of last modification to account settings\"\n }",
"examples": [
{
"title": "Add an account from seed",
"curl": "curl -d'{\"method\": \"account_add\", \"params\": {\"account_name\": \"new account\", \"seed\": \"three educate eagle smooth trade cram tobacco decrease cannon situate movie hub\", \"single_key\": false}}' http://localhost:5279/",
"lbrynet": "lbrynet account add \"new account\" --seed=\"three educate eagle smooth trade cram tobacco decrease cannon situate movie hub\"",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"account_add\", \"params\": {\"account_name\": \"new account\", \"seed\": \"three educate eagle smooth trade cram tobacco decrease cannon situate movie hub\", \"single_key\": false}}).json()",
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"address_generator\": {\n \"change\": {\n \"gap\": 6,\n \"maximum_uses_per_address\": 1\n },\n \"name\": \"deterministic-chain\",\n \"receiving\": {\n \"gap\": 20,\n \"maximum_uses_per_address\": 1\n }\n },\n \"encrypted\": false,\n \"id\": \"mrZC8uh7yPXsNLp7cnKijCLfSf9zZiYiER\",\n \"is_default\": false,\n \"ledger\": \"lbc_regtest\",\n \"modified_on\": 1602347132,\n \"name\": \"new account\",\n \"private_key\": \"tprv8ZgxMBicQKsPdPBSZ4mFsbEgMhMUq3AXDp3x7gErF1xu5UCkjLwnWv1QpbgnVqXg86qizrGspJARPEwT8XbEqzGGKwKMuYHp5KdWyK6YfTx\",\n \"public_key\": \"tpubD6NzVbkrYhZ4WrDESiRrGztnvisQzNMRo7ejQCH9fHmHuxTXMjmNhQdGzhuEvkAA2j6kbUddUGJjwCySMh4mi9kaHY2U3CcYCSy5WnZhAe9\",\n \"seed\": \"three educate eagle smooth trade cram tobacco decrease cannon situate movie hub\"\n }\n}"
}
]
},
{
"name": "account_balance",
"description": "Return the balance of an account",
"arguments": [
{
"name": "account_id",
"type": "str",
"description": "If provided only the balance for this account will be given. Otherwise default account.",
"is_required": false
},
{
"name": "wallet_id",
"type": "str",
"description": "balance for specific wallet",
"is_required": false
},
{
"name": "confirmations",
"type": "int",
"description": "Only include transactions with this many confirmed blocks.",
"is_required": false
}
],
"returns": "(decimal) amount of lbry credits in wallet",
"examples": [
{
"title": "Get default account balance",
"curl": "curl -d'{\"method\": \"account_balance\", \"params\": {}}' http://localhost:5279/",
"lbrynet": "lbrynet account balance",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"account_balance\", \"params\": {}}).json()",
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"available\": \"7.999876\",\n \"reserved\": \"0.0\",\n \"reserved_subtotals\": {\n \"claims\": \"0.0\",\n \"supports\": \"0.0\",\n \"tips\": \"0.0\"\n },\n \"total\": \"7.999876\"\n }\n}"
},
{
"title": "Get balance for specific account by id",
"curl": "curl -d'{\"method\": \"account_balance\", \"params\": {\"account_id\": \"mrZC8uh7yPXsNLp7cnKijCLfSf9zZiYiER\"}}' http://localhost:5279/",
"lbrynet": "lbrynet account balance \"mrZC8uh7yPXsNLp7cnKijCLfSf9zZiYiER\"",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"account_balance\", \"params\": {\"account_id\": \"mrZC8uh7yPXsNLp7cnKijCLfSf9zZiYiER\"}}).json()",
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"available\": \"2.0\",\n \"reserved\": \"0.0\",\n \"reserved_subtotals\": {\n \"claims\": \"0.0\",\n \"supports\": \"0.0\",\n \"tips\": \"0.0\"\n },\n \"total\": \"2.0\"\n }\n}"
}
]
},
{
"name": "account_create",
"description": "Create a new account. Specify --single_key if you want to use\nthe same address for all transactions (not recommended).",
"arguments": [
{
"name": "account_name",
"type": "str",
"description": "name of the account to create",
"is_required": true
},
{
"name": "single_key",
"type": "bool",
"description": "create single key account, default is multi-key",
"is_required": false
},
{
"name": "wallet_id",
"type": "str",
"description": "restrict operation to specific wallet",
"is_required": false
}
],
"returns": " {\n \"id\": \"account_id\",\n \"is_default\": \"this account is used by default\",\n \"ledger\": \"name of crypto currency and network\",\n \"name\": \"optional account name\",\n \"seed\": \"human friendly words from which account can be recreated\",\n \"encrypted\": \"if account is encrypted\",\n \"private_key\": \"extended private key\",\n \"public_key\": \"extended public key\",\n \"address_generator\": \"settings for generating addresses\",\n \"modified_on\": \"date of last modification to account settings\"\n }",
"examples": [
{
"title": "Create an account",
"curl": "curl -d'{\"method\": \"account_create\", \"params\": {\"account_name\": \"generated account\", \"single_key\": false}}' http://localhost:5279/",
"lbrynet": "lbrynet account create \"generated account\"",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"account_create\", \"params\": {\"account_name\": \"generated account\", \"single_key\": false}}).json()",
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"address_generator\": {\n \"change\": {\n \"gap\": 6,\n \"maximum_uses_per_address\": 1\n },\n \"name\": \"deterministic-chain\",\n \"receiving\": {\n \"gap\": 20,\n \"maximum_uses_per_address\": 1\n }\n },\n \"encrypted\": false,\n \"id\": \"mrZC8uh7yPXsNLp7cnKijCLfSf9zZiYiER\",\n \"is_default\": false,\n \"ledger\": \"lbc_regtest\",\n \"modified_on\": 1602347132,\n \"name\": \"generated account\",\n \"private_key\": \"tprv8ZgxMBicQKsPdPBSZ4mFsbEgMhMUq3AXDp3x7gErF1xu5UCkjLwnWv1QpbgnVqXg86qizrGspJARPEwT8XbEqzGGKwKMuYHp5KdWyK6YfTx\",\n \"public_key\": \"tpubD6NzVbkrYhZ4WrDESiRrGztnvisQzNMRo7ejQCH9fHmHuxTXMjmNhQdGzhuEvkAA2j6kbUddUGJjwCySMh4mi9kaHY2U3CcYCSy5WnZhAe9\",\n \"seed\": \"three educate eagle smooth trade cram tobacco decrease cannon situate movie hub\"\n }\n}"
}
]
},
{
"name": "account_fund",
"description": "Transfer some amount (or --everything) to an account from another\naccount (can be the same account). Amounts are interpreted as LBC.\nYou can also spread the transfer across a number of --outputs (cannot\nbe used together with --everything).",
"arguments": [
{
"name": "to_account",
"type": "str",
"description": "send to this account",
"is_required": false
},
{
"name": "from_account",
"type": "str",
"description": "spend from this account",
"is_required": false
},
{
"name": "amount",
"type": "str",
"description": "the amount to transfer lbc",
"is_required": true
},
{
"name": "everything",
"type": "bool",
"description": "transfer everything (excluding claims), default: false.",
"is_required": false
},
{
"name": "outputs",
"type": "int",
"description": "split payment across many outputs, default: 1.",
"is_required": false
},
{
"name": "wallet_id",
"type": "str",
"description": "limit operation to specific wallet.",
"is_required": false
},
{
"name": "broadcast",
"type": "bool",
"description": "actually broadcast the transaction, default: false.",
"is_required": false
}
],
"returns": " {\n \"txid\": \"hash of transaction in hex\",\n \"height\": \"block where transaction was recorded\",\n \"inputs\": [\n {\n \"txid\": \"hash of transaction in hex\",\n \"nout\": \"position in the transaction\",\n \"height\": \"block where transaction was recorded\",\n \"amount\": \"value of the txo as a decimal\",\n \"address\": \"address of who can spend the txo\",\n \"confirmations\": \"number of confirmed blocks\",\n \"is_change\": \"payment to change address, only available when it can be determined\",\n \"is_received\": \"true if txo was sent from external account to this account\",\n \"is_spent\": \"true if txo is spent\",\n \"is_mine\": \"payment to one of your accounts, only available when it can be determined\",\n \"type\": \"one of 'claim', 'support' or 'purchase'\",\n \"name\": \"when type is 'claim' or 'support', this is the claim name\",\n \"claim_id\": \"when type is 'claim', 'support' or 'purchase', this is the claim id\",\n \"claim_op\": \"when type is 'claim', this determines if it is 'create' or 'update'\",\n \"value\": \"when type is 'claim' or 'support' with payload, this is the decoded protobuf payload\",\n \"value_type\": \"determines the type of the 'value' field: 'channel', 'stream', etc\",\n \"protobuf\": \"hex encoded raw protobuf version of 'value' field\",\n \"permanent_url\": \"when type is 'claim' or 'support', this is the long permanent claim URL\",\n \"claim\": \"for purchase outputs only, metadata of purchased claim\",\n \"reposted_claim\": \"for repost claims only, metadata of claim being reposted\",\n \"signing_channel\": \"for signed claims only, metadata of signing channel\",\n \"is_channel_signature_valid\": \"for signed claims only, whether signature is valid\",\n \"purchase_receipt\": \"metadata for the purchase transaction associated with this claim\"\n }\n ],\n \"outputs\": [\n {\n \"txid\": \"hash of transaction in hex\",\n \"nout\": \"position in the transaction\",\n \"height\": \"block where transaction was recorded\",\n \"amount\": \"value of the txo as a decimal\",\n \"address\": \"address of who can spend the txo\",\n \"confirmations\": \"number of confirmed blocks\",\n \"is_change\": \"payment to change address, only available when it can be determined\",\n \"is_received\": \"true if txo was sent from external account to this account\",\n \"is_spent\": \"true if txo is spent\",\n \"is_mine\": \"payment to one of your accounts, only available when it can be determined\",\n \"type\": \"one of 'claim', 'support' or 'purchase'\",\n \"name\": \"when type is 'claim' or 'support', this is the claim name\",\n \"claim_id\": \"when type is 'claim', 'support' or 'purchase', this is the claim id\",\n \"claim_op\": \"when type is 'claim', this determines if it is 'create' or 'update'\",\n \"value\": \"when type is 'claim' or 'support' with payload, this is the decoded protobuf payload\",\n \"value_type\": \"determines the type of the 'value' field: 'channel', 'stream', etc\",\n \"protobuf\": \"hex encoded raw protobuf version of 'value' field\",\n \"permanent_url\": \"when type is 'claim' or 'support', this is the long permanent claim URL\",\n \"claim\": \"for purchase outputs only, metadata of purchased claim\",\n \"reposted_claim\": \"for repost claims only, metadata of claim being reposted\",\n \"signing_channel\": \"for signed claims only, metadata of signing channel\",\n \"is_channel_signature_valid\": \"for signed claims only, whether signature is valid\",\n \"purchase_receipt\": \"metadata for the purchase transaction associated with this claim\"\n }\n ],\n \"total_input\": \"sum of inputs as a decimal\",\n \"total_output\": \"sum of outputs, sans fee, as a decimal\",\n \"total_fee\": \"fee amount\",\n \"hex\": \"entire transaction encoded in hex\"\n }",
"examples": [
{
"title": "Transfer 2 LBC from default account to specific account",
"curl": "curl -d'{\"method\": \"account_fund\", \"params\": {\"to_account\": \"mrZC8uh7yPXsNLp7cnKijCLfSf9zZiYiER\", \"amount\": \"2.0\", \"everything\": false, \"broadcast\": true}}' http://localhost:5279/",
"lbrynet": "lbrynet account fund --to_account=\"mrZC8uh7yPXsNLp7cnKijCLfSf9zZiYiER\" --amount=2.0 --broadcast",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"account_fund\", \"params\": {\"to_account\": \"mrZC8uh7yPXsNLp7cnKijCLfSf9zZiYiER\", \"amount\": \"2.0\", \"everything\": false, \"broadcast\": true}}).json()",
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"height\": -2,\n \"hex\": \"01000000017737909e752ad61334bdc01fe9db9b0ccfca83be5be5b383804f7e4fb429a8e7000000006a47304402204508041c314b3a961df9acd60c588895e4421734c7346089b35bf0e979542c93022025403336b85b441133a22106fa56b50932630ac1f499e743c429fa10a1703f8001210235b6cd33ef8081bd69e871ac88bdec3e426a30a29989e41d7670ce0fbaa31291ffffffff0200c2eb0b000000001976a914e2606d9ded2da067c7871abfe4c3e87f8d58f13088ac90d7ae2f000000001976a914cbf6689db925dc52503a84cf4ab8e626fb031e5788ac00000000\",\n \"inputs\": [\n {\n \"address\": \"mhT466YG6Y3x2Q3zBhvfjbuSBffYcSSYCA\",\n \"amount\": \"10.0\",\n \"confirmations\": 6,\n \"height\": 201,\n \"nout\": 0,\n \"timestamp\": 1602347162,\n \"txid\": \"e7a829b44f7e4f8083b3e55bbe83cacf0c9bdbe91fc0bd3413d62a759e903777\",\n \"type\": \"payment\"\n }\n ],\n \"outputs\": [\n {\n \"address\": \"n29vXMbPKzTvfhkCEiZK65XAo6qLBF58r1\",\n \"amount\": \"2.0\",\n \"confirmations\": -2,\n \"height\": -2,\n \"nout\": 0,\n \"timestamp\": null,\n \"txid\": \"7a5c9610fd69d73a634decc9e60adf58239968d40ae2fe59fcf9f0bf1ab03a69\",\n \"type\": \"payment\"\n },\n {\n \"address\": \"mz7QemZsW1NyZtnLt7tuhqyBEyBN4xNnEC\",\n \"amount\": \"7.999876\",\n \"confirmations\": -2,\n \"height\": -2,\n \"nout\": 1,\n \"timestamp\": null,\n \"txid\": \"7a5c9610fd69d73a634decc9e60adf58239968d40ae2fe59fcf9f0bf1ab03a69\",\n \"type\": \"payment\"\n }\n ],\n \"total_fee\": \"0.000124\",\n \"total_input\": \"10.0\",\n \"total_output\": \"9.999876\",\n \"txid\": \"7a5c9610fd69d73a634decc9e60adf58239968d40ae2fe59fcf9f0bf1ab03a69\"\n }\n}"
},
{
"title": "Spread LBC between multiple addresses",
"curl": "curl -d'{\"method\": \"account_fund\", \"params\": {\"to_account\": \"mrZC8uh7yPXsNLp7cnKijCLfSf9zZiYiER\", \"from_account\": \"mrZC8uh7yPXsNLp7cnKijCLfSf9zZiYiER\", \"amount\": \"1.5\", \"everything\": false, \"outputs\": 2, \"broadcast\": true}}' http://localhost:5279/",
"lbrynet": "lbrynet account fund --to_account=\"mrZC8uh7yPXsNLp7cnKijCLfSf9zZiYiER\" --from_account=\"mrZC8uh7yPXsNLp7cnKijCLfSf9zZiYiER\" --amount=1.5 --outputs=2 --broadcast",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"account_fund\", \"params\": {\"to_account\": \"mrZC8uh7yPXsNLp7cnKijCLfSf9zZiYiER\", \"from_account\": \"mrZC8uh7yPXsNLp7cnKijCLfSf9zZiYiER\", \"amount\": \"1.5\", \"everything\": false, \"outputs\": 2, \"broadcast\": true}}).json()",
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"height\": -2,\n \"hex\": \"0100000001693ab01abff0f9fc59fee20ad468992358df0ae6c9ec4d633ad769fd10965c7a000000006a47304402203c6df1c6d08140ed389259145826b9ba2c510670c070ecc68d1dedb61d1be7010220415be53ede17d0dcffe2b1c7d6a3305147fc9e9fb5a21c169c88c2180d3e1851012103524c8e2ac559c52214a58b3f7a01c659ab1e05db6ba58443aafcc0797b70fe95ffffffff03c0687804000000001976a914dc1fe1b384738f2e961de8225a9d37df7231e83e88acc0687804000000001976a914dc1fe1b384738f2e961de8225a9d37df7231e83e88ac6cb9fa02000000001976a914de6179465c79c0fa7e14d22b5c7929950a0ae51f88ac00000000\",\n \"inputs\": [\n {\n \"address\": \"n29vXMbPKzTvfhkCEiZK65XAo6qLBF58r1\",\n \"amount\": \"2.0\",\n \"confirmations\": 1,\n \"height\": 207,\n \"nout\": 0,\n \"timestamp\": 1602347163,\n \"txid\": \"7a5c9610fd69d73a634decc9e60adf58239968d40ae2fe59fcf9f0bf1ab03a69\",\n \"type\": \"payment\"\n }\n ],\n \"outputs\": [\n {\n \"address\": \"n1as9S2RihLw3XnLBZQsiKvUpYK6pviSZE\",\n \"amount\": \"0.75\",\n \"confirmations\": -2,\n \"height\": -2,\n \"nout\": 0,\n \"timestamp\": null,\n \"txid\": \"af528a2842cccb05e2b6541de1a83319b851cb8a5022c63ed4c1375f0bf3634d\",\n \"type\": \"payment\"\n },\n {\n \"address\": \"n1as9S2RihLw3XnLBZQsiKvUpYK6pviSZE\",\n \"amount\": \"0.75\",\n \"confirmations\": -2,\n \"height\": -2,\n \"nout\": 1,\n \"timestamp\": null,\n \"txid\": \"af528a2842cccb05e2b6541de1a83319b851cb8a5022c63ed4c1375f0bf3634d\",\n \"type\": \"payment\"\n },\n {\n \"address\": \"n1no5EWx5pNZRwtnDhzf46aoFqyELgfBXx\",\n \"amount\": \"0.499859\",\n \"confirmations\": -2,\n \"height\": -2,\n \"nout\": 2,\n \"timestamp\": null,\n \"txid\": \"af528a2842cccb05e2b6541de1a83319b851cb8a5022c63ed4c1375f0bf3634d\",\n \"type\": \"payment\"\n }\n ],\n \"total_fee\": \"0.000141\",\n \"total_input\": \"2.0\",\n \"total_output\": \"1.999859\",\n \"txid\": \"af528a2842cccb05e2b6541de1a83319b851cb8a5022c63ed4c1375f0bf3634d\"\n }\n}"
},
{
"title": "Transfer all LBC to a specified account",
"curl": "curl -d'{\"method\": \"account_fund\", \"params\": {\"from_account\": \"mrZC8uh7yPXsNLp7cnKijCLfSf9zZiYiER\", \"everything\": true, \"broadcast\": true}}' http://localhost:5279/",
"lbrynet": "lbrynet account fund --from_account=\"mrZC8uh7yPXsNLp7cnKijCLfSf9zZiYiER\" --everything --broadcast",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"account_fund\", \"params\": {\"from_account\": \"mrZC8uh7yPXsNLp7cnKijCLfSf9zZiYiER\", \"everything\": true, \"broadcast\": true}}).json()",
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"height\": -2,\n \"hex\": \"01000000034d63f30b5f37c1d43ec622508acb51b81933a8e11d54b6e205cbcc42288a52af000000006b483045022100ae0dd5aa00d2150a92280e43052e9bd067de1cd0411fe0ff0f891542f9447ae602200e002b679fc429bffc894189775156cfa7c238d23aecb0aba1a57b87926b7ad2012103e3d7a6abed73fcbcb732c293a92f24fe9e086d23633c7af3cbdb7a628177214bffffffff4d63f30b5f37c1d43ec622508acb51b81933a8e11d54b6e205cbcc42288a52af010000006a47304402207d31a5ce08e74a8ef30ce1234e8f05f7e998017e6977bfa55f95804967196c6202201d0a7557844384129c69ed0a5026970c3b1aac9a4590e020f7585f2d32767a70012103e3d7a6abed73fcbcb732c293a92f24fe9e086d23633c7af3cbdb7a628177214bffffffff4d63f30b5f37c1d43ec622508acb51b81933a8e11d54b6e205cbcc42288a52af020000006b483045022100f656402402d388b5aa19e152463ac93ec2d43c2bbfee418362e1782a9d02c6bd022064495e1a440cc5b2bd0cee521ac14aedef04fb6ee246fbd0ee85871aba96c4250121026064fd1225c75d704dc113fe4362a153e48b14c9bfe1183833b46b2abc474b46ffffffff015027eb0b000000001976a914429178dc65e997aed56709402cebb4f90eaf8b9588ac00000000\",\n \"inputs\": [\n {\n \"address\": \"n1as9S2RihLw3XnLBZQsiKvUpYK6pviSZE\",\n \"amount\": \"0.75\",\n \"confirmations\": 1,\n \"height\": 208,\n \"nout\": 0,\n \"timestamp\": 1602347163,\n \"txid\": \"af528a2842cccb05e2b6541de1a83319b851cb8a5022c63ed4c1375f0bf3634d\",\n \"type\": \"payment\"\n },\n {\n \"address\": \"n1as9S2RihLw3XnLBZQsiKvUpYK6pviSZE\",\n \"amount\": \"0.75\",\n \"confirmations\": 1,\n \"height\": 208,\n \"nout\": 1,\n \"timestamp\": 1602347163,\n \"txid\": \"af528a2842cccb05e2b6541de1a83319b851cb8a5022c63ed4c1375f0bf3634d\",\n \"type\": \"payment\"\n },\n {\n \"address\": \"n1no5EWx5pNZRwtnDhzf46aoFqyELgfBXx\",\n \"amount\": \"0.499859\",\n \"confirmations\": 1,\n \"height\": 208,\n \"nout\": 2,\n \"timestamp\": 1602347163,\n \"txid\": \"af528a2842cccb05e2b6541de1a83319b851cb8a5022c63ed4c1375f0bf3634d\",\n \"type\": \"payment\"\n }\n ],\n \"outputs\": [\n {\n \"address\": \"mmawAJ2k762cNvvrWWUvp8CbL5ecXsnFe4\",\n \"amount\": \"1.999604\",\n \"confirmations\": -2,\n \"height\": -2,\n \"nout\": 0,\n \"timestamp\": null,\n \"txid\": \"7a4a236462e50c8ae79d2a633afe1833f6a022b80dcf3f0adaafcf61203ce377\",\n \"type\": \"payment\"\n }\n ],\n \"total_fee\": \"0.000255\",\n \"total_input\": \"1.999859\",\n \"total_output\": \"1.999604\",\n \"txid\": \"7a4a236462e50c8ae79d2a633afe1833f6a022b80dcf3f0adaafcf61203ce377\"\n }\n}"
}
]
},
{
"name": "account_list",
"description": "List details of all of the accounts or a specific account.",
"arguments": [
{
"name": "account_id",
"type": "str",
"description": "If provided only the balance for this account will be given",
"is_required": false
},
{
"name": "wallet_id",
"type": "str",
"description": "accounts in specific wallet",
"is_required": false
},
{
"name": "confirmations",
"type": "int",
"description": "required confirmations (default: 0)",
"is_required": false
},
{
"name": "include_claims",
"type": "bool",
"description": "include claims, requires than a LBC account is specified (default: false)",
"is_required": false
},
{
"name": "show_seed",
"type": "bool",
"description": "show the seed for the account",
"is_required": false
},
{
"name": "page",
"type": "int",
"description": "page to return during paginating",
"is_required": false
},
{
"name": "page_size",
"type": "int",
"description": "number of items on page during pagination",
"is_required": false
}
],
"returns": " {\n \"page\": \"Page number of the current items.\",\n \"page_size\": \"Number of items to show on a page.\",\n \"total_pages\": \"Total number of pages.\",\n \"total_items\": \"Total number of items.\",\n \"items\": [\n {\n \"id\": \"account_id\",\n \"is_default\": \"this account is used by default\",\n \"ledger\": \"name of crypto currency and network\",\n \"name\": \"optional account name\",\n \"seed\": \"human friendly words from which account can be recreated\",\n \"encrypted\": \"if account is encrypted\",\n \"private_key\": \"extended private key\",\n \"public_key\": \"extended public key\",\n \"address_generator\": \"settings for generating addresses\",\n \"modified_on\": \"date of last modification to account settings\"\n }\n ]\n }",
"examples": [
{
"title": "List your accounts",
"curl": "curl -d'{\"method\": \"account_list\", \"params\": {\"include_claims\": false, \"show_seed\": false}}' http://localhost:5279/",
"lbrynet": "lbrynet account list",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"account_list\", \"params\": {\"include_claims\": false, \"show_seed\": false}}).json()",
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"items\": [\n {\n \"address_generator\": {\n \"change\": {\n \"gap\": 6,\n \"maximum_uses_per_address\": 1\n },\n \"name\": \"deterministic-chain\",\n \"receiving\": {\n \"gap\": 20,\n \"maximum_uses_per_address\": 1\n }\n },\n \"certificates\": 0,\n \"coins\": 10.0,\n \"encrypted\": false,\n \"id\": \"n12F5dP42LAjUmzLfsXKL9hWir9Moc4gFa\",\n \"is_default\": true,\n \"ledger\": \"lbc_regtest\",\n \"name\": \"Account #n12F5dP42LAjUmzLfsXKL9hWir9Moc4gFa\",\n \"public_key\": \"tpubD6NzVbkrYhZ4YFAumnSDC9Lnmbvr3CvZcNASuScmPCNxD9YuPEFX21bActkEX4ov5unEHmBNSoFaVwEzQfvsSNVkYCf4Jfesk3wYmkou4XD\",\n \"satoshis\": 1000000000\n }\n ],\n \"page\": 1,\n \"page_size\": 20,\n \"total_items\": 1,\n \"total_pages\": 1\n }\n}"
}
]
},
{
"name": "account_max_address_gap",
"description": "Finds ranges of consecutive addresses that are unused and returns the length\nof the longest such range: for change and receiving address chains. This is\nuseful to figure out ideal values to set for 'receiving_gap' and 'change_gap'\naccount settings.",
"arguments": [
{
"name": "account_id",
"type": "str",
"description": "account for which to get max gaps",
"is_required": true
},
{
"name": "wallet_id",
"type": "str",
"description": "restrict operation to specific wallet",
"is_required": false
}
],
"returns": "(map) maximum gap for change and receiving addresses",
"examples": []
},
{
"name": "account_remove",
"description": "Remove an existing account.",
"arguments": [
{
"name": "account_id",
"type": "str",
"description": "id of the account to remove",
"is_required": true
},
{
"name": "wallet_id",
"type": "str",
"description": "restrict operation to specific wallet",
"is_required": false
}
],
"returns": " {\n \"id\": \"account_id\",\n \"is_default\": \"this account is used by default\",\n \"ledger\": \"name of crypto currency and network\",\n \"name\": \"optional account name\",\n \"seed\": \"human friendly words from which account can be recreated\",\n \"encrypted\": \"if account is encrypted\",\n \"private_key\": \"extended private key\",\n \"public_key\": \"extended public key\",\n \"address_generator\": \"settings for generating addresses\",\n \"modified_on\": \"date of last modification to account settings\"\n }",
"examples": [
{
"title": "Remove an account",
"curl": "curl -d'{\"method\": \"account_remove\", \"params\": {\"account_id\": \"mrZC8uh7yPXsNLp7cnKijCLfSf9zZiYiER\"}}' http://localhost:5279/",
"lbrynet": "lbrynet account remove mrZC8uh7yPXsNLp7cnKijCLfSf9zZiYiER",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"account_remove\", \"params\": {\"account_id\": \"mrZC8uh7yPXsNLp7cnKijCLfSf9zZiYiER\"}}).json()",
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"address_generator\": {\n \"change\": {\n \"gap\": 6,\n \"maximum_uses_per_address\": 1\n },\n \"name\": \"deterministic-chain\",\n \"receiving\": {\n \"gap\": 20,\n \"maximum_uses_per_address\": 1\n }\n },\n \"encrypted\": false,\n \"id\": \"mrZC8uh7yPXsNLp7cnKijCLfSf9zZiYiER\",\n \"is_default\": false,\n \"ledger\": \"lbc_regtest\",\n \"modified_on\": 1602347132,\n \"name\": \"generated account\",\n \"private_key\": \"tprv8ZgxMBicQKsPdPBSZ4mFsbEgMhMUq3AXDp3x7gErF1xu5UCkjLwnWv1QpbgnVqXg86qizrGspJARPEwT8XbEqzGGKwKMuYHp5KdWyK6YfTx\",\n \"public_key\": \"tpubD6NzVbkrYhZ4WrDESiRrGztnvisQzNMRo7ejQCH9fHmHuxTXMjmNhQdGzhuEvkAA2j6kbUddUGJjwCySMh4mi9kaHY2U3CcYCSy5WnZhAe9\",\n \"seed\": \"three educate eagle smooth trade cram tobacco decrease cannon situate movie hub\"\n }\n}"
}
]
},
{
"name": "account_send",
"description": "Send the same number of credits to multiple addresses from a specific account (or default account).",
"arguments": [
{
"name": "account_id",
"type": "str",
"description": "account to fund the transaction",
"is_required": false
},
{
"name": "wallet_id",
"type": "str",
"description": "restrict operation to specific wallet",
"is_required": false
},
{
"name": "preview",
"type": "bool",
"description": "do not broadcast the transaction",
"is_required": false
},
{
"name": "blocking",
"type": "bool",
"description": "wait until tx has synced",
"is_required": false
}
],
"returns": " {\n \"txid\": \"hash of transaction in hex\",\n \"height\": \"block where transaction was recorded\",\n \"inputs\": [\n {\n \"txid\": \"hash of transaction in hex\",\n \"nout\": \"position in the transaction\",\n \"height\": \"block where transaction was recorded\",\n \"amount\": \"value of the txo as a decimal\",\n \"address\": \"address of who can spend the txo\",\n \"confirmations\": \"number of confirmed blocks\",\n \"is_change\": \"payment to change address, only available when it can be determined\",\n \"is_received\": \"true if txo was sent from external account to this account\",\n \"is_spent\": \"true if txo is spent\",\n \"is_mine\": \"payment to one of your accounts, only available when it can be determined\",\n \"type\": \"one of 'claim', 'support' or 'purchase'\",\n \"name\": \"when type is 'claim' or 'support', this is the claim name\",\n \"claim_id\": \"when type is 'claim', 'support' or 'purchase', this is the claim id\",\n \"claim_op\": \"when type is 'claim', this determines if it is 'create' or 'update'\",\n \"value\": \"when type is 'claim' or 'support' with payload, this is the decoded protobuf payload\",\n \"value_type\": \"determines the type of the 'value' field: 'channel', 'stream', etc\",\n \"protobuf\": \"hex encoded raw protobuf version of 'value' field\",\n \"permanent_url\": \"when type is 'claim' or 'support', this is the long permanent claim URL\",\n \"claim\": \"for purchase outputs only, metadata of purchased claim\",\n \"reposted_claim\": \"for repost claims only, metadata of claim being reposted\",\n \"signing_channel\": \"for signed claims only, metadata of signing channel\",\n \"is_channel_signature_valid\": \"for signed claims only, whether signature is valid\",\n \"purchase_receipt\": \"metadata for the purchase transaction associated with this claim\"\n }\n ],\n \"outputs\": [\n {\n \"txid\": \"hash of transaction in hex\",\n \"nout\": \"position in the transaction\",\n \"height\": \"block where transaction was recorded\",\n \"amount\": \"value of the txo as a decimal\",\n \"address\": \"address of who can spend the txo\",\n \"confirmations\": \"number of confirmed blocks\",\n \"is_change\": \"payment to change address, only available when it can be determined\",\n \"is_received\": \"true if txo was sent from external account to this account\",\n \"is_spent\": \"true if txo is spent\",\n \"is_mine\": \"payment to one of your accounts, only available when it can be determined\",\n \"type\": \"one of 'claim', 'support' or 'purchase'\",\n \"name\": \"when type is 'claim' or 'support', this is the claim name\",\n \"claim_id\": \"when type is 'claim', 'support' or 'purchase', this is the claim id\",\n \"claim_op\": \"when type is 'claim', this determines if it is 'create' or 'update'\",\n \"value\": \"when type is 'claim' or 'support' with payload, this is the decoded protobuf payload\",\n \"value_type\": \"determines the type of the 'value' field: 'channel', 'stream', etc\",\n \"protobuf\": \"hex encoded raw protobuf version of 'value' field\",\n \"permanent_url\": \"when type is 'claim' or 'support', this is the long permanent claim URL\",\n \"claim\": \"for purchase outputs only, metadata of purchased claim\",\n \"reposted_claim\": \"for repost claims only, metadata of claim being reposted\",\n \"signing_channel\": \"for signed claims only, metadata of signing channel\",\n \"is_channel_signature_valid\": \"for signed claims only, whether signature is valid\",\n \"purchase_receipt\": \"metadata for the purchase transaction associated with this claim\"\n }\n ],\n \"total_input\": \"sum of inputs as a decimal\",\n \"total_output\": \"sum of outputs, sans fee, as a decimal\",\n \"total_fee\": \"fee amount\",\n \"hex\": \"entire transaction encoded in hex\"\n }",
"examples": []
},
{
"name": "account_set",
"description": "Change various settings on an account.",
"arguments": [
{
"name": "account_id",
"type": "str",
"description": "id of the account to change",
"is_required": true
},
{
"name": "wallet_id",
"type": "str",
"description": "restrict operation to specific wallet",
"is_required": false
},
{
"name": "default",
"type": "bool",
"description": "make this account the default",
"is_required": false
},
{
"name": "new_name",
"type": "str",
"description": "new name for the account",
"is_required": false
},
{
"name": "receiving_gap",
"type": "int",
"description": "set the gap for receiving addresses",
"is_required": false
},
{
"name": "receiving_max_uses",
"type": "int",
"description": "set the maximum number of times to use a receiving address",
"is_required": false
},
{
"name": "change_gap",
"type": "int",
"description": "set the gap for change addresses",
"is_required": false
},
{
"name": "change_max_uses",
"type": "int",
"description": "set the maximum number of times to use a change address",
"is_required": false
}
],
"returns": " {\n \"id\": \"account_id\",\n \"is_default\": \"this account is used by default\",\n \"ledger\": \"name of crypto currency and network\",\n \"name\": \"optional account name\",\n \"seed\": \"human friendly words from which account can be recreated\",\n \"encrypted\": \"if account is encrypted\",\n \"private_key\": \"extended private key\",\n \"public_key\": \"extended public key\",\n \"address_generator\": \"settings for generating addresses\",\n \"modified_on\": \"date of last modification to account settings\"\n }",
"examples": [
{
"title": "Modify maximum number of times a change address can be reused",
"curl": "curl -d'{\"method\": \"account_set\", \"params\": {\"account_id\": \"mrZC8uh7yPXsNLp7cnKijCLfSf9zZiYiER\", \"default\": false, \"change_max_uses\": 10}}' http://localhost:5279/",
"lbrynet": "lbrynet account set mrZC8uh7yPXsNLp7cnKijCLfSf9zZiYiER --change_max_uses=10",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"account_set\", \"params\": {\"account_id\": \"mrZC8uh7yPXsNLp7cnKijCLfSf9zZiYiER\", \"default\": false, \"change_max_uses\": 10}}).json()",
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"address_generator\": {\n \"change\": {\n \"gap\": 6,\n \"maximum_uses_per_address\": 10\n },\n \"name\": \"deterministic-chain\",\n \"receiving\": {\n \"gap\": 20,\n \"maximum_uses_per_address\": 1\n }\n },\n \"encrypted\": false,\n \"id\": \"mrZC8uh7yPXsNLp7cnKijCLfSf9zZiYiER\",\n \"is_default\": false,\n \"ledger\": \"lbc_regtest\",\n \"modified_on\": 1602347132,\n \"name\": \"new account\",\n \"private_key\": \"tprv8ZgxMBicQKsPdPBSZ4mFsbEgMhMUq3AXDp3x7gErF1xu5UCkjLwnWv1QpbgnVqXg86qizrGspJARPEwT8XbEqzGGKwKMuYHp5KdWyK6YfTx\",\n \"public_key\": \"tpubD6NzVbkrYhZ4WrDESiRrGztnvisQzNMRo7ejQCH9fHmHuxTXMjmNhQdGzhuEvkAA2j6kbUddUGJjwCySMh4mi9kaHY2U3CcYCSy5WnZhAe9\",\n \"seed\": \"three educate eagle smooth trade cram tobacco decrease cannon situate movie hub\"\n }\n}"
}
]
}
]
},
"address": {
"doc": "List, generate and verify addresses.",
"commands": [
{
"name": "address_is_mine",
"description": "Checks if an address is associated with the current wallet.",
"arguments": [
{
"name": "address",
"type": "str",
"description": "address to check",
"is_required": true
},
{
"name": "account_id",
"type": "str",
"description": "id of the account to use",
"is_required": false
},
{
"name": "wallet_id",
"type": "str",
"description": "restrict operation to specific wallet",
"is_required": false
}
],
"returns": "(bool) true, if address is associated with current wallet",
"examples": [
{
"title": "Check if address is mine",
"curl": "curl -d'{\"method\": \"address_is_mine\", \"params\": {\"address\": \"n1WWyHtbpT3W1eB2TD6VU7hX4yJTvQCLaZ\"}}' http://localhost:5279/",
"lbrynet": "lbrynet address is_mine n1WWyHtbpT3W1eB2TD6VU7hX4yJTvQCLaZ",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"address_is_mine\", \"params\": {\"address\": \"n1WWyHtbpT3W1eB2TD6VU7hX4yJTvQCLaZ\"}}).json()",
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": true\n}"
}
]
},
{
"name": "address_list",
"description": "List account addresses or details of single address.",
"arguments": [
{
"name": "address",
"type": "str",
"description": "just show details for single address",
"is_required": false
},
{
"name": "account_id",
"type": "str",
"description": "id of the account to use",
"is_required": false
},
{
"name": "wallet_id",
"type": "str",
"description": "restrict operation to specific wallet",
"is_required": false
},
{
"name": "page",
"type": "int",
"description": "page to return during paginating",
"is_required": false
},
{
"name": "page_size",
"type": "int",
"description": "number of items on page during pagination",
"is_required": false
}
],
"returns": " {\n \"page\": \"Page number of the current items.\",\n \"page_size\": \"Number of items to show on a page.\",\n \"total_pages\": \"Total number of pages.\",\n \"total_items\": \"Total number of items.\",\n \"items\": [\n \"an address in base58\"\n ]\n }",
"examples": [
{
"title": "List addresses in default account",
"curl": "curl -d'{\"method\": \"address_list\", \"params\": {}}' http://localhost:5279/",
"lbrynet": "lbrynet address list",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"address_list\", \"params\": {}}).json()",
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"items\": [\n {\n \"account\": \"mrZC8uh7yPXsNLp7cnKijCLfSf9zZiYiER\",\n \"address\": \"mfjNbstnsVa48XhDnSPSapQbY9fvpKyZsK\",\n \"pubkey\": \"tpubDA9GDAntyJu4KoN4BTMNAoj8pX5bCRB5UyJFayZPdnGTJGLqGQBGpZWqKqQNjsazhWxXLQ8kb29PAVw8EZPkTtePEfa42Zoy9HvewqkgRn8\",\n \"used_times\": 0\n },\n {\n \"account\": \"mrZC8uh7yPXsNLp7cnKijCLfSf9zZiYiER\",\n \"address\": \"mgN7AAkBk9PPCWzvRAkjRJMb8cDm7n8xAj\",\n \"pubkey\": \"tpubDA9GDAntyJu4wKnmUnJudm6w1NJFiWtKRo16GZ2FS3L7gJX8Bbyzpr9VWQTG4V7CJ8Y1mwN9pWktzrZyq8WrVLmJeWZLR8k68mhKNjCzhs9\",\n \"used_times\": 0\n },\n {\n \"account\": \"mrZC8uh7yPXsNLp7cnKijCLfSf9zZiYiER\",\n \"address\": \"mgU3YrLxEiyVsR28JgMLtXEEb3fZ7WMsqu\",\n \"pubkey\": \"tpubDA9GDAntyJu4m8kzE92TADkZkY4fmwviDsNSB424oz6pNF61dyCrjr1uTTUjRHxNaTE1UNHR3vC9kgSmvFrojyXDceetd29Nh7m7dABx9Ds\",\n \"used_times\": 0\n },\n {\n \"account\": \"mrZC8uh7yPXsNLp7cnKijCLfSf9zZiYiER\",\n \"address\": \"mhSMZAqJ8mFEJfG3tuBEAcFet1A3vxm7hY\",\n \"pubkey\": \"tpubDA9GDAntyJu4JT7yq3n8p3VoXHUiE5G6xxJcwhe4sQnqeWiPt58NoWarBVSU3iNueQsUJjWv5m2VJKLttip74HFmg7An9p57MFt7uLJS5DY\",\n \"used_times\": 0\n },\n {\n \"account\": \"mrZC8uh7yPXsNLp7cnKijCLfSf9zZiYiER\",\n \"address\": \"mhanDQpEg1EdBqohwe47izzHx3viBdBYE6\",\n \"pubkey\": \"tpubDA9GDAntyJu4JatiSGaXvHmKiJvr2kgWq6XdREhXW2y3UP5d7yABCt1333g1bY7bydNYhZpMXB6CmPEZkUo8TcJCfdczBFmxaDH7ke1RrGt\",\n \"used_times\": 0\n },\n {\n \"account\": \"mrZC8uh7yPXsNLp7cnKijCLfSf9zZiYiER\",\n \"address\": \"mhhPr1vwRNVxUdKXefg3CknqE8vVAMH7d6\",\n \"pubkey\": \"tpubDA9GDAntyJu4KsY2PQHNWrswXoBCTfVNc91hTev8CzDh8QiYpjL1x3Pfehv6niSDtuVCKapTs16eaU94RQqBE8gujFMzqKEq8CgtsqarGi3\",\n \"used_times\": 0\n },\n {\n \"account\": \"mrZC8uh7yPXsNLp7cnKijCLfSf9zZiYiER\",\n \"address\": \"mjVKBbRWvJ7j2RrS6ytmf3b3bS6Xpc4GST\",\n \"pubkey\": \"tpubDA9GDAntyJu4QexZzQzAm2EN52KFRXGELiMqbY8SwthMUreny7zf1ggVFZveA8U6o2sMSa6bof28qqCg7G5As6aXKKBHCzEre3saVkWNhqn\",\n \"used_times\": 0\n },\n {\n \"account\": \"mrZC8uh7yPXsNLp7cnKijCLfSf9zZiYiER\",\n \"address\": \"mmVwQBy9fRfjCnAAPxjeAepkGsrFtKbu7j\",\n \"pubkey\": \"tpubDA9GDAntyJu4UbDaRcJbyKWUyiADBrrmD2GKV7qyF1vPRCwpShWdF1M5Zf6i5kEbj9LkbQdAJNyCtSnqTq6HmbNjrFvSLDf2xzQMNXKcmQj\",\n \"used_times\": 0\n },\n {\n \"account\": \"mrZC8uh7yPXsNLp7cnKijCLfSf9zZiYiER\",\n \"address\": \"mmZae3dpvRLrkbDYGtbUub5VCKwRSD1759\",\n \"pubkey\": \"tpubDA9GDAntyJu4U2NGzZJBKU9NtznxWZKCsrj91kv37E1do2AizKzrrbP3R49BXZ1jKsHFCPs29icvBmVPqZbyMrgzia6ZLFNiCXgssHPTvsg\",\n \"used_times\": 0\n },\n {\n \"account\": \"mrZC8uh7yPXsNLp7cnKijCLfSf9zZiYiER\",\n \"address\": \"mmsCgEHQheLZAv3R5rrSGaxoGrpkdoAhQ3\",\n \"pubkey\": \"tpubDA9GDAntyJu4FwufEJZGndGSWHx48mxDg5JTH792QDTqdH6KYsgiLbnNit1C5YdNsHAjh35BDSWTiXprF9aZQBQupfdpb3Kj44GynksM8pK\",\n \"used_times\": 0\n },\n {\n \"account\": \"mrZC8uh7yPXsNLp7cnKijCLfSf9zZiYiER\",\n \"address\": \"mn8edzFP13a9qsT3xhBFUz49sZvNYuDCGE\",\n \"pubkey\": \"tpubDA9GDAntyJu4EZQrTFjZMbb3CyJESKnCfpb1y6mA9bGf9Y5ESU4CR9KxYJACejKt459tZH4pWEdHmd4DRzhfSyL1bwgbTeQPu6QCQST6qp7\",\n \"used_times\": 0\n },\n {\n \"account\": \"mrZC8uh7yPXsNLp7cnKijCLfSf9zZiYiER\",\n \"address\": \"mqR9pHCGeD9H1AjD4BagjSRevcdZH2jKce\",\n \"pubkey\": \"tpubDA9GDAntyJu4Y15wW9HaBaYsPhxDXnyUmu5HkKH7vbBwbDkYVjFJEa1iT59eZX1ET4yw47iZXTVitP1rLEyiRX36M7uKzUGVnVqrLiDwjcg\",\n \"used_times\": 0\n },\n {\n \"account\": \"mrZC8uh7yPXsNLp7cnKijCLfSf9zZiYiER\",\n \"address\": \"mrFZgVvdJRACFyapQT6U2kYYssxtEBhsJN\",\n \"pubkey\": \"tpubDA9GDAntyJu4g6YSmmC5ASxUGPcqB6Pwr1RPT7LEtfBeEJAtVCH54WSTnMjH3hZCPMfiYKTNgwEvkWiUpampD95omcQyph26DC2eaeC2UtH\",\n \"used_times\": 0\n },\n {\n \"account\": \"mrZC8uh7yPXsNLp7cnKijCLfSf9zZiYiER\",\n \"address\": \"mraWt7Xiyf6pvfhAjRLHXyJHz38JwWcg9e\",\n \"pubkey\": \"tpubDA9GDAntyJu4jvZbhhLgmjyHwiFFWRhdC5BECWWDbfRbRAWgm3C1yc3mKkRQYqTYGnHTeRnqqAX7C6sfjYfpendk2S6V1TZpAYFN6CNoV3X\",\n \"used_times\": 0\n },\n {\n \"account\": \"mrZC8uh7yPXsNLp7cnKijCLfSf9zZiYiER\",\n \"address\": \"mtqUMLDLuPELeJutd4Y4uxYD9PKBGuXRbh\",\n \"pubkey\": \"tpubDA9GDAntyJu4qY3XmFuJ1BQVVvZ7XWKYcnbnk96isfswPHPJ4DHguYbLtg8HzCU2KQ9DgxdQHfDaJXmsWNYcm5C6wHqFw9B9EToaBbsdXLs\",\n \"used_times\": 0\n },\n {\n \"account\": \"mrZC8uh7yPXsNLp7cnKijCLfSf9zZiYiER\",\n \"address\": \"mutNYuAqUSmrrQkgFvQe7WD9jTZ2QVwyqu\",\n \"pubkey\": \"tpubDA9GDAntyJu4ctpMETHCrwzt6f6K4q2MSvXMzRprvAfW1AoRvaYWUKBD91KPdCVKLmhfpfdRnSmMLnzC52vL9B8EF1QUkxM5ogs4idd544Y\",\n \"used_times\": 0\n },\n {\n \"account\": \"mrZC8uh7yPXsNLp7cnKijCLfSf9zZiYiER\",\n \"address\": \"mwvV51bCLS7qHBgEiWaxXaQzYSu7YNzavG\",\n \"pubkey\": \"tpubDA9GDAntyJu4yJ7Y5PVcgCQobvtVdQ6H8VQQhCKK37CjjYbsbfRzNrjV7xbWAVscjxp98mEKi85KFtEx5r9qtWuAcLXczsmBTpyz9cZ5gg5\",\n \"used_times\": 0\n },\n {\n \"account\": \"mrZC8uh7yPXsNLp7cnKijCLfSf9zZiYiER\",\n \"address\": \"myAxgFakEd6UeZEsD4tdKsLrF9zywY87TK\",\n \"pubkey\": \"tpubDA9GDAntyJu521sVo8GSGip4wjT3Ab6FHTxnz8RpMZk952yKz5Q8Pac2UWPoh6gMzHP6DVZrcyBTRTh6UyoK8HJ8gWYVpPaUJMQb7FzaDBY\",\n \"used_times\": 0\n },\n {\n \"account\": \"mrZC8uh7yPXsNLp7cnKijCLfSf9zZiYiER\",\n \"address\": \"n1DF88zcKpApebq5z2VGaSjDt3qkaS9N6X\",\n \"pubkey\": \"tpubDA9GDAntyJu4PC52ogGuoLn7sSftHW67VQAhDY248EPzQ9BzA1ChiPfXghrbiNHNCrNrj8Dezm3o9xg26jAvqyDjRbmBCJ1LBdsE6BFQ4YV\",\n \"used_times\": 0\n },\n {\n \"account\": \"mrZC8uh7yPXsNLp7cnKijCLfSf9zZiYiER\",\n \"address\": \"n1no5EWx5pNZRwtnDhzf46aoFqyELgfBXx\",\n \"pubkey\": \"tpubDA9GDAntyJu4RgYXP3AEGcZ6xo6v3XQBLA93hNuzSLvEHZ1tv42mPgsbqpu8bM77Hg7EGjNwENtazUsN4MQ5zEnKyjbRhB3WRSxWxsbE7ea\",\n \"used_times\": 0\n }\n ],\n \"page\": 1,\n \"page_size\": 20,\n \"total_items\": 53,\n \"total_pages\": 3\n }\n}"
},
{
"title": "List addresses in specified account",
"curl": "curl -d'{\"method\": \"address_list\", \"params\": {\"account_id\": \"mrZC8uh7yPXsNLp7cnKijCLfSf9zZiYiER\"}}' http://localhost:5279/",
"lbrynet": "lbrynet address list --account_id=\"mrZC8uh7yPXsNLp7cnKijCLfSf9zZiYiER\"",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"address_list\", \"params\": {\"account_id\": \"mrZC8uh7yPXsNLp7cnKijCLfSf9zZiYiER\"}}).json()",
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"items\": [\n {\n \"account\": \"mrZC8uh7yPXsNLp7cnKijCLfSf9zZiYiER\",\n \"address\": \"mfjNbstnsVa48XhDnSPSapQbY9fvpKyZsK\",\n \"pubkey\": \"tpubDA9GDAntyJu4KoN4BTMNAoj8pX5bCRB5UyJFayZPdnGTJGLqGQBGpZWqKqQNjsazhWxXLQ8kb29PAVw8EZPkTtePEfa42Zoy9HvewqkgRn8\",\n \"used_times\": 0\n },\n {\n \"account\": \"mrZC8uh7yPXsNLp7cnKijCLfSf9zZiYiER\",\n \"address\": \"mgN7AAkBk9PPCWzvRAkjRJMb8cDm7n8xAj\",\n \"pubkey\": \"tpubDA9GDAntyJu4wKnmUnJudm6w1NJFiWtKRo16GZ2FS3L7gJX8Bbyzpr9VWQTG4V7CJ8Y1mwN9pWktzrZyq8WrVLmJeWZLR8k68mhKNjCzhs9\",\n \"used_times\": 0\n },\n {\n \"account\": \"mrZC8uh7yPXsNLp7cnKijCLfSf9zZiYiER\",\n \"address\": \"mgU3YrLxEiyVsR28JgMLtXEEb3fZ7WMsqu\",\n \"pubkey\": \"tpubDA9GDAntyJu4m8kzE92TADkZkY4fmwviDsNSB424oz6pNF61dyCrjr1uTTUjRHxNaTE1UNHR3vC9kgSmvFrojyXDceetd29Nh7m7dABx9Ds\",\n \"used_times\": 0\n },\n {\n \"account\": \"mrZC8uh7yPXsNLp7cnKijCLfSf9zZiYiER\",\n \"address\": \"mhSMZAqJ8mFEJfG3tuBEAcFet1A3vxm7hY\",\n \"pubkey\": \"tpubDA9GDAntyJu4JT7yq3n8p3VoXHUiE5G6xxJcwhe4sQnqeWiPt58NoWarBVSU3iNueQsUJjWv5m2VJKLttip74HFmg7An9p57MFt7uLJS5DY\",\n \"used_times\": 0\n },\n {\n \"account\": \"mrZC8uh7yPXsNLp7cnKijCLfSf9zZiYiER\",\n \"address\": \"mhanDQpEg1EdBqohwe47izzHx3viBdBYE6\",\n \"pubkey\": \"tpubDA9GDAntyJu4JatiSGaXvHmKiJvr2kgWq6XdREhXW2y3UP5d7yABCt1333g1bY7bydNYhZpMXB6CmPEZkUo8TcJCfdczBFmxaDH7ke1RrGt\",\n \"used_times\": 0\n },\n {\n \"account\": \"mrZC8uh7yPXsNLp7cnKijCLfSf9zZiYiER\",\n \"address\": \"mhhPr1vwRNVxUdKXefg3CknqE8vVAMH7d6\",\n \"pubkey\": \"tpubDA9GDAntyJu4KsY2PQHNWrswXoBCTfVNc91hTev8CzDh8QiYpjL1x3Pfehv6niSDtuVCKapTs16eaU94RQqBE8gujFMzqKEq8CgtsqarGi3\",\n \"used_times\": 0\n },\n {\n \"account\": \"mrZC8uh7yPXsNLp7cnKijCLfSf9zZiYiER\",\n \"address\": \"mjVKBbRWvJ7j2RrS6ytmf3b3bS6Xpc4GST\",\n \"pubkey\": \"tpubDA9GDAntyJu4QexZzQzAm2EN52KFRXGELiMqbY8SwthMUreny7zf1ggVFZveA8U6o2sMSa6bof28qqCg7G5As6aXKKBHCzEre3saVkWNhqn\",\n \"used_times\": 0\n },\n {\n \"account\": \"mrZC8uh7yPXsNLp7cnKijCLfSf9zZiYiER\",\n \"address\": \"mmVwQBy9fRfjCnAAPxjeAepkGsrFtKbu7j\",\n \"pubkey\": \"tpubDA9GDAntyJu4UbDaRcJbyKWUyiADBrrmD2GKV7qyF1vPRCwpShWdF1M5Zf6i5kEbj9LkbQdAJNyCtSnqTq6HmbNjrFvSLDf2xzQMNXKcmQj\",\n \"used_times\": 0\n },\n {\n \"account\": \"mrZC8uh7yPXsNLp7cnKijCLfSf9zZiYiER\",\n \"address\": \"mmZae3dpvRLrkbDYGtbUub5VCKwRSD1759\",\n \"pubkey\": \"tpubDA9GDAntyJu4U2NGzZJBKU9NtznxWZKCsrj91kv37E1do2AizKzrrbP3R49BXZ1jKsHFCPs29icvBmVPqZbyMrgzia6ZLFNiCXgssHPTvsg\",\n \"used_times\": 0\n },\n {\n \"account\": \"mrZC8uh7yPXsNLp7cnKijCLfSf9zZiYiER\",\n \"address\": \"mmsCgEHQheLZAv3R5rrSGaxoGrpkdoAhQ3\",\n \"pubkey\": \"tpubDA9GDAntyJu4FwufEJZGndGSWHx48mxDg5JTH792QDTqdH6KYsgiLbnNit1C5YdNsHAjh35BDSWTiXprF9aZQBQupfdpb3Kj44GynksM8pK\",\n \"used_times\": 0\n },\n {\n \"account\": \"mrZC8uh7yPXsNLp7cnKijCLfSf9zZiYiER\",\n \"address\": \"mn8edzFP13a9qsT3xhBFUz49sZvNYuDCGE\",\n \"pubkey\": \"tpubDA9GDAntyJu4EZQrTFjZMbb3CyJESKnCfpb1y6mA9bGf9Y5ESU4CR9KxYJACejKt459tZH4pWEdHmd4DRzhfSyL1bwgbTeQPu6QCQST6qp7\",\n \"used_times\": 0\n },\n {\n \"account\": \"mrZC8uh7yPXsNLp7cnKijCLfSf9zZiYiER\",\n \"address\": \"mqR9pHCGeD9H1AjD4BagjSRevcdZH2jKce\",\n \"pubkey\": \"tpubDA9GDAntyJu4Y15wW9HaBaYsPhxDXnyUmu5HkKH7vbBwbDkYVjFJEa1iT59eZX1ET4yw47iZXTVitP1rLEyiRX36M7uKzUGVnVqrLiDwjcg\",\n \"used_times\": 0\n },\n {\n \"account\": \"mrZC8uh7yPXsNLp7cnKijCLfSf9zZiYiER\",\n \"address\": \"mrFZgVvdJRACFyapQT6U2kYYssxtEBhsJN\",\n \"pubkey\": \"tpubDA9GDAntyJu4g6YSmmC5ASxUGPcqB6Pwr1RPT7LEtfBeEJAtVCH54WSTnMjH3hZCPMfiYKTNgwEvkWiUpampD95omcQyph26DC2eaeC2UtH\",\n \"used_times\": 0\n },\n {\n \"account\": \"mrZC8uh7yPXsNLp7cnKijCLfSf9zZiYiER\",\n \"address\": \"mraWt7Xiyf6pvfhAjRLHXyJHz38JwWcg9e\",\n \"pubkey\": \"tpubDA9GDAntyJu4jvZbhhLgmjyHwiFFWRhdC5BECWWDbfRbRAWgm3C1yc3mKkRQYqTYGnHTeRnqqAX7C6sfjYfpendk2S6V1TZpAYFN6CNoV3X\",\n \"used_times\": 0\n },\n {\n \"account\": \"mrZC8uh7yPXsNLp7cnKijCLfSf9zZiYiER\",\n \"address\": \"mtqUMLDLuPELeJutd4Y4uxYD9PKBGuXRbh\",\n \"pubkey\": \"tpubDA9GDAntyJu4qY3XmFuJ1BQVVvZ7XWKYcnbnk96isfswPHPJ4DHguYbLtg8HzCU2KQ9DgxdQHfDaJXmsWNYcm5C6wHqFw9B9EToaBbsdXLs\",\n \"used_times\": 0\n },\n {\n \"account\": \"mrZC8uh7yPXsNLp7cnKijCLfSf9zZiYiER\",\n \"address\": \"mutNYuAqUSmrrQkgFvQe7WD9jTZ2QVwyqu\",\n \"pubkey\": \"tpubDA9GDAntyJu4ctpMETHCrwzt6f6K4q2MSvXMzRprvAfW1AoRvaYWUKBD91KPdCVKLmhfpfdRnSmMLnzC52vL9B8EF1QUkxM5ogs4idd544Y\",\n \"used_times\": 0\n },\n {\n \"account\": \"mrZC8uh7yPXsNLp7cnKijCLfSf9zZiYiER\",\n \"address\": \"mwvV51bCLS7qHBgEiWaxXaQzYSu7YNzavG\",\n \"pubkey\": \"tpubDA9GDAntyJu4yJ7Y5PVcgCQobvtVdQ6H8VQQhCKK37CjjYbsbfRzNrjV7xbWAVscjxp98mEKi85KFtEx5r9qtWuAcLXczsmBTpyz9cZ5gg5\",\n \"used_times\": 0\n },\n {\n \"account\": \"mrZC8uh7yPXsNLp7cnKijCLfSf9zZiYiER\",\n \"address\": \"myAxgFakEd6UeZEsD4tdKsLrF9zywY87TK\",\n \"pubkey\": \"tpubDA9GDAntyJu521sVo8GSGip4wjT3Ab6FHTxnz8RpMZk952yKz5Q8Pac2UWPoh6gMzHP6DVZrcyBTRTh6UyoK8HJ8gWYVpPaUJMQb7FzaDBY\",\n \"used_times\": 0\n },\n {\n \"account\": \"mrZC8uh7yPXsNLp7cnKijCLfSf9zZiYiER\",\n \"address\": \"n1DF88zcKpApebq5z2VGaSjDt3qkaS9N6X\",\n \"pubkey\": \"tpubDA9GDAntyJu4PC52ogGuoLn7sSftHW67VQAhDY248EPzQ9BzA1ChiPfXghrbiNHNCrNrj8Dezm3o9xg26jAvqyDjRbmBCJ1LBdsE6BFQ4YV\",\n \"used_times\": 0\n },\n {\n \"account\": \"mrZC8uh7yPXsNLp7cnKijCLfSf9zZiYiER\",\n \"address\": \"n1no5EWx5pNZRwtnDhzf46aoFqyELgfBXx\",\n \"pubkey\": \"tpubDA9GDAntyJu4RgYXP3AEGcZ6xo6v3XQBLA93hNuzSLvEHZ1tv42mPgsbqpu8bM77Hg7EGjNwENtazUsN4MQ5zEnKyjbRhB3WRSxWxsbE7ea\",\n \"used_times\": 0\n }\n ],\n \"page\": 1,\n \"page_size\": 20,\n \"total_items\": 26,\n \"total_pages\": 2\n }\n}"
}
]
},
{
"name": "address_unused",
"description": "Return an address containing no balance, will create\na new address if there is none.",
"arguments": [
{
"name": "account_id",
"type": "str",
"description": "id of the account to use",
"is_required": false
},
{
"name": "wallet_id",
"type": "str",
"description": "restrict operation to specific wallet",
"is_required": false
}
],
"returns": " \"an address in base58\"",
"examples": [
{
"title": "Get an unused address",
"curl": "curl -d'{\"method\": \"address_unused\", \"params\": {}}' http://localhost:5279/",
"lbrynet": "lbrynet address unused",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"address_unused\", \"params\": {}}).json()",
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": \"n1WWyHtbpT3W1eB2TD6VU7hX4yJTvQCLaZ\"\n}"
}
]
}
]
},
"blob": {
"doc": "Blob management.",
"commands": [
{
"name": "blob_announce",
"description": "Announce blobs to the DHT",
"arguments": [
{
"name": "blob_hash",
"type": "str",
"description": "announce a blob, specified by blob_hash",
"is_required": false
},
{
"name": "stream_hash",
"type": "str",
"description": "announce all blobs associated with stream_hash",
"is_required": false
},
{
"name": "sd_hash",
"type": "str",
"description": "announce all blobs associated with sd_hash and the sd_hash itself",
"is_required": false
}
],
"returns": "(bool) true if successful",
"examples": []
},
{
"name": "blob_delete",
"description": "Delete a blob",
"arguments": [
{
"name": "blob_hash",
"type": "str",
"description": "blob hash of the blob to delete",
"is_required": true
}
],
"returns": "(str) Success/fail message",
"examples": [
{
"title": "Delete a blob",
"curl": "curl -d'{\"method\": \"blob_delete\", \"params\": {\"blob_hash\": \"b029ae2f6897987809ce2fa84bb87588c958cb70f64a51e0b65557d93010383ef066c2fe4fd94a8e46589e3e2fb14652\"}}' http://localhost:5279/",
"lbrynet": "lbrynet blob delete b029ae2f6897987809ce2fa84bb87588c958cb70f64a51e0b65557d93010383ef066c2fe4fd94a8e46589e3e2fb14652",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"blob_delete\", \"params\": {\"blob_hash\": \"b029ae2f6897987809ce2fa84bb87588c958cb70f64a51e0b65557d93010383ef066c2fe4fd94a8e46589e3e2fb14652\"}}).json()",
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": \"Deleted b029ae2f6897987809ce2fa84bb87588c958cb70f64a51e0b65557d93010383ef066c2fe4fd94a8e46589e3e2fb14652\"\n}"
}
]
},
{
"name": "blob_get",
"description": "Download and return a blob",
"arguments": [
{
"name": "blob_hash",
"type": "str",
"description": "blob hash of the blob to get",
"is_required": true
},
{
"name": "timeout",
"type": "int",
"description": "timeout in number of seconds",
"is_required": false
}
],
"returns": "(str) Success/Fail message or (dict) decoded data",
"examples": []
},
{
"name": "blob_list",
"description": "Returns blob hashes. If not given filters, returns all blobs known by the blob manager",
"arguments": [
{
"name": "needed",
"type": "bool",
"description": "only return needed blobs",
"is_required": false
},
{
"name": "finished",
"type": "bool",
"description": "only return finished blobs",
"is_required": false
},
{
"name": "uri",
"type": "str",
"description": "filter blobs by stream in a uri",
"is_required": false
},
{
"name": "stream_hash",
"type": "str",
"description": "filter blobs by stream hash",
"is_required": false
},
{
"name": "sd_hash",
"type": "str",
"description": "filter blobs by sd hash",
"is_required": false
},
{
"name": "page",
"type": "int",
"description": "page to return during paginating",
"is_required": false
},
{
"name": "page_size",
"type": "int",
"description": "number of items on page during pagination",
"is_required": false
}
],
"returns": "(list) List of blob hashes",
"examples": [
{
"title": "List your local blobs",
"curl": "curl -d'{\"method\": \"blob_list\", \"params\": {\"needed\": false, \"finished\": false}}' http://localhost:5279/",
"lbrynet": "lbrynet blob list",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"blob_list\", \"params\": {\"needed\": false, \"finished\": false}}).json()",
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"items\": [\n \"b029ae2f6897987809ce2fa84bb87588c958cb70f64a51e0b65557d93010383ef066c2fe4fd94a8e46589e3e2fb14652\",\n \"70bc4ff167487bf172fbde83889c210f43578eb4b24a93fc708157dbee3e8a4ef8dcc8800d964803d8e21ad03ac32fd7\",\n \"8bd6e7458594581fe20ab834247bb23c87943d28b219d350ce32532cdfed237193ae9ed2c867ccdfa53371936d84647d\",\n \"f5dd1bd0df88ccbc2f016abaad0b3ffde5e87508dc7af1d964d51736fa260c5f25f2af741573d6bbd59ff458c554972b\"\n ],\n \"page\": 1,\n \"page_size\": 20,\n \"total_items\": 4,\n \"total_pages\": 1\n }\n}"
}
]
},
{
"name": "blob_reflect",
"description": "Reflects specified blobs",
"arguments": [
{
"name": "reflector_server",
"type": "str",
"description": "reflector address",
"is_required": false
}
],
"returns": "(list) reflected blob hashes",
"examples": []
},
{
"name": "blob_reflect_all",
"description": "Reflects all saved blobs",
"arguments": [],
"returns": "(bool) true if successful",
"examples": []
}
]
},
"channel": {
"doc": "Create, update, abandon and list your channel claims.",
"commands": [
{
"name": "channel_abandon",
"description": "Abandon one of my channel claims.",
"arguments": [
{
"name": "claim_id",
"type": "str",
"description": "claim_id of the claim to abandon",
"is_required": false
},
{
"name": "txid",
"type": "str",
"description": "txid of the claim to abandon",
"is_required": false
},
{
"name": "nout",
"type": "int",
"description": "nout of the claim to abandon",
"is_required": false
},
{
"name": "account_id",
"type": "str",
"description": "id of the account to use",
"is_required": false
},
{
"name": "wallet_id",
"type": "str",
"description": "restrict operation to specific wallet",
"is_required": false
},
{
"name": "preview",
"type": "bool",
"description": "do not broadcast the transaction",
"is_required": false
},
{
"name": "blocking",
"type": "bool",
"description": "wait until abandon is in mempool",
"is_required": false
}
],
"returns": " {\n \"txid\": \"hash of transaction in hex\",\n \"height\": \"block where transaction was recorded\",\n \"inputs\": [\n {\n \"txid\": \"hash of transaction in hex\",\n \"nout\": \"position in the transaction\",\n \"height\": \"block where transaction was recorded\",\n \"amount\": \"value of the txo as a decimal\",\n \"address\": \"address of who can spend the txo\",\n \"confirmations\": \"number of confirmed blocks\",\n \"is_change\": \"payment to change address, only available when it can be determined\",\n \"is_received\": \"true if txo was sent from external account to this account\",\n \"is_spent\": \"true if txo is spent\",\n \"is_mine\": \"payment to one of your accounts, only available when it can be determined\",\n \"type\": \"one of 'claim', 'support' or 'purchase'\",\n \"name\": \"when type is 'claim' or 'support', this is the claim name\",\n \"claim_id\": \"when type is 'claim', 'support' or 'purchase', this is the claim id\",\n \"claim_op\": \"when type is 'claim', this determines if it is 'create' or 'update'\",\n \"value\": \"when type is 'claim' or 'support' with payload, this is the decoded protobuf payload\",\n \"value_type\": \"determines the type of the 'value' field: 'channel', 'stream', etc\",\n \"protobuf\": \"hex encoded raw protobuf version of 'value' field\",\n \"permanent_url\": \"when type is 'claim' or 'support', this is the long permanent claim URL\",\n \"claim\": \"for purchase outputs only, metadata of purchased claim\",\n \"reposted_claim\": \"for repost claims only, metadata of claim being reposted\",\n \"signing_channel\": \"for signed claims only, metadata of signing channel\",\n \"is_channel_signature_valid\": \"for signed claims only, whether signature is valid\",\n \"purchase_receipt\": \"metadata for the purchase transaction associated with this claim\"\n }\n ],\n \"outputs\": [\n {\n \"txid\": \"hash of transaction in hex\",\n \"nout\": \"position in the transaction\",\n \"height\": \"block where transaction was recorded\",\n \"amount\": \"value of the txo as a decimal\",\n \"address\": \"address of who can spend the txo\",\n \"confirmations\": \"number of confirmed blocks\",\n \"is_change\": \"payment to change address, only available when it can be determined\",\n \"is_received\": \"true if txo was sent from external account to this account\",\n \"is_spent\": \"true if txo is spent\",\n \"is_mine\": \"payment to one of your accounts, only available when it can be determined\",\n \"type\": \"one of 'claim', 'support' or 'purchase'\",\n \"name\": \"when type is 'claim' or 'support', this is the claim name\",\n \"claim_id\": \"when type is 'claim', 'support' or 'purchase', this is the claim id\",\n \"claim_op\": \"when type is 'claim', this determines if it is 'create' or 'update'\",\n \"value\": \"when type is 'claim' or 'support' with payload, this is the decoded protobuf payload\",\n \"value_type\": \"determines the type of the 'value' field: 'channel', 'stream', etc\",\n \"protobuf\": \"hex encoded raw protobuf version of 'value' field\",\n \"permanent_url\": \"when type is 'claim' or 'support', this is the long permanent claim URL\",\n \"claim\": \"for purchase outputs only, metadata of purchased claim\",\n \"reposted_claim\": \"for repost claims only, metadata of claim being reposted\",\n \"signing_channel\": \"for signed claims only, metadata of signing channel\",\n \"is_channel_signature_valid\": \"for signed claims only, whether signature is valid\",\n \"purchase_receipt\": \"metadata for the purchase transaction associated with this claim\"\n }\n ],\n \"total_input\": \"sum of inputs as a decimal\",\n \"total_output\": \"sum of outputs, sans fee, as a decimal\",\n \"total_fee\": \"fee amount\",\n \"hex\": \"entire transaction encoded in hex\"\n }",
"examples": [
{
"title": "Abandon a channel claim",
"curl": "curl -d'{\"method\": \"channel_abandon\", \"params\": {\"claim_id\": \"2c20835e4289fe13bc88249efa4d20c2246b29d7\", \"preview\": false, \"blocking\": false}}' http://localhost:5279/",
"lbrynet": "lbrynet channel abandon 2c20835e4289fe13bc88249efa4d20c2246b29d7",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"channel_abandon\", \"params\": {\"claim_id\": \"2c20835e4289fe13bc88249efa4d20c2246b29d7\", \"preview\": false, \"blocking\": false}}).json()",
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"height\": -2,\n \"hex\": \"01000000017c42eb25578d7a14ced50f985f3684fc27c5e32d0c4de0e42fbd19275e2352db000000006a47304402201acf6486377578fe8da483ba54e756817561552fb01b455c0e295e6456a14ee502204997778cd1eac21430d169f755e780950479e350ccf595b3c24a62bd3eb7b9530121033cfe10e3cabcaf74ab8b6eda6389d1afcb44150bcd90bbc30c81a58e3df32d32ffffffff0134b7f505000000001976a91495673ef5014050b5b1a45e2ccbb7740eba05497788ac00000000\",\n \"inputs\": [\n {\n \"address\": \"mth8FNCBtmx5M92AtxUpWigDPaB1g2xNpZ\",\n \"amount\": \"1.0\",\n \"claim_id\": \"2c20835e4289fe13bc88249efa4d20c2246b29d7\",\n \"claim_op\": \"update\",\n \"confirmations\": 8,\n \"has_signing_key\": true,\n \"height\": 210,\n \"meta\": {},\n \"name\": \"@channel\",\n \"normalized_name\": \"@channel\",\n \"nout\": 0,\n \"permanent_url\": \"lbry://@channel#2c20835e4289fe13bc88249efa4d20c2246b29d7\",\n \"timestamp\": 1602347163,\n \"txid\": \"db52235e2719bd2fe4e04d0c2de3c527fc84365f980fd5ce147a8d5725eb427c\",\n \"type\": \"claim\",\n \"value\": {\n \"public_key\": \"3056301006072a8648ce3d020106052b8104000a03420004bb438060971d65dfccc532c2c72357b802057d458a9143c2f863461ba8f5f79a512b770a19b80717467e0d0366e8097d3cf803a91609a2827d0701d6562e5a88\",\n \"public_key_id\": \"msagyzG92X562roXPRfSYQkmoNWzMYtZd8\",\n \"title\": \"New Channel\"\n },\n \"value_type\": \"channel\"\n }\n ],\n \"outputs\": [\n {\n \"address\": \"mu8vfHjyRsqBkbt4aiR7MvoJ4ZH2i8zshW\",\n \"amount\": \"0.999893\",\n \"confirmations\": -2,\n \"height\": -2,\n \"nout\": 0,\n \"timestamp\": null,\n \"txid\": \"2ac3fc94044dc9ac75dda5debf7c2ca4789321a335c8ffbc968bd9699e571041\",\n \"type\": \"payment\"\n }\n ],\n \"total_fee\": \"0.000107\",\n \"total_input\": \"1.0\",\n \"total_output\": \"0.999893\",\n \"txid\": \"2ac3fc94044dc9ac75dda5debf7c2ca4789321a335c8ffbc968bd9699e571041\"\n }\n}"
}
]
},
{
"name": "channel_create",
"description": "Create a new channel by generating a channel private key and establishing an '@' prefixed claim.",
"arguments": [
{
"name": "name",
"type": "str",
"description": "name of the channel prefixed with '@'",
"is_required": true
},
{
"name": "bid",
"type": "decimal",
"description": "amount to back the claim",
"is_required": true
},
{
"name": "allow_duplicate_name",
"type": "bool",
"description": "create new channel even if one already exists with given name. default: false.",
"is_required": false
},
{
"name": "title",
"type": "str",
"description": "title of the publication",
"is_required": false
},
{
"name": "description",
"type": "str",
"description": "description of the publication",
"is_required": false
},
{
"name": "email",
"type": "str",
"description": "email of channel owner",
"is_required": false
},
{
"name": "website_url",
"type": "str",
"description": "website url",
"is_required": false
},
{
"name": "featured",
"type": "list",
"description": "claim_ids of featured content in channel",
"is_required": false
},
{
"name": "tags",
"type": "list",
"description": "content tags",
"is_required": false
},
{
"name": "languages",
"type": "list",
"description": "languages used by the channel, using RFC 5646 format, eg: for English `--languages=en` for Spanish (Spain) `--languages=es-ES` for Spanish (Mexican) `--languages=es-MX` for Chinese (Simplified) `--languages=zh-Hans` for Chinese (Traditional) `--languages=zh-Hant`",
"is_required": false
},
{
"name": "locations",
"type": "list",
"description": "locations of the channel, consisting of 2 letter `country` code and a `state`, `city` and a postal `code` along with a `latitude` and `longitude`. for JSON RPC: pass a dictionary with aforementioned attributes as keys, eg: ... \"locations\": [{'country': 'US', 'state': 'NH'}] ... for command line: pass a colon delimited list with values in the following order: \"COUNTRY:STATE:CITY:CODE:LATITUDE:LONGITUDE\" making sure to include colon for blank values, for example to provide only the city: ... --locations=\"::Manchester\" with all values set: ... --locations=\"US:NH:Manchester:03101:42.990605:-71.460989\" optionally, you can just pass the \"LATITUDE:LONGITUDE\": ... --locations=\"42.990605:-71.460989\" finally, you can also pass JSON string of dictionary on the command line as you would via JSON RPC ... --locations=\"{'country': 'US', 'state': 'NH'}\"",
"is_required": false
},
{
"name": "thumbnail_url",
"type": "str",
"description": "thumbnail url",
"is_required": false
},
{
"name": "cover_url",
"type": "str",
"description": "url of cover image",
"is_required": false
},
{
"name": "account_id",
"type": "str",
"description": "account to use for holding the transaction",
"is_required": false
},
{
"name": "wallet_id",
"type": "str",
"description": "restrict operation to specific wallet",
"is_required": false
},
{
"name": "funding_account_ids",
"type": "list",
"description": "ids of accounts to fund this transaction",
"is_required": false
},
{
"name": "claim_address",
"type": "str",
"description": "address where the channel is sent to, if not specified it will be determined automatically from the account",
"is_required": false
},
{
"name": "preview",
"type": "bool",
"description": "do not broadcast the transaction",
"is_required": false
},
{
"name": "blocking",
"type": "bool",
"description": "wait until transaction is in mempool",
"is_required": false
}
],
"returns": " {\n \"txid\": \"hash of transaction in hex\",\n \"height\": \"block where transaction was recorded\",\n \"inputs\": [\n {\n \"txid\": \"hash of transaction in hex\",\n \"nout\": \"position in the transaction\",\n \"height\": \"block where transaction was recorded\",\n \"amount\": \"value of the txo as a decimal\",\n \"address\": \"address of who can spend the txo\",\n \"confirmations\": \"number of confirmed blocks\",\n \"is_change\": \"payment to change address, only available when it can be determined\",\n \"is_received\": \"true if txo was sent from external account to this account\",\n \"is_spent\": \"true if txo is spent\",\n \"is_mine\": \"payment to one of your accounts, only available when it can be determined\",\n \"type\": \"one of 'claim', 'support' or 'purchase'\",\n \"name\": \"when type is 'claim' or 'support', this is the claim name\",\n \"claim_id\": \"when type is 'claim', 'support' or 'purchase', this is the claim id\",\n \"claim_op\": \"when type is 'claim', this determines if it is 'create' or 'update'\",\n \"value\": \"when type is 'claim' or 'support' with payload, this is the decoded protobuf payload\",\n \"value_type\": \"determines the type of the 'value' field: 'channel', 'stream', etc\",\n \"protobuf\": \"hex encoded raw protobuf version of 'value' field\",\n \"permanent_url\": \"when type is 'claim' or 'support', this is the long permanent claim URL\",\n \"claim\": \"for purchase outputs only, metadata of purchased claim\",\n \"reposted_claim\": \"for repost claims only, metadata of claim being reposted\",\n \"signing_channel\": \"for signed claims only, metadata of signing channel\",\n \"is_channel_signature_valid\": \"for signed claims only, whether signature is valid\",\n \"purchase_receipt\": \"metadata for the purchase transaction associated with this claim\"\n }\n ],\n \"outputs\": [\n {\n \"txid\": \"hash of transaction in hex\",\n \"nout\": \"position in the transaction\",\n \"height\": \"block where transaction was recorded\",\n \"amount\": \"value of the txo as a decimal\",\n \"address\": \"address of who can spend the txo\",\n \"confirmations\": \"number of confirmed blocks\",\n \"is_change\": \"payment to change address, only available when it can be determined\",\n \"is_received\": \"true if txo was sent from external account to this account\",\n \"is_spent\": \"true if txo is spent\",\n \"is_mine\": \"payment to one of your accounts, only available when it can be determined\",\n \"type\": \"one of 'claim', 'support' or 'purchase'\",\n \"name\": \"when type is 'claim' or 'support', this is the claim name\",\n \"claim_id\": \"when type is 'claim', 'support' or 'purchase', this is the claim id\",\n \"claim_op\": \"when type is 'claim', this determines if it is 'create' or 'update'\",\n \"value\": \"when type is 'claim' or 'support' with payload, this is the decoded protobuf payload\",\n \"value_type\": \"determines the type of the 'value' field: 'channel', 'stream', etc\",\n \"protobuf\": \"hex encoded raw protobuf version of 'value' field\",\n \"permanent_url\": \"when type is 'claim' or 'support', this is the long permanent claim URL\",\n \"claim\": \"for purchase outputs only, metadata of purchased claim\",\n \"reposted_claim\": \"for repost claims only, metadata of claim being reposted\",\n \"signing_channel\": \"for signed claims only, metadata of signing channel\",\n \"is_channel_signature_valid\": \"for signed claims only, whether signature is valid\",\n \"purchase_receipt\": \"metadata for the purchase transaction associated with this claim\"\n }\n ],\n \"total_input\": \"sum of inputs as a decimal\",\n \"total_output\": \"sum of outputs, sans fee, as a decimal\",\n \"total_fee\": \"fee amount\",\n \"hex\": \"entire transaction encoded in hex\"\n }",
"examples": [
{
"title": "Create a channel claim without metadata",
"curl": "curl -d'{\"method\": \"channel_create\", \"params\": {\"name\": \"@channel\", \"bid\": \"1.0\", \"featured\": [], \"tags\": [], \"languages\": [], \"locations\": [], \"funding_account_ids\": [], \"preview\": false, \"blocking\": false}}' http://localhost:5279/",
"lbrynet": "lbrynet channel create @channel 1.0",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"channel_create\", \"params\": {\"name\": \"@channel\", \"bid\": \"1.0\", \"featured\": [], \"tags\": [], \"languages\": [], \"locations\": [], \"funding_account_ids\": [], \"preview\": false, \"blocking\": false}}).json()",
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"height\": -2,\n \"hex\": \"0100000001693ab01abff0f9fc59fee20ad468992358df0ae6c9ec4d633ad769fd10965c7a010000006a4730440220073395385b372aea05c4b46b3b71e0205d8f8d7fd160684d93e1f38a302ee8fe0220780cc361e97e8637818f341cefe889835568c15ce05b204f6441e62c34f841f70121022426df37c4781c5bfb8c92e42c70d4804ccbf02590105090de2ca5b9e68ff254ffffffff0200e1f5050000000084b508406368616e6e656c4c5d00125a0a583056301006072a8648ce3d020106052b8104000a03420004bb438060971d65dfccc532c2c72357b802057d458a9143c2f863461ba8f5f79a512b770a19b80717467e0d0366e8097d3cf803a91609a2827d0701d6562e5a886d7576a91490861a8c41b20bab8f4952e3506a3ffb75fc8eec88acc462a029000000001976a91400f398243e768c619ed545eee796075f45c47b8188ac00000000\",\n \"inputs\": [\n {\n \"address\": \"mz7QemZsW1NyZtnLt7tuhqyBEyBN4xNnEC\",\n \"amount\": \"7.999876\",\n \"confirmations\": 2,\n \"height\": 207,\n \"nout\": 1,\n \"timestamp\": 1602347163,\n \"txid\": \"7a5c9610fd69d73a634decc9e60adf58239968d40ae2fe59fcf9f0bf1ab03a69\",\n \"type\": \"payment\"\n }\n ],\n \"outputs\": [\n {\n \"address\": \"mth8FNCBtmx5M92AtxUpWigDPaB1g2xNpZ\",\n \"amount\": \"1.0\",\n \"claim_id\": \"2c20835e4289fe13bc88249efa4d20c2246b29d7\",\n \"claim_op\": \"create\",\n \"confirmations\": -2,\n \"has_signing_key\": true,\n \"height\": -2,\n \"meta\": {},\n \"name\": \"@channel\",\n \"normalized_name\": \"@channel\",\n \"nout\": 0,\n \"permanent_url\": \"lbry://@channel#2c20835e4289fe13bc88249efa4d20c2246b29d7\",\n \"timestamp\": null,\n \"txid\": \"1857a5655c164b39b664fa34b3f756d6350fa051182840e75d323844bc3ff973\",\n \"type\": \"claim\",\n \"value\": {\n \"public_key\": \"3056301006072a8648ce3d020106052b8104000a03420004bb438060971d65dfccc532c2c72357b802057d458a9143c2f863461ba8f5f79a512b770a19b80717467e0d0366e8097d3cf803a91609a2827d0701d6562e5a88\",\n \"public_key_id\": \"msagyzG92X562roXPRfSYQkmoNWzMYtZd8\"\n },\n \"value_type\": \"channel\"\n },\n {\n \"address\": \"mfbz7HMyrLu4N8Buv2M9Jie2rjRTdYo8mD\",\n \"amount\": \"6.983769\",\n \"confirmations\": -2,\n \"height\": -2,\n \"nout\": 1,\n \"timestamp\": null,\n \"txid\": \"1857a5655c164b39b664fa34b3f756d6350fa051182840e75d323844bc3ff973\",\n \"type\": \"payment\"\n }\n ],\n \"total_fee\": \"0.016107\",\n \"total_input\": \"7.999876\",\n \"total_output\": \"7.983769\",\n \"txid\": \"1857a5655c164b39b664fa34b3f756d6350fa051182840e75d323844bc3ff973\"\n }\n}"
},
{
"title": "Create a channel claim with all metadata",
"curl": "curl -d'{\"method\": \"channel_create\", \"params\": {\"name\": \"@bigchannel\", \"bid\": \"1.0\", \"title\": \"Big Channel\", \"description\": \"A channel with lots of videos.\", \"email\": \"creator@smallmedia.com\", \"website_url\": \"http://smallmedia.com\", \"featured\": [], \"tags\": [\"music\", \"art\"], \"languages\": [\"pt-BR\", \"uk\"], \"locations\": [\"BR\", \"UA::Kiyv\"], \"thumbnail_url\": \"http://smallmedia.com/logo.jpg\", \"cover_url\": \"http://smallmedia.com/logo.jpg\", \"funding_account_ids\": [], \"preview\": false, \"blocking\": false}}' http://localhost:5279/",
"lbrynet": "lbrynet channel create @bigchannel 1.0 --title=\"Big Channel\" --description=\"A channel with lots of videos.\" --email=\"creator@smallmedia.com\" --tags=music --tags=art --languages=pt-BR --languages=uk --locations=BR --locations=UA::Kiyv --website_url=\"http://smallmedia.com\" --thumbnail_url=\"http://smallmedia.com/logo.jpg\" --cover_url=\"http://smallmedia.com/logo.jpg\"",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"channel_create\", \"params\": {\"name\": \"@bigchannel\", \"bid\": \"1.0\", \"title\": \"Big Channel\", \"description\": \"A channel with lots of videos.\", \"email\": \"creator@smallmedia.com\", \"website_url\": \"http://smallmedia.com\", \"featured\": [], \"tags\": [\"music\", \"art\"], \"languages\": [\"pt-BR\", \"uk\"], \"locations\": [\"BR\", \"UA::Kiyv\"], \"thumbnail_url\": \"http://smallmedia.com/logo.jpg\", \"cover_url\": \"http://smallmedia.com/logo.jpg\", \"funding_account_ids\": [], \"preview\": false, \"blocking\": false}}).json()",
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"height\": -2,\n \"hex\": \"01000000017c42eb25578d7a14ced50f985f3684fc27c5e32d0c4de0e42fbd19275e2352db010000006b483045022100d10af77218922d00c58198c6e2b6ed03ca24299c8f02deb757dfe311c83461bc0220747c562cdb0d8ffdf582d5569c1751f610f3c02902f65c1073ec41b1d4977421012102df0403cd16ed2f2c589e2a453875de7836ff4ccd410bad3a75261a41ca9f6d5dffffffff0200e1f50500000000fd5001b50b406269676368616e6e656c4d25010012ab010a583056301006072a8648ce3d020106052b8104000a0342000436051718e2ab52f58c4534244423acb0fd21647b16f710ffd93b8b245df40d8a863ff0cef51ef4e806a1e3555ed242317ebed197743d7c0cccf270eeae4b0eb5121663726561746f7240736d616c6c6d656469612e636f6d1a15687474703a2f2f736d616c6c6d656469612e636f6d22202a1e687474703a2f2f736d616c6c6d656469612e636f6d2f6c6f676f2e6a7067420b426967204368616e6e656c4a1e41206368616e6e656c2077697468206c6f7473206f6620766964656f732e52202a1e687474703a2f2f736d616c6c6d656469612e636f6d2f6c6f676f2e6a70675a056d757369635a0361727462050883011820620308ab016a0208206a0908e9011a044b6979766d7576a9144b862a192c3868172c6e64a02ce61a51e1ea75e288ace221d305000000001976a914cc89c6ea9a2cd8ea630fd745113fc30656c2efaa88ac00000000\",\n \"inputs\": [\n {\n \"address\": \"mpSQEXUiXBWzW1dSag9RDd3horvLTVcXwt\",\n \"amount\": \"1.9993355\",\n \"confirmations\": 1,\n \"height\": 210,\n \"nout\": 1,\n \"timestamp\": 1602347163,\n \"txid\": \"db52235e2719bd2fe4e04d0c2de3c527fc84365f980fd5ce147a8d5725eb427c\",\n \"type\": \"payment\"\n }\n ],\n \"outputs\": [\n {\n \"address\": \"mnQHhMHFsPD3FAr2yLQ7jd3fy48vBqrUm7\",\n \"amount\": \"1.0\",\n \"claim_id\": \"eeb35c20382ffe506c2de8915f23341d62bcd431\",\n \"claim_op\": \"create\",\n \"confirmations\": -2,\n \"has_signing_key\": true,\n \"height\": -2,\n \"meta\": {},\n \"name\": \"@bigchannel\",\n \"normalized_name\": \"@bigchannel\",\n \"nout\": 0,\n \"permanent_url\": \"lbry://@bigchannel#eeb35c20382ffe506c2de8915f23341d62bcd431\",\n \"timestamp\": null,\n \"txid\": \"8882be2adceebafcc1de60e100fe5a5604c587f6d1890ad5d6c491178ff1619d\",\n \"type\": \"claim\",\n \"value\": {\n \"cover\": {\n \"url\": \"http://smallmedia.com/logo.jpg\"\n },\n \"description\": \"A channel with lots of videos.\",\n \"email\": \"creator@smallmedia.com\",\n \"languages\": [\n \"pt-BR\",\n \"uk\"\n ],\n \"locations\": [\n {\n \"country\": \"BR\"\n },\n {\n \"city\": \"Kiyv\",\n \"country\": \"UA\"\n }\n ],\n \"public_key\": \"3056301006072a8648ce3d020106052b8104000a0342000436051718e2ab52f58c4534244423acb0fd21647b16f710ffd93b8b245df40d8a863ff0cef51ef4e806a1e3555ed242317ebed197743d7c0cccf270eeae4b0eb5\",\n \"public_key_id\": \"miZpSVeZ1797y6T6DkytvVSAvAz5mN4VWy\",\n \"tags\": [\n \"music\",\n \"art\"\n ],\n \"thumbnail\": {\n \"url\": \"http://smallmedia.com/logo.jpg\"\n },\n \"title\": \"Big Channel\",\n \"website_url\": \"http://smallmedia.com\"\n },\n \"value_type\": \"channel\"\n },\n {\n \"address\": \"mzATC6tkxXtP6xGUhJXoUporBcJNru6Lty\",\n \"amount\": \"0.9772285\",\n \"confirmations\": -2,\n \"height\": -2,\n \"nout\": 1,\n \"timestamp\": null,\n \"txid\": \"8882be2adceebafcc1de60e100fe5a5604c587f6d1890ad5d6c491178ff1619d\",\n \"type\": \"payment\"\n }\n ],\n \"total_fee\": \"0.022107\",\n \"total_input\": \"1.9993355\",\n \"total_output\": \"1.9772285\",\n \"txid\": \"8882be2adceebafcc1de60e100fe5a5604c587f6d1890ad5d6c491178ff1619d\"\n }\n}"
}
]
},
{
"name": "channel_export",
"description": "Export channel private key.",
"arguments": [
{
"name": "channel_id",
"type": "str",
"description": "claim id of channel to export",
"is_required": true
},
{
"name": "channel_name",
"type": "str",
"description": "name of channel to export",
"is_required": false
},
{
"name": "account_id",
"type": "str",
"description": "one or more account ids for accounts to look in for channels, defaults to all accounts.",
"is_required": false
},
{
"name": "wallet_id",
"type": "str",
"description": "restrict operation to specific wallet",
"is_required": false
}
],
"returns": "(str) serialized channel private key",
"examples": []
},
{
"name": "channel_import",
"description": "Import serialized channel private key (to allow signing new streams to the channel)",
"arguments": [
{
"name": "channel_data",
"type": "str",
"description": "serialized channel, as exported by channel export",
"is_required": true
},
{
"name": "wallet_id",
"type": "str",
"description": "import into specific wallet",
"is_required": false
}
],
"returns": "(dict) Result dictionary",
"examples": []
},
{
"name": "channel_list",
"description": "List my channel claims.",
"arguments": [
{
"name": "name",
"type": "str or list",
"description": "channel name",
"is_required": false
},
{
"name": "claim_id",
"type": "str or list",
"description": "channel id",
"is_required": false
},
{
"name": "is_spent",
"type": "bool",
"description": "shows previous channel updates and abandons",
"is_required": false
},
{
"name": "account_id",
"type": "str",
"description": "id of the account to use",
"is_required": false
},
{
"name": "wallet_id",
"type": "str",
"description": "restrict results to specific wallet",
"is_required": false
},
{
"name": "page",
"type": "int",
"description": "page to return during paginating",
"is_required": false
},
{
"name": "page_size",
"type": "int",
"description": "number of items on page during pagination",
"is_required": false
},
{
"name": "resolve",
"type": "bool",
"description": "resolves each channel to provide additional metadata",
"is_required": false
},
{
"name": "no_totals",
"type": "bool",
"description": "do not calculate the total number of pages and items in result set (significant performance boost)",
"is_required": false
}
],
"returns": " {\n \"page\": \"Page number of the current items.\",\n \"page_size\": \"Number of items to show on a page.\",\n \"total_pages\": \"Total number of pages.\",\n \"total_items\": \"Total number of items.\",\n \"items\": [\n {\n \"txid\": \"hash of transaction in hex\",\n \"nout\": \"position in the transaction\",\n \"height\": \"block where transaction was recorded\",\n \"amount\": \"value of the txo as a decimal\",\n \"address\": \"address of who can spend the txo\",\n \"confirmations\": \"number of confirmed blocks\",\n \"is_change\": \"payment to change address, only available when it can be determined\",\n \"is_received\": \"true if txo was sent from external account to this account\",\n \"is_spent\": \"true if txo is spent\",\n \"is_mine\": \"payment to one of your accounts, only available when it can be determined\",\n \"type\": \"one of 'claim', 'support' or 'purchase'\",\n \"name\": \"when type is 'claim' or 'support', this is the claim name\",\n \"claim_id\": \"when type is 'claim', 'support' or 'purchase', this is the claim id\",\n \"claim_op\": \"when type is 'claim', this determines if it is 'create' or 'update'\",\n \"value\": \"when type is 'claim' or 'support' with payload, this is the decoded protobuf payload\",\n \"value_type\": \"determines the type of the 'value' field: 'channel', 'stream', etc\",\n \"protobuf\": \"hex encoded raw protobuf version of 'value' field\",\n \"permanent_url\": \"when type is 'claim' or 'support', this is the long permanent claim URL\",\n \"claim\": \"for purchase outputs only, metadata of purchased claim\",\n \"reposted_claim\": \"for repost claims only, metadata of claim being reposted\",\n \"signing_channel\": \"for signed claims only, metadata of signing channel\",\n \"is_channel_signature_valid\": \"for signed claims only, whether signature is valid\",\n \"purchase_receipt\": \"metadata for the purchase transaction associated with this claim\"\n }\n ]\n }",
"examples": [
{
"title": "List your channel claims",
"curl": "curl -d'{\"method\": \"channel_list\", \"params\": {\"name\": [], \"claim_id\": [], \"is_spent\": false, \"resolve\": false, \"no_totals\": false}}' http://localhost:5279/",
"lbrynet": "lbrynet channel list",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"channel_list\", \"params\": {\"name\": [], \"claim_id\": [], \"is_spent\": false, \"resolve\": false, \"no_totals\": false}}).json()",
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"items\": [\n {\n \"address\": \"mth8FNCBtmx5M92AtxUpWigDPaB1g2xNpZ\",\n \"amount\": \"1.0\",\n \"claim_id\": \"2c20835e4289fe13bc88249efa4d20c2246b29d7\",\n \"claim_op\": \"create\",\n \"confirmations\": 1,\n \"has_signing_key\": true,\n \"height\": 209,\n \"is_internal_transfer\": false,\n \"is_my_input\": true,\n \"is_my_output\": true,\n \"is_spent\": false,\n \"meta\": {},\n \"name\": \"@channel\",\n \"normalized_name\": \"@channel\",\n \"nout\": 0,\n \"permanent_url\": \"lbry://@channel#2c20835e4289fe13bc88249efa4d20c2246b29d7\",\n \"timestamp\": 1602347163,\n \"txid\": \"1857a5655c164b39b664fa34b3f756d6350fa051182840e75d323844bc3ff973\",\n \"type\": \"claim\",\n \"value\": {\n \"public_key\": \"3056301006072a8648ce3d020106052b8104000a03420004bb438060971d65dfccc532c2c72357b802057d458a9143c2f863461ba8f5f79a512b770a19b80717467e0d0366e8097d3cf803a91609a2827d0701d6562e5a88\",\n \"public_key_id\": \"msagyzG92X562roXPRfSYQkmoNWzMYtZd8\"\n },\n \"value_type\": \"channel\"\n }\n ],\n \"page\": 1,\n \"page_size\": 20,\n \"total_items\": 1,\n \"total_pages\": 1\n }\n}"
},
{
"title": "Paginate your channel claims",
"curl": "curl -d'{\"method\": \"channel_list\", \"params\": {\"name\": [], \"claim_id\": [], \"is_spent\": false, \"page\": 1, \"page_size\": 20, \"resolve\": false, \"no_totals\": false}}' http://localhost:5279/",
"lbrynet": "lbrynet channel list --page=1 --page_size=20",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"channel_list\", \"params\": {\"name\": [], \"claim_id\": [], \"is_spent\": false, \"page\": 1, \"page_size\": 20, \"resolve\": false, \"no_totals\": false}}).json()",
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"items\": [\n {\n \"address\": \"mth8FNCBtmx5M92AtxUpWigDPaB1g2xNpZ\",\n \"amount\": \"1.0\",\n \"claim_id\": \"2c20835e4289fe13bc88249efa4d20c2246b29d7\",\n \"claim_op\": \"create\",\n \"confirmations\": 1,\n \"has_signing_key\": true,\n \"height\": 209,\n \"is_internal_transfer\": false,\n \"is_my_input\": true,\n \"is_my_output\": true,\n \"is_spent\": false,\n \"meta\": {},\n \"name\": \"@channel\",\n \"normalized_name\": \"@channel\",\n \"nout\": 0,\n \"permanent_url\": \"lbry://@channel#2c20835e4289fe13bc88249efa4d20c2246b29d7\",\n \"timestamp\": 1602347163,\n \"txid\": \"1857a5655c164b39b664fa34b3f756d6350fa051182840e75d323844bc3ff973\",\n \"type\": \"claim\",\n \"value\": {\n \"public_key\": \"3056301006072a8648ce3d020106052b8104000a03420004bb438060971d65dfccc532c2c72357b802057d458a9143c2f863461ba8f5f79a512b770a19b80717467e0d0366e8097d3cf803a91609a2827d0701d6562e5a88\",\n \"public_key_id\": \"msagyzG92X562roXPRfSYQkmoNWzMYtZd8\"\n },\n \"value_type\": \"channel\"\n }\n ],\n \"page\": 1,\n \"page_size\": 20,\n \"total_items\": 1,\n \"total_pages\": 1\n }\n}"
}
]
},
{
"name": "channel_update",
"description": "Update an existing channel claim.",
"arguments": [
{
"name": "claim_id",
"type": "str",
"description": "claim_id of the channel to update",
"is_required": true
},
{
"name": "bid",
"type": "decimal",
"description": "amount to back the claim",
"is_required": false
},
{
"name": "title",
"type": "str",
"description": "title of the publication",
"is_required": false
},
{
"name": "description",
"type": "str",
"description": "description of the publication",
"is_required": false
},
{
"name": "email",
"type": "str",
"description": "email of channel owner",
"is_required": false
},
{
"name": "website_url",
"type": "str",
"description": "website url",
"is_required": false
},
{
"name": "featured",
"type": "list",
"description": "claim_ids of featured content in channel",
"is_required": false
},
{
"name": "clear_featured",
"type": "bool",
"description": "clear existing featured content (prior to adding new ones)",
"is_required": false
},
{
"name": "tags",
"type": "list",
"description": "add content tags",
"is_required": false
},
{
"name": "clear_tags",
"type": "bool",
"description": "clear existing tags (prior to adding new ones)",
"is_required": false
},
{
"name": "languages",
"type": "list",
"description": "languages used by the channel, using RFC 5646 format, eg: for English `--languages=en` for Spanish (Spain) `--languages=es-ES` for Spanish (Mexican) `--languages=es-MX` for Chinese (Simplified) `--languages=zh-Hans` for Chinese (Traditional) `--languages=zh-Hant`",
"is_required": false
},
{
"name": "clear_languages",
"type": "bool",
"description": "clear existing languages (prior to adding new ones)",
"is_required": false
},
{
"name": "locations",
"type": "list",
"description": "locations of the channel, consisting of 2 letter `country` code and a `state`, `city` and a postal `code` along with a `latitude` and `longitude`. for JSON RPC: pass a dictionary with aforementioned attributes as keys, eg: ... \"locations\": [{'country': 'US', 'state': 'NH'}] ... for command line: pass a colon delimited list with values in the following order: \"COUNTRY:STATE:CITY:CODE:LATITUDE:LONGITUDE\" making sure to include colon for blank values, for example to provide only the city: ... --locations=\"::Manchester\" with all values set: ... --locations=\"US:NH:Manchester:03101:42.990605:-71.460989\" optionally, you can just pass the \"LATITUDE:LONGITUDE\": ... --locations=\"42.990605:-71.460989\" finally, you can also pass JSON string of dictionary on the command line as you would via JSON RPC ... --locations=\"{'country': 'US', 'state': 'NH'}\"",
"is_required": false
},
{
"name": "clear_locations",
"type": "bool",
"description": "clear existing locations (prior to adding new ones)",
"is_required": false
},
{
"name": "thumbnail_url",
"type": "str",
"description": "thumbnail url",
"is_required": false
},
{
"name": "cover_url",
"type": "str",
"description": "url of cover image",
"is_required": false
},
{
"name": "account_id",
"type": "str",
"description": "account in which to look for channel (default: all)",
"is_required": false
},
{
"name": "wallet_id",
"type": "str",
"description": "restrict operation to specific wallet",
"is_required": false
},
{
"name": "funding_account_ids",
"type": "list",
"description": "ids of accounts to fund this transaction",
"is_required": false
},
{
"name": "claim_address",
"type": "str",
"description": "address where the channel is sent",
"is_required": false
},
{
"name": "new_signing_key",
"type": "bool",
"description": "generate a new signing key, will invalidate all previous publishes",
"is_required": false
},
{
"name": "preview",
"type": "bool",
"description": "do not broadcast the transaction",
"is_required": false
},
{
"name": "blocking",
"type": "bool",
"description": "wait until transaction is in mempool",
"is_required": false
},
{
"name": "replace",
"type": "bool",
"description": "instead of modifying specific values on the channel, this will clear all existing values and only save passed in values, useful for form submissions where all values are always set",
"is_required": false
}
],
"returns": " {\n \"txid\": \"hash of transaction in hex\",\n \"height\": \"block where transaction was recorded\",\n \"inputs\": [\n {\n \"txid\": \"hash of transaction in hex\",\n \"nout\": \"position in the transaction\",\n \"height\": \"block where transaction was recorded\",\n \"amount\": \"value of the txo as a decimal\",\n \"address\": \"address of who can spend the txo\",\n \"confirmations\": \"number of confirmed blocks\",\n \"is_change\": \"payment to change address, only available when it can be determined\",\n \"is_received\": \"true if txo was sent from external account to this account\",\n \"is_spent\": \"true if txo is spent\",\n \"is_mine\": \"payment to one of your accounts, only available when it can be determined\",\n \"type\": \"one of 'claim', 'support' or 'purchase'\",\n \"name\": \"when type is 'claim' or 'support', this is the claim name\",\n \"claim_id\": \"when type is 'claim', 'support' or 'purchase', this is the claim id\",\n \"claim_op\": \"when type is 'claim', this determines if it is 'create' or 'update'\",\n \"value\": \"when type is 'claim' or 'support' with payload, this is the decoded protobuf payload\",\n \"value_type\": \"determines the type of the 'value' field: 'channel', 'stream', etc\",\n \"protobuf\": \"hex encoded raw protobuf version of 'value' field\",\n \"permanent_url\": \"when type is 'claim' or 'support', this is the long permanent claim URL\",\n \"claim\": \"for purchase outputs only, metadata of purchased claim\",\n \"reposted_claim\": \"for repost claims only, metadata of claim being reposted\",\n \"signing_channel\": \"for signed claims only, metadata of signing channel\",\n \"is_channel_signature_valid\": \"for signed claims only, whether signature is valid\",\n \"purchase_receipt\": \"metadata for the purchase transaction associated with this claim\"\n }\n ],\n \"outputs\": [\n {\n \"txid\": \"hash of transaction in hex\",\n \"nout\": \"position in the transaction\",\n \"height\": \"block where transaction was recorded\",\n \"amount\": \"value of the txo as a decimal\",\n \"address\": \"address of who can spend the txo\",\n \"confirmations\": \"number of confirmed blocks\",\n \"is_change\": \"payment to change address, only available when it can be determined\",\n \"is_received\": \"true if txo was sent from external account to this account\",\n \"is_spent\": \"true if txo is spent\",\n \"is_mine\": \"payment to one of your accounts, only available when it can be determined\",\n \"type\": \"one of 'claim', 'support' or 'purchase'\",\n \"name\": \"when type is 'claim' or 'support', this is the claim name\",\n \"claim_id\": \"when type is 'claim', 'support' or 'purchase', this is the claim id\",\n \"claim_op\": \"when type is 'claim', this determines if it is 'create' or 'update'\",\n \"value\": \"when type is 'claim' or 'support' with payload, this is the decoded protobuf payload\",\n \"value_type\": \"determines the type of the 'value' field: 'channel', 'stream', etc\",\n \"protobuf\": \"hex encoded raw protobuf version of 'value' field\",\n \"permanent_url\": \"when type is 'claim' or 'support', this is the long permanent claim URL\",\n \"claim\": \"for purchase outputs only, metadata of purchased claim\",\n \"reposted_claim\": \"for repost claims only, metadata of claim being reposted\",\n \"signing_channel\": \"for signed claims only, metadata of signing channel\",\n \"is_channel_signature_valid\": \"for signed claims only, whether signature is valid\",\n \"purchase_receipt\": \"metadata for the purchase transaction associated with this claim\"\n }\n ],\n \"total_input\": \"sum of inputs as a decimal\",\n \"total_output\": \"sum of outputs, sans fee, as a decimal\",\n \"total_fee\": \"fee amount\",\n \"hex\": \"entire transaction encoded in hex\"\n }",
"examples": [
{
"title": "Update a channel claim",
"curl": "curl -d'{\"method\": \"channel_update\", \"params\": {\"claim_id\": \"2c20835e4289fe13bc88249efa4d20c2246b29d7\", \"title\": \"New Channel\", \"featured\": [], \"clear_featured\": false, \"tags\": [], \"clear_tags\": false, \"languages\": [], \"clear_languages\": false, \"locations\": [], \"clear_locations\": false, \"new_signing_key\": false, \"funding_account_ids\": [], \"preview\": false, \"blocking\": false, \"replace\": false}}' http://localhost:5279/",
"lbrynet": "lbrynet channel update 2c20835e4289fe13bc88249efa4d20c2246b29d7 --title=\"New Channel\"",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"channel_update\", \"params\": {\"claim_id\": \"2c20835e4289fe13bc88249efa4d20c2246b29d7\", \"title\": \"New Channel\", \"featured\": [], \"clear_featured\": false, \"tags\": [], \"clear_tags\": false, \"languages\": [], \"clear_languages\": false, \"locations\": [], \"clear_locations\": false, \"new_signing_key\": false, \"funding_account_ids\": [], \"preview\": false, \"blocking\": false, \"replace\": false}}).json()",
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"height\": -2,\n \"hex\": \"010000000273f93fbc4438325de740281851a00f35d656f7b334fa64b6394b165c65a55718000000006a47304402207b45689eb02dcf7be3682a5b30da3202dd2ac1fa06a926645cc67348bebdc696022021551191db9cf3f5a500e40a4ee5dc3369c21da775438380f2bda4c318a83eac0121033cfe10e3cabcaf74ab8b6eda6389d1afcb44150bcd90bbc30c81a58e3df32d32ffffffff77e33c2061cfafda0a3fcf0db822a0f63318fe3a632a9de78a0ce56264234a7a000000006b483045022100ea904889ff44167c2cfdf924efcf9597cfae19f500e911473c531fef07a6b9c002206be927bb8efd01da8c6f3a960e0cfb1bcf4cca0b58128db6b85dabbf277284ec012103d938c3838a7afab5347ef5e70894515ccc7b3016f401b4a1bfaf6f663b6687dbffffffff0200e1f50500000000a6b708406368616e6e656c14d7296b24c2204dfa9e2488bc13fe89425e83202c4c6a00125a0a583056301006072a8648ce3d020106052b8104000a03420004bb438060971d65dfccc532c2c72357b802057d458a9143c2f863461ba8f5f79a512b770a19b80717467e0d0366e8097d3cf803a91609a2827d0701d6562e5a88420b4e6577204368616e6e656c6d6d76a91490861a8c41b20bab8f4952e3506a3ffb75fc8eec88ac6ebeea0b000000001976a91461dcb486a8807446605420d149654f03a82b347a88ac00000000\",\n \"inputs\": [\n {\n \"address\": \"mth8FNCBtmx5M92AtxUpWigDPaB1g2xNpZ\",\n \"amount\": \"1.0\",\n \"claim_id\": \"2c20835e4289fe13bc88249efa4d20c2246b29d7\",\n \"claim_op\": \"create\",\n \"confirmations\": 1,\n \"has_signing_key\": true,\n \"height\": 209,\n \"meta\": {},\n \"name\": \"@channel\",\n \"normalized_name\": \"@channel\",\n \"nout\": 0,\n \"permanent_url\": \"lbry://@channel#2c20835e4289fe13bc88249efa4d20c2246b29d7\",\n \"timestamp\": 1602347163,\n \"txid\": \"1857a5655c164b39b664fa34b3f756d6350fa051182840e75d323844bc3ff973\",\n \"type\": \"claim\",\n \"value\": {\n \"public_key\": \"3056301006072a8648ce3d020106052b8104000a03420004bb438060971d65dfccc532c2c72357b802057d458a9143c2f863461ba8f5f79a512b770a19b80717467e0d0366e8097d3cf803a91609a2827d0701d6562e5a88\",\n \"public_key_id\": \"msagyzG92X562roXPRfSYQkmoNWzMYtZd8\"\n },\n \"value_type\": \"channel\"\n },\n {\n \"address\": \"mmawAJ2k762cNvvrWWUvp8CbL5ecXsnFe4\",\n \"amount\": \"1.999604\",\n \"confirmations\": 1,\n \"height\": 209,\n \"nout\": 0,\n \"timestamp\": 1602347163,\n \"txid\": \"7a4a236462e50c8ae79d2a633afe1833f6a022b80dcf3f0adaafcf61203ce377\",\n \"type\": \"payment\"\n }\n ],\n \"outputs\": [\n {\n \"address\": \"mth8FNCBtmx5M92AtxUpWigDPaB1g2xNpZ\",\n \"amount\": \"1.0\",\n \"claim_id\": \"2c20835e4289fe13bc88249efa4d20c2246b29d7\",\n \"claim_op\": \"update\",\n \"confirmations\": -2,\n \"has_signing_key\": true,\n \"height\": -2,\n \"meta\": {},\n \"name\": \"@channel\",\n \"normalized_name\": \"@channel\",\n \"nout\": 0,\n \"permanent_url\": \"lbry://@channel#2c20835e4289fe13bc88249efa4d20c2246b29d7\",\n \"timestamp\": null,\n \"txid\": \"db52235e2719bd2fe4e04d0c2de3c527fc84365f980fd5ce147a8d5725eb427c\",\n \"type\": \"claim\",\n \"value\": {\n \"public_key\": \"3056301006072a8648ce3d020106052b8104000a03420004bb438060971d65dfccc532c2c72357b802057d458a9143c2f863461ba8f5f79a512b770a19b80717467e0d0366e8097d3cf803a91609a2827d0701d6562e5a88\",\n \"public_key_id\": \"msagyzG92X562roXPRfSYQkmoNWzMYtZd8\",\n \"title\": \"New Channel\"\n },\n \"value_type\": \"channel\"\n },\n {\n \"address\": \"mpSQEXUiXBWzW1dSag9RDd3horvLTVcXwt\",\n \"amount\": \"1.9993355\",\n \"confirmations\": -2,\n \"height\": -2,\n \"nout\": 1,\n \"timestamp\": null,\n \"txid\": \"db52235e2719bd2fe4e04d0c2de3c527fc84365f980fd5ce147a8d5725eb427c\",\n \"type\": \"payment\"\n }\n ],\n \"total_fee\": \"0.0002685\",\n \"total_input\": \"2.999604\",\n \"total_output\": \"2.9993355\",\n \"txid\": \"db52235e2719bd2fe4e04d0c2de3c527fc84365f980fd5ce147a8d5725eb427c\"\n }\n}"
}
]
}
]
},
"claim": {
"doc": "List and search all types of claims.",
"commands": [
{
"name": "claim_list",
"description": "List my stream and channel claims.",
"arguments": [
{
"name": "claim_type",
"type": "str or list",
"description": "claim type: channel, stream, repost, collection",
"is_required": false
},
{
"name": "claim_id",
"type": "str or list",
"description": "claim id",
"is_required": false
},
{
"name": "channel_id",
"type": "str or list",
"description": "streams in this channel",
"is_required": false
},
{
"name": "name",
"type": "str or list",
"description": "claim name",
"is_required": false
},
{
"name": "is_spent",
"type": "bool",
"description": "shows previous claim updates and abandons",
"is_required": false
},
{
"name": "account_id",
"type": "str",
"description": "id of the account to query",
"is_required": false
},
{
"name": "wallet_id",
"type": "str",
"description": "restrict results to specific wallet",
"is_required": false
},
{
"name": "page",
"type": "int",
"description": "page to return during paginating",
"is_required": false
},
{
"name": "page_size",
"type": "int",
"description": "number of items on page during pagination",
"is_required": false
},
{
"name": "resolve",
"type": "bool",
"description": "resolves each claim to provide additional metadata",
"is_required": false
},
{
"name": "order_by",
"type": "str",
"description": "field to order by: 'name', 'height', 'amount'",
"is_required": false
},
{
"name": "no_totals",
"type": "bool",
"description": "do not calculate the total number of pages and items in result set (significant performance boost)",
"is_required": false
},
{
"name": "include_received_tips",
"type": "bool",
"description": "calculate the amount of tips recieved for claim outputs",
"is_required": false
}
],
"returns": " {\n \"page\": \"Page number of the current items.\",\n \"page_size\": \"Number of items to show on a page.\",\n \"total_pages\": \"Total number of pages.\",\n \"total_items\": \"Total number of items.\",\n \"items\": [\n {\n \"txid\": \"hash of transaction in hex\",\n \"nout\": \"position in the transaction\",\n \"height\": \"block where transaction was recorded\",\n \"amount\": \"value of the txo as a decimal\",\n \"address\": \"address of who can spend the txo\",\n \"confirmations\": \"number of confirmed blocks\",\n \"is_change\": \"payment to change address, only available when it can be determined\",\n \"is_received\": \"true if txo was sent from external account to this account\",\n \"is_spent\": \"true if txo is spent\",\n \"is_mine\": \"payment to one of your accounts, only available when it can be determined\",\n \"type\": \"one of 'claim', 'support' or 'purchase'\",\n \"name\": \"when type is 'claim' or 'support', this is the claim name\",\n \"claim_id\": \"when type is 'claim', 'support' or 'purchase', this is the claim id\",\n \"claim_op\": \"when type is 'claim', this determines if it is 'create' or 'update'\",\n \"value\": \"when type is 'claim' or 'support' with payload, this is the decoded protobuf payload\",\n \"value_type\": \"determines the type of the 'value' field: 'channel', 'stream', etc\",\n \"protobuf\": \"hex encoded raw protobuf version of 'value' field\",\n \"permanent_url\": \"when type is 'claim' or 'support', this is the long permanent claim URL\",\n \"claim\": \"for purchase outputs only, metadata of purchased claim\",\n \"reposted_claim\": \"for repost claims only, metadata of claim being reposted\",\n \"signing_channel\": \"for signed claims only, metadata of signing channel\",\n \"is_channel_signature_valid\": \"for signed claims only, whether signature is valid\",\n \"purchase_receipt\": \"metadata for the purchase transaction associated with this claim\"\n }\n ]\n }",
"examples": [
{
"title": "List all your claims",
"curl": "curl -d'{\"method\": \"claim_list\", \"params\": {\"claim_type\": [], \"claim_id\": [], \"name\": [], \"is_spent\": false, \"channel_id\": [], \"resolve\": false, \"no_totals\": false, \"include_received_tips\": false}}' http://localhost:5279/",
"lbrynet": "lbrynet claim list",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"claim_list\", \"params\": {\"claim_type\": [], \"claim_id\": [], \"name\": [], \"is_spent\": false, \"channel_id\": [], \"resolve\": false, \"no_totals\": false, \"include_received_tips\": false}}).json()",
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"items\": [\n {\n \"address\": \"muo3EZhx8VQtZsscvKLVCS2nk8tPeGSUKC\",\n \"amount\": \"1.0\",\n \"claim_id\": \"03d4002f8c09c4fac675ff2b3bb41bd6b3136f1b\",\n \"claim_op\": \"update\",\n \"confirmations\": 1,\n \"height\": 214,\n \"is_channel_signature_valid\": true,\n \"is_internal_transfer\": false,\n \"is_my_input\": true,\n \"is_my_output\": true,\n \"is_spent\": false,\n \"meta\": {},\n \"name\": \"astream\",\n \"normalized_name\": \"astream\",\n \"nout\": 0,\n \"permanent_url\": \"lbry://astream#03d4002f8c09c4fac675ff2b3bb41bd6b3136f1b\",\n \"signing_channel\": {\n \"address\": \"mth8FNCBtmx5M92AtxUpWigDPaB1g2xNpZ\",\n \"amount\": \"1.0\",\n \"claim_id\": \"2c20835e4289fe13bc88249efa4d20c2246b29d7\",\n \"claim_op\": \"update\",\n \"confirmations\": 5,\n \"has_signing_key\": true,\n \"height\": 210,\n \"meta\": {},\n \"name\": \"@channel\",\n \"normalized_name\": \"@channel\",\n \"nout\": 0,\n \"permanent_url\": \"lbry://@channel#2c20835e4289fe13bc88249efa4d20c2246b29d7\",\n \"timestamp\": 1602347163,\n \"txid\": \"db52235e2719bd2fe4e04d0c2de3c527fc84365f980fd5ce147a8d5725eb427c\",\n \"type\": \"claim\",\n \"value\": {\n \"public_key\": \"3056301006072a8648ce3d020106052b8104000a03420004bb438060971d65dfccc532c2c72357b802057d458a9143c2f863461ba8f5f79a512b770a19b80717467e0d0366e8097d3cf803a91609a2827d0701d6562e5a88\",\n \"public_key_id\": \"msagyzG92X562roXPRfSYQkmoNWzMYtZd8\",\n \"title\": \"New Channel\"\n },\n \"value_type\": \"channel\"\n },\n \"timestamp\": 1602347164,\n \"txid\": \"455ab61c9819a88dd7b0e7421251fc7883f0c9bafe790049db6e9716149e8e5e\",\n \"type\": \"claim\",\n \"value\": {\n \"source\": {\n \"hash\": \"fdbd8e75a67f29f701a4e040385e2e23986303ea10239211af907fcbb83578b3e417cb71ce646efd0819dd8c088de1bd\",\n \"media_type\": \"application/octet-stream\",\n \"name\": \"tmpoqm09_cn\",\n \"sd_hash\": \"f5dd1bd0df88ccbc2f016abaad0b3ffde5e87508dc7af1d964d51736fa260c5f25f2af741573d6bbd59ff458c554972b\",\n \"size\": \"11\"\n },\n \"stream_type\": \"binary\"\n },\n \"value_type\": \"stream\"\n },\n {\n \"address\": \"mth8FNCBtmx5M92AtxUpWigDPaB1g2xNpZ\",\n \"amount\": \"1.0\",\n \"claim_id\": \"2c20835e4289fe13bc88249efa4d20c2246b29d7\",\n \"claim_op\": \"update\",\n \"confirmations\": 5,\n \"has_signing_key\": true,\n \"height\": 210,\n \"is_internal_transfer\": false,\n \"is_my_input\": true,\n \"is_my_output\": true,\n \"is_spent\": false,\n \"meta\": {},\n \"name\": \"@channel\",\n \"normalized_name\": \"@channel\",\n \"nout\": 0,\n \"permanent_url\": \"lbry://@channel#2c20835e4289fe13bc88249efa4d20c2246b29d7\",\n \"timestamp\": 1602347163,\n \"txid\": \"db52235e2719bd2fe4e04d0c2de3c527fc84365f980fd5ce147a8d5725eb427c\",\n \"type\": \"claim\",\n \"value\": {\n \"public_key\": \"3056301006072a8648ce3d020106052b8104000a03420004bb438060971d65dfccc532c2c72357b802057d458a9143c2f863461ba8f5f79a512b770a19b80717467e0d0366e8097d3cf803a91609a2827d0701d6562e5a88\",\n \"public_key_id\": \"msagyzG92X562roXPRfSYQkmoNWzMYtZd8\",\n \"title\": \"New Channel\"\n },\n \"value_type\": \"channel\"\n }\n ],\n \"page\": 1,\n \"page_size\": 20,\n \"total_items\": 2,\n \"total_pages\": 1\n }\n}"
},
{
"title": "Paginate your claims",
"curl": "curl -d'{\"method\": \"claim_list\", \"params\": {\"claim_type\": [], \"claim_id\": [], \"name\": [], \"is_spent\": false, \"channel_id\": [], \"page\": 1, \"page_size\": 20, \"resolve\": false, \"no_totals\": false, \"include_received_tips\": false}}' http://localhost:5279/",
"lbrynet": "lbrynet claim list --page=1 --page_size=20",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"claim_list\", \"params\": {\"claim_type\": [], \"claim_id\": [], \"name\": [], \"is_spent\": false, \"channel_id\": [], \"page\": 1, \"page_size\": 20, \"resolve\": false, \"no_totals\": false, \"include_received_tips\": false}}).json()",
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"items\": [\n {\n \"address\": \"muo3EZhx8VQtZsscvKLVCS2nk8tPeGSUKC\",\n \"amount\": \"1.0\",\n \"claim_id\": \"03d4002f8c09c4fac675ff2b3bb41bd6b3136f1b\",\n \"claim_op\": \"update\",\n \"confirmations\": 1,\n \"height\": 214,\n \"is_channel_signature_valid\": true,\n \"is_internal_transfer\": false,\n \"is_my_input\": true,\n \"is_my_output\": true,\n \"is_spent\": false,\n \"meta\": {},\n \"name\": \"astream\",\n \"normalized_name\": \"astream\",\n \"nout\": 0,\n \"permanent_url\": \"lbry://astream#03d4002f8c09c4fac675ff2b3bb41bd6b3136f1b\",\n \"signing_channel\": {\n \"address\": \"mth8FNCBtmx5M92AtxUpWigDPaB1g2xNpZ\",\n \"amount\": \"1.0\",\n \"claim_id\": \"2c20835e4289fe13bc88249efa4d20c2246b29d7\",\n \"claim_op\": \"update\",\n \"confirmations\": 5,\n \"has_signing_key\": true,\n \"height\": 210,\n \"meta\": {},\n \"name\": \"@channel\",\n \"normalized_name\": \"@channel\",\n \"nout\": 0,\n \"permanent_url\": \"lbry://@channel#2c20835e4289fe13bc88249efa4d20c2246b29d7\",\n \"timestamp\": 1602347163,\n \"txid\": \"db52235e2719bd2fe4e04d0c2de3c527fc84365f980fd5ce147a8d5725eb427c\",\n \"type\": \"claim\",\n \"value\": {\n \"public_key\": \"3056301006072a8648ce3d020106052b8104000a03420004bb438060971d65dfccc532c2c72357b802057d458a9143c2f863461ba8f5f79a512b770a19b80717467e0d0366e8097d3cf803a91609a2827d0701d6562e5a88\",\n \"public_key_id\": \"msagyzG92X562roXPRfSYQkmoNWzMYtZd8\",\n \"title\": \"New Channel\"\n },\n \"value_type\": \"channel\"\n },\n \"timestamp\": 1602347164,\n \"txid\": \"455ab61c9819a88dd7b0e7421251fc7883f0c9bafe790049db6e9716149e8e5e\",\n \"type\": \"claim\",\n \"value\": {\n \"source\": {\n \"hash\": \"fdbd8e75a67f29f701a4e040385e2e23986303ea10239211af907fcbb83578b3e417cb71ce646efd0819dd8c088de1bd\",\n \"media_type\": \"application/octet-stream\",\n \"name\": \"tmpoqm09_cn\",\n \"sd_hash\": \"f5dd1bd0df88ccbc2f016abaad0b3ffde5e87508dc7af1d964d51736fa260c5f25f2af741573d6bbd59ff458c554972b\",\n \"size\": \"11\"\n },\n \"stream_type\": \"binary\"\n },\n \"value_type\": \"stream\"\n },\n {\n \"address\": \"mth8FNCBtmx5M92AtxUpWigDPaB1g2xNpZ\",\n \"amount\": \"1.0\",\n \"claim_id\": \"2c20835e4289fe13bc88249efa4d20c2246b29d7\",\n \"claim_op\": \"update\",\n \"confirmations\": 5,\n \"has_signing_key\": true,\n \"height\": 210,\n \"is_internal_transfer\": false,\n \"is_my_input\": true,\n \"is_my_output\": true,\n \"is_spent\": false,\n \"meta\": {},\n \"name\": \"@channel\",\n \"normalized_name\": \"@channel\",\n \"nout\": 0,\n \"permanent_url\": \"lbry://@channel#2c20835e4289fe13bc88249efa4d20c2246b29d7\",\n \"timestamp\": 1602347163,\n \"txid\": \"db52235e2719bd2fe4e04d0c2de3c527fc84365f980fd5ce147a8d5725eb427c\",\n \"type\": \"claim\",\n \"value\": {\n \"public_key\": \"3056301006072a8648ce3d020106052b8104000a03420004bb438060971d65dfccc532c2c72357b802057d458a9143c2f863461ba8f5f79a512b770a19b80717467e0d0366e8097d3cf803a91609a2827d0701d6562e5a88\",\n \"public_key_id\": \"msagyzG92X562roXPRfSYQkmoNWzMYtZd8\",\n \"title\": \"New Channel\"\n },\n \"value_type\": \"channel\"\n }\n ],\n \"page\": 1,\n \"page_size\": 20,\n \"total_items\": 2,\n \"total_pages\": 1\n }\n}"
}
]
},
{
"name": "claim_search",
"description": "Search for stream and channel claims on the blockchain.\n\nArguments marked with \"supports equality constraints\" allow prepending the\nvalue with an equality constraint such as '>', '>=', '<' and '<='\neg. --height=\">400000\" would limit results to only claims above 400k block height.",
"arguments": [
{
"name": "name",
"type": "str",
"description": "claim name (normalized)",
"is_required": false
},
{
"name": "text",
"type": "str",
"description": "full text search",
"is_required": false
},
{
"name": "claim_id",
"type": "str",
"description": "full or partial claim id",
"is_required": false
},
{
"name": "claim_ids",
"type": "list",
"description": "list of full claim ids",
"is_required": false
},
{
"name": "txid",
"type": "str",
"description": "transaction id",
"is_required": false
},
{
"name": "nout",
"type": "str",
"description": "position in the transaction",
"is_required": false
},
{
"name": "channel",
"type": "str",
"description": "claims signed by this channel (argument is a URL which automatically gets resolved), see --channel_ids if you need to filter by multiple channels at the same time, includes claims with invalid signatures, use in conjunction with --valid_channel_signature",
"is_required": false
},
{
"name": "channel_ids",
"type": "list",
"description": "claims signed by any of these channels (arguments must be claim ids of the channels), includes claims with invalid signatures, implies --has_channel_signature, use in conjunction with --valid_channel_signature",
"is_required": false
},
{
"name": "not_channel_ids",
"type": "list",
"description": "exclude claims signed by any of these channels (arguments must be claim ids of the channels)",
"is_required": false
},
{
"name": "has_channel_signature",
"type": "bool",
"description": "claims with a channel signature (valid or invalid)",
"is_required": false
},
{
"name": "valid_channel_signature",
"type": "bool",
"description": "claims with a valid channel signature or no signature, use in conjunction with --has_channel_signature to only get claims with valid signatures",
"is_required": false
},
{
"name": "invalid_channel_signature",
"type": "bool",
"description": "claims with invalid channel signature or no signature, use in conjunction with --has_channel_signature to only get claims with invalid signatures",
"is_required": false
},
{
"name": "limit_claims_per_channel",
"type": "int",
"description": "only return up to the specified number of claims per channel",
"is_required": false
},
{
"name": "is_controlling",
"type": "bool",
"description": "winning claims of their respective name",
"is_required": false
},
{
"name": "public_key_id",
"type": "str",
"description": "only return channels having this public key id, this is the same key as used in the wallet file to map channel certificate private keys: {'public_key_id': 'private key'}",
"is_required": false
},
{
"name": "height",
"type": "int",
"description": "last updated block height (supports equality constraints)",
"is_required": false
},
{
"name": "timestamp",
"type": "int",
"description": "last updated timestamp (supports equality constraints)",
"is_required": false
},
{
"name": "creation_height",
"type": "int",
"description": "created at block height (supports equality constraints)",
"is_required": false
},
{
"name": "creation_timestamp",
"type": "int",
"description": "created at timestamp (supports equality constraints)",
"is_required": false
},
{
"name": "activation_height",
"type": "int",
"description": "height at which claim starts competing for name (supports equality constraints)",
"is_required": false
},
{
"name": "expiration_height",
"type": "int",
"description": "height at which claim will expire (supports equality constraints)",
"is_required": false
},
{
"name": "release_time",
"type": "int",
"description": "limit to claims self-described as having been released to the public on or after this UTC timestamp, when claim does not provide a release time the publish time is used instead (supports equality constraints)",
"is_required": false
},
{
"name": "amount",
"type": "int",
"description": "limit by claim value (supports equality constraints)",
"is_required": false
},
{
"name": "support_amount",
"type": "int",
"description": "limit by supports and tips received (supports equality constraints)",
"is_required": false
},
{
"name": "effective_amount",
"type": "int",
"description": "limit by total value (initial claim value plus all tips and supports received), this amount is blank until claim has reached activation height (supports equality constraints)",
"is_required": false
},
{
"name": "trending_group",
"type": "int",
"description": "group numbers 1 through 4 representing the trending groups of the content: 4 means content is trending globally and independently, 3 means content is not trending globally but is trending independently (locally), 2 means it is trending globally but not independently and 1 means it's not trending globally or locally (supports equality constraints)",
"is_required": false
},
{
"name": "trending_mixed",
"type": "int",
"description": "trending amount taken from the global or local value depending on the trending group: 4 - global value, 3 - local value, 2 - global value, 1 - local value (supports equality constraints)",
"is_required": false
},
{
"name": "trending_local",
"type": "int",
"description": "trending value calculated relative only to the individual contents past history (supports equality constraints)",
"is_required": false
},
{
"name": "trending_global",
"type": "int",
"description": "trending value calculated relative to all trending content globally (supports equality constraints)",
"is_required": false
},
{
"name": "reposted_claim_id",
"type": "str",
"description": "all reposts of the specified original claim id",
"is_required": false
},
{
"name": "reposted",
"type": "int",
"description": "claims reposted this many times (supports equality constraints)",
"is_required": false
},
{
"name": "claim_type",
"type": "str",
"description": "filter by 'channel', 'stream' or 'unknown'",
"is_required": false
},
{
"name": "stream_types",
"type": "list",
"description": "filter by 'video', 'image', 'document', etc",
"is_required": false
},
{
"name": "media_types",
"type": "list",
"description": "filter by 'video/mp4', 'image/png', etc",
"is_required": false
},
{
"name": "fee_currency",
"type": "string",
"description": "specify fee currency: LBC, BTC, USD",
"is_required": false
},
{
"name": "fee_amount",
"type": "decimal",
"description": "content download fee (supports equality constraints)",
"is_required": false
},
{
"name": "duration",
"type": "int",
"description": "duration of video or audio in seconds (supports equality constraints)",
"is_required": false
},
{
"name": "any_tags",
"type": "list",
"description": "find claims containing any of the tags",
"is_required": false
},
{
"name": "all_tags",
"type": "list",
"description": "find claims containing every tag",
"is_required": false
},
{
"name": "not_tags",
"type": "list",
"description": "find claims not containing any of these tags",
"is_required": false
},
{
"name": "any_languages",
"type": "list",
"description": "find claims containing any of the languages",
"is_required": false
},
{
"name": "all_languages",
"type": "list",
"description": "find claims containing every language",
"is_required": false
},
{
"name": "not_languages",
"type": "list",
"description": "find claims not containing any of these languages",
"is_required": false
},
{
"name": "any_locations",
"type": "list",
"description": "find claims containing any of the locations",
"is_required": false
},
{
"name": "all_locations",
"type": "list",
"description": "find claims containing every location",
"is_required": false
},
{
"name": "not_locations",
"type": "list",
"description": "find claims not containing any of these locations",
"is_required": false
},
{
"name": "page",
"type": "int",
"description": "page to return during paginating",
"is_required": false
},
{
"name": "page_size",
"type": "int",
"description": "number of items on page during pagination",
"is_required": false
},
{
"name": "order_by",
"type": "list",
"description": "field to order by, default is descending order, to do an ascending order prepend ^ to the field name, eg. '^amount' available fields: 'name', 'height', 'release_time', 'publish_time', 'amount', 'effective_amount', 'support_amount', 'trending_group', 'trending_mixed', 'trending_local', 'trending_global', 'activation_height'",
"is_required": false
},
{
"name": "no_totals",
"type": "bool",
"description": "do not calculate the total number of pages and items in result set (significant performance boost)",
"is_required": false
},
{
"name": "wallet_id",
"type": "str",
"description": "wallet to check for claim purchase reciepts",
"is_required": false
},
{
"name": "include_purchase_receipt",
"type": "bool",
"description": "lookup and include a receipt if this wallet has purchased the claim",
"is_required": false
},
{
"name": "include_is_my_output",
"type": "bool",
"description": "lookup and include a boolean indicating if claim being resolved is yours",
"is_required": false
},
{
"name": "new_sdk_server",
"type": "str",
"description": "URL of the new SDK server (EXPERIMENTAL)",
"is_required": false
}
],
"returns": " {\n \"page\": \"Page number of the current items.\",\n \"page_size\": \"Number of items to show on a page.\",\n \"total_pages\": \"Total number of pages.\",\n \"total_items\": \"Total number of items.\",\n \"items\": [\n {\n \"txid\": \"hash of transaction in hex\",\n \"nout\": \"position in the transaction\",\n \"height\": \"block where transaction was recorded\",\n \"amount\": \"value of the txo as a decimal\",\n \"address\": \"address of who can spend the txo\",\n \"confirmations\": \"number of confirmed blocks\",\n \"is_change\": \"payment to change address, only available when it can be determined\",\n \"is_received\": \"true if txo was sent from external account to this account\",\n \"is_spent\": \"true if txo is spent\",\n \"is_mine\": \"payment to one of your accounts, only available when it can be determined\",\n \"type\": \"one of 'claim', 'support' or 'purchase'\",\n \"name\": \"when type is 'claim' or 'support', this is the claim name\",\n \"claim_id\": \"when type is 'claim', 'support' or 'purchase', this is the claim id\",\n \"claim_op\": \"when type is 'claim', this determines if it is 'create' or 'update'\",\n \"value\": \"when type is 'claim' or 'support' with payload, this is the decoded protobuf payload\",\n \"value_type\": \"determines the type of the 'value' field: 'channel', 'stream', etc\",\n \"protobuf\": \"hex encoded raw protobuf version of 'value' field\",\n \"permanent_url\": \"when type is 'claim' or 'support', this is the long permanent claim URL\",\n \"claim\": \"for purchase outputs only, metadata of purchased claim\",\n \"reposted_claim\": \"for repost claims only, metadata of claim being reposted\",\n \"signing_channel\": \"for signed claims only, metadata of signing channel\",\n \"is_channel_signature_valid\": \"for signed claims only, whether signature is valid\",\n \"purchase_receipt\": \"metadata for the purchase transaction associated with this claim\"\n }\n ]\n }",
"examples": [
{
"title": "Search for all claims in channel",
"curl": "curl -d'{\"method\": \"claim_search\", \"params\": {\"claim_ids\": [], \"channel\": \"@channel\", \"channel_ids\": [], \"not_channel_ids\": [], \"has_channel_signature\": false, \"valid_channel_signature\": false, \"invalid_channel_signature\": false, \"is_controlling\": false, \"stream_types\": [], \"media_types\": [], \"any_tags\": [], \"all_tags\": [], \"not_tags\": [], \"any_languages\": [], \"all_languages\": [], \"not_languages\": [], \"any_locations\": [], \"all_locations\": [], \"not_locations\": [], \"order_by\": [], \"include_purchase_receipt\": false, \"include_is_my_output\": false}}' http://localhost:5279/",
"lbrynet": "lbrynet claim search --channel=@channel",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"claim_search\", \"params\": {\"claim_ids\": [], \"channel\": \"@channel\", \"channel_ids\": [], \"not_channel_ids\": [], \"has_channel_signature\": false, \"valid_channel_signature\": false, \"invalid_channel_signature\": false, \"is_controlling\": false, \"stream_types\": [], \"media_types\": [], \"any_tags\": [], \"all_tags\": [], \"not_tags\": [], \"any_languages\": [], \"all_languages\": [], \"not_languages\": [], \"any_locations\": [], \"all_locations\": [], \"not_locations\": [], \"order_by\": [], \"include_purchase_receipt\": false, \"include_is_my_output\": false}}).json()",
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"blocked\": {\n \"channels\": [],\n \"total\": 0\n },\n \"items\": [\n {\n \"address\": \"muo3EZhx8VQtZsscvKLVCS2nk8tPeGSUKC\",\n \"amount\": \"1.0\",\n \"canonical_url\": \"lbry://@channel#2/astream#0\",\n \"claim_id\": \"03d4002f8c09c4fac675ff2b3bb41bd6b3136f1b\",\n \"claim_op\": \"update\",\n \"confirmations\": 1,\n \"height\": 214,\n \"is_channel_signature_valid\": true,\n \"meta\": {\n \"activation_height\": 213,\n \"creation_height\": 213,\n \"creation_timestamp\": 1602347164,\n \"effective_amount\": \"1.0\",\n \"expiration_height\": 263187,\n \"is_controlling\": true,\n \"reposted\": 0,\n \"support_amount\": \"0.0\",\n \"take_over_height\": 213,\n \"trending_global\": 0.0,\n \"trending_group\": 0,\n \"trending_local\": 0.0,\n \"trending_mixed\": 0.0\n },\n \"name\": \"astream\",\n \"normalized_name\": \"astream\",\n \"nout\": 0,\n \"permanent_url\": \"lbry://astream#03d4002f8c09c4fac675ff2b3bb41bd6b3136f1b\",\n \"short_url\": \"lbry://astream#0\",\n \"signing_channel\": {\n \"address\": \"mth8FNCBtmx5M92AtxUpWigDPaB1g2xNpZ\",\n \"amount\": \"1.0\",\n \"canonical_url\": \"lbry://@channel#2\",\n \"claim_id\": \"2c20835e4289fe13bc88249efa4d20c2246b29d7\",\n \"claim_op\": \"update\",\n \"confirmations\": 5,\n \"has_signing_key\": false,\n \"height\": 210,\n \"meta\": {\n \"activation_height\": 209,\n \"claims_in_channel\": 1,\n \"creation_height\": 209,\n \"creation_timestamp\": 1602347163,\n \"effective_amount\": \"1.0\",\n \"expiration_height\": 263183,\n \"is_controlling\": true,\n \"reposted\": 0,\n \"support_amount\": \"0.0\",\n \"take_over_height\": 209,\n \"trending_global\": 0.0,\n \"trending_group\": 0,\n \"trending_local\": 0.0,\n \"trending_mixed\": 0.0\n },\n \"name\": \"@channel\",\n \"normalized_name\": \"@channel\",\n \"nout\": 0,\n \"permanent_url\": \"lbry://@channel#2c20835e4289fe13bc88249efa4d20c2246b29d7\",\n \"short_url\": \"lbry://@channel#2\",\n \"timestamp\": 1602347163,\n \"txid\": \"db52235e2719bd2fe4e04d0c2de3c527fc84365f980fd5ce147a8d5725eb427c\",\n \"type\": \"claim\",\n \"value\": {\n \"public_key\": \"3056301006072a8648ce3d020106052b8104000a03420004bb438060971d65dfccc532c2c72357b802057d458a9143c2f863461ba8f5f79a512b770a19b80717467e0d0366e8097d3cf803a91609a2827d0701d6562e5a88\",\n \"public_key_id\": \"msagyzG92X562roXPRfSYQkmoNWzMYtZd8\",\n \"title\": \"New Channel\"\n },\n \"value_type\": \"channel\"\n },\n \"timestamp\": 1602347164,\n \"txid\": \"455ab61c9819a88dd7b0e7421251fc7883f0c9bafe790049db6e9716149e8e5e\",\n \"type\": \"claim\",\n \"value\": {\n \"source\": {\n \"hash\": \"fdbd8e75a67f29f701a4e040385e2e23986303ea10239211af907fcbb83578b3e417cb71ce646efd0819dd8c088de1bd\",\n \"media_type\": \"application/octet-stream\",\n \"name\": \"tmpoqm09_cn\",\n \"sd_hash\": \"f5dd1bd0df88ccbc2f016abaad0b3ffde5e87508dc7af1d964d51736fa260c5f25f2af741573d6bbd59ff458c554972b\",\n \"size\": \"11\"\n },\n \"stream_type\": \"binary\"\n },\n \"value_type\": \"stream\"\n }\n ],\n \"page\": 1,\n \"page_size\": 20,\n \"total_items\": 1,\n \"total_pages\": 1\n }\n}"
},
{
"title": "Search for claims matching a name",
"curl": "curl -d'{\"method\": \"claim_search\", \"params\": {\"name\": \"astream\", \"claim_ids\": [], \"channel_ids\": [], \"not_channel_ids\": [], \"has_channel_signature\": false, \"valid_channel_signature\": false, \"invalid_channel_signature\": false, \"is_controlling\": false, \"stream_types\": [], \"media_types\": [], \"any_tags\": [], \"all_tags\": [], \"not_tags\": [], \"any_languages\": [], \"all_languages\": [], \"not_languages\": [], \"any_locations\": [], \"all_locations\": [], \"not_locations\": [], \"order_by\": [], \"include_purchase_receipt\": false, \"include_is_my_output\": false}}' http://localhost:5279/",
"lbrynet": "lbrynet claim search --name=\"astream\"",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"claim_search\", \"params\": {\"name\": \"astream\", \"claim_ids\": [], \"channel_ids\": [], \"not_channel_ids\": [], \"has_channel_signature\": false, \"valid_channel_signature\": false, \"invalid_channel_signature\": false, \"is_controlling\": false, \"stream_types\": [], \"media_types\": [], \"any_tags\": [], \"all_tags\": [], \"not_tags\": [], \"any_languages\": [], \"all_languages\": [], \"not_languages\": [], \"any_locations\": [], \"all_locations\": [], \"not_locations\": [], \"order_by\": [], \"include_purchase_receipt\": false, \"include_is_my_output\": false}}).json()",
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"blocked\": {\n \"channels\": [],\n \"total\": 0\n },\n \"items\": [\n {\n \"address\": \"muo3EZhx8VQtZsscvKLVCS2nk8tPeGSUKC\",\n \"amount\": \"1.0\",\n \"canonical_url\": \"lbry://@channel#2/astream#0\",\n \"claim_id\": \"03d4002f8c09c4fac675ff2b3bb41bd6b3136f1b\",\n \"claim_op\": \"update\",\n \"confirmations\": 1,\n \"height\": 214,\n \"is_channel_signature_valid\": true,\n \"meta\": {\n \"activation_height\": 213,\n \"creation_height\": 213,\n \"creation_timestamp\": 1602347164,\n \"effective_amount\": \"1.0\",\n \"expiration_height\": 263187,\n \"is_controlling\": true,\n \"reposted\": 0,\n \"support_amount\": \"0.0\",\n \"take_over_height\": 213,\n \"trending_global\": 0.0,\n \"trending_group\": 0,\n \"trending_local\": 0.0,\n \"trending_mixed\": 0.0\n },\n \"name\": \"astream\",\n \"normalized_name\": \"astream\",\n \"nout\": 0,\n \"permanent_url\": \"lbry://astream#03d4002f8c09c4fac675ff2b3bb41bd6b3136f1b\",\n \"short_url\": \"lbry://astream#0\",\n \"signing_channel\": {\n \"address\": \"mth8FNCBtmx5M92AtxUpWigDPaB1g2xNpZ\",\n \"amount\": \"1.0\",\n \"canonical_url\": \"lbry://@channel#2\",\n \"claim_id\": \"2c20835e4289fe13bc88249efa4d20c2246b29d7\",\n \"claim_op\": \"update\",\n \"confirmations\": 5,\n \"has_signing_key\": false,\n \"height\": 210,\n \"meta\": {\n \"activation_height\": 209,\n \"claims_in_channel\": 1,\n \"creation_height\": 209,\n \"creation_timestamp\": 1602347163,\n \"effective_amount\": \"1.0\",\n \"expiration_height\": 263183,\n \"is_controlling\": true,\n \"reposted\": 0,\n \"support_amount\": \"0.0\",\n \"take_over_height\": 209,\n \"trending_global\": 0.0,\n \"trending_group\": 0,\n \"trending_local\": 0.0,\n \"trending_mixed\": 0.0\n },\n \"name\": \"@channel\",\n \"normalized_name\": \"@channel\",\n \"nout\": 0,\n \"permanent_url\": \"lbry://@channel#2c20835e4289fe13bc88249efa4d20c2246b29d7\",\n \"short_url\": \"lbry://@channel#2\",\n \"timestamp\": 1602347163,\n \"txid\": \"db52235e2719bd2fe4e04d0c2de3c527fc84365f980fd5ce147a8d5725eb427c\",\n \"type\": \"claim\",\n \"value\": {\n \"public_key\": \"3056301006072a8648ce3d020106052b8104000a03420004bb438060971d65dfccc532c2c72357b802057d458a9143c2f863461ba8f5f79a512b770a19b80717467e0d0366e8097d3cf803a91609a2827d0701d6562e5a88\",\n \"public_key_id\": \"msagyzG92X562roXPRfSYQkmoNWzMYtZd8\",\n \"title\": \"New Channel\"\n },\n \"value_type\": \"channel\"\n },\n \"timestamp\": 1602347164,\n \"txid\": \"455ab61c9819a88dd7b0e7421251fc7883f0c9bafe790049db6e9716149e8e5e\",\n \"type\": \"claim\",\n \"value\": {\n \"source\": {\n \"hash\": \"fdbd8e75a67f29f701a4e040385e2e23986303ea10239211af907fcbb83578b3e417cb71ce646efd0819dd8c088de1bd\",\n \"media_type\": \"application/octet-stream\",\n \"name\": \"tmpoqm09_cn\",\n \"sd_hash\": \"f5dd1bd0df88ccbc2f016abaad0b3ffde5e87508dc7af1d964d51736fa260c5f25f2af741573d6bbd59ff458c554972b\",\n \"size\": \"11\"\n },\n \"stream_type\": \"binary\"\n },\n \"value_type\": \"stream\"\n }\n ],\n \"page\": 1,\n \"page_size\": 20,\n \"total_items\": 1,\n \"total_pages\": 1\n }\n}"
}
]
}
]
},
"collection": {
"doc": "Create, update, list, resolve, and abandon collections.",
"commands": [
{
"name": "collection_abandon",
"description": "Abandon one of my collection claims.",
"arguments": [
{
"name": "claim_id",
"type": "str",
"description": "claim_id of the claim to abandon",
"is_required": false
},
{
"name": "txid",
"type": "str",
"description": "txid of the claim to abandon",
"is_required": false
},
{
"name": "nout",
"type": "int",
"description": "nout of the claim to abandon",
"is_required": false
},
{
"name": "account_id",
"type": "str",
"description": "id of the account to use",
"is_required": false
},
{
"name": "wallet_id",
"type": "str",
"description": "restrict operation to specific wallet",
"is_required": false
},
{
"name": "preview",
"type": "bool",
"description": "do not broadcast the transaction",
"is_required": false
},
{
"name": "blocking",
"type": "bool",
"description": "wait until abandon is in mempool",
"is_required": false
}
],
"returns": " {\n \"txid\": \"hash of transaction in hex\",\n \"height\": \"block where transaction was recorded\",\n \"inputs\": [\n {\n \"txid\": \"hash of transaction in hex\",\n \"nout\": \"position in the transaction\",\n \"height\": \"block where transaction was recorded\",\n \"amount\": \"value of the txo as a decimal\",\n \"address\": \"address of who can spend the txo\",\n \"confirmations\": \"number of confirmed blocks\",\n \"is_change\": \"payment to change address, only available when it can be determined\",\n \"is_received\": \"true if txo was sent from external account to this account\",\n \"is_spent\": \"true if txo is spent\",\n \"is_mine\": \"payment to one of your accounts, only available when it can be determined\",\n \"type\": \"one of 'claim', 'support' or 'purchase'\",\n \"name\": \"when type is 'claim' or 'support', this is the claim name\",\n \"claim_id\": \"when type is 'claim', 'support' or 'purchase', this is the claim id\",\n \"claim_op\": \"when type is 'claim', this determines if it is 'create' or 'update'\",\n \"value\": \"when type is 'claim' or 'support' with payload, this is the decoded protobuf payload\",\n \"value_type\": \"determines the type of the 'value' field: 'channel', 'stream', etc\",\n \"protobuf\": \"hex encoded raw protobuf version of 'value' field\",\n \"permanent_url\": \"when type is 'claim' or 'support', this is the long permanent claim URL\",\n \"claim\": \"for purchase outputs only, metadata of purchased claim\",\n \"reposted_claim\": \"for repost claims only, metadata of claim being reposted\",\n \"signing_channel\": \"for signed claims only, metadata of signing channel\",\n \"is_channel_signature_valid\": \"for signed claims only, whether signature is valid\",\n \"purchase_receipt\": \"metadata for the purchase transaction associated with this claim\"\n }\n ],\n \"outputs\": [\n {\n \"txid\": \"hash of transaction in hex\",\n \"nout\": \"position in the transaction\",\n \"height\": \"block where transaction was recorded\",\n \"amount\": \"value of the txo as a decimal\",\n \"address\": \"address of who can spend the txo\",\n \"confirmations\": \"number of confirmed blocks\",\n \"is_change\": \"payment to change address, only available when it can be determined\",\n \"is_received\": \"true if txo was sent from external account to this account\",\n \"is_spent\": \"true if txo is spent\",\n \"is_mine\": \"payment to one of your accounts, only available when it can be determined\",\n \"type\": \"one of 'claim', 'support' or 'purchase'\",\n \"name\": \"when type is 'claim' or 'support', this is the claim name\",\n \"claim_id\": \"when type is 'claim', 'support' or 'purchase', this is the claim id\",\n \"claim_op\": \"when type is 'claim', this determines if it is 'create' or 'update'\",\n \"value\": \"when type is 'claim' or 'support' with payload, this is the decoded protobuf payload\",\n \"value_type\": \"determines the type of the 'value' field: 'channel', 'stream', etc\",\n \"protobuf\": \"hex encoded raw protobuf version of 'value' field\",\n \"permanent_url\": \"when type is 'claim' or 'support', this is the long permanent claim URL\",\n \"claim\": \"for purchase outputs only, metadata of purchased claim\",\n \"reposted_claim\": \"for repost claims only, metadata of claim being reposted\",\n \"signing_channel\": \"for signed claims only, metadata of signing channel\",\n \"is_channel_signature_valid\": \"for signed claims only, whether signature is valid\",\n \"purchase_receipt\": \"metadata for the purchase transaction associated with this claim\"\n }\n ],\n \"total_input\": \"sum of inputs as a decimal\",\n \"total_output\": \"sum of outputs, sans fee, as a decimal\",\n \"total_fee\": \"fee amount\",\n \"hex\": \"entire transaction encoded in hex\"\n }",
"examples": []
},
{
"name": "collection_create",
"description": "Create a new collection.",
"arguments": [
{
"name": "name",
"type": "str",
"description": "name of the collection",
"is_required": true
},
{
"name": "bid",
"type": "decimal",
"description": "amount to back the claim",
"is_required": true
},
{
"name": "claims",
"type": "list",
"description": "claim ids to be included in the collection",
"is_required": true
},
{
"name": "allow_duplicate_name",
"type": "bool",
"description": "create new collection even if one already exists with given name. default: false.",
"is_required": false
},
{
"name": "title",
"type": "str",
"description": "title of the collection",
"is_required": false
},
{
"name": "description",
"type": "str",
"description": "description of the collection",
"is_required": false
},
{
"name": "tags",
"type": "list",
"description": "content tags",
"is_required": false
},
{
"name": "clear_languages",
"type": "bool",
"description": "clear existing languages (prior to adding new ones)",
"is_required": false
},
{
"name": "languages",
"type": "list",
"description": "languages used by the collection, using RFC 5646 format, eg: for English `--languages=en` for Spanish (Spain) `--languages=es-ES` for Spanish (Mexican) `--languages=es-MX` for Chinese (Simplified) `--languages=zh-Hans` for Chinese (Traditional) `--languages=zh-Hant`",
"is_required": false
},
{
"name": "locations",
"type": "list",
"description": "locations of the collection, consisting of 2 letter `country` code and a `state`, `city` and a postal `code` along with a `latitude` and `longitude`. for JSON RPC: pass a dictionary with aforementioned attributes as keys, eg: ... \"locations\": [{'country': 'US', 'state': 'NH'}] ... for command line: pass a colon delimited list with values in the following order: \"COUNTRY:STATE:CITY:CODE:LATITUDE:LONGITUDE\" making sure to include colon for blank values, for example to provide only the city: ... --locations=\"::Manchester\" with all values set: ... --locations=\"US:NH:Manchester:03101:42.990605:-71.460989\" optionally, you can just pass the \"LATITUDE:LONGITUDE\": ... --locations=\"42.990605:-71.460989\" finally, you can also pass JSON string of dictionary on the command line as you would via JSON RPC ... --locations=\"{'country': 'US', 'state': 'NH'}\"",
"is_required": false
},
{
"name": "thumbnail_url",
"type": "str",
"description": "thumbnail url",
"is_required": false
},
{
"name": "account_id",
"type": "str",
"description": "account to use for holding the transaction",
"is_required": false
},
{
"name": "wallet_id",
"type": "str",
"description": "restrict operation to specific wallet",
"is_required": false
},
{
"name": "funding_account_ids",
"type": "list",
"description": "ids of accounts to fund this transaction",
"is_required": false
},
{
"name": "claim_address",
"type": "str",
"description": "address where the collection is sent to, if not specified it will be determined automatically from the account",
"is_required": false
},
{
"name": "preview",
"type": "bool",
"description": "do not broadcast the transaction",
"is_required": false
},
{
"name": "blocking",
"type": "bool",
"description": "wait until transaction is in mempool",
"is_required": false
}
],
"returns": " {\n \"txid\": \"hash of transaction in hex\",\n \"height\": \"block where transaction was recorded\",\n \"inputs\": [\n {\n \"txid\": \"hash of transaction in hex\",\n \"nout\": \"position in the transaction\",\n \"height\": \"block where transaction was recorded\",\n \"amount\": \"value of the txo as a decimal\",\n \"address\": \"address of who can spend the txo\",\n \"confirmations\": \"number of confirmed blocks\",\n \"is_change\": \"payment to change address, only available when it can be determined\",\n \"is_received\": \"true if txo was sent from external account to this account\",\n \"is_spent\": \"true if txo is spent\",\n \"is_mine\": \"payment to one of your accounts, only available when it can be determined\",\n \"type\": \"one of 'claim', 'support' or 'purchase'\",\n \"name\": \"when type is 'claim' or 'support', this is the claim name\",\n \"claim_id\": \"when type is 'claim', 'support' or 'purchase', this is the claim id\",\n \"claim_op\": \"when type is 'claim', this determines if it is 'create' or 'update'\",\n \"value\": \"when type is 'claim' or 'support' with payload, this is the decoded protobuf payload\",\n \"value_type\": \"determines the type of the 'value' field: 'channel', 'stream', etc\",\n \"protobuf\": \"hex encoded raw protobuf version of 'value' field\",\n \"permanent_url\": \"when type is 'claim' or 'support', this is the long permanent claim URL\",\n \"claim\": \"for purchase outputs only, metadata of purchased claim\",\n \"reposted_claim\": \"for repost claims only, metadata of claim being reposted\",\n \"signing_channel\": \"for signed claims only, metadata of signing channel\",\n \"is_channel_signature_valid\": \"for signed claims only, whether signature is valid\",\n \"purchase_receipt\": \"metadata for the purchase transaction associated with this claim\"\n }\n ],\n \"outputs\": [\n {\n \"txid\": \"hash of transaction in hex\",\n \"nout\": \"position in the transaction\",\n \"height\": \"block where transaction was recorded\",\n \"amount\": \"value of the txo as a decimal\",\n \"address\": \"address of who can spend the txo\",\n \"confirmations\": \"number of confirmed blocks\",\n \"is_change\": \"payment to change address, only available when it can be determined\",\n \"is_received\": \"true if txo was sent from external account to this account\",\n \"is_spent\": \"true if txo is spent\",\n \"is_mine\": \"payment to one of your accounts, only available when it can be determined\",\n \"type\": \"one of 'claim', 'support' or 'purchase'\",\n \"name\": \"when type is 'claim' or 'support', this is the claim name\",\n \"claim_id\": \"when type is 'claim', 'support' or 'purchase', this is the claim id\",\n \"claim_op\": \"when type is 'claim', this determines if it is 'create' or 'update'\",\n \"value\": \"when type is 'claim' or 'support' with payload, this is the decoded protobuf payload\",\n \"value_type\": \"determines the type of the 'value' field: 'channel', 'stream', etc\",\n \"protobuf\": \"hex encoded raw protobuf version of 'value' field\",\n \"permanent_url\": \"when type is 'claim' or 'support', this is the long permanent claim URL\",\n \"claim\": \"for purchase outputs only, metadata of purchased claim\",\n \"reposted_claim\": \"for repost claims only, metadata of claim being reposted\",\n \"signing_channel\": \"for signed claims only, metadata of signing channel\",\n \"is_channel_signature_valid\": \"for signed claims only, whether signature is valid\",\n \"purchase_receipt\": \"metadata for the purchase transaction associated with this claim\"\n }\n ],\n \"total_input\": \"sum of inputs as a decimal\",\n \"total_output\": \"sum of outputs, sans fee, as a decimal\",\n \"total_fee\": \"fee amount\",\n \"hex\": \"entire transaction encoded in hex\"\n }",
"examples": []
},
{
"name": "collection_list",
"description": "List my collection claims.",
"arguments": [
{
"name": "resolve_claims",
"type": "int",
"description": "resolve every claim",
"is_required": false
},
{
"name": "account_id",
"type": "str",
"description": "id of the account to use",
"is_required": false
},
{
"name": "wallet_id",
"type": "str",
"description": "restrict results to specific wallet",
"is_required": false
},
{
"name": "page",
"type": "int",
"description": "page to return during paginating",
"is_required": false
},
{
"name": "page_size",
"type": "int",
"description": "number of items on page during pagination",
"is_required": false
}
],
"returns": " {\n \"page\": \"Page number of the current items.\",\n \"page_size\": \"Number of items to show on a page.\",\n \"total_pages\": \"Total number of pages.\",\n \"total_items\": \"Total number of items.\",\n \"items\": [\n {\n \"txid\": \"hash of transaction in hex\",\n \"nout\": \"position in the transaction\",\n \"height\": \"block where transaction was recorded\",\n \"amount\": \"value of the txo as a decimal\",\n \"address\": \"address of who can spend the txo\",\n \"confirmations\": \"number of confirmed blocks\",\n \"is_change\": \"payment to change address, only available when it can be determined\",\n \"is_received\": \"true if txo was sent from external account to this account\",\n \"is_spent\": \"true if txo is spent\",\n \"is_mine\": \"payment to one of your accounts, only available when it can be determined\",\n \"type\": \"one of 'claim', 'support' or 'purchase'\",\n \"name\": \"when type is 'claim' or 'support', this is the claim name\",\n \"claim_id\": \"when type is 'claim', 'support' or 'purchase', this is the claim id\",\n \"claim_op\": \"when type is 'claim', this determines if it is 'create' or 'update'\",\n \"value\": \"when type is 'claim' or 'support' with payload, this is the decoded protobuf payload\",\n \"value_type\": \"determines the type of the 'value' field: 'channel', 'stream', etc\",\n \"protobuf\": \"hex encoded raw protobuf version of 'value' field\",\n \"permanent_url\": \"when type is 'claim' or 'support', this is the long permanent claim URL\",\n \"claim\": \"for purchase outputs only, metadata of purchased claim\",\n \"reposted_claim\": \"for repost claims only, metadata of claim being reposted\",\n \"signing_channel\": \"for signed claims only, metadata of signing channel\",\n \"is_channel_signature_valid\": \"for signed claims only, whether signature is valid\",\n \"purchase_receipt\": \"metadata for the purchase transaction associated with this claim\"\n }\n ]\n }",
"examples": []
},
{
"name": "collection_resolve",
"description": "Resolve claims in the collection.",
"arguments": [
{
"name": "claim_id",
"type": "str",
"description": "claim id of the collection",
"is_required": false
},
{
"name": "url",
"type": "str",
"description": "url of the collection",
"is_required": false
},
{
"name": "wallet_id",
"type": "str",
"description": "restrict results to specific wallet",
"is_required": false
},
{
"name": "page",
"type": "int",
"description": "page to return during paginating",
"is_required": false
},
{
"name": "page_size",
"type": "int",
"description": "number of items on page during pagination",
"is_required": false
}
],
"returns": " {\n \"page\": \"Page number of the current items.\",\n \"page_size\": \"Number of items to show on a page.\",\n \"total_pages\": \"Total number of pages.\",\n \"total_items\": \"Total number of items.\",\n \"items\": [\n {\n \"txid\": \"hash of transaction in hex\",\n \"nout\": \"position in the transaction\",\n \"height\": \"block where transaction was recorded\",\n \"amount\": \"value of the txo as a decimal\",\n \"address\": \"address of who can spend the txo\",\n \"confirmations\": \"number of confirmed blocks\",\n \"is_change\": \"payment to change address, only available when it can be determined\",\n \"is_received\": \"true if txo was sent from external account to this account\",\n \"is_spent\": \"true if txo is spent\",\n \"is_mine\": \"payment to one of your accounts, only available when it can be determined\",\n \"type\": \"one of 'claim', 'support' or 'purchase'\",\n \"name\": \"when type is 'claim' or 'support', this is the claim name\",\n \"claim_id\": \"when type is 'claim', 'support' or 'purchase', this is the claim id\",\n \"claim_op\": \"when type is 'claim', this determines if it is 'create' or 'update'\",\n \"value\": \"when type is 'claim' or 'support' with payload, this is the decoded protobuf payload\",\n \"value_type\": \"determines the type of the 'value' field: 'channel', 'stream', etc\",\n \"protobuf\": \"hex encoded raw protobuf version of 'value' field\",\n \"permanent_url\": \"when type is 'claim' or 'support', this is the long permanent claim URL\",\n \"claim\": \"for purchase outputs only, metadata of purchased claim\",\n \"reposted_claim\": \"for repost claims only, metadata of claim being reposted\",\n \"signing_channel\": \"for signed claims only, metadata of signing channel\",\n \"is_channel_signature_valid\": \"for signed claims only, whether signature is valid\",\n \"purchase_receipt\": \"metadata for the purchase transaction associated with this claim\"\n }\n ]\n }",
"examples": []
},
{
"name": "collection_update",
"description": "Update an existing collection claim.",
"arguments": [
{
"name": "claim_id",
"type": "str",
"description": "claim_id of the collection to update",
"is_required": true
},
{
"name": "bid",
"type": "decimal",
"description": "amount to back the claim",
"is_required": false
},
{
"name": "claims",
"type": "list",
"description": "claim ids",
"is_required": false
},
{
"name": "clear_claims",
"type": "bool",
"description": "clear existing claim references (prior to adding new ones)",
"is_required": false
},
{
"name": "title",
"type": "str",
"description": "title of the collection",
"is_required": false
},
{
"name": "description",
"type": "str",
"description": "description of the collection",
"is_required": false
},
{
"name": "tags",
"type": "list",
"description": "add content tags",
"is_required": false
},
{
"name": "clear_tags",
"type": "bool",
"description": "clear existing tags (prior to adding new ones)",
"is_required": false
},
{
"name": "languages",
"type": "list",
"description": "languages used by the collection, using RFC 5646 format, eg: for English `--languages=en` for Spanish (Spain) `--languages=es-ES` for Spanish (Mexican) `--languages=es-MX` for Chinese (Simplified) `--languages=zh-Hans` for Chinese (Traditional) `--languages=zh-Hant`",
"is_required": false
},
{
"name": "clear_languages",
"type": "bool",
"description": "clear existing languages (prior to adding new ones)",
"is_required": false
},
{
"name": "locations",
"type": "list",
"description": "locations of the collection, consisting of 2 letter `country` code and a `state`, `city` and a postal `code` along with a `latitude` and `longitude`. for JSON RPC: pass a dictionary with aforementioned attributes as keys, eg: ... \"locations\": [{'country': 'US', 'state': 'NH'}] ... for command line: pass a colon delimited list with values in the following order: \"COUNTRY:STATE:CITY:CODE:LATITUDE:LONGITUDE\" making sure to include colon for blank values, for example to provide only the city: ... --locations=\"::Manchester\" with all values set: ... --locations=\"US:NH:Manchester:03101:42.990605:-71.460989\" optionally, you can just pass the \"LATITUDE:LONGITUDE\": ... --locations=\"42.990605:-71.460989\" finally, you can also pass JSON string of dictionary on the command line as you would via JSON RPC ... --locations=\"{'country': 'US', 'state': 'NH'}\"",
"is_required": false
},
{
"name": "clear_locations",
"type": "bool",
"description": "clear existing locations (prior to adding new ones)",
"is_required": false
},
{
"name": "thumbnail_url",
"type": "str",
"description": "thumbnail url",
"is_required": false
},
{
"name": "account_id",
"type": "str",
"description": "account in which to look for collection (default: all)",
"is_required": false
},
{
"name": "wallet_id",
"type": "str",
"description": "restrict operation to specific wallet",
"is_required": false
},
{
"name": "funding_account_ids",
"type": "list",
"description": "ids of accounts to fund this transaction",
"is_required": false
},
{
"name": "claim_address",
"type": "str",
"description": "address where the collection is sent",
"is_required": false
},
{
"name": "new_signing_key",
"type": "bool",
"description": "generate a new signing key, will invalidate all previous publishes",
"is_required": false
},
{
"name": "preview",
"type": "bool",
"description": "do not broadcast the transaction",
"is_required": false
},
{
"name": "blocking",
"type": "bool",
"description": "wait until transaction is in mempool",
"is_required": false
},
{
"name": "replace",
"type": "bool",
"description": "instead of modifying specific values on the collection, this will clear all existing values and only save passed in values, useful for form submissions where all values are always set",
"is_required": false
}
],
"returns": " {\n \"txid\": \"hash of transaction in hex\",\n \"height\": \"block where transaction was recorded\",\n \"inputs\": [\n {\n \"txid\": \"hash of transaction in hex\",\n \"nout\": \"position in the transaction\",\n \"height\": \"block where transaction was recorded\",\n \"amount\": \"value of the txo as a decimal\",\n \"address\": \"address of who can spend the txo\",\n \"confirmations\": \"number of confirmed blocks\",\n \"is_change\": \"payment to change address, only available when it can be determined\",\n \"is_received\": \"true if txo was sent from external account to this account\",\n \"is_spent\": \"true if txo is spent\",\n \"is_mine\": \"payment to one of your accounts, only available when it can be determined\",\n \"type\": \"one of 'claim', 'support' or 'purchase'\",\n \"name\": \"when type is 'claim' or 'support', this is the claim name\",\n \"claim_id\": \"when type is 'claim', 'support' or 'purchase', this is the claim id\",\n \"claim_op\": \"when type is 'claim', this determines if it is 'create' or 'update'\",\n \"value\": \"when type is 'claim' or 'support' with payload, this is the decoded protobuf payload\",\n \"value_type\": \"determines the type of the 'value' field: 'channel', 'stream', etc\",\n \"protobuf\": \"hex encoded raw protobuf version of 'value' field\",\n \"permanent_url\": \"when type is 'claim' or 'support', this is the long permanent claim URL\",\n \"claim\": \"for purchase outputs only, metadata of purchased claim\",\n \"reposted_claim\": \"for repost claims only, metadata of claim being reposted\",\n \"signing_channel\": \"for signed claims only, metadata of signing channel\",\n \"is_channel_signature_valid\": \"for signed claims only, whether signature is valid\",\n \"purchase_receipt\": \"metadata for the purchase transaction associated with this claim\"\n }\n ],\n \"outputs\": [\n {\n \"txid\": \"hash of transaction in hex\",\n \"nout\": \"position in the transaction\",\n \"height\": \"block where transaction was recorded\",\n \"amount\": \"value of the txo as a decimal\",\n \"address\": \"address of who can spend the txo\",\n \"confirmations\": \"number of confirmed blocks\",\n \"is_change\": \"payment to change address, only available when it can be determined\",\n \"is_received\": \"true if txo was sent from external account to this account\",\n \"is_spent\": \"true if txo is spent\",\n \"is_mine\": \"payment to one of your accounts, only available when it can be determined\",\n \"type\": \"one of 'claim', 'support' or 'purchase'\",\n \"name\": \"when type is 'claim' or 'support', this is the claim name\",\n \"claim_id\": \"when type is 'claim', 'support' or 'purchase', this is the claim id\",\n \"claim_op\": \"when type is 'claim', this determines if it is 'create' or 'update'\",\n \"value\": \"when type is 'claim' or 'support' with payload, this is the decoded protobuf payload\",\n \"value_type\": \"determines the type of the 'value' field: 'channel', 'stream', etc\",\n \"protobuf\": \"hex encoded raw protobuf version of 'value' field\",\n \"permanent_url\": \"when type is 'claim' or 'support', this is the long permanent claim URL\",\n \"claim\": \"for purchase outputs only, metadata of purchased claim\",\n \"reposted_claim\": \"for repost claims only, metadata of claim being reposted\",\n \"signing_channel\": \"for signed claims only, metadata of signing channel\",\n \"is_channel_signature_valid\": \"for signed claims only, whether signature is valid\",\n \"purchase_receipt\": \"metadata for the purchase transaction associated with this claim\"\n }\n ],\n \"total_input\": \"sum of inputs as a decimal\",\n \"total_output\": \"sum of outputs, sans fee, as a decimal\",\n \"total_fee\": \"fee amount\",\n \"hex\": \"entire transaction encoded in hex\"\n }",
"examples": []
}
]
},
"comment": {
"doc": "View, create and abandon comments.",
"commands": [
{
"name": "comment_abandon",
"description": "Abandon a comment published under your channel identity.",
"arguments": [
{
"name": "comment_id",
"type": "str",
"description": "The ID of the comment to be abandoned.",
"is_required": true
},
{
"name": "wallet_id",
"type": "str",
"description": "restrict operation to specific wallet",
"is_required": false
}
],
"returns": "(dict) Object with the `comment_id` passed in as the key, and a flag indicating if it was abandoned\n {\n <comment_id> (str): {\n \"abandoned\": (bool)\n }\n }",
"examples": [
{
"title": "Abandon a comment",
"curl": "curl -d'{\"method\": \"comment_abandon\", \"params\": {\"comment_id\": \"8273c3d6ed1cbed8301a19937c3b2d2c0707ce95deeb17f8727c01cf8b05bb75\"}}' http://localhost:5279/",
"lbrynet": "lbrynet comment abandon 8273c3d6ed1cbed8301a19937c3b2d2c0707ce95deeb17f8727c01cf8b05bb75",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"comment_abandon\", \"params\": {\"comment_id\": \"8273c3d6ed1cbed8301a19937c3b2d2c0707ce95deeb17f8727c01cf8b05bb75\"}}).json()",
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"error\": {\n \"code\": -32000,\n \"data\": null,\n \"message\": \"could not get claim from sdk with claim id 2c20835e4289fe13bc88249efa4d20c2246b29d7\"\n },\n \"id\": 1,\n \"jsonrpc\": \"2.0\"\n }\n}"
}
]
},
{
"name": "comment_create",
"description": "Create and associate a comment with a claim using your channel identity.",
"arguments": [
{
"name": "comment",
"type": "str",
"description": "Comment to be made, should be at most 2000 characters.",
"is_required": true
},
{
"name": "claim_id",
"type": "str",
"description": "The ID of the claim to comment on",
"is_required": true
},
{
"name": "parent_id",
"type": "str",
"description": "The ID of a comment to make a response to",
"is_required": false
},
{
"name": "channel_id",
"type": "str",
"description": "The ID of the channel you want to post under",
"is_required": false
},
{
"name": "channel_name",
"type": "str",
"description": "The channel you want to post as, prepend with a '@'",
"is_required": false
},
{
"name": "channel_account_id",
"type": "str",
"description": "one or more account ids for accounts to look in for channel certificates, defaults to all accounts",
"is_required": false
},
{
"name": "wallet_id",
"type": "str",
"description": "restrict operation to specific wallet",
"is_required": false
}
],
"returns": "(dict) Comment object if successfully made, (None) otherwise\n {\n \"comment\": (str) The actual string as inputted by the user,\n \"comment_id\": (str) The Comment's unique identifier,\n \"claim_id\": (str) The claim commented on,\n \"channel_name\": (str) Name of the channel this was posted under, prepended with a '@',\n \"channel_id\": (str) The Channel Claim ID that this comment was posted under,\n \"is_pinned\": (boolean) Channel owner has pinned this comment,\n \"signature\": (str) The signature of the comment,\n \"signing_ts\": (str) The timestamp used to sign the comment,\n \"channel_url\": (str) Channel's URI in the ClaimTrie,\n \"parent_id\": (str) Comment this is replying to, (None) if this is the root,\n \"timestamp\": (int) The time at which comment was entered into the server at, in nanoseconds.\n }",
"examples": [
{
"title": "Posting a comment as your channel",
"curl": "curl -d'{\"method\": \"comment_create\", \"params\": {\"comment\": \"Thank you Based God\", \"claim_id\": \"03d4002f8c09c4fac675ff2b3bb41bd6b3136f1b\", \"channel_name\": \"@channel\", \"channel_account_id\": []}}' http://localhost:5279/",
"lbrynet": "lbrynet comment create --comment=\"Thank you Based God\" --channel_name=@channel --claim_id=03d4002f8c09c4fac675ff2b3bb41bd6b3136f1b",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"comment_create\", \"params\": {\"comment\": \"Thank you Based God\", \"claim_id\": \"03d4002f8c09c4fac675ff2b3bb41bd6b3136f1b\", \"channel_name\": \"@channel\", \"channel_account_id\": []}}).json()",
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"channel_id\": \"2c20835e4289fe13bc88249efa4d20c2246b29d7\",\n \"channel_name\": \"@channel\",\n \"channel_url\": \"lbry://@channel#2c20835e4289fe13bc88249efa4d20c2246b29d7\",\n \"claim_id\": \"03d4002f8c09c4fac675ff2b3bb41bd6b3136f1b\",\n \"comment\": \"Thank you Based God\",\n \"comment_id\": \"8273c3d6ed1cbed8301a19937c3b2d2c0707ce95deeb17f8727c01cf8b05bb75\",\n \"is_claim_signature_valid\": true,\n \"is_hidden\": false,\n \"is_pinned\": false,\n \"signature\": \"b212c0b9e8f9206748709bae222d1e0225f1fde1b9064d7bf4ba20eb0b99f9d9ead10b7d31dcf13c9ffa133694a89696d6cd3afc16cb96689029a794674d486e\",\n \"signing_ts\": \"1602347141\",\n \"timestamp\": 1602347142\n }\n}"
},
{
"title": "Use the parent_id param to make replies",
"curl": "curl -d'{\"method\": \"comment_create\", \"params\": {\"comment\": \"I have photographic evidence confirming Sasquatch exists\", \"parent_id\": \"8273c3d6ed1cbed8301a19937c3b2d2c0707ce95deeb17f8727c01cf8b05bb75\", \"channel_name\": \"@channel\", \"channel_account_id\": []}}' http://localhost:5279/",
"lbrynet": "lbrynet comment create --comment=\"I have photographic evidence confirming Sasquatch exists\" --channel_name=@channel --parent_id=8273c3d6ed1cbed8301a19937c3b2d2c0707ce95deeb17f8727c01cf8b05bb75",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"comment_create\", \"params\": {\"comment\": \"I have photographic evidence confirming Sasquatch exists\", \"parent_id\": \"8273c3d6ed1cbed8301a19937c3b2d2c0707ce95deeb17f8727c01cf8b05bb75\", \"channel_name\": \"@channel\", \"channel_account_id\": []}}).json()",
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"channel_id\": \"2c20835e4289fe13bc88249efa4d20c2246b29d7\",\n \"channel_name\": \"@channel\",\n \"channel_url\": \"lbry://@channel#2c20835e4289fe13bc88249efa4d20c2246b29d7\",\n \"claim_id\": \"\",\n \"comment\": \"I have photographic evidence confirming Sasquatch exists\",\n \"comment_id\": \"5725edae858dabe4e0bb536e84ed76a8d70c0ddf74032bc0473834c164240efd\",\n \"is_claim_signature_valid\": true,\n \"is_hidden\": false,\n \"is_pinned\": false,\n \"parent_id\": \"8273c3d6ed1cbed8301a19937c3b2d2c0707ce95deeb17f8727c01cf8b05bb75\",\n \"signature\": \"bc2099c617979cb5ef148fe6393bca549d1146c4f6c83f637cd05c670d60295bcd2414897cea3088f774422c73343430219a0be2aca22e5b7e7f949c8007e460\",\n \"signing_ts\": \"1602347141\",\n \"timestamp\": 1602347142\n }\n}"
}
]
},
{
"name": "comment_hide",
"description": "Hide a comment published to a claim you control.",
"arguments": [
{
"name": "comment_ids",
"type": "str, list",
"description": "one or more comment_id to hide.",
"is_required": false
},
{
"name": "wallet_id",
"type": "str",
"description": "restrict operation to specific wallet",
"is_required": false
}
],
"returns": "lists containing the ids comments that are hidden and visible.\n\n {\n \"hidden\": (list) IDs of hidden comments.\n \"visible\": (list) IDs of visible comments.\n }",
"examples": []
},
{
"name": "comment_list",
"description": "List comments associated with a claim.",
"arguments": [
{
"name": "claim_id",
"type": "str",
"description": "The claim on which the comment will be made on",
"is_required": true
},
{
"name": "parent_id",
"type": "str",
"description": "CommentId of a specific thread you'd like to see",
"is_required": false
},
{
"name": "page",
"type": "int",
"description": "The page you'd like to see in the comment list.",
"is_required": false
},
{
"name": "page_size",
"type": "int",
"description": "The amount of comments that you'd like to retrieve",
"is_required": false
},
{
"name": "skip_validation",
"type": "bool",
"description": "Skip resolving comments to validate channel names",
"is_required": false
},
{
"name": "include_replies",
"type": "bool",
"description": "Whether or not you want to include replies in list",
"is_required": false
},
{
"name": "is_channel_signature_valid",
"type": "bool",
"description": "Only include comments with valid signatures. [Warning: Paginated total size will not change, even if list reduces]",
"is_required": false
},
{
"name": "visible",
"type": "bool",
"description": "Select only Visible Comments",
"is_required": false
},
{
"name": "hidden",
"type": "bool",
"description": "Select only Hidden Comments",
"is_required": false
}
],
"returns": "(dict) Containing the list, and information about the paginated content:\n {\n \"page\": \"Page number of the current items.\",\n \"page_size\": \"Number of items to show on a page.\",\n \"total_pages\": \"Total number of pages.\",\n \"total_items\": \"Total number of items.\",\n \"items\": \"A List of dict objects representing comments.\"\n [\n {\n \"comment\": (str) The actual string as inputted by the user,\n \"comment_id\": (str) The Comment's unique identifier,\n \"channel_name\": (str) Name of the channel this was posted under, prepended with a '@',\n \"channel_id\": (str) The Channel Claim ID that this comment was posted under,\n \"signature\": (str) The signature of the comment,\n \"channel_url\": (str) Channel's URI in the ClaimTrie,\n \"parent_id\": (str) Comment this is replying to, (None) if this is the root,\n \"timestamp\": (int) The time at which comment was entered into the server at, in nanoseconds.\n },\n ...\n ]\n }",
"examples": [
{
"title": "List all comments on a claim",
"curl": "curl -d'{\"method\": \"comment_list\", \"params\": {\"claim_id\": \"03d4002f8c09c4fac675ff2b3bb41bd6b3136f1b\", \"include_replies\": true, \"skip_validation\": false, \"is_channel_signature_valid\": false, \"visible\": false, \"hidden\": false}}' http://localhost:5279/",
"lbrynet": "lbrynet comment list 03d4002f8c09c4fac675ff2b3bb41bd6b3136f1b --include_replies",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"comment_list\", \"params\": {\"claim_id\": \"03d4002f8c09c4fac675ff2b3bb41bd6b3136f1b\", \"include_replies\": true, \"skip_validation\": false, \"is_channel_signature_valid\": false, \"visible\": false, \"hidden\": false}}).json()",
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"has_hidden_comments\": false,\n \"items\": [\n {\n \"channel_id\": \"2c20835e4289fe13bc88249efa4d20c2246b29d7\",\n \"channel_name\": \"@channel\",\n \"channel_url\": \"lbry://@channel#2c20835e4289fe13bc88249efa4d20c2246b29d7\",\n \"claim_id\": \"03d4002f8c09c4fac675ff2b3bb41bd6b3136f1b\",\n \"comment\": \"Thank you Based God\",\n \"comment_id\": \"8273c3d6ed1cbed8301a19937c3b2d2c0707ce95deeb17f8727c01cf8b05bb75\",\n \"is_channel_signature_valid\": true,\n \"is_hidden\": false,\n \"is_pinned\": false,\n \"signature\": \"b212c0b9e8f9206748709bae222d1e0225f1fde1b9064d7bf4ba20eb0b99f9d9ead10b7d31dcf13c9ffa133694a89696d6cd3afc16cb96689029a794674d486e\",\n \"signing_ts\": \"1602347141\",\n \"timestamp\": 1602347142\n }\n ],\n \"page\": 1,\n \"page_size\": 50,\n \"total_items\": 1,\n \"total_pages\": 1\n }\n}"
},
{
"title": "List a comment thread replying to a top level comment",
"curl": "curl -d'{\"method\": \"comment_list\", \"params\": {\"claim_id\": \"03d4002f8c09c4fac675ff2b3bb41bd6b3136f1b\", \"parent_id\": \"8273c3d6ed1cbed8301a19937c3b2d2c0707ce95deeb17f8727c01cf8b05bb75\", \"include_replies\": false, \"skip_validation\": false, \"is_channel_signature_valid\": false, \"visible\": false, \"hidden\": false}}' http://localhost:5279/",
"lbrynet": "lbrynet comment list 03d4002f8c09c4fac675ff2b3bb41bd6b3136f1b --parent_id=8273c3d6ed1cbed8301a19937c3b2d2c0707ce95deeb17f8727c01cf8b05bb75",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"comment_list\", \"params\": {\"claim_id\": \"03d4002f8c09c4fac675ff2b3bb41bd6b3136f1b\", \"parent_id\": \"8273c3d6ed1cbed8301a19937c3b2d2c0707ce95deeb17f8727c01cf8b05bb75\", \"include_replies\": false, \"skip_validation\": false, \"is_channel_signature_valid\": false, \"visible\": false, \"hidden\": false}}).json()",
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"has_hidden_comments\": false,\n \"page\": 1,\n \"page_size\": 50,\n \"total_items\": 0,\n \"total_pages\": 0\n }\n}"
}
]
},
{
"name": "comment_pin",
"description": "Pin a comment published to a claim you control.",
"arguments": [
{
"name": "comment_id",
"type": "str",
"description": "Hash identifying the comment to pin",
"is_required": true
},
{
"name": "channel_id",
"type": "str",
"description": "The ID of channel owning the commented claim",
"is_required": false
},
{
"name": "channel_name",
"type": "str",
"description": "The name of channel owning the commented claim",
"is_required": false
},
{
"name": "remove",
"type": "bool",
"description": "remove the pin",
"is_required": false
},
{
"name": "channel_account_id",
"type": "str",
"description": "one or more account ids for accounts to look in",
"is_required": false
},
{
"name": "wallet_id",
"type": "str",
"description": "restrict operation to specific wallet",
"is_required": false
}
],
"returns": "lists containing the ids comments that are hidden and visible.\n\n {\n \"hidden\": (list) IDs of hidden comments.\n \"visible\": (list) IDs of visible comments.\n }",
"examples": []
},
{
"name": "comment_react",
"description": "Create and associate a reaction emoji with a comment using your channel identity.",
"arguments": [
{
"name": "comment_ids",
"type": "str",
"description": "one or more comment id reacted to, comma delimited",
"is_required": false
},
{
"name": "channel_id",
"type": "str",
"description": "The ID of channel reacting",
"is_required": false
},
{
"name": "channel_name",
"type": "str",
"description": "The name of the channel reacting",
"is_required": false
},
{
"name": "wallet_id",
"type": "str",
"description": "restrict operation to specific wallet",
"is_required": false
},
{
"name": "channel_account_id",
"type": "str",
"description": "one or more account ids for accounts to look in",
"is_required": false
},
{
"name": "react_type",
"type": "str",
"description": "name of reaction type",
"is_required": false
},
{
"name": "remove",
"type": "bool",
"description": "remove specified react_type",
"is_required": false
},
{
"name": "clear_types",
"type": "str",
"description": "types to clear when adding another type",
"is_required": false
}
],
"returns": "(dict) Reaction object if successfully made, (None) otherwise\n {\n \"Reactions\": {\n <comment_id>: {\n <reaction_type>: (int) Count for this reaction\n ...\n }\n }",
"examples": []
},
{
"name": "comment_react_list",
"description": "List reactions emoji with a claim using your channel identity.",
"arguments": [
{
"name": "comment_ids",
"type": "str",
"description": "The comment ids reacted to, comma delimited",
"is_required": false
},
{
"name": "channel_id",
"type": "str",
"description": "The ID of channel reacting",
"is_required": false
},
{
"name": "channel_name",
"type": "str",
"description": "The name of the channel reacting",
"is_required": false
},
{
"name": "wallet_id",
"type": "str",
"description": "restrict operation to specific wallet",
"is_required": false
},
{
"name": "react_types",
"type": "str",
"description": "comma delimited reaction types",
"is_required": false
}
],
"returns": "(dict) Comment object if successfully made, (None) otherwise\n {\n \"my_reactions\": {\n <comment_id>: {\n <reaction_type>: (int) Count for this reaction type\n ...\n }\n }\n \"other_reactions\": {\n <comment_id>: {\n <reaction_type>: (int) Count for this reaction type\n ...\n }\n }\n }",
"examples": []
},
{
"name": "comment_update",
"description": "Edit a comment published as one of your channels.",
"arguments": [
{
"name": "comment",
"type": "str",
"description": "New comment replacing the old one",
"is_required": true
},
{
"name": "comment_id",
"type": "str",
"description": "Hash identifying the comment to edit",
"is_required": true
},
{
"name": "wallet_id",
"type": "str",
"description": "restrict operation to specific wallet",
"is_required": false
}
],
"returns": "(dict) Comment object if edit was successful, (None) otherwise\n {\n \"comment\": (str) The actual string as inputted by the user,\n \"comment_id\": (str) The Comment's unique identifier,\n \"claim_id\": (str) The claim commented on,\n \"channel_name\": (str) Name of the channel this was posted under, prepended with a '@',\n \"channel_id\": (str) The Channel Claim ID that this comment was posted under,\n \"signature\": (str) The signature of the comment,\n \"signing_ts\": (str) Timestamp used to sign the most recent signature,\n \"channel_url\": (str) Channel's URI in the ClaimTrie,\n \"is_pinned\": (boolean) Channel owner has pinned this comment,\n \"parent_id\": (str) Comment this is replying to, (None) if this is the root,\n \"timestamp\": (int) The time at which comment was entered into the server at, in nanoseconds.\n }",
"examples": [
{
"title": "Edit the contents of a comment",
"curl": "curl -d'{\"method\": \"comment_update\", \"params\": {\"comment\": \"Where there was once sasquatch, there is not\", \"comment_id\": \"8273c3d6ed1cbed8301a19937c3b2d2c0707ce95deeb17f8727c01cf8b05bb75\"}}' http://localhost:5279/",
"lbrynet": "lbrynet comment update Where there was once sasquatch, there is not --comment_id=8273c3d6ed1cbed8301a19937c3b2d2c0707ce95deeb17f8727c01cf8b05bb75",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"comment_update\", \"params\": {\"comment\": \"Where there was once sasquatch, there is not\", \"comment_id\": \"8273c3d6ed1cbed8301a19937c3b2d2c0707ce95deeb17f8727c01cf8b05bb75\"}}).json()",
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"error\": {\n \"code\": -32000,\n \"data\": null,\n \"message\": \"could not get claim from sdk with claim id 2c20835e4289fe13bc88249efa4d20c2246b29d7\"\n },\n \"id\": 1,\n \"jsonrpc\": \"2.0\"\n }\n}"
}
]
}
]
},
"file": {
"doc": "File management.",
"commands": [
{
"name": "file_delete",
"description": "Delete a LBRY file",
"arguments": [
{
"name": "delete_from_download_dir",
"type": "bool",
"description": "delete file from download directory, instead of just deleting blobs",
"is_required": false
},
{
"name": "delete_all",
"type": "bool",
"description": "if there are multiple matching files, allow the deletion of multiple files. Otherwise do not delete anything.",
"is_required": false
},
{
"name": "sd_hash",
"type": "str",
"description": "delete by file sd hash",
"is_required": false
},
{
"name": "file_name",
"type": "str",
"description": "delete by file name in downloads folder",
"is_required": false
},
{
"name": "stream_hash",
"type": "str",
"description": "delete by file stream hash",
"is_required": false
},
{
"name": "rowid",
"type": "int",
"description": "delete by file row id",
"is_required": false
},
{
"name": "claim_id",
"type": "str",
"description": "delete by file claim id",
"is_required": false
},
{
"name": "txid",
"type": "str",
"description": "delete by file claim txid",
"is_required": false
},
{
"name": "nout",
"type": "int",
"description": "delete by file claim nout",
"is_required": false
},
{
"name": "claim_name",
"type": "str",
"description": "delete by file claim name",
"is_required": false
},
{
"name": "channel_claim_id",
"type": "str",
"description": "delete by file channel claim id",
"is_required": false
},
{
"name": "channel_name",
"type": "str",
"description": "delete by file channel claim name",
"is_required": false
}
],
"returns": "(bool) true if deletion was successful",
"examples": [
{
"title": "Delete a file",
"curl": "curl -d'{\"method\": \"file_delete\", \"params\": {\"delete_from_download_dir\": false, \"delete_all\": false, \"claim_id\": \"03d4002f8c09c4fac675ff2b3bb41bd6b3136f1b\"}}' http://localhost:5279/",
"lbrynet": "lbrynet file delete --claim_id=\"03d4002f8c09c4fac675ff2b3bb41bd6b3136f1b\"",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"file_delete\", \"params\": {\"delete_from_download_dir\": false, \"delete_all\": false, \"claim_id\": \"03d4002f8c09c4fac675ff2b3bb41bd6b3136f1b\"}}).json()",
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": true\n}"
}
]
},
{
"name": "file_list",
"description": "List files limited by optional filters",
"arguments": [
{
"name": "sd_hash",
"type": "str",
"description": "get file with matching sd hash",
"is_required": false
},
{
"name": "file_name",
"type": "str",
"description": "get file with matching file name in the downloads folder",
"is_required": false
},
{
"name": "stream_hash",
"type": "str",
"description": "get file with matching stream hash",
"is_required": false
},
{
"name": "rowid",
"type": "int",
"description": "get file with matching row id",
"is_required": false
},
{
"name": "added_on",
"type": "int",
"description": "get file with matching time of insertion",
"is_required": false
},
{
"name": "claim_id",
"type": "str",
"description": "get file with matching claim id(s)",
"is_required": false
},
{
"name": "outpoint",
"type": "str",
"description": "get file with matching claim outpoint(s)",
"is_required": false
},
{
"name": "txid",
"type": "str",
"description": "get file with matching claim txid",
"is_required": false
},
{
"name": "nout",
"type": "int",
"description": "get file with matching claim nout",
"is_required": false
},
{
"name": "channel_claim_id",
"type": "str",
"description": "get file with matching channel claim id(s)",
"is_required": false
},
{
"name": "channel_name",
"type": "str",
"description": "get file with matching channel name",
"is_required": false
},
{
"name": "claim_name",
"type": "str",
"description": "get file with matching claim name",
"is_required": false
},
{
"name": "blobs_in_stream<blobs_in_stream>",
"type": "int",
"description": "get file with matching blobs in stream",
"is_required": false
},
{
"name": "download_path",
"type": "str",
"description": "get file with matching download path",
"is_required": false
},
{
"name": "uploading_to_reflector",
"type": "bool",
"description": "get files currently uploading to reflector",
"is_required": false
},
{
"name": "is_fully_reflected",
"type": "bool",
"description": "get files that have been uploaded to reflector",
"is_required": false
},
{
"name": "status",
"type": "str",
"description": "match by status, ( running | finished | stopped )",
"is_required": false
},
{
"name": "completed",
"type": "bool",
"description": "match only completed",
"is_required": false
},
{
"name": "blobs_remaining",
"type": "int",
"description": "amount of remaining blobs to download",
"is_required": false
},
{
"name": "sort",
"type": "str",
"description": "field to sort by (one of the above filter fields)",
"is_required": false
},
{
"name": "comparison",
"type": "str",
"description": "logical comparison, (eq | ne | g | ge | l | le | in)",
"is_required": false
},
{
"name": "page",
"type": "int",
"description": "page to return during paginating",
"is_required": false
},
{
"name": "page_size",
"type": "int",
"description": "number of items on page during pagination",
"is_required": false
},
{
"name": "wallet_id",
"type": "str",
"description": "add purchase receipts from this wallet",
"is_required": false
}
],
"returns": " {\n \"page\": \"Page number of the current items.\",\n \"page_size\": \"Number of items to show on a page.\",\n \"total_pages\": \"Total number of pages.\",\n \"total_items\": \"Total number of items.\",\n \"items\": [\n {\n \"streaming_url\": \"(str) url to stream the file using range requests\",\n \"completed\": \"(bool) true if download is completed\",\n \"file_name\": \"(str) name of file\",\n \"download_directory\": \"(str) download directory\",\n \"points_paid\": \"(float) credit paid to download file\",\n \"stopped\": \"(bool) true if download is stopped\",\n \"stream_hash\": \"(str) stream hash of file\",\n \"stream_name\": \"(str) stream name\",\n \"suggested_file_name\": \"(str) suggested file name\",\n \"sd_hash\": \"(str) sd hash of file\",\n \"download_path\": \"(str) download path of file\",\n \"mime_type\": \"(str) mime type of file\",\n \"key\": \"(str) key attached to file\",\n \"total_bytes_lower_bound\": \"(int) lower bound file size in bytes\",\n \"total_bytes\": \"(int) file upper bound size in bytes\",\n \"written_bytes\": \"(int) written size in bytes\",\n \"blobs_completed\": \"(int) number of fully downloaded blobs\",\n \"blobs_in_stream\": \"(int) total blobs on stream\",\n \"blobs_remaining\": \"(int) total blobs remaining to download\",\n \"status\": \"(str) downloader status\",\n \"claim_id\": \"(str) None if claim is not found else the claim id\",\n \"txid\": \"(str) None if claim is not found else the transaction id\",\n \"nout\": \"(int) None if claim is not found else the transaction output index\",\n \"outpoint\": \"(str) None if claim is not found else the tx and output\",\n \"metadata\": \"(dict) None if claim is not found else the claim metadata\",\n \"channel_claim_id\": \"(str) None if claim is not found or not signed\",\n \"channel_name\": \"(str) None if claim is not found or not signed\",\n \"claim_name\": \"(str) None if claim is not found else the claim name\",\n \"reflector_progress\": \"(int) reflector upload progress, 0 to 100\",\n \"uploading_to_reflector\": \"(bool) set to True when currently uploading to reflector\"\n }\n ]\n }",
"examples": [
{
"title": "List local files",
"curl": "curl -d'{\"method\": \"file_list\", \"params\": {\"reverse\": false}}' http://localhost:5279/",
"lbrynet": "lbrynet file list",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"file_list\", \"params\": {\"reverse\": false}}).json()",
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"items\": [\n {\n \"added_on\": null,\n \"blobs_completed\": 1,\n \"blobs_in_stream\": 1,\n \"blobs_remaining\": 0,\n \"channel_claim_id\": \"2c20835e4289fe13bc88249efa4d20c2246b29d7\",\n \"channel_name\": \"@channel\",\n \"claim_id\": \"03d4002f8c09c4fac675ff2b3bb41bd6b3136f1b\",\n \"claim_name\": \"astream\",\n \"completed\": true,\n \"confirmations\": -1,\n \"content_fee\": null,\n \"download_directory\": null,\n \"download_path\": null,\n \"file_name\": null,\n \"height\": -1,\n \"is_fully_reflected\": true,\n \"key\": \"4c7ff8e062dc8e3101d7a3a17806a66b\",\n \"metadata\": {\n \"source\": {\n \"hash\": \"fdbd8e75a67f29f701a4e040385e2e23986303ea10239211af907fcbb83578b3e417cb71ce646efd0819dd8c088de1bd\",\n \"media_type\": \"application/octet-stream\",\n \"name\": \"tmpoqm09_cn\",\n \"sd_hash\": \"f5dd1bd0df88ccbc2f016abaad0b3ffde5e87508dc7af1d964d51736fa260c5f25f2af741573d6bbd59ff458c554972b\",\n \"size\": \"11\"\n },\n \"stream_type\": \"binary\"\n },\n \"mime_type\": \"application/octet-stream\",\n \"nout\": 0,\n \"outpoint\": \"455ab61c9819a88dd7b0e7421251fc7883f0c9bafe790049db6e9716149e8e5e:0\",\n \"points_paid\": 0.0,\n \"protobuf\": \"01d7296b24c2204dfa9e2488bc13fe89425e83202c5adece9151b63be0b469b1230fcb3a108605f48e7b2c1d5b886d7d6737c93580ed7021901fdf627559f3dc724be3f50c66bc375956cccff2e91f74d9e839c0070a90010a8d010a30fdbd8e75a67f29f701a4e040385e2e23986303ea10239211af907fcbb83578b3e417cb71ce646efd0819dd8c088de1bd120b746d706f716d30395f636e180b22186170706c69636174696f6e2f6f637465742d73747265616d3230f5dd1bd0df88ccbc2f016abaad0b3ffde5e87508dc7af1d964d51736fa260c5f25f2af741573d6bbd59ff458c554972b\",\n \"purchase_receipt\": null,\n \"reflector_progress\": 100,\n \"sd_hash\": \"f5dd1bd0df88ccbc2f016abaad0b3ffde5e87508dc7af1d964d51736fa260c5f25f2af741573d6bbd59ff458c554972b\",\n \"status\": \"finished\",\n \"stopped\": true,\n \"stream_hash\": \"6719038b2faab800f1bc7a967ff6e23213db9447bea46effe25bdebf302098d581e4a3fbbe34b75dcd29f3dbe7f5a266\",\n \"stream_name\": \"tmpoqm09_cn\",\n \"streaming_url\": \"http://localhost:5280/stream/f5dd1bd0df88ccbc2f016abaad0b3ffde5e87508dc7af1d964d51736fa260c5f25f2af741573d6bbd59ff458c554972b\",\n \"suggested_file_name\": \"tmpoqm09_cn\",\n \"timestamp\": null,\n \"total_bytes\": 16,\n \"total_bytes_lower_bound\": 0,\n \"txid\": \"455ab61c9819a88dd7b0e7421251fc7883f0c9bafe790049db6e9716149e8e5e\",\n \"uploading_to_reflector\": false,\n \"written_bytes\": 0\n },\n {\n \"added_on\": null,\n \"blobs_completed\": 1,\n \"blobs_in_stream\": 1,\n \"blobs_remaining\": 0,\n \"channel_claim_id\": \"2c20835e4289fe13bc88249efa4d20c2246b29d7\",\n \"channel_name\": \"@channel\",\n \"claim_id\": \"b9baaf557ab346664e6bc3c01a2162c0d18c0d8a\",\n \"claim_name\": \"blank-image\",\n \"completed\": false,\n \"confirmations\": -1,\n \"content_fee\": null,\n \"download_directory\": null,\n \"download_path\": null,\n \"file_name\": null,\n \"height\": -1,\n \"is_fully_reflected\": true,\n \"key\": \"b1f6169d22eb6b4642b38d51c7883e26\",\n \"metadata\": {\n \"author\": \"Picaso\",\n \"description\": \"A blank PNG that is 5x7.\",\n \"fee\": {\n \"address\": \"n1W7YBTYAiwHiUrbirbrqMFM7QSu98mKft\",\n \"amount\": \"0.3\",\n \"currency\": \"LBC\"\n },\n \"image\": {\n \"height\": 7,\n \"width\": 5\n },\n \"languages\": [\n \"en\"\n ],\n \"license\": \"Public Domain\",\n \"license_url\": \"http://public-domain.org\",\n \"locations\": [\n {\n \"city\": \"Manchester\",\n \"country\": \"US\",\n \"state\": \"NH\"\n }\n ],\n \"release_time\": \"1602347139\",\n \"source\": {\n \"hash\": \"6c7df435d412c603390f593ef658c199817c7830ba3f16b7eadd8f99fa50e85dbd0d2b3dc61eadc33fe096e3872d1545\",\n \"media_type\": \"image/png\",\n \"name\": \"tmpsddz9nb5.png\",\n \"sd_hash\": \"70bc4ff167487bf172fbde83889c210f43578eb4b24a93fc708157dbee3e8a4ef8dcc8800d964803d8e21ad03ac32fd7\",\n \"size\": \"99\"\n },\n \"stream_type\": \"image\",\n \"tags\": [\n \"blank\",\n \"art\"\n ],\n \"thumbnail\": {\n \"url\": \"http://smallmedia.com/thumbnail.jpg\"\n },\n \"title\": \"Blank Image\"\n },\n \"mime_type\": \"image/png\",\n \"nout\": 0,\n \"outpoint\": \"0d61ccf645751949196e97f0550a79056b28d4929f673d637b0c0884fbd84eed:0\",\n \"points_paid\": 0.0,\n \"protobuf\": \"01d7296b24c2204dfa9e2488bc13fe89425e83202c459e12774a78db26e30fbd9a152fb094189b65a06364f85a17bf76eff0cb41a6a6900fb2d45a3ddcb34ca9174ee4926624d171b909490c87b28127cb5e5ab4f70ae6010a82010a306c7df435d412c603390f593ef658c199817c7830ba3f16b7eadd8f99fa50e85dbd0d2b3dc61eadc33fe096e3872d1545120f746d707364647a396e62352e706e6718632209696d6167652f706e67323070bc4ff167487bf172fbde83889c210f43578eb4b24a93fc708157dbee3e8a4ef8dcc8800d964803d8e21ad03ac32fd7120650696361736f1a0d5075626c696320446f6d61696e2218687474703a2f2f7075626c69632d646f6d61696e2e6f72672883c187fc053222080112196fdb39d0dc114c42dca3418a636953e50c8cb2cd1ce4209b27188087a70e520408051007420b426c616e6b20496d6167654a184120626c616e6b20504e472074686174206973203578372e52252a23687474703a2f2f736d616c6c6d656469612e636f6d2f7468756d626e61696c2e6a70675a05626c616e6b5a03617274620208016a1308ec0112024e481a0a4d616e63686573746572\",\n \"purchase_receipt\": null,\n \"reflector_progress\": 100,\n \"sd_hash\": \"70bc4ff167487bf172fbde83889c210f43578eb4b24a93fc708157dbee3e8a4ef8dcc8800d964803d8e21ad03ac32fd7\",\n \"status\": \"finished\",\n \"stopped\": true,\n \"stream_hash\": \"72c02c3c917b49cdf501263c9d63873d9e079c70084868ebd74a914f231db4b7b6a2c3f45944d59c04f72fa36505b349\",\n \"stream_name\": \"tmpsddz9nb5.png\",\n \"streaming_url\": \"http://localhost:5280/stream/70bc4ff167487bf172fbde83889c210f43578eb4b24a93fc708157dbee3e8a4ef8dcc8800d964803d8e21ad03ac32fd7\",\n \"suggested_file_name\": \"tmpsddz9nb5.png\",\n \"timestamp\": null,\n \"total_bytes\": 112,\n \"total_bytes_lower_bound\": 96,\n \"txid\": \"0d61ccf645751949196e97f0550a79056b28d4929f673d637b0c0884fbd84eed\",\n \"uploading_to_reflector\": false,\n \"written_bytes\": 0\n }\n ],\n \"page\": 1,\n \"page_size\": 20,\n \"total_items\": 2,\n \"total_pages\": 1\n }\n}"
},
{
"title": "List files matching a parameter",
"curl": "curl -d'{\"method\": \"file_list\", \"params\": {\"claim_id\": \"03d4002f8c09c4fac675ff2b3bb41bd6b3136f1b\", \"reverse\": false}}' http://localhost:5279/",
"lbrynet": "lbrynet file list --claim_id=\"03d4002f8c09c4fac675ff2b3bb41bd6b3136f1b\"",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"file_list\", \"params\": {\"claim_id\": \"03d4002f8c09c4fac675ff2b3bb41bd6b3136f1b\", \"reverse\": false}}).json()",
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"items\": [\n {\n \"added_on\": null,\n \"blobs_completed\": 1,\n \"blobs_in_stream\": 1,\n \"blobs_remaining\": 0,\n \"channel_claim_id\": \"2c20835e4289fe13bc88249efa4d20c2246b29d7\",\n \"channel_name\": \"@channel\",\n \"claim_id\": \"03d4002f8c09c4fac675ff2b3bb41bd6b3136f1b\",\n \"claim_name\": \"astream\",\n \"completed\": true,\n \"confirmations\": 3,\n \"content_fee\": null,\n \"download_directory\": null,\n \"download_path\": null,\n \"file_name\": null,\n \"height\": 214,\n \"is_fully_reflected\": true,\n \"key\": \"4c7ff8e062dc8e3101d7a3a17806a66b\",\n \"metadata\": {\n \"source\": {\n \"hash\": \"fdbd8e75a67f29f701a4e040385e2e23986303ea10239211af907fcbb83578b3e417cb71ce646efd0819dd8c088de1bd\",\n \"media_type\": \"application/octet-stream\",\n \"name\": \"tmpoqm09_cn\",\n \"sd_hash\": \"f5dd1bd0df88ccbc2f016abaad0b3ffde5e87508dc7af1d964d51736fa260c5f25f2af741573d6bbd59ff458c554972b\",\n \"size\": \"11\"\n },\n \"stream_type\": \"binary\"\n },\n \"mime_type\": \"application/octet-stream\",\n \"nout\": 0,\n \"outpoint\": \"455ab61c9819a88dd7b0e7421251fc7883f0c9bafe790049db6e9716149e8e5e:0\",\n \"points_paid\": 0.0,\n \"protobuf\": \"01d7296b24c2204dfa9e2488bc13fe89425e83202c5adece9151b63be0b469b1230fcb3a108605f48e7b2c1d5b886d7d6737c93580ed7021901fdf627559f3dc724be3f50c66bc375956cccff2e91f74d9e839c0070a90010a8d010a30fdbd8e75a67f29f701a4e040385e2e23986303ea10239211af907fcbb83578b3e417cb71ce646efd0819dd8c088de1bd120b746d706f716d30395f636e180b22186170706c69636174696f6e2f6f637465742d73747265616d3230f5dd1bd0df88ccbc2f016abaad0b3ffde5e87508dc7af1d964d51736fa260c5f25f2af741573d6bbd59ff458c554972b\",\n \"purchase_receipt\": null,\n \"reflector_progress\": 100,\n \"sd_hash\": \"f5dd1bd0df88ccbc2f016abaad0b3ffde5e87508dc7af1d964d51736fa260c5f25f2af741573d6bbd59ff458c554972b\",\n \"status\": \"finished\",\n \"stopped\": true,\n \"stream_hash\": \"6719038b2faab800f1bc7a967ff6e23213db9447bea46effe25bdebf302098d581e4a3fbbe34b75dcd29f3dbe7f5a266\",\n \"stream_name\": \"tmpoqm09_cn\",\n \"streaming_url\": \"http://localhost:5280/stream/f5dd1bd0df88ccbc2f016abaad0b3ffde5e87508dc7af1d964d51736fa260c5f25f2af741573d6bbd59ff458c554972b\",\n \"suggested_file_name\": \"tmpoqm09_cn\",\n \"timestamp\": 1602347164,\n \"total_bytes\": 16,\n \"total_bytes_lower_bound\": 0,\n \"txid\": \"455ab61c9819a88dd7b0e7421251fc7883f0c9bafe790049db6e9716149e8e5e\",\n \"uploading_to_reflector\": false,\n \"written_bytes\": 0\n }\n ],\n \"page\": 1,\n \"page_size\": 20,\n \"total_items\": 1,\n \"total_pages\": 1\n }\n}"
}
]
},
{
"name": "file_reflect",
"description": "Reflect all the blobs in a file matching the filter criteria",
"arguments": [
{
"name": "sd_hash",
"type": "str",
"description": "get file with matching sd hash",
"is_required": false
},
{
"name": "file_name",
"type": "str",
"description": "get file with matching file name in the downloads folder",
"is_required": false
},
{
"name": "stream_hash",
"type": "str",
"description": "get file with matching stream hash",
"is_required": false
},
{
"name": "rowid",
"type": "int",
"description": "get file with matching row id",
"is_required": false
},
{
"name": "reflector",
"type": "str",
"description": "reflector server, ip address or url by default choose a server from the config",
"is_required": false
}
],
"returns": "(list) list of blobs reflected",
"examples": []
},
{
"name": "file_save",
"description": "Start saving a file to disk.",
"arguments": [
{
"name": "file_name",
"type": "str",
"description": "file name to save to",
"is_required": false
},
{
"name": "download_directory",
"type": "str",
"description": "directory to save into",
"is_required": false
},
{
"name": "sd_hash",
"type": "str",
"description": "save file with matching sd hash",
"is_required": false
},
{
"name": "stream_hash",
"type": "str",
"description": "save file with matching stream hash",
"is_required": false
},
{
"name": "rowid",
"type": "int",
"description": "save file with matching row id",
"is_required": false
},
{
"name": "claim_id",
"type": "str",
"description": "save file with matching claim id",
"is_required": false
},
{
"name": "txid",
"type": "str",
"description": "save file with matching claim txid",
"is_required": false
},
{
"name": "nout",
"type": "int",
"description": "save file with matching claim nout",
"is_required": false
},
{
"name": "claim_name",
"type": "str",
"description": "save file with matching claim name",
"is_required": false
},
{
"name": "channel_claim_id",
"type": "str",
"description": "save file with matching channel claim id",
"is_required": false
},
{
"name": "channel_name",
"type": "str",
"description": "save file with matching channel claim name",
"is_required": false
}
],
"returns": " {\n \"streaming_url\": \"(str) url to stream the file using range requests\",\n \"completed\": \"(bool) true if download is completed\",\n \"file_name\": \"(str) name of file\",\n \"download_directory\": \"(str) download directory\",\n \"points_paid\": \"(float) credit paid to download file\",\n \"stopped\": \"(bool) true if download is stopped\",\n \"stream_hash\": \"(str) stream hash of file\",\n \"stream_name\": \"(str) stream name\",\n \"suggested_file_name\": \"(str) suggested file name\",\n \"sd_hash\": \"(str) sd hash of file\",\n \"download_path\": \"(str) download path of file\",\n \"mime_type\": \"(str) mime type of file\",\n \"key\": \"(str) key attached to file\",\n \"total_bytes_lower_bound\": \"(int) lower bound file size in bytes\",\n \"total_bytes\": \"(int) file upper bound size in bytes\",\n \"written_bytes\": \"(int) written size in bytes\",\n \"blobs_completed\": \"(int) number of fully downloaded blobs\",\n \"blobs_in_stream\": \"(int) total blobs on stream\",\n \"blobs_remaining\": \"(int) total blobs remaining to download\",\n \"status\": \"(str) downloader status\",\n \"claim_id\": \"(str) None if claim is not found else the claim id\",\n \"txid\": \"(str) None if claim is not found else the transaction id\",\n \"nout\": \"(int) None if claim is not found else the transaction output index\",\n \"outpoint\": \"(str) None if claim is not found else the tx and output\",\n \"metadata\": \"(dict) None if claim is not found else the claim metadata\",\n \"channel_claim_id\": \"(str) None if claim is not found or not signed\",\n \"channel_name\": \"(str) None if claim is not found or not signed\",\n \"claim_name\": \"(str) None if claim is not found else the claim name\",\n \"reflector_progress\": \"(int) reflector upload progress, 0 to 100\",\n \"uploading_to_reflector\": \"(bool) set to True when currently uploading to reflector\"\n }",
"examples": [
{
"title": "Save a file to the downloads directory",
"curl": "curl -d'{\"method\": \"file_save\", \"params\": {\"sd_hash\": \"f5dd1bd0df88ccbc2f016abaad0b3ffde5e87508dc7af1d964d51736fa260c5f25f2af741573d6bbd59ff458c554972b\"}}' http://localhost:5279/",
"lbrynet": "lbrynet file save --sd_hash=\"f5dd1bd0df88ccbc2f016abaad0b3ffde5e87508dc7af1d964d51736fa260c5f25f2af741573d6bbd59ff458c554972b\"",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"file_save\", \"params\": {\"sd_hash\": \"f5dd1bd0df88ccbc2f016abaad0b3ffde5e87508dc7af1d964d51736fa260c5f25f2af741573d6bbd59ff458c554972b\"}}).json()",
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"added_on\": 1602347143,\n \"blobs_completed\": 1,\n \"blobs_in_stream\": 1,\n \"blobs_remaining\": 0,\n \"channel_claim_id\": \"2c20835e4289fe13bc88249efa4d20c2246b29d7\",\n \"channel_name\": \"@channel\",\n \"claim_id\": \"03d4002f8c09c4fac675ff2b3bb41bd6b3136f1b\",\n \"claim_name\": \"astream\",\n \"completed\": true,\n \"confirmations\": 3,\n \"content_fee\": null,\n \"download_directory\": \"/tmp/tmpi0ftuq_m\",\n \"download_path\": \"/tmp/tmpi0ftuq_m/tmpoqm09_cn_1\",\n \"file_name\": \"tmpoqm09_cn_1\",\n \"height\": 214,\n \"is_fully_reflected\": false,\n \"key\": \"4c7ff8e062dc8e3101d7a3a17806a66b\",\n \"metadata\": {\n \"source\": {\n \"hash\": \"fdbd8e75a67f29f701a4e040385e2e23986303ea10239211af907fcbb83578b3e417cb71ce646efd0819dd8c088de1bd\",\n \"media_type\": \"application/octet-stream\",\n \"name\": \"tmpoqm09_cn\",\n \"sd_hash\": \"f5dd1bd0df88ccbc2f016abaad0b3ffde5e87508dc7af1d964d51736fa260c5f25f2af741573d6bbd59ff458c554972b\",\n \"size\": \"11\"\n },\n \"stream_type\": \"binary\"\n },\n \"mime_type\": \"application/octet-stream\",\n \"nout\": 0,\n \"outpoint\": \"455ab61c9819a88dd7b0e7421251fc7883f0c9bafe790049db6e9716149e8e5e:0\",\n \"points_paid\": 0.0,\n \"protobuf\": \"01d7296b24c2204dfa9e2488bc13fe89425e83202c5adece9151b63be0b469b1230fcb3a108605f48e7b2c1d5b886d7d6737c93580ed7021901fdf627559f3dc724be3f50c66bc375956cccff2e91f74d9e839c0070a90010a8d010a30fdbd8e75a67f29f701a4e040385e2e23986303ea10239211af907fcbb83578b3e417cb71ce646efd0819dd8c088de1bd120b746d706f716d30395f636e180b22186170706c69636174696f6e2f6f637465742d73747265616d3230f5dd1bd0df88ccbc2f016abaad0b3ffde5e87508dc7af1d964d51736fa260c5f25f2af741573d6bbd59ff458c554972b\",\n \"purchase_receipt\": null,\n \"reflector_progress\": 0,\n \"sd_hash\": \"f5dd1bd0df88ccbc2f016abaad0b3ffde5e87508dc7af1d964d51736fa260c5f25f2af741573d6bbd59ff458c554972b\",\n \"status\": \"finished\",\n \"stopped\": true,\n \"stream_hash\": \"6719038b2faab800f1bc7a967ff6e23213db9447bea46effe25bdebf302098d581e4a3fbbe34b75dcd29f3dbe7f5a266\",\n \"stream_name\": \"tmpoqm09_cn\",\n \"streaming_url\": \"http://localhost:5280/stream/f5dd1bd0df88ccbc2f016abaad0b3ffde5e87508dc7af1d964d51736fa260c5f25f2af741573d6bbd59ff458c554972b\",\n \"suggested_file_name\": \"tmpoqm09_cn\",\n \"timestamp\": 1602347164,\n \"total_bytes\": 16,\n \"total_bytes_lower_bound\": 0,\n \"txid\": \"455ab61c9819a88dd7b0e7421251fc7883f0c9bafe790049db6e9716149e8e5e\",\n \"uploading_to_reflector\": false,\n \"written_bytes\": 11\n }\n}"
}
]
},
{
"name": "file_set_status",
"description": "Start or stop downloading a file",
"arguments": [
{
"name": "status",
"type": "str",
"description": "one of \"start\" or \"stop\"",
"is_required": true
},
{
"name": "sd_hash",
"type": "str",
"description": "set status of file with matching sd hash",
"is_required": false
},
{
"name": "file_name",
"type": "str",
"description": "set status of file with matching file name in the downloads folder",
"is_required": false
},
{
"name": "stream_hash",
"type": "str",
"description": "set status of file with matching stream hash",
"is_required": false
},
{
"name": "rowid",
"type": "int",
"description": "set status of file with matching row id",
"is_required": false
}
],
"returns": "(str) Confirmation message",
"examples": []
}
]
},
"peer": {
"doc": "DHT / Blob Exchange peer commands.",
"commands": [
{
"name": "peer_list",
"description": "Get peers for blob hash",
"arguments": [
{
"name": "blob_hash",
"type": "str",
"description": "find available peers for this blob hash",
"is_required": true
},
{
"name": "search_bottom_out_limit",
"type": "int",
"description": "the number of search probes in a row that don't find any new peers before giving up and returning",
"is_required": false
},
{
"name": "page",
"type": "int",
"description": "page to return during paginating",
"is_required": false
},
{
"name": "page_size",
"type": "int",
"description": "number of items on page during pagination",
"is_required": false
}
],
"returns": "(list) List of contact dictionaries {'address': <peer ip>, 'udp_port': <dht port>, 'tcp_port': <peer port>,\n 'node_id': <peer node id>}",
"examples": []
},
{
"name": "peer_ping",
"description": "Send a kademlia ping to the specified peer. If address and port are provided the peer is directly pinged,\nif not provided the peer is located first.",
"arguments": [],
"returns": "(str) pong, or {'error': <error message>} if an error is encountered",
"examples": []
}
]
},
"preference": {
"doc": "Preferences management.",
"commands": [
{
"name": "preference_get",
"description": "Get preference value for key or all values if not key is passed in.",
"arguments": [
{
"name": "key",
"type": "str",
"description": "key associated with value",
"is_required": false
},
{
"name": "wallet_id",
"type": "str",
"description": "restrict operation to specific wallet",
"is_required": false
}
],
"returns": "(dict) Dictionary of preference(s)",
"examples": [
{
"title": "Get preferences",
"curl": "curl -d'{\"method\": \"preference_get\", \"params\": {}}' http://localhost:5279/",
"lbrynet": "lbrynet preference get",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"preference_get\", \"params\": {}}).json()",
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"theme\": \"dark\"\n }\n}"
}
]
},
{
"name": "preference_set",
"description": "Set preferences",
"arguments": [
{
"name": "key",
"type": "str",
"description": "key associated with value",
"is_required": true
},
{
"name": "value",
"type": "str",
"description": "key associated with value",
"is_required": true
},
{
"name": "wallet_id",
"type": "str",
"description": "restrict operation to specific wallet",
"is_required": false
}
],
"returns": "(dict) Dictionary with key/value of new preference",
"examples": [
{
"title": "Set preference",
"curl": "curl -d'{\"method\": \"preference_set\", \"params\": {\"key\": \"theme\", \"value\": \"dark\"}}' http://localhost:5279/",
"lbrynet": "lbrynet preference set \"theme\" \"dark\"",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"preference_set\", \"params\": {\"key\": \"theme\", \"value\": \"dark\"}}).json()",
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"theme\": \"dark\"\n }\n}"
}
]
}
]
},
"purchase": {
"doc": "List and make purchases of claims.",
"commands": [
{
"name": "purchase_create",
"description": "Purchase a claim.",
"arguments": [
{
"name": "claim_id",
"type": "str",
"description": "claim id of claim to purchase",
"is_required": false
},
{
"name": "url",
"type": "str",
"description": "lookup claim to purchase by url",
"is_required": false
},
{
"name": "wallet_id",
"type": "str",
"description": "restrict operation to specific wallet",
"is_required": false
},
{
"name": "funding_account_ids",
"type": "list",
"description": "ids of accounts to fund this transaction",
"is_required": false
},
{
"name": "allow_duplicate_purchase",
"type": "bool",
"description": "allow purchasing claim_id you already own",
"is_required": false
},
{
"name": "override_max_key_fee",
"type": "bool",
"description": "ignore max key fee for this purchase",
"is_required": false
},
{
"name": "preview",
"type": "bool",
"description": "do not broadcast the transaction",
"is_required": false
},
{
"name": "blocking",
"type": "bool",
"description": "wait until transaction is in mempool",
"is_required": false
}
],
"returns": " {\n \"txid\": \"hash of transaction in hex\",\n \"height\": \"block where transaction was recorded\",\n \"inputs\": [\n {\n \"txid\": \"hash of transaction in hex\",\n \"nout\": \"position in the transaction\",\n \"height\": \"block where transaction was recorded\",\n \"amount\": \"value of the txo as a decimal\",\n \"address\": \"address of who can spend the txo\",\n \"confirmations\": \"number of confirmed blocks\",\n \"is_change\": \"payment to change address, only available when it can be determined\",\n \"is_received\": \"true if txo was sent from external account to this account\",\n \"is_spent\": \"true if txo is spent\",\n \"is_mine\": \"payment to one of your accounts, only available when it can be determined\",\n \"type\": \"one of 'claim', 'support' or 'purchase'\",\n \"name\": \"when type is 'claim' or 'support', this is the claim name\",\n \"claim_id\": \"when type is 'claim', 'support' or 'purchase', this is the claim id\",\n \"claim_op\": \"when type is 'claim', this determines if it is 'create' or 'update'\",\n \"value\": \"when type is 'claim' or 'support' with payload, this is the decoded protobuf payload\",\n \"value_type\": \"determines the type of the 'value' field: 'channel', 'stream', etc\",\n \"protobuf\": \"hex encoded raw protobuf version of 'value' field\",\n \"permanent_url\": \"when type is 'claim' or 'support', this is the long permanent claim URL\",\n \"claim\": \"for purchase outputs only, metadata of purchased claim\",\n \"reposted_claim\": \"for repost claims only, metadata of claim being reposted\",\n \"signing_channel\": \"for signed claims only, metadata of signing channel\",\n \"is_channel_signature_valid\": \"for signed claims only, whether signature is valid\",\n \"purchase_receipt\": \"metadata for the purchase transaction associated with this claim\"\n }\n ],\n \"outputs\": [\n {\n \"txid\": \"hash of transaction in hex\",\n \"nout\": \"position in the transaction\",\n \"height\": \"block where transaction was recorded\",\n \"amount\": \"value of the txo as a decimal\",\n \"address\": \"address of who can spend the txo\",\n \"confirmations\": \"number of confirmed blocks\",\n \"is_change\": \"payment to change address, only available when it can be determined\",\n \"is_received\": \"true if txo was sent from external account to this account\",\n \"is_spent\": \"true if txo is spent\",\n \"is_mine\": \"payment to one of your accounts, only available when it can be determined\",\n \"type\": \"one of 'claim', 'support' or 'purchase'\",\n \"name\": \"when type is 'claim' or 'support', this is the claim name\",\n \"claim_id\": \"when type is 'claim', 'support' or 'purchase', this is the claim id\",\n \"claim_op\": \"when type is 'claim', this determines if it is 'create' or 'update'\",\n \"value\": \"when type is 'claim' or 'support' with payload, this is the decoded protobuf payload\",\n \"value_type\": \"determines the type of the 'value' field: 'channel', 'stream', etc\",\n \"protobuf\": \"hex encoded raw protobuf version of 'value' field\",\n \"permanent_url\": \"when type is 'claim' or 'support', this is the long permanent claim URL\",\n \"claim\": \"for purchase outputs only, metadata of purchased claim\",\n \"reposted_claim\": \"for repost claims only, metadata of claim being reposted\",\n \"signing_channel\": \"for signed claims only, metadata of signing channel\",\n \"is_channel_signature_valid\": \"for signed claims only, whether signature is valid\",\n \"purchase_receipt\": \"metadata for the purchase transaction associated with this claim\"\n }\n ],\n \"total_input\": \"sum of inputs as a decimal\",\n \"total_output\": \"sum of outputs, sans fee, as a decimal\",\n \"total_fee\": \"fee amount\",\n \"hex\": \"entire transaction encoded in hex\"\n }",
"examples": []
},
{
"name": "purchase_list",
"description": "List my claim purchases.",
"arguments": [
{
"name": "claim_id",
"type": "str",
"description": "purchases for specific claim",
"is_required": false
},
{
"name": "resolve",
"type": "str",
"description": "include resolved claim information",
"is_required": false
},
{
"name": "account_id",
"type": "str",
"description": "id of the account to query",
"is_required": false
},
{
"name": "wallet_id",
"type": "str",
"description": "restrict results to specific wallet",
"is_required": false
},
{
"name": "page",
"type": "int",
"description": "page to return during paginating",
"is_required": false
},
{
"name": "page_size",
"type": "int",
"description": "number of items on page during pagination",
"is_required": false
}
],
"returns": " {\n \"page\": \"Page number of the current items.\",\n \"page_size\": \"Number of items to show on a page.\",\n \"total_pages\": \"Total number of pages.\",\n \"total_items\": \"Total number of items.\",\n \"items\": [\n {\n \"txid\": \"hash of transaction in hex\",\n \"nout\": \"position in the transaction\",\n \"height\": \"block where transaction was recorded\",\n \"amount\": \"value of the txo as a decimal\",\n \"address\": \"address of who can spend the txo\",\n \"confirmations\": \"number of confirmed blocks\",\n \"is_change\": \"payment to change address, only available when it can be determined\",\n \"is_received\": \"true if txo was sent from external account to this account\",\n \"is_spent\": \"true if txo is spent\",\n \"is_mine\": \"payment to one of your accounts, only available when it can be determined\",\n \"type\": \"one of 'claim', 'support' or 'purchase'\",\n \"name\": \"when type is 'claim' or 'support', this is the claim name\",\n \"claim_id\": \"when type is 'claim', 'support' or 'purchase', this is the claim id\",\n \"claim_op\": \"when type is 'claim', this determines if it is 'create' or 'update'\",\n \"value\": \"when type is 'claim' or 'support' with payload, this is the decoded protobuf payload\",\n \"value_type\": \"determines the type of the 'value' field: 'channel', 'stream', etc\",\n \"protobuf\": \"hex encoded raw protobuf version of 'value' field\",\n \"permanent_url\": \"when type is 'claim' or 'support', this is the long permanent claim URL\",\n \"claim\": \"for purchase outputs only, metadata of purchased claim\",\n \"reposted_claim\": \"for repost claims only, metadata of claim being reposted\",\n \"signing_channel\": \"for signed claims only, metadata of signing channel\",\n \"is_channel_signature_valid\": \"for signed claims only, whether signature is valid\",\n \"purchase_receipt\": \"metadata for the purchase transaction associated with this claim\"\n }\n ]\n }",
"examples": []
}
]
},
"settings": {
"doc": "Settings management.",
"commands": [
{
"name": "settings_clear",
"description": "Clear daemon settings",
"arguments": [],
"returns": "(dict) Updated dictionary of daemon settings",
"examples": []
},
{
"name": "settings_get",
"description": "Get daemon settings",
"arguments": [],
"returns": "(dict) Dictionary of daemon settings\n See ADJUSTABLE_SETTINGS in lbry/conf.py for full list of settings",
"examples": [
{
"title": "Get settings",
"curl": "curl -d'{\"method\": \"settings_get\", \"params\": {}}' http://localhost:5279/",
"lbrynet": "lbrynet settings get",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"settings_get\", \"params\": {}}).json()",
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"allowed_origin\": \"\",\n \"announce_head_and_sd_only\": true,\n \"api\": \"localhost:5279\",\n \"audio_encoder\": \"aac -b:a 160k\",\n \"blob_download_timeout\": 30.0,\n \"blob_lru_cache_size\": 0,\n \"blockchain_name\": \"lbrycrd_regtest\",\n \"coin_selection_strategy\": \"standard\",\n \"comment_server\": \"https://comments.lbry.com/api/v2\",\n \"components_to_skip\": [\n \"dht\",\n \"upnp\",\n \"hash_announcer\",\n \"peer_protocol_server\"\n ],\n \"concurrent_blob_announcers\": 10,\n \"concurrent_reflector_uploads\": 10,\n \"config\": \"/home/lex/.local/share/lbry/lbrynet/daemon_settings.yml\",\n \"data_dir\": \"/tmp/tmpi0ftuq_m\",\n \"download_dir\": \"/tmp/tmpi0ftuq_m\",\n \"download_timeout\": 30.0,\n \"ffmpeg_path\": \"\",\n \"fixed_peer_delay\": 2.0,\n \"fixed_peers\": [\n [\n \"127.0.0.1\",\n 5567\n ]\n ],\n \"known_dht_nodes\": [],\n \"lbryum_servers\": [\n [\n \"127.0.0.1\",\n 50001\n ]\n ],\n \"max_connections_per_download\": 4,\n \"max_key_fee\": {\n \"amount\": 50.0,\n \"currency\": \"USD\"\n },\n \"max_wallet_server_fee\": \"0.0\",\n \"network_interface\": \"0.0.0.0\",\n \"node_rpc_timeout\": 5.0,\n \"peer_connect_timeout\": 3.0,\n \"prometheus_port\": 0,\n \"reflect_streams\": true,\n \"reflector_servers\": [\n [\n \"127.0.0.1\",\n 5566\n ]\n ],\n \"save_blobs\": true,\n \"save_files\": true,\n \"save_resolved_claims\": true,\n \"share_usage_data\": false,\n \"split_buckets_under_index\": 1,\n \"streaming_get\": true,\n \"streaming_server\": \"localhost:5280\",\n \"tcp_port\": 3333,\n \"track_bandwidth\": true,\n \"transaction_cache_size\": 100000,\n \"udp_port\": 4444,\n \"use_upnp\": false,\n \"video_bitrate_maximum\": 5000000,\n \"video_encoder\": \"libx264 -crf 24 -preset faster -pix_fmt yuv420p\",\n \"video_scaler\": \"-vf \\\"scale=if(gte(iw\\\\,ih)\\\\,min(1920\\\\,iw)\\\\,-2):if(lt(iw\\\\,ih)\\\\,min(1920\\\\,ih)\\\\,-2)\\\" -maxrate 5500K -bufsize 5000K\",\n \"volume_analysis_time\": 240,\n \"volume_filter\": \"\",\n \"wallet_dir\": \"/tmp/tmpi0ftuq_m\",\n \"wallets\": [\n \"default_wallet\"\n ]\n }\n}"
}
]
},
{
"name": "settings_set",
"description": "Set daemon settings",
"arguments": [],
"returns": "(dict) Updated dictionary of daemon settings",
"examples": [
{
"title": "Set settings",
"curl": "curl -d'{\"method\": \"settings_set\", \"params\": {\"key\": \"tcp_port\", \"value\": 99}}' http://localhost:5279/",
"lbrynet": "lbrynet settings set \"tcp_port\" 99",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"settings_set\", \"params\": {\"key\": \"tcp_port\", \"value\": 99}}).json()",
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"tcp_port\": 99\n }\n}"
}
]
}
]
},
"stream": {
"doc": "Create, update, abandon, list and inspect your stream claims.",
"commands": [
{
"name": "stream_abandon",
"description": "Abandon one of my stream claims.",
"arguments": [
{
"name": "claim_id",
"type": "str",
"description": "claim_id of the claim to abandon",
"is_required": false
},
{
"name": "txid",
"type": "str",
"description": "txid of the claim to abandon",
"is_required": false
},
{
"name": "nout",
"type": "int",
"description": "nout of the claim to abandon",
"is_required": false
},
{
"name": "account_id",
"type": "str",
"description": "id of the account to use",
"is_required": false
},
{
"name": "wallet_id",
"type": "str",
"description": "restrict operation to specific wallet",
"is_required": false
},
{
"name": "preview",
"type": "bool",
"description": "do not broadcast the transaction",
"is_required": false
},
{
"name": "blocking",
"type": "bool",
"description": "wait until abandon is in mempool",
"is_required": false
}
],
"returns": " {\n \"txid\": \"hash of transaction in hex\",\n \"height\": \"block where transaction was recorded\",\n \"inputs\": [\n {\n \"txid\": \"hash of transaction in hex\",\n \"nout\": \"position in the transaction\",\n \"height\": \"block where transaction was recorded\",\n \"amount\": \"value of the txo as a decimal\",\n \"address\": \"address of who can spend the txo\",\n \"confirmations\": \"number of confirmed blocks\",\n \"is_change\": \"payment to change address, only available when it can be determined\",\n \"is_received\": \"true if txo was sent from external account to this account\",\n \"is_spent\": \"true if txo is spent\",\n \"is_mine\": \"payment to one of your accounts, only available when it can be determined\",\n \"type\": \"one of 'claim', 'support' or 'purchase'\",\n \"name\": \"when type is 'claim' or 'support', this is the claim name\",\n \"claim_id\": \"when type is 'claim', 'support' or 'purchase', this is the claim id\",\n \"claim_op\": \"when type is 'claim', this determines if it is 'create' or 'update'\",\n \"value\": \"when type is 'claim' or 'support' with payload, this is the decoded protobuf payload\",\n \"value_type\": \"determines the type of the 'value' field: 'channel', 'stream', etc\",\n \"protobuf\": \"hex encoded raw protobuf version of 'value' field\",\n \"permanent_url\": \"when type is 'claim' or 'support', this is the long permanent claim URL\",\n \"claim\": \"for purchase outputs only, metadata of purchased claim\",\n \"reposted_claim\": \"for repost claims only, metadata of claim being reposted\",\n \"signing_channel\": \"for signed claims only, metadata of signing channel\",\n \"is_channel_signature_valid\": \"for signed claims only, whether signature is valid\",\n \"purchase_receipt\": \"metadata for the purchase transaction associated with this claim\"\n }\n ],\n \"outputs\": [\n {\n \"txid\": \"hash of transaction in hex\",\n \"nout\": \"position in the transaction\",\n \"height\": \"block where transaction was recorded\",\n \"amount\": \"value of the txo as a decimal\",\n \"address\": \"address of who can spend the txo\",\n \"confirmations\": \"number of confirmed blocks\",\n \"is_change\": \"payment to change address, only available when it can be determined\",\n \"is_received\": \"true if txo was sent from external account to this account\",\n \"is_spent\": \"true if txo is spent\",\n \"is_mine\": \"payment to one of your accounts, only available when it can be determined\",\n \"type\": \"one of 'claim', 'support' or 'purchase'\",\n \"name\": \"when type is 'claim' or 'support', this is the claim name\",\n \"claim_id\": \"when type is 'claim', 'support' or 'purchase', this is the claim id\",\n \"claim_op\": \"when type is 'claim', this determines if it is 'create' or 'update'\",\n \"value\": \"when type is 'claim' or 'support' with payload, this is the decoded protobuf payload\",\n \"value_type\": \"determines the type of the 'value' field: 'channel', 'stream', etc\",\n \"protobuf\": \"hex encoded raw protobuf version of 'value' field\",\n \"permanent_url\": \"when type is 'claim' or 'support', this is the long permanent claim URL\",\n \"claim\": \"for purchase outputs only, metadata of purchased claim\",\n \"reposted_claim\": \"for repost claims only, metadata of claim being reposted\",\n \"signing_channel\": \"for signed claims only, metadata of signing channel\",\n \"is_channel_signature_valid\": \"for signed claims only, whether signature is valid\",\n \"purchase_receipt\": \"metadata for the purchase transaction associated with this claim\"\n }\n ],\n \"total_input\": \"sum of inputs as a decimal\",\n \"total_output\": \"sum of outputs, sans fee, as a decimal\",\n \"total_fee\": \"fee amount\",\n \"hex\": \"entire transaction encoded in hex\"\n }",
"examples": [
{
"title": "Abandon a stream claim",
"curl": "curl -d'{\"method\": \"stream_abandon\", \"params\": {\"claim_id\": \"03d4002f8c09c4fac675ff2b3bb41bd6b3136f1b\", \"preview\": false, \"blocking\": false}}' http://localhost:5279/",
"lbrynet": "lbrynet stream abandon 03d4002f8c09c4fac675ff2b3bb41bd6b3136f1b",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"stream_abandon\", \"params\": {\"claim_id\": \"03d4002f8c09c4fac675ff2b3bb41bd6b3136f1b\", \"preview\": false, \"blocking\": false}}).json()",
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"height\": -2,\n \"hex\": \"01000000015e8e9e1416976edb490079febac9f08378fc511242e7b0d78da819981cb65a45000000006a473044022053838c1a9edce2acb9fe68ab4b8a6ab1643117b4e07f94c7395335a36061bcf20220391adbe7a4ae0964292939d065ab486d7625091e7a894f7a47ba806804f304650121020c1c56c75a2dbc80abf41c4eba747255560e9171b6a26a4d5e448e5112710a59ffffffff0134b7f505000000001976a91404425e71483eb9da4ee71bd4bbe79204334a81aa88ac00000000\",\n \"inputs\": [\n {\n \"address\": \"muo3EZhx8VQtZsscvKLVCS2nk8tPeGSUKC\",\n \"amount\": \"1.0\",\n \"claim_id\": \"03d4002f8c09c4fac675ff2b3bb41bd6b3136f1b\",\n \"claim_op\": \"update\",\n \"confirmations\": 3,\n \"height\": 214,\n \"meta\": {},\n \"name\": \"astream\",\n \"normalized_name\": \"astream\",\n \"nout\": 0,\n \"permanent_url\": \"lbry://astream#03d4002f8c09c4fac675ff2b3bb41bd6b3136f1b\",\n \"timestamp\": 1602347164,\n \"txid\": \"455ab61c9819a88dd7b0e7421251fc7883f0c9bafe790049db6e9716149e8e5e\",\n \"type\": \"claim\",\n \"value\": {\n \"source\": {\n \"hash\": \"fdbd8e75a67f29f701a4e040385e2e23986303ea10239211af907fcbb83578b3e417cb71ce646efd0819dd8c088de1bd\",\n \"media_type\": \"application/octet-stream\",\n \"name\": \"tmpoqm09_cn\",\n \"sd_hash\": \"f5dd1bd0df88ccbc2f016abaad0b3ffde5e87508dc7af1d964d51736fa260c5f25f2af741573d6bbd59ff458c554972b\",\n \"size\": \"11\"\n },\n \"stream_type\": \"binary\"\n },\n \"value_type\": \"stream\"\n }\n ],\n \"outputs\": [\n {\n \"address\": \"mfuUWDPjuiitg51T2RW9Gv8BwLnRTQ31KA\",\n \"amount\": \"0.999893\",\n \"confirmations\": -2,\n \"height\": -2,\n \"nout\": 0,\n \"timestamp\": null,\n \"txid\": \"063a5ca0d6642fa037d2afbd8594504f554db6cee6446bec200d5edce3caf39a\",\n \"type\": \"payment\"\n }\n ],\n \"total_fee\": \"0.000107\",\n \"total_input\": \"1.0\",\n \"total_output\": \"0.999893\",\n \"txid\": \"063a5ca0d6642fa037d2afbd8594504f554db6cee6446bec200d5edce3caf39a\"\n }\n}"
}
]
},
{
"name": "stream_cost_estimate",
"description": "Get estimated cost for a lbry stream",
"arguments": [
{
"name": "uri",
"type": "str",
"description": "uri to use",
"is_required": true
}
],
"returns": "(float) Estimated cost in lbry credits, returns None if uri is not\n resolvable",
"examples": []
},
{
"name": "stream_create",
"description": "Make a new stream claim and announce the associated file to lbrynet.",
"arguments": [
{
"name": "name",
"type": "str",
"description": "name of the content (can only consist of a-z A-Z 0-9 and -(dash))",
"is_required": true
},
{
"name": "bid",
"type": "decimal",
"description": "amount to back the claim",
"is_required": true
},
{
"name": "file_path",
"type": "str",
"description": "path to file to be associated with name.",
"is_required": true
},
{
"name": "validate_file",
"type": "bool",
"description": "validate that the video container and encodings match common web browser support or that optimization succeeds if specified. FFmpeg is required",
"is_required": false
},
{
"name": "optimize_file",
"type": "bool",
"description": "transcode the video & audio if necessary to ensure common web browser support. FFmpeg is required",
"is_required": false
},
{
"name": "allow_duplicate_name",
"type": "bool",
"description": "create new claim even if one already exists with given name. default: false.",
"is_required": false
},
{
"name": "fee_currency",
"type": "string",
"description": "specify fee currency",
"is_required": false
},
{
"name": "fee_amount",
"type": "decimal",
"description": "content download fee",
"is_required": false
},
{
"name": "fee_address",
"type": "str",
"description": "address where to send fee payments, will use value from --claim_address if not provided",
"is_required": false
},
{
"name": "title",
"type": "str",
"description": "title of the publication",
"is_required": false
},
{
"name": "description",
"type": "str",
"description": "description of the publication",
"is_required": false
},
{
"name": "author",
"type": "str",
"description": "author of the publication. The usage for this field is not the same as for channels. The author field is used to credit an author who is not the publisher and is not represented by the channel. For example, a pdf file of 'The Odyssey' has an author of 'Homer' but may by published to a channel such as '@classics', or to no channel at all",
"is_required": false
},
{
"name": "tags",
"type": "list",
"description": "add content tags",
"is_required": false
},
{
"name": "languages",
"type": "list",
"description": "languages used by the channel, using RFC 5646 format, eg: for English `--languages=en` for Spanish (Spain) `--languages=es-ES` for Spanish (Mexican) `--languages=es-MX` for Chinese (Simplified) `--languages=zh-Hans` for Chinese (Traditional) `--languages=zh-Hant`",
"is_required": false
},
{
"name": "locations",
"type": "list",
"description": "locations relevant to the stream, consisting of 2 letter `country` code and a `state`, `city` and a postal `code` along with a `latitude` and `longitude`. for JSON RPC: pass a dictionary with aforementioned attributes as keys, eg: ... \"locations\": [{'country': 'US', 'state': 'NH'}] ... for command line: pass a colon delimited list with values in the following order: \"COUNTRY:STATE:CITY:CODE:LATITUDE:LONGITUDE\" making sure to include colon for blank values, for example to provide only the city: ... --locations=\"::Manchester\" with all values set: ... --locations=\"US:NH:Manchester:03101:42.990605:-71.460989\" optionally, you can just pass the \"LATITUDE:LONGITUDE\": ... --locations=\"42.990605:-71.460989\" finally, you can also pass JSON string of dictionary on the command line as you would via JSON RPC ... --locations=\"{'country': 'US', 'state': 'NH'}\"",
"is_required": false
},
{
"name": "license",
"type": "str",
"description": "publication license",
"is_required": false
},
{
"name": "license_url",
"type": "str",
"description": "publication license url",
"is_required": false
},
{
"name": "thumbnail_url",
"type": "str",
"description": "thumbnail url",
"is_required": false
},
{
"name": "release_time",
"type": "int",
"description": "original public release of content, seconds since UNIX epoch",
"is_required": false
},
{
"name": "width",
"type": "int",
"description": "image/video width, automatically calculated from media file",
"is_required": false
},
{
"name": "height",
"type": "int",
"description": "image/video height, automatically calculated from media file",
"is_required": false
},
{
"name": "duration",
"type": "int",
"description": "audio/video duration in seconds, automatically calculated",
"is_required": false
},
{
"name": "channel_id",
"type": "str",
"description": "claim id of the publisher channel",
"is_required": false
},
{
"name": "channel_name",
"type": "str",
"description": "name of the publisher channel",
"is_required": false
},
{
"name": "channel_account_id",
"type": "str",
"description": "one or more account ids for accounts to look in for channel certificates, defaults to all accounts.",
"is_required": false
},
{
"name": "account_id",
"type": "str",
"description": "account to use for holding the transaction",
"is_required": false
},
{
"name": "wallet_id",
"type": "str",
"description": "restrict operation to specific wallet",
"is_required": false
},
{
"name": "funding_account_ids",
"type": "list",
"description": "ids of accounts to fund this transaction",
"is_required": false
},
{
"name": "claim_address",
"type": "str",
"description": "address where the claim is sent to, if not specified it will be determined automatically from the account",
"is_required": false
},
{
"name": "preview",
"type": "bool",
"description": "do not broadcast the transaction",
"is_required": false
},
{
"name": "blocking",
"type": "bool",
"description": "wait until transaction is in mempool",
"is_required": false
}
],
"returns": " {\n \"txid\": \"hash of transaction in hex\",\n \"height\": \"block where transaction was recorded\",\n \"inputs\": [\n {\n \"txid\": \"hash of transaction in hex\",\n \"nout\": \"position in the transaction\",\n \"height\": \"block where transaction was recorded\",\n \"amount\": \"value of the txo as a decimal\",\n \"address\": \"address of who can spend the txo\",\n \"confirmations\": \"number of confirmed blocks\",\n \"is_change\": \"payment to change address, only available when it can be determined\",\n \"is_received\": \"true if txo was sent from external account to this account\",\n \"is_spent\": \"true if txo is spent\",\n \"is_mine\": \"payment to one of your accounts, only available when it can be determined\",\n \"type\": \"one of 'claim', 'support' or 'purchase'\",\n \"name\": \"when type is 'claim' or 'support', this is the claim name\",\n \"claim_id\": \"when type is 'claim', 'support' or 'purchase', this is the claim id\",\n \"claim_op\": \"when type is 'claim', this determines if it is 'create' or 'update'\",\n \"value\": \"when type is 'claim' or 'support' with payload, this is the decoded protobuf payload\",\n \"value_type\": \"determines the type of the 'value' field: 'channel', 'stream', etc\",\n \"protobuf\": \"hex encoded raw protobuf version of 'value' field\",\n \"permanent_url\": \"when type is 'claim' or 'support', this is the long permanent claim URL\",\n \"claim\": \"for purchase outputs only, metadata of purchased claim\",\n \"reposted_claim\": \"for repost claims only, metadata of claim being reposted\",\n \"signing_channel\": \"for signed claims only, metadata of signing channel\",\n \"is_channel_signature_valid\": \"for signed claims only, whether signature is valid\",\n \"purchase_receipt\": \"metadata for the purchase transaction associated with this claim\"\n }\n ],\n \"outputs\": [\n {\n \"txid\": \"hash of transaction in hex\",\n \"nout\": \"position in the transaction\",\n \"height\": \"block where transaction was recorded\",\n \"amount\": \"value of the txo as a decimal\",\n \"address\": \"address of who can spend the txo\",\n \"confirmations\": \"number of confirmed blocks\",\n \"is_change\": \"payment to change address, only available when it can be determined\",\n \"is_received\": \"true if txo was sent from external account to this account\",\n \"is_spent\": \"true if txo is spent\",\n \"is_mine\": \"payment to one of your accounts, only available when it can be determined\",\n \"type\": \"one of 'claim', 'support' or 'purchase'\",\n \"name\": \"when type is 'claim' or 'support', this is the claim name\",\n \"claim_id\": \"when type is 'claim', 'support' or 'purchase', this is the claim id\",\n \"claim_op\": \"when type is 'claim', this determines if it is 'create' or 'update'\",\n \"value\": \"when type is 'claim' or 'support' with payload, this is the decoded protobuf payload\",\n \"value_type\": \"determines the type of the 'value' field: 'channel', 'stream', etc\",\n \"protobuf\": \"hex encoded raw protobuf version of 'value' field\",\n \"permanent_url\": \"when type is 'claim' or 'support', this is the long permanent claim URL\",\n \"claim\": \"for purchase outputs only, metadata of purchased claim\",\n \"reposted_claim\": \"for repost claims only, metadata of claim being reposted\",\n \"signing_channel\": \"for signed claims only, metadata of signing channel\",\n \"is_channel_signature_valid\": \"for signed claims only, whether signature is valid\",\n \"purchase_receipt\": \"metadata for the purchase transaction associated with this claim\"\n }\n ],\n \"total_input\": \"sum of inputs as a decimal\",\n \"total_output\": \"sum of outputs, sans fee, as a decimal\",\n \"total_fee\": \"fee amount\",\n \"hex\": \"entire transaction encoded in hex\"\n }",
"examples": [
{
"title": "Create a stream claim without metadata",
"curl": "curl -d'{\"method\": \"stream_create\", \"params\": {\"name\": \"astream\", \"bid\": \"1.0\", \"file_path\": \"/tmp/tmpoqm09_cn\", \"validate_file\": false, \"optimize_file\": false, \"tags\": [], \"languages\": [], \"locations\": [], \"channel_account_id\": [], \"funding_account_ids\": [], \"preview\": false, \"blocking\": false}}' http://localhost:5279/",
"lbrynet": "lbrynet stream create astream 1.0 /tmp/tmpoqm09_cn",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"stream_create\", \"params\": {\"name\": \"astream\", \"bid\": \"1.0\", \"file_path\": \"/tmp/tmpoqm09_cn\", \"validate_file\": false, \"optimize_file\": false, \"tags\": [], \"languages\": [], \"locations\": [], \"channel_account_id\": [], \"funding_account_ids\": [], \"preview\": false, \"blocking\": false}}).json()",
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"height\": -2,\n \"hex\": \"010000000173f93fbc4438325de740281851a00f35d656f7b334fa64b6394b165c65a55718010000006a4730440220610f73970a99c0e060854776dfd490350f65eaab71203769d3a82bb24ebf316002206abe7267a8e4fb6fac656db10f90b1cbb0f770831a2e8a62c6fadf1a83ffacd5012103c1de52bed1341a0dca16dff47a1f1f494852c67ded2f9ef83548f8243b6741e1ffffffff0200e1f50500000000bab5076173747265616d4c94000a90010a8d010a30fdbd8e75a67f29f701a4e040385e2e23986303ea10239211af907fcbb83578b3e417cb71ce646efd0819dd8c088de1bd120b746d706f716d30395f636e180b22186170706c69636174696f6e2f6f637465742d73747265616d3230f5dd1bd0df88ccbc2f016abaad0b3ffde5e87508dc7af1d964d51736fa260c5f25f2af741573d6bbd59ff458c554972b6d7576a9149c9c8a38fa0a5c7c78dca0c7262a9b4cd02e5e2a88ac38fb9423000000001976a9148c98273fcd66dcc29f52e998b63c729839b8d3bb88ac00000000\",\n \"inputs\": [\n {\n \"address\": \"mfbz7HMyrLu4N8Buv2M9Jie2rjRTdYo8mD\",\n \"amount\": \"6.983769\",\n \"confirmations\": 4,\n \"height\": 209,\n \"nout\": 1,\n \"timestamp\": 1602347163,\n \"txid\": \"1857a5655c164b39b664fa34b3f756d6350fa051182840e75d323844bc3ff973\",\n \"type\": \"payment\"\n }\n ],\n \"outputs\": [\n {\n \"address\": \"muo3EZhx8VQtZsscvKLVCS2nk8tPeGSUKC\",\n \"amount\": \"1.0\",\n \"claim_id\": \"03d4002f8c09c4fac675ff2b3bb41bd6b3136f1b\",\n \"claim_op\": \"create\",\n \"confirmations\": -2,\n \"height\": -2,\n \"meta\": {},\n \"name\": \"astream\",\n \"normalized_name\": \"astream\",\n \"nout\": 0,\n \"permanent_url\": \"lbry://astream#03d4002f8c09c4fac675ff2b3bb41bd6b3136f1b\",\n \"timestamp\": null,\n \"txid\": \"b2bc3654e16df9db36642e8bc84c0167fda196e70a452ced58d42a71abcc1244\",\n \"type\": \"claim\",\n \"value\": {\n \"source\": {\n \"hash\": \"fdbd8e75a67f29f701a4e040385e2e23986303ea10239211af907fcbb83578b3e417cb71ce646efd0819dd8c088de1bd\",\n \"media_type\": \"application/octet-stream\",\n \"name\": \"tmpoqm09_cn\",\n \"sd_hash\": \"f5dd1bd0df88ccbc2f016abaad0b3ffde5e87508dc7af1d964d51736fa260c5f25f2af741573d6bbd59ff458c554972b\",\n \"size\": \"11\"\n },\n \"stream_type\": \"binary\"\n },\n \"value_type\": \"stream\"\n },\n {\n \"address\": \"mtLMAi2JnL341S1bK4wskCparLrH5Fu4t8\",\n \"amount\": \"5.969662\",\n \"confirmations\": -2,\n \"height\": -2,\n \"nout\": 1,\n \"timestamp\": null,\n \"txid\": \"b2bc3654e16df9db36642e8bc84c0167fda196e70a452ced58d42a71abcc1244\",\n \"type\": \"payment\"\n }\n ],\n \"total_fee\": \"0.014107\",\n \"total_input\": \"6.983769\",\n \"total_output\": \"6.969662\",\n \"txid\": \"b2bc3654e16df9db36642e8bc84c0167fda196e70a452ced58d42a71abcc1244\"\n }\n}"
},
{
"title": "Create an image stream claim with all metadata and fee",
"curl": "curl -d'{\"method\": \"stream_create\", \"params\": {\"name\": \"blank-image\", \"bid\": \"1.0\", \"file_path\": \"/tmp/tmpsddz9nb5.png\", \"validate_file\": false, \"optimize_file\": false, \"fee_currency\": \"LBC\", \"fee_amount\": \"0.3\", \"title\": \"Blank Image\", \"description\": \"A blank PNG that is 5x7.\", \"author\": \"Picaso\", \"tags\": [\"blank\", \"art\"], \"languages\": [\"en\"], \"locations\": [\"US:NH:Manchester\"], \"license\": \"Public Domain\", \"license_url\": \"http://public-domain.org\", \"thumbnail_url\": \"http://smallmedia.com/thumbnail.jpg\", \"release_time\": 1602347139, \"channel_id\": \"2c20835e4289fe13bc88249efa4d20c2246b29d7\", \"channel_account_id\": [], \"funding_account_ids\": [], \"preview\": false, \"blocking\": false}}' http://localhost:5279/",
"lbrynet": "lbrynet stream create blank-image 1.0 /tmp/tmpsddz9nb5.png --tags=blank --tags=art --languages=en --locations=US:NH:Manchester --fee_currency=LBC --fee_amount=0.3 --title=\"Blank Image\" --description=\"A blank PNG that is 5x7.\" --author=Picaso --license=\"Public Domain\" --license_url=http://public-domain.org --thumbnail_url=\"http://smallmedia.com/thumbnail.jpg\" --release_time=1602347139 --channel_id=\"2c20835e4289fe13bc88249efa4d20c2246b29d7\"",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"stream_create\", \"params\": {\"name\": \"blank-image\", \"bid\": \"1.0\", \"file_path\": \"/tmp/tmpsddz9nb5.png\", \"validate_file\": false, \"optimize_file\": false, \"fee_currency\": \"LBC\", \"fee_amount\": \"0.3\", \"title\": \"Blank Image\", \"description\": \"A blank PNG that is 5x7.\", \"author\": \"Picaso\", \"tags\": [\"blank\", \"art\"], \"languages\": [\"en\"], \"locations\": [\"US:NH:Manchester\"], \"license\": \"Public Domain\", \"license_url\": \"http://public-domain.org\", \"thumbnail_url\": \"http://smallmedia.com/thumbnail.jpg\", \"release_time\": 1602347139, \"channel_id\": \"2c20835e4289fe13bc88249efa4d20c2246b29d7\", \"channel_account_id\": [], \"funding_account_ids\": [], \"preview\": false, \"blocking\": false}}).json()",
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"height\": -2,\n \"hex\": \"01000000014412ccab712ad458ed2c450ae796a1fd67014cc88b2e6436dbf96de15436bcb2010000006a47304402203fe700069ccb5f7621fb2f2f24320c37519883c75458aafe11075d9cbed547be022071b43a6060bf43017c04d589e357f17756936c94fbd9c9035180d484ca2efd30012102227817a8ad7a33c1e24d0ada38ee942e8a38cbea980d02df01d3652b1f28f9afffffffff0200e1f50500000000fddc01b50b626c616e6b2d696d6167654db10101d7296b24c2204dfa9e2488bc13fe89425e83202c459e12774a78db26e30fbd9a152fb094189b65a06364f85a17bf76eff0cb41a6a6900fb2d45a3ddcb34ca9174ee4926624d171b909490c87b28127cb5e5ab4f70ae6010a82010a306c7df435d412c603390f593ef658c199817c7830ba3f16b7eadd8f99fa50e85dbd0d2b3dc61eadc33fe096e3872d1545120f746d707364647a396e62352e706e6718632209696d6167652f706e67323070bc4ff167487bf172fbde83889c210f43578eb4b24a93fc708157dbee3e8a4ef8dcc8800d964803d8e21ad03ac32fd7120650696361736f1a0d5075626c696320446f6d61696e2218687474703a2f2f7075626c69632d646f6d61696e2e6f72672883c187fc053222080112196fdb39d0dc114c42dca3418a636953e50c8cb2cd1ce4209b27188087a70e520408051007420b426c616e6b20496d6167654a184120626c616e6b20504e472074686174206973203578372e52252a23687474703a2f2f736d616c6c6d656469612e636f6d2f7468756d626e61696c2e6a70675a05626c616e6b5a03617274620208016a1308ec0112024e481a0a4d616e636865737465726d7576a914db39d0dc114c42dca3418a636953e50c8cb2cd1c88acac5e7d1d000000001976a914628b92ad36fb3f24af2a062b433e7927b0a9867688ac00000000\",\n \"inputs\": [\n {\n \"address\": \"mtLMAi2JnL341S1bK4wskCparLrH5Fu4t8\",\n \"amount\": \"5.969662\",\n \"confirmations\": 2,\n \"height\": 213,\n \"nout\": 1,\n \"timestamp\": 1602347164,\n \"txid\": \"b2bc3654e16df9db36642e8bc84c0167fda196e70a452ced58d42a71abcc1244\",\n \"type\": \"payment\"\n }\n ],\n \"outputs\": [\n {\n \"address\": \"n1W7YBTYAiwHiUrbirbrqMFM7QSu98mKft\",\n \"amount\": \"1.0\",\n \"claim_id\": \"b9baaf557ab346664e6bc3c01a2162c0d18c0d8a\",\n \"claim_op\": \"create\",\n \"confirmations\": -2,\n \"height\": -2,\n \"is_channel_signature_valid\": true,\n \"meta\": {},\n \"name\": \"blank-image\",\n \"normalized_name\": \"blank-image\",\n \"nout\": 0,\n \"permanent_url\": \"lbry://blank-image#b9baaf557ab346664e6bc3c01a2162c0d18c0d8a\",\n \"signing_channel\": {\n \"address\": \"mth8FNCBtmx5M92AtxUpWigDPaB1g2xNpZ\",\n \"amount\": \"1.0\",\n \"claim_id\": \"2c20835e4289fe13bc88249efa4d20c2246b29d7\",\n \"claim_op\": \"update\",\n \"confirmations\": 5,\n \"has_signing_key\": true,\n \"height\": 210,\n \"meta\": {},\n \"name\": \"@channel\",\n \"normalized_name\": \"@channel\",\n \"nout\": 0,\n \"permanent_url\": \"lbry://@channel#2c20835e4289fe13bc88249efa4d20c2246b29d7\",\n \"timestamp\": 1602347163,\n \"txid\": \"db52235e2719bd2fe4e04d0c2de3c527fc84365f980fd5ce147a8d5725eb427c\",\n \"type\": \"claim\",\n \"value\": {\n \"public_key\": \"3056301006072a8648ce3d020106052b8104000a03420004bb438060971d65dfccc532c2c72357b802057d458a9143c2f863461ba8f5f79a512b770a19b80717467e0d0366e8097d3cf803a91609a2827d0701d6562e5a88\",\n \"public_key_id\": \"msagyzG92X562roXPRfSYQkmoNWzMYtZd8\",\n \"title\": \"New Channel\"\n },\n \"value_type\": \"channel\"\n },\n \"timestamp\": null,\n \"txid\": \"0d61ccf645751949196e97f0550a79056b28d4929f673d637b0c0884fbd84eed\",\n \"type\": \"claim\",\n \"value\": {\n \"author\": \"Picaso\",\n \"description\": \"A blank PNG that is 5x7.\",\n \"fee\": {\n \"address\": \"n1W7YBTYAiwHiUrbirbrqMFM7QSu98mKft\",\n \"amount\": \"0.3\",\n \"currency\": \"LBC\"\n },\n \"image\": {\n \"height\": 7,\n \"width\": 5\n },\n \"languages\": [\n \"en\"\n ],\n \"license\": \"Public Domain\",\n \"license_url\": \"http://public-domain.org\",\n \"locations\": [\n {\n \"city\": \"Manchester\",\n \"country\": \"US\",\n \"state\": \"NH\"\n }\n ],\n \"release_time\": \"1602347139\",\n \"source\": {\n \"hash\": \"6c7df435d412c603390f593ef658c199817c7830ba3f16b7eadd8f99fa50e85dbd0d2b3dc61eadc33fe096e3872d1545\",\n \"media_type\": \"image/png\",\n \"name\": \"tmpsddz9nb5.png\",\n \"sd_hash\": \"70bc4ff167487bf172fbde83889c210f43578eb4b24a93fc708157dbee3e8a4ef8dcc8800d964803d8e21ad03ac32fd7\",\n \"size\": \"99\"\n },\n \"stream_type\": \"image\",\n \"tags\": [\n \"blank\",\n \"art\"\n ],\n \"thumbnail\": {\n \"url\": \"http://smallmedia.com/thumbnail.jpg\"\n },\n \"title\": \"Blank Image\"\n },\n \"value_type\": \"stream\"\n },\n {\n \"address\": \"mpW1iYzQqMxFqphUGRf5WH5qE4TwbEaLYW\",\n \"amount\": \"4.947555\",\n \"confirmations\": -2,\n \"height\": -2,\n \"nout\": 1,\n \"timestamp\": null,\n \"txid\": \"0d61ccf645751949196e97f0550a79056b28d4929f673d637b0c0884fbd84eed\",\n \"type\": \"payment\"\n }\n ],\n \"total_fee\": \"0.022107\",\n \"total_input\": \"5.969662\",\n \"total_output\": \"5.947555\",\n \"txid\": \"0d61ccf645751949196e97f0550a79056b28d4929f673d637b0c0884fbd84eed\"\n }\n}"
}
]
},
{
"name": "stream_list",
"description": "List my stream claims.",
"arguments": [
{
"name": "name",
"type": "str or list",
"description": "stream name",
"is_required": false
},
{
"name": "claim_id",
"type": "str or list",
"description": "stream id",
"is_required": false
},
{
"name": "is_spent",
"type": "bool",
"description": "shows previous stream updates and abandons",
"is_required": false
},
{
"name": "account_id",
"type": "str",
"description": "id of the account to query",
"is_required": false
},
{
"name": "wallet_id",
"type": "str",
"description": "restrict results to specific wallet",
"is_required": false
},
{
"name": "page",
"type": "int",
"description": "page to return during paginating",
"is_required": false
},
{
"name": "page_size",
"type": "int",
"description": "number of items on page during pagination",
"is_required": false
},
{
"name": "resolve",
"type": "bool",
"description": "resolves each stream to provide additional metadata",
"is_required": false
},
{
"name": "no_totals",
"type": "bool",
"description": "do not calculate the total number of pages and items in result set (significant performance boost)",
"is_required": false
}
],
"returns": " {\n \"page\": \"Page number of the current items.\",\n \"page_size\": \"Number of items to show on a page.\",\n \"total_pages\": \"Total number of pages.\",\n \"total_items\": \"Total number of items.\",\n \"items\": [\n {\n \"txid\": \"hash of transaction in hex\",\n \"nout\": \"position in the transaction\",\n \"height\": \"block where transaction was recorded\",\n \"amount\": \"value of the txo as a decimal\",\n \"address\": \"address of who can spend the txo\",\n \"confirmations\": \"number of confirmed blocks\",\n \"is_change\": \"payment to change address, only available when it can be determined\",\n \"is_received\": \"true if txo was sent from external account to this account\",\n \"is_spent\": \"true if txo is spent\",\n \"is_mine\": \"payment to one of your accounts, only available when it can be determined\",\n \"type\": \"one of 'claim', 'support' or 'purchase'\",\n \"name\": \"when type is 'claim' or 'support', this is the claim name\",\n \"claim_id\": \"when type is 'claim', 'support' or 'purchase', this is the claim id\",\n \"claim_op\": \"when type is 'claim', this determines if it is 'create' or 'update'\",\n \"value\": \"when type is 'claim' or 'support' with payload, this is the decoded protobuf payload\",\n \"value_type\": \"determines the type of the 'value' field: 'channel', 'stream', etc\",\n \"protobuf\": \"hex encoded raw protobuf version of 'value' field\",\n \"permanent_url\": \"when type is 'claim' or 'support', this is the long permanent claim URL\",\n \"claim\": \"for purchase outputs only, metadata of purchased claim\",\n \"reposted_claim\": \"for repost claims only, metadata of claim being reposted\",\n \"signing_channel\": \"for signed claims only, metadata of signing channel\",\n \"is_channel_signature_valid\": \"for signed claims only, whether signature is valid\",\n \"purchase_receipt\": \"metadata for the purchase transaction associated with this claim\"\n }\n ]\n }",
"examples": [
{
"title": "List all your stream claims",
"curl": "curl -d'{\"method\": \"stream_list\", \"params\": {\"name\": [], \"claim_id\": [], \"is_spent\": false, \"resolve\": false, \"no_totals\": false}}' http://localhost:5279/",
"lbrynet": "lbrynet stream list",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"stream_list\", \"params\": {\"name\": [], \"claim_id\": [], \"is_spent\": false, \"resolve\": false, \"no_totals\": false}}).json()",
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"items\": [\n {\n \"address\": \"muo3EZhx8VQtZsscvKLVCS2nk8tPeGSUKC\",\n \"amount\": \"1.0\",\n \"claim_id\": \"03d4002f8c09c4fac675ff2b3bb41bd6b3136f1b\",\n \"claim_op\": \"update\",\n \"confirmations\": 1,\n \"height\": 214,\n \"is_channel_signature_valid\": true,\n \"is_internal_transfer\": false,\n \"is_my_input\": true,\n \"is_my_output\": true,\n \"is_spent\": false,\n \"meta\": {},\n \"name\": \"astream\",\n \"normalized_name\": \"astream\",\n \"nout\": 0,\n \"permanent_url\": \"lbry://astream#03d4002f8c09c4fac675ff2b3bb41bd6b3136f1b\",\n \"signing_channel\": {\n \"address\": \"mth8FNCBtmx5M92AtxUpWigDPaB1g2xNpZ\",\n \"amount\": \"1.0\",\n \"claim_id\": \"2c20835e4289fe13bc88249efa4d20c2246b29d7\",\n \"claim_op\": \"update\",\n \"confirmations\": 5,\n \"has_signing_key\": true,\n \"height\": 210,\n \"meta\": {},\n \"name\": \"@channel\",\n \"normalized_name\": \"@channel\",\n \"nout\": 0,\n \"permanent_url\": \"lbry://@channel#2c20835e4289fe13bc88249efa4d20c2246b29d7\",\n \"timestamp\": 1602347163,\n \"txid\": \"db52235e2719bd2fe4e04d0c2de3c527fc84365f980fd5ce147a8d5725eb427c\",\n \"type\": \"claim\",\n \"value\": {\n \"public_key\": \"3056301006072a8648ce3d020106052b8104000a03420004bb438060971d65dfccc532c2c72357b802057d458a9143c2f863461ba8f5f79a512b770a19b80717467e0d0366e8097d3cf803a91609a2827d0701d6562e5a88\",\n \"public_key_id\": \"msagyzG92X562roXPRfSYQkmoNWzMYtZd8\",\n \"title\": \"New Channel\"\n },\n \"value_type\": \"channel\"\n },\n \"timestamp\": 1602347164,\n \"txid\": \"455ab61c9819a88dd7b0e7421251fc7883f0c9bafe790049db6e9716149e8e5e\",\n \"type\": \"claim\",\n \"value\": {\n \"source\": {\n \"hash\": \"fdbd8e75a67f29f701a4e040385e2e23986303ea10239211af907fcbb83578b3e417cb71ce646efd0819dd8c088de1bd\",\n \"media_type\": \"application/octet-stream\",\n \"name\": \"tmpoqm09_cn\",\n \"sd_hash\": \"f5dd1bd0df88ccbc2f016abaad0b3ffde5e87508dc7af1d964d51736fa260c5f25f2af741573d6bbd59ff458c554972b\",\n \"size\": \"11\"\n },\n \"stream_type\": \"binary\"\n },\n \"value_type\": \"stream\"\n },\n {\n \"address\": \"muo3EZhx8VQtZsscvKLVCS2nk8tPeGSUKC\",\n \"amount\": \"1.0\",\n \"claim_id\": \"03d4002f8c09c4fac675ff2b3bb41bd6b3136f1b\",\n \"claim_op\": \"create\",\n \"confirmations\": 2,\n \"height\": 213,\n \"is_internal_transfer\": false,\n \"is_my_input\": true,\n \"is_my_output\": true,\n \"is_spent\": true,\n \"meta\": {},\n \"name\": \"astream\",\n \"normalized_name\": \"astream\",\n \"nout\": 0,\n \"permanent_url\": \"lbry://astream#03d4002f8c09c4fac675ff2b3bb41bd6b3136f1b\",\n \"timestamp\": 1602347164,\n \"txid\": \"b2bc3654e16df9db36642e8bc84c0167fda196e70a452ced58d42a71abcc1244\",\n \"type\": \"claim\",\n \"value\": {\n \"source\": {\n \"hash\": \"fdbd8e75a67f29f701a4e040385e2e23986303ea10239211af907fcbb83578b3e417cb71ce646efd0819dd8c088de1bd\",\n \"media_type\": \"application/octet-stream\",\n \"name\": \"tmpoqm09_cn\",\n \"sd_hash\": \"f5dd1bd0df88ccbc2f016abaad0b3ffde5e87508dc7af1d964d51736fa260c5f25f2af741573d6bbd59ff458c554972b\",\n \"size\": \"11\"\n },\n \"stream_type\": \"binary\"\n },\n \"value_type\": \"stream\"\n }\n ],\n \"page\": 1,\n \"page_size\": 20,\n \"total_items\": 2,\n \"total_pages\": 1\n }\n}"
},
{
"title": "Paginate your stream claims",
"curl": "curl -d'{\"method\": \"stream_list\", \"params\": {\"name\": [], \"claim_id\": [], \"is_spent\": false, \"page\": 1, \"page_size\": 20, \"resolve\": false, \"no_totals\": false}}' http://localhost:5279/",
"lbrynet": "lbrynet stream list --page=1 --page_size=20",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"stream_list\", \"params\": {\"name\": [], \"claim_id\": [], \"is_spent\": false, \"page\": 1, \"page_size\": 20, \"resolve\": false, \"no_totals\": false}}).json()",
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"items\": [\n {\n \"address\": \"muo3EZhx8VQtZsscvKLVCS2nk8tPeGSUKC\",\n \"amount\": \"1.0\",\n \"claim_id\": \"03d4002f8c09c4fac675ff2b3bb41bd6b3136f1b\",\n \"claim_op\": \"update\",\n \"confirmations\": 1,\n \"height\": 214,\n \"is_channel_signature_valid\": true,\n \"is_internal_transfer\": false,\n \"is_my_input\": true,\n \"is_my_output\": true,\n \"is_spent\": false,\n \"meta\": {},\n \"name\": \"astream\",\n \"normalized_name\": \"astream\",\n \"nout\": 0,\n \"permanent_url\": \"lbry://astream#03d4002f8c09c4fac675ff2b3bb41bd6b3136f1b\",\n \"signing_channel\": {\n \"address\": \"mth8FNCBtmx5M92AtxUpWigDPaB1g2xNpZ\",\n \"amount\": \"1.0\",\n \"claim_id\": \"2c20835e4289fe13bc88249efa4d20c2246b29d7\",\n \"claim_op\": \"update\",\n \"confirmations\": 5,\n \"has_signing_key\": true,\n \"height\": 210,\n \"meta\": {},\n \"name\": \"@channel\",\n \"normalized_name\": \"@channel\",\n \"nout\": 0,\n \"permanent_url\": \"lbry://@channel#2c20835e4289fe13bc88249efa4d20c2246b29d7\",\n \"timestamp\": 1602347163,\n \"txid\": \"db52235e2719bd2fe4e04d0c2de3c527fc84365f980fd5ce147a8d5725eb427c\",\n \"type\": \"claim\",\n \"value\": {\n \"public_key\": \"3056301006072a8648ce3d020106052b8104000a03420004bb438060971d65dfccc532c2c72357b802057d458a9143c2f863461ba8f5f79a512b770a19b80717467e0d0366e8097d3cf803a91609a2827d0701d6562e5a88\",\n \"public_key_id\": \"msagyzG92X562roXPRfSYQkmoNWzMYtZd8\",\n \"title\": \"New Channel\"\n },\n \"value_type\": \"channel\"\n },\n \"timestamp\": 1602347164,\n \"txid\": \"455ab61c9819a88dd7b0e7421251fc7883f0c9bafe790049db6e9716149e8e5e\",\n \"type\": \"claim\",\n \"value\": {\n \"source\": {\n \"hash\": \"fdbd8e75a67f29f701a4e040385e2e23986303ea10239211af907fcbb83578b3e417cb71ce646efd0819dd8c088de1bd\",\n \"media_type\": \"application/octet-stream\",\n \"name\": \"tmpoqm09_cn\",\n \"sd_hash\": \"f5dd1bd0df88ccbc2f016abaad0b3ffde5e87508dc7af1d964d51736fa260c5f25f2af741573d6bbd59ff458c554972b\",\n \"size\": \"11\"\n },\n \"stream_type\": \"binary\"\n },\n \"value_type\": \"stream\"\n },\n {\n \"address\": \"muo3EZhx8VQtZsscvKLVCS2nk8tPeGSUKC\",\n \"amount\": \"1.0\",\n \"claim_id\": \"03d4002f8c09c4fac675ff2b3bb41bd6b3136f1b\",\n \"claim_op\": \"create\",\n \"confirmations\": 2,\n \"height\": 213,\n \"is_internal_transfer\": false,\n \"is_my_input\": true,\n \"is_my_output\": true,\n \"is_spent\": true,\n \"meta\": {},\n \"name\": \"astream\",\n \"normalized_name\": \"astream\",\n \"nout\": 0,\n \"permanent_url\": \"lbry://astream#03d4002f8c09c4fac675ff2b3bb41bd6b3136f1b\",\n \"timestamp\": 1602347164,\n \"txid\": \"b2bc3654e16df9db36642e8bc84c0167fda196e70a452ced58d42a71abcc1244\",\n \"type\": \"claim\",\n \"value\": {\n \"source\": {\n \"hash\": \"fdbd8e75a67f29f701a4e040385e2e23986303ea10239211af907fcbb83578b3e417cb71ce646efd0819dd8c088de1bd\",\n \"media_type\": \"application/octet-stream\",\n \"name\": \"tmpoqm09_cn\",\n \"sd_hash\": \"f5dd1bd0df88ccbc2f016abaad0b3ffde5e87508dc7af1d964d51736fa260c5f25f2af741573d6bbd59ff458c554972b\",\n \"size\": \"11\"\n },\n \"stream_type\": \"binary\"\n },\n \"value_type\": \"stream\"\n }\n ],\n \"page\": 1,\n \"page_size\": 20,\n \"total_items\": 2,\n \"total_pages\": 1\n }\n}"
}
]
},
{
"name": "stream_repost",
"description": "Creates a claim that references an existing stream by its claim id.",
"arguments": [
{
"name": "name",
"type": "str",
"description": "name of the content (can only consist of a-z A-Z 0-9 and -(dash))",
"is_required": true
},
{
"name": "bid",
"type": "decimal",
"description": "amount to back the claim",
"is_required": true
},
{
"name": "claim_id",
"type": "str",
"description": "id of the claim being reposted",
"is_required": true
},
{
"name": "allow_duplicate_name",
"type": "bool",
"description": "create new claim even if one already exists with given name. default: false.",
"is_required": false
},
{
"name": "channel_id",
"type": "str",
"description": "claim id of the publisher channel",
"is_required": false
},
{
"name": "channel_name",
"type": "str",
"description": "name of the publisher channel",
"is_required": false
},
{
"name": "channel_account_id",
"type": "str",
"description": "one or more account ids for accounts to look in for channel certificates, defaults to all accounts.",
"is_required": false
},
{
"name": "account_id",
"type": "str",
"description": "account to use for holding the transaction",
"is_required": false
},
{
"name": "wallet_id",
"type": "str",
"description": "restrict operation to specific wallet",
"is_required": false
},
{
"name": "funding_account_ids",
"type": "list",
"description": "ids of accounts to fund this transaction",
"is_required": false
},
{
"name": "claim_address",
"type": "str",
"description": "address where the claim is sent to, if not specified it will be determined automatically from the account",
"is_required": false
},
{
"name": "preview",
"type": "bool",
"description": "do not broadcast the transaction",
"is_required": false
},
{
"name": "blocking",
"type": "bool",
"description": "wait until transaction is in mempool",
"is_required": false
}
],
"returns": " {\n \"txid\": \"hash of transaction in hex\",\n \"height\": \"block where transaction was recorded\",\n \"inputs\": [\n {\n \"txid\": \"hash of transaction in hex\",\n \"nout\": \"position in the transaction\",\n \"height\": \"block where transaction was recorded\",\n \"amount\": \"value of the txo as a decimal\",\n \"address\": \"address of who can spend the txo\",\n \"confirmations\": \"number of confirmed blocks\",\n \"is_change\": \"payment to change address, only available when it can be determined\",\n \"is_received\": \"true if txo was sent from external account to this account\",\n \"is_spent\": \"true if txo is spent\",\n \"is_mine\": \"payment to one of your accounts, only available when it can be determined\",\n \"type\": \"one of 'claim', 'support' or 'purchase'\",\n \"name\": \"when type is 'claim' or 'support', this is the claim name\",\n \"claim_id\": \"when type is 'claim', 'support' or 'purchase', this is the claim id\",\n \"claim_op\": \"when type is 'claim', this determines if it is 'create' or 'update'\",\n \"value\": \"when type is 'claim' or 'support' with payload, this is the decoded protobuf payload\",\n \"value_type\": \"determines the type of the 'value' field: 'channel', 'stream', etc\",\n \"protobuf\": \"hex encoded raw protobuf version of 'value' field\",\n \"permanent_url\": \"when type is 'claim' or 'support', this is the long permanent claim URL\",\n \"claim\": \"for purchase outputs only, metadata of purchased claim\",\n \"reposted_claim\": \"for repost claims only, metadata of claim being reposted\",\n \"signing_channel\": \"for signed claims only, metadata of signing channel\",\n \"is_channel_signature_valid\": \"for signed claims only, whether signature is valid\",\n \"purchase_receipt\": \"metadata for the purchase transaction associated with this claim\"\n }\n ],\n \"outputs\": [\n {\n \"txid\": \"hash of transaction in hex\",\n \"nout\": \"position in the transaction\",\n \"height\": \"block where transaction was recorded\",\n \"amount\": \"value of the txo as a decimal\",\n \"address\": \"address of who can spend the txo\",\n \"confirmations\": \"number of confirmed blocks\",\n \"is_change\": \"payment to change address, only available when it can be determined\",\n \"is_received\": \"true if txo was sent from external account to this account\",\n \"is_spent\": \"true if txo is spent\",\n \"is_mine\": \"payment to one of your accounts, only available when it can be determined\",\n \"type\": \"one of 'claim', 'support' or 'purchase'\",\n \"name\": \"when type is 'claim' or 'support', this is the claim name\",\n \"claim_id\": \"when type is 'claim', 'support' or 'purchase', this is the claim id\",\n \"claim_op\": \"when type is 'claim', this determines if it is 'create' or 'update'\",\n \"value\": \"when type is 'claim' or 'support' with payload, this is the decoded protobuf payload\",\n \"value_type\": \"determines the type of the 'value' field: 'channel', 'stream', etc\",\n \"protobuf\": \"hex encoded raw protobuf version of 'value' field\",\n \"permanent_url\": \"when type is 'claim' or 'support', this is the long permanent claim URL\",\n \"claim\": \"for purchase outputs only, metadata of purchased claim\",\n \"reposted_claim\": \"for repost claims only, metadata of claim being reposted\",\n \"signing_channel\": \"for signed claims only, metadata of signing channel\",\n \"is_channel_signature_valid\": \"for signed claims only, whether signature is valid\",\n \"purchase_receipt\": \"metadata for the purchase transaction associated with this claim\"\n }\n ],\n \"total_input\": \"sum of inputs as a decimal\",\n \"total_output\": \"sum of outputs, sans fee, as a decimal\",\n \"total_fee\": \"fee amount\",\n \"hex\": \"entire transaction encoded in hex\"\n }",
"examples": []
},
{
"name": "stream_update",
"description": "Update an existing stream claim and if a new file is provided announce it to lbrynet.",
"arguments": [
{
"name": "claim_id",
"type": "str",
"description": "id of the stream claim to update",
"is_required": true
},
{
"name": "bid",
"type": "decimal",
"description": "amount to back the claim",
"is_required": false
},
{
"name": "file_path",
"type": "str",
"description": "path to file to be associated with name.",
"is_required": false
},
{
"name": "validate_file",
"type": "bool",
"description": "validate that the video container and encodings match common web browser support or that optimization succeeds if specified. FFmpeg is required and file_path must be specified.",
"is_required": false
},
{
"name": "optimize_file",
"type": "bool",
"description": "transcode the video & audio if necessary to ensure common web browser support. FFmpeg is required and file_path must be specified.",
"is_required": false
},
{
"name": "file_name",
"type": "str",
"description": "override file name, defaults to name from file_path.",
"is_required": false
},
{
"name": "file_size",
"type": "str",
"description": "override file size, otherwise automatically computed.",
"is_required": false
},
{
"name": "file_hash",
"type": "str",
"description": "override file hash, otherwise automatically computed.",
"is_required": false
},
{
"name": "fee_currency",
"type": "string",
"description": "specify fee currency",
"is_required": false
},
{
"name": "fee_amount",
"type": "decimal",
"description": "content download fee",
"is_required": false
},
{
"name": "fee_address",
"type": "str",
"description": "address where to send fee payments, will use value from --claim_address if not provided",
"is_required": false
},
{
"name": "clear_fee",
"type": "bool",
"description": "clear previously set fee",
"is_required": false
},
{
"name": "title",
"type": "str",
"description": "title of the publication",
"is_required": false
},
{
"name": "description",
"type": "str",
"description": "description of the publication",
"is_required": false
},
{
"name": "author",
"type": "str",
"description": "author of the publication. The usage for this field is not the same as for channels. The author field is used to credit an author who is not the publisher and is not represented by the channel. For example, a pdf file of 'The Odyssey' has an author of 'Homer' but may by published to a channel such as '@classics', or to no channel at all",
"is_required": false
},
{
"name": "tags",
"type": "list",
"description": "add content tags",
"is_required": false
},
{
"name": "clear_tags",
"type": "bool",
"description": "clear existing tags (prior to adding new ones)",
"is_required": false
},
{
"name": "languages",
"type": "list",
"description": "languages used by the channel, using RFC 5646 format, eg: for English `--languages=en` for Spanish (Spain) `--languages=es-ES` for Spanish (Mexican) `--languages=es-MX` for Chinese (Simplified) `--languages=zh-Hans` for Chinese (Traditional) `--languages=zh-Hant`",
"is_required": false
},
{
"name": "clear_languages",
"type": "bool",
"description": "clear existing languages (prior to adding new ones)",
"is_required": false
},
{
"name": "locations",
"type": "list",
"description": "locations relevant to the stream, consisting of 2 letter `country` code and a `state`, `city` and a postal `code` along with a `latitude` and `longitude`. for JSON RPC: pass a dictionary with aforementioned attributes as keys, eg: ... \"locations\": [{'country': 'US', 'state': 'NH'}] ... for command line: pass a colon delimited list with values in the following order: \"COUNTRY:STATE:CITY:CODE:LATITUDE:LONGITUDE\" making sure to include colon for blank values, for example to provide only the city: ... --locations=\"::Manchester\" with all values set: ... --locations=\"US:NH:Manchester:03101:42.990605:-71.460989\" optionally, you can just pass the \"LATITUDE:LONGITUDE\": ... --locations=\"42.990605:-71.460989\" finally, you can also pass JSON string of dictionary on the command line as you would via JSON RPC ... --locations=\"{'country': 'US', 'state': 'NH'}\"",
"is_required": false
},
{
"name": "clear_locations",
"type": "bool",
"description": "clear existing locations (prior to adding new ones)",
"is_required": false
},
{
"name": "license",
"type": "str",
"description": "publication license",
"is_required": false
},
{
"name": "license_url",
"type": "str",
"description": "publication license url",
"is_required": false
},
{
"name": "thumbnail_url",
"type": "str",
"description": "thumbnail url",
"is_required": false
},
{
"name": "release_time",
"type": "int",
"description": "original public release of content, seconds since UNIX epoch",
"is_required": false
},
{
"name": "width",
"type": "int",
"description": "image/video width, automatically calculated from media file",
"is_required": false
},
{
"name": "height",
"type": "int",
"description": "image/video height, automatically calculated from media file",
"is_required": false
},
{
"name": "duration",
"type": "int",
"description": "audio/video duration in seconds, automatically calculated",
"is_required": false
},
{
"name": "channel_id",
"type": "str",
"description": "claim id of the publisher channel",
"is_required": false
},
{
"name": "channel_name",
"type": "str",
"description": "name of the publisher channel",
"is_required": false
},
{
"name": "clear_channel",
"type": "bool",
"description": "remove channel signature",
"is_required": false
},
{
"name": "channel_account_id",
"type": "str",
"description": "one or more account ids for accounts to look in for channel certificates, defaults to all accounts.",
"is_required": false
},
{
"name": "account_id",
"type": "str",
"description": "account in which to look for stream (default: all)",
"is_required": false
},
{
"name": "wallet_id",
"type": "str",
"description": "restrict operation to specific wallet",
"is_required": false
},
{
"name": "funding_account_ids",
"type": "list",
"description": "ids of accounts to fund this transaction",
"is_required": false
},
{
"name": "claim_address",
"type": "str",
"description": "address where the claim is sent to, if not specified it will be determined automatically from the account",
"is_required": false
},
{
"name": "preview",
"type": "bool",
"description": "do not broadcast the transaction",
"is_required": false
},
{
"name": "blocking",
"type": "bool",
"description": "wait until transaction is in mempool",
"is_required": false
},
{
"name": "replace",
"type": "bool",
"description": "instead of modifying specific values on the stream, this will clear all existing values and only save passed in values, useful for form submissions where all values are always set",
"is_required": false
}
],
"returns": " {\n \"txid\": \"hash of transaction in hex\",\n \"height\": \"block where transaction was recorded\",\n \"inputs\": [\n {\n \"txid\": \"hash of transaction in hex\",\n \"nout\": \"position in the transaction\",\n \"height\": \"block where transaction was recorded\",\n \"amount\": \"value of the txo as a decimal\",\n \"address\": \"address of who can spend the txo\",\n \"confirmations\": \"number of confirmed blocks\",\n \"is_change\": \"payment to change address, only available when it can be determined\",\n \"is_received\": \"true if txo was sent from external account to this account\",\n \"is_spent\": \"true if txo is spent\",\n \"is_mine\": \"payment to one of your accounts, only available when it can be determined\",\n \"type\": \"one of 'claim', 'support' or 'purchase'\",\n \"name\": \"when type is 'claim' or 'support', this is the claim name\",\n \"claim_id\": \"when type is 'claim', 'support' or 'purchase', this is the claim id\",\n \"claim_op\": \"when type is 'claim', this determines if it is 'create' or 'update'\",\n \"value\": \"when type is 'claim' or 'support' with payload, this is the decoded protobuf payload\",\n \"value_type\": \"determines the type of the 'value' field: 'channel', 'stream', etc\",\n \"protobuf\": \"hex encoded raw protobuf version of 'value' field\",\n \"permanent_url\": \"when type is 'claim' or 'support', this is the long permanent claim URL\",\n \"claim\": \"for purchase outputs only, metadata of purchased claim\",\n \"reposted_claim\": \"for repost claims only, metadata of claim being reposted\",\n \"signing_channel\": \"for signed claims only, metadata of signing channel\",\n \"is_channel_signature_valid\": \"for signed claims only, whether signature is valid\",\n \"purchase_receipt\": \"metadata for the purchase transaction associated with this claim\"\n }\n ],\n \"outputs\": [\n {\n \"txid\": \"hash of transaction in hex\",\n \"nout\": \"position in the transaction\",\n \"height\": \"block where transaction was recorded\",\n \"amount\": \"value of the txo as a decimal\",\n \"address\": \"address of who can spend the txo\",\n \"confirmations\": \"number of confirmed blocks\",\n \"is_change\": \"payment to change address, only available when it can be determined\",\n \"is_received\": \"true if txo was sent from external account to this account\",\n \"is_spent\": \"true if txo is spent\",\n \"is_mine\": \"payment to one of your accounts, only available when it can be determined\",\n \"type\": \"one of 'claim', 'support' or 'purchase'\",\n \"name\": \"when type is 'claim' or 'support', this is the claim name\",\n \"claim_id\": \"when type is 'claim', 'support' or 'purchase', this is the claim id\",\n \"claim_op\": \"when type is 'claim', this determines if it is 'create' or 'update'\",\n \"value\": \"when type is 'claim' or 'support' with payload, this is the decoded protobuf payload\",\n \"value_type\": \"determines the type of the 'value' field: 'channel', 'stream', etc\",\n \"protobuf\": \"hex encoded raw protobuf version of 'value' field\",\n \"permanent_url\": \"when type is 'claim' or 'support', this is the long permanent claim URL\",\n \"claim\": \"for purchase outputs only, metadata of purchased claim\",\n \"reposted_claim\": \"for repost claims only, metadata of claim being reposted\",\n \"signing_channel\": \"for signed claims only, metadata of signing channel\",\n \"is_channel_signature_valid\": \"for signed claims only, whether signature is valid\",\n \"purchase_receipt\": \"metadata for the purchase transaction associated with this claim\"\n }\n ],\n \"total_input\": \"sum of inputs as a decimal\",\n \"total_output\": \"sum of outputs, sans fee, as a decimal\",\n \"total_fee\": \"fee amount\",\n \"hex\": \"entire transaction encoded in hex\"\n }",
"examples": [
{
"title": "Update a stream claim to add channel",
"curl": "curl -d'{\"method\": \"stream_update\", \"params\": {\"claim_id\": \"03d4002f8c09c4fac675ff2b3bb41bd6b3136f1b\", \"validate_file\": false, \"optimize_file\": false, \"clear_fee\": false, \"tags\": [], \"clear_tags\": false, \"languages\": [], \"clear_languages\": false, \"locations\": [], \"clear_locations\": false, \"channel_id\": \"2c20835e4289fe13bc88249efa4d20c2246b29d7\", \"clear_channel\": false, \"channel_account_id\": [], \"funding_account_ids\": [], \"preview\": false, \"blocking\": false, \"replace\": false}}' http://localhost:5279/",
"lbrynet": "lbrynet stream update 03d4002f8c09c4fac675ff2b3bb41bd6b3136f1b --channel_id=\"2c20835e4289fe13bc88249efa4d20c2246b29d7\"",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"stream_update\", \"params\": {\"claim_id\": \"03d4002f8c09c4fac675ff2b3bb41bd6b3136f1b\", \"validate_file\": false, \"optimize_file\": false, \"clear_fee\": false, \"tags\": [], \"clear_tags\": false, \"languages\": [], \"clear_languages\": false, \"locations\": [], \"clear_locations\": false, \"channel_id\": \"2c20835e4289fe13bc88249efa4d20c2246b29d7\", \"clear_channel\": false, \"channel_account_id\": [], \"funding_account_ids\": [], \"preview\": false, \"blocking\": false, \"replace\": false}}).json()",
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"height\": -2,\n \"hex\": \"01000000024412ccab712ad458ed2c450ae796a1fd67014cc88b2e6436dbf96de15436bcb2000000006a47304402203ea72a540317c922102a0a4d6542b0cc62fe9eb7cca583c1c8d59271bac9a17902201a80461bf002aa6df1fea59610b888f805c5267aa364e3b143360f15685059e80121020c1c56c75a2dbc80abf41c4eba747255560e9171b6a26a4d5e448e5112710a59ffffffff9d61f18f1791c4d6d50a89d1f687c504565afe00e160dec1fcbaeedc2abe8288010000006b483045022100a5229fc465e0d475796026dee75822408d47c640aa7b508cf4fe9d51f6438a00022072f7f649fc2f30254ebc4012fd9fa68998be354609115e738c994779beb9ba6c0121020c25ef96399f35f81c54b40b934d82391c8a9fa5950e7503a25328872cf9f89bffffffff0200e1f50500000000fd2301b7076173747265616d141b6f13b3d61bb43b2bff75c6fac4098c2f00d4034ce801d7296b24c2204dfa9e2488bc13fe89425e83202c5adece9151b63be0b469b1230fcb3a108605f48e7b2c1d5b886d7d6737c93580ed7021901fdf627559f3dc724be3f50c66bc375956cccff2e91f74d9e839c0070a90010a8d010a30fdbd8e75a67f29f701a4e040385e2e23986303ea10239211af907fcbb83578b3e417cb71ce646efd0819dd8c088de1bd120b746d706f716d30395f636e180b22186170706c69636174696f6e2f6f637465742d73747265616d3230f5dd1bd0df88ccbc2f016abaad0b3ffde5e87508dc7af1d964d51736fa260c5f25f2af741573d6bbd59ff458c554972b6d6d76a9149c9c8a38fa0a5c7c78dca0c7262a9b4cd02e5e2a88ac32a0d205000000001976a914f3821a0f3daa8d88ee979459735490111b72c90188ac00000000\",\n \"inputs\": [\n {\n \"address\": \"muo3EZhx8VQtZsscvKLVCS2nk8tPeGSUKC\",\n \"amount\": \"1.0\",\n \"claim_id\": \"03d4002f8c09c4fac675ff2b3bb41bd6b3136f1b\",\n \"claim_op\": \"create\",\n \"confirmations\": 1,\n \"height\": 213,\n \"meta\": {},\n \"name\": \"astream\",\n \"normalized_name\": \"astream\",\n \"nout\": 0,\n \"permanent_url\": \"lbry://astream#03d4002f8c09c4fac675ff2b3bb41bd6b3136f1b\",\n \"timestamp\": 1602347164,\n \"txid\": \"b2bc3654e16df9db36642e8bc84c0167fda196e70a452ced58d42a71abcc1244\",\n \"type\": \"claim\",\n \"value\": {\n \"source\": {\n \"hash\": \"fdbd8e75a67f29f701a4e040385e2e23986303ea10239211af907fcbb83578b3e417cb71ce646efd0819dd8c088de1bd\",\n \"media_type\": \"application/octet-stream\",\n \"name\": \"tmpoqm09_cn\",\n \"sd_hash\": \"f5dd1bd0df88ccbc2f016abaad0b3ffde5e87508dc7af1d964d51736fa260c5f25f2af741573d6bbd59ff458c554972b\",\n \"size\": \"11\"\n },\n \"stream_type\": \"binary\"\n },\n \"value_type\": \"stream\"\n },\n {\n \"address\": \"mzATC6tkxXtP6xGUhJXoUporBcJNru6Lty\",\n \"amount\": \"0.9772285\",\n \"confirmations\": 3,\n \"height\": 211,\n \"nout\": 1,\n \"timestamp\": 1602347163,\n \"txid\": \"8882be2adceebafcc1de60e100fe5a5604c587f6d1890ad5d6c491178ff1619d\",\n \"type\": \"payment\"\n }\n ],\n \"outputs\": [\n {\n \"address\": \"muo3EZhx8VQtZsscvKLVCS2nk8tPeGSUKC\",\n \"amount\": \"1.0\",\n \"claim_id\": \"03d4002f8c09c4fac675ff2b3bb41bd6b3136f1b\",\n \"claim_op\": \"update\",\n \"confirmations\": -2,\n \"height\": -2,\n \"is_channel_signature_valid\": true,\n \"meta\": {},\n \"name\": \"astream\",\n \"normalized_name\": \"astream\",\n \"nout\": 0,\n \"permanent_url\": \"lbry://astream#03d4002f8c09c4fac675ff2b3bb41bd6b3136f1b\",\n \"signing_channel\": {\n \"address\": \"mth8FNCBtmx5M92AtxUpWigDPaB1g2xNpZ\",\n \"amount\": \"1.0\",\n \"claim_id\": \"2c20835e4289fe13bc88249efa4d20c2246b29d7\",\n \"claim_op\": \"update\",\n \"confirmations\": 4,\n \"has_signing_key\": true,\n \"height\": 210,\n \"meta\": {},\n \"name\": \"@channel\",\n \"normalized_name\": \"@channel\",\n \"nout\": 0,\n \"permanent_url\": \"lbry://@channel#2c20835e4289fe13bc88249efa4d20c2246b29d7\",\n \"timestamp\": 1602347163,\n \"txid\": \"db52235e2719bd2fe4e04d0c2de3c527fc84365f980fd5ce147a8d5725eb427c\",\n \"type\": \"claim\",\n \"value\": {\n \"public_key\": \"3056301006072a8648ce3d020106052b8104000a03420004bb438060971d65dfccc532c2c72357b802057d458a9143c2f863461ba8f5f79a512b770a19b80717467e0d0366e8097d3cf803a91609a2827d0701d6562e5a88\",\n \"public_key_id\": \"msagyzG92X562roXPRfSYQkmoNWzMYtZd8\",\n \"title\": \"New Channel\"\n },\n \"value_type\": \"channel\"\n },\n \"timestamp\": null,\n \"txid\": \"455ab61c9819a88dd7b0e7421251fc7883f0c9bafe790049db6e9716149e8e5e\",\n \"type\": \"claim\",\n \"value\": {\n \"source\": {\n \"hash\": \"fdbd8e75a67f29f701a4e040385e2e23986303ea10239211af907fcbb83578b3e417cb71ce646efd0819dd8c088de1bd\",\n \"media_type\": \"application/octet-stream\",\n \"name\": \"tmpoqm09_cn\",\n \"sd_hash\": \"f5dd1bd0df88ccbc2f016abaad0b3ffde5e87508dc7af1d964d51736fa260c5f25f2af741573d6bbd59ff458c554972b\",\n \"size\": \"11\"\n },\n \"stream_type\": \"binary\"\n },\n \"value_type\": \"stream\"\n },\n {\n \"address\": \"n3iWMJMV1ay1fWzeML3rwBGEB2rbczw7WW\",\n \"amount\": \"0.9768965\",\n \"confirmations\": -2,\n \"height\": -2,\n \"nout\": 1,\n \"timestamp\": null,\n \"txid\": \"455ab61c9819a88dd7b0e7421251fc7883f0c9bafe790049db6e9716149e8e5e\",\n \"type\": \"payment\"\n }\n ],\n \"total_fee\": \"0.000332\",\n \"total_input\": \"1.9772285\",\n \"total_output\": \"1.9768965\",\n \"txid\": \"455ab61c9819a88dd7b0e7421251fc7883f0c9bafe790049db6e9716149e8e5e\"\n }\n}"
}
]
}
]
},
"support": {
"doc": "Create, list and abandon all types of supports.",
"commands": [
{
"name": "support_abandon",
"description": "Abandon supports, including tips, of a specific claim, optionally\nkeeping some amount as supports.",
"arguments": [
{
"name": "claim_id",
"type": "str",
"description": "claim_id of the support to abandon",
"is_required": false
},
{
"name": "txid",
"type": "str",
"description": "txid of the claim to abandon",
"is_required": false
},
{
"name": "nout",
"type": "int",
"description": "nout of the claim to abandon",
"is_required": false
},
{
"name": "keep",
"type": "decimal",
"description": "amount of lbc to keep as support",
"is_required": false
},
{
"name": "account_id",
"type": "str",
"description": "id of the account to use",
"is_required": false
},
{
"name": "wallet_id",
"type": "str",
"description": "restrict operation to specific wallet",
"is_required": false
},
{
"name": "preview",
"type": "bool",
"description": "do not broadcast the transaction",
"is_required": false
},
{
"name": "blocking",
"type": "bool",
"description": "wait until abandon is in mempool",
"is_required": false
}
],
"returns": " {\n \"txid\": \"hash of transaction in hex\",\n \"height\": \"block where transaction was recorded\",\n \"inputs\": [\n {\n \"txid\": \"hash of transaction in hex\",\n \"nout\": \"position in the transaction\",\n \"height\": \"block where transaction was recorded\",\n \"amount\": \"value of the txo as a decimal\",\n \"address\": \"address of who can spend the txo\",\n \"confirmations\": \"number of confirmed blocks\",\n \"is_change\": \"payment to change address, only available when it can be determined\",\n \"is_received\": \"true if txo was sent from external account to this account\",\n \"is_spent\": \"true if txo is spent\",\n \"is_mine\": \"payment to one of your accounts, only available when it can be determined\",\n \"type\": \"one of 'claim', 'support' or 'purchase'\",\n \"name\": \"when type is 'claim' or 'support', this is the claim name\",\n \"claim_id\": \"when type is 'claim', 'support' or 'purchase', this is the claim id\",\n \"claim_op\": \"when type is 'claim', this determines if it is 'create' or 'update'\",\n \"value\": \"when type is 'claim' or 'support' with payload, this is the decoded protobuf payload\",\n \"value_type\": \"determines the type of the 'value' field: 'channel', 'stream', etc\",\n \"protobuf\": \"hex encoded raw protobuf version of 'value' field\",\n \"permanent_url\": \"when type is 'claim' or 'support', this is the long permanent claim URL\",\n \"claim\": \"for purchase outputs only, metadata of purchased claim\",\n \"reposted_claim\": \"for repost claims only, metadata of claim being reposted\",\n \"signing_channel\": \"for signed claims only, metadata of signing channel\",\n \"is_channel_signature_valid\": \"for signed claims only, whether signature is valid\",\n \"purchase_receipt\": \"metadata for the purchase transaction associated with this claim\"\n }\n ],\n \"outputs\": [\n {\n \"txid\": \"hash of transaction in hex\",\n \"nout\": \"position in the transaction\",\n \"height\": \"block where transaction was recorded\",\n \"amount\": \"value of the txo as a decimal\",\n \"address\": \"address of who can spend the txo\",\n \"confirmations\": \"number of confirmed blocks\",\n \"is_change\": \"payment to change address, only available when it can be determined\",\n \"is_received\": \"true if txo was sent from external account to this account\",\n \"is_spent\": \"true if txo is spent\",\n \"is_mine\": \"payment to one of your accounts, only available when it can be determined\",\n \"type\": \"one of 'claim', 'support' or 'purchase'\",\n \"name\": \"when type is 'claim' or 'support', this is the claim name\",\n \"claim_id\": \"when type is 'claim', 'support' or 'purchase', this is the claim id\",\n \"claim_op\": \"when type is 'claim', this determines if it is 'create' or 'update'\",\n \"value\": \"when type is 'claim' or 'support' with payload, this is the decoded protobuf payload\",\n \"value_type\": \"determines the type of the 'value' field: 'channel', 'stream', etc\",\n \"protobuf\": \"hex encoded raw protobuf version of 'value' field\",\n \"permanent_url\": \"when type is 'claim' or 'support', this is the long permanent claim URL\",\n \"claim\": \"for purchase outputs only, metadata of purchased claim\",\n \"reposted_claim\": \"for repost claims only, metadata of claim being reposted\",\n \"signing_channel\": \"for signed claims only, metadata of signing channel\",\n \"is_channel_signature_valid\": \"for signed claims only, whether signature is valid\",\n \"purchase_receipt\": \"metadata for the purchase transaction associated with this claim\"\n }\n ],\n \"total_input\": \"sum of inputs as a decimal\",\n \"total_output\": \"sum of outputs, sans fee, as a decimal\",\n \"total_fee\": \"fee amount\",\n \"hex\": \"entire transaction encoded in hex\"\n }",
"examples": []
},
{
"name": "support_create",
"description": "Create a support or a tip for name claim.",
"arguments": [
{
"name": "claim_id",
"type": "str",
"description": "claim_id of the claim to support",
"is_required": true
},
{
"name": "amount",
"type": "decimal",
"description": "amount of support",
"is_required": true
},
{
"name": "tip",
"type": "bool",
"description": "send support to claim owner, default: false.",
"is_required": false
},
{
"name": "channel_id",
"type": "str",
"description": "claim id of the supporters identity channel",
"is_required": false
},
{
"name": "channel_name",
"type": "str",
"description": "name of the supporters identity channel",
"is_required": false
},
{
"name": "channel_account_id",
"type": "str",
"description": "one or more account ids for accounts to look in for channel certificates, defaults to all accounts.",
"is_required": false
},
{
"name": "account_id",
"type": "str",
"description": "account to use for holding the transaction",
"is_required": false
},
{
"name": "wallet_id",
"type": "str",
"description": "restrict operation to specific wallet",
"is_required": false
},
{
"name": "funding_account_ids",
"type": "list",
"description": "ids of accounts to fund this transaction",
"is_required": false
},
{
"name": "preview",
"type": "bool",
"description": "do not broadcast the transaction",
"is_required": false
},
{
"name": "blocking",
"type": "bool",
"description": "wait until transaction is in mempool",
"is_required": false
}
],
"returns": " {\n \"txid\": \"hash of transaction in hex\",\n \"height\": \"block where transaction was recorded\",\n \"inputs\": [\n {\n \"txid\": \"hash of transaction in hex\",\n \"nout\": \"position in the transaction\",\n \"height\": \"block where transaction was recorded\",\n \"amount\": \"value of the txo as a decimal\",\n \"address\": \"address of who can spend the txo\",\n \"confirmations\": \"number of confirmed blocks\",\n \"is_change\": \"payment to change address, only available when it can be determined\",\n \"is_received\": \"true if txo was sent from external account to this account\",\n \"is_spent\": \"true if txo is spent\",\n \"is_mine\": \"payment to one of your accounts, only available when it can be determined\",\n \"type\": \"one of 'claim', 'support' or 'purchase'\",\n \"name\": \"when type is 'claim' or 'support', this is the claim name\",\n \"claim_id\": \"when type is 'claim', 'support' or 'purchase', this is the claim id\",\n \"claim_op\": \"when type is 'claim', this determines if it is 'create' or 'update'\",\n \"value\": \"when type is 'claim' or 'support' with payload, this is the decoded protobuf payload\",\n \"value_type\": \"determines the type of the 'value' field: 'channel', 'stream', etc\",\n \"protobuf\": \"hex encoded raw protobuf version of 'value' field\",\n \"permanent_url\": \"when type is 'claim' or 'support', this is the long permanent claim URL\",\n \"claim\": \"for purchase outputs only, metadata of purchased claim\",\n \"reposted_claim\": \"for repost claims only, metadata of claim being reposted\",\n \"signing_channel\": \"for signed claims only, metadata of signing channel\",\n \"is_channel_signature_valid\": \"for signed claims only, whether signature is valid\",\n \"purchase_receipt\": \"metadata for the purchase transaction associated with this claim\"\n }\n ],\n \"outputs\": [\n {\n \"txid\": \"hash of transaction in hex\",\n \"nout\": \"position in the transaction\",\n \"height\": \"block where transaction was recorded\",\n \"amount\": \"value of the txo as a decimal\",\n \"address\": \"address of who can spend the txo\",\n \"confirmations\": \"number of confirmed blocks\",\n \"is_change\": \"payment to change address, only available when it can be determined\",\n \"is_received\": \"true if txo was sent from external account to this account\",\n \"is_spent\": \"true if txo is spent\",\n \"is_mine\": \"payment to one of your accounts, only available when it can be determined\",\n \"type\": \"one of 'claim', 'support' or 'purchase'\",\n \"name\": \"when type is 'claim' or 'support', this is the claim name\",\n \"claim_id\": \"when type is 'claim', 'support' or 'purchase', this is the claim id\",\n \"claim_op\": \"when type is 'claim', this determines if it is 'create' or 'update'\",\n \"value\": \"when type is 'claim' or 'support' with payload, this is the decoded protobuf payload\",\n \"value_type\": \"determines the type of the 'value' field: 'channel', 'stream', etc\",\n \"protobuf\": \"hex encoded raw protobuf version of 'value' field\",\n \"permanent_url\": \"when type is 'claim' or 'support', this is the long permanent claim URL\",\n \"claim\": \"for purchase outputs only, metadata of purchased claim\",\n \"reposted_claim\": \"for repost claims only, metadata of claim being reposted\",\n \"signing_channel\": \"for signed claims only, metadata of signing channel\",\n \"is_channel_signature_valid\": \"for signed claims only, whether signature is valid\",\n \"purchase_receipt\": \"metadata for the purchase transaction associated with this claim\"\n }\n ],\n \"total_input\": \"sum of inputs as a decimal\",\n \"total_output\": \"sum of outputs, sans fee, as a decimal\",\n \"total_fee\": \"fee amount\",\n \"hex\": \"entire transaction encoded in hex\"\n }",
"examples": []
},
{
"name": "support_list",
"description": "List staked supports and sent/received tips.",
"arguments": [
{
"name": "name",
"type": "str or list",
"description": "claim name",
"is_required": false
},
{
"name": "claim_id",
"type": "str or list",
"description": "claim id",
"is_required": false
},
{
"name": "received",
"type": "bool",
"description": "only show received (tips)",
"is_required": false
},
{
"name": "sent",
"type": "bool",
"description": "only show sent (tips)",
"is_required": false
},
{
"name": "staked",
"type": "bool",
"description": "only show my staked supports",
"is_required": false
},
{
"name": "is_spent",
"type": "bool",
"description": "show abandoned supports",
"is_required": false
},
{
"name": "account_id",
"type": "str",
"description": "id of the account to query",
"is_required": false
},
{
"name": "wallet_id",
"type": "str",
"description": "restrict results to specific wallet",
"is_required": false
},
{
"name": "page",
"type": "int",
"description": "page to return during paginating",
"is_required": false
},
{
"name": "page_size",
"type": "int",
"description": "number of items on page during pagination",
"is_required": false
},
{
"name": "no_totals",
"type": "bool",
"description": "do not calculate the total number of pages and items in result set (significant performance boost)",
"is_required": false
}
],
"returns": " {\n \"page\": \"Page number of the current items.\",\n \"page_size\": \"Number of items to show on a page.\",\n \"total_pages\": \"Total number of pages.\",\n \"total_items\": \"Total number of items.\",\n \"items\": [\n {\n \"txid\": \"hash of transaction in hex\",\n \"nout\": \"position in the transaction\",\n \"height\": \"block where transaction was recorded\",\n \"amount\": \"value of the txo as a decimal\",\n \"address\": \"address of who can spend the txo\",\n \"confirmations\": \"number of confirmed blocks\",\n \"is_change\": \"payment to change address, only available when it can be determined\",\n \"is_received\": \"true if txo was sent from external account to this account\",\n \"is_spent\": \"true if txo is spent\",\n \"is_mine\": \"payment to one of your accounts, only available when it can be determined\",\n \"type\": \"one of 'claim', 'support' or 'purchase'\",\n \"name\": \"when type is 'claim' or 'support', this is the claim name\",\n \"claim_id\": \"when type is 'claim', 'support' or 'purchase', this is the claim id\",\n \"claim_op\": \"when type is 'claim', this determines if it is 'create' or 'update'\",\n \"value\": \"when type is 'claim' or 'support' with payload, this is the decoded protobuf payload\",\n \"value_type\": \"determines the type of the 'value' field: 'channel', 'stream', etc\",\n \"protobuf\": \"hex encoded raw protobuf version of 'value' field\",\n \"permanent_url\": \"when type is 'claim' or 'support', this is the long permanent claim URL\",\n \"claim\": \"for purchase outputs only, metadata of purchased claim\",\n \"reposted_claim\": \"for repost claims only, metadata of claim being reposted\",\n \"signing_channel\": \"for signed claims only, metadata of signing channel\",\n \"is_channel_signature_valid\": \"for signed claims only, whether signature is valid\",\n \"purchase_receipt\": \"metadata for the purchase transaction associated with this claim\"\n }\n ]\n }",
"examples": []
}
]
},
"sync": {
"doc": "Wallet synchronization.",
"commands": [
{
"name": "sync_apply",
"description": "Apply incoming synchronization data, if provided, and return a sync hash and update wallet data.\n\nWallet must be unlocked to perform this operation.\n\nIf \"encrypt-on-disk\" preference is True and supplied password is different from local password,\nor there is no local password (because local wallet was not encrypted), then the supplied password\nwill be used for local encryption (overwriting previous local encryption password).",
"arguments": [
{
"name": "password",
"type": "str",
"description": "password to decrypt incoming and encrypt outgoing data",
"is_required": false
},
{
"name": "data",
"type": "str",
"description": "incoming sync data, if any",
"is_required": false
},
{
"name": "wallet_id",
"type": "str",
"description": "wallet being sync'ed",
"is_required": false
},
{
"name": "blocking",
"type": "bool",
"description": "wait until any new accounts have sync'ed",
"is_required": false
}
],
"returns": "(map) sync hash and data",
"examples": []
},
{
"name": "sync_hash",
"description": "Deterministic hash of the wallet.",
"arguments": [
{
"name": "wallet_id",
"type": "str",
"description": "wallet for which to generate hash",
"is_required": false
}
],
"returns": "(str) sha256 hash of wallet",
"examples": []
}
]
},
"tracemalloc": {
"doc": "Controls and queries tracemalloc memory tracing tools for troubleshooting.",
"commands": [
{
"name": "tracemalloc_disable",
"description": "Disable tracemalloc memory tracing",
"arguments": [],
"returns": "(bool) is it tracing?",
"examples": []
},
{
"name": "tracemalloc_enable",
"description": "Enable tracemalloc memory tracing",
"arguments": [],
"returns": "(bool) is it tracing?",
"examples": []
},
{
"name": "tracemalloc_top",
"description": "Show most common objects, the place that created them and their size.",
"arguments": [
{
"name": "items",
"type": "int",
"description": "maximum items to return, from the most common",
"is_required": true
}
],
"returns": "(dict) dictionary containing most common objects in memory\n {\n \"line\": (str) filename and line number where it was created,\n \"code\": (str) code that created it,\n \"size\": (int) size in bytes, for each \"memory block\",\n \"count\" (int) number of memory blocks\n }",
"examples": []
}
]
},
"transaction": {
"doc": "Transaction management.",
"commands": [
{
"name": "transaction_list",
"description": "List transactions belonging to wallet",
"arguments": [
{
"name": "account_id",
"type": "str",
"description": "id of the account to query",
"is_required": false
},
{
"name": "wallet_id",
"type": "str",
"description": "restrict results to specific wallet",
"is_required": false
},
{
"name": "page",
"type": "int",
"description": "page to return during paginating",
"is_required": false
},
{
"name": "page_size",
"type": "int",
"description": "number of items on page during pagination",
"is_required": false
}
],
"returns": "(list) List of transactions\n\n {\n \"claim_info\": (list) claim info if in txn [{\n \"address\": (str) address of claim,\n \"balance_delta\": (float) bid amount,\n \"amount\": (float) claim amount,\n \"claim_id\": (str) claim id,\n \"claim_name\": (str) claim name,\n \"nout\": (int) nout\n }],\n \"abandon_info\": (list) abandon info if in txn [{\n \"address\": (str) address of abandoned claim,\n \"balance_delta\": (float) returned amount,\n \"amount\": (float) claim amount,\n \"claim_id\": (str) claim id,\n \"claim_name\": (str) claim name,\n \"nout\": (int) nout\n }],\n \"confirmations\": (int) number of confirmations for the txn,\n \"date\": (str) date and time of txn,\n \"fee\": (float) txn fee,\n \"support_info\": (list) support info if in txn [{\n \"address\": (str) address of support,\n \"balance_delta\": (float) support amount,\n \"amount\": (float) support amount,\n \"claim_id\": (str) claim id,\n \"claim_name\": (str) claim name,\n \"is_tip\": (bool),\n \"nout\": (int) nout\n }],\n \"timestamp\": (int) timestamp,\n \"txid\": (str) txn id,\n \"update_info\": (list) update info if in txn [{\n \"address\": (str) address of claim,\n \"balance_delta\": (float) credited/debited\n \"amount\": (float) absolute amount,\n \"claim_id\": (str) claim id,\n \"claim_name\": (str) claim name,\n \"nout\": (int) nout\n }],\n \"value\": (float) value of txn\n }",
"examples": [
{
"title": "List your transactions",
"curl": "curl -d'{\"method\": \"transaction_list\", \"params\": {}}' http://localhost:5279/",
"lbrynet": "lbrynet transaction list",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"transaction_list\", \"params\": {}}).json()",
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"items\": [\n {\n \"abandon_info\": [],\n \"claim_info\": [],\n \"confirmations\": 1,\n \"date\": \"2020-10-10 12:26\",\n \"fee\": \"-0.000124\",\n \"purchase_info\": [],\n \"support_info\": [],\n \"timestamp\": 1602347163,\n \"txid\": \"7a5c9610fd69d73a634decc9e60adf58239968d40ae2fe59fcf9f0bf1ab03a69\",\n \"update_info\": [],\n \"value\": \"0.0\"\n },\n {\n \"abandon_info\": [],\n \"claim_info\": [],\n \"confirmations\": 7,\n \"date\": \"2020-10-10 12:26\",\n \"fee\": \"0.0\",\n \"purchase_info\": [],\n \"support_info\": [],\n \"timestamp\": 1602347162,\n \"txid\": \"e7a829b44f7e4f8083b3e55bbe83cacf0c9bdbe91fc0bd3413d62a759e903777\",\n \"update_info\": [],\n \"value\": \"10.0\"\n }\n ],\n \"page\": 1,\n \"page_size\": 20,\n \"total_items\": 2,\n \"total_pages\": 1\n }\n}"
}
]
},
{
"name": "transaction_show",
"description": "Get a decoded transaction from a txid",
"arguments": [
{
"name": "txid",
"type": "str",
"description": "txid of the transaction",
"is_required": true
}
],
"returns": " {\n \"txid\": \"hash of transaction in hex\",\n \"height\": \"block where transaction was recorded\",\n \"inputs\": [\n {\n \"txid\": \"hash of transaction in hex\",\n \"nout\": \"position in the transaction\",\n \"height\": \"block where transaction was recorded\",\n \"amount\": \"value of the txo as a decimal\",\n \"address\": \"address of who can spend the txo\",\n \"confirmations\": \"number of confirmed blocks\",\n \"is_change\": \"payment to change address, only available when it can be determined\",\n \"is_received\": \"true if txo was sent from external account to this account\",\n \"is_spent\": \"true if txo is spent\",\n \"is_mine\": \"payment to one of your accounts, only available when it can be determined\",\n \"type\": \"one of 'claim', 'support' or 'purchase'\",\n \"name\": \"when type is 'claim' or 'support', this is the claim name\",\n \"claim_id\": \"when type is 'claim', 'support' or 'purchase', this is the claim id\",\n \"claim_op\": \"when type is 'claim', this determines if it is 'create' or 'update'\",\n \"value\": \"when type is 'claim' or 'support' with payload, this is the decoded protobuf payload\",\n \"value_type\": \"determines the type of the 'value' field: 'channel', 'stream', etc\",\n \"protobuf\": \"hex encoded raw protobuf version of 'value' field\",\n \"permanent_url\": \"when type is 'claim' or 'support', this is the long permanent claim URL\",\n \"claim\": \"for purchase outputs only, metadata of purchased claim\",\n \"reposted_claim\": \"for repost claims only, metadata of claim being reposted\",\n \"signing_channel\": \"for signed claims only, metadata of signing channel\",\n \"is_channel_signature_valid\": \"for signed claims only, whether signature is valid\",\n \"purchase_receipt\": \"metadata for the purchase transaction associated with this claim\"\n }\n ],\n \"outputs\": [\n {\n \"txid\": \"hash of transaction in hex\",\n \"nout\": \"position in the transaction\",\n \"height\": \"block where transaction was recorded\",\n \"amount\": \"value of the txo as a decimal\",\n \"address\": \"address of who can spend the txo\",\n \"confirmations\": \"number of confirmed blocks\",\n \"is_change\": \"payment to change address, only available when it can be determined\",\n \"is_received\": \"true if txo was sent from external account to this account\",\n \"is_spent\": \"true if txo is spent\",\n \"is_mine\": \"payment to one of your accounts, only available when it can be determined\",\n \"type\": \"one of 'claim', 'support' or 'purchase'\",\n \"name\": \"when type is 'claim' or 'support', this is the claim name\",\n \"claim_id\": \"when type is 'claim', 'support' or 'purchase', this is the claim id\",\n \"claim_op\": \"when type is 'claim', this determines if it is 'create' or 'update'\",\n \"value\": \"when type is 'claim' or 'support' with payload, this is the decoded protobuf payload\",\n \"value_type\": \"determines the type of the 'value' field: 'channel', 'stream', etc\",\n \"protobuf\": \"hex encoded raw protobuf version of 'value' field\",\n \"permanent_url\": \"when type is 'claim' or 'support', this is the long permanent claim URL\",\n \"claim\": \"for purchase outputs only, metadata of purchased claim\",\n \"reposted_claim\": \"for repost claims only, metadata of claim being reposted\",\n \"signing_channel\": \"for signed claims only, metadata of signing channel\",\n \"is_channel_signature_valid\": \"for signed claims only, whether signature is valid\",\n \"purchase_receipt\": \"metadata for the purchase transaction associated with this claim\"\n }\n ],\n \"total_input\": \"sum of inputs as a decimal\",\n \"total_output\": \"sum of outputs, sans fee, as a decimal\",\n \"total_fee\": \"fee amount\",\n \"hex\": \"entire transaction encoded in hex\"\n }",
"examples": []
}
]
},
"txo": {
"doc": "List and sum transaction outputs.",
"commands": [
{
"name": "txo_list",
"description": "List my transaction outputs.",
"arguments": [
{
"name": "type",
"type": "str or list",
"description": "claim type: stream, channel, support, purchase, collection, repost, other",
"is_required": false
},
{
"name": "txid",
"type": "str or list",
"description": "transaction id of outputs",
"is_required": false
},
{
"name": "claim_id",
"type": "str or list",
"description": "claim id",
"is_required": false
},
{
"name": "channel_id",
"type": "str or list",
"description": "claims in this channel",
"is_required": false
},
{
"name": "name",
"type": "str or list",
"description": "claim name",
"is_required": false
},
{
"name": "is_spent",
"type": "bool",
"description": "only show spent txos",
"is_required": false
},
{
"name": "is_not_spent",
"type": "bool",
"description": "only show not spent txos",
"is_required": false
},
{
"name": "is_my_input_or_output",
"type": "bool",
"description": "txos which have your inputs or your outputs, if using this flag the other related flags are ignored (--is_my_output, --is_my_input, etc)",
"is_required": false
},
{
"name": "is_my_output",
"type": "bool",
"description": "show outputs controlled by you",
"is_required": false
},
{
"name": "is_not_my_output",
"type": "bool",
"description": "show outputs not controlled by you",
"is_required": false
},
{
"name": "is_my_input",
"type": "bool",
"description": "show outputs created by you",
"is_required": false
},
{
"name": "is_not_my_input",
"type": "bool",
"description": "show outputs not created by you",
"is_required": false
},
{
"name": "exclude_internal_transfers",
"type": "bool",
"description": "excludes any outputs that are exactly this combination: \"--is_my_input --is_my_output --type=other\" this allows to exclude \"change\" payments, this flag can be used in combination with any of the other flags",
"is_required": false
},
{
"name": "include_received_tips",
"type": "bool",
"description": "calculate the amount of tips recieved for claim outputs",
"is_required": false
},
{
"name": "account_id",
"type": "str",
"description": "id of the account to query",
"is_required": false
},
{
"name": "wallet_id",
"type": "str",
"description": "restrict results to specific wallet",
"is_required": false
},
{
"name": "page",
"type": "int",
"description": "page to return during paginating",
"is_required": false
},
{
"name": "page_size",
"type": "int",
"description": "number of items on page during pagination",
"is_required": false
},
{
"name": "resolve",
"type": "bool",
"description": "resolves each claim to provide additional metadata",
"is_required": false
},
{
"name": "order_by",
"type": "str",
"description": "field to order by: 'name', 'height', 'amount' and 'none'",
"is_required": false
},
{
"name": "no_totals",
"type": "bool",
"description": "do not calculate the total number of pages and items in result set (significant performance boost)",
"is_required": false
}
],
"returns": " {\n \"page\": \"Page number of the current items.\",\n \"page_size\": \"Number of items to show on a page.\",\n \"total_pages\": \"Total number of pages.\",\n \"total_items\": \"Total number of items.\",\n \"items\": [\n {\n \"txid\": \"hash of transaction in hex\",\n \"nout\": \"position in the transaction\",\n \"height\": \"block where transaction was recorded\",\n \"amount\": \"value of the txo as a decimal\",\n \"address\": \"address of who can spend the txo\",\n \"confirmations\": \"number of confirmed blocks\",\n \"is_change\": \"payment to change address, only available when it can be determined\",\n \"is_received\": \"true if txo was sent from external account to this account\",\n \"is_spent\": \"true if txo is spent\",\n \"is_mine\": \"payment to one of your accounts, only available when it can be determined\",\n \"type\": \"one of 'claim', 'support' or 'purchase'\",\n \"name\": \"when type is 'claim' or 'support', this is the claim name\",\n \"claim_id\": \"when type is 'claim', 'support' or 'purchase', this is the claim id\",\n \"claim_op\": \"when type is 'claim', this determines if it is 'create' or 'update'\",\n \"value\": \"when type is 'claim' or 'support' with payload, this is the decoded protobuf payload\",\n \"value_type\": \"determines the type of the 'value' field: 'channel', 'stream', etc\",\n \"protobuf\": \"hex encoded raw protobuf version of 'value' field\",\n \"permanent_url\": \"when type is 'claim' or 'support', this is the long permanent claim URL\",\n \"claim\": \"for purchase outputs only, metadata of purchased claim\",\n \"reposted_claim\": \"for repost claims only, metadata of claim being reposted\",\n \"signing_channel\": \"for signed claims only, metadata of signing channel\",\n \"is_channel_signature_valid\": \"for signed claims only, whether signature is valid\",\n \"purchase_receipt\": \"metadata for the purchase transaction associated with this claim\"\n }\n ]\n }",
"examples": []
},
{
"name": "txo_plot",
"description": "Plot transaction output sum over days.",
"arguments": [
{
"name": "type",
"type": "str or list",
"description": "claim type: stream, channel, support, purchase, collection, repost, other",
"is_required": false
},
{
"name": "txid",
"type": "str or list",
"description": "transaction id of outputs",
"is_required": false
},
{
"name": "claim_id",
"type": "str or list",
"description": "claim id",
"is_required": false
},
{
"name": "name",
"type": "str or list",
"description": "claim name",
"is_required": false
},
{
"name": "is_spent",
"type": "bool",
"description": "only show spent txos",
"is_required": false
},
{
"name": "is_not_spent",
"type": "bool",
"description": "only show not spent txos",
"is_required": false
},
{
"name": "is_my_input_or_output",
"type": "bool",
"description": "txos which have your inputs or your outputs, if using this flag the other related flags are ignored (--is_my_output, --is_my_input, etc)",
"is_required": false
},
{
"name": "is_my_output",
"type": "bool",
"description": "show outputs controlled by you",
"is_required": false
},
{
"name": "is_not_my_output",
"type": "bool",
"description": "show outputs not controlled by you",
"is_required": false
},
{
"name": "is_my_input",
"type": "bool",
"description": "show outputs created by you",
"is_required": false
},
{
"name": "is_not_my_input",
"type": "bool",
"description": "show outputs not created by you",
"is_required": false
},
{
"name": "exclude_internal_transfers",
"type": "bool",
"description": "excludes any outputs that are exactly this combination: \"--is_my_input --is_my_output --type=other\" this allows to exclude \"change\" payments, this flag can be used in combination with any of the other flags",
"is_required": false
},
{
"name": "account_id",
"type": "str",
"description": "id of the account to query",
"is_required": false
},
{
"name": "wallet_id",
"type": "str",
"description": "restrict results to specific wallet",
"is_required": false
},
{
"name": "days_back",
"type": "int",
"description": "number of days back from today (not compatible with --start_day, --days_after, --end_day)",
"is_required": false
},
{
"name": "start_day",
"type": "date",
"description": "start on specific date (YYYY-MM-DD) (instead of --days_back)",
"is_required": false
},
{
"name": "days_after",
"type": "int",
"description": "end number of days after --start_day (instead of --end_day)",
"is_required": false
},
{
"name": "end_day",
"type": "date",
"description": "end on specific date (YYYY-MM-DD) (instead of --days_after)",
"is_required": false
}
],
"returns": "List[Dict]",
"examples": []
},
{
"name": "txo_spend",
"description": "Spend transaction outputs, batching into multiple transactions as necessary.",
"arguments": [
{
"name": "type",
"type": "str or list",
"description": "claim type: stream, channel, support, purchase, collection, repost, other",
"is_required": false
},
{
"name": "txid",
"type": "str or list",
"description": "transaction id of outputs",
"is_required": false
},
{
"name": "claim_id",
"type": "str or list",
"description": "claim id",
"is_required": false
},
{
"name": "channel_id",
"type": "str or list",
"description": "claims in this channel",
"is_required": false
},
{
"name": "name",
"type": "str or list",
"description": "claim name",
"is_required": false
},
{
"name": "is_my_input",
"type": "bool",
"description": "show outputs created by you",
"is_required": false
},
{
"name": "is_not_my_input",
"type": "bool",
"description": "show outputs not created by you",
"is_required": false
},
{
"name": "exclude_internal_transfers",
"type": "bool",
"description": "excludes any outputs that are exactly this combination: \"--is_my_input --is_my_output --type=other\" this allows to exclude \"change\" payments, this flag can be used in combination with any of the other flags",
"is_required": false
},
{
"name": "account_id",
"type": "str",
"description": "id of the account to query",
"is_required": false
},
{
"name": "wallet_id",
"type": "str",
"description": "restrict results to specific wallet",
"is_required": false
},
{
"name": "preview",
"type": "bool",
"description": "do not broadcast the transaction",
"is_required": false
},
{
"name": "blocking",
"type": "bool",
"description": "wait until abandon is in mempool",
"is_required": false
},
{
"name": "batch_size",
"type": "int",
"description": "number of txos to spend per transactions",
"is_required": false
},
{
"name": "include_full_tx",
"type": "bool",
"description": "include entire tx in output and not just the txid",
"is_required": false
}
],
"returns": " [\n {\n \"txid\": \"hash of transaction in hex\",\n \"height\": \"block where transaction was recorded\",\n \"inputs\": [\n {\n \"txid\": \"hash of transaction in hex\",\n \"nout\": \"position in the transaction\",\n \"height\": \"block where transaction was recorded\",\n \"amount\": \"value of the txo as a decimal\",\n \"address\": \"address of who can spend the txo\",\n \"confirmations\": \"number of confirmed blocks\",\n \"is_change\": \"payment to change address, only available when it can be determined\",\n \"is_received\": \"true if txo was sent from external account to this account\",\n \"is_spent\": \"true if txo is spent\",\n \"is_mine\": \"payment to one of your accounts, only available when it can be determined\",\n \"type\": \"one of 'claim', 'support' or 'purchase'\",\n \"name\": \"when type is 'claim' or 'support', this is the claim name\",\n \"claim_id\": \"when type is 'claim', 'support' or 'purchase', this is the claim id\",\n \"claim_op\": \"when type is 'claim', this determines if it is 'create' or 'update'\",\n \"value\": \"when type is 'claim' or 'support' with payload, this is the decoded protobuf payload\",\n \"value_type\": \"determines the type of the 'value' field: 'channel', 'stream', etc\",\n \"protobuf\": \"hex encoded raw protobuf version of 'value' field\",\n \"permanent_url\": \"when type is 'claim' or 'support', this is the long permanent claim URL\",\n \"claim\": \"for purchase outputs only, metadata of purchased claim\",\n \"reposted_claim\": \"for repost claims only, metadata of claim being reposted\",\n \"signing_channel\": \"for signed claims only, metadata of signing channel\",\n \"is_channel_signature_valid\": \"for signed claims only, whether signature is valid\",\n \"purchase_receipt\": \"metadata for the purchase transaction associated with this claim\"\n }\n ],\n \"outputs\": [\n {\n \"txid\": \"hash of transaction in hex\",\n \"nout\": \"position in the transaction\",\n \"height\": \"block where transaction was recorded\",\n \"amount\": \"value of the txo as a decimal\",\n \"address\": \"address of who can spend the txo\",\n \"confirmations\": \"number of confirmed blocks\",\n \"is_change\": \"payment to change address, only available when it can be determined\",\n \"is_received\": \"true if txo was sent from external account to this account\",\n \"is_spent\": \"true if txo is spent\",\n \"is_mine\": \"payment to one of your accounts, only available when it can be determined\",\n \"type\": \"one of 'claim', 'support' or 'purchase'\",\n \"name\": \"when type is 'claim' or 'support', this is the claim name\",\n \"claim_id\": \"when type is 'claim', 'support' or 'purchase', this is the claim id\",\n \"claim_op\": \"when type is 'claim', this determines if it is 'create' or 'update'\",\n \"value\": \"when type is 'claim' or 'support' with payload, this is the decoded protobuf payload\",\n \"value_type\": \"determines the type of the 'value' field: 'channel', 'stream', etc\",\n \"protobuf\": \"hex encoded raw protobuf version of 'value' field\",\n \"permanent_url\": \"when type is 'claim' or 'support', this is the long permanent claim URL\",\n \"claim\": \"for purchase outputs only, metadata of purchased claim\",\n \"reposted_claim\": \"for repost claims only, metadata of claim being reposted\",\n \"signing_channel\": \"for signed claims only, metadata of signing channel\",\n \"is_channel_signature_valid\": \"for signed claims only, whether signature is valid\",\n \"purchase_receipt\": \"metadata for the purchase transaction associated with this claim\"\n }\n ],\n \"total_input\": \"sum of inputs as a decimal\",\n \"total_output\": \"sum of outputs, sans fee, as a decimal\",\n \"total_fee\": \"fee amount\",\n \"hex\": \"entire transaction encoded in hex\"\n }\n ]",
"examples": []
},
{
"name": "txo_sum",
"description": "Sum of transaction outputs.",
"arguments": [
{
"name": "type",
"type": "str or list",
"description": "claim type: stream, channel, support, purchase, collection, repost, other",
"is_required": false
},
{
"name": "txid",
"type": "str or list",
"description": "transaction id of outputs",
"is_required": false
},
{
"name": "claim_id",
"type": "str or list",
"description": "claim id",
"is_required": false
},
{
"name": "name",
"type": "str or list",
"description": "claim name",
"is_required": false
},
{
"name": "is_spent",
"type": "bool",
"description": "only show spent txos",
"is_required": false
},
{
"name": "is_not_spent",
"type": "bool",
"description": "only show not spent txos",
"is_required": false
},
{
"name": "is_my_input_or_output",
"type": "bool",
"description": "txos which have your inputs or your outputs, if using this flag the other related flags are ignored (--is_my_output, --is_my_input, etc)",
"is_required": false
},
{
"name": "is_my_output",
"type": "bool",
"description": "show outputs controlled by you",
"is_required": false
},
{
"name": "is_not_my_output",
"type": "bool",
"description": "show outputs not controlled by you",
"is_required": false
},
{
"name": "is_my_input",
"type": "bool",
"description": "show outputs created by you",
"is_required": false
},
{
"name": "is_not_my_input",
"type": "bool",
"description": "show outputs not created by you",
"is_required": false
},
{
"name": "exclude_internal_transfers",
"type": "bool",
"description": "excludes any outputs that are exactly this combination: \"--is_my_input --is_my_output --type=other\" this allows to exclude \"change\" payments, this flag can be used in combination with any of the other flags",
"is_required": false
},
{
"name": "account_id",
"type": "str",
"description": "id of the account to query",
"is_required": false
},
{
"name": "wallet_id",
"type": "str",
"description": "restrict results to specific wallet",
"is_required": false
}
],
"returns": "int",
"examples": []
}
]
},
"utxo": {
"doc": "Unspent transaction management.",
"commands": [
{
"name": "utxo_list",
"description": "List unspent transaction outputs",
"arguments": [
{
"name": "account_id",
"type": "str",
"description": "id of the account to query",
"is_required": false
},
{
"name": "wallet_id",
"type": "str",
"description": "restrict results to specific wallet",
"is_required": false
},
{
"name": "page",
"type": "int",
"description": "page to return during paginating",
"is_required": false
},
{
"name": "page_size",
"type": "int",
"description": "number of items on page during pagination",
"is_required": false
}
],
"returns": " {\n \"page\": \"Page number of the current items.\",\n \"page_size\": \"Number of items to show on a page.\",\n \"total_pages\": \"Total number of pages.\",\n \"total_items\": \"Total number of items.\",\n \"items\": [\n {\n \"txid\": \"hash of transaction in hex\",\n \"nout\": \"position in the transaction\",\n \"height\": \"block where transaction was recorded\",\n \"amount\": \"value of the txo as a decimal\",\n \"address\": \"address of who can spend the txo\",\n \"confirmations\": \"number of confirmed blocks\",\n \"is_change\": \"payment to change address, only available when it can be determined\",\n \"is_received\": \"true if txo was sent from external account to this account\",\n \"is_spent\": \"true if txo is spent\",\n \"is_mine\": \"payment to one of your accounts, only available when it can be determined\",\n \"type\": \"one of 'claim', 'support' or 'purchase'\",\n \"name\": \"when type is 'claim' or 'support', this is the claim name\",\n \"claim_id\": \"when type is 'claim', 'support' or 'purchase', this is the claim id\",\n \"claim_op\": \"when type is 'claim', this determines if it is 'create' or 'update'\",\n \"value\": \"when type is 'claim' or 'support' with payload, this is the decoded protobuf payload\",\n \"value_type\": \"determines the type of the 'value' field: 'channel', 'stream', etc\",\n \"protobuf\": \"hex encoded raw protobuf version of 'value' field\",\n \"permanent_url\": \"when type is 'claim' or 'support', this is the long permanent claim URL\",\n \"claim\": \"for purchase outputs only, metadata of purchased claim\",\n \"reposted_claim\": \"for repost claims only, metadata of claim being reposted\",\n \"signing_channel\": \"for signed claims only, metadata of signing channel\",\n \"is_channel_signature_valid\": \"for signed claims only, whether signature is valid\",\n \"purchase_receipt\": \"metadata for the purchase transaction associated with this claim\"\n }\n ]\n }",
"examples": []
},
{
"name": "utxo_release",
"description": "When spending a UTXO it is locally locked to prevent double spends;\noccasionally this can result in a UTXO being locked which ultimately\ndid not get spent (failed to broadcast, spend transaction was not\naccepted by blockchain node, etc). This command releases the lock\non all UTXOs in your account.",
"arguments": [
{
"name": "account_id",
"type": "str",
"description": "id of the account to query",
"is_required": false
},
{
"name": "wallet_id",
"type": "str",
"description": "restrict operation to specific wallet",
"is_required": false
}
],
"returns": "None",
"examples": []
}
]
},
"wallet": {
"doc": "Create, modify and inspect wallets.",
"commands": [
{
"name": "wallet_add",
"description": "Add existing wallet.",
"arguments": [
{
"name": "wallet_id",
"type": "str",
"description": "wallet file name",
"is_required": true
}
],
"returns": " {\n \"id\": \"wallet_id\",\n \"name\": \"optional wallet name\"\n }",
"examples": []
},
{
"name": "wallet_balance",
"description": "Return the balance of a wallet",
"arguments": [
{
"name": "wallet_id",
"type": "str",
"description": "balance for specific wallet",
"is_required": false
},
{
"name": "confirmations",
"type": "int",
"description": "Only include transactions with this many confirmed blocks.",
"is_required": false
}
],
"returns": "(decimal) amount of lbry credits in wallet",
"examples": []
},
{
"name": "wallet_create",
"description": "Create a new wallet.",
"arguments": [
{
"name": "wallet_id",
"type": "str",
"description": "wallet file name",
"is_required": true
},
{
"name": "skip_on_startup",
"type": "bool",
"description": "don't add wallet to daemon_settings.yml",
"is_required": false
},
{
"name": "create_account",
"type": "bool",
"description": "generates the default account",
"is_required": false
},
{
"name": "single_key",
"type": "bool",
"description": "used with --create_account, creates single-key account",
"is_required": false
}
],
"returns": " {\n \"id\": \"wallet_id\",\n \"name\": \"optional wallet name\"\n }",
"examples": []
},
{
"name": "wallet_decrypt",
"description": "Decrypt an encrypted wallet, this will remove the wallet password. The wallet must be unlocked to decrypt it",
"arguments": [
{
"name": "wallet_id",
"type": "str",
"description": "restrict operation to specific wallet",
"is_required": false
}
],
"returns": "(bool) true if wallet is decrypted, otherwise false",
"examples": []
},
{
"name": "wallet_encrypt",
"description": "Encrypt an unencrypted wallet with a password",
"arguments": [
{
"name": "new_password",
"type": "str",
"description": "password to encrypt account",
"is_required": true
},
{
"name": "wallet_id",
"type": "str",
"description": "restrict operation to specific wallet",
"is_required": false
}
],
"returns": "(bool) true if wallet is decrypted, otherwise false",
"examples": []
},
{
"name": "wallet_list",
"description": "List wallets.",
"arguments": [
{
"name": "wallet_id",
"type": "str",
"description": "show specific wallet only",
"is_required": false
},
{
"name": "page",
"type": "int",
"description": "page to return during paginating",
"is_required": false
},
{
"name": "page_size",
"type": "int",
"description": "number of items on page during pagination",
"is_required": false
}
],
"returns": " {\n \"page\": \"Page number of the current items.\",\n \"page_size\": \"Number of items to show on a page.\",\n \"total_pages\": \"Total number of pages.\",\n \"total_items\": \"Total number of items.\",\n \"items\": [\n {\n \"id\": \"wallet_id\",\n \"name\": \"optional wallet name\"\n }\n ]\n }",
"examples": [
{
"title": "List your wallets",
"curl": "curl -d'{\"method\": \"wallet_list\", \"params\": {}}' http://localhost:5279/",
"lbrynet": "lbrynet wallet list",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"wallet_list\", \"params\": {}}).json()",
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"items\": [\n {\n \"id\": \"my_wallet.json\",\n \"name\": \"Wallet\"\n }\n ],\n \"page\": 1,\n \"page_size\": 20,\n \"total_items\": 1,\n \"total_pages\": 1\n }\n}"
}
]
},
{
"name": "wallet_lock",
"description": "Lock an unlocked wallet",
"arguments": [
{
"name": "wallet_id",
"type": "str",
"description": "restrict operation to specific wallet",
"is_required": false
}
],
"returns": "(bool) true if wallet is locked, otherwise false",
"examples": []
},
{
"name": "wallet_reconnect",
"description": "Reconnects ledger network client, applying new configurations.",
"arguments": [],
"returns": "None",
"examples": []
},
{
"name": "wallet_remove",
"description": "Remove an existing wallet.",
"arguments": [
{
"name": "wallet_id",
"type": "str",
"description": "name of wallet to remove",
"is_required": true
}
],
"returns": " {\n \"id\": \"wallet_id\",\n \"name\": \"optional wallet name\"\n }",
"examples": []
},
{
"name": "wallet_send",
"description": "Send the same number of credits to multiple addresses using all accounts in wallet to\nfund the transaction and the default account to receive any change.",
"arguments": [
{
"name": "wallet_id",
"type": "str",
"description": "restrict operation to specific wallet",
"is_required": false
},
{
"name": "change_account_id",
"type": "str",
"description": "account where change will go",
"is_required": false
},
{
"name": "funding_account_ids",
"type": "str",
"description": "accounts to fund the transaction",
"is_required": false
},
{
"name": "preview",
"type": "bool",
"description": "do not broadcast the transaction",
"is_required": false
},
{
"name": "blocking",
"type": "bool",
"description": "wait until tx has synced",
"is_required": false
}
],
"returns": " {\n \"txid\": \"hash of transaction in hex\",\n \"height\": \"block where transaction was recorded\",\n \"inputs\": [\n {\n \"txid\": \"hash of transaction in hex\",\n \"nout\": \"position in the transaction\",\n \"height\": \"block where transaction was recorded\",\n \"amount\": \"value of the txo as a decimal\",\n \"address\": \"address of who can spend the txo\",\n \"confirmations\": \"number of confirmed blocks\",\n \"is_change\": \"payment to change address, only available when it can be determined\",\n \"is_received\": \"true if txo was sent from external account to this account\",\n \"is_spent\": \"true if txo is spent\",\n \"is_mine\": \"payment to one of your accounts, only available when it can be determined\",\n \"type\": \"one of 'claim', 'support' or 'purchase'\",\n \"name\": \"when type is 'claim' or 'support', this is the claim name\",\n \"claim_id\": \"when type is 'claim', 'support' or 'purchase', this is the claim id\",\n \"claim_op\": \"when type is 'claim', this determines if it is 'create' or 'update'\",\n \"value\": \"when type is 'claim' or 'support' with payload, this is the decoded protobuf payload\",\n \"value_type\": \"determines the type of the 'value' field: 'channel', 'stream', etc\",\n \"protobuf\": \"hex encoded raw protobuf version of 'value' field\",\n \"permanent_url\": \"when type is 'claim' or 'support', this is the long permanent claim URL\",\n \"claim\": \"for purchase outputs only, metadata of purchased claim\",\n \"reposted_claim\": \"for repost claims only, metadata of claim being reposted\",\n \"signing_channel\": \"for signed claims only, metadata of signing channel\",\n \"is_channel_signature_valid\": \"for signed claims only, whether signature is valid\",\n \"purchase_receipt\": \"metadata for the purchase transaction associated with this claim\"\n }\n ],\n \"outputs\": [\n {\n \"txid\": \"hash of transaction in hex\",\n \"nout\": \"position in the transaction\",\n \"height\": \"block where transaction was recorded\",\n \"amount\": \"value of the txo as a decimal\",\n \"address\": \"address of who can spend the txo\",\n \"confirmations\": \"number of confirmed blocks\",\n \"is_change\": \"payment to change address, only available when it can be determined\",\n \"is_received\": \"true if txo was sent from external account to this account\",\n \"is_spent\": \"true if txo is spent\",\n \"is_mine\": \"payment to one of your accounts, only available when it can be determined\",\n \"type\": \"one of 'claim', 'support' or 'purchase'\",\n \"name\": \"when type is 'claim' or 'support', this is the claim name\",\n \"claim_id\": \"when type is 'claim', 'support' or 'purchase', this is the claim id\",\n \"claim_op\": \"when type is 'claim', this determines if it is 'create' or 'update'\",\n \"value\": \"when type is 'claim' or 'support' with payload, this is the decoded protobuf payload\",\n \"value_type\": \"determines the type of the 'value' field: 'channel', 'stream', etc\",\n \"protobuf\": \"hex encoded raw protobuf version of 'value' field\",\n \"permanent_url\": \"when type is 'claim' or 'support', this is the long permanent claim URL\",\n \"claim\": \"for purchase outputs only, metadata of purchased claim\",\n \"reposted_claim\": \"for repost claims only, metadata of claim being reposted\",\n \"signing_channel\": \"for signed claims only, metadata of signing channel\",\n \"is_channel_signature_valid\": \"for signed claims only, whether signature is valid\",\n \"purchase_receipt\": \"metadata for the purchase transaction associated with this claim\"\n }\n ],\n \"total_input\": \"sum of inputs as a decimal\",\n \"total_output\": \"sum of outputs, sans fee, as a decimal\",\n \"total_fee\": \"fee amount\",\n \"hex\": \"entire transaction encoded in hex\"\n }",
"examples": []
},
{
"name": "wallet_status",
"description": "Status of wallet including encryption/lock state.",
"arguments": [
{
"name": "wallet_id",
"type": "str",
"description": "status of specific wallet",
"is_required": false
}
],
"returns": "Dictionary of wallet status information.",
"examples": []
},
{
"name": "wallet_unlock",
"description": "Unlock an encrypted wallet",
"arguments": [
{
"name": "password",
"type": "str",
"description": "password to use for unlocking",
"is_required": true
},
{
"name": "wallet_id",
"type": "str",
"description": "restrict operation to specific wallet",
"is_required": false
}
],
"returns": "(bool) true if wallet is unlocked, otherwise false",
"examples": []
}
]
}
}