io.contek.invoker.hbdmlinear.api.rest.user.PostSwapCrossAccountInfo Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of invoker-hbdmlinear-api Show documentation
Show all versions of invoker-hbdmlinear-api Show documentation
Huobi Derivative Linear Java API
package io.contek.invoker.hbdmlinear.api.rest.user;
import com.google.common.collect.ImmutableList;
import io.contek.invoker.commons.actor.IActor;
import io.contek.invoker.commons.actor.ratelimit.TypedPermitRequest;
import io.contek.invoker.commons.rest.RestContext;
import io.contek.invoker.commons.rest.RestParams;
import io.contek.invoker.hbdmlinear.api.common._CrossAccountInfo;
import io.contek.invoker.hbdmlinear.api.rest.common.RestDataResponse;
import javax.annotation.concurrent.NotThreadSafe;
import java.util.List;
import static io.contek.invoker.hbdmlinear.api.ApiFactory.RateLimits.ONE_API_KEY_REST_PRIVATE_READ_REQUEST;
@NotThreadSafe
public final class PostSwapCrossAccountInfo
extends UserRestRequest {
private String margin_account;
PostSwapCrossAccountInfo(IActor actor, RestContext context) {
super(actor, context);
}
public PostSwapCrossAccountInfo setMarginAccount(String margin_account) {
this.margin_account = margin_account;
return this;
}
@Override
protected Class getResponseType() {
return Response.class;
}
@Override
protected String getEndpointPath() {
return "/linear-swap-api/v1/swap_cross_account_info";
}
@Override
protected RestParams getParams() {
RestParams.Builder builder = RestParams.newBuilder();
if (margin_account != null) {
builder.add("margin_account", margin_account);
}
return builder.build();
}
@Override
protected ImmutableList getRequiredQuotas() {
return ONE_API_KEY_REST_PRIVATE_READ_REQUEST;
}
@NotThreadSafe
public static final class Response extends RestDataResponse> {}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy