Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

In this Discussion

osTicket v1.10 (stable) and Maintenance Release v1.9.15 are now available! Go get it now

iPhone App created (Android to come)

Hi everyone,
 
We've been using the OSTicket program for years here at Atomic Computers and decided that it was a shame not to have a mobile app for it.  Our techs are out in the field often and find it cumbersome to log in through the browser on their phones to check on tickets or get credentials from a ticket.
 
Because we had the need to have a quick way to be notified and review tickets, we went ahead and created an iPhone app (currently working on Android), since that's what the majority of us use here, called eTicket.  We've been using the app for a couple months now and have decided to release the app on the iTunes app store.
 
The app has push notification, which is great to know when someone replies to a ticket or to let you know when you've been assigned a ticket.  You can turn the different alerts on and off using the settings.  And the app has all the functionality we use on a daily basis.
 
The app is easy to set up.  You simply put in your username and password, and the URL of your installation to OSTicket.  Of course, there are API files that need to be placed within your hosted install.  The API files create a SOAP server that allows the phones to communicate with your installation.  That is also where you would put your integration ID to receive push notifications.  You can find the files at osticketapp.com under “Downloads”.
 
The SOAP API files would be placed under the API folder within your install.  If you do not want push notifications, that's all you have to do.  If you do want push notifications, you just simply edit one value in one file.  Then you would also need to replace your ticket class file with the appropriate file from the files we provide.  After that you will be set to receive push notifications.
If you need assistance with the installation or configuration of the API and push notifications we can help, just email us at support@atomicx.com
 
Obviously, we are looking for feedback.  We would like to give away [10 of copies] free apps to users in exchange for that feedback.  You can view more information about the app at http://osticketapp.com or view the app in the iTunes store at https://itunes.apple.com/us/app/eticket/id888871509?mt=8 .  Just contact us if you are interested in a free copy.
 
Thank you,
The Atomic Computers team
«1

Comments

  • Will replacing the "class.ticket.php" change anything for desktop/PC users? 
  • Hi Raj,

    I know we've already talked in email, but just in case someone else also wonders, the only change made to the class.ticket.php is adding a reference to the function script in the API files at the top of the file, then adding in calls to push messages through the API to send the push messages to the phones (when applicable). You can use the app without replacing this file, but you would not receive push notifications.

    If you have any other questions just let me know.

    Thanks,
    James
  • Hi James,

    When setting up the iPhone app i get a warning: Invalid phone ID and cannot proceed after that :-(
    I have an iPhone 4S with iOS 7.

    Regards, Eric
  • Hi Eric,

    Is this the same Eric that emailed too?  If so, it seems to be an issue where your site is actually redirecting to an older site you used to host (as per our conversation).  If this can be resolved, we'll be in business.  I can connect remotely and help you if you'd like, just let me know.

    Thanks,
    James
  • I've just updated our API files so that other countries can use our app.  We had an issue with someone from Germany downloading the app and having it crash on them.  It was due to the character encoding.  No app changes were made.  This fix should fix anyone from other countries that were having this problem due to special characters.

    Thanks,
    James
  • Hi

    I would love to test this app out if the offer still stands

    Peter
  • edited July 2014
    Hi Peter,

    It does.  Please just send us an email at support@atomicx.com to receive your free code.

    Thanks,
    James
  • Thanks James,

    App is working fine so far on our tests :-)

    Only notification is a badge on the icon. Is it also supposed to show on lockscreen or dropdown?
  • Take that back. It is working as expected and notifying in all places, lockscreen, dropdown and badge
  • James,

    Inline images or attachments do not show on the app. Is that functionality excluded?

  • James, Inline images or attachments do not show on the app. Is that functionality excluded?
    Hi Raj,

    That has not yet been included, but will be.  I am hoping to add the attachments in the next revision.

    Thanks,
    James
  • Hi, I'd like to test it as well. I'm looking for a mobile app to integrate with osticket. Can you lend me a demo version? I can give you feedback.
  • Hi Marco,

    I'll be sending you a code shortly.

    Thanks,
    James
  • edited July 2014
    Response has been good.  We've decided to give away additional copies (1 per company) of the iPhone/iPad app.  If you are interested, please contact us at support@atomicx.com .

    Thanks to everyone who has given your feedback so far.  Please keep it coming.  We are creating a bug-fix list and will be releasing an update after receiving more feedback and correct the bug list.

    We have already received feedback about creating a multi-lingual version of the OSTicket eTicket mobile app.  Is this something that some of you would be interested in?

    We are currently working on the Android version of the OSTicket eTicket app and will create a new thread when complete.

    Thanks,
    James
  • I like this thread, and have been waiting for the android version before I chime in.  But I do not mind testing it on my iPad (still not sure why why company got me an iPad).
  • Hi ntozier,

    Thanks for the help in the other thread.  Can you send a message to support@atomicx.com and I will send you a code to get the app for free?

    Thanks,
    James
  • You already did.  :)  Thanks
  • James,

    The app looks promising. I have emailed the above referenced asking for a code to review it. I noticed on the site in the downloads section it says that it is compatible with v1.9.1 of osTicket. As the latest is v1.9.2, is this also supported or should I hold off on installation?

    Thanks,

    Ryan
  • Hi Ryan,

    The app itself is actually good for most any version of OSTicket.  However, I had to update the class.ticket.php file for the version compatibility.  This has been done (just now) and is good to go.

    Also, for anyone who's downloaded this before, if you are using version 1.9.1 (or 1.9.2), you will want to re-download the API files and replace the class.ticket.php file.  The push notifications for 1.9.1 were all set to notify as if it was a new ticket instead of new, reply, or assigned.

    Lastly, we have given out all of the free downloads we had (more than how many we were going to, actually), so there will not be any more free downloads at the moment.  We are receiving some good feedback and hope to make the next version even better.  Thanks to everyone who participated.

    Thanks,
    James
  • James,

    Should the app work if your OSTicket site is running on a alternative port?

    Whenever i enter the domain where my site is running on; http://support.**.nl:35413 and i enter my username/password it comes up with "Invalid phone ID".
  • Just got it working on our 1.7, requires a few code tweaks.

    I diff'd the class.tickets.php files.. merged in the changes, sweet. Reset permissions on /api/soap/ when it became obvious that I'd broken the whole thing trying to require files that the web-server can't read.. ;-)

    Next, got one of our reps to guinea-pig the app, wasn't sure what the url is, perhaps your documentation should say that its the Client url, even for staff.. bit of faffing about trying to figure that out, not that big of a deal I suppose.

    Next, started seeing massive errors in the logs. Turns out our older version of php (the reason we haven't gone beyond 1.7 yet) baulks at lambda functions.. so, that lovely inline usort algorithm you've implemented (tickets.class.php:384), nuh.. had to name it to get it working. (global scope, I'm useful, but lazy), if you wished backwards compatibility, or if my 1.7 brothers attempt this, you'll need to rewrite it thusly:
                usort($messages, 'sort_thread');

    Create the following after the class definition:
        function sort_thread($a, $b) {
             return strtotime($a['message']['created']) - strtotime($b['message']['created']);
        };


    Next major errors preventing anything happening, the thread, it needed to be rewritten (ticket.class.php:289) to something like this:
                if (isVersion('1.7'))
                {
                    if($thread=$ticket->getThreadEntries(array('M', 'R'))) {

    ...

    Which meant the "getNotes" function also needed expanding, which is admittedly a copypasta of the 1.8+ code, but with the correct $thread.

                if(isVersion('1.7')){
                     if($thread = $ticket->getThreadEntries(array('N'))) {
                        foreach($thread as $entry) {
                            if ($entry['thread_type'] == 'N')
                                $notes[] = array(
                                    'created' => date(DATE_RFC3339, strtotime($entry['created'])),
                                    'staff' => Format::htmlchars($entry['staff_id']),
                                    'title' => Format::htmlchars($entry['title']),
                                    'note' => Format::htmlchars($entry['body'])
                                );
                        }
                    }
                }


    Finally, I modified your == null thing (ticket.class.php:198), into:

                // Do we have a valid ticket?
                if (!($ticket instanceof Ticket))


    I probably should have detailed that in "file order".. but that was the order I found them in.

    Quick question about this "Integration ID" field in notify.php.. how would that work for more than one user?
    Also, does it use your servers? (url = "http://atomiccomputers.com/eTicketAPI.php")
    I'm sure there is something odd about that, just can't put my finger on it.. guess we'll stick to email notifications for now.
  • James, Should the app work if your OSTicket site is running on a alternative port? Whenever i enter the domain where my site is running on; http://support.**.nl:35413 and i enter my username/password it comes up with "Invalid phone ID".
    Hi Yorickr,

    It will work, but only if we know what port it is that it is running on.  Our firewall has only specific outbound ports open, so unless we add it to the list it will not work.  We are thinking of only allowing certain ports to be open for this, but for now we are just opening what people would like to use.

    Thanks,
    James
  • Just got it working on our 1.7, requires a few code tweaks. I diff'd the class.tickets.php files.. merged in the changes, sweet. Reset permissions on /api/soap/ when it became obvious that I'd broken the whole thing trying to require files that the web-server can't read.. ;-) Next, got one of our reps to guinea-pig the app, wasn't sure what the url is, perhaps your documentation should say that its the Client url, even for staff.. bit of faffing about trying to figure that out, not that big of a deal I suppose. Next, started seeing massive errors in the logs. Turns out our older version of php (the reason we haven't gone beyond 1.7 yet) baulks at lambda functions.. so, that lovely inline usort algorithm you've implemented (tickets.class.php:384), nuh.. had to name it to get it working. (global scope, I'm useful, but lazy), if you wished backwards compatibility, or if my 1.7 brothers attempt this, you'll need to rewrite it thusly:             usort($messages, 'sort_thread'); Create the following after the class definition:     function sort_thread($a, $b) {          return strtotime($a['message']['created']) - strtotime($b['message']['created']);     }; Next major errors preventing anything happening, the thread, it needed to be rewritten (ticket.class.php:289) to something like this:             if (isVersion('1.7'))             {                 if($thread=$ticket->getThreadEntries(array('M', 'R'))) { ... Which meant the "getNotes" function also needed expanding, which is admittedly a copypasta of the 1.8+ code, but with the correct $thread.             if(isVersion('1.7')){                  if($thread = $ticket->getThreadEntries(array('N'))) {                     foreach($thread as $entry) {                         if ($entry['thread_type'] == 'N')                             $notes[] = array(                                 'created' => date(DATE_RFC3339, strtotime($entry['created'])),                                 'staff' => Format::htmlchars($entry['staff_id']),                                 'title' => Format::htmlchars($entry['title']),                                 'note' => Format::htmlchars($entry['body'])                             );                     }                 }             } Finally, I modified your == null thing (ticket.class.php:198), into:             // Do we have a valid ticket?             if (!($ticket instanceof Ticket)) I probably should have detailed that in "file order".. but that was the order I found them in. Quick question about this "Integration ID" field in notify.php.. how would that work for more than one user? Also, does it use your servers? (url = "http://atomiccomputers.com/eTicketAPI.php") I'm sure there is something odd about that, just can't put my finger on it.. guess we'll stick to email notifications for now.
    Hi Grizly,

    I applaud your work on updating the class.ticket.php file, but unfortunately you went way above and beyond what was actually needed, I'm sorry to say.  I would have made one or 1.7.*, but I didn't not have that version when I made these.  However, the updates I made to class.ticket.php are only for push notifications.  If you do not need to use push notifications you do not need to update this file.

    If you do want to use push notifications, you only need to do these things.  Add this to the top under all the other includes:



    //code added by atomic computers for eticket app integration
    if (file_exists(dirname(dirname(__FILE__))."/api/soap/notify.php")) {
        require_once(dirname(dirname(__FILE__))."/api/soap/notify.php");
    }

    Then, in all of the places where it sends and email notification, you will add this:

    //code added by atomic computers for eticket app integration
    $args = array(
        'action' => 'sendPushNotification',
        'ticket_id' => $this->getId(),
        'staff_id' => $staff->getId(),
        'message' => $alert['subj'],
        'type' => "notify_new"
    );

    post_json($args);

    It is always inside this area:

    foreach( $recipients as $k=>$staff) {
        if(!is_object($staff) || !$staff->isAvailable() || in_array($staff->getEmail(), $sentlist)) continue;
        $alert = $this->replaceVars($msg, array('recipient' => $staff));
        $email->sendAlert($staff->getEmail(), $alert['subj'], $alert['body'], null, $options);
        $sentlist[] = $staff->getEmail();
       
        //code added by atomic computers for eticket app integration
        $args = array(
            'action' => 'sendPushNotification',
            'ticket_id' => $this->getId(),
            'staff_id' => $staff->getId(),
            'message' => $alert['subj'],
            'type' => "notify_new"
        );
       
        post_json($args);
    }
    This will have it send a push notification to each staff member who would have been notified by email.

    The issue here is the 'type' key.  In this example, it says 'notify_new'.  But you also have 'notify_assign' for the area of the class file where it sends an email for the ticket being assigned, 'notify_overdue', 'notify_transfer', and 'notify_reply' for all of their corresponding areas.  Then I use 'notify_misc' for anything else.

    That is all of the changes made to the ticket class file.  The rest of the file should be the default file that came with your version of OSTicket.

    The 'Integration ID' field is for everyone using your installation of OSTicket.  Everyone has the same integration ID that logs into your system.  (It goes by the URL.)  But yes, all push notifications go through our server.  We have to use a .pem file to sign all of the push notifications before we send them to Apple, which the .pem file is on our server.

    Let me know if you have any other questions.

    Thanks,
    James

  • Hi James,

    I wondered, especially when those post_json errors appeared for non-app users.. That was disabled shortly after, I just didn't document it here.

    However, I did have to change your code for the app user to even start using it. Those changes weren't to osTicket code mate, to yours.

    Anyway, the user is happy as can be, so I'm happy, thank you very much!
  • Hi James,

    I work for a school and am looking at implementing OS Ticket and your iOS App would be perfect. Are you still offering a free copy to organisations?

    If so it would be greta to get a copy.

    Kind regards,
    Ben
  • I also work for a school, in higher education, and we started widely using osticket only about a year ago and love it. We would also be interested in evaluating the app with 1 or 2 users before deciding to implement it on a larger scale. 

    I know I am late to the party but are there free copies still up for grabs?

    Thanks in advance for all your hard work in developing this,

    B
  • James,

    I have replaced the class file and updated the notify file with my ID, but i still dont get any push notification settings. 

    IOS 7.1.2
    osTicket Versionv1.9.3-58-g0130809 (0130809)

    I can login with no problem and see the tickets.
    and open tickets and such, just no push notification.

    thanks
    Dave


  • Hi Dave,

    When you say you don't get any settings, do you just mean you are not receiving any push notifications at all?

    Can you send me a message through the app so I can get your app ID please?  I'll be able to check it out from there.

    Thanks,
    James
  • To All,

    Sorry, but we are no longer giving away free copies of the app.  We are receiving good feedback and have a list of bugs to fix and features to include.  If we start to give away more apps, we'll let you know.

    Thanks,
    James
  • Maybe you could use the new TestFlight feature from Apple?
    Then it's only the betaversions.. ;-)
Sign In or Register to comment.