Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Booking type causes sync to fail #420

Open
marcoancona opened this issue Jan 3, 2023 · 0 comments
Open

Booking type causes sync to fail #420

marcoancona opened this issue Jan 3, 2023 · 0 comments

Comments

@marcoancona
Copy link
Contributor

marcoancona commented Jan 3, 2023

It appears that events created from Microsoft Bookings (https://learn.microsoft.com/en-us/microsoft-365/bookings/bookings-overview?view=o365-worldwide) have a different schema.

Here, for example, a SyncFolderItemsResponse containing an update of Booking type.

{
    "__prefix": "s",
    "__xmlns": {
        "s": "http://schemas.xmlsoap.org/soap/envelope/",
        "h": "http://schemas.microsoft.com/exchange/services/2006/types",
        "xsd": "http://www.w3.org/2001/XMLSchema",
        "xsi": "http://www.w3.org/2001/XMLSchema-instance",
        "m": "http://schemas.microsoft.com/exchange/services/2006/messages",
        "t": "http://schemas.microsoft.com/exchange/services/2006/types"
    },
    "Header": {
        "__prefix": "s",
        "ServerVersionInfo": {
            "__prefix": "h",
            "__type": "ServerVersionInfo",
            "MajorVersion": "15",
            "MinorVersion": "20",
            "MajorBuildNumber": "5944",
            "MinorBuildNumber": "19",
            "Version": "V2018_01_08"
        }
    },
    "Body": {
        "__prefix": "s",
        "SyncFolderItemsResponse": {
            "__prefix": "m",
            "__type": "SyncFolderItemsResponse",
            "ResponseMessages": {
                "__prefix": "m",
                "__type": "ResponseMessages",
                "SyncFolderItemsResponseMessage": {
                    "__prefix": "m",
                    "__type": "SyncFolderItemsResponseMessage",
                    "ResponseClass": "Success",
                    "ResponseCode": "NoError",
                    "SyncState": "XXX...XXX",
                    "IncludesLastItemInRange": "true",
                    "Changes": {
                        "__prefix": "m",
                        "__type": "Changes",
                        "Update": {
                            "__prefix": "t",
                            "__type": "Update",
                            "Booking": {
                                "__prefix": "t",
                                "__type": "Booking",
                                "ItemId": {
                                    "__prefix": "t",
                                    "__type": "ItemId",
                                    "Id": "AAMkADZkYWYzNzY2LWFjN2EtNDFjOS1hYzVhLTZlMGE5ODJlYjU3OABGAAAAAAD9RG+Xd/5qRYlD3TDYDmiqBwAMRD6BvLPtR5EDDbxarne7AAAAAAENAAAMRD6BvLPtR5EDDbxarne7AAIXUBnTAAA=",
                                    "ChangeKey": "TgAAABYAAAAMRD6BvLPtR5EDDbxarne7AAIVyTtN"
                                },
                                "PreBuffer": "0",
                                "PostBuffer": "0",
                                "PricingType": "Undefined",
                                "Price": "0",
                                "BookingFee": "0",
                                "BookingTax": "0",
                                "SelfServiceId": "00000000-0000-0000-0000-000000000000"
                            }
                        }
                    }
                }
            }
        }
    }
}

This causes the parsing to fail. Depending on the API called, we see either The type of the object in the store (Booking) does not match that of the local object (CalendarItem). (when using LoadPropertiesForItems) or Cannot read property of null (reading 'LoadFromXmlJsObject') (when using SyncFolderItems).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant