Skip to content

Conversation

@gewenyu99
Copy link
Contributor

What does this PR do?

(Provide a description of what this PR does.)

Test Plan

(Write your test plan here. If you changed any code, please provide us with clear instructions on how you verified your changes work.)

Related PRs and Issues

(If this PR is related to any other PR or resolves any issue or related to any issue link all related PR and issues here.)

Have you read the Contributing Guidelines on issues?

(Write your answer here.)

@render
Copy link

render bot commented Jan 31, 2024

@gewenyu99 gewenyu99 changed the base branch from main to 1.5.x January 31, 2024 04:00
Copy link
Contributor Author

@gewenyu99 gewenyu99 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Start of concept pages

# Sending a message {% #create-a-message %}
You can create a message with the `METHOD` method using a Server SDK.
{% multicode %}
```js
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@abnegate @stnguyen90 Simple code example of just the three methods.

We will cover full flow in detail in their journies.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You should be able to determine the methods from the API. Do you need additional detail?


# Types of targets {% #types-of-targets %}

[@abnegate @stnguyen90: TODO types of targets and how to create/add targets in console + code.]
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@abnegate @stnguyen90 What are the different target types called?

What's the code like for creating targets?

Is there client code required?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What are the different target types called?

// Message types
const MESSAGE_TYPE_EMAIL = 'email';
const MESSAGE_TYPE_SMS = 'sms';
const MESSAGE_TYPE_PUSH = 'push';

https://github.com/appwrite/appwrite/blob/49a753509b17ee4209999e08678e8cad71a20bee/app/init.php#L197-L199

What's the code like for creating targets?

Client-side, you can only create a push target:

account.createPushTarget()

Server-side, you can create any target:

users.createTarget()

Is there client code required?

Did I answer your question?

{% /tabsitem %}

{% tabsitem #server-sdk title="Server SDK" %}
Lorem ipsum dolor sit amet consectetur.
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@abnegate @stnguyen90 Simple server SDK examples <3

{% /tabsitem %}

{% tabsitem #server-sdk title="Server SDK" %}
Lorem ipsum dolor sit amet consectetur.
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@abnegate @stnguyen90 Simple server SDK examples <3

Copy link
Contributor

@stnguyen90 stnguyen90 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

see replies

@gewenyu99 gewenyu99 merged commit bd1881b into 1.5.x Feb 6, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants