question

DavidDowning-2679 avatar image
0 Votes"
DavidDowning-2679 asked ·

Azure Lab Services REST API Send Invitation Email

Hello,

I'm trying to use a REST API to send an invitation to the users. From "Users" there is an "Invite All" link... I'm trying to automate this.

Thank you, David

azure-lab-services-automation
10 |1000 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

1 Answer

SamaraSoucyMSFT avatar image
1 Vote"
SamaraSoucyMSFT answered ·

As with the other questions (1) (2) this can be accomplished using the 2019-01-01-preview version of the API that is not in the documentation. As with the others, as a preview feature, the endpoint could change without notice.

I've discussed this with the product team, and they are working on an API update that will be a later API version than 2019-01-01. Once those updates are ready, the documentation will be updated with that newer version.

URL:

 POST https://management.azure.com/subscriptions/{TenantID}/resourcegroups/{ResourceGroup}/providers/microsoft.labservicesl/labaccounts/{LabAccountName}/labs/{LabName}/sendEmail?api-version=2019-01-01-preview

Body for this one is fairly simple:

 {
     "emailAddresses": ["{email 1}", "{email 2}"],
     "extraMessage": "{custom message}"
 }

· 2 · Share
10 |1000 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

Hello,

I am getting a successful "200" OK response, however I'm never seeing an email in my inbox.

I'm using:

https://management.azure.com/subscriptions/{subscriptionID}/resourcegroups/{resourceGroupName}/providers/microsoft.labservices/labaccounts/{labAccountName}/labs/{labName}/sendEmail?api-version=2019-01-01-preview

with body

{ "emailAddresses": [ "<myemail>@<company>.com" ], "extraMessage": "test mmmmmmmmm" }

I checked &#34;Deleted&#34; and &#34;Junk&#34; folders.

David

0 Votes 0 · ·