-
Notifications
You must be signed in to change notification settings - Fork 297
Add all providers #563
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add all providers #563
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,14 +1,90 @@ | ||
| --- | ||
| layout: article | ||
| title: Apple Push Notification service | ||
| description: Send push notifications to apps on Apple devices through Apple Push Notification service (APNs) using Appwrite Messaging. | ||
| back: /docs | ||
| title: Firebase Cloud Messaging | ||
| description: Send push notifications to Android, Apple, or Web app with Firebase Cloud Messaging (FCM). | ||
| back: /docs/products/messaging/providers | ||
| --- | ||
|
|
||
| Apple Push Notification service (APNs) lets you send push notifications to Apple devices like macOS, iOS, tvOS, iPadOS, and watchOS devices. | ||
| APNs is a best-effort service, and will attempt to deliver you messages to your device when it's online and available again. | ||
| APNs will save the last [N] messages for [M] days and attempt delivery as soon as it's online. | ||
| Firebase Cloud Messaging (FCM) lets you send push notifications to your iOS, Android, and web apps through Appwrite Messaging. | ||
| Before you can deliver messages, you must connect to a messaging provider. | ||
|
|
||
| # Add provider {% #add-provider %} | ||
| To add APNs as a provier, navigate to **Messaging** > **Providers** > {% icon icon="plus" /%} **Add provider** | ||
| [SCREENSHOT] | ||
| {% section #add-provider step=1 title="Add provider" %} | ||
|
|
||
| To add FCM as a provider, navigate to **Messaging** > **Providers** > {% icon icon="plus" size="m" /%} **Add provider** > **Push notification**. | ||
| [SCREENSHOT] | ||
|
|
||
| Give your provider a name > choose **FCM** > click **Save and continue**. | ||
| The provider will be saved to your project, but not enabled until you complete its configuration. | ||
| {% /section %} | ||
| {% section #configure-provider step=2 title="Configure provider" %} | ||
|
|
||
| In the **Configure** step, you will need to provide details form your Firebase console to connect your Appwrite project. | ||
|
|
||
| [SCREENSHOT] | ||
|
|
||
| You will need to provide the following information from the **Firebase console**. | ||
|
|
||
| {% info title="Enable FCM" %} | ||
| FCM must be enabled on your Firebase project. | ||
|
|
||
| Head to Firebase console -> Settings -> Project settings -> Cloud Messaging. | ||
| If FCM is disabled, click the three-dots menu and open the link. On the following page, click **Enable** (it might take a few minutes for the action to complete). | ||
| {% /info %} | ||
|
|
||
| {% table %} | ||
| * Field name | ||
| * | ||
| --- | ||
| * Server key (.json file) | ||
| * Head to Project settings -> Service accounts -> Generate new private key. | ||
| {% /table %} | ||
|
|
||
| After adding the following details, click **Save and continue** to enable the provider. | ||
| {% /section %} | ||
|
|
||
| {% section #test-provider step=3 title="Test provider" %} | ||
| Before sending your first message, | ||
| make sure you've configured [a topic](/docs/products/messaging/topic) and [a target](/docs/products/messaging/target) to send messages to. | ||
| {% tabs %} | ||
| {% tabsitem #console title="Console" %} | ||
| To send a test message, navigate to **Messaging** > **Messages** > {% icon icon="plus" size="m" /%} **Create message** > **Push notification**. | ||
| [SCREENSHOT] | ||
|
|
||
| Add your message and in the targets step, select one of your test targets. Set the schedule to **Now** and click **Send**. | ||
|
|
||
| Verify that you can receive the message in your inbox. If not | ||
| {% /tabsitem %} | ||
|
|
||
| {% tabsitem #server-sdk title="Server SDK" %} | ||
| To send a message programmatically, use an [Appwrite Server SDK](/docs/sdks#server). | ||
| {% multicode %} | ||
| ```js | ||
|
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @abnegate @stnguyen90 Code example for sending a message through this provider |
||
| ``` | ||
| ```deno | ||
| ``` | ||
| ```php | ||
| ``` | ||
| ```python | ||
| ``` | ||
| ```ruby | ||
| ``` | ||
| ```csharp | ||
| ``` | ||
| ```dart | ||
| ``` | ||
| ```kotlin | ||
| ``` | ||
| ```java | ||
| ``` | ||
| ```swift | ||
| ``` | ||
| {% /multicode %} | ||
| {% /tabsitem %} | ||
| {% /tabs %} | ||
|
|
||
| You can follow the [Send push notifications](TODO) journey to send your first push notification and test your provider. | ||
| {% /section %} | ||
|
|
||
| {% section #manage-provider step=4 title="Manage provider" %} | ||
| [TODO: How to update and delete provider.] | ||
| {% /section %} | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,103 @@ | ||
| --- | ||
| layout: article | ||
| title: Mailgun | ||
| description: Send emails to your Appwrite users using Mailgun and Appwrite Messaging. | ||
| back: /docs/products/messaging/providers | ||
| --- | ||
|
|
||
| Mailgun lets you send customized email messages to your users. | ||
| These emails can be sent immediately or scheduled. | ||
| You can send emails for purposes like reminders, promotions, announcements, and even custom authentication flows. | ||
|
|
||
| {% section #add-provider step=1 title="Add provider" %} | ||
|
|
||
| To add Mailgun as a provider, navigate to **Messaging** > **Providers** > {% icon icon="plus" size="m" /%} **Add provider** > **Email**. | ||
| [SCREENSHOT] | ||
|
|
||
| Give your provider a name > choose **Mailgun** > click **Save and continue**. | ||
| The provider will be saved to your project, but not enabled until you complete its configuration. | ||
| {% /section %} | ||
| {% section #configure-provider step=2 title="Configure provider" %} | ||
|
|
||
| In the **Configure** step, you will need to provide details form your Mailgun dashboard to connect your Appwrite project. | ||
|
|
||
| [SCREENSHOT] | ||
|
|
||
| You will need to provide the following information from your **Mailgun dashboard**. | ||
|
|
||
| {% table %} | ||
| * Field name | ||
| * | ||
| --- | ||
| * API key | ||
| * Head to Profile -> API Security -> Add new key. | ||
| --- | ||
| * Domain | ||
| * Head to Sending -> Domains -> Add new domain. | ||
| Follow [Mailgun's instructions](https://help.mailgun.com/hc/en-us/articles/360026833053-Domain-Verification-Walkthrough) to verify the domain name. | ||
| --- | ||
| * EU region | ||
| * Enable the EU region setting if your domain is within the European Union. | ||
| --- | ||
| * Sender email | ||
| * [TODO] | ||
| --- | ||
| * Sender name | ||
| * [TODO] | ||
| --- | ||
| * Reply-to email | ||
| * [TODO] | ||
| --- | ||
| * Reply-to name | ||
| * [TODO] | ||
| {% /table %} | ||
|
|
||
| After adding the following details, click **Save and continue** to enable the provider. | ||
| {% /section %} | ||
|
|
||
| {% section #test-provider step=3 title="Test provider" %} | ||
| Before sending your first message, | ||
| make sure you've configured [a topic](/docs/products/messaging/topic) and [a target](/docs/products/messaging/target) to send messages to. | ||
| {% tabs %} | ||
| {% tabsitem #console title="Console" %} | ||
| To send a test message, navigate to **Messaging** > **Messages** > {% icon icon="plus" size="m" /%} **Create message** > **Email**. | ||
| [SCREENSHOT] | ||
|
|
||
| Add your message and in the targets step, select one of your test targets. Set the schedule to **Now** and click **Send**. | ||
|
|
||
| Verify that you can receive the message in your inbox. If not | ||
| {% /tabsitem %} | ||
|
|
||
| {% tabsitem #server-sdk title="Server SDK" %} | ||
| To send a message programmatically, use an [Appwrite Server SDK](/docs/sdks#server). | ||
| {% multicode %} | ||
| ```js | ||
|
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @abnegate @stnguyen90 Code example for sending a message through this provider |
||
| ``` | ||
| ```deno | ||
| ``` | ||
| ```php | ||
| ``` | ||
| ```python | ||
| ``` | ||
| ```ruby | ||
| ``` | ||
| ```csharp | ||
| ``` | ||
| ```dart | ||
| ``` | ||
| ```kotlin | ||
| ``` | ||
| ```java | ||
| ``` | ||
| ```swift | ||
| ``` | ||
| {% /multicode %} | ||
| {% /tabsitem %} | ||
| {% /tabs %} | ||
|
|
||
| You can follow the [Send push notifications](TODO) journey to send your first push notification and test your provider. | ||
| {% /section %} | ||
|
|
||
| {% section #manage-provider step=4 title="Manage provider" %} | ||
| [TODO: How to update and delete provider.] | ||
| {% /section %} | ||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@abnegate @stnguyen90 Code example for sending a message through this provider