-
-
Notifications
You must be signed in to change notification settings - Fork 386
BOT API v9.4 #431
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
BOT API v9.4 #431
Changes from all commits
c9d71b6
2f11974
5d079d9
b6a933d
7ce5730
7c18d17
91f4ef5
b1b4cfc
f53ba08
ad8e5f9
8c96ca3
62be061
7fb1b76
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,22 @@ | ||
| package com.pengrad.telegrambot.model | ||
|
|
||
| data class UserProfileAudios( | ||
| @get:JvmName("totalCount") val totalCount: Int, | ||
| @get:JvmName("audios") val audios: Array<Audio> | ||
| ) { | ||
|
|
||
| override fun equals(other: Any?): Boolean { | ||
| if (this === other) return true | ||
| if (other !is UserProfileAudios) return false | ||
|
|
||
| return totalCount == other.totalCount && | ||
| audios contentEquals other.audios | ||
| } | ||
|
|
||
| override fun hashCode(): Int { | ||
| var result = totalCount.hashCode() | ||
| result = 31 * result + audios.contentHashCode() | ||
| return result | ||
| } | ||
|
|
||
| } |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,10 @@ | ||
| package com.pengrad.telegrambot.model | ||
|
|
||
| data class VideoQuality( | ||
| @get:JvmName("fileId") val fileId: String, | ||
| @get:JvmName("fileUniqueId") val fileUniqueId: String, | ||
| @get:JvmName("width") val width: Int, | ||
| @get:JvmName("height") val height: Int, | ||
| @get:JvmName("codec") val codec: String, | ||
| @get:JvmName("fileSize") val fileSize: Long? = null | ||
| ) |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,8 @@ | ||
| package com.pengrad.telegrambot.model.chatowner | ||
|
|
||
| import com.pengrad.telegrambot.model.User | ||
|
|
||
| data class ChatOwnerChanged( | ||
| @get:JvmName("newOwner") val newOwner: User | ||
| ) { | ||
| } | ||
| Original file line number | Diff line number | Diff line change | ||||||
|---|---|---|---|---|---|---|---|---|
| @@ -0,0 +1,8 @@ | ||||||||
| package com.pengrad.telegrambot.model.chatowner | ||||||||
|
|
||||||||
| import com.pengrad.telegrambot.model.User | ||||||||
|
|
||||||||
| data class ChatOwnerLeft( | ||||||||
| @get:JvmName("newOwner") val newOwner: User | ||||||||
| ) { | ||||||||
| } | ||||||||
|
Comment on lines
+7
to
+8
|
||||||||
| ) { | |
| } | |
| ) |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,20 @@ | ||
| package com.pengrad.telegrambot.request | ||
|
|
||
| import com.pengrad.telegrambot.response.GetUserProfileAudiosResponse | ||
| import com.pengrad.telegrambot.utility.kotlin.optionalRequestParameter | ||
| import com.pengrad.telegrambot.utility.kotlin.requestParameter | ||
|
|
||
| class GetUserProfileAudios( | ||
| userId: Long | ||
| ) : KBaseRequest<GetUserProfileAudios, GetUserProfileAudiosResponse>(GetUserProfileAudiosResponse::class) { | ||
|
|
||
| val userId: Long by requestParameter(userId) | ||
|
|
||
| var offset: Int? by optionalRequestParameter() | ||
| var limit: Int? by optionalRequestParameter() | ||
|
|
||
| fun offset(offset: Int) = applySelf { this.offset = offset } | ||
|
|
||
| fun limit(limit: Int) = applySelf { this.limit = limit } | ||
|
|
||
| } |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,7 @@ | ||
| package com.pengrad.telegrambot.request | ||
|
|
||
| import com.pengrad.telegrambot.response.BaseResponse | ||
|
|
||
| class RemoveMyProfilePhoto ( | ||
|
|
||
| ) : KBaseRequest<RemoveMyProfilePhoto, BaseResponse>(BaseResponse::class) | ||
|
Comment on lines
+5
to
+7
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,14 @@ | ||
| package com.pengrad.telegrambot.request | ||
|
|
||
| import com.pengrad.telegrambot.model.inputprofilephoto.InputProfilePhoto | ||
| import com.pengrad.telegrambot.response.BaseResponse | ||
| import com.pengrad.telegrambot.utility.kotlin.requestParameter | ||
|
|
||
| class SetMyProfilePhoto( | ||
| photo: InputProfilePhoto | ||
|
|
||
| ) : KBaseRequest<SetMyProfilePhoto, BaseResponse>(BaseResponse::class) { | ||
|
|
||
| val photo: InputProfilePhoto by requestParameter(photo) | ||
|
|
||
| } |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,5 @@ | ||
| package com.pengrad.telegrambot.response | ||
|
|
||
| import com.pengrad.telegrambot.model.UserProfileAudios | ||
|
|
||
| data class GetUserProfileAudiosResponse(val result: UserProfileAudios) : BaseResponse() |
Uh oh!
There was an error while loading. Please reload this page.