// *** WARNING: this file was generated by pulumi-java-gen. ***
// *** Do not edit by hand unless you're certain you know what you are doing! ***

package com.pulumi.azure.apimanagement.inputs;

import com.pulumi.azure.apimanagement.inputs.BackendCredentialsAuthorizationArgs;
import com.pulumi.core.Output;
import com.pulumi.core.annotations.Import;
import java.lang.String;
import java.util.List;
import java.util.Map;
import java.util.Objects;
import java.util.Optional;
import javax.annotation.Nullable;


public final class BackendCredentialsArgs extends com.pulumi.resources.ResourceArgs {

    public static final BackendCredentialsArgs Empty = new BackendCredentialsArgs();

    /**
     * An `authorization` block as defined below.
     * 
     */
    @Import(name="authorization")
    private @Nullable Output<BackendCredentialsAuthorizationArgs> authorization;

    /**
     * @return An `authorization` block as defined below.
     * 
     */
    public Optional<Output<BackendCredentialsAuthorizationArgs>> authorization() {
        return Optional.ofNullable(this.authorization);
    }

    /**
     * A list of client certificate thumbprints to present to the backend host. The certificates must exist within the API Management Service.
     * 
     */
    @Import(name="certificates")
    private @Nullable Output<List<String>> certificates;

    /**
     * @return A list of client certificate thumbprints to present to the backend host. The certificates must exist within the API Management Service.
     * 
     */
    public Optional<Output<List<String>>> certificates() {
        return Optional.ofNullable(this.certificates);
    }

    /**
     * A mapping of header parameters to pass to the backend host. The keys are the header names and the values are a comma separated string of header values. This is converted to a list before being passed to the API.
     * 
     */
    @Import(name="header")
    private @Nullable Output<Map<String,String>> header;

    /**
     * @return A mapping of header parameters to pass to the backend host. The keys are the header names and the values are a comma separated string of header values. This is converted to a list before being passed to the API.
     * 
     */
    public Optional<Output<Map<String,String>>> header() {
        return Optional.ofNullable(this.header);
    }

    /**
     * A mapping of query parameters to pass to the backend host. The keys are the query names and the values are a comma separated string of query values. This is converted to a list before being passed to the API.
     * 
     */
    @Import(name="query")
    private @Nullable Output<Map<String,String>> query;

    /**
     * @return A mapping of query parameters to pass to the backend host. The keys are the query names and the values are a comma separated string of query values. This is converted to a list before being passed to the API.
     * 
     */
    public Optional<Output<Map<String,String>>> query() {
        return Optional.ofNullable(this.query);
    }

    private BackendCredentialsArgs() {}

    private BackendCredentialsArgs(BackendCredentialsArgs $) {
        this.authorization = $.authorization;
        this.certificates = $.certificates;
        this.header = $.header;
        this.query = $.query;
    }

    public static Builder builder() {
        return new Builder();
    }
    public static Builder builder(BackendCredentialsArgs defaults) {
        return new Builder(defaults);
    }

    public static final class Builder {
        private BackendCredentialsArgs $;

        public Builder() {
            $ = new BackendCredentialsArgs();
        }

        public Builder(BackendCredentialsArgs defaults) {
            $ = new BackendCredentialsArgs(Objects.requireNonNull(defaults));
        }

        /**
         * @param authorization An `authorization` block as defined below.
         * 
         * @return builder
         * 
         */
        public Builder authorization(@Nullable Output<BackendCredentialsAuthorizationArgs> authorization) {
            $.authorization = authorization;
            return this;
        }

        /**
         * @param authorization An `authorization` block as defined below.
         * 
         * @return builder
         * 
         */
        public Builder authorization(BackendCredentialsAuthorizationArgs authorization) {
            return authorization(Output.of(authorization));
        }

        /**
         * @param certificates A list of client certificate thumbprints to present to the backend host. The certificates must exist within the API Management Service.
         * 
         * @return builder
         * 
         */
        public Builder certificates(@Nullable Output<List<String>> certificates) {
            $.certificates = certificates;
            return this;
        }

        /**
         * @param certificates A list of client certificate thumbprints to present to the backend host. The certificates must exist within the API Management Service.
         * 
         * @return builder
         * 
         */
        public Builder certificates(List<String> certificates) {
            return certificates(Output.of(certificates));
        }

        /**
         * @param certificates A list of client certificate thumbprints to present to the backend host. The certificates must exist within the API Management Service.
         * 
         * @return builder
         * 
         */
        public Builder certificates(String... certificates) {
            return certificates(List.of(certificates));
        }

        /**
         * @param header A mapping of header parameters to pass to the backend host. The keys are the header names and the values are a comma separated string of header values. This is converted to a list before being passed to the API.
         * 
         * @return builder
         * 
         */
        public Builder header(@Nullable Output<Map<String,String>> header) {
            $.header = header;
            return this;
        }

        /**
         * @param header A mapping of header parameters to pass to the backend host. The keys are the header names and the values are a comma separated string of header values. This is converted to a list before being passed to the API.
         * 
         * @return builder
         * 
         */
        public Builder header(Map<String,String> header) {
            return header(Output.of(header));
        }

        /**
         * @param query A mapping of query parameters to pass to the backend host. The keys are the query names and the values are a comma separated string of query values. This is converted to a list before being passed to the API.
         * 
         * @return builder
         * 
         */
        public Builder query(@Nullable Output<Map<String,String>> query) {
            $.query = query;
            return this;
        }

        /**
         * @param query A mapping of query parameters to pass to the backend host. The keys are the query names and the values are a comma separated string of query values. This is converted to a list before being passed to the API.
         * 
         * @return builder
         * 
         */
        public Builder query(Map<String,String> query) {
            return query(Output.of(query));
        }

        public BackendCredentialsArgs build() {
            return $;
        }
    }

}
