Skip to content

Commit 4e98760

Browse files
committed
Added vCard support when sharing contacts
added the field vcard to the objects Contact, InlineQueryResultContact, InputContactMessageContent and the method sendContact.
1 parent ea63778 commit 4e98760

File tree

4 files changed

+28
-0
lines changed

4 files changed

+28
-0
lines changed

src/Telegram/Methods/SendContact.php

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,13 @@ class SendContact extends TelegramMethods
4040
*/
4141
public $last_name = '';
4242

43+
/**
44+
* Optional. Additional data about the contact in the form of a vCard, 0-2048 bytes
45+
* @see https://en.wikipedia.org/wiki/VCard
46+
* @var string
47+
*/
48+
public $vcard = '';
49+
4350
/**
4451
* Optional. Sends the message silently. iOS users will not receive a notification, Android users will receive a
4552
* notification with no sound.

src/Telegram/Types/Contact.php

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,4 +38,11 @@ class Contact extends TelegramTypes
3838
* @var int
3939
*/
4040
public $user_id = 0;
41+
42+
/**
43+
* Optional. Additional data about the contact in the form of a vCard
44+
* @see https://en.wikipedia.org/wiki/VCard
45+
* @var string
46+
*/
47+
public $vcard = '';
4148
}

src/Telegram/Types/Inline/Query/Result/Contact.php

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,13 @@ class Contact extends Result
4141
*/
4242
public $last_name = '';
4343

44+
/**
45+
* Optional. Additional data about the contact in the form of a vCard, 0-2048 bytes
46+
* @see https://en.wikipedia.org/wiki/VCard
47+
* @var string
48+
*/
49+
public $vcard = '';
50+
4451
/**
4552
* Optional. Url of the thumbnail for the result
4653
* @var string

src/Telegram/Types/InputMessageContent/Contact.php

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,4 +33,11 @@ class Contact extends InputMessageContent
3333
* @var string
3434
*/
3535
public $last_name = '';
36+
37+
/**
38+
* Optional. Additional data about the contact in the form of a vCard, 0-2048 bytes
39+
* @see https://en.wikipedia.org/wiki/VCard
40+
* @var string
41+
*/
42+
public $vcard = '';
3643
}

0 commit comments

Comments
 (0)