Skip to content
App Notification Library for Jailbroken Devices
Objective-C Objective-C++ Shell
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
Packages
libnotificationd
libnotifications.xcodeproj
libnotifications
.gitignore
LatestBuild initial sync Aug 4, 2019
README.md

README.md

libnotifications

App Notification Library for Jailbroken Devices

Requires iOS10+

This library can be used in a process or a tweak. You can set up a rocketbootstrap server in SpringBoard if you're using in a sandboxed process & run this code there.

How to use in your tweak:

#include <dlfcn.h>

@interface CPNotification : NSObject
+ (void)showAlertWithTitle:(NSString*)title message:(NSString*)message userInfo:(NSDictionary*)userInfo badgeCount:(int)badgeCount soundName:(NSString*)soundName delay:(double)delay repeats:(BOOL)repeats bundleId:(nonnull NSString*)bundleId;
@end

void *handle = dlopen("/usr/lib/libnotifications.dylib", RTLD_LAZY);
if (handle != NULL) {                                            
    [objc_getClass("CPNotification") showAlertWithTitle:@"Holy Smokes!"
                                                message:@"This is the message!"
                                               userInfo:@{@"" : @""}
                                             badgeCount:1
                                              soundName:@"can be nil.caff" //research UNNotificationSound
                                                  delay:1.00 //cannot be zero & cannot be < 60 if repeats is YES
                                                repeats:NO
                                               bundleId:@"com.cokepokes.iNutt"];                                     
	dlclose(handle);
}
	

The app must have notification privileges. To do this you can add this BOOL to the Info.plist file for an app in /Applications:

<key>SBAppUsesLocalNotifications</key>
<true/>
You can’t perform that action at this time.