# Email OTP

## Create

> Create a new Email OTP MFA.

```json
{"openapi":"3.0.1","info":{"title":"Parallels RAS - REST API v1.0","version":"1.0"},"paths":{"/api/MFA/EmailOTP":{"post":{"tags":["2-Site settings/Multi-factor Authentication//0-Basic Operations"],"summary":"Create","description":"Create a new Email OTP MFA.","operationId":"03bfa8e6-f9cf-4afc-bd68-1159f2e6ce6d","requestBody":{"description":"MFA settings","content":{"application/json; api-version=1.0":{"schema":{"$ref":"#/components/schemas/NewMFAEmailOTP"}}}},"responses":{"201":{"description":"Created","content":{"application/json; api-version=1.0":{"schema":{"$ref":"#/components/schemas/MFAEmailOTP"}}}},"401":{"description":"Unauthorized","content":{"application/json; api-version=1.0":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"409":{"description":"Conflict","content":{"application/json; api-version=1.0":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}}}}}},"components":{"schemas":{"NewMFAEmailOTP":{"required":["displayName","name"],"type":"object","properties":{"name":{"maxLength":255,"minLength":1,"type":"string","description":"<para type=\"description\">The name of the target Multi Factor Authentication.</para>\r\n<para type=\"description\">This must be the actual Multi Factor Authentication name used in the RAS farm.</para>","nullable":true},"siteId":{"type":"integer","description":"<para type=\"description\">Site ID in which to modify the specified Multi Factor Authentication.</para>\r\n<para type=\"description\">If the parameter is omitted, the site ID of the Licensing Server will be used.</para>","format":"int32"},"description":{"type":"string","description":"<para type=\"description\">A user-defined Multi Factor Authentication description.</para>","nullable":true},"enabled":{"type":"boolean","description":"<para type=\"description\">Enable or disable the Multi Factor Authentication upon creation.</para>\r\n<para type=\"description\">If the parameter is omitted, the Multi Factor Authentication is initialised as Disabled.</para>"},"displayName":{"maxLength":200,"minLength":0,"type":"string","description":"<para type=\"description\">RADIUS type name.</para>","nullable":true},"userEnrollment":{"$ref":"#/components/schemas/UserEnrollment"},"showInformationForUnenrolledUsers":{"$ref":"#/components/schemas/ShowInformationForUnenrolledUsers"},"untilDateTime":{"type":"string","description":"<para type=\"description\">Allow User Enrollment until date/time</para>","format":"date-time","nullable":true},"otpLifespanSec":{"type":"integer","description":"<para type=\"description\">The lifespan of the OTP (seconds)</para>","format":"int32","nullable":true},"externalEmailStorage":{"$ref":"#/components/schemas/ExternalEmailStorage"},"emailContent":{"maxLength":2048,"minLength":1,"type":"string","description":"<para type=\"description\">The content of the email. Possible variables: %OTP%, %DURATION%</para>","nullable":true},"emailSubject":{"maxLength":300,"minLength":1,"type":"string","description":"<para type=\"description\">The subject of the email. Possible variables: %OTP%</para>","nullable":true},"userMessagePrompt":{"maxLength":300,"minLength":0,"type":"string","description":"<para type=\"description\">User message prompt</para>","nullable":true},"adCustomAttribute":{"maxLength":200,"minLength":1,"type":"string","description":"<para type=\"description\">AD Custom Attribute</para>","nullable":true},"allowEnrollExternalEmail":{"type":"boolean","description":"<para type=\"description\">Allow enrollment of external email</para>","nullable":true},"otpLength":{"type":"integer","description":"<para type=\"description\">The length of the OTP generated</para>","format":"int32","nullable":true}},"additionalProperties":false,"description":"<para type=\"synopsis\">Create MFA of type Email OTP</para>\r\n<para type=\"description\"></para>"},"UserEnrollment":{"enum":[["0 = Allow","1 = AllowUntil","2 = DoNotAllow"]],"type":"string","description":"<para type=\"synopsis\">User Enrollment</para>\r\n<para type=\"description\"></para>","format":"int32"},"ShowInformationForUnenrolledUsers":{"enum":[["0 = Always","1 = IfEnrollmentIsAllowed","2 = Never"]],"type":"string","description":"<para type=\"synopsis\">Show information for unenrolled users</para>\r\n<para type=\"description\"></para>","format":"int32"},"ExternalEmailStorage":{"enum":[["0 = RASDatabase","1 = ADMail","2 = ADCustom"]],"type":"string","description":"<para type=\"synopsis\">External email storage</para>\r\n<para type=\"description\"></para>","format":"int32"},"MFAEmailOTP":{"type":"object","properties":{"id":{"type":"integer","description":"<para type=\"description\">ID of the object.</para>","format":"int32"},"adminCreate":{"type":"string","description":"<para type=\"description\">User who created the object.</para>","nullable":true},"adminLastMod":{"type":"string","description":"<para type=\"description\">User who last modified the object.</para>","nullable":true},"timeCreate":{"type":"string","description":"<para type=\"description\">Time when the object was created.</para>","format":"date-time"},"timeLastMod":{"type":"string","description":"<para type=\"description\">Time when the object was last modified.</para>","format":"date-time"},"name":{"type":"string","description":"<para type=\"description\">Name</para>","nullable":true},"siteId":{"type":"integer","description":"<para type=\"description\">Site ID</para>","format":"int32"},"description":{"type":"string","description":"<para type=\"description\">Description</para>","nullable":true},"enabled":{"type":"boolean","description":"<para type=\"description\">Whether MFA provider is enabled or not.</para>"},"type":{"$ref":"#/components/schemas/MFAType"},"inheritDefaultCriteriaSettings":{"type":"boolean","description":"<para type=\"description\">If true default criteria restriction settings will be inherited.</para>"},"criteria":{"$ref":"#/components/schemas/MFACriteria"},"displayName":{"type":"string","description":"<para type=\"description\">Display name</para>","nullable":true},"userEnrollment":{"$ref":"#/components/schemas/UserEnrollment"},"showInformationForUnenrolledUsers":{"$ref":"#/components/schemas/ShowInformationForUnenrolledUsers"},"untilDateTime":{"type":"string","description":"<para type=\"description\">Allow User Enrollment until date/time</para>","format":"date-time"},"otpLifespanSec":{"type":"integer","description":"<para type=\"description\">The lifespan of the OTP (seconds)</para>","format":"int32"},"externalEmailStorage":{"$ref":"#/components/schemas/ExternalEmailStorage"},"emailContent":{"type":"string","description":"<para type=\"description\">The content of the email. Possible variables: %OTP%, %DURATION%</para>","nullable":true},"emailSubject":{"type":"string","description":"<para type=\"description\">The subject of the email. Possible variables: %OTP%</para>","nullable":true},"userMessagePrompt":{"type":"string","description":"<para type=\"description\">User message prompt</para>","nullable":true},"adCustomAttribute":{"type":"string","description":"<para type=\"description\">AD Custom Attribute</para>","nullable":true},"allowEnrollExternalEmail":{"type":"boolean","description":"<para type=\"description\">Allow enrollment of external email</para>"},"otpLength":{"type":"integer","description":"<para type=\"description\">The length of the OTP generated</para>","format":"int32"}},"additionalProperties":false,"description":"<para type=\"synopsis\">MFA Email OTP Settings</para>\r\n<para type=\"description\"></para>"},"MFAType":{"enum":[["1 = Deepnet","2 = SafeNet","3 = Radius","4 = AzureRadius","5 = DuoRadius","6 = FortiRadius","7 = TekRadius","8 = GAuthTOTP","9 = TOTP","10 = MicrosoftTOTP","11 = EmailOTP"]],"type":"string","description":"<para type=\"synopsis\">Provider Type</para>\r\n<para type=\"description\"></para>","format":"int32"},"MFACriteria":{"type":"object","properties":{"securityPrincipals":{"$ref":"#/components/schemas/SecurityPrincipalsCriteria"},"gateways":{"$ref":"#/components/schemas/GatewaysCriteria"},"oSs":{"$ref":"#/components/schemas/OSsCriteria"},"iPs":{"$ref":"#/components/schemas/IPsCriteria"},"hardwareIDs":{"$ref":"#/components/schemas/HardwareIDsCriteria"},"access":{"$ref":"#/components/schemas/AccessType"},"devices":{"$ref":"#/components/schemas/DevicesCriteria"}},"additionalProperties":false,"description":"<para type=\"synopsis\">MFA Criteria</para>\r\n<para type=\"description\"></para>"},"SecurityPrincipalsCriteria":{"type":"object","properties":{"enabled":{"type":"boolean","description":"<para type=\"description\">Whether the Security Principals Criteria is enabled or not</para>"},"matchingMode":{"$ref":"#/components/schemas/MatchingModeType"},"members":{"type":"array","items":{"$ref":"#/components/schemas/SecurityPrincipalCriteriaEntry"},"description":"<para type=\"description\">User criteria list</para>","nullable":true}},"additionalProperties":false,"description":"<para type=\"synopsis\">Security Principals Criteria</para>\r\n<para type=\"description\"></para>"},"MatchingModeType":{"enum":[["0 = IsNotOneOfTheFollowing","1 = IsOneOfTheFollowing"]],"type":"string","description":"<para type=\"synopsis\">Matching mode type options</para>\r\n<para type=\"description\"></para>","format":"int32"},"SecurityPrincipalCriteriaEntry":{"type":"object","properties":{"account":{"type":"string","description":"<para type=\"description\">The name of the user/group account the filter is added to.</para>","nullable":true},"type":{"$ref":"#/components/schemas/UserType"},"sid":{"type":"string","description":"<para type=\"description\">The SID of the user/group account the filter is added to.</para>","nullable":true}},"additionalProperties":false,"description":"<para type=\"synopsis\">Security Principal Criteria Entry</para>\r\n<para type=\"description\"></para>"},"UserType":{"enum":[["1 = User","2 = Group","3 = ForeignSecurityPrincipal","4 = Computer"]],"type":"string","description":"<para type=\"synopsis\">User Type</para>\r\n<para type=\"description\"></para>","format":"int32"},"GatewaysCriteria":{"type":"object","properties":{"enabled":{"type":"boolean","description":"<para type=\"description\">Whether the Gateways Criteria is enabled or not</para>"},"matchingMode":{"$ref":"#/components/schemas/MatchingModeType"},"members":{"type":"array","items":{"$ref":"#/components/schemas/GatewayCriteriaEntry"},"description":"<para type=\"description\">Gateway criteria list</para>","nullable":true}},"additionalProperties":false,"description":"<para type=\"synopsis\">Gateways Criteria</para>\r\n<para type=\"description\"></para>"},"GatewayCriteriaEntry":{"type":"object","properties":{"gatewayIP":{"type":"string","description":"<para type=\"description\">The gateway IP.</para>","nullable":true}},"additionalProperties":false,"description":"<para type=\"synopsis\">Gateway criteria entry</para>\r\n<para type=\"description\"></para>"},"OSsCriteria":{"type":"object","properties":{"enabled":{"type":"boolean","description":"<para type=\"description\">Whether the OSs Criteria is enabled or not</para>"},"matchingMode":{"$ref":"#/components/schemas/MatchingModeType"},"allowedOSes":{"$ref":"#/components/schemas/AllowedOperatingSystems"}},"additionalProperties":false,"description":"<para type=\"synopsis\">OS Criteria Settings</para>\r\n<para type=\"description\"></para>"},"AllowedOperatingSystems":{"type":"object","properties":{"chrome":{"type":"boolean","description":"<para type=\"description\">Whether Chrome is allowed or not.</para>"},"android":{"type":"boolean","description":"<para type=\"description\">Whether Android is allowed or not.</para>"},"webClient":{"type":"boolean","description":"<para type=\"description\">Whether Web Client is allowed or not.</para>"},"iOS":{"type":"boolean","description":"<para type=\"description\">Whether iOS is allowed or not.</para>"},"linux":{"type":"boolean","description":"<para type=\"description\">Whether Linux is allowed or not.</para>"},"mac":{"type":"boolean","description":"<para type=\"description\">Whether MAC OS is allowed or not.</para>"},"wyse":{"type":"boolean","description":"<para type=\"description\">Whether Wyse is allowed or not.</para>"},"windows":{"type":"boolean","description":"<para type=\"description\">Whether Windows is allowed or not.</para>"}},"additionalProperties":false,"description":"<para type=\"synopsis\">Allowed Operating Systems</para>\r\n<para type=\"description\"></para>"},"IPsCriteria":{"type":"object","properties":{"enabled":{"type":"boolean","description":"<para type=\"description\">Whether the IPs Criteria is enabled or not</para>"},"matchingMode":{"$ref":"#/components/schemas/MatchingModeType"},"allowedIPs":{"$ref":"#/components/schemas/AllowedIPsCriteria"}},"additionalProperties":false,"description":"<para type=\"synopsis\">IPs Criteria</para>\r\n<para type=\"description\"></para>"},"AllowedIPsCriteria":{"type":"object","properties":{"iPv4s":{"type":"array","items":{"$ref":"#/components/schemas/IPv4CriteriaEntry"},"description":"<para type=\"description\">IPv4 criteria list</para>","nullable":true},"iPv6s":{"type":"array","items":{"$ref":"#/components/schemas/IPv6CriteriaEntry"},"description":"<para type=\"description\">IPv6 criteria list</para>","nullable":true}},"additionalProperties":false,"description":"<para type=\"synopsis\">Allowed IPs Criteria</para>\r\n<para type=\"description\"></para>"},"IPv4CriteriaEntry":{"type":"object","properties":{"from":{"type":"string","nullable":true},"to":{"type":"string","nullable":true}},"additionalProperties":false,"description":"<para type=\"synopsis\">IPv4 Criteria Entry</para>\r\n<para type=\"description\"></para>"},"IPv6CriteriaEntry":{"type":"object","properties":{"from":{"type":"string","nullable":true},"to":{"type":"string","nullable":true}},"additionalProperties":false,"description":"<para type=\"synopsis\">IPv6 Criteria Entry</para>\r\n<para type=\"description\"></para>"},"HardwareIDsCriteria":{"type":"object","properties":{"enabled":{"type":"boolean","description":"<para type=\"description\">Whether the Hardware IDs Criteria is enabled or not</para>"},"matchingMode":{"$ref":"#/components/schemas/MatchingModeType"},"members":{"type":"array","items":{"$ref":"#/components/schemas/HardwareIDCriteriaEntry"},"description":"<para type=\"description\">Hardware IDs criteria list</para>","nullable":true}},"additionalProperties":false,"description":"<para type=\"synopsis\">Hardware IDs Criteria</para>\r\n<para type=\"description\"></para>"},"HardwareIDCriteriaEntry":{"type":"object","properties":{"hardwareID":{"type":"string","description":"<para type=\"description\">The hardware ID.</para>","nullable":true}},"additionalProperties":false,"description":"<para type=\"synopsis\">Hardware ID criteria entry</para>\r\n<para type=\"description\"></para>"},"AccessType":{"enum":[["0 = DenyCriteriaWhen","1 = AllowCriteriaWhen"]],"type":"string","description":"<para type=\"synopsis\">Access type options</para>\r\n<para type=\"description\"></para>","format":"int32"},"DevicesCriteria":{"type":"object","properties":{"enabled":{"type":"boolean","description":"<para type=\"description\">Whether the Devices Criteria is enabled or not</para>"},"matchingMode":{"$ref":"#/components/schemas/MatchingModeType"},"members":{"type":"array","items":{"$ref":"#/components/schemas/ClientDeviceCriteriaEntry"},"description":"<para type=\"description\">Client criteria list</para>","nullable":true}},"additionalProperties":false,"description":"<para type=\"synopsis\">Devices Criteria</para>\r\n<para type=\"description\"></para>"},"ClientDeviceCriteriaEntry":{"type":"object","properties":{"client":{"type":"string","description":"<para type=\"description\">The name of the client device.</para>","nullable":true}},"additionalProperties":false,"description":"<para type=\"synopsis\">Client device criteria entry</para>\r\n<para type=\"description\"></para>"},"ProblemDetails":{"type":"object","properties":{"type":{"type":"string","nullable":true},"title":{"type":"string","nullable":true},"status":{"type":"integer","format":"int32","nullable":true},"detail":{"type":"string","nullable":true},"instance":{"type":"string","nullable":true}},"additionalProperties":{}}}}}
```

## Update

> Update the Email OTP MFA Site Settings.

```json
{"openapi":"3.0.1","info":{"title":"Parallels RAS - REST API v1.0","version":"1.0"},"paths":{"/api/MFA/EmailOTP/{id}":{"put":{"tags":["2-Site settings/Multi-factor Authentication//0-Basic Operations"],"summary":"Update","description":"Update the Email OTP MFA Site Settings.","operationId":"da0c5b47-e0f7-4a5f-a5c4-958873a0d51b","parameters":[{"name":"id","in":"path","description":"The ID for which to modify the MFA settings.","required":true,"schema":{"type":"integer","format":"int32"}}],"requestBody":{"description":"MFA settings.","content":{"application/json; api-version=1.0":{"schema":{"$ref":"#/components/schemas/SetMFAEmailOTP"}}}},"responses":{"204":{"description":"No Content"},"401":{"description":"Unauthorized","content":{"application/json; api-version=1.0":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"404":{"description":"Not Found","content":{"application/json; api-version=1.0":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}}}}}},"components":{"schemas":{"SetMFAEmailOTP":{"type":"object","properties":{"name":{"maxLength":255,"minLength":1,"type":"string","description":"<para type=\"description\">The new name of the target multi-factor authentication .</para>","nullable":true},"description":{"type":"string","description":"<para type=\"description\">A user-defined multi-factor authentication description.</para>","nullable":true},"enabled":{"type":"boolean","description":"<para type=\"description\">Enable or disable the specified multi-factor authentication in a site.</para>","nullable":true},"inheritDefaultCriteriaSettings":{"type":"boolean","description":"<para type=\"description\">If true default criteria settings will be inherited.</para>","nullable":true},"displayName":{"maxLength":200,"minLength":0,"type":"string","description":"<para type=\"description\">RADIUS type name.</para>","nullable":true},"userEnrollment":{"$ref":"#/components/schemas/UserEnrollment"},"showInformationForUnenrolledUsers":{"$ref":"#/components/schemas/ShowInformationForUnenrolledUsers"},"untilDateTime":{"type":"string","description":"<para type=\"description\">Allow User Enrollment until date/time</para>","format":"date-time","nullable":true},"otpLifespanSec":{"type":"integer","description":"<para type=\"description\">The lifespan of the OTP (seconds)</para>","format":"int32","nullable":true},"externalEmailStorage":{"$ref":"#/components/schemas/ExternalEmailStorage"},"defaultEmailContent":{"type":"boolean","description":"<para type=\"description\">If this parameter is included, the email body content will be replaced with the default body content.</para>","default":false},"emailContent":{"maxLength":2048,"minLength":1,"type":"string","description":"<para type=\"description\">The content of the email. Possible variables: %OTP%, %DURATION%</para>","nullable":true},"defaultEmailSubject":{"type":"boolean","description":"<para type=\"description\">If this parameter is included, the email subject will be replaced with the default subject.</para>","default":false},"emailSubject":{"maxLength":300,"minLength":1,"type":"string","description":"<para type=\"description\">The subject of the email. Possible variables: %OTP%</para>","nullable":true},"defaultUserMessagePrompt":{"type":"boolean","description":"<para type=\"description\">If this parameter is included, the message prompt will be replaced with the default message prompt.</para>","default":false},"userMessagePrompt":{"maxLength":300,"minLength":0,"type":"string","description":"<para type=\"description\">User message prompt</para>","nullable":true},"adCustomAttribute":{"maxLength":200,"minLength":1,"type":"string","description":"<para type=\"description\">AD Custom Attribute</para>","nullable":true},"allowEnrollExternalEmail":{"type":"boolean","description":"<para type=\"description\">Allow enrollment of external email</para>","nullable":true},"otpLength":{"type":"integer","description":"<para type=\"description\">The length of the OTP generated</para>","format":"int32","nullable":true}},"additionalProperties":false,"description":"<para type=\"synopsis\">Update MFA of type TOTP</para>\r\n<para type=\"description\"></para>"},"UserEnrollment":{"enum":[["0 = Allow","1 = AllowUntil","2 = DoNotAllow"]],"type":"string","description":"<para type=\"synopsis\">User Enrollment</para>\r\n<para type=\"description\"></para>","format":"int32"},"ShowInformationForUnenrolledUsers":{"enum":[["0 = Always","1 = IfEnrollmentIsAllowed","2 = Never"]],"type":"string","description":"<para type=\"synopsis\">Show information for unenrolled users</para>\r\n<para type=\"description\"></para>","format":"int32"},"ExternalEmailStorage":{"enum":[["0 = RASDatabase","1 = ADMail","2 = ADCustom"]],"type":"string","description":"<para type=\"synopsis\">External email storage</para>\r\n<para type=\"description\"></para>","format":"int32"},"ProblemDetails":{"type":"object","properties":{"type":{"type":"string","nullable":true},"title":{"type":"string","nullable":true},"status":{"type":"integer","format":"int32","nullable":true},"detail":{"type":"string","nullable":true},"instance":{"type":"string","nullable":true}},"additionalProperties":{}}}}}
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.parallels.com/landing/ras-rest-api-guide/api-reference/site-settings/mfa/email-otp.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
