UNPKG

2.47 kBMarkdownView Raw
1# User
2
3## Properties
4
5### id
6User's unique ID
7**Type:** Int
8
9### first_name
10User's first name
11**Type:** String
12
13### last_name
14User's last name
15**Type:** String
16
17### profile_pic
18User's profile picture
19**Type:** String
20
21### locale
22User's language
23**Type:** String
24
25### timezone
26UTC +timezone
27**Type:** Int
28
29### gender
30User's gender
31**Type:** String
32
33## Methods
34
35### fullname
36Returns first_name + last_name with a white space between
37
38### send
39Sends a message
40
41| Parameter | Type | Description |
42|:-------------------------------|:------------------|:---------------------|
43| value | String, Number, Object | Any value |
44| options / callback | Object / Function | Optional |
45| callback | Function | Optional |
46
47### sendAttachment
48Sends an attachment to the user
49
50| Parameter | Type | Description |
51|:-------------------------------|:------------------|:---------------------|
52| type | String | Attachment type ("image", "audio", "video", "file) |
53| url | String | URL of attachment |
54
55**Returns:** Promise
56
57### sendImage
58Sends an image to the user
59
60| Parameter | Type | Description |
61|:-------------------------------|:------------------|:---------------------|
62| url | String | URL of the image |
63
64**Returns:** Promise
65
66### sendAudio
67Sends an audio to the user
68
69| Parameter | Type | Description |
70|:-------------------------------|:------------------|:---------------------|
71| url | String | URL of the audio |
72
73**Returns:** Promise
74
75### sendVideo
76Sends a video to the user
77
78| Parameter | Type | Description |
79|:-------------------------------|:------------------|:---------------------|
80| url | String | URL of the video |
81
82**Returns:** Promise
83
84### sendFile
85Sends a file to the user
86
87| Parameter | Type | Description |
88|:-------------------------------|:------------------|:---------------------|
89| url | String | URL of the file |
90
91**Returns:** Promise
\No newline at end of file