lbry-sdk/docs/api.json

5347 lines
528 KiB
JSON
Raw Normal View History

2019-04-11 21:35:24 +02:00
{
"main": {
"doc": "Ungrouped commands.",
"commands": [
2020-03-22 01:15:21 +01:00
{
"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": []
},
2019-04-11 21:35:24 +02:00
{
"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",
2019-04-25 05:03:30 +02:00
"description": "specified name for the downloaded file, overrides the stream file name",
2019-04-11 21:35:24 +02:00
"is_required": false
},
2019-05-09 16:32:07 +02:00
{
"name": "download_directory",
"type": "str",
"description": "full path to the directory to download into",
"is_required": false
},
2019-04-11 21:35:24 +02:00
{
"name": "timeout",
"type": "int",
"description": "download timeout in number of seconds",
"is_required": false
2019-04-25 05:03:30 +02:00
},
{
"name": "save_file",
"type": "bool",
"description": "save the file to the downloads directory",
"is_required": false
2019-11-20 16:39:17 +01:00
},
{
"name": "wallet_id",
"type": "str",
2021-02-17 00:07:43 +01:00
"description": "wallet to check for claim purchase receipts",
2019-11-20 16:39:17 +01:00
"is_required": false
2019-04-11 21:35:24 +02:00
}
],
2020-08-19 21:46:29 +02:00
"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 }",
2019-04-12 14:58:00 +02:00
"examples": [
{
"title": "Get a file",
2021-03-04 06:02:42 +01:00
"curl": "curl -d'{\"method\": \"get\", \"params\": {\"uri\": \"astream#8e1d6b1b4aabe90269528e6cd09ec6e67086aa27\"}}' http://localhost:5279/",
"lbrynet": "lbrynet get astream#8e1d6b1b4aabe90269528e6cd09ec6e67086aa27",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"get\", \"params\": {\"uri\": \"astream#8e1d6b1b4aabe90269528e6cd09ec6e67086aa27\"}}).json()",
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"added_on\": 1614834139,\n \"blobs_completed\": 1,\n \"blobs_in_stream\": 1,\n \"blobs_remaining\": 0,\n \"channel_claim_id\": \"b312a0c4eff10abe98542f99679ccddc20840daa\",\n \"channel_name\": \"@channel\",\n \"claim_id\": \"8e1d6b1b4aabe90269528e6cd09ec6e67086aa27\",\n \"claim_name\": \"astream\",\n \"completed\": true,\n \"confirmations\": 4,\n \"content_fee\": null,\n \"download_directory\": \"/tmp/tmperer8uup\",\n \"download_path\": \"/tmp/tmperer8uup/tmpuyu0q8tj\",\n \"file_name\": \"tmpuyu0q8tj\",\n \"height\": 214,\n \"is_fully_reflected\": false,\n \"key\": \"cd4485fae55b2147206733882971405a\",\n \"metadata\": {\n \"source\": {\n \"hash\": \"fdbd8e75a67f29f701a4e040385e2e23986303ea10239211af907fcbb83578b3e417cb71ce646efd0819dd8c088de1bd\",\n \"media_type\": \"application/octet-stream\",\n \"name\": \"tmpuyu0q8tj\",\n \"sd_hash\": \"3da9fe6b3aee199c40a6307f293f9006690cc8bbe1c30dca591e7d09f39ec7d3a3443cb526f95da4f9b94915ec511f6d\",\n \"size\": \"11\"\n },\n \"stream_type\": \"binary\"\n },\n \"mime_type\": \"application/octet-stream\",\n \"nout\": 0,\n \"outpoint\": \"040def12329d3b9002595f77a3bb87fd43f9c603595f0c7da3fa92582efde10d:0\",\n \"points_paid\": 0.0,\n \"protobuf\": \"01aa0d8420dccd9c67992f5498be0af1efc4a012b337f1ca30a5844b95623ce944a8279839e5111bc041faf55de4cd6452e2ff25ea6ad84a1e3c478596408f4342829ffaa690073dfbdf024eb5b4c12c2509ad72980a90010a8d010a30fdbd8e75a67f29f701a4e040385e2e23986303ea10239211af907fcbb83578b3e417cb71ce646efd0819dd8c088de1bd120b746d70757975307138746a180b22186170706c69636174696f6e2f6f637465742d73747265616d32303da9fe6b3aee199c40a6307f293f9006690cc8bbe1c30dca591e7d09f39ec7d3a3443cb526f95da4f9b94915ec511f6d\",\n \"purchase_receipt\": null,\n \"reflector_progress\": 0,\n \"sd_hash\": \"3da9fe6b3aee199c40a6307f293f9006690cc8bbe1c30dca591e7d09f39ec7d3a3443cb526f95da4f9b94915ec511f6d\",\n \"status\": \"finished\",\n \"stopped\": true,\n \"stream_hash\": \"ed940f9a26c786d7a10f006354ac7d0f29772269bd752ce9b6b3681647581d5bd74c89a48e48ca5277eae641b1088239\",\n \"stream_name\": \"tmpuyu0q8tj\",\n \"streaming_url\": \"http://localhost:5280/stream/3da9fe6b3aee199c40a6307f293f9006690cc8bbe1c30dca591e7d09f39ec7d3a3443cb526f95da4f9b94915ec511f6d\",\n \"suggested_file_name\": \"tmpuyu0q8tj\",\n \"timestamp\": 1614834157,\n \"total_bytes\": 16,\n \"total_bytes_lower_bound\": 0,\n \"txid\": \"040def12329d3b9002595f77a3bb87fd43f9c603595f0c7da3fa92582efde10d\",\n \"uploading_to_reflector\": false,\n \"written_bytes\": 11\n }\n}"
2019-04-12 14:58:00 +02:00
}
]
2019-04-11 21:35:24 +02:00
},
{
"name": "publish",
2019-04-27 19:13:20 +02:00
"description": "Create or replace a stream claim at a given name (use 'stream create/update' for more control).",
2019-04-11 21:35:24 +02:00
"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
},
2020-02-04 04:30:39 +01:00
{
"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
},
2019-04-11 21:35:24 +02:00
{
"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
},
{
2019-04-21 05:56:40 +02:00
"name": "width",
2019-04-11 21:35:24 +02:00
"type": "int",
2019-04-21 05:56:40 +02:00
"description": "image/video width, automatically calculated from media file",
2019-04-11 21:35:24 +02:00
"is_required": false
},
{
2019-04-21 05:56:40 +02:00
"name": "height",
2019-04-11 21:35:24 +02:00
"type": "int",
2019-04-21 05:56:40 +02:00
"description": "image/video height, automatically calculated from media file",
2019-04-11 21:35:24 +02:00
"is_required": false
},
{
2019-04-21 05:56:40 +02:00
"name": "duration",
2019-04-11 21:35:24 +02:00
"type": "int",
2019-04-21 05:56:40 +02:00
"description": "audio/video duration in seconds, automatically calculated",
2019-04-11 21:35:24 +02:00
"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",
2019-08-12 07:26:42 +02:00
"description": "account to use for holding the transaction",
"is_required": false
},
2019-09-20 15:43:58 +02:00
{
"name": "wallet_id",
"type": "str",
"description": "restrict operation to specific wallet",
"is_required": false
},
2019-08-12 07:26:42 +02:00
{
"name": "funding_account_ids",
"type": "list",
"description": "ids of accounts to fund this transaction",
2019-04-11 21:35:24 +02:00
"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
2019-06-25 21:34:32 +02:00
},
{
"name": "blocking",
"type": "bool",
"description": "wait until transaction is in mempool",
"is_required": false
2019-04-11 21:35:24 +02:00
}
],
2020-03-22 01:15:21 +01:00
"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 prot
2019-04-11 21:35:24 +02:00
"examples": [
{
2019-04-12 14:58:00 +02:00
"title": "Publish a file",
2021-03-04 06:02:42 +01:00
"curl": "curl -d'{\"method\": \"publish\", \"params\": {\"name\": \"a-new-stream\", \"bid\": \"1.0\", \"file_path\": \"/tmp/tmpp181cxyh\", \"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/tmpp181cxyh",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"publish\", \"params\": {\"name\": \"a-new-stream\", \"bid\": \"1.0\", \"file_path\": \"/tmp/tmpp181cxyh\", \"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\": \"0100000001d3c61021883790cb859b83f45a3f0b5be6c1510b65269804c10df83ff374d379010000006a47304402207538dfdc7d1553bd5c8d0b666e9fdeb623bc6724580261f0567e5cca9655584702200e8fd6bb472107eff06d91696d31e6c888c5a75bddf598e64a78d64d8aeb94d7012103b9fcada9f923391eadc91ce20b3f728e9af6c67cbbb8dd070267b7d3dc9bae8cffffffff0200e1f50500000000bfb50c612d6e65772d73747265616d4c94000a90010a8d010a30fdbd8e75a67f29f701a4e040385e2e23986303ea10239211af907fcbb83578b3e417cb71ce646efd0819dd8c088de1bd120b746d707031383163787968180b22186170706c69636174696f6e2f6f637465742d73747265616d3230074e388a3cc85d990c4efd2981091aea193bcc4c79d7fce1bb6ebe21e974367a8532b437703157cb4ebcf0478fa5f4a46d7576a91492ba98b5cc1dd6657a59adb9f11219790bd6da2888ac54826311000000001976a9148bf7ed85b10e08bd836503d41c7e599c69beee2288ac00000000\",\n \"inputs\": [\n {\n \"address\": \"mqQ9oWwESPiXhdCqnX74GKJC52Au3mLppJ\",\n \"amount\": \"3.941448\",\n \"confirmations\": 3,\n \"height\": 217,\n \"nout\": 1,\n \"timestamp\": 1614834157,\n \"txid\": \"79d374f33ff80dc1049826650b51c1e65b0b3f5af4839b85cb9037882110c6d3\",\n \"type\": \"payment\"\n }\n ],\n \"outputs\": [\n {\n \"address\": \"mttnV1prP9cR6NqH9cknfSCNcayLTZEgeo\",\n \"amount\": \"1.0\",\n \"claim_id\": \"555fa6a2699a5eebdd78bda6aa419e4274b4db97\",\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#555fa6a2699a5eebdd78bda6aa419e4274b4db97\",\n \"timestamp\": null,\n \"txid\": \"90115557747edc0bae55e73c8b612f5213637dc3099bbb5bae169989d954cce0\",\n \"type\": \"claim\",\n \"value\": {\n \"source\": {\n \"hash\": \"fdbd8e75a67f29f701a4e040385e2e23986303ea10239211af907fcbb83578b3e417cb71ce646efd0819dd8c088de1bd\",\n \"media_type\": \"application/octet-stream\",\n \"name\": \"tmpp181cxyh\",\n \"sd_hash\": \"074e388a3cc85d990c4efd2981091aea193bcc4c79d7fce1bb6ebe21e974367a8532b437703157cb4ebcf0478fa5f4a4\",\n \"size\": \"11\"\n },\n \"stream_type\": \"binary\"\n },\n \"value_type\": \"stream\"\n },\n {\n \"address\": \"mtH3E3bCZS3BYt1zrYyxgE4JMPeYiu32xc\",\n \"amount\": \"2.917341\",\n \"confirmations\": -2,\n \"height\": -2,\n \"nout\": 1,\n \"timestamp\": null,\n \"txid\": \"90115557747edc0bae55e73c8b612f5213637dc3099bbb5bae169989d954cce0\",\n \"type\": \"payment\"\n }\n ],\n \"total_fee\": \"0.024107\",\n \"total_input\": \"3.941448\",\n \"total_output\": \"3.917341\",\n \"txid\": \"90115557747edc0bae55e73c8b612f5213637dc3099bbb5bae169989d954cce0\"\n }\n}"
2019-04-11 21:35:24 +02:00
}
]
},
{
"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
2019-11-20 16:39:17 +01:00
},
{
"name": "wallet_id",
"type": "str",
2021-02-17 00:07:43 +01:00
"description": "wallet to check for claim purchase receipts",
2019-11-20 16:39:17 +01:00
"is_required": false
2020-03-31 03:45:58 +02:00
},
2020-08-19 21:46:29 +02:00
{
"name": "new_sdk_server",
"type": "str",
"description": "URL of the new SDK server (EXPERIMENTAL)",
"is_required": false
},
2020-03-31 03:45:58 +02:00
{
"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
2019-04-11 21:35:24 +02:00
}
],
2019-04-29 15:49:39 +02:00
"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 }",
2019-04-12 14:58:00 +02:00
"examples": [
{
"title": "Resolve a claim",
2021-03-04 06:02:42 +01:00
"curl": "curl -d'{\"method\": \"resolve\", \"params\": {\"urls\": [\"astream#8e1d6b1b4aabe90269528e6cd09ec6e67086aa27\"], \"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#8e1d6b1b4aabe90269528e6cd09ec6e67086aa27",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"resolve\", \"params\": {\"urls\": [\"astream#8e1d6b1b4aabe90269528e6cd09ec6e67086aa27\"], \"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#8e1d6b1b4aabe90269528e6cd09ec6e67086aa27\": {\n \"address\": \"n4fHJYFChC7a9V7M9BjLsnyzsMj4p821u2\",\n \"amount\": \"1.0\",\n \"canonical_url\": \"lbry://@channel#b/astream#8\",\n \"claim_id\": \"8e1d6b1b4aabe90269528e6cd09ec6e67086aa27\",\n \"claim_op\": \"update\",\n \"confirmations\": 4,\n \"height\": 214,\n \"is_channel_signature_valid\": true,\n \"meta\": {\n \"activation_height\": 213,\n \"creation_height\": 213,\n \"creation_timestamp\": 1614834157,\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#8e1d6b1b4aabe90269528e6cd09ec6e67086aa27\",\n \"short_url\": \"lbry://astream#8\",\n \"signing_channel\": {\n \"address\": \"mtcRw1f5eTuchnSTgvRMiBDJ97eQSeWRb3\",\n \"amount\": \"1.0\",\n \"canonical_url\": \"lbry://@channel#b\",\n \"claim_id\": \"b312a0c4eff10abe98542f99679ccddc20840daa\",\n \"claim_op\": \"update\",\n \"confirmations\": 8,\n \"has_signing_key\": false,\n \"height\": 210,\n \"meta\": {\n \"activation_height\": 209,\n \"claims_in_channel\": 2,\n \"creation_height\": 209,\n \"creation_timestamp\": 1614834156,\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#b312a0c4eff10abe98542f99679ccddc20840daa\",\n \"short_url\": \"lbry://@channel#b\",\n \"timestamp\": 1614834156,\n \"txid\": \"51756a383ab1ba913f43442a9651231fb65761698666361f3203e4a43aa15fac\",\n \"type\": \"claim\",\n \"value\": {\n \"public_key\": \"3056301006072a8648ce3d020106052b8104000a03420004822b2981f3e209733bab8625b24389d8c1dc9e18d6dab2eaff74977992dce4f0e884799d7eb928337595d7df1384f8851f5043e2d1532cd2a5f69a7e16797b5a\",\n \"public_key_id\": \"mzK5Y4GEhLT3bT6Xw4MDvEF2ve1BaNAtJt\",\n \"title\": \"New Channel\"\n },\n \"value_type\": \"channel\"\n },\n \"timestamp\": 1614834157,\n \"txid\": \"040def12329d3b9002595f77a3bb87fd43f9c603595f0c7da3fa92582efde10d\",\n \"type\": \"claim\",\n \"value\": {\n \"source\": {\n \"hash\": \"fdbd8e75a67f29f701a4e040385e2e23986303ea10239211af907fcbb83578b3e417cb71ce646efd0819dd8c088de1bd\",\n \"media_type\": \"application/octet-stream\",\n \"name\": \"tmpuyu0q8tj\",\n \"sd_hash\": \"3da9fe6b3aee199c40a6307f293f9006690cc8bbe1c30dca591e7d09f39ec7d3a3443cb526f95da4f9b94915ec511f6d\",\n \"size\": \"11\"\n },\n \"stream_type\": \"binary\"\n },\n \"value_type\": \"stream\"\n }\n }\n}"
2019-04-12 14:58:00 +02:00
}
]
2019-04-11 21:35:24 +02:00
},
{
"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": []
},
{
2019-04-11 21:35:24 +02:00
"name": "status",
"description": "Get daemon status",
"arguments": [],
2020-08-19 21:46:29 +02:00
"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 }",
2019-04-12 14:58:00 +02:00
"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()",
2021-03-04 06:02:42 +01:00
"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\": \"2aTFQbeCGfsYLp6UZ8iMaPpg2LXZ4Kz9CtSj5NvXzTAUQiAKzvYTbCej1UJ3bo3Up4\",\n \"is_running\": true,\n \"skipped_components\": [\n \"dht\",\n \"upnp\",\n \"hash_announcer\",\n \"peer_protocol_server\",\n \"libtorrent_component\"\n ],\n \"startup_status\": {\n \"blob_manager\": true,\n \"database\": true,\n \"exchange_rate_manager\": true,\n \"file_manager\": true,\n \"wallet\": true,\n \"wallet_server_payments\": true\n },\n \"wallet\": {\n \"available_servers\": 1,\n \"best_blockhash\": \"ebf3b243548e51e906821b439c20ca0389ce76e76d2778ece293f0bd5262ae52\",\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.90.1\",\n \"trending_algorithm\": \"zscore\"\n },\n \"headers_synchronization_progress\": 100,\n \"known_servers\": 1,\n \"servers\": [\n {\n \"availability\": true,\n \"host\": \"127.0.0.1\",\n \"latency\": 0.011066530016250908,\n \"port\": 50002\n }\n ]\n },\n \"wallet_server_payments\": {\n \"max_fee\": \"0.0\",\n \"running\": false\n }\n }\n}"
2019-04-12 14:58:00 +02:00
}
]
},
{
2019-04-11 21:35:24 +02:00
"name": "stop",
"description": "Stop lbrynet API server.",
"arguments": [],
"returns": "(string) Shutdown message",
"examples": []
},
{
2019-04-11 21:35:24 +02:00
"name": "version",
"description": "Get lbrynet API server version information",
"arguments": [],
2020-01-19 03:23:38 +01:00
"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 }",
2019-04-12 14:58:00 +02:00
"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()",
2021-03-04 06:02:42 +01:00
"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.90.1\",\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.9\",\n \"version\": \"0.90.1\"\n }\n}"
2019-04-12 14:58:00 +02:00
}
]
2019-04-06 21:33:19 +02:00
}
]
},
2019-04-11 21:35:24 +02:00
"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
2019-09-20 15:43:58 +02:00
},
{
"name": "wallet_id",
"type": "str",
"description": "restrict operation to specific wallet",
"is_required": false
2019-04-11 21:35:24 +02:00
}
],
"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": [
{
2019-04-12 14:58:00 +02:00
"title": "Add an account from seed",
2021-03-04 06:02:42 +01:00
"curl": "curl -d'{\"method\": \"account_add\", \"params\": {\"account_name\": \"new account\", \"seed\": \"summer correct gift diesel onion split asset expect frozen drip process solid\", \"single_key\": false}}' http://localhost:5279/",
"lbrynet": "lbrynet account add \"new account\" --seed=\"summer correct gift diesel onion split asset expect frozen drip process solid\"",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"account_add\", \"params\": {\"account_name\": \"new account\", \"seed\": \"summer correct gift diesel onion split asset expect frozen drip process solid\", \"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\": \"n47cvxWxXeFRHte7tfsjeqJyoTNtofuMuL\",\n \"is_default\": false,\n \"ledger\": \"lbc_regtest\",\n \"modified_on\": 1614834128,\n \"name\": \"new account\",\n \"private_key\": \"tprv8ZgxMBicQKsPedmGmKh6rP9DD9MJtJU1zBJMFmwxc4AJhGTMEYAademgSSuvkotAvfTd1t83sh99hjxr64ngQpYKNjVmrMKUDVFb8CcCFPb\",\n \"public_key\": \"tpubD6NzVbkrYhZ4Y6o4eyMhFnoKnAsF3devZUu8YHzG2KxhXki7rvzAp9PYcZWVjEXTCBwzqHydbVt15j9e2knARs5wJ3yMaA5LXUoZNLYXYR8\",\n \"seed\": \"summer correct gift diesel onion split asset expect frozen drip process solid\"\n }\n}"
2019-04-11 21:35:24 +02:00
}
]
},
{
"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
},
2019-09-20 15:43:58 +02:00
{
"name": "wallet_id",
"type": "str",
"description": "balance for specific wallet",
"is_required": false
},
2019-04-11 21:35:24 +02:00
{
"name": "confirmations",
"type": "int",
"description": "Only include transactions with this many confirmed blocks.",
"is_required": false
}
],
"returns": "(decimal) amount of lbry credits in wallet",
2019-04-12 14:58:00 +02:00
"examples": [
{
"title": "Get default account balance",
2019-11-20 16:39:17 +01:00
"curl": "curl -d'{\"method\": \"account_balance\", \"params\": {}}' http://localhost:5279/",
2019-04-12 14:58:00 +02:00
"lbrynet": "lbrynet account balance",
2019-11-20 16:39:17 +01:00
"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}"
2019-04-12 14:58:00 +02:00
},
{
"title": "Get balance for specific account by id",
2021-03-04 06:02:42 +01:00
"curl": "curl -d'{\"method\": \"account_balance\", \"params\": {\"account_id\": \"n47cvxWxXeFRHte7tfsjeqJyoTNtofuMuL\"}}' http://localhost:5279/",
"lbrynet": "lbrynet account balance \"n47cvxWxXeFRHte7tfsjeqJyoTNtofuMuL\"",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"account_balance\", \"params\": {\"account_id\": \"n47cvxWxXeFRHte7tfsjeqJyoTNtofuMuL\"}}).json()",
2019-11-20 16:39:17 +01:00
"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}"
2019-04-12 14:58:00 +02:00
}
]
2019-04-11 21:35:24 +02:00
},
{
"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
2019-09-20 15:43:58 +02:00
},
{
"name": "wallet_id",
"type": "str",
"description": "restrict operation to specific wallet",
"is_required": false
2019-04-11 21:35:24 +02:00
}
],
"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": [
{
2019-04-12 14:58:00 +02:00
"title": "Create an account",
2019-04-11 21:35:24 +02:00
"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()",
2021-03-04 06:02:42 +01:00
"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\": \"n47cvxWxXeFRHte7tfsjeqJyoTNtofuMuL\",\n \"is_default\": false,\n \"ledger\": \"lbc_regtest\",\n \"modified_on\": 1614834128,\n \"name\": \"generated account\",\n \"private_key\": \"tprv8ZgxMBicQKsPedmGmKh6rP9DD9MJtJU1zBJMFmwxc4AJhGTMEYAademgSSuvkotAvfTd1t83sh99hjxr64ngQpYKNjVmrMKUDVFb8CcCFPb\",\n \"public_key\": \"tpubD6NzVbkrYhZ4Y6o4eyMhFnoKnAsF3devZUu8YHzG2KxhXki7rvzAp9PYcZWVjEXTCBwzqHydbVt15j9e2knARs5wJ3yMaA5LXUoZNLYXYR8\",\n \"seed\": \"summer correct gift diesel onion split asset expect frozen drip process solid\"\n }\n}"
2019-04-11 21:35:24 +02:00
}
]
},
{
"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
},
2019-09-20 15:43:58 +02:00
{
"name": "wallet_id",
"type": "str",
"description": "limit operation to specific wallet.",
"is_required": false
},
2019-04-11 21:35:24 +02:00
{
"name": "broadcast",
"type": "bool",
"description": "actually broadcast the transaction, default: false.",
"is_required": false
}
],
2020-03-22 01:15:21 +01:00
"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 prot
2019-04-12 14:58:00 +02:00
"examples": [
{
"title": "Transfer 2 LBC from default account to specific account",
2021-03-04 06:02:42 +01:00
"curl": "curl -d'{\"method\": \"account_fund\", \"params\": {\"to_account\": \"n47cvxWxXeFRHte7tfsjeqJyoTNtofuMuL\", \"amount\": \"2.0\", \"everything\": false, \"broadcast\": true}}' http://localhost:5279/",
"lbrynet": "lbrynet account fund --to_account=\"n47cvxWxXeFRHte7tfsjeqJyoTNtofuMuL\" --amount=2.0 --broadcast",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"account_fund\", \"params\": {\"to_account\": \"n47cvxWxXeFRHte7tfsjeqJyoTNtofuMuL\", \"amount\": \"2.0\", \"everything\": false, \"broadcast\": true}}).json()",
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"height\": -2,\n \"hex\": \"01000000014a33693119a1c72123a870ac6d144daffcfd74f9f4bd09326711851c96dc618b000000006a4730440220438ed3d4599b4e7e7a92eb84cad58cd42f76c894f90e194dc84a02224e39e1f502202ae99eab4bae234a40a138c9126dd4c35a0704e4768e723a51b64681c921e9c101210364f31b2915935fabfed02054c219d527afdad8ac5599421993ef4a00dc0867b9ffffffff0200c2eb0b000000001976a91455cba7026d1281c324842bfa14eae6c4e74ea76288ac90d7ae2f000000001976a914edde0e46ac202e67ffd89b724429a71629888b3a88ac00000000\",\n \"inputs\": [\n {\n \"address\": \"mhMnQn3qu9GMZ6B7ZezhNP7mPEC1JYzQ2L\",\n \"amount\": \"10.0\",\n \"confirmations\": 6,\n \"height\": 201,\n \"nout\": 0,\n \"timestamp\": 1614834155,\n \"txid\": \"8b61dc961c8511673209bdf4f974fdfcaf4d146dac70a82321c7a1193169334a\",\n \"type\": \"payment\"\n }\n ],\n \"outputs\": [\n {\n \"address\": \"moLbhNi41ra7J3b5e7dmBSoxqNgjvp9XJb\",\n \"amount\": \"2.0\",\n \"confirmations\": -2,\n \"height\": -2,\n \"nout\": 0,\n \"timestamp\": null,\n \"txid\": \"fa97d309280b2e779d0a4f7a0b3c5fa5586b8697d601e336e865517608e328a2\",\n \"type\": \"payment\"\n },\n {\n \"address\": \"n3CgTDtBMq1jigfQ3Y8NpYesjZyA4Qp3wm\",\n \"amount\": \"7.999876\",\n \"confirmations\": -2,\n \"height\": -2,\n \"nout\": 1,\n \"timestamp\": null,\n \"txid\": \"fa97d309280b2e779d0a4f7a0b3c5fa5586b8697d601e336e865517608e328a2\",\n \"type\": \"payment\"\n }\n ],\n \"total_fee\": \"0.000124\",\n \"total_input\": \"10.0\",\n \"total_output\": \"9.999876\",\n \"txid\": \"fa97d309280b2e779d0a4f7a0b3c5fa5586b8697d601e336e865517608e328a2\"\n }\n}"
2019-04-12 14:58:00 +02:00
},
{
"title": "Spread LBC between multiple addresses",
2021-03-04 06:02:42 +01:00
"curl": "curl -d'{\"method\": \"account_fund\", \"params\": {\"to_account\": \"n47cvxWxXeFRHte7tfsjeqJyoTNtofuMuL\", \"from_account\": \"n47cvxWxXeFRHte7tfsjeqJyoTNtofuMuL\", \"amount\": \"1.5\", \"everything\": false, \"outputs\": 2, \"broadcast\": true}}' http://localhost:5279/",
"lbrynet": "lbrynet account fund --to_account=\"n47cvxWxXeFRHte7tfsjeqJyoTNtofuMuL\" --from_account=\"n47cvxWxXeFRHte7tfsjeqJyoTNtofuMuL\" --amount=1.5 --outputs=2 --broadcast",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"account_fund\", \"params\": {\"to_account\": \"n47cvxWxXeFRHte7tfsjeqJyoTNtofuMuL\", \"from_account\": \"n47cvxWxXeFRHte7tfsjeqJyoTNtofuMuL\", \"amount\": \"1.5\", \"everything\": false, \"outputs\": 2, \"broadcast\": true}}).json()",
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"height\": -2,\n \"hex\": \"0100000001a228e308765165e836e301d697866b58a55f3c0b7a4f0a9d772e0b2809d397fa000000006b483045022100c3bb7374d37c62079bffa50679b79fa49322331be5464f48657ddcc73fd719c2022074e5723a0d3fc5326f87a9324d903d6609eb75bd62b7281f1cc33cde0fff180f012102ad2ab35a6ff6c7152cdf996b06d669dfa58c0f75cf59d2c2ca1764e1aedbf816ffffffff03c0687804000000001976a914909dd2aed4405ed6dc377a9c1afebd98cd46f82088acc0687804000000001976a914909dd2aed4405ed6dc377a9c1afebd98cd46f82088ac6cb9fa02000000001976a9141d9f53f394b630e9faadf0b21d6c5b7fc1481f5f88ac00000000\",\n \"inputs\": [\n {\n \"address\": \"moLbhNi41ra7J3b5e7dmBSoxqNgjvp9XJb\",\n \"amount\": \"2.0\",\n \"confirmations\": 1,\n \"height\": 207,\n \"nout\": 0,\n \"timestamp\": 1614834156,\n \"txid\": \"fa97d309280b2e779d0a4f7a0b3c5fa5586b8697d601e336e865517608e328a2\",\n \"type\": \"payment\"\n }\n ],\n \"outputs\": [\n {\n \"address\": \"mthcfQmCReFgixYFzt5f8bQc4rbrJ1uKUP\",\n \"amount\": \"0.75\",\n \"confirmations\": -2,\n \"height\": -2,\n \"nout\": 0,\n \"timestamp\": null,\n \"txid\": \"822687d83a8cb6e5e0c9610b4692fb11d8c46dad8396e4af52fda369be510d07\",\n \"type\": \"payment\"\n },\n {\n \"address\": \"mthcfQmCReFgixYFzt5f8bQc4rbrJ1uKUP\",\n \"amount\": \"0.75\",\n \"confirmations\": -2,\n \"height\": -2,\n \"nout\": 1,\n \"timestamp\": null,\n \"txid\": \"822687d83a8cb6e5e0c9610b4692fb11d8c46dad8396e4af52fda369be510d07\",\n \"type\": \"payment\"\n },\n {\n \"address\": \"miDakv6911nvbxLnKykA5HcqRyY1SGHZvg\",\n \"amount\": \"0.499859\",\n \"confirmations\": -2,\n \"height\": -2,\n \"nout\": 2,\n \"timestamp\": null,\n \"txid\": \"822687d83a8cb6e5e0c9610b4692fb11d8c46dad8396e4af52fda369be510d07\",\n \"type\": \"payment\"\n }\n ],\n \"total_fee\": \"0.000141\",\n \"total_input\": \"2.0\",\n \"total_output\": \"1.999859\",\n \"txid\": \"822687d83a8cb6e5e0c9610b4692fb11d8c46dad8396e4af52fda369be510d07\"\n }\n}"
2019-04-12 14:58:00 +02:00
},
{
"title": "Transfer all LBC to a specified account",
2021-03-04 06:02:42 +01:00
"curl": "curl -d'{\"method\": \"account_fund\", \"params\": {\"from_account\": \"n47cvxWxXeFRHte7tfsjeqJyoTNtofuMuL\", \"everything\": true, \"broadcast\": true}}' http://localhost:5279/",
"lbrynet": "lbrynet account fund --from_account=\"n47cvxWxXeFRHte7tfsjeqJyoTNtofuMuL\" --everything --broadcast",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"account_fund\", \"params\": {\"from_account\": \"n47cvxWxXeFRHte7tfsjeqJyoTNtofuMuL\", \"everything\": true, \"broadcast\": true}}).json()",
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"height\": -2,\n \"hex\": \"0100000003070d51be69a3fd52afe49683ad6dc4d811fb92460b61c9e0e5b68c3ad8872682000000006b483045022100c1052202abee3a4f0b5a184bb47ab3f6a91a0e942c16765d215eac495f0770e702206d19209d0036958000bde6101fa7a7c87c589faab201db15aa3c31f2787fdd990121025db03aaf1e0489320e56bcb77c89f3bf84d5a859c7260fcca1698680fefd95afffffffff070d51be69a3fd52afe49683ad6dc4d811fb92460b61c9e0e5b68c3ad8872682010000006b483045022100b09a819af23d1525b4823050cea32260bebd9eb3b0cc4c0945814d4d79e0f654022041c381e571ba25a696434aa5f0df48108bdf6434ac796a9f446dd6e5177e4f360121025db03aaf1e0489320e56bcb77c89f3bf84d5a859c7260fcca1698680fefd95afffffffff070d51be69a3fd52afe49683ad6dc4d811fb92460b61c9e0e5b68c3ad8872682020000006b483045022100aa8f6ea8524a541b97fc6ee3dcdecd08c2a64d0219afa74e6ce455fc25219f5c022044f8178a28921c5722191ed3f20937ae6e426dedeaaa59079380b2dfa6c65bed0121028d89f7d9d868a973242786c2654268a20bb3bdab098b48877466db59826ca7a3ffffffff015027eb0b000000001976a914a3daa8bbce4bc9102c73b83c0f8328222cce6e8e88ac00000000\",\n \"inputs\": [\n {\n \"address\": \"mthcfQmCReFgixYFzt5f8bQc4rbrJ1uKUP\",\n \"amount\": \"0.75\",\n \"confirmations\": 1,\n \"height\": 208,\n \"nout\": 0,\n \"timestamp\": 1614834156,\n \"txid\": \"822687d83a8cb6e5e0c9610b4692fb11d8c46dad8396e4af52fda369be510d07\",\n \"type\": \"payment\"\n },\n {\n \"address\": \"mthcfQmCReFgixYFzt5f8bQc4rbrJ1uKUP\",\n \"amount\": \"0.75\",\n \"confirmations\": 1,\n \"height\": 208,\n \"nout\": 1,\n \"timestamp\": 1614834156,\n \"txid\": \"822687d83a8cb6e5e0c9610b4692fb11d8c46dad8396e4af52fda369be510d07\",\n \"type\": \"payment\"\n },\n {\n \"address\": \"miDakv6911nvbxLnKykA5HcqRyY1SGHZvg\",\n \"amount\": \"0.499859\",\n \"confirmations\": 1,\n \"height\": 208,\n \"nout\": 2,\n \"timestamp\": 1614834156,\n \"txid\": \"822687d83a8cb6e5e0c9610b4692fb11d8c46dad8396e4af52fda369be510d07\",\n \"type\": \"payment\"\n }\n ],\n \"outputs\": [\n {\n \"address\": \"mvTLP2MGeAmwS7y9ir6Sowoa6hhBymUkpv\",\n \"amount\": \"1.999604\",\n \"confirmations\": -2,\n \"height\": -2,\n \"nout\": 0,\n \"timestamp\": null,\n \"txid\": \"f1b5ee954812d3e88d5d08f535280814ea7cb4913e9801e60f2098c8b0a7c4ec\",\n \"type\": \"payment\"\n }\n ],\n \"total_fee\": \"0.000255\",\n \"total_input\": \"1.999859\",\n \"total_output\": \"1.999604\",\n \"txid\": \"f1b5ee954812d3e88d5d08f535280814ea7cb4913e9801e60f2098c8b0a7c4ec\"\n }\n}"
2019-04-12 14:58:00 +02:00
}
]
2019-04-11 21:35:24 +02:00
},
{
"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
},
2019-09-20 15:43:58 +02:00
{
"name": "wallet_id",
"type": "str",
"description": "accounts in specific wallet",
"is_required": false
},
2019-04-11 21:35:24 +02:00
{
"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
2019-10-26 05:46:24 +02:00
},
{
"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
2019-04-11 21:35:24 +02:00
}
],
2019-10-26 05:46:24 +02:00
"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 }",
2019-04-11 21:35:24 +02:00
"examples": [
{
2019-04-12 14:58:00 +02:00
"title": "List your accounts",
2019-04-11 21:35:24 +02:00
"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()",
2021-03-04 06:02:42 +01:00
"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\": \"miXR2YJXsSXjZVfT712myc7AWRu7hQbSmJ\",\n \"is_default\": true,\n \"ledger\": \"lbc_regtest\",\n \"name\": \"Account #miXR2YJXsSXjZVfT712myc7AWRu7hQbSmJ\",\n \"public_key\": \"tpubD6NzVbkrYhZ4XUodLJ3wP7453rkhnEU9euqeBULDrbsmbwrwoPFpm3CeyXqQhsccPxugpfdxZBjwAvjgBqqB99RhQWtKUJvxyMbos77qyTG\",\n \"satoshis\": 1000000000\n }\n ],\n \"page\": 1,\n \"page_size\": 20,\n \"total_items\": 1,\n \"total_pages\": 1\n }\n}"
2019-04-11 21:35:24 +02:00
}
]
},
{
"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
2019-09-20 15:43:58 +02:00
},
{
"name": "wallet_id",
"type": "str",
"description": "restrict operation to specific wallet",
"is_required": false
2019-04-11 21:35:24 +02:00
}
],
"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
2019-09-20 15:43:58 +02:00
},
{
"name": "wallet_id",
"type": "str",
"description": "restrict operation to specific wallet",
"is_required": false
2019-04-11 21:35:24 +02:00
}
],
"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": [
{
2019-04-12 14:58:00 +02:00
"title": "Remove an account",
2021-03-04 06:02:42 +01:00
"curl": "curl -d'{\"method\": \"account_remove\", \"params\": {\"account_id\": \"n47cvxWxXeFRHte7tfsjeqJyoTNtofuMuL\"}}' http://localhost:5279/",
"lbrynet": "lbrynet account remove n47cvxWxXeFRHte7tfsjeqJyoTNtofuMuL",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"account_remove\", \"params\": {\"account_id\": \"n47cvxWxXeFRHte7tfsjeqJyoTNtofuMuL\"}}).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\": \"n47cvxWxXeFRHte7tfsjeqJyoTNtofuMuL\",\n \"is_default\": false,\n \"ledger\": \"lbc_regtest\",\n \"modified_on\": 1614834128,\n \"name\": \"generated account\",\n \"private_key\": \"tprv8ZgxMBicQKsPedmGmKh6rP9DD9MJtJU1zBJMFmwxc4AJhGTMEYAademgSSuvkotAvfTd1t83sh99hjxr64ngQpYKNjVmrMKUDVFb8CcCFPb\",\n \"public_key\": \"tpubD6NzVbkrYhZ4Y6o4eyMhFnoKnAsF3devZUu8YHzG2KxhXki7rvzAp9PYcZWVjEXTCBwzqHydbVt15j9e2knARs5wJ3yMaA5LXUoZNLYXYR8\",\n \"seed\": \"summer correct gift diesel onion split asset expect frozen drip process solid\"\n }\n}"
2019-04-11 21:35:24 +02:00
}
]
},
{
"name": "account_send",
2019-10-15 18:12:35 +02:00
"description": "Send the same number of credits to multiple addresses from a specific account (or default account).",
2019-04-11 21:35:24 +02:00
"arguments": [
{
"name": "account_id",
"type": "str",
"description": "account to fund the transaction",
"is_required": false
},
2019-09-20 15:43:58 +02:00
{
"name": "wallet_id",
"type": "str",
"description": "restrict operation to specific wallet",
"is_required": false
},
2019-04-11 21:35:24 +02:00
{
"name": "preview",
"type": "bool",
"description": "do not broadcast the transaction",
"is_required": false
2020-08-19 21:46:29 +02:00
},
{
"name": "blocking",
"type": "bool",
"description": "wait until tx has synced",
"is_required": false
2019-04-11 21:35:24 +02:00
}
],
2020-03-22 01:15:21 +01:00
"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 prot
2019-04-11 21:35:24 +02:00
"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
},
2019-09-20 15:43:58 +02:00
{
"name": "wallet_id",
"type": "str",
"description": "restrict operation to specific wallet",
"is_required": false
},
2019-04-11 21:35:24 +02:00
{
"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": [
{
2019-04-12 14:58:00 +02:00
"title": "Modify maximum number of times a change address can be reused",
2021-03-04 06:02:42 +01:00
"curl": "curl -d'{\"method\": \"account_set\", \"params\": {\"account_id\": \"n47cvxWxXeFRHte7tfsjeqJyoTNtofuMuL\", \"default\": false, \"change_max_uses\": 10}}' http://localhost:5279/",
"lbrynet": "lbrynet account set n47cvxWxXeFRHte7tfsjeqJyoTNtofuMuL --change_max_uses=10",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"account_set\", \"params\": {\"account_id\": \"n47cvxWxXeFRHte7tfsjeqJyoTNtofuMuL\", \"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\": \"n47cvxWxXeFRHte7tfsjeqJyoTNtofuMuL\",\n \"is_default\": false,\n \"ledger\": \"lbc_regtest\",\n \"modified_on\": 1614834128,\n \"name\": \"new account\",\n \"private_key\": \"tprv8ZgxMBicQKsPedmGmKh6rP9DD9MJtJU1zBJMFmwxc4AJhGTMEYAademgSSuvkotAvfTd1t83sh99hjxr64ngQpYKNjVmrMKUDVFb8CcCFPb\",\n \"public_key\": \"tpubD6NzVbkrYhZ4Y6o4eyMhFnoKnAsF3devZUu8YHzG2KxhXki7rvzAp9PYcZWVjEXTCBwzqHydbVt15j9e2knARs5wJ3yMaA5LXUoZNLYXYR8\",\n \"seed\": \"summer correct gift diesel onion split asset expect frozen drip process solid\"\n }\n}"
2019-04-11 21:35:24 +02:00
}
]
2019-04-06 21:33:19 +02:00
}
]
},
2019-04-11 21:35:24 +02:00
"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
2019-09-20 15:43:58 +02:00
},
{
"name": "wallet_id",
"type": "str",
"description": "restrict operation to specific wallet",
"is_required": false
2019-04-11 21:35:24 +02:00
}
],
"returns": "(bool) true, if address is associated with current wallet",
2019-04-12 14:58:00 +02:00
"examples": [
{
"title": "Check if address is mine",
2021-03-04 06:02:42 +01:00
"curl": "curl -d'{\"method\": \"address_is_mine\", \"params\": {\"address\": \"mtcRw1f5eTuchnSTgvRMiBDJ97eQSeWRb3\"}}' http://localhost:5279/",
"lbrynet": "lbrynet address is_mine mtcRw1f5eTuchnSTgvRMiBDJ97eQSeWRb3",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"address_is_mine\", \"params\": {\"address\": \"mtcRw1f5eTuchnSTgvRMiBDJ97eQSeWRb3\"}}).json()",
2019-04-12 14:58:00 +02:00
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": true\n}"
}
]
2019-04-11 21:35:24 +02:00
},
{
"name": "address_list",
"description": "List account addresses or details of single address.",
2019-04-11 21:35:24 +02:00
"arguments": [
{
"name": "address",
"type": "str",
"description": "just show details for single address",
"is_required": false
},
2019-04-11 21:35:24 +02:00
{
"name": "account_id",
"type": "str",
"description": "id of the account to use",
"is_required": false
},
2019-09-20 15:43:58 +02:00
{
"name": "wallet_id",
"type": "str",
"description": "restrict operation to specific wallet",
"is_required": false
},
2019-04-11 21:35:24 +02:00
{
"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
}
],
2019-05-28 04:50:26 +02:00
"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 }",
2019-04-12 14:58:00 +02:00
"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()",
2021-03-04 06:02:42 +01:00
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"items\": [\n {\n \"account\": \"miXR2YJXsSXjZVfT712myc7AWRu7hQbSmJ\",\n \"address\": \"mg3aDqAVfSW3uryy9dQfEnfariyceeQmNW\",\n \"pubkey\": \"tpubDA9GDAntyJu4gc7ypzz4Rvj1b28KSU3pKRocV4pg7unYUwTRpc3KPSAwBNguNrEB59MQwyUp371LoTh4yHu8y3oVfeoq3RjL35RSLSMJ9iu\",\n \"used_times\": 0\n },\n {\n \"account\": \"miXR2YJXsSXjZVfT712myc7AWRu7hQbSmJ\",\n \"address\": \"mhMnQn3qu9GMZ6B7ZezhNP7mPEC1JYzQ2L\",\n \"pubkey\": \"tpubDA9GDAntyJu4FCqZ5AJHRZfTTdftsTALhQDbW2pCReUYEPzivonCwavzDnQnSdeqtRUo6YntTPWKME8TBL3Y6uRLBVXuzkiN3cDMnff4i7P\",\n \"used_times\": 1\n },\n {\n \"account\": \"miXR2YJXsSXjZVfT712myc7AWRu7hQbSmJ\",\n \"address\": \"miyXSyh46NjaLEKtpuFHESgrcaPWfuxL4R\",\n \"pubkey\": \"tpubDA9GDAntyJu4KXRZmhVv4hRyhKNpTVcc46QjEFwT7i3H1ZHsCFNatToFcBQtWnazktb52UDzAqmq8L15XZotbaDy3TgEqWtuhfGkn4pBQCE\",\n \"used_times\": 0\n },\n {\n \"account\": \"miXR2YJXsSXjZVfT712myc7AWRu7hQbSmJ\",\n \"address\": \"mjCkJPVYyTBGvSvkfXZFNqc1L7nXc15Day\",\n \"pubkey\": \"tpubDA9GDAntyJu4wAUyxkukn8ugM9NLrSSxDLG8CsC7jxeP8kV1t579WUTNCK4uieBMPVWG3gamyRgi3rXBekPZsGtsD8ft9rTEWScCKa7Buxf\",\n \"used_times\": 0\n },\n {\n \"account\": \"miXR2YJXsSXjZVfT712myc7AWRu7hQbSmJ\",\n \"address\": \"mjgiK4aNDfaKPWXqn2WHGU22AMYMduuAJD\",\n \"pubkey\": \"tpubDA9GDAntyJu58cYV3jR6GgP3uuaVZ4o7sUsHybCs9jHdZ7gUYLAMQ5bWDBhcW7SWYgT77qzpr2hsDWEwUYTwEtG39aACVgRTS8xkk819oJY\",\n \"used_times\": 0\n },\n {\n \"account\": \"miXR2YJXsSXjZVfT712myc7AWRu7hQbSmJ\",\n \"address\": \"mkCTWx3KRynCmrb6MfUnS8T9dJn2nRuky8\",\n \"pubkey\": \"tpubDA9GDAntyJu4Lc3dLiAQT2xXQ8EP2W6UiK2vG1XWShPYXaEUKibWR4oUR5xA5SfUk6cuPVSuwKbcEDdS8K6XPLyh1QKuNKYq6TkTSp1EPh8\",\n \"used_times\": 0\n },\n {\n \"account\": \"miXR2YJXsSXjZVfT712myc7AWRu7hQbSmJ\",\n \"address\": \"mnqoxBn14bSdzLMLH1F94GouriTenxXEnC\",\n \"pubkey\": \"tpubDA9GDAntyJu4HSrPCWehpoqdoaj2VSC5GfQ4EAiFZh8oNQeqze6TaTgFSgUhRfeBsXQCRu8FrJcJsDKurkTxovNZJmryEwXyRSAbSAZtSTu\",\n \"used_times\": 0\n },\n {\n \"account\": \"miXR2YJXsSXjZVfT712myc7AWRu7hQbSmJ\",\n \"address\": \"mpit786FdfWRJjUAExgFMDLn44M7tYa6Hs\",\n \"pubkey\": \"tpubDA9GDAntyJu4c7nfbNCFdFYJZKbJbbGTkTSmwcDhkvdXsbTrbzpyzBCHVMpcBZxc9FVYmTnk7AarTsnELWDJWaV6EqTju4dtguPrQKoMJN5\",\n \"used_times\": 0\n },\n {\n \"account\": \"miXR2YJXsSXjZVfT712myc7AWRu7hQbSmJ\",\n \"address\": \"mpivxyQqxeBJ6etmv3eX2vgW5jsrTE7q8U\",\n \"pubkey\": \"tpubDA9GDAntyJu51Xa89UwY7Lrh513tjSuAc7bnJNT6k51LEU2w2ukDDsKMi36DMyFiyde7Fuy92KzdxFhkCCgjuJ9vdfBFRKYqMhk5htYMmky\",\n \"used_times\": 0\n },\n {\n \"account\": \"miXR2YJXsSXjZVfT712myc7AWRu7hQbSmJ\",\n \"address\": \"mrzPcqorgqSkPCoXhrnjrwccjokfz7niQk\",\n \"pubkey\": \"tpubDA9GDAntyJu4nrEJRwzgCf48JfpNpFrW2f3SEYYY4ipU5ySFgyHCJb7JXN5XSk7fwvb8cMGWc921gw6gZADM3ENNPZ8k3s5ojtuWdCUT6T4\",\n \"used_times\": 0\n },\n {\n \"account\": \"miXR2YJXsSXjZVfT712myc7AWRu7hQbSmJ\",\n \"address\": \"msVjfN91aPpAwYctxGLtQ7xVXfLnyr7mwN\",\n \"pubkey\": \"tpubDA9GDAntyJu4u5ERSSJptznmXvBnGykSQFgzNDN9gJPHj6BMoN2xXvfT9Y2SZPj8A7jx91ZqasxCK3wYxbEU3HyprK6U4rD5cJa7eR897Cq\",\n \"used_times\": 0\n },\n {\n \"account\": \"miXR2YJXsSXjZVfT712myc7AWRu7hQbSmJ\",\n \"address\": \"mtEiDQqYaxPYPj5HBwxUrEoFMYK8aAQBgy\",\n \"pubkey\": \"tpubDA9GDAntyJu4PNvrcE92znSGd6FMpVqhnvvTDRL8qP5i731gioPusSF2wr51DjiWozkC8dUaVKrmFJwYc6scg5oV22v95twvDts6Pq5epvU\",\n \"used_times\": 0\n },\n {\n \"account\": \"miXR2YJXsSXjZVfT712myc7AWRu7hQbSmJ\",\n \"address\": \"mtcRw1f5eTuchnSTgvRMiBDJ97eQSeWRb3\",\n \"pubkey\": \"tpubDA9GDAntyJu4XCwH8RgEhNN9CuyisZLbWnBtyjh2yQnGT9VnmijM7ZbUxwzLYS5ZexdYCrCaUmXqbY1D3r2YM4AWEzrRVqDXNTkWP6j5ou3\",\n \"used_times\": 0\n
2019-04-12 14:58:00 +02:00
},
{
"title": "List addresses in specified account",
2021-03-04 06:02:42 +01:00
"curl": "curl -d'{\"method\": \"address_list\", \"params\": {\"account_id\": \"n47cvxWxXeFRHte7tfsjeqJyoTNtofuMuL\"}}' http://localhost:5279/",
"lbrynet": "lbrynet address list --account_id=\"n47cvxWxXeFRHte7tfsjeqJyoTNtofuMuL\"",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"address_list\", \"params\": {\"account_id\": \"n47cvxWxXeFRHte7tfsjeqJyoTNtofuMuL\"}}).json()",
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"items\": [\n {\n \"account\": \"n47cvxWxXeFRHte7tfsjeqJyoTNtofuMuL\",\n \"address\": \"mhFP2Zdc91j891DF85eTQpHnniC7QbBasB\",\n \"pubkey\": \"tpubDA9GDAntyJu4hsgTLfwp7vAsaPH7MfUAcsHdEiLWXDEKntPegTKJUTqr9fyT5BFVWKJvwAsSUpNTd9KBWJaniFo5u6UtsbcmdYNGcSDTDjU\",\n \"used_times\": 0\n },\n {\n \"account\": \"n47cvxWxXeFRHte7tfsjeqJyoTNtofuMuL\",\n \"address\": \"miQgcq56an5igGs64LsVRMWGLcYLnPudpR\",\n \"pubkey\": \"tpubDA9GDAntyJu52q6gXw2XST7kMHSwtrWLGZGogkwDicEGy1Pgz6GJ9FA5uCtJxdMqKxCfAncLDFVnPy5VfofLv18Xe2ZLDDzKk2q1Ad2pzDv\",\n \"used_times\": 0\n },\n {\n \"account\": \"n47cvxWxXeFRHte7tfsjeqJyoTNtofuMuL\",\n \"address\": \"miono4mUaX9Tcp1jDPgZyD9J91TuRXEC2J\",\n \"pubkey\": \"tpubDA9GDAntyJu4dPR37HcmPfStTvRCWpQu5ZjMhGoYRsWqzscNSDTkofvGF3fWSsT13azm2RVC1Wv1KGU61zZHc94Y2PyAY7c4T3Ho12ncyu8\",\n \"used_times\": 0\n },\n {\n \"account\": \"n47cvxWxXeFRHte7tfsjeqJyoTNtofuMuL\",\n \"address\": \"mjFnRT7i6pzBPhXp27Vp39RmzWQSb81SRK\",\n \"pubkey\": \"tpubDA9GDAntyJu4xAJm37VYh8e1nCo1NsNVNfx9TGmVjUEUeUSf1GjxSPZqgWt2ECsMTzUfRa9RzzZpGzmKoSBcdKu8iUHo5YH2DNxybMFSA3A\",\n \"used_times\": 0\n },\n {\n \"account\": \"n47cvxWxXeFRHte7tfsjeqJyoTNtofuMuL\",\n \"address\": \"mkg1cmswRJ2wUqacULmormrydmZT6bqqNe\",\n \"pubkey\": \"tpubDA9GDAntyJu4zV1ZF7UfFvfNLaqsJ9m2o9KeiMtvnyT3RSMwE5pwVn5TzKe8Tzunbu5osABzN4UqaWm5ouHhEPQ6JCHGWb9JhHryc7oJmrs\",\n \"used_times\": 0\n },\n {\n \"account\": \"n47cvxWxXeFRHte7tfsjeqJyoTNtofuMuL\",\n \"address\": \"mmoMYKFhYwewfEgFyKeHdqirT9g9tS2k4R\",\n \"pubkey\": \"tpubDA9GDAntyJu4QE8b2Fa3XvZQwhQAVQFyMUJPRscRMmEo5V4n76mra9DQXzo4XbE27sqxD8b32mXjVSDz9MMFhmqLozbPZNwbV9kgKmHArWt\",\n \"used_times\": 0\n },\n {\n \"account\": \"n47cvxWxXeFRHte7tfsjeqJyoTNtofuMuL\",\n \"address\": \"mmzu9JZrenPxoV64HsycFY4Ju3rQpNKy9r\",\n \"pubkey\": \"tpubDA9GDAntyJu4GygwpgLDe5waifv7Ai3SuSB2SJNCDvofnFrqKaaASN9FXEjDGvhjkCyvi5Xev4Mtr5fsMwPSnTb4AxQ2CRS6uMCnrPxAQYg\",\n \"used_times\": 0\n },\n {\n \"account\": \"n47cvxWxXeFRHte7tfsjeqJyoTNtofuMuL\",\n \"address\": \"moLbhNi41ra7J3b5e7dmBSoxqNgjvp9XJb\",\n \"pubkey\": \"tpubDA9GDAntyJu4JT4BYUyUERwdA4jDu7PTBtPCZJon2gTp8gMCjoUBQ8pNbXbxxPGX3xt8Wv6LRNXDfeunrVBckS5nSqost9rhzt7MRfAgXw2\",\n \"used_times\": 0\n },\n {\n \"account\": \"n47cvxWxXeFRHte7tfsjeqJyoTNtofuMuL\",\n \"address\": \"mpFepBmE6hsZKNdRpyFNRK9nfxAea6LCrn\",\n \"pubkey\": \"tpubDA9GDAntyJu4SfmdGXjafHJeBGZZYU7x7ufcm2ANfUuZGt7LpM9mZV7tJ6ujm1sM4hMU5gwbYVinAPdR3BixptuxDqNRerHQMYPf78uFJsK\",\n \"used_times\": 0\n },\n {\n \"account\": \"n47cvxWxXeFRHte7tfsjeqJyoTNtofuMuL\",\n \"address\": \"mphhicxoJqNAw5vjGW5M8wsc4WsCQ9fdhq\",\n \"pubkey\": \"tpubDA9GDAntyJu4NP8LD2z3FkRvdMtao82utfGWuDQdD7waFw2Xj2XJ9zPKXaLQ4jqqRf6TwsYGsKU8BuCLYtq4Kmg5DnHU3wSzGBGKwMZyAiZ\",\n \"used_times\": 0\n },\n {\n \"account\": \"n47cvxWxXeFRHte7tfsjeqJyoTNtofuMuL\",\n \"address\": \"mqDjsJd1bGYYyLSqCNizoYcUkKPVCwtWd1\",\n \"pubkey\": \"tpubDA9GDAntyJu4XFKuPajLBn2a1z1ibj4haRMwsgneG5LN4iPUY1LVERnvdteLUyM192JMQraQdyTyMBXcyAVfr3FnsVLFJ97niveUrzUbA4z\",\n \"used_times\": 0\n },\n {\n \"account\": \"n47cvxWxXeFRHte7tfsjeqJyoTNtofuMuL\",\n \"address\": \"mrh8Xwtjf5RHtq1T38niNeR1VWpZzKyH7b\",\n \"pubkey\": \"tpubDA9GDAntyJu4LdVb9z2CsMUJPougvg53mtiVx2Xkx8SG5Hc2nnmKRJz6mKFG1B4E1LA32TJoVtUjayD5y2JE4Yn6eZSY1B2JG8mtZxvknw1\",\n \"used_times\": 0\n },\n {\n \"account\": \"n47cvxWxXeFRHte7tfsjeqJyoTNtofuMuL\",\n \"address\": \"mrxYztgggu7bozVNFGyZN4DmRfBBNiJity\",\n \"pubkey\": \"tpubDA9GDAntyJu4rQgPAxSXJhHCsbXztszCybGmQJpwe1QjkgjAwZEp5HAAmLvEvScsF1c2GFWfiJGMbJVQzEiYdTjtCWK68sPq21QcWzZYX5Y\",\n \"used_times\": 0\n
2019-04-12 14:58:00 +02:00
}
]
2019-04-11 21:35:24 +02:00
},
{
"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
2019-09-20 15:43:58 +02:00
},
{
"name": "wallet_id",
"type": "str",
"description": "restrict operation to specific wallet",
"is_required": false
2019-04-11 21:35:24 +02:00
}
],
"returns": " \"an address in base58\"",
2019-04-12 14:58:00 +02:00
"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()",
2021-03-04 06:02:42 +01:00
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": \"mtcRw1f5eTuchnSTgvRMiBDJ97eQSeWRb3\"\n}"
2019-04-12 14:58:00 +02:00
}
]
2019-01-21 23:37:56 +01:00
}
]
},
2019-04-11 21:35:24 +02:00
"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",
2019-04-12 14:58:00 +02:00
"examples": [
{
"title": "Delete a blob",
2021-03-04 06:02:42 +01:00
"curl": "curl -d'{\"method\": \"blob_delete\", \"params\": {\"blob_hash\": \"311cd51592acc28ad9e7026da4a4969f70d403a70d5974ab94cdaacbbe50a0a48036e3431e52134857f822a49de4196d\"}}' http://localhost:5279/",
"lbrynet": "lbrynet blob delete 311cd51592acc28ad9e7026da4a4969f70d403a70d5974ab94cdaacbbe50a0a48036e3431e52134857f822a49de4196d",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"blob_delete\", \"params\": {\"blob_hash\": \"311cd51592acc28ad9e7026da4a4969f70d403a70d5974ab94cdaacbbe50a0a48036e3431e52134857f822a49de4196d\"}}).json()",
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": \"Deleted 311cd51592acc28ad9e7026da4a4969f70d403a70d5974ab94cdaacbbe50a0a48036e3431e52134857f822a49de4196d\"\n}"
2019-04-12 14:58:00 +02:00
}
]
2019-04-11 21:35:24 +02:00
},
{
"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
},
{
2019-10-26 05:46:24 +02:00
"name": "page",
2019-04-11 21:35:24 +02:00
"type": "int",
2019-10-26 05:46:24 +02:00
"description": "page to return during paginating",
2019-04-11 21:35:24 +02:00
"is_required": false
},
{
2019-10-26 05:46:24 +02:00
"name": "page_size",
2019-04-11 21:35:24 +02:00
"type": "int",
2019-10-26 05:46:24 +02:00
"description": "number of items on page during pagination",
2019-04-11 21:35:24 +02:00
"is_required": false
}
],
"returns": "(list) List of blob hashes",
2019-04-12 14:58:00 +02:00
"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()",
2021-03-04 06:02:42 +01:00
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"items\": [\n \"311cd51592acc28ad9e7026da4a4969f70d403a70d5974ab94cdaacbbe50a0a48036e3431e52134857f822a49de4196d\",\n \"f31cb322b4fb4dd4b40b9d34aa73a653a91e8750f99d2be518f18bc11ac3a45bdebbb3974b73a198a7c0079ca1006acf\",\n \"3da9fe6b3aee199c40a6307f293f9006690cc8bbe1c30dca591e7d09f39ec7d3a3443cb526f95da4f9b94915ec511f6d\",\n \"ffd0b34649756ecf40381268f41e05fae1c40290888edd2a3b2e4c7af67935873d9805fb50f7464c942de34f06a23a6c\"\n ],\n \"page\": 1,\n \"page_size\": 20,\n \"total_items\": 4,\n \"total_pages\": 1\n }\n}"
2019-04-12 14:58:00 +02:00
}
]
2019-04-11 21:35:24 +02:00
},
{
"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": []
2019-04-06 21:33:19 +02:00
}
]
},
2019-04-11 21:35:24 +02:00
"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
},
2019-09-20 15:43:58 +02:00
{
"name": "wallet_id",
"type": "str",
"description": "restrict operation to specific wallet",
"is_required": false
},
2019-04-11 21:35:24 +02:00
{
"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
}
],
2020-03-22 01:15:21 +01:00
"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 prot
2019-04-11 21:35:24 +02:00
"examples": [
{
2019-04-12 14:58:00 +02:00
"title": "Abandon a channel claim",
2021-03-04 06:02:42 +01:00
"curl": "curl -d'{\"method\": \"channel_abandon\", \"params\": {\"claim_id\": \"b312a0c4eff10abe98542f99679ccddc20840daa\", \"preview\": false, \"blocking\": false}}' http://localhost:5279/",
"lbrynet": "lbrynet channel abandon b312a0c4eff10abe98542f99679ccddc20840daa",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"channel_abandon\", \"params\": {\"claim_id\": \"b312a0c4eff10abe98542f99679ccddc20840daa\", \"preview\": false, \"blocking\": false}}).json()",
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"height\": -2,\n \"hex\": \"0100000001ac5fa13aa4e403321f366686696157b61f2351962a44433f91bab13a386a7551000000006a47304402202f6572c66002f6f6c22a8fc14d77917cfab88ca10beac1e15e9127e656a8cbdb0220120f385d2920de764049a6cb43e6866335b14a97806e8dc334541ad79c634dad012103e9b87aec0af2761f19ac855a484f47963e812e14ae0c15d41fa330875b0e166cffffffff0134b7f505000000001976a9145059d1db9f1e07185401089951f3382b56bc602e88ac00000000\",\n \"inputs\": [\n {\n \"address\": \"mtcRw1f5eTuchnSTgvRMiBDJ97eQSeWRb3\",\n \"amount\": \"1.0\",\n \"claim_id\": \"b312a0c4eff10abe98542f99679ccddc20840daa\",\n \"claim_op\": \"update\",\n \"confirmations\": 9,\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#b312a0c4eff10abe98542f99679ccddc20840daa\",\n \"timestamp\": 1614834156,\n \"txid\": \"51756a383ab1ba913f43442a9651231fb65761698666361f3203e4a43aa15fac\",\n \"type\": \"claim\",\n \"value\": {\n \"public_key\": \"3056301006072a8648ce3d020106052b8104000a03420004822b2981f3e209733bab8625b24389d8c1dc9e18d6dab2eaff74977992dce4f0e884799d7eb928337595d7df1384f8851f5043e2d1532cd2a5f69a7e16797b5a\",\n \"public_key_id\": \"mzK5Y4GEhLT3bT6Xw4MDvEF2ve1BaNAtJt\",\n \"title\": \"New Channel\"\n },\n \"value_type\": \"channel\"\n }\n ],\n \"outputs\": [\n {\n \"address\": \"mnqoxBn14bSdzLMLH1F94GouriTenxXEnC\",\n \"amount\": \"0.999893\",\n \"confirmations\": -2,\n \"height\": -2,\n \"nout\": 0,\n \"timestamp\": null,\n \"txid\": \"aafe34a4e2b90dfa1c60917945a4a43ef44515c6669f9be0a60ff05feb54ef14\",\n \"type\": \"payment\"\n }\n ],\n \"total_fee\": \"0.000107\",\n \"total_input\": \"1.0\",\n \"total_output\": \"0.999893\",\n \"txid\": \"aafe34a4e2b90dfa1c60917945a4a43ef44515c6669f9be0a60ff05feb54ef14\"\n }\n}"
2019-04-11 21:35:24 +02:00
}
]
},
{
"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
},
2019-04-27 19:13:20 +02:00
{
"name": "allow_duplicate_name",
"type": "bool",
"description": "create new channel even if one already exists with given name. default: false.",
"is_required": false
},
2019-04-11 21:35:24 +02:00
{
"name": "title",
"type": "str",
"description": "title of the publication",
"is_required": false
},
{
"name": "description",
"type": "str",
"description": "description of the publication",
"is_required": false
},
2019-04-27 19:13:20 +02:00
{
"name": "email",
"type": "str",
"description": "email of channel owner",
"is_required": false
},
{
"name": "website_url",
"type": "str",
"description": "website url",
"is_required": false
},
2019-04-21 05:56:40 +02:00
{
"name": "featured",
"type": "list",
"description": "claim_ids of featured content in channel",
"is_required": false
},
2019-04-11 21:35:24 +02:00
{
"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",
2019-08-12 07:26:42 +02:00
"description": "account to use for holding the transaction",
"is_required": false
},
2019-09-20 15:43:58 +02:00
{
"name": "wallet_id",
"type": "str",
"description": "restrict operation to specific wallet",
"is_required": false
},
2019-08-12 07:26:42 +02:00
{
"name": "funding_account_ids",
"type": "list",
"description": "ids of accounts to fund this transaction",
2019-04-11 21:35:24 +02:00
"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
2019-06-25 21:34:32 +02:00
},
{
"name": "blocking",
"type": "bool",
"description": "wait until transaction is in mempool",
"is_required": false
2019-04-11 21:35:24 +02:00
}
],
2020-03-22 01:15:21 +01:00
"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 prot
2019-04-11 21:35:24 +02:00
"examples": [
{
"title": "Create a channel claim without metadata",
2019-08-12 07:26:42 +02:00
"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/",
2019-04-11 21:35:24 +02:00
"lbrynet": "lbrynet channel create @channel 1.0",
2019-08-12 07:26:42 +02:00
"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()",
2021-03-04 06:02:42 +01:00
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"height\": -2,\n \"hex\": \"0100000001a228e308765165e836e301d697866b58a55f3c0b7a4f0a9d772e0b2809d397fa010000006b483045022100fa1add496427b8d6f93f57e0fe47afd39d8c4d405ee6c81b88f997d0cae30e5302207a0a70cf0c6bbfb0e2b315796d0c3229f958ba242311ab1c0020ac4c535039e1012103c34a1e25ff921e476d5fcf7af1eb5ceec6d699261094d7ed6f02347d0447f834ffffffff0200e1f5050000000084b508406368616e6e656c4c5d00125a0a583056301006072a8648ce3d020106052b8104000a03420004822b2981f3e209733bab8625b24389d8c1dc9e18d6dab2eaff74977992dce4f0e884799d7eb928337595d7df1384f8851f5043e2d1532cd2a5f69a7e16797b5a6d7576a9148fa2c90e8c0619d00ccdaccd72be943796a9e24588acc462a029000000001976a9148b8739f3cdb5fea9a383d0c1e17ad2996fcbc4df88ac00000000\",\n \"inputs\": [\n {\n \"address\": \"n3CgTDtBMq1jigfQ3Y8NpYesjZyA4Qp3wm\",\n \"amount\": \"7.999876\",\n \"confirmations\": 2,\n \"height\": 207,\n \"nout\": 1,\n \"timestamp\": 1614834156,\n \"txid\": \"fa97d309280b2e779d0a4f7a0b3c5fa5586b8697d601e336e865517608e328a2\",\n \"type\": \"payment\"\n }\n ],\n \"outputs\": [\n {\n \"address\": \"mtcRw1f5eTuchnSTgvRMiBDJ97eQSeWRb3\",\n \"amount\": \"1.0\",\n \"claim_id\": \"b312a0c4eff10abe98542f99679ccddc20840daa\",\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#b312a0c4eff10abe98542f99679ccddc20840daa\",\n \"timestamp\": null,\n \"txid\": \"26aac673364ba7b2a982a9b389b3bb0678c35ef8c7c906328a9e8964b084966f\",\n \"type\": \"claim\",\n \"value\": {\n \"public_key\": \"3056301006072a8648ce3d020106052b8104000a03420004822b2981f3e209733bab8625b24389d8c1dc9e18d6dab2eaff74977992dce4f0e884799d7eb928337595d7df1384f8851f5043e2d1532cd2a5f69a7e16797b5a\",\n \"public_key_id\": \"mzK5Y4GEhLT3bT6Xw4MDvEF2ve1BaNAtJt\"\n },\n \"value_type\": \"channel\"\n },\n {\n \"address\": \"mtEiDQqYaxPYPj5HBwxUrEoFMYK8aAQBgy\",\n \"amount\": \"6.983769\",\n \"confirmations\": -2,\n \"height\": -2,\n \"nout\": 1,\n \"timestamp\": null,\n \"txid\": \"26aac673364ba7b2a982a9b389b3bb0678c35ef8c7c906328a9e8964b084966f\",\n \"type\": \"payment\"\n }\n ],\n \"total_fee\": \"0.016107\",\n \"total_input\": \"7.999876\",\n \"total_output\": \"7.983769\",\n \"txid\": \"26aac673364ba7b2a982a9b389b3bb0678c35ef8c7c906328a9e8964b084966f\"\n }\n}"
},
{
"title": "Create a channel claim with all metadata",
2019-08-12 07:26:42 +02:00
"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\"",
2019-08-12 07:26:42 +02:00
"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()",
2021-03-04 06:02:42 +01:00
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"height\": -2,\n \"hex\": \"0100000001ac5fa13aa4e403321f366686696157b61f2351962a44433f91bab13a386a7551010000006b483045022100acf26e284e018c32470ecdb05fc6650b84e40b0ee54ef9ef40e57673e20f44b40220671a3e8828bda4dbce3ca75eb65268041e93812a29c9340a0360c6b496fe72ed012102a3a837a10321357e9d8da8fda91900b98b800165dbaa8997ae6b56810ae7c7beffffffff0200e1f50500000000fd5001b50b406269676368616e6e656c4d25010012ab010a583056301006072a8648ce3d020106052b8104000a034200047ed273e6c364ab8e981e1b44776bf56a0995b0df2cf7a154a9530bd0cdba276e4672a7ae8fd9deb22d43c9c741a8478cbc1306330e2ae022f6a96c9fe1788018121663726561746f7240736d616c6c6d656469612e636f6d1a15687474703a2f2f736d616c6c6d656469612e636f6d22202a1e687474703a2f2f736d616c6c6d656469612e636f6d2f6c6f676f2e6a7067420b426967204368616e6e656c4a1e41206368616e6e656c2077697468206c6f7473206f6620766964656f732e52202a1e687474703a2f2f736d616c6c6d656469612e636f6d2f6c6f676f2e6a70675a056d757369635a0361727462050883011820620308ab016a0208206a0908e9011a044b6979766d7576a914a530022a5d3c8a898c574e1d0745b66d81fa986c88ace221d305000000001976a914fa2d6d25de892780ce0ebaf0c2f772c08bee754a88ac00000000\",\n \"inputs\": [\n {\n \"address\": \"mm6vVq975abgNiLdsxyLixMyP2LsqLiWXQ\",\n \"amount\": \"1.9993355\",\n \"confirmations\": 1,\n \"height\": 210,\n \"nout\": 1,\n \"timestamp\": 1614834156,\n \"txid\": \"51756a383ab1ba913f43442a9651231fb65761698666361f3203e4a43aa15fac\",\n \"type\": \"payment\"\n }\n ],\n \"outputs\": [\n {\n \"address\": \"mvaPJPhmN6aNDbYNWPtTgf3vR3SCQxUvfw\",\n \"amount\": \"1.0\",\n \"claim_id\": \"29ecfaaab4b2bdeb69f8cd02a07b717f14c522d1\",\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#29ecfaaab4b2bdeb69f8cd02a07b717f14c522d1\",\n \"timestamp\": null,\n \"txid\": \"8aa03d71ba83a0e77f5007dfc388becb91c55eb96694c57d442551849ca811e9\",\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\": \"3056301006072a8648ce3d020106052b8104000a034200047ed273e6c364ab8e981e1b44776bf56a0995b0df2cf7a154a9530bd0cdba276e4672a7ae8fd9deb22d43c9c741a8478cbc1306330e2ae022f6a96c9fe1788018\",\n \"public_key_id\": \"mugMj6KFwrKRwkuGi4VaTC2YJTmFLaL8pJ\",\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\": \"n4KmeHo7zQ59rjVxxzNv1tSA7g5w4yWqyk\",\n \"amount\": \"0.9772285\",\n \"confirmations\": -2,\n \"height\": -2,\n \"nout\": 1,\n \"timestamp\": null,\n \"txid\": \"8aa03d71ba83a0e77f5007dfc388becb91c55eb96694c57d442551849ca811e9\",\n \"type\": \"payment\"\n }\n ],\n \"total_fee\": \"0.022107\",\n \"total_input\": \"1.9993355\",\n \"total_output\": \"1.9772285\",\n \"txid\": \"8aa03d71ba83a0e77f5007dfc388becb91c55eb96694c57d442551849ca811e9\"\n }\n}"
2019-04-11 21:35:24 +02:00
}
]
},
{
"name": "channel_export",
2019-06-25 21:34:32 +02:00
"description": "Export channel private key.",
2019-04-11 21:35:24 +02:00
"arguments": [
{
2019-06-25 21:34:32 +02:00
"name": "channel_id",
2019-04-11 21:35:24 +02:00
"type": "str",
2019-06-25 21:34:32 +02:00
"description": "claim id of channel to export",
2019-04-11 21:35:24 +02:00
"is_required": true
2019-06-25 21:34:32 +02:00
},
{
"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
2019-09-20 15:43:58 +02:00
},
{
"name": "wallet_id",
"type": "str",
"description": "restrict operation to specific wallet",
"is_required": false
2019-04-11 21:35:24 +02:00
}
],
2019-06-25 21:34:32 +02:00
"returns": "(str) serialized channel private key",
2019-04-11 21:35:24 +02:00
"examples": []
},
{
"name": "channel_import",
2019-06-25 21:34:32 +02:00
"description": "Import serialized channel private key (to allow signing new streams to the channel)",
2019-04-11 21:35:24 +02:00
"arguments": [
{
2019-06-25 21:34:32 +02:00
"name": "channel_data",
2019-04-11 21:35:24 +02:00
"type": "str",
2019-06-25 21:34:32 +02:00
"description": "serialized channel, as exported by channel export",
2019-04-11 21:35:24 +02:00
"is_required": true
2019-09-20 15:43:58 +02:00
},
{
"name": "wallet_id",
"type": "str",
"description": "import into specific wallet",
"is_required": false
2019-04-11 21:35:24 +02:00
}
],
"returns": "(dict) Result dictionary",
"examples": []
},
{
"name": "channel_list",
"description": "List my channel claims.",
"arguments": [
2020-03-22 01:15:21 +01:00
{
"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
},
2020-08-19 21:46:29 +02:00
{
"name": "is_spent",
"type": "bool",
"description": "shows previous channel updates and abandons",
"is_required": false
},
2019-04-11 21:35:24 +02:00
{
"name": "account_id",
"type": "str",
"description": "id of the account to use",
"is_required": false
},
2019-09-20 15:43:58 +02:00
{
"name": "wallet_id",
"type": "str",
"description": "restrict results to specific wallet",
"is_required": false
},
2019-04-11 21:35:24 +02:00
{
"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
2020-02-01 23:59:57 +01:00
},
{
"name": "resolve",
"type": "bool",
"description": "resolves each channel to provide additional metadata",
"is_required": false
2020-03-22 01:15:21 +01:00
},
{
"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
2019-04-11 21:35:24 +02:00
}
],
2020-03-22 01:15:21 +01:00
"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 }",
2019-04-11 21:35:24 +02:00
"examples": [
{
2019-04-12 14:58:00 +02:00
"title": "List your channel claims",
2020-08-19 21:46:29 +02:00
"curl": "curl -d'{\"method\": \"channel_list\", \"params\": {\"name\": [], \"claim_id\": [], \"is_spent\": false, \"resolve\": false, \"no_totals\": false}}' http://localhost:5279/",
2019-04-11 21:35:24 +02:00
"lbrynet": "lbrynet channel list",
2020-08-19 21:46:29 +02:00
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"channel_list\", \"params\": {\"name\": [], \"claim_id\": [], \"is_spent\": false, \"resolve\": false, \"no_totals\": false}}).json()",
2021-03-04 06:02:42 +01:00
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"items\": [\n {\n \"address\": \"mtcRw1f5eTuchnSTgvRMiBDJ97eQSeWRb3\",\n \"amount\": \"1.0\",\n \"claim_id\": \"b312a0c4eff10abe98542f99679ccddc20840daa\",\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#b312a0c4eff10abe98542f99679ccddc20840daa\",\n \"timestamp\": 1614834156,\n \"txid\": \"26aac673364ba7b2a982a9b389b3bb0678c35ef8c7c906328a9e8964b084966f\",\n \"type\": \"claim\",\n \"value\": {\n \"public_key\": \"3056301006072a8648ce3d020106052b8104000a03420004822b2981f3e209733bab8625b24389d8c1dc9e18d6dab2eaff74977992dce4f0e884799d7eb928337595d7df1384f8851f5043e2d1532cd2a5f69a7e16797b5a\",\n \"public_key_id\": \"mzK5Y4GEhLT3bT6Xw4MDvEF2ve1BaNAtJt\"\n },\n \"value_type\": \"channel\"\n }\n ],\n \"page\": 1,\n \"page_size\": 20,\n \"total_items\": 1,\n \"total_pages\": 1\n }\n}"
2019-04-11 21:35:24 +02:00
},
{
2019-04-12 14:58:00 +02:00
"title": "Paginate your channel claims",
2020-08-19 21:46:29 +02:00
"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/",
2019-04-11 21:35:24 +02:00
"lbrynet": "lbrynet channel list --page=1 --page_size=20",
2020-08-19 21:46:29 +02:00
"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()",
2021-03-04 06:02:42 +01:00
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"items\": [\n {\n \"address\": \"mtcRw1f5eTuchnSTgvRMiBDJ97eQSeWRb3\",\n \"amount\": \"1.0\",\n \"claim_id\": \"b312a0c4eff10abe98542f99679ccddc20840daa\",\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#b312a0c4eff10abe98542f99679ccddc20840daa\",\n \"timestamp\": 1614834156,\n \"txid\": \"26aac673364ba7b2a982a9b389b3bb0678c35ef8c7c906328a9e8964b084966f\",\n \"type\": \"claim\",\n \"value\": {\n \"public_key\": \"3056301006072a8648ce3d020106052b8104000a03420004822b2981f3e209733bab8625b24389d8c1dc9e18d6dab2eaff74977992dce4f0e884799d7eb928337595d7df1384f8851f5043e2d1532cd2a5f69a7e16797b5a\",\n \"public_key_id\": \"mzK5Y4GEhLT3bT6Xw4MDvEF2ve1BaNAtJt\"\n },\n \"value_type\": \"channel\"\n }\n ],\n \"page\": 1,\n \"page_size\": 20,\n \"total_items\": 1,\n \"total_pages\": 1\n }\n}"
2019-04-11 21:35:24 +02:00
}
]
},
{
"name": "channel_sign",
"description": "Signs data using the specified channel signing key.",
"arguments": [
{
"name": "channel_name",
"type": "str",
"description": "name of channel used to sign (or use channel id)",
"is_required": false
},
{
"name": "channel_id",
"type": "str",
"description": "claim id of channel used to sign (or use channel name)",
"is_required": false
},
{
"name": "hexdata",
"type": "str",
"description": "data to sign, encoded as hexadecimal",
"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) Signature if successfully made, (None) or an error otherwise\n {\n \"signature\": (str) The signature of the comment,\n \"signing_ts\": (str) The timestamp used to sign the comment,\n }",
"examples": []
},
2019-04-11 21:35:24 +02:00
{
"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
},
2019-04-21 05:56:40 +02:00
{
2019-04-27 19:13:20 +02:00
"name": "email",
"type": "str",
"description": "email of channel owner",
"is_required": false
},
{
"name": "website_url",
"type": "str",
"description": "website url",
2019-04-21 05:56:40 +02:00
"is_required": false
},
{
"name": "featured",
"type": "list",
"description": "claim_ids of featured content in channel",
"is_required": false
},
2019-04-11 21:35:24 +02:00
{
2019-04-27 19:13:20 +02:00
"name": "clear_featured",
2019-04-11 21:35:24 +02:00
"type": "bool",
2019-04-27 19:13:20 +02:00
"description": "clear existing featured content (prior to adding new ones)",
2019-04-11 21:35:24 +02:00
"is_required": false
},
{
"name": "tags",
"type": "list",
"description": "add content tags",
"is_required": false
},
{
2019-04-27 19:13:20 +02:00
"name": "clear_tags",
2019-04-11 21:35:24 +02:00
"type": "bool",
2019-04-27 19:13:20 +02:00
"description": "clear existing tags (prior to adding new ones)",
2019-04-11 21:35:24 +02:00
"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
},
{
2019-04-27 19:13:20 +02:00
"name": "clear_languages",
2019-04-11 21:35:24 +02:00
"type": "bool",
2019-04-27 19:13:20 +02:00
"description": "clear existing languages (prior to adding new ones)",
2019-04-11 21:35:24 +02:00
"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
},
{
2019-04-27 19:13:20 +02:00
"name": "clear_locations",
"type": "bool",
"description": "clear existing locations (prior to adding new ones)",
2019-04-11 21:35:24 +02:00
"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",
2019-10-15 18:12:35 +02:00
"description": "account in which to look for channel (default: all)",
2019-08-12 07:26:42 +02:00
"is_required": false
},
2019-09-20 15:43:58 +02:00
{
"name": "wallet_id",
"type": "str",
"description": "restrict operation to specific wallet",
"is_required": false
},
2019-08-12 07:26:42 +02:00
{
"name": "funding_account_ids",
"type": "list",
"description": "ids of accounts to fund this transaction",
2019-04-11 21:35:24 +02:00
"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
2019-04-27 19:13:20 +02:00
},
2019-06-25 21:34:32 +02:00
{
"name": "blocking",
"type": "bool",
"description": "wait until transaction is in mempool",
"is_required": false
},
2019-04-27 19:13:20 +02:00
{
"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
2019-04-11 21:35:24 +02:00
}
],
2020-03-22 01:15:21 +01:00
"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 prot
2019-04-11 21:35:24 +02:00
"examples": [
{
2019-04-12 14:58:00 +02:00
"title": "Update a channel claim",
2021-03-04 06:02:42 +01:00
"curl": "curl -d'{\"method\": \"channel_update\", \"params\": {\"claim_id\": \"b312a0c4eff10abe98542f99679ccddc20840daa\", \"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 b312a0c4eff10abe98542f99679ccddc20840daa --title=\"New Channel\"",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"channel_update\", \"params\": {\"claim_id\": \"b312a0c4eff10abe98542f99679ccddc20840daa\", \"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\": \"01000000026f9684b064899e8a3206c9c7f85ec37806bbb389b3a982a9b2a74b3673c6aa26000000006b483045022100fb4eed6bf242b190099834cb4ddec11d92369984b989861ee56c6234ba7dc86b0220015dad9d0dc8d8d96699042bc7db01fe3f7d4d631fe954a2fad359632b12f5bf012103e9b87aec0af2761f19ac855a484f47963e812e14ae0c15d41fa330875b0e166cffffffffecc4a7b0c898200fe601983e91b47cea14082835f5085d8de8d3124895eeb5f1000000006b483045022100e491563240d3f4ec6a702b216602f5116c82c82a1c39621ee5718e98a7bacd03022077d6bd151099254e08df2c63509730b8239222fc44226d6dbb932e4cf26a599001210347e377e56ef15349d303511a87bb9d3b6c43e3a35b2361f7426c5d62e54a07f1ffffffff0200e1f50500000000a6b708406368616e6e656c14aa0d8420dccd9c67992f5498be0af1efc4a012b34c6a00125a0a583056301006072a8648ce3d020106052b8104000a03420004822b2981f3e209733bab8625b24389d8c1dc9e18d6dab2eaff74977992dce4f0e884799d7eb928337595d7df1384f8851f5043e2d1532cd2a5f69a7e16797b5a420b4e6577204368616e6e656c6d6d76a9148fa2c90e8c0619d00ccdaccd72be943796a9e24588ac6ebeea0b000000001976a9143d454587911f8a1a26e87397ba2e0d0a17d0923a88ac00000000\",\n \"inputs\": [\n {\n \"address\": \"mtcRw1f5eTuchnSTgvRMiBDJ97eQSeWRb3\",\n \"amount\": \"1.0\",\n \"claim_id\": \"b312a0c4eff10abe98542f99679ccddc20840daa\",\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#b312a0c4eff10abe98542f99679ccddc20840daa\",\n \"timestamp\": 1614834156,\n \"txid\": \"26aac673364ba7b2a982a9b389b3bb0678c35ef8c7c906328a9e8964b084966f\",\n \"type\": \"claim\",\n \"value\": {\n \"public_key\": \"3056301006072a8648ce3d020106052b8104000a03420004822b2981f3e209733bab8625b24389d8c1dc9e18d6dab2eaff74977992dce4f0e884799d7eb928337595d7df1384f8851f5043e2d1532cd2a5f69a7e16797b5a\",\n \"public_key_id\": \"mzK5Y4GEhLT3bT6Xw4MDvEF2ve1BaNAtJt\"\n },\n \"value_type\": \"channel\"\n },\n {\n \"address\": \"mvTLP2MGeAmwS7y9ir6Sowoa6hhBymUkpv\",\n \"amount\": \"1.999604\",\n \"confirmations\": 1,\n \"height\": 209,\n \"nout\": 0,\n \"timestamp\": 1614834156,\n \"txid\": \"f1b5ee954812d3e88d5d08f535280814ea7cb4913e9801e60f2098c8b0a7c4ec\",\n \"type\": \"payment\"\n }\n ],\n \"outputs\": [\n {\n \"address\": \"mtcRw1f5eTuchnSTgvRMiBDJ97eQSeWRb3\",\n \"amount\": \"1.0\",\n \"claim_id\": \"b312a0c4eff10abe98542f99679ccddc20840daa\",\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#b312a0c4eff10abe98542f99679ccddc20840daa\",\n \"timestamp\": null,\n \"txid\": \"51756a383ab1ba913f43442a9651231fb65761698666361f3203e4a43aa15fac\",\n \"type\": \"claim\",\n \"value\": {\n \"public_key\": \"3056301006072a8648ce3d020106052b8104000a03420004822b2981f3e209733bab8625b24389d8c1dc9e18d6dab2eaff74977992dce4f0e884799d7eb928337595d7df1384f8851f5043e2d1532cd2a5f69a7e16797b5a\",\n \"public_key_id\": \"mzK5Y4GEhLT3bT6Xw4MDvEF2ve1BaNAtJt\",\n \"title\": \"New Channel\"\n },\n \"value_type\": \"channel\"\n },\n {\n \"address\": \"mm6vVq975abgNiLdsxyLixMyP2LsqLiWXQ\",\n \"amount\": \"1.9993355\",\n \"confirmations\": -2,\n \"height\": -2,\n \"nout\": 1,\n \"timestamp\": null,\n \"txid\": \"51756a383ab1ba913f43442a9651231fb65761698666361f3203e4a43aa15fac\",\n \"type\": \"payment\"\n }\n ],\n \"total_fee\": \"0.0002685\",\n \"total_input\": \"2.999604\",\n \"total_output\": \"2.9993355\",\n
2019-04-11 21:35:24 +02:00
}
]
2019-04-06 21:33:19 +02:00
}
]
},
2019-04-11 21:35:24 +02:00
"claim": {
"doc": "List and search all types of claims.",
"commands": [
{
"name": "claim_list",
"description": "List my stream and channel claims.",
"arguments": [
2019-11-20 16:39:17 +01:00
{
"name": "claim_type",
2020-03-22 01:15:21 +01:00
"type": "str or list",
2019-11-20 16:39:17 +01:00
"description": "claim type: channel, stream, repost, collection",
"is_required": false
},
2020-03-22 01:15:21 +01:00
{
"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
},
2020-08-19 21:46:29 +02:00
{
"name": "is_spent",
"type": "bool",
"description": "shows previous claim updates and abandons",
"is_required": false
},
2019-04-11 21:35:24 +02:00
{
"name": "account_id",
"type": "str",
"description": "id of the account to query",
"is_required": false
},
2019-09-20 15:43:58 +02:00
{
"name": "wallet_id",
"type": "str",
"description": "restrict results to specific wallet",
"is_required": false
},
2019-04-11 21:35:24 +02:00
{
"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
2020-02-01 23:59:57 +01:00
},
{
"name": "resolve",
"type": "bool",
"description": "resolves each claim to provide additional metadata",
"is_required": false
2020-03-22 01:15:21 +01:00
},
{
"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
2020-03-31 03:45:58 +02:00
},
{
"name": "include_received_tips",
"type": "bool",
2021-02-17 00:07:43 +01:00
"description": "calculate the amount of tips received for claim outputs",
2020-03-31 03:45:58 +02:00
"is_required": false
2019-04-11 21:35:24 +02:00
}
],
2020-03-22 01:15:21 +01:00
"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 }",
2019-04-11 21:35:24 +02:00
"examples": [
{
2019-04-12 14:58:00 +02:00
"title": "List all your claims",
2020-08-19 21:46:29 +02:00
"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/",
2019-04-11 21:35:24 +02:00
"lbrynet": "lbrynet claim list",
2020-08-19 21:46:29 +02:00
"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()",
2021-03-04 06:02:42 +01:00
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"items\": [\n {\n \"address\": \"n4fHJYFChC7a9V7M9BjLsnyzsMj4p821u2\",\n \"amount\": \"1.0\",\n \"claim_id\": \"8e1d6b1b4aabe90269528e6cd09ec6e67086aa27\",\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#8e1d6b1b4aabe90269528e6cd09ec6e67086aa27\",\n \"signing_channel\": {\n \"address\": \"mtcRw1f5eTuchnSTgvRMiBDJ97eQSeWRb3\",\n \"amount\": \"1.0\",\n \"claim_id\": \"b312a0c4eff10abe98542f99679ccddc20840daa\",\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#b312a0c4eff10abe98542f99679ccddc20840daa\",\n \"timestamp\": 1614834156,\n \"txid\": \"51756a383ab1ba913f43442a9651231fb65761698666361f3203e4a43aa15fac\",\n \"type\": \"claim\",\n \"value\": {\n \"public_key\": \"3056301006072a8648ce3d020106052b8104000a03420004822b2981f3e209733bab8625b24389d8c1dc9e18d6dab2eaff74977992dce4f0e884799d7eb928337595d7df1384f8851f5043e2d1532cd2a5f69a7e16797b5a\",\n \"public_key_id\": \"mzK5Y4GEhLT3bT6Xw4MDvEF2ve1BaNAtJt\",\n \"title\": \"New Channel\"\n },\n \"value_type\": \"channel\"\n },\n \"timestamp\": 1614834157,\n \"txid\": \"040def12329d3b9002595f77a3bb87fd43f9c603595f0c7da3fa92582efde10d\",\n \"type\": \"claim\",\n \"value\": {\n \"source\": {\n \"hash\": \"fdbd8e75a67f29f701a4e040385e2e23986303ea10239211af907fcbb83578b3e417cb71ce646efd0819dd8c088de1bd\",\n \"media_type\": \"application/octet-stream\",\n \"name\": \"tmpuyu0q8tj\",\n \"sd_hash\": \"3da9fe6b3aee199c40a6307f293f9006690cc8bbe1c30dca591e7d09f39ec7d3a3443cb526f95da4f9b94915ec511f6d\",\n \"size\": \"11\"\n },\n \"stream_type\": \"binary\"\n },\n \"value_type\": \"stream\"\n },\n {\n \"address\": \"mtcRw1f5eTuchnSTgvRMiBDJ97eQSeWRb3\",\n \"amount\": \"1.0\",\n \"claim_id\": \"b312a0c4eff10abe98542f99679ccddc20840daa\",\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#b312a0c4eff10abe98542f99679ccddc20840daa\",\n \"timestamp\": 1614834156,\n \"txid\": \"51756a383ab1ba913f43442a9651231fb65761698666361f3203e4a43aa15fac\",\n \"type\": \"claim\",\n \"value\": {\n \"public_key\": \"3056301006072a8648ce3d020106052b8104000a03420004822b2981f3e209733bab8625b24389d8c1dc9e18d6dab2eaff74977992dce4f0e884799d7eb928337595d7df1384f8851f5043e2d1532cd2a5f69a7e16797b5a\",\n \"public_key_id\": \"mzK5Y4GEhLT3bT6Xw4MDvEF2ve1BaNAtJt\",\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}"
2019-04-11 21:35:24 +02:00
},
{
2019-04-12 14:58:00 +02:00
"title": "Paginate your claims",
2020-08-19 21:46:29 +02:00
"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/",
2019-04-11 21:35:24 +02:00
"lbrynet": "lbrynet claim list --page=1 --page_size=20",
2020-08-19 21:46:29 +02:00
"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()",
2021-03-04 06:02:42 +01:00
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"items\": [\n {\n \"address\": \"n4fHJYFChC7a9V7M9BjLsnyzsMj4p821u2\",\n \"amount\": \"1.0\",\n \"claim_id\": \"8e1d6b1b4aabe90269528e6cd09ec6e67086aa27\",\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#8e1d6b1b4aabe90269528e6cd09ec6e67086aa27\",\n \"signing_channel\": {\n \"address\": \"mtcRw1f5eTuchnSTgvRMiBDJ97eQSeWRb3\",\n \"amount\": \"1.0\",\n \"claim_id\": \"b312a0c4eff10abe98542f99679ccddc20840daa\",\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#b312a0c4eff10abe98542f99679ccddc20840daa\",\n \"timestamp\": 1614834156,\n \"txid\": \"51756a383ab1ba913f43442a9651231fb65761698666361f3203e4a43aa15fac\",\n \"type\": \"claim\",\n \"value\": {\n \"public_key\": \"3056301006072a8648ce3d020106052b8104000a03420004822b2981f3e209733bab8625b24389d8c1dc9e18d6dab2eaff74977992dce4f0e884799d7eb928337595d7df1384f8851f5043e2d1532cd2a5f69a7e16797b5a\",\n \"public_key_id\": \"mzK5Y4GEhLT3bT6Xw4MDvEF2ve1BaNAtJt\",\n \"title\": \"New Channel\"\n },\n \"value_type\": \"channel\"\n },\n \"timestamp\": 1614834157,\n \"txid\": \"040def12329d3b9002595f77a3bb87fd43f9c603595f0c7da3fa92582efde10d\",\n \"type\": \"claim\",\n \"value\": {\n \"source\": {\n \"hash\": \"fdbd8e75a67f29f701a4e040385e2e23986303ea10239211af907fcbb83578b3e417cb71ce646efd0819dd8c088de1bd\",\n \"media_type\": \"application/octet-stream\",\n \"name\": \"tmpuyu0q8tj\",\n \"sd_hash\": \"3da9fe6b3aee199c40a6307f293f9006690cc8bbe1c30dca591e7d09f39ec7d3a3443cb526f95da4f9b94915ec511f6d\",\n \"size\": \"11\"\n },\n \"stream_type\": \"binary\"\n },\n \"value_type\": \"stream\"\n },\n {\n \"address\": \"mtcRw1f5eTuchnSTgvRMiBDJ97eQSeWRb3\",\n \"amount\": \"1.0\",\n \"claim_id\": \"b312a0c4eff10abe98542f99679ccddc20840daa\",\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#b312a0c4eff10abe98542f99679ccddc20840daa\",\n \"timestamp\": 1614834156,\n \"txid\": \"51756a383ab1ba913f43442a9651231fb65761698666361f3203e4a43aa15fac\",\n \"type\": \"claim\",\n \"value\": {\n \"public_key\": \"3056301006072a8648ce3d020106052b8104000a03420004822b2981f3e209733bab8625b24389d8c1dc9e18d6dab2eaff74977992dce4f0e884799d7eb928337595d7df1384f8851f5043e2d1532cd2a5f69a7e16797b5a\",\n \"public_key_id\": \"mzK5Y4GEhLT3bT6Xw4MDvEF2ve1BaNAtJt\",\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}"
2019-04-11 21:35:24 +02:00
}
]
},
{
"name": "claim_search",
2019-05-28 04:50:26 +02:00
"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.",
2019-04-11 21:35:24 +02:00
"arguments": [
{
"name": "name",
"type": "str",
2019-05-28 04:50:26 +02:00
"description": "claim name (normalized)",
2019-04-11 21:35:24 +02:00
"is_required": false
},
2019-11-20 16:39:17 +01:00
{
"name": "text",
"type": "str",
"description": "full text search",
"is_required": false
},
2019-04-11 21:35:24 +02:00
{
"name": "claim_id",
"type": "str",
2019-05-28 04:50:26 +02:00
"description": "full or partial claim id",
2019-04-11 21:35:24 +02:00
"is_required": false
},
2019-11-20 16:39:17 +01:00
{
"name": "claim_ids",
"type": "list",
"description": "list of full claim ids",
"is_required": false
},
2019-04-11 21:35:24 +02:00
{
"name": "txid",
"type": "str",
2019-05-28 04:50:26 +02:00
"description": "transaction id",
2019-04-11 21:35:24 +02:00
"is_required": false
},
{
"name": "nout",
"type": "str",
2019-05-28 04:50:26 +02:00
"description": "position in the transaction",
2019-04-11 21:35:24 +02:00
"is_required": false
},
{
2019-05-28 04:50:26 +02:00
"name": "channel",
2019-04-11 21:35:24 +02:00
"type": "str",
2019-06-25 21:34:32 +02:00
"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",
2019-04-11 21:35:24 +02:00
"is_required": false
},
2019-04-27 19:13:20 +02:00
{
2019-05-28 04:50:26 +02:00
"name": "channel_ids",
2019-08-12 07:26:42 +02:00
"type": "list",
2019-06-25 21:34:32 +02:00
"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",
2019-04-27 19:13:20 +02:00
"is_required": false
},
2019-04-11 21:35:24 +02:00
{
2019-06-25 21:34:32 +02:00
"name": "not_channel_ids",
2019-08-12 07:26:42 +02:00
"type": "list",
2019-06-25 21:34:32 +02:00
"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",
2019-04-11 21:35:24 +02:00
"type": "bool",
2019-06-25 21:34:32 +02:00
"description": "claims with invalid channel signature or no signature, use in conjunction with --has_channel_signature to only get claims with invalid signatures",
2019-05-28 04:50:26 +02:00
"is_required": false
},
2020-08-19 21:46:29 +02:00
{
"name": "limit_claims_per_channel",
"type": "int",
"description": "only return up to the specified number of claims per channel",
"is_required": false
},
2019-05-28 04:50:26 +02:00
{
"name": "is_controlling",
"type": "bool",
2019-06-25 21:34:32 +02:00
"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'}",
2019-05-28 04:50:26 +02:00
"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",
2019-10-02 20:04:30 +02:00
"description": "limit by supports and tips received (supports equality constraints)",
2019-05-28 04:50:26 +02:00
"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
},
2019-11-20 16:39:17 +01:00
{
"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
},
2019-06-25 21:34:32 +02:00
{
"name": "claim_type",
"type": "str",
2021-03-01 17:52:17 +01:00
"description": "filter by 'channel', 'stream', 'repost' or 'collection'",
2019-06-25 21:34:32 +02:00
"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
},
2020-02-01 23:59:57 +01:00
{
"name": "duration",
"type": "int",
"description": "duration of video or audio in seconds (supports equality constraints)",
"is_required": false
},
2019-05-28 04:50:26 +02:00
{
"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",
2019-04-11 21:35:24 +02:00
"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
2019-05-28 04:50:26 +02:00
},
{
"name": "order_by",
2019-08-12 07:26:42 +02:00
"type": "list",
2019-05-28 04:50:26 +02:00
"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
2019-08-12 07:26:42 +02:00
},
{
"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
2019-11-20 16:39:17 +01:00
},
{
"name": "wallet_id",
"type": "str",
2021-02-17 00:07:43 +01:00
"description": "wallet to check for claim purchase receipts",
2019-11-20 16:39:17 +01:00
"is_required": false
2020-03-31 03:45:58 +02:00
},
{
"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
2020-08-19 21:46:29 +02:00
},
{
"name": "new_sdk_server",
"type": "str",
"description": "URL of the new SDK server (EXPERIMENTAL)",
"is_required": false
2019-04-11 21:35:24 +02:00
}
],
2020-03-22 01:15:21 +01:00
"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 }",
2019-04-12 14:58:00 +02:00
"examples": [
{
"title": "Search for all claims in channel",
2021-03-01 17:52:17 +01:00
"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\": [], \"no_totals\": false, \"include_purchase_receipt\": false, \"include_is_my_output\": false}}' http://localhost:5279/",
2019-05-28 04:50:26 +02:00
"lbrynet": "lbrynet claim search --channel=@channel",
2021-03-01 17:52:17 +01:00
"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\": [], \"no_totals\": false, \"include_purchase_receipt\": false, \"include_is_my_output\": false}}).json()",
2021-03-04 06:02:42 +01:00
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"blocked\": {\n \"channels\": [],\n \"total\": 0\n },\n \"items\": [\n {\n \"address\": \"n4fHJYFChC7a9V7M9BjLsnyzsMj4p821u2\",\n \"amount\": \"1.0\",\n \"canonical_url\": \"lbry://@channel#b/astream#8\",\n \"claim_id\": \"8e1d6b1b4aabe90269528e6cd09ec6e67086aa27\",\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\": 1614834157,\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#8e1d6b1b4aabe90269528e6cd09ec6e67086aa27\",\n \"short_url\": \"lbry://astream#8\",\n \"signing_channel\": {\n \"address\": \"mtcRw1f5eTuchnSTgvRMiBDJ97eQSeWRb3\",\n \"amount\": \"1.0\",\n \"canonical_url\": \"lbry://@channel#b\",\n \"claim_id\": \"b312a0c4eff10abe98542f99679ccddc20840daa\",\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\": 1614834156,\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#b312a0c4eff10abe98542f99679ccddc20840daa\",\n \"short_url\": \"lbry://@channel#b\",\n \"timestamp\": 1614834156,\n \"txid\": \"51756a383ab1ba913f43442a9651231fb65761698666361f3203e4a43aa15fac\",\n \"type\": \"claim\",\n \"value\": {\n \"public_key\": \"3056301006072a8648ce3d020106052b8104000a03420004822b2981f3e209733bab8625b24389d8c1dc9e18d6dab2eaff74977992dce4f0e884799d7eb928337595d7df1384f8851f5043e2d1532cd2a5f69a7e16797b5a\",\n \"public_key_id\": \"mzK5Y4GEhLT3bT6Xw4MDvEF2ve1BaNAtJt\",\n \"title\": \"New Channel\"\n },\n \"value_type\": \"channel\"\n },\n \"timestamp\": 1614834157,\n \"txid\": \"040def12329d3b9002595f77a3bb87fd43f9c603595f0c7da3fa92582efde10d\",\n \"type\": \"claim\",\n \"value\": {\n \"source\": {\n \"hash\": \"fdbd8e75a67f29f701a4e040385e2e23986303ea10239211af907fcbb83578b3e417cb71ce646efd0819dd8c088de1bd\",\n \"media_type\": \"application/octet-stream\",\n \"name\": \"tmpuyu0q8tj\",\n \"sd_hash\": \"3da9fe6b3aee199c40a6307f293f9006690cc8bbe1c30dca591e7d09f39ec7d3a3443cb526f95da4f9b94915ec511f6d\",\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}"
2019-04-12 14:58:00 +02:00
},
{
"title": "Search for claims matching a name",
2021-03-01 17:52:17 +01:00
"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\": [], \"no_totals\": false, \"include_purchase_receipt\": false, \"include_is_my_output\": false}}' http://localhost:5279/",
2019-04-12 14:58:00 +02:00
"lbrynet": "lbrynet claim search --name=\"astream\"",
2021-03-01 17:52:17 +01:00
"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\": [], \"no_totals\": false, \"include_purchase_receipt\": false, \"include_is_my_output\": false}}).json()",
2021-03-04 06:02:42 +01:00
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"blocked\": {\n \"channels\": [],\n \"total\": 0\n },\n \"items\": [\n {\n \"address\": \"n4fHJYFChC7a9V7M9BjLsnyzsMj4p821u2\",\n \"amount\": \"1.0\",\n \"canonical_url\": \"lbry://@channel#b/astream#8\",\n \"claim_id\": \"8e1d6b1b4aabe90269528e6cd09ec6e67086aa27\",\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\": 1614834157,\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#8e1d6b1b4aabe90269528e6cd09ec6e67086aa27\",\n \"short_url\": \"lbry://astream#8\",\n \"signing_channel\": {\n \"address\": \"mtcRw1f5eTuchnSTgvRMiBDJ97eQSeWRb3\",\n \"amount\": \"1.0\",\n \"canonical_url\": \"lbry://@channel#b\",\n \"claim_id\": \"b312a0c4eff10abe98542f99679ccddc20840daa\",\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\": 1614834156,\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#b312a0c4eff10abe98542f99679ccddc20840daa\",\n \"short_url\": \"lbry://@channel#b\",\n \"timestamp\": 1614834156,\n \"txid\": \"51756a383ab1ba913f43442a9651231fb65761698666361f3203e4a43aa15fac\",\n \"type\": \"claim\",\n \"value\": {\n \"public_key\": \"3056301006072a8648ce3d020106052b8104000a03420004822b2981f3e209733bab8625b24389d8c1dc9e18d6dab2eaff74977992dce4f0e884799d7eb928337595d7df1384f8851f5043e2d1532cd2a5f69a7e16797b5a\",\n \"public_key_id\": \"mzK5Y4GEhLT3bT6Xw4MDvEF2ve1BaNAtJt\",\n \"title\": \"New Channel\"\n },\n \"value_type\": \"channel\"\n },\n \"timestamp\": 1614834157,\n \"txid\": \"040def12329d3b9002595f77a3bb87fd43f9c603595f0c7da3fa92582efde10d\",\n \"type\": \"claim\",\n \"value\": {\n \"source\": {\n \"hash\": \"fdbd8e75a67f29f701a4e040385e2e23986303ea10239211af907fcbb83578b3e417cb71ce646efd0819dd8c088de1bd\",\n \"media_type\": \"application/octet-stream\",\n \"name\": \"tmpuyu0q8tj\",\n \"sd_hash\": \"3da9fe6b3aee199c40a6307f293f9006690cc8bbe1c30dca591e7d09f39ec7d3a3443cb526f95da4f9b94915ec511f6d\",\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}"
2019-04-12 14:58:00 +02:00
}
]
2018-08-22 06:20:30 +02:00
}
2019-04-11 21:35:24 +02:00
]
},
2019-11-20 16:39:17 +01:00
"collection": {
"doc": "Create, update, list, resolve, and abandon collections.",
2019-04-11 21:35:24 +02:00
"commands": [
2019-08-12 07:26:42 +02:00
{
2019-11-20 16:39:17 +01:00
"name": "collection_abandon",
"description": "Abandon one of my collection claims.",
2019-04-11 21:35:24 +02:00
"arguments": [
2019-06-25 21:34:32 +02:00
{
"name": "claim_id",
"type": "str",
2019-11-20 16:39:17 +01:00
"description": "claim_id of the claim to abandon",
2019-04-11 21:35:24 +02:00
"is_required": false
2019-06-25 21:34:32 +02:00
},
{
2019-11-20 16:39:17 +01:00
"name": "txid",
2019-06-25 21:34:32 +02:00
"type": "str",
2019-11-20 16:39:17 +01:00
"description": "txid of the claim to abandon",
2019-06-25 21:34:32 +02:00
"is_required": false
},
{
2019-11-20 16:39:17 +01:00
"name": "nout",
"type": "int",
"description": "nout of the claim to abandon",
2019-06-25 21:34:32 +02:00
"is_required": false
},
{
2019-11-20 16:39:17 +01:00
"name": "account_id",
2019-06-25 21:34:32 +02:00
"type": "str",
2019-11-20 16:39:17 +01:00
"description": "id of the account to use",
2019-06-25 21:34:32 +02:00
"is_required": false
2019-09-20 15:43:58 +02:00
},
{
"name": "wallet_id",
"type": "str",
"description": "restrict operation to specific wallet",
"is_required": false
2019-11-20 16:39:17 +01:00
},
2019-08-28 18:55:19 +02:00
{
2019-11-20 16:39:17 +01:00
"name": "preview",
"type": "bool",
"description": "do not broadcast the transaction",
2019-08-28 18:55:19 +02:00
"is_required": false
2019-09-20 15:43:58 +02:00
},
{
2019-11-20 16:39:17 +01:00
"name": "blocking",
"type": "bool",
"description": "wait until abandon is in mempool",
2019-09-20 15:43:58 +02:00
"is_required": false
2019-08-28 18:55:19 +02:00
}
],
2020-03-22 01:15:21 +01:00
"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 prot
2019-08-28 18:55:19 +02:00
"examples": []
},
2019-04-11 21:35:24 +02:00
{
2019-11-20 16:39:17 +01:00
"name": "collection_create",
"description": "Create a new collection.",
2019-04-11 21:35:24 +02:00
"arguments": [
{
2019-11-20 16:39:17 +01:00
"name": "name",
2019-06-25 21:34:32 +02:00
"type": "str",
2019-11-20 16:39:17 +01:00
"description": "name of the collection",
2019-06-25 21:34:32 +02:00
"is_required": true
},
{
2019-11-20 16:39:17 +01:00
"name": "bid",
"type": "decimal",
"description": "amount to back the claim",
"is_required": true
2019-04-11 21:35:24 +02:00
},
{
2019-11-20 16:39:17 +01:00
"name": "claims",
"type": "list",
"description": "claim ids to be included in the collection",
2021-03-01 17:52:17 +01:00
"is_required": false
2019-04-11 21:35:24 +02:00
},
{
2019-11-20 16:39:17 +01:00
"name": "allow_duplicate_name",
2019-06-25 21:34:32 +02:00
"type": "bool",
2019-11-20 16:39:17 +01:00
"description": "create new collection even if one already exists with given name. default: false.",
2019-04-11 21:35:24 +02:00
"is_required": false
},
{
2019-11-20 16:39:17 +01:00
"name": "title",
"type": "str",
"description": "title of the collection",
2019-04-11 21:35:24 +02:00
"is_required": false
2019-08-28 18:55:19 +02:00
},
{
2019-11-20 16:39:17 +01:00
"name": "description",
"type": "str",
"description": "description of the collection",
2019-08-28 18:55:19 +02:00
"is_required": false
},
2019-04-11 21:35:24 +02:00
{
2019-11-20 16:39:17 +01:00
"name": "tags",
"type": "list",
"description": "content tags",
2019-04-11 21:35:24 +02:00
"is_required": false
},
{
2019-11-20 16:39:17 +01:00
"name": "clear_languages",
2019-04-11 21:35:24 +02:00
"type": "bool",
2019-11-20 16:39:17 +01:00
"description": "clear existing languages (prior to adding new ones)",
2019-04-11 21:35:24 +02:00
"is_required": false
},
{
2019-11-20 16:39:17 +01:00
"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`",
2019-04-11 21:35:24 +02:00
"is_required": false
},
{
2019-11-20 16:39:17 +01:00
"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'}\"",
2019-04-11 21:35:24 +02:00
"is_required": false
},
{
2019-11-20 16:39:17 +01:00
"name": "thumbnail_url",
2019-04-11 21:35:24 +02:00
"type": "str",
2019-11-20 16:39:17 +01:00
"description": "thumbnail url",
2019-04-11 21:35:24 +02:00
"is_required": false
},
2021-03-01 17:52:17 +01:00
{
"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
},
2019-04-11 21:35:24 +02:00
{
2019-11-20 16:39:17 +01:00
"name": "account_id",
2019-04-11 21:35:24 +02:00
"type": "str",
2019-11-20 16:39:17 +01:00
"description": "account to use for holding the transaction",
2019-04-11 21:35:24 +02:00
"is_required": false
},
{
2019-11-20 16:39:17 +01:00
"name": "wallet_id",
2019-04-11 21:35:24 +02:00
"type": "str",
2019-11-20 16:39:17 +01:00
"description": "restrict operation to specific wallet",
2019-04-11 21:35:24 +02:00
"is_required": false
},
{
2019-11-20 16:39:17 +01:00
"name": "funding_account_ids",
"type": "list",
"description": "ids of accounts to fund this transaction",
2019-04-11 21:35:24 +02:00
"is_required": false
},
{
2019-11-20 16:39:17 +01:00
"name": "claim_address",
2019-04-11 21:35:24 +02:00
"type": "str",
2019-11-20 16:39:17 +01:00
"description": "address where the collection is sent to, if not specified it will be determined automatically from the account",
2019-04-11 21:35:24 +02:00
"is_required": false
},
{
2019-11-20 16:39:17 +01:00
"name": "preview",
"type": "bool",
"description": "do not broadcast the transaction",
2019-04-11 21:35:24 +02:00
"is_required": false
},
{
2019-11-20 16:39:17 +01:00
"name": "blocking",
"type": "bool",
"description": "wait until transaction is in mempool",
2019-04-11 21:35:24 +02:00
"is_required": false
}
],
2020-03-22 01:15:21 +01:00
"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 prot
2021-03-01 18:54:09 +01:00
"examples": [
{
"title": "Create a collection of one stream",
2021-03-04 06:02:42 +01:00
"curl": "curl -d'{\"method\": \"collection_create\", \"params\": {\"name\": \"tom\", \"bid\": \"1.0\", \"claims\": [\"8e1d6b1b4aabe90269528e6cd09ec6e67086aa27\"], \"allow_duplicate_name\": false, \"tags\": [], \"languages\": [], \"locations\": [], \"channel_id\": \"b312a0c4eff10abe98542f99679ccddc20840daa\", \"channel_account_id\": [], \"funding_account_ids\": [], \"preview\": false, \"blocking\": false}}' http://localhost:5279/",
"lbrynet": "lbrynet collection create --name=tom --bid=1.0 --channel_id=b312a0c4eff10abe98542f99679ccddc20840daa --claims=8e1d6b1b4aabe90269528e6cd09ec6e67086aa27",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"collection_create\", \"params\": {\"name\": \"tom\", \"bid\": \"1.0\", \"claims\": [\"8e1d6b1b4aabe90269528e6cd09ec6e67086aa27\"], \"allow_duplicate_name\": false, \"tags\": [], \"languages\": [], \"locations\": [], \"channel_id\": \"b312a0c4eff10abe98542f99679ccddc20840daa\", \"channel_account_id\": [], \"funding_account_ids\": [], \"preview\": false, \"blocking\": false}}).json()",
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"height\": -2,\n \"hex\": \"0100000001c658e7bbd1b900c27854ee50bc1c936efecbff86f0b6dbe0fa935498ccbc9c8a010000006a4730440220249e1e97baa1f9e7602414ecd53e310ae31fb4598d0e69dc3ebb05f47b9f8e5a022021d5fd28eab560a955fa2fe5d5c9b33333751ddd3b10c3c766070dc5656d14e601210301cf1ec4ac3fe3f25c6250752288e42586396b61cd85fe4c15202ad8af47cab4ffffffff0200e1f5050000000091b503746f6d4c6f01aa0d8420dccd9c67992f5498be0af1efc4a012b3fa0a33fbce950319e1e93d37b8e7ac027b1c4ef42780aa428e756d4f3e986b70ee7a996b23a95b08b489fc27a3b926bf89fbd3755362d45900d0a584e5cea5db1a1812160a1427aa8670e6c69ed06c8e526902e9ab4a1b6b1d8e6d7576a9149163664e4085c5c218cc4ebef8fec91feb3e4ca588ac202c7e17000000001976a9146c67f3d6029f4e5eb63fc9c4c20755099924f65488ac00000000\",\n \"inputs\": [\n {\n \"address\": \"mvjMmSnptUQq5P81YaER63A2xvh3f8Fy18\",\n \"amount\": \"4.947555\",\n \"confirmations\": 2,\n \"height\": 215,\n \"nout\": 1,\n \"timestamp\": 1614834157,\n \"txid\": \"8a9cbccc985493fae0dbb6f086ffcbfe6e931cbc50ee5478c200b9d1bbe758c6\",\n \"type\": \"payment\"\n }\n ],\n \"outputs\": [\n {\n \"address\": \"mtmhMH1mm3xzJfzsKcgGgwb8Tga7nKsGSQ\",\n \"amount\": \"1.0\",\n \"claim_id\": \"99d652cb5528dbe8b01d06e550af798ea6cd0ee5\",\n \"claim_op\": \"create\",\n \"confirmations\": -2,\n \"height\": -2,\n \"is_channel_signature_valid\": true,\n \"meta\": {},\n \"name\": \"tom\",\n \"normalized_name\": \"tom\",\n \"nout\": 0,\n \"permanent_url\": \"lbry://tom#99d652cb5528dbe8b01d06e550af798ea6cd0ee5\",\n \"signing_channel\": {\n \"address\": \"mtcRw1f5eTuchnSTgvRMiBDJ97eQSeWRb3\",\n \"amount\": \"1.0\",\n \"claim_id\": \"b312a0c4eff10abe98542f99679ccddc20840daa\",\n \"claim_op\": \"update\",\n \"confirmations\": 7,\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#b312a0c4eff10abe98542f99679ccddc20840daa\",\n \"timestamp\": 1614834156,\n \"txid\": \"51756a383ab1ba913f43442a9651231fb65761698666361f3203e4a43aa15fac\",\n \"type\": \"claim\",\n \"value\": {\n \"public_key\": \"3056301006072a8648ce3d020106052b8104000a03420004822b2981f3e209733bab8625b24389d8c1dc9e18d6dab2eaff74977992dce4f0e884799d7eb928337595d7df1384f8851f5043e2d1532cd2a5f69a7e16797b5a\",\n \"public_key_id\": \"mzK5Y4GEhLT3bT6Xw4MDvEF2ve1BaNAtJt\",\n \"title\": \"New Channel\"\n },\n \"value_type\": \"channel\"\n },\n \"timestamp\": null,\n \"txid\": \"79d374f33ff80dc1049826650b51c1e65b0b3f5af4839b85cb9037882110c6d3\",\n \"type\": \"claim\",\n \"value\": {\n \"claims\": [\n \"8e1d6b1b4aabe90269528e6cd09ec6e67086aa27\"\n ]\n },\n \"value_type\": \"collection\"\n },\n {\n \"address\": \"mqQ9oWwESPiXhdCqnX74GKJC52Au3mLppJ\",\n \"amount\": \"3.941448\",\n \"confirmations\": -2,\n \"height\": -2,\n \"nout\": 1,\n \"timestamp\": null,\n \"txid\": \"79d374f33ff80dc1049826650b51c1e65b0b3f5af4839b85cb9037882110c6d3\",\n \"type\": \"payment\"\n }\n ],\n \"total_fee\": \"0.006107\",\n \"total_input\": \"4.947555\",\n \"total_output\": \"4.941448\",\n \"txid\": \"79d374f33ff80dc1049826650b51c1e65b0b3f5af4839b85cb9037882110c6d3\"\n }\n}"
2021-03-01 18:54:09 +01:00
}
]
2019-04-11 21:35:24 +02:00
},
{
2019-11-20 16:39:17 +01:00
"name": "collection_list",
"description": "List my collection claims.",
2019-04-11 21:35:24 +02:00
"arguments": [
2021-03-01 18:54:09 +01:00
{
"name": "resolve",
"type": "bool",
"description": "resolve collection claim",
"is_required": false
},
2019-04-11 21:35:24 +02:00
{
2019-11-20 16:39:17 +01:00
"name": "resolve_claims",
"type": "int",
"description": "resolve every claim",
2019-04-11 21:35:24 +02:00
"is_required": false
},
{
2019-11-20 16:39:17 +01:00
"name": "account_id",
2019-04-11 21:35:24 +02:00
"type": "str",
2019-11-20 16:39:17 +01:00
"description": "id of the account to use",
2019-04-11 21:35:24 +02:00
"is_required": false
},
{
2019-11-20 16:39:17 +01:00
"name": "wallet_id",
2019-04-11 21:35:24 +02:00
"type": "str",
2019-11-20 16:39:17 +01:00
"description": "restrict results to specific wallet",
2019-04-11 21:35:24 +02:00
"is_required": false
},
{
2019-11-20 16:39:17 +01:00
"name": "page",
2019-04-11 21:35:24 +02:00
"type": "int",
2019-11-20 16:39:17 +01:00
"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
}
],
2020-03-22 01:15:21 +01:00
"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 }",
2021-03-01 18:54:09 +01:00
"examples": [
{
"title": "List collections",
"curl": "curl -d'{\"method\": \"collection_list\", \"params\": {\"resolve_claims\": 1, \"resolve\": true}}' http://localhost:5279/",
"lbrynet": "lbrynet collection list --resolve --resolve_claims=1",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"collection_list\", \"params\": {\"resolve_claims\": 1, \"resolve\": true}}).json()",
2021-03-04 06:02:42 +01:00
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"items\": [\n {\n \"address\": \"mtmhMH1mm3xzJfzsKcgGgwb8Tga7nKsGSQ\",\n \"amount\": \"1.0\",\n \"canonical_url\": \"lbry://@channel#b/tom#9\",\n \"claim_id\": \"99d652cb5528dbe8b01d06e550af798ea6cd0ee5\",\n \"claim_op\": \"create\",\n \"claims\": [\n {\n \"address\": \"n4fHJYFChC7a9V7M9BjLsnyzsMj4p821u2\",\n \"amount\": \"1.0\",\n \"canonical_url\": \"lbry://@channel#b/astream#8\",\n \"claim_id\": \"8e1d6b1b4aabe90269528e6cd09ec6e67086aa27\",\n \"claim_op\": \"update\",\n \"confirmations\": 4,\n \"height\": 214,\n \"is_channel_signature_valid\": true,\n \"meta\": {\n \"activation_height\": 213,\n \"creation_height\": 213,\n \"creation_timestamp\": 1614834157,\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#8e1d6b1b4aabe90269528e6cd09ec6e67086aa27\",\n \"short_url\": \"lbry://astream#8\",\n \"signing_channel\": {\n \"address\": \"mtcRw1f5eTuchnSTgvRMiBDJ97eQSeWRb3\",\n \"amount\": \"1.0\",\n \"canonical_url\": \"lbry://@channel#b\",\n \"claim_id\": \"b312a0c4eff10abe98542f99679ccddc20840daa\",\n \"claim_op\": \"update\",\n \"confirmations\": 8,\n \"has_signing_key\": false,\n \"height\": 210,\n \"meta\": {\n \"activation_height\": 209,\n \"claims_in_channel\": 2,\n \"creation_height\": 209,\n \"creation_timestamp\": 1614834156,\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#b312a0c4eff10abe98542f99679ccddc20840daa\",\n \"short_url\": \"lbry://@channel#b\",\n \"timestamp\": 1614834156,\n \"txid\": \"51756a383ab1ba913f43442a9651231fb65761698666361f3203e4a43aa15fac\",\n \"type\": \"claim\",\n \"value\": {\n \"public_key\": \"3056301006072a8648ce3d020106052b8104000a03420004822b2981f3e209733bab8625b24389d8c1dc9e18d6dab2eaff74977992dce4f0e884799d7eb928337595d7df1384f8851f5043e2d1532cd2a5f69a7e16797b5a\",\n \"public_key_id\": \"mzK5Y4GEhLT3bT6Xw4MDvEF2ve1BaNAtJt\",\n \"title\": \"New Channel\"\n },\n \"value_type\": \"channel\"\n },\n \"timestamp\": 1614834157,\n \"txid\": \"040def12329d3b9002595f77a3bb87fd43f9c603595f0c7da3fa92582efde10d\",\n \"type\": \"claim\",\n \"value\": {\n \"source\": {\n \"hash\": \"fdbd8e75a67f29f701a4e040385e2e23986303ea10239211af907fcbb83578b3e417cb71ce646efd0819dd8c088de1bd\",\n \"media_type\": \"application/octet-stream\",\n \"name\": \"tmpuyu0q8tj\",\n \"sd_hash\": \"3da9fe6b3aee199c40
2021-03-01 18:54:09 +01:00
}
]
2019-11-20 16:39:17 +01:00
},
{
"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
}
],
2020-03-22 01:15:21 +01:00
"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 }",
2019-11-20 16:39:17 +01:00
"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": "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
}
],
2020-03-22 01:15:21 +01:00
"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 prot
2019-11-20 16:39:17 +01:00
"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 }",
2020-01-04 02:23:40 +01:00
"examples": [
{
"title": "Abandon a comment",
2021-03-04 06:02:42 +01:00
"curl": "curl -d'{\"method\": \"comment_abandon\", \"params\": {\"comment_id\": \"b88abe2cd021b3b6b2a705a09b0cc3a97f9c8a49008b3a1d5c435b0431ba62ab4658c0e2e5d47fb78147016cb2a4708de87ca27ee6b5657e042db085bcb9692c\"}}' http://localhost:5279/",
"lbrynet": "lbrynet comment abandon b88abe2cd021b3b6b2a705a09b0cc3a97f9c8a49008b3a1d5c435b0431ba62ab4658c0e2e5d47fb78147016cb2a4708de87ca27ee6b5657e042db085bcb9692c",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"comment_abandon\", \"params\": {\"comment_id\": \"b88abe2cd021b3b6b2a705a09b0cc3a97f9c8a49008b3a1d5c435b0431ba62ab4658c0e2e5d47fb78147016cb2a4708de87ca27ee6b5657e042db085bcb9692c\"}}).json()",
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"b88abe2cd021b3b6b2a705a09b0cc3a97f9c8a49008b3a1d5c435b0431ba62ab4658c0e2e5d47fb78147016cb2a4708de87ca27ee6b5657e042db085bcb9692c\": {\n \"abandoned\": true\n }\n }\n}"
2020-01-04 02:23:40 +01:00
}
]
2019-11-20 16:39:17 +01:00
},
{
"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",
2020-01-19 03:23:38 +01:00
"description": "one or more account ids for accounts to look in for channel certificates, defaults to all accounts",
2019-11-20 16:39:17 +01:00
"is_required": false
},
{
"name": "wallet_id",
"type": "str",
"description": "restrict operation to specific wallet",
"is_required": false
}
],
2020-10-10 18:26:26 +02:00
"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 }",
2020-01-04 02:23:40 +01:00
"examples": [
{
"title": "Posting a comment as your channel",
2021-03-04 06:02:42 +01:00
"curl": "curl -d'{\"method\": \"comment_create\", \"params\": {\"comment\": \"Thank you Based God\", \"claim_id\": \"8e1d6b1b4aabe90269528e6cd09ec6e67086aa27\", \"channel_name\": \"@channel\", \"channel_account_id\": []}}' http://localhost:5279/",
"lbrynet": "lbrynet comment create --comment=\"Thank you Based God\" --channel_name=@channel --claim_id=8e1d6b1b4aabe90269528e6cd09ec6e67086aa27",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"comment_create\", \"params\": {\"comment\": \"Thank you Based God\", \"claim_id\": \"8e1d6b1b4aabe90269528e6cd09ec6e67086aa27\", \"channel_name\": \"@channel\", \"channel_account_id\": []}}).json()",
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"channel_id\": \"b312a0c4eff10abe98542f99679ccddc20840daa\",\n \"channel_name\": \"@channel\",\n \"channel_url\": \"lbry://@channel#b312a0c4eff10abe98542f99679ccddc20840daa\",\n \"claim_id\": \"8e1d6b1b4aabe90269528e6cd09ec6e67086aa27\",\n \"comment\": \"Thank you Based God\",\n \"comment_id\": \"b88abe2cd021b3b6b2a705a09b0cc3a97f9c8a49008b3a1d5c435b0431ba62ab4658c0e2e5d47fb78147016cb2a4708de87ca27ee6b5657e042db085bcb9692c\",\n \"is_claim_signature_valid\": true,\n \"is_hidden\": false,\n \"is_pinned\": false,\n \"signature\": \"c8abd66f333be477aae482d73ee7446f9249261b8278f48c0518f5e29726357aecaad62bb962c5c079de5f023586d7f93759ab8bdbaf4de4d888cfb601146fdd\",\n \"signing_ts\": \"1614834138\",\n \"timestamp\": \"1614834138\"\n }\n}"
2020-01-04 02:23:40 +01:00
},
{
2020-03-22 01:15:21 +01:00
"title": "Use the parent_id param to make replies",
2021-03-04 06:02:42 +01:00
"curl": "curl -d'{\"method\": \"comment_create\", \"params\": {\"comment\": \"I have photographic evidence confirming Sasquatch exists\", \"claim_id\": \"8e1d6b1b4aabe90269528e6cd09ec6e67086aa27\", \"parent_id\": \"b88abe2cd021b3b6b2a705a09b0cc3a97f9c8a49008b3a1d5c435b0431ba62ab4658c0e2e5d47fb78147016cb2a4708de87ca27ee6b5657e042db085bcb9692c\", \"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=b88abe2cd021b3b6b2a705a09b0cc3a97f9c8a49008b3a1d5c435b0431ba62ab4658c0e2e5d47fb78147016cb2a4708de87ca27ee6b5657e042db085bcb9692c --claim_id=8e1d6b1b4aabe90269528e6cd09ec6e67086aa27",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"comment_create\", \"params\": {\"comment\": \"I have photographic evidence confirming Sasquatch exists\", \"claim_id\": \"8e1d6b1b4aabe90269528e6cd09ec6e67086aa27\", \"parent_id\": \"b88abe2cd021b3b6b2a705a09b0cc3a97f9c8a49008b3a1d5c435b0431ba62ab4658c0e2e5d47fb78147016cb2a4708de87ca27ee6b5657e042db085bcb9692c\", \"channel_name\": \"@channel\", \"channel_account_id\": []}}).json()",
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"channel_id\": \"b312a0c4eff10abe98542f99679ccddc20840daa\",\n \"channel_name\": \"@channel\",\n \"channel_url\": \"lbry://@channel#b312a0c4eff10abe98542f99679ccddc20840daa\",\n \"claim_id\": \"8e1d6b1b4aabe90269528e6cd09ec6e67086aa27\",\n \"comment\": \"I have photographic evidence confirming Sasquatch exists\",\n \"comment_id\": \"4cf468b7f4d57c97ccecc02a2834f6197141b365640a0df40062574748f601760c2046fa3b007ac7652b092ba4731e1c9bf77f116b531c25e809fc8a309dae98\",\n \"is_claim_signature_valid\": true,\n \"is_hidden\": false,\n \"is_pinned\": false,\n \"parent_id\": \"b88abe2cd021b3b6b2a705a09b0cc3a97f9c8a49008b3a1d5c435b0431ba62ab4658c0e2e5d47fb78147016cb2a4708de87ca27ee6b5657e042db085bcb9692c\",\n \"signature\": \"786e474fce43d6bb8714194f2e33e1f4fb79f2d8b7889572713b73fdd76b089aec78dfe310f440f59959ac0989c3f39a6a2d650aa1dd285667c49417cf10fda9\",\n \"signing_ts\": \"1614834138\",\n \"timestamp\": \"1614834138\"\n }\n}"
2020-01-04 02:23:40 +01:00
}
]
2019-11-20 16:39:17 +01:00
},
{
"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
}
],
2020-08-19 21:46:29 +02:00
"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 }",
2019-11-20 16:39:17 +01:00
"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
},
2020-08-19 21:46:29 +02:00
{
"name": "skip_validation",
"type": "bool",
"description": "Skip resolving comments to validate channel names",
"is_required": false
},
2019-11-20 16:39:17 +01:00
{
"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 }",
2020-01-04 02:23:40 +01:00
"examples": [
{
"title": "List all comments on a claim",
2021-03-04 06:02:42 +01:00
"curl": "curl -d'{\"method\": \"comment_list\", \"params\": {\"claim_id\": \"8e1d6b1b4aabe90269528e6cd09ec6e67086aa27\", \"include_replies\": true, \"skip_validation\": false, \"is_channel_signature_valid\": false, \"visible\": false, \"hidden\": false}}' http://localhost:5279/",
"lbrynet": "lbrynet comment list 8e1d6b1b4aabe90269528e6cd09ec6e67086aa27 --include_replies",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"comment_list\", \"params\": {\"claim_id\": \"8e1d6b1b4aabe90269528e6cd09ec6e67086aa27\", \"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\": \"b312a0c4eff10abe98542f99679ccddc20840daa\",\n \"channel_name\": \"@channel\",\n \"channel_url\": \"lbry://@channel#b312a0c4eff10abe98542f99679ccddc20840daa\",\n \"claim_id\": \"8e1d6b1b4aabe90269528e6cd09ec6e67086aa27\",\n \"comment\": \"I have photographic evidence confirming Sasquatch exists\",\n \"comment_id\": \"4cf468b7f4d57c97ccecc02a2834f6197141b365640a0df40062574748f601760c2046fa3b007ac7652b092ba4731e1c9bf77f116b531c25e809fc8a309dae98\",\n \"is_channel_signature_valid\": true,\n \"is_hidden\": false,\n \"is_pinned\": false,\n \"parent_id\": \"b88abe2cd021b3b6b2a705a09b0cc3a97f9c8a49008b3a1d5c435b0431ba62ab4658c0e2e5d47fb78147016cb2a4708de87ca27ee6b5657e042db085bcb9692c\",\n \"signature\": \"786e474fce43d6bb8714194f2e33e1f4fb79f2d8b7889572713b73fdd76b089aec78dfe310f440f59959ac0989c3f39a6a2d650aa1dd285667c49417cf10fda9\",\n \"signing_ts\": \"1614834138\",\n \"timestamp\": \"1614834138\"\n },\n {\n \"channel_id\": \"b312a0c4eff10abe98542f99679ccddc20840daa\",\n \"channel_name\": \"@channel\",\n \"channel_url\": \"lbry://@channel#b312a0c4eff10abe98542f99679ccddc20840daa\",\n \"claim_id\": \"8e1d6b1b4aabe90269528e6cd09ec6e67086aa27\",\n \"comment\": \"Thank you Based God\",\n \"comment_id\": \"b88abe2cd021b3b6b2a705a09b0cc3a97f9c8a49008b3a1d5c435b0431ba62ab4658c0e2e5d47fb78147016cb2a4708de87ca27ee6b5657e042db085bcb9692c\",\n \"is_channel_signature_valid\": true,\n \"is_hidden\": false,\n \"is_pinned\": false,\n \"signature\": \"c8abd66f333be477aae482d73ee7446f9249261b8278f48c0518f5e29726357aecaad62bb962c5c079de5f023586d7f93759ab8bdbaf4de4d888cfb601146fdd\",\n \"signing_ts\": \"1614834138\",\n \"timestamp\": \"1614834138\"\n }\n ],\n \"page\": 1,\n \"page_size\": 50,\n \"total_items\": 2,\n \"total_pages\": 1\n }\n}"
2020-01-04 02:23:40 +01:00
},
{
"title": "List a comment thread replying to a top level comment",
2021-03-04 06:02:42 +01:00
"curl": "curl -d'{\"method\": \"comment_list\", \"params\": {\"claim_id\": \"8e1d6b1b4aabe90269528e6cd09ec6e67086aa27\", \"parent_id\": \"b88abe2cd021b3b6b2a705a09b0cc3a97f9c8a49008b3a1d5c435b0431ba62ab4658c0e2e5d47fb78147016cb2a4708de87ca27ee6b5657e042db085bcb9692c\", \"include_replies\": false, \"skip_validation\": false, \"is_channel_signature_valid\": false, \"visible\": false, \"hidden\": false}}' http://localhost:5279/",
"lbrynet": "lbrynet comment list 8e1d6b1b4aabe90269528e6cd09ec6e67086aa27 --parent_id=b88abe2cd021b3b6b2a705a09b0cc3a97f9c8a49008b3a1d5c435b0431ba62ab4658c0e2e5d47fb78147016cb2a4708de87ca27ee6b5657e042db085bcb9692c",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"comment_list\", \"params\": {\"claim_id\": \"8e1d6b1b4aabe90269528e6cd09ec6e67086aa27\", \"parent_id\": \"b88abe2cd021b3b6b2a705a09b0cc3a97f9c8a49008b3a1d5c435b0431ba62ab4658c0e2e5d47fb78147016cb2a4708de87ca27ee6b5657e042db085bcb9692c\", \"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 \"items\": [\n {\n \"channel_id\": \"b312a0c4eff10abe98542f99679ccddc20840daa\",\n \"channel_name\": \"@channel\",\n \"channel_url\": \"lbry://@channel#b312a0c4eff10abe98542f99679ccddc20840daa\",\n \"claim_id\": \"8e1d6b1b4aabe90269528e6cd09ec6e67086aa27\",\n \"comment\": \"I have photographic evidence confirming Sasquatch exists\",\n \"comment_id\": \"4cf468b7f4d57c97ccecc02a2834f6197141b365640a0df40062574748f601760c2046fa3b007ac7652b092ba4731e1c9bf77f116b531c25e809fc8a309dae98\",\n \"is_channel_signature_valid\": true,\n \"is_hidden\": false,\n \"is_pinned\": false,\n \"parent_id\": \"b88abe2cd021b3b6b2a705a09b0cc3a97f9c8a49008b3a1d5c435b0431ba62ab4658c0e2e5d47fb78147016cb2a4708de87ca27ee6b5657e042db085bcb9692c\",\n \"signature\": \"786e474fce43d6bb8714194f2e33e1f4fb79f2d8b7889572713b73fdd76b089aec78dfe310f440f59959ac0989c3f39a6a2d650aa1dd285667c49417cf10fda9\",\n \"signing_ts\": \"1614834138\",\n \"timestamp\": \"1614834138\"\n },\n {\n \"channel_id\": \"b312a0c4eff10abe98542f99679ccddc20840daa\",\n \"channel_name\": \"@channel\",\n \"channel_url\": \"lbry://@channel#b312a0c4eff10abe98542f99679ccddc20840daa\",\n \"claim_id\": \"8e1d6b1b4aabe90269528e6cd09ec6e67086aa27\",\n \"comment\": \"Thank you Based God\",\n \"comment_id\": \"b88abe2cd021b3b6b2a705a09b0cc3a97f9c8a49008b3a1d5c435b0431ba62ab4658c0e2e5d47fb78147016cb2a4708de87ca27ee6b5657e042db085bcb9692c\",\n \"is_channel_signature_valid\": true,\n \"is_hidden\": false,\n \"is_pinned\": false,\n \"signature\": \"c8abd66f333be477aae482d73ee7446f9249261b8278f48c0518f5e29726357aecaad62bb962c5c079de5f023586d7f93759ab8bdbaf4de4d888cfb601146fdd\",\n \"signing_ts\": \"1614834138\",\n \"timestamp\": \"1614834138\"\n }\n ],\n \"page\": 1,\n \"page_size\": 50,\n \"total_items\": 2,\n \"total_pages\": 1\n }\n}"
2020-01-19 03:23:38 +01:00
}
]
},
2020-10-10 18:26:26 +02:00
{
"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": []
},
2020-01-19 03:23:38 +01:00
{
"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
}
],
2020-10-10 18:26:26 +02:00
"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 }",
2020-01-19 03:23:38 +01:00
"examples": [
{
"title": "Edit the contents of a comment",
2021-03-04 06:02:42 +01:00
"curl": "curl -d'{\"method\": \"comment_update\", \"params\": {\"comment\": \"Where there was once sasquatch, there is not\", \"comment_id\": \"b88abe2cd021b3b6b2a705a09b0cc3a97f9c8a49008b3a1d5c435b0431ba62ab4658c0e2e5d47fb78147016cb2a4708de87ca27ee6b5657e042db085bcb9692c\"}}' http://localhost:5279/",
"lbrynet": "lbrynet comment update Where there was once sasquatch, there is not --comment_id=b88abe2cd021b3b6b2a705a09b0cc3a97f9c8a49008b3a1d5c435b0431ba62ab4658c0e2e5d47fb78147016cb2a4708de87ca27ee6b5657e042db085bcb9692c",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"comment_update\", \"params\": {\"comment\": \"Where there was once sasquatch, there is not\", \"comment_id\": \"b88abe2cd021b3b6b2a705a09b0cc3a97f9c8a49008b3a1d5c435b0431ba62ab4658c0e2e5d47fb78147016cb2a4708de87ca27ee6b5657e042db085bcb9692c\"}}).json()",
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"channel_id\": \"b312a0c4eff10abe98542f99679ccddc20840daa\",\n \"channel_name\": \"@channel\",\n \"channel_url\": \"lbry://@channel#b312a0c4eff10abe98542f99679ccddc20840daa\",\n \"claim_id\": \"8e1d6b1b4aabe90269528e6cd09ec6e67086aa27\",\n \"comment\": \"Where there was once sasquatch, there is not\",\n \"comment_id\": \"b88abe2cd021b3b6b2a705a09b0cc3a97f9c8a49008b3a1d5c435b0431ba62ab4658c0e2e5d47fb78147016cb2a4708de87ca27ee6b5657e042db085bcb9692c\",\n \"is_hidden\": false,\n \"is_pinned\": false,\n \"parent_id\": null,\n \"signature\": \"922e62510909966535c0234cc3c0b03e2d72c6867333bfce300ff785b40695f82502b033b162504b9d8adb20303472012724439849228cb0ad2927422428797e\",\n \"signing_ts\": \"1614834138\",\n \"timestamp\": \"1614834138\"\n }\n}"
2020-01-04 02:23:40 +01:00
}
]
2019-11-20 16:39:17 +01:00
}
]
},
"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",
2021-03-04 06:02:42 +01:00
"curl": "curl -d'{\"method\": \"file_delete\", \"params\": {\"delete_from_download_dir\": false, \"delete_all\": false, \"claim_id\": \"8e1d6b1b4aabe90269528e6cd09ec6e67086aa27\"}}' http://localhost:5279/",
"lbrynet": "lbrynet file delete --claim_id=\"8e1d6b1b4aabe90269528e6cd09ec6e67086aa27\"",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"file_delete\", \"params\": {\"delete_from_download_dir\": false, \"delete_all\": false, \"claim_id\": \"8e1d6b1b4aabe90269528e6cd09ec6e67086aa27\"}}).json()",
2019-11-20 16:39:17 +01:00
"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",
2019-04-11 21:35:24 +02:00
"is_required": false
},
{
"name": "claim_id",
"type": "str",
2020-08-19 21:46:29 +02:00
"description": "get file with matching claim id(s)",
2019-04-11 21:35:24 +02:00
"is_required": false
},
{
"name": "outpoint",
"type": "str",
2020-08-19 21:46:29 +02:00
"description": "get file with matching claim outpoint(s)",
2019-04-11 21:35:24 +02:00
"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",
2020-08-19 21:46:29 +02:00
"description": "get file with matching channel claim id(s)",
2019-04-11 21:35:24 +02:00
"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
},
2020-08-19 21:46:29 +02:00
{
"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
},
2019-04-11 21:35:24 +02:00
{
"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",
2020-08-19 21:46:29 +02:00
"description": "logical comparison, (eq | ne | g | ge | l | le | in)",
2019-04-11 21:35:24 +02:00
"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
2019-11-20 16:39:17 +01:00
},
{
"name": "wallet_id",
"type": "str",
"description": "add purchase receipts from this wallet",
"is_required": false
2019-04-11 21:35:24 +02:00
}
],
2020-08-19 21:46:29 +02:00
"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 }",
2019-04-12 14:58:00 +02:00
"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()",
2021-03-04 06:02:42 +01:00
"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\": \"b312a0c4eff10abe98542f99679ccddc20840daa\",\n \"channel_name\": \"@channel\",\n \"claim_id\": \"8e1d6b1b4aabe90269528e6cd09ec6e67086aa27\",\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\": \"cd4485fae55b2147206733882971405a\",\n \"metadata\": {\n \"source\": {\n \"hash\": \"fdbd8e75a67f29f701a4e040385e2e23986303ea10239211af907fcbb83578b3e417cb71ce646efd0819dd8c088de1bd\",\n \"media_type\": \"application/octet-stream\",\n \"name\": \"tmpuyu0q8tj\",\n \"sd_hash\": \"3da9fe6b3aee199c40a6307f293f9006690cc8bbe1c30dca591e7d09f39ec7d3a3443cb526f95da4f9b94915ec511f6d\",\n \"size\": \"11\"\n },\n \"stream_type\": \"binary\"\n },\n \"mime_type\": \"application/octet-stream\",\n \"nout\": 0,\n \"outpoint\": \"040def12329d3b9002595f77a3bb87fd43f9c603595f0c7da3fa92582efde10d:0\",\n \"points_paid\": 0.0,\n \"protobuf\": \"01aa0d8420dccd9c67992f5498be0af1efc4a012b337f1ca30a5844b95623ce944a8279839e5111bc041faf55de4cd6452e2ff25ea6ad84a1e3c478596408f4342829ffaa690073dfbdf024eb5b4c12c2509ad72980a90010a8d010a30fdbd8e75a67f29f701a4e040385e2e23986303ea10239211af907fcbb83578b3e417cb71ce646efd0819dd8c088de1bd120b746d70757975307138746a180b22186170706c69636174696f6e2f6f637465742d73747265616d32303da9fe6b3aee199c40a6307f293f9006690cc8bbe1c30dca591e7d09f39ec7d3a3443cb526f95da4f9b94915ec511f6d\",\n \"purchase_receipt\": null,\n \"reflector_progress\": 100,\n \"sd_hash\": \"3da9fe6b3aee199c40a6307f293f9006690cc8bbe1c30dca591e7d09f39ec7d3a3443cb526f95da4f9b94915ec511f6d\",\n \"status\": \"finished\",\n \"stopped\": true,\n \"stream_hash\": \"ed940f9a26c786d7a10f006354ac7d0f29772269bd752ce9b6b3681647581d5bd74c89a48e48ca5277eae641b1088239\",\n \"stream_name\": \"tmpuyu0q8tj\",\n \"streaming_url\": \"http://localhost:5280/stream/3da9fe6b3aee199c40a6307f293f9006690cc8bbe1c30dca591e7d09f39ec7d3a3443cb526f95da4f9b94915ec511f6d\",\n \"suggested_file_name\": \"tmpuyu0q8tj\",\n \"timestamp\": null,\n \"total_bytes\": 16,\n \"total_bytes_lower_bound\": 0,\n \"txid\": \"040def12329d3b9002595f77a3bb87fd43f9c603595f0c7da3fa92582efde10d\",\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\": \"b312a0c4eff10abe98542f99679ccddc20840daa\",\n \"channel_name\": \"@channel\",\n \"claim_id\": \"d0c162f216e4e566d6da93a28ad4e23a78bcea87\",\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\": \"7a49ee69a28aa0865fb8952469bd8cbf\",\n \"metadata\": {\n \"author\": \"Picaso\",\n \"description\": \"A blank PNG that is 5x7.\",\n \"fee\": {\n \"address\": \"myvqTjDz7Jo3mqvnPN5BQ5ACeffyPGzS9u\",\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://pub
2019-04-12 14:58:00 +02:00
},
{
"title": "List files matching a parameter",
2021-03-04 06:02:42 +01:00
"curl": "curl -d'{\"method\": \"file_list\", \"params\": {\"claim_id\": \"8e1d6b1b4aabe90269528e6cd09ec6e67086aa27\", \"reverse\": false}}' http://localhost:5279/",
"lbrynet": "lbrynet file list --claim_id=\"8e1d6b1b4aabe90269528e6cd09ec6e67086aa27\"",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"file_list\", \"params\": {\"claim_id\": \"8e1d6b1b4aabe90269528e6cd09ec6e67086aa27\", \"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\": \"b312a0c4eff10abe98542f99679ccddc20840daa\",\n \"channel_name\": \"@channel\",\n \"claim_id\": \"8e1d6b1b4aabe90269528e6cd09ec6e67086aa27\",\n \"claim_name\": \"astream\",\n \"completed\": true,\n \"confirmations\": 4,\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\": \"cd4485fae55b2147206733882971405a\",\n \"metadata\": {\n \"source\": {\n \"hash\": \"fdbd8e75a67f29f701a4e040385e2e23986303ea10239211af907fcbb83578b3e417cb71ce646efd0819dd8c088de1bd\",\n \"media_type\": \"application/octet-stream\",\n \"name\": \"tmpuyu0q8tj\",\n \"sd_hash\": \"3da9fe6b3aee199c40a6307f293f9006690cc8bbe1c30dca591e7d09f39ec7d3a3443cb526f95da4f9b94915ec511f6d\",\n \"size\": \"11\"\n },\n \"stream_type\": \"binary\"\n },\n \"mime_type\": \"application/octet-stream\",\n \"nout\": 0,\n \"outpoint\": \"040def12329d3b9002595f77a3bb87fd43f9c603595f0c7da3fa92582efde10d:0\",\n \"points_paid\": 0.0,\n \"protobuf\": \"01aa0d8420dccd9c67992f5498be0af1efc4a012b337f1ca30a5844b95623ce944a8279839e5111bc041faf55de4cd6452e2ff25ea6ad84a1e3c478596408f4342829ffaa690073dfbdf024eb5b4c12c2509ad72980a90010a8d010a30fdbd8e75a67f29f701a4e040385e2e23986303ea10239211af907fcbb83578b3e417cb71ce646efd0819dd8c088de1bd120b746d70757975307138746a180b22186170706c69636174696f6e2f6f637465742d73747265616d32303da9fe6b3aee199c40a6307f293f9006690cc8bbe1c30dca591e7d09f39ec7d3a3443cb526f95da4f9b94915ec511f6d\",\n \"purchase_receipt\": null,\n \"reflector_progress\": 100,\n \"sd_hash\": \"3da9fe6b3aee199c40a6307f293f9006690cc8bbe1c30dca591e7d09f39ec7d3a3443cb526f95da4f9b94915ec511f6d\",\n \"status\": \"finished\",\n \"stopped\": true,\n \"stream_hash\": \"ed940f9a26c786d7a10f006354ac7d0f29772269bd752ce9b6b3681647581d5bd74c89a48e48ca5277eae641b1088239\",\n \"stream_name\": \"tmpuyu0q8tj\",\n \"streaming_url\": \"http://localhost:5280/stream/3da9fe6b3aee199c40a6307f293f9006690cc8bbe1c30dca591e7d09f39ec7d3a3443cb526f95da4f9b94915ec511f6d\",\n \"suggested_file_name\": \"tmpuyu0q8tj\",\n \"timestamp\": 1614834157,\n \"total_bytes\": 16,\n \"total_bytes_lower_bound\": 0,\n \"txid\": \"040def12329d3b9002595f77a3bb87fd43f9c603595f0c7da3fa92582efde10d\",\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}"
2019-04-12 14:58:00 +02:00
}
]
2019-04-11 21:35:24 +02:00
},
{
"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": []
},
2019-04-25 05:03:30 +02:00
{
"name": "file_save",
2019-05-17 19:06:59 +02:00
"description": "Start saving a file to disk.",
2019-04-25 05:03:30 +02:00
"arguments": [
{
"name": "file_name",
"type": "str",
2019-05-17 19:06:59 +02:00
"description": "file name to save to",
2019-04-25 05:03:30 +02:00
"is_required": false
},
{
"name": "download_directory",
"type": "str",
2019-05-17 19:06:59 +02:00
"description": "directory to save into",
2019-04-25 05:03:30 +02:00
"is_required": false
},
{
"name": "sd_hash",
"type": "str",
2019-05-17 19:06:59 +02:00
"description": "save file with matching sd hash",
2019-04-25 05:03:30 +02:00
"is_required": false
},
{
"name": "stream_hash",
"type": "str",
2019-05-17 19:06:59 +02:00
"description": "save file with matching stream hash",
2019-04-25 05:03:30 +02:00
"is_required": false
},
{
"name": "rowid",
"type": "int",
2019-05-17 19:06:59 +02:00
"description": "save file with matching row id",
2019-04-25 05:03:30 +02:00
"is_required": false
},
{
"name": "claim_id",
"type": "str",
2019-05-17 19:06:59 +02:00
"description": "save file with matching claim id",
2019-04-25 05:03:30 +02:00
"is_required": false
},
{
"name": "txid",
"type": "str",
2019-05-17 19:06:59 +02:00
"description": "save file with matching claim txid",
2019-04-25 05:03:30 +02:00
"is_required": false
},
{
"name": "nout",
"type": "int",
2019-05-17 19:06:59 +02:00
"description": "save file with matching claim nout",
2019-04-25 05:03:30 +02:00
"is_required": false
},
{
"name": "claim_name",
"type": "str",
2019-05-17 19:06:59 +02:00
"description": "save file with matching claim name",
2019-04-25 05:03:30 +02:00
"is_required": false
},
{
"name": "channel_claim_id",
"type": "str",
2019-05-17 19:06:59 +02:00
"description": "save file with matching channel claim id",
2019-04-25 05:03:30 +02:00
"is_required": false
},
{
"name": "channel_name",
"type": "str",
2019-05-17 19:06:59 +02:00
"description": "save file with matching channel claim name",
2019-04-25 05:03:30 +02:00
"is_required": false
}
],
2020-08-19 21:46:29 +02:00
"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 }",
2019-04-25 05:03:30 +02:00
"examples": [
{
"title": "Save a file to the downloads directory",
2021-03-04 06:02:42 +01:00
"curl": "curl -d'{\"method\": \"file_save\", \"params\": {\"sd_hash\": \"3da9fe6b3aee199c40a6307f293f9006690cc8bbe1c30dca591e7d09f39ec7d3a3443cb526f95da4f9b94915ec511f6d\"}}' http://localhost:5279/",
"lbrynet": "lbrynet file save --sd_hash=\"3da9fe6b3aee199c40a6307f293f9006690cc8bbe1c30dca591e7d09f39ec7d3a3443cb526f95da4f9b94915ec511f6d\"",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"file_save\", \"params\": {\"sd_hash\": \"3da9fe6b3aee199c40a6307f293f9006690cc8bbe1c30dca591e7d09f39ec7d3a3443cb526f95da4f9b94915ec511f6d\"}}).json()",
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"added_on\": 1614834139,\n \"blobs_completed\": 1,\n \"blobs_in_stream\": 1,\n \"blobs_remaining\": 0,\n \"channel_claim_id\": \"b312a0c4eff10abe98542f99679ccddc20840daa\",\n \"channel_name\": \"@channel\",\n \"claim_id\": \"8e1d6b1b4aabe90269528e6cd09ec6e67086aa27\",\n \"claim_name\": \"astream\",\n \"completed\": true,\n \"confirmations\": 4,\n \"content_fee\": null,\n \"download_directory\": \"/tmp/tmperer8uup\",\n \"download_path\": \"/tmp/tmperer8uup/tmpuyu0q8tj_1\",\n \"file_name\": \"tmpuyu0q8tj_1\",\n \"height\": 214,\n \"is_fully_reflected\": false,\n \"key\": \"cd4485fae55b2147206733882971405a\",\n \"metadata\": {\n \"source\": {\n \"hash\": \"fdbd8e75a67f29f701a4e040385e2e23986303ea10239211af907fcbb83578b3e417cb71ce646efd0819dd8c088de1bd\",\n \"media_type\": \"application/octet-stream\",\n \"name\": \"tmpuyu0q8tj\",\n \"sd_hash\": \"3da9fe6b3aee199c40a6307f293f9006690cc8bbe1c30dca591e7d09f39ec7d3a3443cb526f95da4f9b94915ec511f6d\",\n \"size\": \"11\"\n },\n \"stream_type\": \"binary\"\n },\n \"mime_type\": \"application/octet-stream\",\n \"nout\": 0,\n \"outpoint\": \"040def12329d3b9002595f77a3bb87fd43f9c603595f0c7da3fa92582efde10d:0\",\n \"points_paid\": 0.0,\n \"protobuf\": \"01aa0d8420dccd9c67992f5498be0af1efc4a012b337f1ca30a5844b95623ce944a8279839e5111bc041faf55de4cd6452e2ff25ea6ad84a1e3c478596408f4342829ffaa690073dfbdf024eb5b4c12c2509ad72980a90010a8d010a30fdbd8e75a67f29f701a4e040385e2e23986303ea10239211af907fcbb83578b3e417cb71ce646efd0819dd8c088de1bd120b746d70757975307138746a180b22186170706c69636174696f6e2f6f637465742d73747265616d32303da9fe6b3aee199c40a6307f293f9006690cc8bbe1c30dca591e7d09f39ec7d3a3443cb526f95da4f9b94915ec511f6d\",\n \"purchase_receipt\": null,\n \"reflector_progress\": 0,\n \"sd_hash\": \"3da9fe6b3aee199c40a6307f293f9006690cc8bbe1c30dca591e7d09f39ec7d3a3443cb526f95da4f9b94915ec511f6d\",\n \"status\": \"finished\",\n \"stopped\": true,\n \"stream_hash\": \"ed940f9a26c786d7a10f006354ac7d0f29772269bd752ce9b6b3681647581d5bd74c89a48e48ca5277eae641b1088239\",\n \"stream_name\": \"tmpuyu0q8tj\",\n \"streaming_url\": \"http://localhost:5280/stream/3da9fe6b3aee199c40a6307f293f9006690cc8bbe1c30dca591e7d09f39ec7d3a3443cb526f95da4f9b94915ec511f6d\",\n \"suggested_file_name\": \"tmpuyu0q8tj\",\n \"timestamp\": 1614834157,\n \"total_bytes\": 16,\n \"total_bytes_lower_bound\": 0,\n \"txid\": \"040def12329d3b9002595f77a3bb87fd43f9c603595f0c7da3fa92582efde10d\",\n \"uploading_to_reflector\": false,\n \"written_bytes\": 11\n }\n}"
2019-04-25 05:03:30 +02:00
}
]
},
2019-04-11 21:35:24 +02:00
{
"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": []
}
2019-04-11 21:35:24 +02:00
]
},
2019-04-11 21:35:24 +02:00
"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
2019-10-26 05:46:24 +02:00
},
{
"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
2019-04-11 21:35:24 +02:00
}
],
"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": []
2019-04-06 21:33:19 +02:00
}
]
},
2019-09-03 17:30:10 +02:00
"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
},
2019-09-20 15:43:58 +02:00
{
"name": "wallet_id",
"type": "str",
"description": "restrict operation to specific wallet",
"is_required": false
2019-09-03 17:30:10 +02:00
}
],
"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
},
2019-09-20 15:43:58 +02:00
{
"name": "wallet_id",
"type": "str",
"description": "restrict operation to specific wallet",
"is_required": false
2019-09-03 17:30:10 +02:00
}
],
"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}"
}
]
}
]
},
2019-11-20 16:39:17 +01:00
"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
}
],
2020-03-22 01:15:21 +01:00
"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 prot
2019-11-20 16:39:17 +01:00
"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
}
],
2020-03-22 01:15:21 +01:00
"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 }",
2019-11-20 16:39:17 +01:00
"examples": []
}
]
},
2019-04-11 21:35:24 +02:00
"settings": {
"doc": "Settings management.",
"commands": [
2020-01-04 02:23:40 +01:00
{
"name": "settings_clear",
"description": "Clear daemon settings",
"arguments": [],
"returns": "(dict) Updated dictionary of daemon settings",
"examples": []
},
2019-04-06 21:33:19 +02:00
{
2019-04-11 21:35:24 +02:00
"name": "settings_get",
"description": "Get daemon settings",
"arguments": [],
2019-06-25 21:34:32 +02:00
"returns": "(dict) Dictionary of daemon settings\n See ADJUSTABLE_SETTINGS in lbry/conf.py for full list of settings",
2019-04-12 14:58:00 +02:00
"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()",
2021-03-04 06:02:42 +01:00
"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\": \"http://localhost:2903/api\",\n \"components_to_skip\": [\n \"dht\",\n \"upnp\",\n \"hash_announcer\",\n \"peer_protocol_server\",\n \"libtorrent_component\"\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/tmperer8uup\",\n \"download_dir\": \"/tmp/tmperer8uup\",\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\": 10000,\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/tmperer8uup\",\n \"wallets\": [\n \"default_wallet\"\n ]\n }\n}"
2019-04-12 14:58:00 +02:00
}
]
2019-04-06 21:33:19 +02:00
},
{
2019-04-11 21:35:24 +02:00
"name": "settings_set",
"description": "Set daemon settings",
"arguments": [],
"returns": "(dict) Updated dictionary of daemon settings",
2019-09-03 17:30:10 +02:00
"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}"
}
]
2019-01-21 23:37:56 +01:00
}
]
},
2019-04-11 21:35:24 +02:00
"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
},
2019-09-20 15:43:58 +02:00
{
"name": "wallet_id",
"type": "str",
"description": "restrict operation to specific wallet",
"is_required": false
},
2019-04-11 21:35:24 +02:00
{
"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
}
],
2020-03-22 01:15:21 +01:00
"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 prot
2019-04-11 21:35:24 +02:00
"examples": [
{
2019-04-12 14:58:00 +02:00
"title": "Abandon a stream claim",
2021-03-04 06:02:42 +01:00
"curl": "curl -d'{\"method\": \"stream_abandon\", \"params\": {\"claim_id\": \"8e1d6b1b4aabe90269528e6cd09ec6e67086aa27\", \"preview\": false, \"blocking\": false}}' http://localhost:5279/",
"lbrynet": "lbrynet stream abandon 8e1d6b1b4aabe90269528e6cd09ec6e67086aa27",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"stream_abandon\", \"params\": {\"claim_id\": \"8e1d6b1b4aabe90269528e6cd09ec6e67086aa27\", \"preview\": false, \"blocking\": false}}).json()",
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"height\": -2,\n \"hex\": \"01000000010de1fd2e5892faa37d0c5f5903c6f943fd87bba3775f5902903b9d3212ef0d04000000006b483045022100e1b1f63c175bf93381a04301c6c05371963ffe291b1bc66cbb234a2dcdfdd58f02203e0b68aeea4fba142f46481bd6e34ff8f2cef7dba289a6fd442c75e4706c412a01210273e915853a992843ce866bb86542bbd8f6bf2a6cd7bd1b40fcc62ebdca3d1033ffffffff0134b7f505000000001976a9145d7218d936e2ee9cd7f6c4e325ec724ef5580af388ac00000000\",\n \"inputs\": [\n {\n \"address\": \"n4fHJYFChC7a9V7M9BjLsnyzsMj4p821u2\",\n \"amount\": \"1.0\",\n \"claim_id\": \"8e1d6b1b4aabe90269528e6cd09ec6e67086aa27\",\n \"claim_op\": \"update\",\n \"confirmations\": 4,\n \"height\": 214,\n \"meta\": {},\n \"name\": \"astream\",\n \"normalized_name\": \"astream\",\n \"nout\": 0,\n \"permanent_url\": \"lbry://astream#8e1d6b1b4aabe90269528e6cd09ec6e67086aa27\",\n \"timestamp\": 1614834157,\n \"txid\": \"040def12329d3b9002595f77a3bb87fd43f9c603595f0c7da3fa92582efde10d\",\n \"type\": \"claim\",\n \"value\": {\n \"source\": {\n \"hash\": \"fdbd8e75a67f29f701a4e040385e2e23986303ea10239211af907fcbb83578b3e417cb71ce646efd0819dd8c088de1bd\",\n \"media_type\": \"application/octet-stream\",\n \"name\": \"tmpuyu0q8tj\",\n \"sd_hash\": \"3da9fe6b3aee199c40a6307f293f9006690cc8bbe1c30dca591e7d09f39ec7d3a3443cb526f95da4f9b94915ec511f6d\",\n \"size\": \"11\"\n },\n \"stream_type\": \"binary\"\n },\n \"value_type\": \"stream\"\n }\n ],\n \"outputs\": [\n {\n \"address\": \"mp33pVo4NnGZL3jxMMrKj1SEiVcRuRjEhz\",\n \"amount\": \"0.999893\",\n \"confirmations\": -2,\n \"height\": -2,\n \"nout\": 0,\n \"timestamp\": null,\n \"txid\": \"fa517763eee137e5c11d8c0364fb16ec493f1bd447bff721dc768ca71af6062f\",\n \"type\": \"payment\"\n }\n ],\n \"total_fee\": \"0.000107\",\n \"total_input\": \"1.0\",\n \"total_output\": \"0.999893\",\n \"txid\": \"fa517763eee137e5c11d8c0364fb16ec493f1bd447bff721dc768ca71af6062f\"\n }\n}"
2019-04-11 21:35:24 +02:00
}
]
},
{
"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
},
2020-02-04 04:30:39 +01:00
{
"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
},
2019-04-27 19:13:20 +02:00
{
"name": "allow_duplicate_name",
"type": "bool",
"description": "create new claim even if one already exists with given name. default: false.",
"is_required": false
},
2019-04-11 21:35:24 +02:00
{
"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
},
{
2019-04-21 05:56:40 +02:00
"name": "width",
2019-04-11 21:35:24 +02:00
"type": "int",
2019-04-21 05:56:40 +02:00
"description": "image/video width, automatically calculated from media file",
2019-04-11 21:35:24 +02:00
"is_required": false
},
{
2019-04-21 05:56:40 +02:00
"name": "height",
2019-04-11 21:35:24 +02:00
"type": "int",
2019-04-21 05:56:40 +02:00
"description": "image/video height, automatically calculated from media file",
2019-04-11 21:35:24 +02:00
"is_required": false
},
{
2019-04-21 05:56:40 +02:00
"name": "duration",
2019-04-11 21:35:24 +02:00
"type": "int",
2019-04-21 05:56:40 +02:00
"description": "audio/video duration in seconds, automatically calculated",
2019-04-11 21:35:24 +02:00
"is_required": false
},
{
"name": "channel_id",
"type": "str",
"description": "claim id of the publisher channel",
"is_required": false
},
2019-04-27 19:13:20 +02:00
{
"name": "channel_name",
"type": "str",
"description": "name of the publisher channel",
"is_required": false
},
2019-04-11 21:35:24 +02:00
{
"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",
2019-08-12 07:26:42 +02:00
"description": "account to use for holding the transaction",
"is_required": false
},
2019-09-20 15:43:58 +02:00
{
"name": "wallet_id",
"type": "str",
"description": "restrict operation to specific wallet",
"is_required": false
},
2019-08-12 07:26:42 +02:00
{
"name": "funding_account_ids",
"type": "list",
"description": "ids of accounts to fund this transaction",
2019-04-11 21:35:24 +02:00
"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
2019-06-25 21:34:32 +02:00
},
{
"name": "blocking",
"type": "bool",
"description": "wait until transaction is in mempool",
"is_required": false
2019-04-11 21:35:24 +02:00
}
],
2020-03-22 01:15:21 +01:00
"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 prot
2019-04-11 21:35:24 +02:00
"examples": [
{
"title": "Create a stream claim without metadata",
2021-03-04 06:02:42 +01:00
"curl": "curl -d'{\"method\": \"stream_create\", \"params\": {\"name\": \"astream\", \"bid\": \"1.0\", \"file_path\": \"/tmp/tmpuyu0q8tj\", \"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/tmpuyu0q8tj",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"stream_create\", \"params\": {\"name\": \"astream\", \"bid\": \"1.0\", \"file_path\": \"/tmp/tmpuyu0q8tj\", \"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\": \"01000000016f9684b064899e8a3206c9c7f85ec37806bbb389b3a982a9b2a74b3673c6aa26010000006b483045022100d289c3b75efaadb927c7251507ae39acea229e88c7665544a4432dc065042b08022045c2ad4d19d59cb53ada7647a1b246bce78827cda797518e38e15208f91d7ff601210216a1734dcbf7cee620b631571e8c7b9529d6e1f89608538f4c56927b8904214fffffffff0200e1f50500000000bab5076173747265616d4c94000a90010a8d010a30fdbd8e75a67f29f701a4e040385e2e23986303ea10239211af907fcbb83578b3e417cb71ce646efd0819dd8c088de1bd120b746d70757975307138746a180b22186170706c69636174696f6e2f6f637465742d73747265616d32303da9fe6b3aee199c40a6307f293f9006690cc8bbe1c30dca591e7d09f39ec7d3a3443cb526f95da4f9b94915ec511f6d6d7576a914fdde168e6017209da83a477c5a85acfded0a69c588ac38fb9423000000001976a914d8fbf8a1a258e53d180240a8f3161d4b92a06ecc88ac00000000\",\n \"inputs\": [\n {\n \"address\": \"mtEiDQqYaxPYPj5HBwxUrEoFMYK8aAQBgy\",\n \"amount\": \"6.983769\",\n \"confirmations\": 4,\n \"height\": 209,\n \"nout\": 1,\n \"timestamp\": 1614834156,\n \"txid\": \"26aac673364ba7b2a982a9b389b3bb0678c35ef8c7c906328a9e8964b084966f\",\n \"type\": \"payment\"\n }\n ],\n \"outputs\": [\n {\n \"address\": \"n4fHJYFChC7a9V7M9BjLsnyzsMj4p821u2\",\n \"amount\": \"1.0\",\n \"claim_id\": \"8e1d6b1b4aabe90269528e6cd09ec6e67086aa27\",\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#8e1d6b1b4aabe90269528e6cd09ec6e67086aa27\",\n \"timestamp\": null,\n \"txid\": \"86099bb8ccfa3045ce91b915e9f9af3ad4f490cacc8bb4883ff2f44f558034a3\",\n \"type\": \"claim\",\n \"value\": {\n \"source\": {\n \"hash\": \"fdbd8e75a67f29f701a4e040385e2e23986303ea10239211af907fcbb83578b3e417cb71ce646efd0819dd8c088de1bd\",\n \"media_type\": \"application/octet-stream\",\n \"name\": \"tmpuyu0q8tj\",\n \"sd_hash\": \"3da9fe6b3aee199c40a6307f293f9006690cc8bbe1c30dca591e7d09f39ec7d3a3443cb526f95da4f9b94915ec511f6d\",\n \"size\": \"11\"\n },\n \"stream_type\": \"binary\"\n },\n \"value_type\": \"stream\"\n },\n {\n \"address\": \"n1JG6kpsUC8Ya9KakL9vNSt9HqyrieVRBW\",\n \"amount\": \"5.969662\",\n \"confirmations\": -2,\n \"height\": -2,\n \"nout\": 1,\n \"timestamp\": null,\n \"txid\": \"86099bb8ccfa3045ce91b915e9f9af3ad4f490cacc8bb4883ff2f44f558034a3\",\n \"type\": \"payment\"\n }\n ],\n \"total_fee\": \"0.014107\",\n \"total_input\": \"6.983769\",\n \"total_output\": \"6.969662\",\n \"txid\": \"86099bb8ccfa3045ce91b915e9f9af3ad4f490cacc8bb4883ff2f44f558034a3\"\n }\n}"
},
{
"title": "Create an image stream claim with all metadata and fee",
2021-03-04 06:02:42 +01:00
"curl": "curl -d'{\"method\": \"stream_create\", \"params\": {\"name\": \"blank-image\", \"bid\": \"1.0\", \"file_path\": \"/tmp/tmpjfjb7uyw.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\": 1614834136, \"channel_id\": \"b312a0c4eff10abe98542f99679ccddc20840daa\", \"channel_account_id\": [], \"funding_account_ids\": [], \"preview\": false, \"blocking\": false}}' http://localhost:5279/",
"lbrynet": "lbrynet stream create blank-image 1.0 /tmp/tmpjfjb7uyw.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=1614834136 --channel_id=\"b312a0c4eff10abe98542f99679ccddc20840daa\"",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"stream_create\", \"params\": {\"name\": \"blank-image\", \"bid\": \"1.0\", \"file_path\": \"/tmp/tmpjfjb7uyw.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\": 1614834136, \"channel_id\": \"b312a0c4eff10abe98542f99679ccddc20840daa\", \"channel_account_id\": [], \"funding_account_ids\": [], \"preview\": false, \"blocking\": false}}).json()",
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"height\": -2,\n \"hex\": \"0100000001a33480554ff4f23f88b48bccca90f4d43aaff9e915b991ce4530faccb89b0986010000006b483045022100de562ecf4e83ba2a48430f0cbfe9e66c5d047aa64499612847e1731894fcbe9b02205dcb6e7ebd3ed5f63468caa31af35d7a6509227ab78058972d45d1f9a8aaa4bf012102556e36a4e5efc6a2e4c0dd14c81ef9d6cfbde7b062fb9b028447fa972c99741fffffffff0200e1f50500000000fddc01b50b626c616e6b2d696d6167654db10101aa0d8420dccd9c67992f5498be0af1efc4a012b3d3deecf6132538bbb1c4105b234d5cb728cf1e54c46f10a89d4eb3a7ca3607b24577bab39ef883697da1eb10afccdf5b6290f05388142bb7523729eea7d2fdad0ae6010a82010a306c7df435d412c603390f593ef658c199817c7830ba3f16b7eadd8f99fa50e85dbd0d2b3dc61eadc33fe096e3872d1545120f746d706a666a62377579772e706e6718632209696d6167652f706e673230311cd51592acc28ad9e7026da4a4969f70d403a70d5974ab94cdaacbbe50a0a48036e3431e52134857f822a49de4196d120650696361736f1a0d5075626c696320446f6d61696e2218687474703a2f2f7075626c69632d646f6d61696e2e6f726728d8d38182063222080112196fc9f68b0a781c37ee7a44bdb607c85b0c2321b0703e1a8620188087a70e520408051007420b426c616e6b20496d6167654a184120626c616e6b20504e472074686174206973203578372e52252a23687474703a2f2f736d616c6c6d656469612e636f6d2f7468756d626e61696c2e6a70675a05626c616e6b5a03617274620208016a1308ec0112024e481a0a4d616e636865737465726d7576a914c9f68b0a781c37ee7a44bdb607c85b0c2321b07088acac5e7d1d000000001976a914a6e278d2550bbb14201c9b3463eee659fff89fbd88ac00000000\",\n \"inputs\": [\n {\n \"address\": \"n1JG6kpsUC8Ya9KakL9vNSt9HqyrieVRBW\",\n \"amount\": \"5.969662\",\n \"confirmations\": 2,\n \"height\": 213,\n \"nout\": 1,\n \"timestamp\": 1614834157,\n \"txid\": \"86099bb8ccfa3045ce91b915e9f9af3ad4f490cacc8bb4883ff2f44f558034a3\",\n \"type\": \"payment\"\n }\n ],\n \"outputs\": [\n {\n \"address\": \"myvqTjDz7Jo3mqvnPN5BQ5ACeffyPGzS9u\",\n \"amount\": \"1.0\",\n \"claim_id\": \"d0c162f216e4e566d6da93a28ad4e23a78bcea87\",\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#d0c162f216e4e566d6da93a28ad4e23a78bcea87\",\n \"signing_channel\": {\n \"address\": \"mtcRw1f5eTuchnSTgvRMiBDJ97eQSeWRb3\",\n \"amount\": \"1.0\",\n \"claim_id\": \"b312a0c4eff10abe98542f99679ccddc20840daa\",\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#b312a0c4eff10abe98542f99679ccddc20840daa\",\n \"timestamp\": 1614834156,\n \"txid\": \"51756a383ab1ba913f43442a9651231fb65761698666361f3203e4a43aa15fac\",\n \"type\": \"claim\",\n \"value\": {\n \"public_key\": \"3056301006072a8648ce3d020106052b8104000a03420004822b2981f3e209733bab8625b24389d8c1dc9e18d6dab2eaff74977992dce4f0e884799d7eb928337595d7df1384f8851f5043e2d1532cd2a5f69a7e16797b5a\",\n \"public_key_id\": \"mzK5Y4GEhLT3bT6Xw4MDvEF2ve1BaNAtJt\",\n \"title\": \"New Channel\"\n },\n \"value_type\": \"channel\"\n },\n \"timestamp\": null,\n \"txid\": \"8a9cbccc985493fae0dbb6f086ffcbfe6e931cbc50ee5478c200b9d1bbe758c6\",\n \"type\": \"claim\",\n \"value\": {\n \"author\": \"Picaso\",\n \"description\": \"A blank PNG that is 5x7.\",\n \"fee\": {\n \"address\": \"myvqTjDz7Jo3mqvnPN5BQ5ACeffyPGzS9u\",\n \"amount\": \"0.3\",\n \"currency\": \"LBC\"\n },\n \"image\": {\n \"height\": 7,\n \"width\": 5\n },\n \"languages\": [\n
2019-04-11 21:35:24 +02:00
}
]
},
{
"name": "stream_list",
"description": "List my stream claims.",
"arguments": [
2020-03-22 01:15:21 +01:00
{
"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
},
2020-08-19 21:46:29 +02:00
{
"name": "is_spent",
"type": "bool",
"description": "shows previous stream updates and abandons",
"is_required": false
},
2019-04-11 21:35:24 +02:00
{
"name": "account_id",
"type": "str",
"description": "id of the account to query",
"is_required": false
},
2019-09-20 15:43:58 +02:00
{
"name": "wallet_id",
"type": "str",
"description": "restrict results to specific wallet",
"is_required": false
},
2019-04-11 21:35:24 +02:00
{
"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
2020-02-01 23:59:57 +01:00
},
{
"name": "resolve",
"type": "bool",
"description": "resolves each stream to provide additional metadata",
"is_required": false
2020-03-22 01:15:21 +01:00
},
{
"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
2019-04-11 21:35:24 +02:00
}
],
2020-03-22 01:15:21 +01:00
"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 }",
2019-04-11 21:35:24 +02:00
"examples": [
{
2019-04-12 14:58:00 +02:00
"title": "List all your stream claims",
2020-08-19 21:46:29 +02:00
"curl": "curl -d'{\"method\": \"stream_list\", \"params\": {\"name\": [], \"claim_id\": [], \"is_spent\": false, \"resolve\": false, \"no_totals\": false}}' http://localhost:5279/",
2019-04-11 21:35:24 +02:00
"lbrynet": "lbrynet stream list",
2020-08-19 21:46:29 +02:00
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"stream_list\", \"params\": {\"name\": [], \"claim_id\": [], \"is_spent\": false, \"resolve\": false, \"no_totals\": false}}).json()",
2021-03-04 06:02:42 +01:00
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"items\": [\n {\n \"address\": \"n4fHJYFChC7a9V7M9BjLsnyzsMj4p821u2\",\n \"amount\": \"1.0\",\n \"claim_id\": \"8e1d6b1b4aabe90269528e6cd09ec6e67086aa27\",\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#8e1d6b1b4aabe90269528e6cd09ec6e67086aa27\",\n \"signing_channel\": {\n \"address\": \"mtcRw1f5eTuchnSTgvRMiBDJ97eQSeWRb3\",\n \"amount\": \"1.0\",\n \"claim_id\": \"b312a0c4eff10abe98542f99679ccddc20840daa\",\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#b312a0c4eff10abe98542f99679ccddc20840daa\",\n \"timestamp\": 1614834156,\n \"txid\": \"51756a383ab1ba913f43442a9651231fb65761698666361f3203e4a43aa15fac\",\n \"type\": \"claim\",\n \"value\": {\n \"public_key\": \"3056301006072a8648ce3d020106052b8104000a03420004822b2981f3e209733bab8625b24389d8c1dc9e18d6dab2eaff74977992dce4f0e884799d7eb928337595d7df1384f8851f5043e2d1532cd2a5f69a7e16797b5a\",\n \"public_key_id\": \"mzK5Y4GEhLT3bT6Xw4MDvEF2ve1BaNAtJt\",\n \"title\": \"New Channel\"\n },\n \"value_type\": \"channel\"\n },\n \"timestamp\": 1614834157,\n \"txid\": \"040def12329d3b9002595f77a3bb87fd43f9c603595f0c7da3fa92582efde10d\",\n \"type\": \"claim\",\n \"value\": {\n \"source\": {\n \"hash\": \"fdbd8e75a67f29f701a4e040385e2e23986303ea10239211af907fcbb83578b3e417cb71ce646efd0819dd8c088de1bd\",\n \"media_type\": \"application/octet-stream\",\n \"name\": \"tmpuyu0q8tj\",\n \"sd_hash\": \"3da9fe6b3aee199c40a6307f293f9006690cc8bbe1c30dca591e7d09f39ec7d3a3443cb526f95da4f9b94915ec511f6d\",\n \"size\": \"11\"\n },\n \"stream_type\": \"binary\"\n },\n \"value_type\": \"stream\"\n },\n {\n \"address\": \"n4fHJYFChC7a9V7M9BjLsnyzsMj4p821u2\",\n \"amount\": \"1.0\",\n \"claim_id\": \"8e1d6b1b4aabe90269528e6cd09ec6e67086aa27\",\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#8e1d6b1b4aabe90269528e6cd09ec6e67086aa27\",\n \"timestamp\": 1614834157,\n \"txid\": \"86099bb8ccfa3045ce91b915e9f9af3ad4f490cacc8bb4883ff2f44f558034a3\",\n \"type\": \"claim\",\n \"value\": {\n \"source\": {\n \"hash\": \"fdbd8e75a67f29f701a4e040385e2e23986303ea10239211af907fcbb83578b3e417cb71ce646efd0819dd8c088de1bd\",\n \"media_type\": \"application/octet-stream\",\n \"name\": \"tmpuyu0q8tj\",\n \"sd_hash\": \"3da9fe6b3aee199c40a6307f293f9006690cc8bbe1c30dca591e7d09f39ec7d3a3443cb526f95da4f9b94915ec511f6d\",\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}"
2019-04-11 21:35:24 +02:00
},
{
2019-04-12 14:58:00 +02:00
"title": "Paginate your stream claims",
2020-08-19 21:46:29 +02:00
"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/",
2019-04-11 21:35:24 +02:00
"lbrynet": "lbrynet stream list --page=1 --page_size=20",
2020-08-19 21:46:29 +02:00
"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()",
2021-03-04 06:02:42 +01:00
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"items\": [\n {\n \"address\": \"n4fHJYFChC7a9V7M9BjLsnyzsMj4p821u2\",\n \"amount\": \"1.0\",\n \"claim_id\": \"8e1d6b1b4aabe90269528e6cd09ec6e67086aa27\",\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#8e1d6b1b4aabe90269528e6cd09ec6e67086aa27\",\n \"signing_channel\": {\n \"address\": \"mtcRw1f5eTuchnSTgvRMiBDJ97eQSeWRb3\",\n \"amount\": \"1.0\",\n \"claim_id\": \"b312a0c4eff10abe98542f99679ccddc20840daa\",\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#b312a0c4eff10abe98542f99679ccddc20840daa\",\n \"timestamp\": 1614834156,\n \"txid\": \"51756a383ab1ba913f43442a9651231fb65761698666361f3203e4a43aa15fac\",\n \"type\": \"claim\",\n \"value\": {\n \"public_key\": \"3056301006072a8648ce3d020106052b8104000a03420004822b2981f3e209733bab8625b24389d8c1dc9e18d6dab2eaff74977992dce4f0e884799d7eb928337595d7df1384f8851f5043e2d1532cd2a5f69a7e16797b5a\",\n \"public_key_id\": \"mzK5Y4GEhLT3bT6Xw4MDvEF2ve1BaNAtJt\",\n \"title\": \"New Channel\"\n },\n \"value_type\": \"channel\"\n },\n \"timestamp\": 1614834157,\n \"txid\": \"040def12329d3b9002595f77a3bb87fd43f9c603595f0c7da3fa92582efde10d\",\n \"type\": \"claim\",\n \"value\": {\n \"source\": {\n \"hash\": \"fdbd8e75a67f29f701a4e040385e2e23986303ea10239211af907fcbb83578b3e417cb71ce646efd0819dd8c088de1bd\",\n \"media_type\": \"application/octet-stream\",\n \"name\": \"tmpuyu0q8tj\",\n \"sd_hash\": \"3da9fe6b3aee199c40a6307f293f9006690cc8bbe1c30dca591e7d09f39ec7d3a3443cb526f95da4f9b94915ec511f6d\",\n \"size\": \"11\"\n },\n \"stream_type\": \"binary\"\n },\n \"value_type\": \"stream\"\n },\n {\n \"address\": \"n4fHJYFChC7a9V7M9BjLsnyzsMj4p821u2\",\n \"amount\": \"1.0\",\n \"claim_id\": \"8e1d6b1b4aabe90269528e6cd09ec6e67086aa27\",\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#8e1d6b1b4aabe90269528e6cd09ec6e67086aa27\",\n \"timestamp\": 1614834157,\n \"txid\": \"86099bb8ccfa3045ce91b915e9f9af3ad4f490cacc8bb4883ff2f44f558034a3\",\n \"type\": \"claim\",\n \"value\": {\n \"source\": {\n \"hash\": \"fdbd8e75a67f29f701a4e040385e2e23986303ea10239211af907fcbb83578b3e417cb71ce646efd0819dd8c088de1bd\",\n \"media_type\": \"application/octet-stream\",\n \"name\": \"tmpuyu0q8tj\",\n \"sd_hash\": \"3da9fe6b3aee199c40a6307f293f9006690cc8bbe1c30dca591e7d09f39ec7d3a3443cb526f95da4f9b94915ec511f6d\",\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}"
2019-04-11 21:35:24 +02:00
}
]
},
2019-11-20 16:39:17 +01:00
{
"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
},
2019-11-20 16:39:17 +01:00
{
"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
}
],
2020-03-22 01:15:21 +01:00
"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 prot
2019-11-20 16:39:17 +01:00
"examples": []
},
2019-04-11 21:35:24 +02:00
{
"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
},
2020-03-22 01:15:21 +01:00
{
"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
},
2019-04-24 05:49:30 +02:00
{
"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
},
2019-04-11 21:35:24 +02:00
{
"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
},
2019-04-27 19:13:20 +02:00
{
"name": "clear_fee",
"type": "bool",
"description": "clear previously set fee",
"is_required": false
},
2019-04-11 21:35:24 +02:00
{
"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
},
{
2019-04-27 19:13:20 +02:00
"name": "clear_tags",
2019-04-11 21:35:24 +02:00
"type": "bool",
2019-04-27 19:13:20 +02:00
"description": "clear existing tags (prior to adding new ones)",
2019-04-11 21:35:24 +02:00
"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
},
{
2019-04-27 19:13:20 +02:00
"name": "clear_languages",
2019-04-11 21:35:24 +02:00
"type": "bool",
2019-04-27 19:13:20 +02:00
"description": "clear existing languages (prior to adding new ones)",
2019-04-11 21:35:24 +02:00
"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
},
2019-04-27 19:13:20 +02:00
{
"name": "clear_locations",
"type": "bool",
"description": "clear existing locations (prior to adding new ones)",
"is_required": false
},
2019-04-11 21:35:24 +02:00
{
"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
},
{
2019-04-21 05:56:40 +02:00
"name": "width",
2019-04-11 21:35:24 +02:00
"type": "int",
2019-04-21 05:56:40 +02:00
"description": "image/video width, automatically calculated from media file",
2019-04-11 21:35:24 +02:00
"is_required": false
},
{
2019-04-21 05:56:40 +02:00
"name": "height",
2019-04-11 21:35:24 +02:00
"type": "int",
2019-04-21 05:56:40 +02:00
"description": "image/video height, automatically calculated from media file",
2019-04-11 21:35:24 +02:00
"is_required": false
},
{
2019-04-21 05:56:40 +02:00
"name": "duration",
2019-04-11 21:35:24 +02:00
"type": "int",
2019-04-21 05:56:40 +02:00
"description": "audio/video duration in seconds, automatically calculated",
2019-04-11 21:35:24 +02:00
"is_required": false
},
{
"name": "channel_id",
"type": "str",
"description": "claim id of the publisher channel",
"is_required": false
},
2019-04-27 19:13:20 +02:00
{
"name": "channel_name",
"type": "str",
"description": "name of the publisher channel",
"is_required": false
},
2019-04-11 21:35:24 +02:00
{
"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",
2019-10-15 18:12:35 +02:00
"description": "account in which to look for stream (default: all)",
2019-08-12 07:26:42 +02:00
"is_required": false
},
2019-09-20 15:43:58 +02:00
{
"name": "wallet_id",
"type": "str",
"description": "restrict operation to specific wallet",
"is_required": false
},
2019-08-12 07:26:42 +02:00
{
"name": "funding_account_ids",
"type": "list",
"description": "ids of accounts to fund this transaction",
2019-04-11 21:35:24 +02:00
"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
2019-04-27 19:13:20 +02:00
},
2019-06-25 21:34:32 +02:00
{
"name": "blocking",
"type": "bool",
"description": "wait until transaction is in mempool",
"is_required": false
},
2019-04-27 19:13:20 +02:00
{
"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
2019-04-11 21:35:24 +02:00
}
],
2020-03-22 01:15:21 +01:00
"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 prot
2019-04-11 21:35:24 +02:00
"examples": [
{
2019-04-12 14:58:00 +02:00
"title": "Update a stream claim to add channel",
2021-03-04 06:02:42 +01:00
"curl": "curl -d'{\"method\": \"stream_update\", \"params\": {\"claim_id\": \"8e1d6b1b4aabe90269528e6cd09ec6e67086aa27\", \"validate_file\": false, \"optimize_file\": false, \"clear_fee\": false, \"tags\": [], \"clear_tags\": false, \"languages\": [], \"clear_languages\": false, \"locations\": [], \"clear_locations\": false, \"channel_id\": \"b312a0c4eff10abe98542f99679ccddc20840daa\", \"clear_channel\": false, \"channel_account_id\": [], \"funding_account_ids\": [], \"preview\": false, \"blocking\": false, \"replace\": false}}' http://localhost:5279/",
"lbrynet": "lbrynet stream update 8e1d6b1b4aabe90269528e6cd09ec6e67086aa27 --channel_id=\"b312a0c4eff10abe98542f99679ccddc20840daa\"",
"python": "requests.post(\"http://localhost:5279\", json={\"method\": \"stream_update\", \"params\": {\"claim_id\": \"8e1d6b1b4aabe90269528e6cd09ec6e67086aa27\", \"validate_file\": false, \"optimize_file\": false, \"clear_fee\": false, \"tags\": [], \"clear_tags\": false, \"languages\": [], \"clear_languages\": false, \"locations\": [], \"clear_locations\": false, \"channel_id\": \"b312a0c4eff10abe98542f99679ccddc20840daa\", \"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\": \"0100000002a33480554ff4f23f88b48bccca90f4d43aaff9e915b991ce4530faccb89b0986000000006b483045022100b80e42a299c759608dacd13380954e9c48326ce7e902466f41c5085c958e9b03022044f9c067d9a517ff0d4f2b88444314a3b512059b751ed99a8ff86049299b40b801210273e915853a992843ce866bb86542bbd8f6bf2a6cd7bd1b40fcc62ebdca3d1033ffffffffe911a89c845125447dc59466b95ec591cbbe88c3df07507fe7a083ba713da08a010000006a47304402202372963cea95a69e89031f098557db31dd2cf4520df7fa0d15f5199cbb366bec022011497ee50c168a9e12666514e8387d57aad75ad51d461b38c9c466cb1e711eca012102719d4eb88793886a737557b637a2aca41df4de8d659874b10a70d10330861f96ffffffff0200e1f50500000000fd2301b7076173747265616d1427aa8670e6c69ed06c8e526902e9ab4a1b6b1d8e4ce801aa0d8420dccd9c67992f5498be0af1efc4a012b337f1ca30a5844b95623ce944a8279839e5111bc041faf55de4cd6452e2ff25ea6ad84a1e3c478596408f4342829ffaa690073dfbdf024eb5b4c12c2509ad72980a90010a8d010a30fdbd8e75a67f29f701a4e040385e2e23986303ea10239211af907fcbb83578b3e417cb71ce646efd0819dd8c088de1bd120b746d70757975307138746a180b22186170706c69636174696f6e2f6f637465742d73747265616d32303da9fe6b3aee199c40a6307f293f9006690cc8bbe1c30dca591e7d09f39ec7d3a3443cb526f95da4f9b94915ec511f6d6d6d76a914fdde168e6017209da83a477c5a85acfded0a69c588ac32a0d205000000001976a91433591e859ffb16562cc9c35996794dc9d28f924188ac00000000\",\n \"inputs\": [\n {\n \"address\": \"n4fHJYFChC7a9V7M9BjLsnyzsMj4p821u2\",\n \"amount\": \"1.0\",\n \"claim_id\": \"8e1d6b1b4aabe90269528e6cd09ec6e67086aa27\",\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#8e1d6b1b4aabe90269528e6cd09ec6e67086aa27\",\n \"timestamp\": 1614834157,\n \"txid\": \"86099bb8ccfa3045ce91b915e9f9af3ad4f490cacc8bb4883ff2f44f558034a3\",\n \"type\": \"claim\",\n \"value\": {\n \"source\": {\n \"hash\": \"fdbd8e75a67f29f701a4e040385e2e23986303ea10239211af907fcbb83578b3e417cb71ce646efd0819dd8c088de1bd\",\n \"media_type\": \"application/octet-stream\",\n \"name\": \"tmpuyu0q8tj\",\n \"sd_hash\": \"3da9fe6b3aee199c40a6307f293f9006690cc8bbe1c30dca591e7d09f39ec7d3a3443cb526f95da4f9b94915ec511f6d\",\n \"size\": \"11\"\n },\n \"stream_type\": \"binary\"\n },\n \"value_type\": \"stream\"\n },\n {\n \"address\": \"n4KmeHo7zQ59rjVxxzNv1tSA7g5w4yWqyk\",\n \"amount\": \"0.9772285\",\n \"confirmations\": 3,\n \"height\": 211,\n \"nout\": 1,\n \"timestamp\": 1614834156,\n \"txid\": \"8aa03d71ba83a0e77f5007dfc388becb91c55eb96694c57d442551849ca811e9\",\n \"type\": \"payment\"\n }\n ],\n \"outputs\": [\n {\n \"address\": \"n4fHJYFChC7a9V7M9BjLsnyzsMj4p821u2\",\n \"amount\": \"1.0\",\n \"claim_id\": \"8e1d6b1b4aabe90269528e6cd09ec6e67086aa27\",\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#8e1d6b1b4aabe90269528e6cd09ec6e67086aa27\",\n \"signing_channel\": {\n \"address\": \"mtcRw1f5eTuchnSTgvRMiBDJ97eQSeWRb3\",\n \"amount\": \"1.0\",\n \"claim_id\": \"b312a0c4eff10abe98542f99679ccddc20840daa\",\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#b312a0c4eff10abe98542f99679ccddc20840daa\",\n \"timestamp\": 1614834156,\n \"txi
2019-04-11 21:35:24 +02:00
}
]
2018-08-22 06:20:30 +02:00
}
2019-04-11 21:35:24 +02:00
]
},
2019-04-11 21:35:24 +02:00
"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",
2019-08-28 18:55:19 +02:00
"description": "claim_id of the support to abandon",
2019-04-11 21:35:24 +02:00
"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
},
2019-09-20 15:43:58 +02:00
{
"name": "wallet_id",
"type": "str",
"description": "restrict operation to specific wallet",
"is_required": false
},
2019-04-11 21:35:24 +02:00
{
"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
}
],
2020-03-22 01:15:21 +01:00
"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 prot
2019-04-11 21:35:24 +02:00
"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
},
2020-08-19 21:46:29 +02:00
{
"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
},
2019-04-11 21:35:24 +02:00
{
"name": "account_id",
"type": "str",
2019-08-12 07:26:42 +02:00
"description": "account to use for holding the transaction",
"is_required": false
},
2019-09-20 15:43:58 +02:00
{
"name": "wallet_id",
"type": "str",
"description": "restrict operation to specific wallet",
"is_required": false
},
2019-08-12 07:26:42 +02:00
{
"name": "funding_account_ids",
"type": "list",
"description": "ids of accounts to fund this transaction",
2019-04-11 21:35:24 +02:00
"is_required": false
},
{
"name": "preview",
"type": "bool",
"description": "do not broadcast the transaction",
"is_required": false
2019-06-25 21:34:32 +02:00
},
{
"name": "blocking",
"type": "bool",
"description": "wait until transaction is in mempool",
"is_required": false
2019-04-11 21:35:24 +02:00
}
],
2020-03-22 01:15:21 +01:00
"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 prot
2019-04-11 21:35:24 +02:00
"examples": []
},
{
"name": "support_list",
2020-08-19 21:46:29 +02:00
"description": "List staked supports and sent/received tips.",
2019-04-11 21:35:24 +02:00
"arguments": [
2020-03-22 01:15:21 +01:00
{
"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
},
{
2020-08-19 21:46:29 +02:00
"name": "received",
"type": "bool",
"description": "only show received (tips)",
"is_required": false
},
{
"name": "sent",
2020-03-22 01:15:21 +01:00
"type": "bool",
2020-08-19 21:46:29 +02:00
"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",
2020-03-22 01:15:21 +01:00
"is_required": false
},
2019-04-11 21:35:24 +02:00
{
"name": "account_id",
"type": "str",
"description": "id of the account to query",
"is_required": false
},
2019-09-20 15:43:58 +02:00
{
"name": "wallet_id",
"type": "str",
"description": "restrict results to specific wallet",
"is_required": false
},
2019-04-11 21:35:24 +02:00
{
"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
2020-03-22 01:15:21 +01:00
},
{
"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
2019-04-11 21:35:24 +02:00
}
],
2020-03-22 01:15:21 +01:00
"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 }",
2019-04-11 21:35:24 +02:00
"examples": []
},
{
"name": "support_sum",
"description": "List total staked supports for a claim, grouped by the channel that signed the support.\n+\n+ If claim_id is a channel claim, you can use --include_channel_content to also include supports for\n+ content claims in the channel.\n\n !!!! NOTE: PAGINATION DOES NOT DO ANYTHING AT THE MOMENT !!!!!",
"arguments": [
{
"name": "claim_id",
"type": "str",
"description": "claim id",
"is_required": false
},
{
"name": "new_sdk_server",
"type": "str",
"description": "URL of the new SDK server (EXPERIMENTAL)",
"is_required": false
},
{
"name": "include_channel_content",
"type": "bool",
"description": "if claim_id is for a channel, include supports for claims in that channel",
"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 \"glorious data in dictionary\"\n ]\n }",
"examples": []
2019-01-21 23:37:56 +01:00
}
]
},
2019-04-11 21:35:24 +02:00
"sync": {
"doc": "Wallet synchronization.",
"commands": [
{
"name": "sync_apply",
2019-10-16 17:12:10 +02:00
"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).",
2019-04-11 21:35:24 +02:00
"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
},
2019-09-20 15:43:58 +02:00
{
"name": "wallet_id",
"type": "str",
"description": "wallet being sync'ed",
"is_required": false
2019-10-15 18:12:35 +02:00
},
{
"name": "blocking",
"type": "bool",
"description": "wait until any new accounts have sync'ed",
"is_required": false
2019-04-11 21:35:24 +02:00
}
],
"returns": "(map) sync hash and data",
"examples": []
},
{
"name": "sync_hash",
"description": "Deterministic hash of the wallet.",
2019-09-20 15:43:58 +02:00
"arguments": [
{
"name": "wallet_id",
"type": "str",
"description": "wallet for which to generate hash",
"is_required": false
}
],
2019-04-11 21:35:24 +02:00
"returns": "(str) sha256 hash of wallet",
"examples": []
2019-04-06 21:33:19 +02:00
}
]
},
2020-03-22 01:15:21 +01:00
"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": []
}
]
},
2019-04-11 21:35:24 +02:00
"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
},
2019-09-20 15:43:58 +02:00
{
"name": "wallet_id",
"type": "str",
"description": "restrict results to specific wallet",
"is_required": false
},
2019-04-11 21:35:24 +02:00
{
"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 }",
2019-04-12 14:58:00 +02:00
"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()",
2021-03-04 06:02:42 +01:00
"output": "{\n \"jsonrpc\": \"2.0\",\n \"result\": {\n \"items\": [\n {\n \"abandon_info\": [],\n \"claim_info\": [],\n \"confirmations\": 1,\n \"date\": \"2021-03-04 00:02\",\n \"fee\": \"-0.000124\",\n \"purchase_info\": [],\n \"support_info\": [],\n \"timestamp\": 1614834156,\n \"txid\": \"fa97d309280b2e779d0a4f7a0b3c5fa5586b8697d601e336e865517608e328a2\",\n \"update_info\": [],\n \"value\": \"0.0\"\n },\n {\n \"abandon_info\": [],\n \"claim_info\": [],\n \"confirmations\": 7,\n \"date\": \"2021-03-04 00:02\",\n \"fee\": \"0.0\",\n \"purchase_info\": [],\n \"support_info\": [],\n \"timestamp\": 1614834155,\n \"txid\": \"8b61dc961c8511673209bdf4f974fdfcaf4d146dac70a82321c7a1193169334a\",\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}"
2019-04-12 14:58:00 +02:00
}
]
2019-04-11 21:35:24 +02:00
},
{
"name": "transaction_show",
"description": "Get a decoded transaction from a txid",
"arguments": [
{
"name": "txid",
"type": "str",
"description": "txid of the transaction",
"is_required": true
}
],
2020-03-22 01:15:21 +01:00
"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 prot
"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": "not_channel_id",
"type": "str or list",
"description": "claims not in this channel",
"is_required": false
},
2020-03-22 01:15:21 +01:00
{
"name": "name",
"type": "str or list",
"description": "claim name",
"is_required": false
},
{
2020-08-19 21:46:29 +02:00
"name": "is_spent",
"type": "bool",
"description": "only show spent txos",
"is_required": false
},
{
"name": "is_not_spent",
2020-03-22 01:15:21 +01:00
"type": "bool",
2020-08-19 21:46:29 +02:00
"description": "only show not spent txos",
2020-03-22 01:15:21 +01:00
"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
},
2020-03-31 03:45:58 +02:00
{
"name": "include_received_tips",
"type": "bool",
2021-02-17 00:07:43 +01:00
"description": "calculate the amount of tips received for claim outputs",
2020-03-31 03:45:58 +02:00
"is_required": false
},
2020-03-22 01:15:21 +01:00
{
"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": []
},
2020-03-31 03:45:58 +02:00
{
"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": "channel_id",
"type": "str or list",
"description": "claims in this channel",
"is_required": false
},
{
"name": "not_channel_id",
"type": "str or list",
"description": "claims not in this channel",
"is_required": false
},
2020-03-31 03:45:58 +02:00
{
2020-08-19 21:46:29 +02:00
"name": "is_spent",
2020-03-31 03:45:58 +02:00
"type": "bool",
2020-08-19 21:46:29 +02:00
"description": "only show spent txos",
"is_required": false
},
{
"name": "is_not_spent",
"type": "bool",
"description": "only show not spent txos",
2020-03-31 03:45:58 +02:00
"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": "not_channel_id",
"type": "str or list",
"description": "claims not in this channel",
"is_required": false
},
2020-03-31 03:45:58 +02:00
{
"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
"examples": []
},
2020-03-22 01:15:21 +01:00
{
"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": "channel_id",
"type": "str or list",
"description": "claims in this channel",
"is_required": false
},
{
"name": "not_channel_id",
"type": "str or list",
"description": "claims not in this channel",
"is_required": false
},
2020-03-22 01:15:21 +01:00
{
2020-08-19 21:46:29 +02:00
"name": "is_spent",
2020-03-22 01:15:21 +01:00
"type": "bool",
2020-08-19 21:46:29 +02:00
"description": "only show spent txos",
"is_required": false
},
{
"name": "is_not_spent",
"type": "bool",
"description": "only show not spent txos",
2020-03-22 01:15:21 +01:00
"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",
2019-04-11 21:35:24 +02:00
"examples": []
2019-04-06 21:33:19 +02:00
}
]
},
2019-04-11 21:35:24 +02:00
"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
},
2019-09-20 15:43:58 +02:00
{
"name": "wallet_id",
"type": "str",
"description": "restrict results to specific wallet",
"is_required": false
},
2019-04-11 21:35:24 +02:00
{
"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
}
],
2020-03-22 01:15:21 +01:00
"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 }",
2019-04-11 21:35:24 +02:00
"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
2019-09-20 15:43:58 +02:00
},
{
"name": "wallet_id",
"type": "str",
"description": "restrict operation to specific wallet",
"is_required": false
2019-04-11 21:35:24 +02:00
}
],
"returns": "None",
"examples": []
2019-01-21 23:37:56 +01:00
}
]
2019-09-20 15:43:58 +02:00
},
"wallet": {
"doc": "Create, modify and inspect wallets.",
"commands": [
{
"name": "wallet_add",
2019-09-23 18:53:31 +02:00
"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": []
},
2019-10-15 18:12:35 +02:00
{
"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": []
},
2019-09-23 18:53:31 +02:00
{
"name": "wallet_create",
"description": "Create a new wallet.",
2019-09-20 15:43:58 +02:00
"arguments": [
{
"name": "wallet_id",
"type": "str",
"description": "wallet file name",
"is_required": true
},
{
2019-09-23 18:53:31 +02:00
"name": "skip_on_startup",
2019-09-20 15:43:58 +02:00
"type": "bool",
2019-09-23 18:53:31 +02:00
"description": "don't add wallet to daemon_settings.yml",
2019-09-20 15:43:58 +02:00
"is_required": false
},
{
"name": "create_account",
"type": "bool",
2019-09-23 18:53:31 +02:00
"description": "generates the default account",
"is_required": false
},
{
"name": "single_key",
"type": "bool",
"description": "used with --create_account, creates single-key account",
2019-09-20 15:43:58 +02:00
"is_required": false
}
],
"returns": " {\n \"id\": \"wallet_id\",\n \"name\": \"optional wallet name\"\n }",
"examples": []
},
2019-10-15 18:12:35 +02:00
{
"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": []
},
2019-09-20 15:43:58 +02:00
{
2019-09-23 18:53:31 +02:00
"name": "wallet_list",
"description": "List wallets.",
2019-09-20 15:43:58 +02:00
"arguments": [
{
"name": "wallet_id",
"type": "str",
2019-09-23 18:53:31 +02:00
"description": "show specific wallet only",
"is_required": false
2019-10-26 05:46:24 +02:00
},
{
"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
2019-09-20 15:43:58 +02:00
}
],
2019-10-26 05:46:24 +02:00
"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 }",
2019-09-20 15:43:58 +02:00
"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()",
2019-10-26 05:46:24 +02:00
"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}"
2019-09-20 15:43:58 +02:00
}
]
},
2019-10-15 18:12:35 +02:00
{
"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": []
},
2020-01-04 02:23:40 +01:00
{
"name": "wallet_reconnect",
"description": "Reconnects ledger network client, applying new configurations.",
"arguments": [],
"returns": "None",
"examples": []
},
2019-09-20 15:43:58 +02:00
{
"name": "wallet_remove",
2019-09-23 18:53:31 +02:00
"description": "Remove an existing wallet.",
2019-09-20 15:43:58 +02:00
"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": []
2019-10-15 18:12:35 +02:00
},
{
"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
2020-08-19 21:46:29 +02:00
},
{
"name": "blocking",
"type": "bool",
"description": "wait until tx has synced",
"is_required": false
2019-10-15 18:12:35 +02:00
}
],
2020-03-22 01:15:21 +01:00
"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 prot
2019-10-15 18:12:35 +02:00
"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": []
2019-09-20 15:43:58 +02:00
}
]
2018-08-22 06:20:30 +02:00
}
2021-03-01 17:52:17 +01:00
}