Layer 220
AccountUploadRingtone
Upload notification sound, use account. save Ringtone to convert it and add it to the list of saved notification sounds.
method
Users
account.uploadRingtone#831a83a2 file:InputFile file_name:string mime_type:string = Document;
Parameters
| Name | Type | Description |
|---|---|---|
| File | InputFile | Notification sound |
| FileName | string | File name |
| MimeType | string | MIME type of file |
Returns
DocumentPossible Errors
| Code | Type | Description |
|---|---|---|
| 400 | RINGTONE_MIME_INVALID | The MIME type for the ringtone is invalid. |
Gogram Example
// AccountUploadRingtone - positional arguments result, err := client.AccountUploadRingtone(&tg.InputFile{ID: int64(0), Parts: 1, Name: "file.dat"}, "...", "...") if err != nil { // handle error } // result is *tg.Document