Kejadian Microsoft Outlook
Artikel ini menyediakan properti dan skema untuk peristiwa Microsoft Outlook yang diterbitkan Microsoft Graph API. Untuk pendahuluan skema peristiwa, lihat skema CloudEvents.
Tipe kejadian yang tersedia
Nama kejadian | Deskripsi |
---|---|
Microsoft.Graph.EventCreated | Dipicu saat kejadian di Outlook dibuat. |
Microsoft.Graph.EventUpdated | Dipicu saat kejadian di Outlook diperbarui. |
Microsoft.Graph.EventDeleted | Dipicu saat kejadian di Outlook dihapus. |
Microsoft.Graph.ContactCreated | Dipicu saat kontak di Outlook dibuat. |
Microsoft.Graph.ContactUpdated | Dipicu saat kontak di Outlook diperbarui. |
Microsoft.Graph.ContactDeleted | Dipicu saat kontak di Outlook dihapus. |
Microsoft.Graph.MessageCreated | Dipicu saat pesan di Outlook dibuat. |
Microsoft.Graph.MessageUpdated | Dipicu saat pesan di Outlook diperbarui. |
Microsoft.Graph.MessageDeleted | Dipicu saat pesan di Outlook dihapus. |
Contoh peristiwa
Saat kejadian dipicu, layanan Event Grid mengirim data mengenai kejadian tersebut ke tujuan berlangganan. Bagian ini berisi contoh tampilan data tersebut untuk setiap kejadian.
Kejadian Microsoft.Graph.EventCreated
{
"id": "00d8a100-2e92-4bfa-86e1-0056dacd0fce",
"type": "Microsoft.Graph.EventCreated",
"source": "/tenants/<tenant-id>/applications/<application-id>",
"subject": "Events/<event-id>",
"time": "2024-05-22T22:24:31.3062901Z",
"datacontenttype": "application/json",
"specversion": "1.0",
"data": {
"@odata.type": "#Microsoft.OutlookServices.Notification",
"Id": null,
"SubscriptionExpirationDateTime": "2024-06-22T23:56:30.1307708Z",
"ChangeType": "created",
"subscriptionId": "MTE1MTVlYTktMjVkZS00MjY3LWI1YzYtMjg0NzliZmRhYWQ2",
"resource": "https://outlook.office365.com/api/beta/Users('userId@tenantId')/Events('<event id>')",
"clientState": "<client state>",
"resourceData": {
"Id": "<event id>",
"@odata.etag": "<tag id>",
"@odata.id": "https://outlook.office365.com/api/beta/Users('userId@tenantId')/Events('<event id>')",
"@odata.type": "#Microsoft.OutlookServices.Event",
"OtherResourceData": "<some other resource data>"
}
}
}
Kejadian Microsoft.Graph.EventUpdated
{
"id": "00d8a100-2e92-4bfa-86e1-0056dacd0fce",
"type": "Microsoft.Graph.EventUpdated",
"source": "/tenants/<tenant-id>/applications/<application-id>",
"subject": "Events/<event-id>",
"time": "2024-05-22T22:24:31.3062901Z",
"datacontenttype": "application/json",
"specversion": "1.0",
"data": {
"@odata.type": "#Microsoft.OutlookServices.Notification",
"Id": null,
"SubscriptionExpirationDateTime": "2024-06-22T23:56:30.1307708Z",
"ChangeType": "updated",
"subscriptionId": "MTE1MTVlYTktMjVkZS00MjY3LWI1YzYtMjg0NzliZmRhYWQ2",
"resource": "https://outlook.office365.com/api/beta/Users('userId@tenantId')/Events('<event id>')",
"clientState": "<client state>",
"resourceData": {
"Id": "<event id>",
"@odata.etag": "<tag id>",
"@odata.id": "https://outlook.office365.com/api/beta/Users('userId@tenantId')/Events('<event id>')",
"@odata.type": "#Microsoft.OutlookServices.Event",
"OtherResourceData": "<some other resource data>"
}
}
}
Kejadian Microsoft.Graph.EventDeleted
{
"id": "00d8a100-2e92-4bfa-86e1-0056dacd0fce",
"type": "Microsoft.Graph.EventDeleted",
"source": "/tenants/<tenant-id>/applications/<application-id>",
"subject": "Events/<event-id>",
"time": "2024-05-22T22:24:31.3062901Z",
"datacontenttype": "application/json",
"specversion": "1.0",
"data": {
"@odata.type": "#Microsoft.OutlookServices.Notification",
"Id": null,
"SubscriptionExpirationDateTime": "2024-06-22T23:56:30.1307708Z",
"ChangeType": "deleted",
"subscriptionId": "MTE1MTVlYTktMjVkZS00MjY3LWI1YzYtMjg0NzliZmRhYWQ2",
"resource": "https://outlook.office365.com/api/beta/Users('userId@tenantId')/Events('<event id>')",
"clientState": "<client state>",
"resourceData": {
"Id": "<event id>",
"@odata.etag": "<tag id>",
"@odata.id": "https://outlook.office365.com/api/beta/Users('userId@tenantId')/Events('<event id>')",
"@odata.type": "#Microsoft.OutlookServices.Event",
"OtherResourceData": "<some other resource data>"
}
}
}
Kejadian Microsoft.Graph.ContactCreated
{
"id": "00d8a100-2e92-4bfa-86e1-0056dacd0fce",
"type": "Microsoft.Graph.ContactCreated",
"source": "/tenants/<tenant-id>/applications/<application-id>",
"subject": "Contacts/<contact-id>",
"time": "2024-05-22T22:24:31.3062901Z",
"datacontenttype": "application/json",
"specversion": "1.0",
"data": {
"@odata.type": "#Microsoft.OutlookServices.Notification",
"Id": null,
"SubscriptionExpirationDateTime": "2024-06-22T23:56:30.1307708Z",
"ChangeType": "created",
"subscriptionId": "MTE1MTVlYTktMjVkZS00MjY3LWI1YzYtMjg0NzliZmRhYWQ2",
"resource": "https://outlook.office365.com/api/beta/Users('userId@tenantId')/Contacts('<contact id>')",
"clientState": "<client state>",
"resourceData": {
"Id": "<contact id>",
"@odata.etag": "<tag id>",
"@odata.id": "https://outlook.office365.com/api/beta/Users('userId@tenantId')/Contacts('<contact id>')",
"@odata.type": "#Microsoft.OutlookServices.Contact",
"OtherResourceData": "<some other resource data>"
}
}
}
Kejadian Microsoft.Graph.ContactUpdated
{
"id": "00d8a100-2e92-4bfa-86e1-0056dacd0fce",
"type": "Microsoft.Graph.ContactUpdated",
"source": "/tenants/<tenant-id>/applications/<application-id>",
"subject": "Contacts/<contact-id>",
"time": "2024-05-22T22:24:31.3062901Z",
"datacontenttype": "application/json",
"specversion": "1.0",
"data": {
"@odata.type": "#Microsoft.OutlookServices.Notification",
"Id": null,
"SubscriptionExpirationDateTime": "2024-06-22T23:56:30.1307708Z",
"ChangeType": "updated",
"subscriptionId": "MTE1MTVlYTktMjVkZS00MjY3LWI1YzYtMjg0NzliZmRhYWQ2",
"resource": "https://outlook.office365.com/api/beta/Users('userId@tenantId')/Contacts('<contact id>')",
"clientState": "<client state>",
"resourceData": {
"Id": "<contact id>",
"@odata.etag": "<tag id>",
"@odata.id": "https://outlook.office365.com/api/beta/Users('userId@tenantId')/Contacts('<contact id>')",
"@odata.type": "#Microsoft.OutlookServices.Contact",
"OtherResourceData": "<some other resource data>"
}
}
}
Kejadian Microsoft.Graph.ContactDeleted
{
"id": "00d8a100-2e92-4bfa-86e1-0056dacd0fce",
"type": "Microsoft.Graph.ContactDeleted",
"source": "/tenants/<tenant-id>/applications/<application-id>",
"subject": "Contacts/<contact-id>",
"time": "2024-05-22T22:24:31.3062901Z",
"datacontenttype": "application/json",
"specversion": "1.0",
"data": {
"@odata.type": "#Microsoft.OutlookServices.Notification",
"Id": null,
"SubscriptionExpirationDateTime": "2024-06-22T23:56:30.1307708Z",
"ChangeType": "deleted",
"subscriptionId": "MTE1MTVlYTktMjVkZS00MjY3LWI1YzYtMjg0NzliZmRhYWQ2",
"resource": "https://outlook.office365.com/api/beta/Users('userId@tenantId')/Contacts('<contact id>')",
"clientState": "<client state>",
"resourceData": {
"Id": "<contact id>",
"@odata.etag": "<tag id>",
"@odata.id": "https://outlook.office365.com/api/beta/Users('userId@tenantId')/Contacts('<contact id>')",
"@odata.type": "#Microsoft.OutlookServices.Contact",
"OtherResourceData": "<some other resource data>"
}
}
}
Peristiwa Microsoft.Graph.MessageCreated
{
"id": "00d8a100-2e92-4bfa-86e1-0056dacd0fce",
"type": "Microsoft.Graph.MessageCreated",
"source": "/tenants/<tenant-id>/applications/<application-id>",
"subject": "Users/<user-id>/Messages/<message-id>",
"time": "2024-05-22T22:24:31.3062901Z",
"datacontenttype": "application/json",
"specversion": "1.0",
"data": {
"@odata.type": "#Microsoft.OutlookServices.Notification",
"Id": null,
"SubscriptionExpirationDateTime": "2024-06-22T23:56:30.1307708Z",
"ChangeType": "created",
"subscriptionId": "MTE1MTVlYTktMjVkZS00MjY3LWI1YzYtMjg0NzliZmRhYWQ2",
"resource": "Users/<user-id>/Messages/<message-id>",
"clientState": "<client state>",
"tenantId":"<tenant-id>",
"resourceData": {
"Id": "<message id>",
"@odata.etag": "<tag id>",
"@odata.id": "Users/<user-id>/Messages/<message-id>",
"@odata.type": "#Microsoft.OutlookServices.Message",
"OtherResourceData": "<some other resource data>"
}
}
}
Peristiwa Microsoft.Graph.MessageUpdated
{
"id": "00d8a100-2e92-4bfa-86e1-0056dacd0fce",
"type": "Microsoft.Graph.MessageUpdated",
"source": "/tenants/<tenant-id>/applications/<application-id>",
"subject": "Messages/<message-id>",
"time": "2024-05-22T22:24:31.3062901Z",
"datacontenttype": "application/json",
"specversion": "1.0",
"data": {
"@odata.type": "#Microsoft.OutlookServices.Notification",
"Id": null,
"SubscriptionExpirationDateTime": "2024-06-22T23:56:30.1307708Z",
"ChangeType": "updated",
"subscriptionId": "MTE1MTVlYTktMjVkZS00MjY3LWI1YzYtMjg0NzliZmRhYWQ2",
"resource": "https://outlook.office365.com/api/beta/Users('userId@tenantId')/Messages('<message id>')",
"clientState": "<client state>",
"resourceData": {
"Id": "<message id>",
"@odata.etag": "<tag id>",
"@odata.id": "https://outlook.office365.com/api/beta/Users('userId@tenantId')/Messages('<message id>')",
"@odata.type": "#Microsoft.OutlookServices.Message",
"OtherResourceData": "<some other resource data>"
}
}
}
Peristiwa Microsoft.Graph.MessageDeleted
{
"id": "00d8a100-2e92-4bfa-86e1-0056dacd0fce",
"type": "Microsoft.Graph.MessageDeleted",
"source": "/tenants/<tenant-id>/applications/<application-id>",
"subject": "Message/<message-id>",
"time": "2024-05-22T22:24:31.3062901Z",
"datacontenttype": "application/json",
"specversion": "1.0",
"data": {
"@odata.type": "#Microsoft.OutlookServices.Notification",
"Id": null,
"SubscriptionExpirationDateTime": "2024-06-22T23:56:30.1307708Z",
"ChangeType": "deleted",
"subscriptionId": "MTE1MTVlYTktMjVkZS00MjY3LWI1YzYtMjg0NzliZmRhYWQ2",
"resource": "https://outlook.office365.com/api/beta/Users('userId@tenantId')/Messages('<message id>')",
"clientState": "<client state>",
"resourceData": {
"Id": "<message id>",
"@odata.etag": "<tag id>",
"@odata.id": "https://outlook.office365.com/api/beta/Users('userId@tenantId')/Messages('<message id>')",
"@odata.type": "#Microsoft.OutlookServices.Message",
"OtherResourceData": "<some other resource data>"
}
}
}
Properti kejadian
Sebuah peristiwa memiliki data tingkat atas berikut ini:
Properti | Tipe | Deskripsi |
---|---|---|
source |
string | Sumber kejadian penyewa. Bidang ini tidak dapat ditulis. API Microsoft Graph menyediakan nilai ini. |
subject |
string | Jalur yang ditentukan penerbit ke subjek kejadian. |
type |
string | Salah satu jenis kejadian untuk sumber kejadian ini. |
time |
string | Waktu kejadian dibuat berdasarkan Waktu Universal Terkoordinasi (UTC) milik penyedia |
id |
string | Pengidentifikasi unik untuk peristiwa tersebut. |
data |
object | Payload kejadian yang menyediakan data mengenai perubahan status sumber daya. |
specversion |
string | Versi spesifikasi skema CloudEvents. |
Objek data memiliki properti berikut:
Properti | Tipe | Deskripsi |
---|---|---|
changeType |
string | Jenis perubahan status sumber daya. |
resource |
string | Pengidentifikasi sumber daya tempat kejadian dimunculkan. |
tenantId |
string | ID organisasi di mana pengguna atau grup disimpan. |
clientState |
string | Rahasia yang diberikan oleh pengguna pada saat pembuatan langganan Graph API. |
@odata.type |
string | Jenis perubahan Graph API. |
@odata.id |
string | Pengidentifikasi sumber daya Graph API tempat kejadian dimunculkan. |
id |
string | Pengidentifikasi sumber daya tempat kejadian dimunculkan. |
organizationId |
string | Pengidentifikasi penyewa Outlook. |
eventTime |
string | Waktu ketika status sumber daya terjadi. |
sequenceNumber |
string | Sebuah nomor urut. |
subscriptionExpirationDateTime |
string | Waktu dalam format Request for Change (RFC) 3339 di mana langganan Graph API kedaluwarsa. |
subscriptionId |
string | Pengidentifikasi langganan Graph API. |
tenantId |
string | Pengidentifikasi penyewa Outlook. |
otherResourceData |
string | Tempat penampung yang mewakili satu atau beberapa properti dinamis yang mungkin disertakan dalam peristiwa tersebut. |
Langkah berikutnya
- Untuk pengenalan Acara Mitra Azure Event Grid, lihat gambaran umum Acara Mitra
- Untuk informasi tentang cara berlangganan API Microsoft Graph untuk menerima kejadian Outlook, lihat berlangganan kejadian API Azure Graph.
- Untuk informasi tentang penanganan aktivitas Azure Event Grid, lihat penanganan aktivitas.
- Untuk informasi selengkapnya tentang cara membuat langganan Azure Event Grid, lihat membuat langganan kejadian dan skema langganan Event Grid.
- Untuk informasi tentang cara mengonfigurasi langganan kejadian guna memilih kejadian tertentu yang akan dikirimkan, lihat pemfilteran kejadian. Anda mungkin juga ingin merujuk ke peristiwa filter.