package ac;

import ca.canadapost.core.data.model.CommonErrorResponseException;
import ca.canadapost.core.data.model.ResultWrapper;
import ca.canadapost.module.epostprofile.account.changepassword.api.IChangePasswordApi;
import g9.i0;
import g9.w;
import km.t;
import kotlin.jvm.internal.p0;
import kotlin.jvm.internal.v;
import or.u;

/* loaded from: classes4.dex */
public final class a {

    /* renamed from: ac.a$a, reason: collision with other inner class name */
    /* loaded from: classes4.dex */
    static final class C0014a extends v implements dn.l {

        /* renamed from: p, reason: collision with root package name */
        final /* synthetic */ t f306p;

        /* JADX WARN: 'super' call moved to the top of the method (can break code semantics) */
        C0014a(t tVar) {
            super(1);
            this.f306p = tVar;
        }

        @Override // dn.l
        /* renamed from: a, reason: merged with bridge method [inline-methods] */
        public final ResultWrapper.Error invoke(or.t response) {
            kotlin.jvm.internal.t.g(response, "response");
            return ha.g.a(response, this.f306p, p0.b(CommonErrorResponseException.class));
        }
    }

    public final IChangePasswordApi a(ha.c httpClientBuilderFactory, f9.a fireBaseAppCheckInterceptor, w tokenInjectInterceptor, jr.a loggingInterceptor, i0 twoSVHeaderInterceptor, t moshi) {
        kotlin.jvm.internal.t.g(httpClientBuilderFactory, "httpClientBuilderFactory");
        kotlin.jvm.internal.t.g(fireBaseAppCheckInterceptor, "fireBaseAppCheckInterceptor");
        kotlin.jvm.internal.t.g(tokenInjectInterceptor, "tokenInjectInterceptor");
        kotlin.jvm.internal.t.g(loggingInterceptor, "loggingInterceptor");
        kotlin.jvm.internal.t.g(twoSVHeaderInterceptor, "twoSVHeaderInterceptor");
        kotlin.jvm.internal.t.g(moshi, "moshi");
        Object b10 = new u.b().c("https://www.canadapost-postescanada.ca/mgw/").b(qr.a.g(moshi)).g(httpClientBuilderFactory.a().a(fireBaseAppCheckInterceptor).a(tokenInjectInterceptor).a(twoSVHeaderInterceptor).a(loggingInterceptor).d()).a(new ha.f(new C0014a(moshi))).e().b(IChangePasswordApi.class);
        kotlin.jvm.internal.t.f(b10, "create(...)");
        return (IChangePasswordApi) b10;
    }
}
