@ariary/ariary 3.0.4 → 3.0.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +4 -8
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -12,7 +12,6 @@ npm install @ariary/ariary
|
|
|
12
12
|
|
|
13
13
|
```typescript
|
|
14
14
|
import { Ariari, Task, Payment } from '@ariary/ariary';
|
|
15
|
-
```
|
|
16
15
|
|
|
17
16
|
Ariari.config({
|
|
18
17
|
projectId: 'your-project-id',
|
|
@@ -25,8 +24,6 @@ Ariari.config({
|
|
|
25
24
|
|
|
26
25
|
## Notification
|
|
27
26
|
|
|
28
|
-
### Send Notification
|
|
29
|
-
|
|
30
27
|
```typescript
|
|
31
28
|
const task = await Ariari.send(
|
|
32
29
|
{ phone: '+261123456789', message: 'Message 1' },
|
|
@@ -41,8 +38,6 @@ const status = await task.status();
|
|
|
41
38
|
const details = await task.smsDetails();
|
|
42
39
|
// Returns TaskDetails with notifTaskId, projectId, summary, smsDetails array, and createdAt
|
|
43
40
|
```
|
|
44
|
-
|
|
45
|
-
|
|
46
41
|
### List Tasks
|
|
47
42
|
|
|
48
43
|
```typescript
|
|
@@ -52,9 +47,10 @@ const result = await Ariari.tasks({
|
|
|
52
47
|
order: -1
|
|
53
48
|
});
|
|
54
49
|
|
|
55
|
-
const
|
|
56
|
-
|
|
57
|
-
const
|
|
50
|
+
const fetchTasks = (from) => Ariari.tasks({ from, count: 20, order: -1 });
|
|
51
|
+
|
|
52
|
+
const nextResult = await fetchTasks(result.next);
|
|
53
|
+
const prevResult = await fetchTasks(result.prev);
|
|
58
54
|
```
|
|
59
55
|
|
|
60
56
|
## Payment
|