Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add a 'listen' entrypoint to redirect to an audio only url #48

Closed
wants to merge 1 commit into from

Conversation

eadmaster
Copy link

get_result was also changed a bit...

@jaimeMF
Copy link
Owner

jaimeMF commented Jun 22, 2016

Two things:

  • Probably it should use bestaudio instead of m4a.
  • It can be implemented in a simpler way (in my opinion):
@route_api('listen')
def listen():
    args = dict(request.args)
    args.setdefault('format', 'bestaudio')
    return redirect(url_for('.play', **args))

@eadmaster
Copy link
Author

I've chosen mp4 because probably it is more compatible with older audio players that may lack opus support.

@jaimeMF
Copy link
Owner

jaimeMF commented Jun 24, 2016

I've chosen mp4 because probably it is more compatible with older audio players that may lack opus support.

If a player only supports m4a, you should specify the format.

@eadmaster
Copy link
Author

eadmaster commented Jun 26, 2016

Allrighty, i just have to add &format=m4a to my urls to get the audio track only...

@eadmaster eadmaster closed this Jun 26, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants