1 | # User
|
2 |
|
3 | ## Properties
|
4 |
|
5 | ### id
|
6 | User's unique ID
|
7 | **Type:** Int
|
8 |
|
9 | ### first_name
|
10 | User's first name
|
11 | **Type:** String
|
12 |
|
13 | ### last_name
|
14 | User's last name
|
15 | **Type:** String
|
16 |
|
17 | ### profile_pic
|
18 | User's profile picture
|
19 | **Type:** String
|
20 |
|
21 | ### locale
|
22 | User's language
|
23 | **Type:** String
|
24 |
|
25 | ### timezone
|
26 | UTC +timezone
|
27 | **Type:** Int
|
28 |
|
29 | ### gender
|
30 | User's gender
|
31 | **Type:** String
|
32 |
|
33 | ## Methods
|
34 |
|
35 | ### fullname
|
36 | Returns first_name + last_name with a white space between
|
37 |
|
38 | ### send
|
39 | Sends 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
|
48 | Sends 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
|
58 | Sends 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
|
67 | Sends 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
|
76 | Sends 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
|
85 | Sends 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 |