Package io.getstream.chat.java.services
Interface PollService
-
public interface PollService
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description @NotNull retrofit2.Call<Poll.PollVoteCastResponse>castVote(@NotNull java.lang.String messageId, @NotNull java.lang.String pollId, @NotNull Poll.PollVoteCastRequestData pollVoteCastRequestData)@NotNull retrofit2.Call<Poll.PollCreateResponse>create(@NotNull Poll.PollCreateRequestData pollCreateRequestData)@NotNull retrofit2.Call<Poll.PollOptionCreateResponse>createOption(@NotNull java.lang.String pollId, @NotNull Poll.PollOptionCreateRequestData pollOptionCreateRequestData)@NotNull retrofit2.Call<Poll.PollDeleteResponse>delete(@NotNull java.lang.String pollId, @Nullable java.lang.String userId)@NotNull retrofit2.Call<Poll.PollOptionDeleteResponse>deleteOption(@NotNull java.lang.String pollId, @NotNull java.lang.String optionId, @Nullable java.lang.String userId)@NotNull retrofit2.Call<Poll.PollVoteDeleteResponse>deleteVote(@NotNull java.lang.String messageId, @NotNull java.lang.String pollId, @NotNull java.lang.String voteId)@NotNull retrofit2.Call<Poll.PollGetResponse>get(@NotNull java.lang.String pollId)@NotNull retrofit2.Call<Poll.PollOptionGetResponse>getOption(@NotNull java.lang.String pollId, @NotNull java.lang.String optionId)@NotNull retrofit2.Call<Poll.PollQueryResponse>query(@NotNull Poll.PollQueryRequestData pollQueryRequestData, @Nullable java.lang.String userId)@NotNull retrofit2.Call<Poll.PollVoteQueryResponse>queryVotes(@NotNull java.lang.String pollId, @NotNull Poll.PollVoteQueryRequestData pollVoteQueryRequestData, @Nullable java.lang.String userId)@NotNull retrofit2.Call<Poll.PollUpdateResponse>update(@NotNull Poll.PollUpdateRequestData pollUpdateRequestData)@NotNull retrofit2.Call<Poll.PollOptionUpdateResponse>updateOption(@NotNull java.lang.String pollId, @NotNull Poll.PollOptionUpdateRequestData pollOptionUpdateRequestData)@NotNull retrofit2.Call<Poll.PollUpdatePartialResponse>updatePartial(@NotNull java.lang.String pollId, @NotNull Poll.PollUpdatePartialRequestData pollUpdatePartialRequestData)
-
-
-
Method Detail
-
create
@POST("polls") @NotNull @NotNull retrofit2.Call<Poll.PollCreateResponse> create(@NotNull @Body @NotNull Poll.PollCreateRequestData pollCreateRequestData)
-
get
@GET("polls/{poll_id}") @NotNull @NotNull retrofit2.Call<Poll.PollGetResponse> get(@NotNull @Path("poll_id") @NotNull java.lang.String pollId)
-
update
@PUT("polls") @NotNull @NotNull retrofit2.Call<Poll.PollUpdateResponse> update(@NotNull @Body @NotNull Poll.PollUpdateRequestData pollUpdateRequestData)
-
updatePartial
@PATCH("polls/{poll_id}") @NotNull @NotNull retrofit2.Call<Poll.PollUpdatePartialResponse> updatePartial(@NotNull @Path("poll_id") @NotNull java.lang.String pollId, @NotNull @Body @NotNull Poll.PollUpdatePartialRequestData pollUpdatePartialRequestData)
-
delete
@DELETE("polls/{poll_id}") @NotNull @NotNull retrofit2.Call<Poll.PollDeleteResponse> delete(@NotNull @Path("poll_id") @NotNull java.lang.String pollId, @Nullable @Query("user_id") @Nullable java.lang.String userId)
-
query
@POST("polls/query") @NotNull @NotNull retrofit2.Call<Poll.PollQueryResponse> query(@NotNull @Body @NotNull Poll.PollQueryRequestData pollQueryRequestData, @Nullable @Query("user_id") @Nullable java.lang.String userId)
-
createOption
@POST("polls/{poll_id}/options") @NotNull @NotNull retrofit2.Call<Poll.PollOptionCreateResponse> createOption(@NotNull @Path("poll_id") @NotNull java.lang.String pollId, @NotNull @Body @NotNull Poll.PollOptionCreateRequestData pollOptionCreateRequestData)
-
getOption
@GET("polls/{poll_id}/options/{option_id}") @NotNull @NotNull retrofit2.Call<Poll.PollOptionGetResponse> getOption(@NotNull @Path("poll_id") @NotNull java.lang.String pollId, @NotNull @Path("option_id") @NotNull java.lang.String optionId)
-
updateOption
@PUT("polls/{poll_id}/options") @NotNull @NotNull retrofit2.Call<Poll.PollOptionUpdateResponse> updateOption(@NotNull @Path("poll_id") @NotNull java.lang.String pollId, @NotNull @Body @NotNull Poll.PollOptionUpdateRequestData pollOptionUpdateRequestData)
-
deleteOption
@DELETE("polls/{poll_id}/options/{option_id}") @NotNull @NotNull retrofit2.Call<Poll.PollOptionDeleteResponse> deleteOption(@NotNull @Path("poll_id") @NotNull java.lang.String pollId, @NotNull @Path("option_id") @NotNull java.lang.String optionId, @Nullable @Query("user_id") @Nullable java.lang.String userId)
-
queryVotes
@POST("polls/{poll_id}/votes") @NotNull @NotNull retrofit2.Call<Poll.PollVoteQueryResponse> queryVotes(@NotNull @Path("poll_id") @NotNull java.lang.String pollId, @NotNull @Body @NotNull Poll.PollVoteQueryRequestData pollVoteQueryRequestData, @Nullable @Query("user_id") @Nullable java.lang.String userId)
-
castVote
@POST("messages/{message_id}/polls/{poll_id}/vote") @NotNull @NotNull retrofit2.Call<Poll.PollVoteCastResponse> castVote(@NotNull @Path("message_id") @NotNull java.lang.String messageId, @NotNull @Path("poll_id") @NotNull java.lang.String pollId, @NotNull @Body @NotNull Poll.PollVoteCastRequestData pollVoteCastRequestData)
-
deleteVote
@DELETE("messages/{message_id}/polls/{poll_id}/vote/{vote_id}") @NotNull @NotNull retrofit2.Call<Poll.PollVoteDeleteResponse> deleteVote(@NotNull @Path("message_id") @NotNull java.lang.String messageId, @NotNull @Path("poll_id") @NotNull java.lang.String pollId, @NotNull @Path("vote_id") @NotNull java.lang.String voteId)
-
-