R-a-dio / R-a-dio-Amazing-Android-App

>wessie doesn't push to master for every commit
MIT License
11 stars 5 forks source link

Sup, also project status? #2

Closed resttime closed 7 years ago

resttime commented 7 years ago

Got a notification from this project. Although I don't use Android anymore, I might be able to help pitch in during my spare time. I feel bad that the previous app I worked on never deployed and sank into all kinds of code hell.

Has there been any updates regarding an API for search/request song? I've also acquired a bit of web programming experience so I could help with that as well.

CaptainJet commented 7 years ago

Assigned @Kethsar to issue: He pinged everyone haha.

KilimIG commented 7 years ago

hi rest!

we're doing pretty good right now, we'll be finished with this in a few days' time; if that, however i can 100% see the code being filled to the brim and memory leaking being an issue (maybe? idk none of us know what we're doing)

any help would, well, help!

resttime commented 7 years ago

Some Random List of Possible Features

I can help dev from any end. Also releasing something with basic features first would be best. That's a mistake the old app didn't do even though it was jacked full of features and used to work. Reading through the code, it seems like this one is on the right track. Here's a list of stuff along with some details that we can do but isn't necessary.

Lastly, I still have the old appkey, keystores, and passwords if needed for signing the application. They will be necessary if we're releasing under the same place. I think Hiroto(?) has them as well.

Tutorial

Just a basic "how to" use the app that people get when they start the app for the first time.

Streaming Schedule

So we know who's streaming and when.

Background Music (DONE)

Playing music without a MainActivity requires an Android service and it will start to complicate things by introducing a different lifecyle. If desired, this would be a fairly high priority after the first release since it will change how components will interact with one another.

Stop/Resume music for calls (DONE)

I think this was definitely very high feature wanted. If the Android people haven't changed their API then it'll be adding a listener onto the phone state.

Bluetooth Controls

So people can use with bluetooth controls like from a car or watch. I remember I had to implement this, not sure if new API facilitates it better.

Homescreen widget

Rice to control the music.

Music visualizer

Super rice

Music Equalizer

Super rice

Recording audio

Save away to a file when you want and listen in a later time.

Notifications

Rice stuff like DJ has changed or YOUR REQUESTED SONG IS PLAYINGH AHRAJHRJ AHRA or YOUR FAVORITE SONG IS PLAYING

Notification bar (DONE)

Ricing widget in that pull down bar to control the player.

Searches (DONE)

There's an API for searches. Autocompletion might be possible but will depend on whether we're willing to let the server handle it.

Requests (DONE)

I don't know about whether there's been API changes/additions but the way that the current website does it is by grabbing the id of a song when searching and POSTing it to /request/ with a CSRF token:

 $(".request-button").click(function (e) {
     e.preventDefault();
     var id = $(this).val(),
     token = $(this).closest("form").find("input[name='_token']").val();
     $.ajax({
     url: "/request/" + id,
     type: "POST",
     data: { _token: token },
     dataType: "json",
     success: function (data) {
         var result;

         if (data.error) {
         result = data.error;
         } else if (data.success) {
         result = data.success;
         } else {
         console.log(data);
         }

         $("#requests .modal-body").text(result);
         $("#requests").modal();

     }
     });

Basically we need a token that is provided to us by the server and the id of our song to make a request with this api. Unless the API has changed, this means using an http client and grabbing the token from the website with a GET then POST with the request. I believe the cookies need to be the same for both requests.

Favorites

This would require new API unless kept local I suppose.

Settings

For whatever if needed, or not. Perhaps things like toggling cellular data.

CaptainJet commented 7 years ago

Background Music, Search/Request, Notification Control we were already planning to implement, the others seem like they can wait.

On the note of request/search, the site has api for checking they can request at https://r-a-d.io/api/can-request and an api for searching at https://r-a-d.io/api/search/termtosearch. There's one for requesting too but idr what it is.

Feel free to fork the project and put in a pull request if you have time to implement any of these yourself.

As a note, we'd prefer solely to rely on the JSON API the site currently provides for as much as possible. No html scraping or webviews and such.

KilimIG commented 7 years ago

oh baby that list is great thanks

resttime commented 7 years ago

@CaptainJet Alright, I'll work on it in like a few days once I get access to my main machine.

I've confirmed with others that there's still no other endpoint for requesting except through the website. The HTML scraping is basically a last resort kinda thing I figured while I was waiting back then, definitely not good practice. I'll see if I can facilitate/implement the request endpoint.

@KilimIG np

CaptainJet commented 7 years ago

i'm just gonna edit the list post whenever we finish something

KilimIG commented 7 years ago

some more stuff we should add:

EASY

MEDIUM

KilimIG commented 7 years ago

also the whole pause on call whopps

CaptainJet commented 7 years ago

Added phone call muting/unmuting and opening the drawer by pressing buttons.

Kethsar commented 7 years ago

We should really split each potential thing to add into it's own 'Issue' so we can keep track of them better.

On that note, I have another to add. Update the notification with the song title and artist whenever a new song starts. That way a user can see what song is playing from their lock screen instead of having to open the app.

KilimIG commented 7 years ago

closing this for now we can pull from it later