# OAuth 2.0(Gmail) Send Email is not supported in Web-Direct on FileMaker Cloud

**URL:** <https://the.fmsoup.org/t/oauth-2-0-gmail-send-email-is-not-supported-in-web-direct-on-filemaker-cloud/4076>\
**Category:** Heads-Up!\
**Created:** [April 5, 2024, 9:37pm UTC](https://the.fmsoup.org/t/oauth-2-0-gmail-send-email-is-not-supported-in-web-direct-on-filemaker-cloud/4076 "2024-04-05T21:37:02Z")\
**Posts on this page:** 9\
**Page:** 1

<div class="post-metadata">

**Author:** ![samfmp](https://avatars.discourse-cdn.com/v4/letter/s/a9a28c/32.png) [@samfmp](https://the.fmsoup.org/u/samfmp)\
**Post date:** [April 5, 2024, 9:37pm UTC](https://the.fmsoup.org/t/oauth-2-0-gmail-send-email-is-not-supported-in-web-direct-on-filemaker-cloud/4076/1 "2024-04-05T21:37:02Z")

</div>

Hi, I have a client who is using web-direct in their normal operation. They ask me to add a send email feature to their system. I tried to add that to the system. Since my client would like to send an email on behalf of their account so I explored OAuth 2.0(Google) which works on Pro, but it results in an error 1542 if Web Direct is used.

Not sure if anyone has faced/posted this issue before. Bear in mind when developing your solution.

---

<div class="post-metadata">

**Author:** ![bdbd](https://yyz2.discourse-cdn.com/flex030/user_avatar/the.fmsoup.org/bdbd/32/620_2.png) [@bdbd](https://the.fmsoup.org/u/bdbd)\
**Post date:** [April 6, 2024, 12:32am UTC](https://the.fmsoup.org/t/oauth-2-0-gmail-send-email-is-not-supported-in-web-direct-on-filemaker-cloud/4076/2 "2024-04-06T00:32:42Z")

</div>

Nice to know. Try sending the email via the server instead (via PSOS). It avoids WebDirect limitations.

---

<div class="post-metadata">

**Author:** ![Malcolm](https://yyz2.discourse-cdn.com/flex030/user_avatar/the.fmsoup.org/malcolm/32/196_2.png) [@Malcolm](https://the.fmsoup.org/u/Malcolm)\
**Post date:** [April 6, 2024, 2:57am UTC](https://the.fmsoup.org/t/oauth-2-0-gmail-send-email-is-not-supported-in-web-direct-on-filemaker-cloud/4076/3 "2024-04-06T02:57:41Z")

</div>

I can't see 1542 in the list of error codes. Is that number coming from FileMaker?

Malcolm

---

<div class="post-metadata">

**Author:** ![daleallyn](https://yyz2.discourse-cdn.com/flex030/user_avatar/the.fmsoup.org/daleallyn/32/819_2.png) [@daleallyn](https://the.fmsoup.org/u/daleallyn)\
**Post date:** [April 6, 2024, 9:16am UTC](https://the.fmsoup.org/t/oauth-2-0-gmail-send-email-is-not-supported-in-web-direct-on-filemaker-cloud/4076/4 "2024-04-06T09:16:16Z")

</div>

A few [comments on it here](https://community.claris.com/en/s/question/0D53w000068j2MSCAY/error-1542), @Malcolm

[This web search](https://www.google.com/search?client=firefox-b-e&q=filemaker+error+code+1542) produced several posts on the topic.

I did the search because, like you, I didn't find it documented in my "updated" list of FM error codes.

---

<div class="post-metadata">

**Author:** ![Malcolm](https://yyz2.discourse-cdn.com/flex030/user_avatar/the.fmsoup.org/malcolm/32/196_2.png) [@Malcolm](https://the.fmsoup.org/u/Malcolm)\
**Post date:** [April 6, 2024, 7:12pm UTC](https://the.fmsoup.org/t/oauth-2-0-gmail-send-email-is-not-supported-in-web-direct-on-filemaker-cloud/4076/5 "2024-04-06T19:12:02Z")

</div>

> [@daleallyn](#):
>
> I did the search because, like you, I didn't find it documented in my "updated" list of FM error codes.

[Error codes for Custom Web Publishing](https://support.claris.com/s/article/Error-codes-for-Custom-Web-Publishing-1503692934814?language=en_US) contain the 1542 number. They hid that well.

---

<div class="post-metadata">

**Author:** ![samfmp](https://avatars.discourse-cdn.com/v4/letter/s/a9a28c/32.png) [@samfmp](https://the.fmsoup.org/u/samfmp)\
**Post date:** [April 6, 2024, 10:00pm UTC](https://the.fmsoup.org/t/oauth-2-0-gmail-send-email-is-not-supported-in-web-direct-on-filemaker-cloud/4076/6 "2024-04-06T22:00:36Z")

</div>

I have tried to use PSOS. Same result if I remember correctly. I may go to gmail api as an alternative.

---

<div class="post-metadata">

**Author:** ![daleallyn](https://yyz2.discourse-cdn.com/flex030/user_avatar/the.fmsoup.org/daleallyn/32/819_2.png) [@daleallyn](https://the.fmsoup.org/u/daleallyn)\
**Post date:** [April 7, 2024, 12:15am UTC](https://the.fmsoup.org/t/oauth-2-0-gmail-send-email-is-not-supported-in-web-direct-on-filemaker-cloud/4076/7 "2024-04-07T00:15:11Z")

</div>

Thanks. My CF lacks 1541, 1542, and 1543. Adding them. 👍🏼 🙏🏼

---

<div class="post-metadata">

**Author:** ![Malcolm](https://yyz2.discourse-cdn.com/flex030/user_avatar/the.fmsoup.org/malcolm/32/196_2.png) [@Malcolm](https://the.fmsoup.org/u/Malcolm)\
**Post date:** [April 7, 2024, 7:58am UTC](https://the.fmsoup.org/t/oauth-2-0-gmail-send-email-is-not-supported-in-web-direct-on-filemaker-cloud/4076/8 "2024-04-07T07:58:22Z")

</div>

> [@bdbd](#):
>
> sending the email via the server instead (via PSOS). It avoids WebDirect limitations

I don't believe it's necessary to call the script using PSOS. You must be using the oAuth or the SMTP options. Support for the Send Mail step in WebDirect is partial and there are a lot of "buts" described in the documentation.

[https://help.claris.com/en/pro-help/content/send-mail.html](https://help.claris.com/en/pro-help/content/send-mail.html)

---

<div class="post-metadata">

**Author:** ![Bobino](https://yyz2.discourse-cdn.com/flex030/user_avatar/the.fmsoup.org/bobino/32/194_2.png) [@Bobino](https://the.fmsoup.org/u/Bobino)\
**Post date:** [December 29, 2024, 3:27am UTC](https://the.fmsoup.org/t/oauth-2-0-gmail-send-email-is-not-supported-in-web-direct-on-filemaker-cloud/4076/9 "2024-12-29T03:27:54Z")

</div>

While waiting for the documentation to be updated, this discussion thread hints at what the error code descriptions may end up like:

[https://community.claris.com/en/s/question/0D5Vy00000Hbuz9KAB/send-mail-oauth-errors-1542-1543-undocumented](https://community.claris.com/en/s/question/0D5Vy00000Hbuz9KAB/send-mail-oauth-errors-1542-1543-undocumented)

> 1541: JSON Web Token (JWT) could not be generated successfully. Please check to make sure you have entered the private key correctly.

> 1542: Access token could not be generated successfully.

> 1543: Email(s) could not be sent successfully.
