I am trying to create list items with Microsoft Graph's new SharePoint endpoint. My URL is as follows: https://graph.microsoft.com/beta/sites/{site-id}/lists/{list-id}/items
Calling this URL with POST, and a body like this:
{
"fields": {
"Title": "test",
}
}
.. works! But if I include a lookup field, the lookup field is always empty. I have tried with
"{columnName}": "id",
"{columnName}": "id;#value",
"{columnName}": {
"@odata.type": "#Microsoft.Azure.Connectors.SharePoint.SPListExpandedReference", //and others like this
"Id": "id",
"Value": "value",
}
"{columnName}": "value",
"{columnName}Id": "id",
None of these seems to work. Some give an error like "The request is malformed or incorrect.", others go through, but doesn't include the lookup field.
The documentation for this is scarce (if any), and I have found very little information on google (apart from someone asking the same question with no answers). Anyone that got this to work yet? Is it even possible?