I have looked through all the examples that Microsoft have given for the Graph API to make calls. All the samples are using "Service Hosted Media", I am looking for an example for "Application Hosted Media". There is nothing in the documents what define what the "blob" attribute should be, I have played around using a SIP SDP with PCMU codec but all it gives is an error:
{"error":
{
"code":"9999",
"message":"Unknown internal server error.",
"innerError":
{
"date":"2025-02-05T04:36:18",
"request-id":"ada9f5d2-85d5-4f39-a539-40b8f628b043",
"client-request-id":"ada9f5d2-85d5-4f39-a539-40b8f628b043"
}
}
}
Has anyone had success with this API with Application Hosted Media.
I have tried to send this request where the blob is base64 encoded SIP SDP encapulated in a "MediaSession" object.
{
"@odata.type": "#microsoft.graph.call",
"callbackUri": ".ashx",
"source": {
"@odata.type": "#microsoft.graph.participantInfo",
"identity": {
"@odata.type": "#microsoft.graph.identitySet",
"application": {
"@odata.type": "#microsoft.graph.identity",
"displayName": "CallingBot",
"id": "6f78d2bb-4e78-408d-a739-e084d79f5863"
}
}
},
"targets": [
{
"@odata.type": "#microsoft.graph.invitationParticipantInfo",
"identity": {
"@odata.type": "#microsoft.graph.identitySet",
"user": {
"@odata.type": "#microsoft.graph.identity",
"displayName": "TestName",
"id": "496ebb4d-e5cc-4340-8359-3714c3bdd456"
}
}
}
],
"requestedModalities": [
"audio"
],
"TenantId": "dabdceb5-cddf-4257-8b35-9f5eb7ac03er",
"mediaConfig": {
"@odata.type": "#microsoft.graph.appHostedMediaConfig",
"blob": "eyJtZWRpYVNlc3Npb24iOnsiaWQiOiI4MDE2NDViOC1kOGUyLTQ3NTQtYTk4YS0zNmE2MzQ1M2FmYjciLCJzdHJlYW1zIjpbeyJzdHJlYW1JZCI6IjEiLCJtZWRpYVR5cGUiOiJhdWRpbyIsImRpcmVjdGlvbiI6InNlbmRyZWN2IiwidHJhbnNwb3J0Ijp7InByb3RvY29sIjoidWRwIiwiaXBBZGRyZXNzIjoiNTcuMy4xMDguMjE5IiwicG9ydCI6MTYzMDB9LCJjb2RlYyI6eyJuYW1lIjoiUENNVSIsImNsb2NrUmF0ZSI6ODAwMCwicGF5bG9hZFR5cGUiOjB9fV19fQ=="
}
}