Coder Social home page Coder Social logo

odysee-api's People

Contributors

anbsky avatar binaryflesh avatar ezshroom avatar g1tman avatar jackrobison avatar jbshu4546 avatar jessopb avatar lucasgpulcinelli avatar lyoshenka avatar nheingit avatar nikooo777 avatar rnd avatar tiger5226 avatar tzarebczan avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

odysee-api's Issues

Add support for fund-locked accounts

Accounts through which all API calls that send funds are disabled.

This would allow us to give accounts out with large LBC balances that can be used for supports only.

Consider separating file uploads from publish call

Coupling the publish call with metadata with the file upload raises two issues:

  • It means a file upload cannot begin until all metadata is provided
  • It changes the typical signature of API calls to require multipart posts

Instead, the design could be a two part process:

  • A file upload endpoint that receives files from authenticated users and returns a unique file token.
  • A publish endpoint that takes a file token in the place of the file_path parameter

use funding_account_ids parameter

To support 0.39.0 backwards-incompatible (https://github.com/lbryio/lbry-sdk/releases/tag/v0.39.0) changes for multi-account wallets, we need to pass the funding_account_ids (list) for the below API calls so that the SDK knows where the funds should come from. This would be in addition to --account_id which specifies where the transaction will go (which we are doing today).

[api] channel_create, channel_update, publish, stream_create, stream_update and support_create have a new --funding_account_ids argument with a new default behavior that all accounts are used to fund those transactions and you must explicitly limit accounts by using the --funding_account_ids argument. 

og:image needs to match content

The Issue

Currently the og:image set for any piece of content is:
og:image

The app should use the thumbnail provided with the content unless it has no thumbnail then should use the above by default.

UXP browsers don't work. (White screen)

@tsjnachos117 commented on Sat Aug 10 2019

Here's the deal: there's a project called "Unified XUL Browser" (also known as "UXP"), which is basically a platform for developing applications using web code. UXP was originally a fork of the Firefox codebase, although there's been significant divergence over the years.

The community that maintains UXP also maintains two browsers that take advantage of it: Basilisk, and Pale Moon. IMHO, they are both a lot lighter than upstream Firefox, which is why I love them. They both use a Gecko-like fork called Goanna.

Unfortunately, if I try to use either browser on beta.lbry.tv, they both give me a blank, white screen. I've checked the url, and it was correct. I've also tried using both browsers with brand new profiles (just in case the problem had something to do with one of my addons), but that didn't help.

Please fix this issue, as the laptop I'm typing this on doesn't *quite*

have enough RAM to use upstream Firefox - much less Chrome, which is an even bigger RAM hog.

Here's a screenshot of what my problem is:

blank-page

I'm running Ubuntu GNU/Linux x64, if that helps.

Analytics for LBRY.TV

Hi guys, I was talking with Josh about getting the right calls for analytics in lbrytv. Not sure what you guys have done here on this.

Currently we link users from web properties like lbry.com via the following code:

https://github.com/lbryio/lbry.com/blob/9d09248bd0466f8dd527a1d89fe34a404d2bf624/view/template/layout/_analytics_footer.php#L13-L17

https://github.com/lbryio/lbry.com/blob/9d09248bd0466f8dd527a1d89fe34a404d2bf624/controller/Session.class.php#L34-L48

The basic flow is to capture the GA client id, pass it to internal-apis which logs it as a web visitor. Then tries to link the IP address to users. Once a link is made special events are pushed to google analytics like searches and views.

Since this is a website, I would assume you could just do this directly in the code. However, since we are sharing a codebase, it might be better to use the method built for lbry.com. I would like to hear your thoughts though. Ultimately, we would like to have this setup for Josh before we go live, so he has access to the important information.

I spoke with @seanyesmunt about the above in slack channel #analytics-lbrytv

Anything in the browser, we can do in electron. They are treated the exact same way as far as individual page tracking and event tracking. We should be able to do the same tracking as we do on lbry.com.

I assigned all parties. I put the issue here since it is directly related to lbry.tv and made it a blocker for when we switch it back over to users so we can get some information that is comparable to the desktop app.

Remove middleware for metrics

We need to sprinkle more metrics around the code. Middleware that was put in place to add abstraction layer around Prometheus seems to be detrimental to this and it would be best to remove it.

Improve streaming module

Streaming module needs to implement io.ReadSeeker interface so we can use built-in http module methods for streaming content delivery.

Move web server into lbryv (maybe)

lbryio/lbry-desktop#2546 highlights the need for the lbry.tv webserver to have access to at least some of the data stores that lbry.tv will use.

Given that the JS web server is currently doing very little, I suspect the right answer is to move this into lbry.tv, but the pros and cons of this should be discussed.

Player module doesn't handle SDK error

The Issue

Player module doesn't seem to be handling failed resolves properly.

Steps to reproduce

  1. Navigate to https://api.lbry.tv/content/claims/two/5508a6113050a8c306d98cab3cad86beec131ed0/stream.mp4

Expected behaviour

Player should return a meaningful error

Actual behaviour

Server errors without any message

System Configuration

  • Browser version:
  • Operating system:

Anything Else

Sentry error event

Screenshots

Internal Use

Acceptance Criteria

Definition of Done

  • Tested against acceptance criteria
  • Tested against the assumptions of user story
  • The project builds without errors
  • Unit tests are written and passing
  • Tests on devices/OS listed in the issue have passed
  • QA performed & issues resolved
  • Refactoring completed
  • Any configuration or build changes documented
  • Documentation updated
  • Peer Code Review performed

Initial public alpha release

Checklist for the public alpha:

  • content navigation
  • streaming video content playback with skipping feature
  • improve streaming module to be able to set write timeouts (#8) turned out to be complex, deferred until there's more time for this
  • implement regular formats playback (#9)
  • UI server
  • disabled features in js

Features planned for the next version:

  • accounts
  • wallets

Make lbrytv streaming work with 0.38

This will require updates to types and possibly lbry.go repos to update resolve response format.

  • claim object is no longer there
  • sd_hash field seems to have been moved out.

0.38 response

{
  "eight": {
    "address": "bESZeiLFPA2bNwszKh6XS16cD79or9NgKq",
    "amount": "570.0",
    "canonical_url": "lbry://@LBRY-India#8/eight#0",
    "claim_id": "07e89510f537d63741b7d370cb3049610e9cdfe0",
    "claim_op": "update",
    "confirmations": 26208,
    "height": 560760,
    "is_change": false,
    "is_channel_signature_valid": true,
    "is_mine": false,
    "meta": {
      "activation_height": 557079,
      "creation_height": 557073,
      "creation_timestamp": 1556184553,
      "effective_amount": "570.0",
      "expiration_height": 2659473,
      "is_controlling": true,
      "support_amount": "0.0",
      "trending_global": 0.0,
      "trending_group": 0,
      "trending_local": 0.0,
      "trending_mixed": 0.0
    },
    "name": "eight",
    "normalized_name": "eight",
    "nout": 0,
    "permanent_url": "lbry://eight#07e89510f537d63741b7d370cb3049610e9cdfe0",
    "short_url": "lbry://eight#0",
    "signing_channel": {
      "address": "bWAbWicEdPTh6fnQZN2Bwv86VX1Xkm5ebZ",
      "amount": "1.0",
      "canonical_url": "lbry://@LBRY-India#8",
      "claim_id": "8f23ab0341dea395384415427d49911958ca442a",
      "claim_op": "create",
      "confirmations": 30797,
      "height": 556171,
      "is_change": false,
      "is_mine": false,
      "meta": {
        "activation_height": 556171,
        "claims_in_channel": 11,
        "creation_height": 556171,
        "creation_timestamp": 1556040690,
        "effective_amount": "1.0",
        "expiration_height": 2658571,
        "is_controlling": true,
        "support_amount": "0.0",
        "trending_global": 0.0,
        "trending_group": 0,
        "trending_local": 0.0,
        "trending_mixed": 0.0
      },
      "name": "@LBRY-India",
      "normalized_name": "@lbry-india",
      "nout": 0,
      "permanent_url": "lbry://@LBRY-India#8f23ab0341dea395384415427d49911958ca442a",
      "short_url": "lbry://@LBRY-India#8",
      "timestamp": 1556040690,
      "txid": "cc604d77dcc1d400d9249add8fb0f2785740f42ae0cb891f6964ad0e879a5463",
      "type": "claim",
      "value": {
        "public_key": "3056301006072a8648ce3d020106052b8104000a034200041cbdbbaf8358b79614254d8a99dfa6eef9e7b36253f3e24a355202b3d2d5d3b8c2c8a1cb0608c94be87cb700419d3aabb2c5707383029998a144728242908ca4",
        "public_key_id": "bMxFG5weZK8k3YyqhFHvRucUaT6Q6tGESx"
      },
      "value_type": "channel"
    },
    "timestamp": 1556777388,
    "txid": "6eb88662cc4b3e0baf56495cc67443929d21b62975b8cbab3e8d9b7f8e25badc",
    "type": "claim",
    "value": {
      "description": "LBRY Is Spreading Like A Virus, Hold Tight Hodlers\nA lot of people are hearing about LBRY, if you've \nalready heard of us, hold tight cos a lot is about to turn ...\n\nSupport us lets create more awareness about LBRY and the future \nof decentralized sharing.\n\nDonations are very much welcome. Thank you.\nDonation add: bWdZueAN5bkep4Z941ezXiKALkhjCYCrSE",
      "languages": [
        "en"
      ],
      "license": "Creative Commons Attribution 4.0 International",
      "license_url": "https://creativecommons.org/licenses/by/4.0/legalcode",
      "source": {
        "media_type": "video/mp4",
        "sd_hash": "834d077d71758d3acae63b87b8d0a583ac26959c6e52bb8c9852391bbf65fd22474b1d4f734b7afac0b9e016f39115e3"
      },
      "stream_type": "video",
      "thumbnail": {
        "url": "https://spee.ch/5/qlVxM841SQucyvePNCfqlNo2.PNG"
      },
      "title": "LBRY Is Spreading Like A Virus, Hold Tight Hodlers"
    },
    "value_type": "stream"
  }
}

0.37 response

  "eight": {
    "certificate": {
      "address": "bWAbWicEdPTh6fnQZN2Bwv86VX1Xkm5ebZ",
      "amount": "1.0",
      "claim_id": "8f23ab0341dea395384415427d49911958ca442a",
      "claim_sequence": -1,
      "confirmations": 30796,
      "decoded_claim": true,
      "effective_amount": "1.0",
      "has_signature": false,
      "height": 556171,
      "name": "@LBRY-India",
      "normalized_name": "@lbry-india",
      "nout": 0,
      "permanent_url": "lbry://@LBRY-India#8f23ab0341dea395384415427d49911958ca442a",
      "protobuf": "00125a0a583056301006072a8648ce3d020106052b8104000a034200041cbdbbaf8358b79614254d8a99dfa6eef9e7b36253f3e24a355202b3d2d5d3b8c2c8a1cb0608c94be87cb700419d3aabb2c5707383029998a144728242908ca4",
      "supports": [],
      "timestamp": 1556040690,
      "txid": "cc604d77dcc1d400d9249add8fb0f2785740f42ae0cb891f6964ad0e879a5463",
      "valid_at_height": 556171,
      "value": {
        "public_key": "3056301006072a8648ce3d020106052b8104000a034200041cbdbbaf8358b79614254d8a99dfa6eef9e7b36253f3e24a355202b3d2d5d3b8c2c8a1cb0608c94be87cb700419d3aabb2c5707383029998a144728242908ca4"
      }
    },
    "claim": {
      "address": "bESZeiLFPA2bNwszKh6XS16cD79or9NgKq",
      "amount": "570.0",
      "channel_name": "@LBRY-India",
      "claim_id": "07e89510f537d63741b7d370cb3049610e9cdfe0",
      "claim_sequence": -1,
      "confirmations": 26207,
      "decoded_claim": true,
      "effective_amount": "570.0",
      "has_signature": true,
      "height": 560760,
      "is_channel_signature_valid": true,
      "name": "eight",
      "nout": 0,
      "permanent_url": "lbry://eight#07e89510f537d63741b7d370cb3049610e9cdfe0",
      "protobuf": "012a44ca581991497d4215443895a3de4103ab238fbd7349da7cb04eb13cb247f13a8086b031c0dcd02ba17518323d61feafeff3cc9062a573267d2f367a8bd7981f95e71aa35eec229248c5c011be9c4d747d2ee10aa6010a3d2209766964656f2f6d70343230834d077d71758d3acae63b87b8d0a583ac26959c6e52bb8c9852391bbf65fd22474b1d4f734b7afac0b9e016f39115e31a2e437265617469766520436f6d6d6f6e73204174747269627574696f6e20342e3020496e7465726e6174696f6e616c223568747470733a2f2f6372656174697665636f6d6d6f6e732e6f72672f6c6963656e7365732f62792f342e302f6c6567616c636f646542324c42525920497320537072656164696e67204c696b6520412056697275732c20486f6c6420546967687420486f646c6572734ade024c42525920497320537072656164696e67204c696b6520412056697275732c20486f6c6420546967687420486f646c6572730a41206c6f74206f662070656f706c65206172652068656172696e672061626f7574204c4252592c20696620796f75277665200a616c7265616479206865617264206f662075732c20686f6c6420746967687420636f732061206c6f742069732061626f757420746f207475726e202e2e2e0a0a537570706f7274207573206c65747320637265617465206d6f72652061776172656e6573732061626f7574204c42525920616e642074686520667574757265200a6f6620646563656e7472616c697a65642073686172696e672e0a0a446f6e6174696f6e73206172652076657279206d7563682077656c636f6d652e205468616e6b20796f752e0a446f6e6174696f6e206164643a206257645a7565414e35626b6570345a393431657a58694b414c6b686a43594372534552302a2e68747470733a2f2f737065652e63682f352f716c56784d38343153517563797665504e4366716c4e6f322e504e4762020801",
      "signature_is_valid": true,
      "signing_channel": {
        "claim_id": "8f23ab0341dea395384415427d49911958ca442a",
        "name": "@LBRY-India",
        "value": {
          "public_key": "3056301006072a8648ce3d020106052b8104000a034200041cbdbbaf8358b79614254d8a99dfa6eef9e7b36253f3e24a355202b3d2d5d3b8c2c8a1cb0608c94be87cb700419d3aabb2c5707383029998a144728242908ca4"
        }
      },
      "supports": [],
      "timestamp": 1556777388,
      "txid": "6eb88662cc4b3e0baf56495cc67443929d21b62975b8cbab3e8d9b7f8e25badc",
      "valid_at_height": 560777,
      "value": {
        "description": "LBRY Is Spreading Like A Virus, Hold Tight Hodlers\nA lot of people are hearing about LBRY, if you've \nalready heard of us, hold tight cos a lot is about to turn ...\n\nSupport us lets create more awareness about LBRY and the future \nof decentralized sharing.\n\nDonations are very much welcome. Thank you.\nDonation add: bWdZueAN5bkep4Z941ezXiKALkhjCYCrSE",
        "languages": [
          "en"
        ],
        "license": "Creative Commons Attribution 4.0 International",
        "license_url": "https://creativecommons.org/licenses/by/4.0/legalcode",
        "source": {
          "media_type": "video/mp4",
          "sd_hash": "834d077d71758d3acae63b87b8d0a583ac26959c6e52bb8c9852391bbf65fd22474b1d4f734b7afac0b9e016f39115e3"
        },
        "thumbnail": {
          "url": "https://spee.ch/5/qlVxM841SQucyvePNCfqlNo2.PNG"
        },
        "title": "LBRY Is Spreading Like A Virus, Hold Tight Hodlers"
      }
    },
    "claims_in_channel": 0
  }
}

[Question] WebRTC

Does this client depend on WebRTC? If so, I think users with WebRTC should be notified as it wouldn't work or them.

support `file xxx` calls

I don't have a whole lot to add to this issue right now, but wanted to create it so it wasn't lost.

We are now using streaming_url in the desktop app that comes from get and file_list. We don't use these commands on lbry.tv.

Ideally we could just use the same calls and the lbrytv api server would change streaming_url to point at lbrytv streaming endpoint so we don't need checks in the code like this:

const source = IS_WEB
    ? `https://api.lbry.tv/content/claims/${claim.name}/${claim.claim_id}/stream`
    : streaming_url;

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.