GithubHelp home page GithubHelp logo

Comments (15)

GoogleCodeExporter avatar GoogleCodeExporter commented on July 24, 2024
A few more functions to add.

/**
     * Gets the Voicemail page raw source code.
     *
     * @return the Voicemail
     * @throws IOException
     *             Signals that an I/O exception has occurred.
     */
    public String getVoicemail() throws IOException {
        return get(voicemailURLString);
    }

    public String getVoicemailPage(int page) throws IOException {
        return get(voicemailURLString,page);
    }

        /**
     * Downloads a voicemail
     *
         * @param id of the voicemail to download
     * @return byte output stream
     * @throws IOException
     *             Signals that an I/O exception has occurred.
     */
        public ByteArrayOutputStream downloadVoicemail(String msgID) throws IOException
        {
           ByteArrayOutputStream outputStream = new ByteArrayOutputStream();

           try
           {
               URL u = new URL (voicemailDownloadURLString + msgID);
               HttpURLConnection huc = (HttpURLConnection)u.openConnection () ;
               huc.setRequestProperty("Authorization", "GoogleLogin auth="+authToken);
               huc.setRequestProperty("User-agent", USER_AGENT);
               huc.setRequestMethod ("GET");
               huc.connect() ;
               InputStream is = huc.getInputStream();

               if(huc.getResponseCode() == HttpURLConnection.HTTP_OK)
               {
                   byte[] buffer = new byte [4096];
                   int bytes = 0;

                   while(true)
                   {
                       bytes = is.read(buffer);
                       if(bytes <= 0)
                           break;
                       outputStream.write(buffer, 0, bytes);
                   }

                   outputStream.flush();
               }

               huc.disconnect ();

               return outputStream;
           }
           catch(IOException e)
           {
               System.out.println ( "Exception\n" + e ) ;
           }

           return null;
        }

Original comment by [email protected] on 26 Sep 2010 at 6:12

from google-voice-java.

GoogleCodeExporter avatar GoogleCodeExporter commented on July 24, 2024
Monstrfolk,

Would you like to be added as a committer?  Is your email [email protected]? 
 Feel free to email me directly to discuss it

-Joseph

Original comment by [email protected] on 26 Sep 2010 at 9:46

from google-voice-java.

GoogleCodeExporter avatar GoogleCodeExporter commented on July 24, 2024
sounds good to me. I can add onto this. I have a php google voice api that I 
have built from many web sources. Basically I am just converting my php api to 
java.

Original comment by [email protected] on 26 Sep 2010 at 9:53

from google-voice-java.

GoogleCodeExporter avatar GoogleCodeExporter commented on July 24, 2024
oh...i can't seem to figure out where I can get your email from this website.

Original comment by [email protected] on 26 Sep 2010 at 9:54

from google-voice-java.

GoogleCodeExporter avatar GoogleCodeExporter commented on July 24, 2024
It is malone dot joseph at gmail

Original comment by [email protected] on 26 Sep 2010 at 11:02

from google-voice-java.

GoogleCodeExporter avatar GoogleCodeExporter commented on July 24, 2024
google voice is having problems with sign on subscribed users for the BB Bold 
9000 with updated OS. It is somehow reading subscribed users as unsubscribed. I 
do not understand why. 

Original comment by [email protected] on 29 Sep 2010 at 2:33

from google-voice-java.

GoogleCodeExporter avatar GoogleCodeExporter commented on July 24, 2024
I've added this to monstrfolk because I see he's a committer now even though I 
haven't seen these functions added yet.

Original comment by [email protected] on 6 Jan 2011 at 2:50

  • Changed state: Accepted

from google-voice-java.

GoogleCodeExporter avatar GoogleCodeExporter commented on July 24, 2024
Liquid, what do you want me to add or fix?

Original comment by [email protected] on 12 Jan 2011 at 11:23

from google-voice-java.

GoogleCodeExporter avatar GoogleCodeExporter commented on July 24, 2024
Hey guys,

I'm working on some scripting for an on-duty phone system that I maintain, and 
I have been working with google-voice-java for the most part.

I see that you guys have been working on the delete function (as based on my 
reading in this thread), but I couldn't find the function in the documentation.

Is there some reading that I could be doing on how to use this to delete all of 
the sms messages in an accounts inbox?

Thanks for any help =)

Original comment by [email protected] on 12 Apr 2011 at 9:23

from google-voice-java.

GoogleCodeExporter avatar GoogleCodeExporter commented on July 24, 2024
monstrfolk, I was going to let you add and test the functions you added above 
and just commit them. 

B.C.,

These aren't in the repository yet. You should be able to add them locally and 
compile the library yourself though.

Original comment by [email protected] on 12 Apr 2011 at 10:21

from google-voice-java.

GoogleCodeExporter avatar GoogleCodeExporter commented on July 24, 2024
those functions should be already be added. i committed them months ago.

comment #9. you can create a function to delete all messages by querying each 
page of messages then deleting each message on every page.

I have also built a fully functioning parser that works for Voicemails and SMS 
messages.

It could be integrated into the current project if people are interested.

Original comment by [email protected] on 27 Apr 2011 at 5:50

  • Added labels: Type-Enhancement
  • Removed labels: Type-Defect

from google-voice-java.

GoogleCodeExporter avatar GoogleCodeExporter commented on July 24, 2024
Monstrfolk, I am assuming you completed Voicemail SMS parser commits???  

Can I close off this issue?

Original comment by [email protected] on 3 Feb 2012 at 3:40

from google-voice-java.

GoogleCodeExporter avatar GoogleCodeExporter commented on July 24, 2024
Monstrfolk, thank you for adding parsers for these functions. I'm checking them 
out now, and will using them in my project that I am currently working on.

Original comment by [email protected] on 14 Feb 2012 at 8:59

from google-voice-java.

GoogleCodeExporter avatar GoogleCodeExporter commented on July 24, 2024
I have confirmed that deleting SMS messages works correctly; I would think that 
it is safe to close this one.

Original comment by [email protected] on 15 Feb 2012 at 8:29

from google-voice-java.

GoogleCodeExporter avatar GoogleCodeExporter commented on July 24, 2024

Original comment by [email protected] on 25 Mar 2012 at 2:05

  • Changed state: Fixed

from google-voice-java.

Related Issues (20)

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.