mirror of
https://github.com/LukeHagar/website.git
synced 2025-12-10 04:22:18 +00:00
fix: docs
This commit is contained in:
1352
pnpm-lock.yaml
generated
1352
pnpm-lock.yaml
generated
File diff suppressed because it is too large
Load Diff
@@ -21,7 +21,6 @@ export enum Service {
|
|||||||
Storage = 'storage',
|
Storage = 'storage',
|
||||||
Teams = 'teams',
|
Teams = 'teams',
|
||||||
Users = 'users',
|
Users = 'users',
|
||||||
Messaging = 'messaging'
|
|
||||||
}
|
}
|
||||||
|
|
||||||
export enum Platform {
|
export enum Platform {
|
||||||
|
|||||||
@@ -10,7 +10,7 @@ Custom token allows you to use [Server SDK](/docs/sdks#server) to generate token
|
|||||||
|
|
||||||
# Create custom token {% #create-custom-token %}
|
# Create custom token {% #create-custom-token %}
|
||||||
|
|
||||||
Once you have your server endpoint prepared either in an Appwrite Function or a server integration, you can use the [Create token](/docs/references/cloud/server-nodejs/users#/docs/references/cloud/server-nodejs/users#createToken) endpoint of the [Users API](/docs/products/auth/users) to generate a token.
|
Once you have your server endpoint prepared either in an Appwrite Function or a server integration, you can use the [Create token](/docs/references/cloud/server-nodejs/users#createToken) endpoint of the [Users API](/docs/products/auth/users) to generate a token.
|
||||||
|
|
||||||
{% multicode %}
|
{% multicode %}
|
||||||
```js
|
```js
|
||||||
|
|||||||
@@ -48,7 +48,7 @@ During development, you can add targets to existing accounts by navigating to **
|
|||||||

|

|
||||||
{% /only_light %}
|
{% /only_light %}
|
||||||
|
|
||||||
You can also implement forms in your app to collect contact information and add it as a target with the [createSubscriber](/references/cloud/server-nodejs/messaging#createSubscriber) endpoint.
|
You can also implement forms in your app to collect contact information and add it as a target with the [createSubscriber](/docs/references/cloud/server-nodejs/messaging#createSubscriber) endpoint.
|
||||||
|
|
||||||
{% multicode %}
|
{% multicode %}
|
||||||
```js
|
```js
|
||||||
@@ -92,9 +92,9 @@ client
|
|||||||
;
|
;
|
||||||
|
|
||||||
const promise = messaging.createSubscriber(
|
const promise = messaging.createSubscriber(
|
||||||
'[TOPIC_ID]', // topicId
|
'[TOPIC_ID]', // topicId
|
||||||
'[SUBSCRIBER_ID]', // subscriberId
|
'[SUBSCRIBER_ID]', // subscriberId
|
||||||
'[TARGET_ID]' // targetId
|
'[TARGET_ID]' // targetId
|
||||||
);
|
);
|
||||||
|
|
||||||
promise.then(function (response) {
|
promise.then(function (response) {
|
||||||
@@ -119,9 +119,9 @@ $client
|
|||||||
|
|
||||||
$messaging = new Messaging($client);
|
$messaging = new Messaging($client);
|
||||||
|
|
||||||
$result = $messaging->createSubscriber(
|
$result = $messaging->createSubscriber(
|
||||||
topicId: '[TOPIC_ID]',
|
topicId: '[TOPIC_ID]',
|
||||||
subscriberId: '[SUBSCRIBER_ID]',
|
subscriberId: '[SUBSCRIBER_ID]',
|
||||||
targetId: '[TARGET_ID]'
|
targetId: '[TARGET_ID]'
|
||||||
);
|
);
|
||||||
```
|
```
|
||||||
@@ -139,9 +139,9 @@ client = Client()
|
|||||||
|
|
||||||
messaging = Messaging(client)
|
messaging = Messaging(client)
|
||||||
|
|
||||||
result = messaging.create_subscriber(
|
result = messaging.create_subscriber(
|
||||||
topic_id = '[TOPIC_ID]',
|
topic_id = '[TOPIC_ID]',
|
||||||
subscriber_id = '[SUBSCRIBER_ID]',
|
subscriber_id = '[SUBSCRIBER_ID]',
|
||||||
target_id = '[TARGET_ID]'
|
target_id = '[TARGET_ID]'
|
||||||
)
|
)
|
||||||
```
|
```
|
||||||
@@ -158,8 +158,8 @@ client = Client.new
|
|||||||
messaging = Messaging.new(client)
|
messaging = Messaging.new(client)
|
||||||
|
|
||||||
response = messaging.create_subscriber(
|
response = messaging.create_subscriber(
|
||||||
topic_id: '[TOPIC_ID]',
|
topic_id: '[TOPIC_ID]',
|
||||||
subscriber_id: '[SUBSCRIBER_ID]',
|
subscriber_id: '[SUBSCRIBER_ID]',
|
||||||
target_id: '[TARGET_ID]'
|
target_id: '[TARGET_ID]'
|
||||||
)
|
)
|
||||||
|
|
||||||
@@ -333,8 +333,8 @@ client
|
|||||||
;
|
;
|
||||||
|
|
||||||
const promise = messaging.createTopic(
|
const promise = messaging.createTopic(
|
||||||
'[TOPIC_ID]', // topicId
|
'[TOPIC_ID]', // topicId
|
||||||
'[NAME]' // name
|
'[NAME]' // name
|
||||||
);
|
);
|
||||||
|
|
||||||
promise.then(function (response) {
|
promise.then(function (response) {
|
||||||
@@ -359,8 +359,8 @@ $client
|
|||||||
|
|
||||||
$messaging = new Messaging($client);
|
$messaging = new Messaging($client);
|
||||||
|
|
||||||
$result = $messaging->createTopic(
|
$result = $messaging->createTopic(
|
||||||
topicId: '[TOPIC_ID]',
|
topicId: '[TOPIC_ID]',
|
||||||
name: '[NAME]'
|
name: '[NAME]'
|
||||||
);
|
);
|
||||||
```
|
```
|
||||||
@@ -378,8 +378,8 @@ client = Client()
|
|||||||
|
|
||||||
messaging = Messaging(client)
|
messaging = Messaging(client)
|
||||||
|
|
||||||
result = messaging.create_topic(
|
result = messaging.create_topic(
|
||||||
topic_id = '[TOPIC_ID]',
|
topic_id = '[TOPIC_ID]',
|
||||||
name = '[NAME]'
|
name = '[NAME]'
|
||||||
)
|
)
|
||||||
```
|
```
|
||||||
@@ -396,7 +396,7 @@ client = Client.new
|
|||||||
messaging = Messaging.new(client)
|
messaging = Messaging.new(client)
|
||||||
|
|
||||||
response = messaging.create_topic(
|
response = messaging.create_topic(
|
||||||
topic_id: '[TOPIC_ID]',
|
topic_id: '[TOPIC_ID]',
|
||||||
name: '[NAME]'
|
name: '[NAME]'
|
||||||
)
|
)
|
||||||
|
|
||||||
@@ -512,7 +512,7 @@ let topic = try await messaging.createTopic(
|
|||||||
{% /multicode %}
|
{% /multicode %}
|
||||||
|
|
||||||
# Send SMS messages {% #send-sms %}
|
# Send SMS messages {% #send-sms %}
|
||||||
You can send SMS messages using a Server SDK.
|
You can send SMS messages using a Server SDK.
|
||||||
To send an SMS messages immediately, you can call the `createSMS` endpoint with `status` set to `'processing'` and `schedule` left empty.
|
To send an SMS messages immediately, you can call the `createSMS` endpoint with `status` set to `'processing'` and `schedule` left empty.
|
||||||
|
|
||||||
{% multicode %}
|
{% multicode %}
|
||||||
@@ -561,8 +561,8 @@ client
|
|||||||
;
|
;
|
||||||
|
|
||||||
const promise = messaging.createSMS(
|
const promise = messaging.createSMS(
|
||||||
'[MESSAGE_ID]', // messageId
|
'[MESSAGE_ID]', // messageId
|
||||||
'[CONTENT]', // content
|
'[CONTENT]', // content
|
||||||
[], // topics (optional)
|
[], // topics (optional)
|
||||||
[], // users (optional)
|
[], // users (optional)
|
||||||
[], // targets (optional)
|
[], // targets (optional)
|
||||||
@@ -592,9 +592,9 @@ $client
|
|||||||
|
|
||||||
$messaging = new Messaging($client);
|
$messaging = new Messaging($client);
|
||||||
|
|
||||||
$result = $messaging->createSMS(
|
$result = $messaging->createSMS(
|
||||||
messageId: '[MESSAGE_ID]',
|
messageId: '[MESSAGE_ID]',
|
||||||
content: '[CONTENT]',
|
content: '[CONTENT]',
|
||||||
topics: [], // optional
|
topics: [], // optional
|
||||||
users: [], // optional
|
users: [], // optional
|
||||||
targets: [], // optional
|
targets: [], // optional
|
||||||
@@ -616,9 +616,9 @@ client = Client()
|
|||||||
|
|
||||||
messaging = Messaging(client)
|
messaging = Messaging(client)
|
||||||
|
|
||||||
result = messaging.create_sms(
|
result = messaging.create_sms(
|
||||||
message_id = '[MESSAGE_ID]',
|
message_id = '[MESSAGE_ID]',
|
||||||
content = '[CONTENT]',
|
content = '[CONTENT]',
|
||||||
topics = [], # optional
|
topics = [], # optional
|
||||||
users = [], # optional
|
users = [], # optional
|
||||||
targets = [], # optional
|
targets = [], # optional
|
||||||
@@ -639,8 +639,8 @@ client = Client.new
|
|||||||
messaging = Messaging.new(client)
|
messaging = Messaging.new(client)
|
||||||
|
|
||||||
response = messaging.create_sms(
|
response = messaging.create_sms(
|
||||||
message_id: '[MESSAGE_ID]',
|
message_id: '[MESSAGE_ID]',
|
||||||
content: '[CONTENT]',
|
content: '[CONTENT]',
|
||||||
topics: [], # optional
|
topics: [], # optional
|
||||||
users: [], # optional
|
users: [], # optional
|
||||||
targets: [], # optional
|
targets: [], # optional
|
||||||
@@ -664,11 +664,11 @@ var messaging = new Messaging(client);
|
|||||||
|
|
||||||
Message result = await messaging.CreateSMS(
|
Message result = await messaging.CreateSMS(
|
||||||
messageId: "[MESSAGE_ID]",
|
messageId: "[MESSAGE_ID]",
|
||||||
content: "[CONTENT]"
|
content: "[CONTENT]"
|
||||||
topics: new List<string> {} // optional
|
topics: new List<string> {} // optional
|
||||||
users: new List<string> {} // optional
|
users: new List<string> {} // optional
|
||||||
targets: new List<string> {} // optional
|
targets: new List<string> {} // optional
|
||||||
status: "processing" // optional
|
status: "processing" // optional
|
||||||
scheduledAt: ""); // optional
|
scheduledAt: ""); // optional
|
||||||
```
|
```
|
||||||
```dart
|
```dart
|
||||||
@@ -832,8 +832,8 @@ client
|
|||||||
;
|
;
|
||||||
|
|
||||||
const promise = messaging.createSMS(
|
const promise = messaging.createSMS(
|
||||||
'[MESSAGE_ID]', // messageId
|
'[MESSAGE_ID]', // messageId
|
||||||
'[CONTENT]', // content
|
'[CONTENT]', // content
|
||||||
[], // topics (optional)
|
[], // topics (optional)
|
||||||
[], // users (optional)
|
[], // users (optional)
|
||||||
[], // targets (optional)
|
[], // targets (optional)
|
||||||
@@ -863,9 +863,9 @@ $client
|
|||||||
|
|
||||||
$messaging = new Messaging($client);
|
$messaging = new Messaging($client);
|
||||||
|
|
||||||
$result = $messaging->createSMS(
|
$result = $messaging->createSMS(
|
||||||
messageId: '[MESSAGE_ID]',
|
messageId: '[MESSAGE_ID]',
|
||||||
content: '[CONTENT]',
|
content: '[CONTENT]',
|
||||||
topics: [], // optional
|
topics: [], // optional
|
||||||
users: [], // optional
|
users: [], // optional
|
||||||
targets: [], // optional
|
targets: [], // optional
|
||||||
@@ -887,9 +887,9 @@ client = Client()
|
|||||||
|
|
||||||
messaging = Messaging(client)
|
messaging = Messaging(client)
|
||||||
|
|
||||||
result = messaging.create_sms(
|
result = messaging.create_sms(
|
||||||
message_id = '[MESSAGE_ID]',
|
message_id = '[MESSAGE_ID]',
|
||||||
content = '[CONTENT]',
|
content = '[CONTENT]',
|
||||||
topics = [], # optional
|
topics = [], # optional
|
||||||
users = [], # optional
|
users = [], # optional
|
||||||
targets = [], # optional
|
targets = [], # optional
|
||||||
@@ -910,8 +910,8 @@ client = Client.new
|
|||||||
messaging = Messaging.new(client)
|
messaging = Messaging.new(client)
|
||||||
|
|
||||||
response = messaging.create_sms(
|
response = messaging.create_sms(
|
||||||
message_id: '[MESSAGE_ID]',
|
message_id: '[MESSAGE_ID]',
|
||||||
content: '[CONTENT]',
|
content: '[CONTENT]',
|
||||||
topics: [], # optional
|
topics: [], # optional
|
||||||
users: [], # optional
|
users: [], # optional
|
||||||
targets: [], # optional
|
targets: [], # optional
|
||||||
@@ -935,11 +935,11 @@ var messaging = new Messaging(client);
|
|||||||
|
|
||||||
Message result = await messaging.CreateSMS(
|
Message result = await messaging.CreateSMS(
|
||||||
messageId: "[MESSAGE_ID]",
|
messageId: "[MESSAGE_ID]",
|
||||||
content: "[CONTENT]"
|
content: "[CONTENT]"
|
||||||
topics: new List<string> {} // optional
|
topics: new List<string> {} // optional
|
||||||
users: new List<string> {} // optional
|
users: new List<string> {} // optional
|
||||||
targets: new List<string> {} // optional
|
targets: new List<string> {} // optional
|
||||||
status: "scheduled" // optional
|
status: "scheduled" // optional
|
||||||
scheduledAt: "2025-02-13T22:01:00+0000"); // optional
|
scheduledAt: "2025-02-13T22:01:00+0000"); // optional
|
||||||
```
|
```
|
||||||
```dart
|
```dart
|
||||||
|
|||||||
Reference in New Issue
Block a user