@Body
– Sends Java objects as request body.
@Field
– send data as form-urlencoded. This requires a @FormUrlEncoded
annotation attached with the method.
The @Field
parameter works only with a POST. @Field
requires a mandatory parameter. In cases when @Field
is optional, we can use @Query
instead and pass a null value.