按开发者文档进行请求,响应405
接口文档:https://developer.apple.com/documentation/devicemanagement/activation_lock_a_device
实际请求如下:
curl --location --request POST 'https://mdmenrollment.apple.com/device/activationlock'
--header 'X-ADM-Auth-Session: 1720513551341O1O293...'
--header 'User-Agent: Apifox/1.0.0 (https://apifox.com)'
--header 'Content-Type: application/json'
--header 'Accept: /'
--header 'Host: mdmenrollment.apple.com'
--header 'Connection: keep-alive'
--data-raw '{"device": "FNXQX..."}'
这个问题要怎么解决?
Notifications
RSS for tagLearn about the technical aspects of notification delivery on device, including notification types, priorities, and notification center management.
Post
Replies
Boosts
Views
Activity
I am working on a VoIP based PTT app. Uses 'voip' apns notification type to get to know about new incoming PTT call.
When the app is in foreground, the app gets to know about incoming VoIP PTT call through incoming push notification. After receiving notification, the app receives audio from the server. This works properly, as expected.
The app faces issues in receiving apns notifications only when the app is in background.
Issue: My app is in background and iPhone locked, the server sends apns notification to the target iPhone about a new incoming VoIP call. Server received 200 success response code from APNS. But the app in background did not receive the notification. Second time, the server sends notification about second VoIP call. App did not receive notification. Third time, server sends notification about 3rd incoming call. This list goes on. Everytime server sends a notification to the target phone, success response is received from APNS.
Now, bring the app to foreground, the app receives all the pending notifications at once. This scenario happens only in a few phones. Those customers are missing PTT calls.
Can you please provide us suggestions to solve this issue ?
My app uses unrestricted-voip entitlement
I was able to successfully archive my main app that has a NotificationServiceExtension.
However, once I installed the app via Testflight, I was able to receive a notification, but the push notification modifications I did were not applied.
When I just ran it via Xcode, the push notification modifications worked.
Do I need to archive the NotificationServiceExtension instead of my main app?
Hello, I would like to implement the function of unsubscribe FCM topics that I was subscribing to when I received a specific push from the server.
It was implemented through "willPresent" when the app was running, but I don't know how to do it when the app is not running.
I activated the 'Background fetch' and 'Remote Notifications' options for now.
const message = {
notification: {
title: 'FCM Topic UnSubscribe',
body: 'TestTestTest',
},
data: {
payload: JSON.stringify(payloadJson)
},
apns: {
payload: {
aps: {
sound: 'default',
'mutable-content': 1,
'content-available': 1
}
}
},
topic: 'unsubscribe_topic',
};
Test node code
Payload contains the type of topic you want to unsubscribe from.
And I added a function to receive push from didReceiveRemoteNotification and handle logic.
But this doesn't work.
Does Remote Notification (content-available) not work in iOS's Not running and Suspended state??
I'm also using the Notification Service Extension, is this related to it?
I need to access notification data that accumulates in the Notification Center, similar to text messages, through BLE communication in my app. How can I achieve this?
Hello, I'm using 'App Store Server Notifications V2'.
I have a question about 'CONSUMPTION_REQUEST' notification in 'notificationType'.
I was wondering if there would be any impact on refunds if I received this notification and didn't respond. (Always refund etc..)
I'm developing a macOS application called Blurt, which aims to provide enhanced notification management in MacOS. The core functionality I'm trying to implement is the ability to intercept and display notifications from various applications in a custom interface.
Current implementation:
Using AppDelegate to handle application lifecycle
Implemented UNUserNotificationCenterDelegate for handling notifications
Created a custom NotificationService extension
Challenges:
Unable to intercept notifications from other applications
System notifications are not being captured by our app
What I've tried:
Using DistributedNotificationCenter to observe system-wide notifications
Implementing a Notification Service Extension
Exploring NSWorkspace notifications
Current roadblocks:
Apple's sandboxing and security model seems to prevent direct access to other apps' notifications
Unable to find a sanctioned API for system-wide notification interception
Questions:
Is there a recommended approach to creating a centralized notification management system within Apple's guidelines?
Are there any specific system notifications or events we can legally subscribe to that might help achieve similar functionality?
How do other notification management apps (if any exist) handle this limitation?
Are there any upcoming APIs or features in macOS that might address this use case?
I'm open to alternative approaches or pivoting the app's functionality if necessary. Any insights, suggestions, or resources would be greatly appreciated.
Thank you in advance for your help!
I have some C++ code to embed in my Application and hence enabling the setting C++ and Objective C ++ compatibility settings to C++/objective-C++ under build settings of my project .Once I enable it I am not receiving any push notification display when I'm in foreground even though I have the required willPresent function handler in app delegate.
Also observed that the code is going into didReceiveRemoteNotification function handler.
But once I disable the setting or change the setting to c/objective-c,then the flow is working fine and I'm getting the push notification on foreground.
Request you to please help me here
how can I customize local notifications contains GIF when my app scanning NFC tags and get different data from NFC tags.
How can I observe notifications triggered by scanning NFC in backgroundMode, I want to customize notifications, add Gif or Image to notification content. because the merchants want to display their images when shopper take their iPhone near goods.
I am getting a lot of messages of the nature that follows;
"RoomPlanExampleApp[606:114689] [ClientDonation] (+[PPSClientDonation sendEventWithIdentifier:payload:]) Invalid inputs: payload={
aneModelPath = "/System/Library/PrivateFrameworks/ObjectUnderstanding.framework/PrecompiledModels/od_af_online.bundle/H14G.bundle/main/main_ane/model.hwx";
bundleIdentfier = "com.example.apple-samplecode.RoomPlanExampleApp9QSS565686";
}"
WHAT is the component origin of the message? What can be done to remedy it?
This is another example of an error message that does not have enough information for the developer to take remedial action.
We are using sonoma OS for generating device token for iPhone real devices,
we are using certificate authentication mechanism for APNs cloud server to send the push notification to the actual device.
Actual mobile device not receiving push messages, i am using my own client to send request APNs cloud.
some how my actual device is not receiving push messages
I have developed an app using Flutter that utilizes the Push to Talk framework on iOS. The Push to Talk feature works perfectly in debug mode, but after archiving the build and installing it on an iOS 17 device, the Push to Talk functionality stops working.
Here are the steps I have already taken:
Enabled background modes.
Enabled Push to Talk capabilities.
Despite these settings, the issue persists in the archive build.
Has anyone else encountered this issue? What additional steps or configurations are required to get Push to Talk working in the archive build on iOS 17?
Any help or guidance would be greatly appreciated. Thank you!
I'm excited to bring my Live Activity to Apple Watch via the .supplementalActivityFamilies([.small]) modifier.
However, I'm also wondering whether it is possible for my watchOS app, separately, to initiate a Live Activity and receive updates for it via push notification. From my testing it seems like no, but the function call itself can be made, since ActivityKit is available on watchOS.
Are there any other recommendations for how to go about initiating a Live Activity from a watchOS app? Would I have to communicate with a companion iOS app to start the Live Activity on the phone instead?
I have setup my https server to receive App Store Server Notification. But I can not receive the test notification. The following is what I did and checked:
Running my https server (It's a simple https server build with python) on port 11234. The server url is https://recorderplus.com:11234
Setup the sandbox server url in App Store Connect: https://recorderplus.com:11234
Use App Store Server Library(python) to request a test notification, And get a response: SendTestNotificationResponse(testNotificationToken='f6ea15ca-0f4f-4233-8ae6-6ecc8a7ab43c_1719371691827')
But my https server did not receive the test notification.
To make sure my https server works fine. In browser(firefox) I input "https://recorderplus.com:11234", the browser can get the result page from https server.
My https server also support Post command, I run the command "curl -X POST -d "test" https://recorderplus.com:11234", my https server can get the post and print it.
Did I miss anything? Is there anything I should do or check to make my server receive the test notification?
I have an iOS app which uses Notification Service Extension (NSE) to process incoming notifications before it displayed to user.
In NSE, as part of initialization of my app, I need to iterate through a 2D array. There are roughly 65k iterations. I've noticed that this iteration fails somewhere in between and the NSE process crashes... I can say it crashes because the logs stopped in between the iterations. This results in 'unmodified notification' getting displayed immediately, whereas NSE is granted 30 sec of background execution.
My question is, why does this happen? The above iteration of 2D array works in app, but fails in NSE. Is there some kind of restriction on background extensions? - the documentation only talks about a time limit of 30sec. If there is some kind of restriction (like CPU and memory), how does one know this and code for it... since Apple did not provide any documentation. Or perhaps, there is a completely different reason?
If receive an file by the air drop when the iPhone is unlocked only with the face id ( i mean like when you are only looking at the time or the notification) can’t accept the file also when you slide down the notification you can’t accept it also . Thx
Although I disable notification permission in setting, still receive push notification when app in foreground
AppDelegate::application(_:didReceiveRemoteNotification:fetchCompletionHandler:)[L:------------------didReceiveRemoteNotification [AnyHashable("aps"): {
alert = {
body = "Push payload body";
subtitle = "Test push notification";
title = "Push Hero";
};
}]------------------]
It is received fine when the watch app is in the foreground.
Code sample:
import Foundation
import PushKit
final class PushNotificationProvider: NSObject {
let registry = PKPushRegistry(queue: nil)
override init() {
super.init()
registry.delegate = self
registry.desiredPushTypes = [.complication]
}
func pushRegistry(_ registry: PKPushRegistry, didUpdate pushCredentials: PKPushCredentials, for type: PKPushType) {
Log("token received")
}
func pushRegistry(_ registry: PKPushRegistry, didReceiveIncomingPushWith payload: PKPushPayload, for type: PKPushType, completion: @escaping () -> Void) {
Log("push received")
completion()
}
}
Watch app:
import SwiftUI
@main
struct XX_Watch_App: App {
@WKApplicationDelegateAdaptor var appDelegate: XXWearableAppDelegate
private let push = PushNotificationProvider()
var body: some Scene {
WindowGroup {
AppView(...)
}
}
}
It is received fine when the watch app is in the foreground.
Code sample:
import Foundation
import PushKit
final class PushNotificationProvider: NSObject {
let registry = PKPushRegistry(queue: nil)
override init() {
super.init()
registry.delegate = self
registry.desiredPushTypes = [.complication]
}
func pushRegistry(_ registry: PKPushRegistry, didUpdate pushCredentials: PKPushCredentials, for type: PKPushType) {
print("token recieved")
}
func pushRegistry(_ registry: PKPushRegistry, didReceiveIncomingPushWith payload: PKPushPayload, for type: PKPushType, completion: @escaping () -> Void) {
print("push recieved")
completion()
}
}
Watch app:
import SwiftUI
@main
struct XX_Watch_App: App {
@WKApplicationDelegateAdaptor var appDelegate: XXWearableAppDelegate
private let push = PushNotificationProvider()
var body: some Scene {
WindowGroup {
AppView(...)
}
}
}