package cz.moneta.test.dsl.util.task.cagw.api;

import cz.moneta.test.dsl.Harness;
import cz.moneta.test.dsl.cagw.api.cbl.psd.aisp.my.accounts.Account;
import cz.moneta.test.dsl.cagw.api.cbl.psd.aisp.my.accounts.AccountsWithParams;

import java.util.function.Function;

public class AccountsTasks {

    private final Harness harness;

    public AccountsTasks(Harness harness) {
        this.harness = harness;
    }

    public Function<Account, Account> setRequestValues(String authToken) {
        return start -> start.withAuthorizationBearer("Bearer " + authToken);
    }

    public Function<AccountsWithParams, AccountsWithParams> setRequestValuesAccountsWithParams(String authToken,
                                                                                               String sort,
                                                                                               String order) {
        return start -> start.withAuthorizationBearer("Bearer " + authToken)
                .sort(sort)
                .order(order);
    }

}