Replies: 3 comments 4 replies
-
you can create a draft message and later on send it. You can also move a message (from deleted items to inbox for example). But I don't believe you can just create a message in the inbox like that (without sending it). However the best place to get answers about API capabilities is through the dedicated Microsoft Q&A forum which is monitored by the product team. (this repo issues/discussions is really about the SDK itself) |
Beta Was this translation helpful? Give feedback.
-
Asked in Issue #155 , but I will say that I have not found the ability to modify a message. An message can be moved to a different directory, but that appears to be it. I have also added the question to the Q&A forum, but I have not heard anything since. |
Beta Was this translation helpful? Give feedback.
-
If one cannot change update an old message via the graph API, the early suggestion of creating a draft should work.
When I pull in an old message and try to setID to the new message Id and post it, I am receiving an error from the API.
Code here :
```go
parseNode, err := absser.DefaultParseNodeFactoryInstance.GetRootParseNode("application/json",bytes)
if err != nil{
fmt.Errorf("Unable to create parseNode:%v\n", err)
}
aMessage, err := parseNode.GetObjectValue(models.CreateMessageFromDiscriminatorValue)
if err != nil{
fmt.Printf("Unable to create message: %v\n", err)
}
if aMessage == nil{
os.Exit(1)
}
message := aMessage.(models.Messageable)
message.SetId( &id )
mailFolderId := "AQMkAGQ1NzViZTdhLTEwMTMtNGJjNi05YWI2LTg4ADVkZWQwNmNlMTgALgAAAw_9XBStqZdPuOVIalVTz7sBAHzBhzS2FNNNiXdGkRghSr4AAAIBDAAAAA=="
attrib, err := client.UsersById(user).MailFoldersById(mailFolderId).Messages().Post(message) // switch Me for userby id
```
|
Beta Was this translation helpful? Give feedback.
-
I did not see this feature in graph explorer, but I was curious if the SDK has the capability.
If I have a message object in memory and it has been deleted by an illegal user, is it possible to put the message back into the mailbox?
If it is possible what is the generic command that would make that possible?
Beta Was this translation helpful? Give feedback.
All reactions