cancel
Showing results for 
Search instead for 
Did you mean: 

Outlook O365 migration from Onprem

HariMR
Level 4
Need your help here 
In one of our engagements migration activity is going on . The client has moved from Outlook 2013 to O365.
The authentication is now modern authentication. As part of this we need to get the authentication by using tokens. we already have the following details
App (client) ID:
Object ID:
Directory (tenant) ID:
Secret value:
Secret ID:
please help how we need to set Msal , Is any setting needs to be done in WebAPI services under system tab?

------------------------------
Hari MR
Developer
EY
Europe/London
------------------------------
22 REPLIES 22

Thanks Eric, They changed the permission and now it is working perfectly.
But for reading the mails . I am using the same object with the same authentication (using Client secret). But it is showing as 400 Bad request.
is that again related to the permission setings.
21174.png

The error that I am getting.
21175.png

------------------------------
Hari MR
Developer
EY
Europe/London
------------------------------

Also I can see , here message id is used. Is there any VBO's which we can use in O365 which reads mail from an outlook mail folder by giving  mail subject
like shown in this below screenshot

21181.png

------------------------------
Hari MR
Developer
EY
Europe/London
------------------------------

Hi @Hari MR,

Regarding retrieving/reading emails, it could be a permissions issue, but based on the screenshot I'd say it's because you have an invalid message ID. Message ID's in Outlook 365 w/ Graph are usually long cryptic strings like this:

BAMkADdhY2Y2MDE1LTA4OGMtNGVlYy1iZWVlLWE1ZWI3MGMzY2NmNQBGAAAAAAC4m1t2yd3rRLBp6h87n7GsBwCY63neJCDgQ6lEUTrNiFSQAAAAAAEMAACY63neJCDgQ6lEUTrNiFSQAAA14fR9AAA=​​


As far as getting emails based on a subject, you should look at the VBO documentation related to the List Mail in Folder action. You specifically want to pay attention to the Filter Query option if you trying to match emails using a sentence or phrase. To get only emails that have a subject line of exactly "This is a test message.", I could use a Filter Query like this:

21188.png

"contains(subject, 'This is a test message.')"


The Search Query option is a bit different in that it's looking for a specific term within the specified field. So, if I wanted to return a list of emails that contain the term "ERROR" in their subject I could use a Search Query like this:

21189.png

Chr(34) & "subject:ERROR" & Chr(34)


There's a decent explanation of the difference between the OData $search and $filter features on this Stack Overflow thread, specifically the accepted answer.

https://stackoverflow.com/questions/50939061/what-is-the-difference-between-the-filter-and-search-query-parameters-in-microso#:~:text=This%20is%20indicated%20in%20Microsoft's,could%20be%20returned%20b...

Cheers,


------------------------------
Eric Wilson
Director, Integrations and Enablement
Blue Prism Digital Exchange
------------------------------

Perfect , Thanks a lot for your help Eric 🙂
Read mail has worked by following the steps you provided.
For move mail the folder Id part . The folder is created inside Inbox ( which is a subfolder that I created in Inbox and I want to move the mail to the sub folder from inbox.)
For getting the folder id I  spent some time and finally I used the action  "List folders" then I got the folder id of inbox. I used the inbox folder id again in "List folder action" to get the sub folder Id's  in Inbox 
Finally I used this sub folder id  that I want  in move mail action and that worked like a charm
Thankyou Eric for your guidance.

------------------------------
Hari MR
Developer
EY
Europe/London
------------------------------

Hi Eric,
Regarding List Mail in folder action, the output is a collection. In the output the body of the email is limited to certain characters, means the whole body of the message is not showing. Bot is fetching details from the body of the email and is then feeding those values to another application. Here the problem is because of the limited character the entire body is not getting populated. and the bot fails to enter the entire info in the application. Is there any way to solve this or to increase the size of that field in the collection?
21208.png

21209.png
Thanks 
Hari

------------------------------
Hari MR
Developer
EY
Europe/London
------------------------------

@Hari MR,

You're looking at the bodyPreview field. Microsoft only includes the first 255 characters of the body within that field. You need to be looking at the body field.

21219.png
The body field contains a child Collection for each message​ with an indicator of the contentType and the actual content. At the moment, I believe Graph always returns the content as HTML.

Cheers,

------------------------------
Eric Wilson
Director, Integrations and Enablement
Blue Prism Digital Exchange
------------------------------

Thankyou Eric for explaining.
Also just want to know if there are any blue prism object for converting Html to text.
The output is html format, needs to remove all html tags from it.

------------------------------
Hari MR
Developer
EY
Europe/London
------------------------------

@Hari MR,

There's no standard VBO for this, but if you search the forum you'll find various examples of how to achieve this using Regular Expression (RegEx).

Cheers,


------------------------------
Eric Wilson
Director, Integrations and Enablement
Blue Prism Digital Exchange
------------------------------

Sure Eric will do this with RegEX or with replace function to remove html tags. 
Thankyou very much

------------------------------
Hari MR
Developer
EY
Europe/London
------------------------------

Hi Eric,

I have a scenario  where we are doing IE to Edge migration 

I am unable to find the html mode for the Edge browser .
I have chosen the below option.
Browser based Application (Chrome, Firefox or Edge chromium).
The application is not even launching when I chose this option.  ( Please see the attachment)
How to get Browser mode (Html syping) because Java script fragments are used.
Also I would like to know why the application is not launching through BP if I use this mode Browser based Application (Chrome, Firefox or Edge chromium).
Please note that the application is launching correctly when I use Browser based Application (Internet Explorer) and also in edge when I type the url manually.



------------------------------
Hari MR
Developer
EY
Europe/London
------------------------------