retrofit2.http.POST Java Examples

The following examples show how to use retrofit2.http.POST. You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: PersonApis.java    From Yuan-WanAndroid with Apache License 2.0 5 votes vote down vote up
/**
 * 注册
 * http://www.wanandroid.com/user/register
 */
@POST("user/register")
@FormUrlEncoded
Observable<BaseResponse<Login>> register(@Field("username") String username,
                                         @Field("password") String password,
                                         @Field("repassword") String rePassword//确认密码
);
 
Example #2
Source File: PersonApis.java    From Yuan-WanAndroid with Apache License 2.0 5 votes vote down vote up
/**
 * 登陆
 * http://www.wanandroid.com/user/login
 */
@POST("user/login")
@FormUrlEncoded
Observable<BaseResponse<Login>> login(
        @Field("username") String userName,
        @Field("password") String password
);
 
Example #3
Source File: CollectApis.java    From Yuan-WanAndroid with Apache License 2.0 5 votes vote down vote up
/**
 * 收藏列表下取消收藏
 * http://www.wanandroid.com/lg/uncollect/2805/json
 */
@POST("lg/uncollect/{id}/json")
@FormUrlEncoded
Observable<BaseResponse> unCollection(@Path("id") int id,//收藏在我的收藏列表的id
                                      @Field("originId") int originId);
 
Example #4
Source File: RestService.java    From FastWaiMai with MIT License 4 votes vote down vote up
@POST
Call<String> postRaw(@HeaderMap Map<String,Object> headers,@Url String url, @Body RequestBody body);
 
Example #5
Source File: V9PornServiceApi.java    From v9porn with MIT License 4 votes vote down vote up
@Headers({"Domain-Name: " + Api.PORN9_VIDEO_DOMAIN_NAME})
@FormUrlEncoded
@POST("/my_favour.php")
Observable<String> deleteMyFavoriteVideo(@Field("rvid") String rvid, @Field("removfavour") String removFavour, @Field("submit") String submit, @Header("Referer") String referer);
 
Example #6
Source File: RxRestService.java    From FastWaiMai with MIT License 4 votes vote down vote up
@Multipart
@POST
Observable<String> upload(@Url String url, @Part MultipartBody.Part files);
 
Example #7
Source File: RxRestService.java    From FastWaiMai with MIT License 4 votes vote down vote up
@POST
Observable<String> postRaw(@Url String url, @Body RequestBody body);
 
Example #8
Source File: RxRestService.java    From FastWaiMai with MIT License 4 votes vote down vote up
@POST
@FormUrlEncoded
Observable<String> post(@Url String url, @FieldMap Map<String, Object> params);
 
Example #9
Source File: RestService.java    From FastWaiMai with MIT License 4 votes vote down vote up
@Multipart
@POST
Call<String> upload(@Url String url, @Part MultipartBody.Part files);
 
Example #10
Source File: OAuthResponseService.java    From PixivforMuzei3 with GNU General Public License v3.0 4 votes vote down vote up
@FormUrlEncoded
@POST("/auth/token")
Call<OauthResponse> postRefreshToken(@FieldMap Map<String, String> params);
 
Example #11
Source File: RestService.java    From FastWaiMai with MIT License 4 votes vote down vote up
@POST
@FormUrlEncoded
Call<String> post(@Url String url, @FieldMap Map<String,Object> params);
 
Example #12
Source File: OAuthSecureService.java    From Pix-EzViewer with MIT License 4 votes vote down vote up
@FormUrlEncoded
@POST("/auth/token")
Observable<PixivOAuthResponse> postRefreshAuthToken(@Field("client_id") String paramString1, @Field("client_secret") String paramString2, @Field("grant_type") String paramString3, @Field("refresh_token") String paramString4, @Field("device_token") String paramString5, @Field("get_secure_url") boolean paramBoolean);
 
Example #13
Source File: OAuthSecureService.java    From Pix-EzViewer with MIT License 4 votes vote down vote up
@FormUrlEncoded
@POST("/auth/token")
Observable<PixivOAuthResponse> postAuthToken(@FieldMap Map<String, Object> map);
 
Example #14
Source File: OAuthSecureService.java    From Pix-EzViewer with MIT License 4 votes vote down vote up
@FormUrlEncoded
@POST("/auth/token")
Call<ResponseBody> postAuthTokenx(@FieldMap Map<String, Object> map);
 
Example #15
Source File: OAuthSecureService.java    From Pix-EzViewer with MIT License 4 votes vote down vote up
@FormUrlEncoded
@POST("/auth/token")
Call<PixivOAuthResponse> postAuthTokenSync(@Field("client_id") String paramString1, @Field("client_secret") String paramString2, @Field("grant_type") String paramString3, @Field("username") String paramString4, @Field("password") String paramString5, @Field("device_token") String paramString6, @Field("get_secure_url") boolean paramBoolean);
 
Example #16
Source File: TinEyeApi.java    From Pixiv-Shaft with MIT License 4 votes vote down vote up
@Multipart
@POST("/search")
Observable<Response<ResponseBody>> query(@Part MultipartBody.Part part);
 
Example #17
Source File: SignApi.java    From Pixiv-Shaft with MIT License 4 votes vote down vote up
@FormUrlEncoded
@POST("/api/account/edit")
Observable<AccountEditResponse> changeEmailAndPixivID(@Header("Authorization") String token,
                                            @Field("new_mail_address") String new_mail_address,
                                            @Field("new_user_account") String new_user_account,
                                            @Field("current_password") String current_password);
 
Example #18
Source File: AppApi.java    From Pixiv-Shaft with MIT License 4 votes vote down vote up
@Multipart
@POST("v1/user/profile/edit")
Observable<NullResponse> updateUserProfile(@Header("Authorization") String token,
                                           @Part List<MultipartBody.Part> parts);
 
Example #19
Source File: AppApi.java    From Pixiv-Shaft with MIT License 4 votes vote down vote up
@FormUrlEncoded
@POST("v1/novel/bookmark/delete")
Observable<NullResponse> postDislikeNovel(@Header("Authorization") String token,
                                          @Field("novel_id") int novel_id);
 
Example #20
Source File: AppApi.java    From Pixiv-Shaft with MIT License 4 votes vote down vote up
@FormUrlEncoded
@POST("v1/illust/bookmark/delete")
Observable<NullResponse> postDislike(@Header("Authorization") String token,
                                     @Field("illust_id") int illust_id);
 
Example #21
Source File: AppApi.java    From Pixiv-Shaft with MIT License 4 votes vote down vote up
@FormUrlEncoded
@POST("v2/illust/bookmark/add")
Observable<NullResponse> postLike(@Header("Authorization") String token,
                                  @Field("illust_id") int illust_id,
                                  @Field("restrict") String restrict,
                                  @Field("tags[]") String... tags);
 
Example #22
Source File: TestHttpClient.java    From beihu-boot with Apache License 2.0 4 votes vote down vote up
@POST(value = "/app/statistics/buyQuantity")
Call<TestHttpRs> test(@Body TestHttpDto testHttpDto);
 
Example #23
Source File: AppApi.java    From Pixiv-Shaft with MIT License 4 votes vote down vote up
@FormUrlEncoded
@POST("v2/illust/bookmark/add")
Observable<NullResponse> postLike(@Header("Authorization") String token,
                                  @Field("illust_id") int illust_id,
                                  @Field("restrict") String restrict);
 
Example #24
Source File: AppApi.java    From Pixiv-Shaft with MIT License 4 votes vote down vote up
@FormUrlEncoded
@POST("v1/illust/comment/add")
Observable<CommentHolder> postComment(@Header("Authorization") String token,
                                      @Field("illust_id") int illust_id,
                                      @Field("comment") String comment,
                                      @Field("parent_comment_id") int parent_comment_id);
 
Example #25
Source File: AppApi.java    From Pixiv-Shaft with MIT License 4 votes vote down vote up
@FormUrlEncoded
@POST("v1/illust/comment/add")
Observable<CommentHolder> postComment(@Header("Authorization") String token,
                                      @Field("illust_id") int illust_id,
                                      @Field("comment") String comment);
 
Example #26
Source File: AppApi.java    From Pixiv-Shaft with MIT License 4 votes vote down vote up
@FormUrlEncoded
@POST("v1/user/follow/delete")
Observable<NullResponse> postUnFollow(@Header("Authorization") String token,
                                      @Field("user_id") int user_id);
 
Example #27
Source File: AppApi.java    From Pixiv-Shaft with MIT License 4 votes vote down vote up
@FormUrlEncoded
@POST("v1/user/follow/add")
Observable<NullResponse> postFollow(@Header("Authorization") String token,
                                    @Field("user_id") int user_id,
                                    @Field("restrict") String followType);
 
Example #28
Source File: SauceNaoApi.java    From Pixiv-Shaft with MIT License 4 votes vote down vote up
@Multipart
@POST("/search.php")
Observable<Response<ResponseBody>> query(@Part MultipartBody.Part part);
 
Example #29
Source File: IqdbApi.java    From Pixiv-Shaft with MIT License 4 votes vote down vote up
@Multipart
@POST("/")
Observable<Response<ResponseBody>> query(@Part MultipartBody.Part part);
 
Example #30
Source File: AppApi.java    From Pixiv-Shaft with MIT License 4 votes vote down vote up
@FormUrlEncoded
@POST("v2/novel/bookmark/add")
Observable<NullResponse> postLikeNovel(@Header("Authorization") String token,
                                       @Field("novel_id") int novel_id,
                                       @Field("restrict") String restrict);