"use strict";
// *** WARNING: this file was generated by pulumi-language-nodejs. ***
// *** Do not edit by hand unless you're certain you know what you are doing! ***
Object.defineProperty(exports, "__esModule", { value: true });
exports.AppleApp = void 0;
const pulumi = require("@pulumi/pulumi");
const utilities = require("../utilities");
/**
 * A Google Cloud Firebase Apple application instance
 *
 * To get more information about AppleApp, see:
 *
 * * [API documentation](https://firebase.google.com/docs/reference/firebase-management/rest/v1beta1/projects.iosApps)
 * * How-to Guides
 *     * [Official Documentation](https://firebase.google.com/docs/ios/setup)
 *
 * ## Example Usage
 *
 * ### Firebase Apple App Basic
 *
 * ```typescript
 * import * as pulumi from "@pulumi/pulumi";
 * import * as gcp from "@pulumi/gcp";
 *
 * const _default = new gcp.firebase.AppleApp("default", {
 *     project: "my-project-name",
 *     displayName: "Display Name Basic",
 *     bundleId: "apple.app.12345",
 * });
 * ```
 * ### Firebase Apple App Full
 *
 * ```typescript
 * import * as pulumi from "@pulumi/pulumi";
 * import * as gcp from "@pulumi/gcp";
 *
 * const apple = new gcp.projects.ApiKey("apple", {
 *     name: "api-key",
 *     displayName: "Display Name Full",
 *     project: "my-project-name",
 *     restrictions: {
 *         iosKeyRestrictions: {
 *             allowedBundleIds: ["apple.app.12345"],
 *         },
 *     },
 * });
 * const full = new gcp.firebase.AppleApp("full", {
 *     project: "my-project-name",
 *     displayName: "Display Name Full",
 *     bundleId: "apple.app.12345",
 *     appStoreId: "12345",
 *     teamId: "9987654321",
 *     apiKeyId: apple.uid,
 * });
 * ```
 *
 * ## Import
 *
 * AppleApp can be imported using any of these accepted formats:
 *
 * * `{{project}} projects/{{project}}/iosApps/{{app_id}}`
 *
 * * `projects/{{project}}/iosApps/{{app_id}}`
 *
 * * `{{project}}/{{project}}/{{app_id}}`
 *
 * * `iosApps/{{app_id}}`
 *
 * * `{{app_id}}`
 *
 * When using the `pulumi import` command, AppleApp can be imported using one of the formats above. For example:
 *
 * ```sh
 * $ pulumi import gcp:firebase/appleApp:AppleApp default "{{project}} projects/{{project}}/iosApps/{{app_id}}"
 * ```
 *
 * ```sh
 * $ pulumi import gcp:firebase/appleApp:AppleApp default projects/{{project}}/iosApps/{{app_id}}
 * ```
 *
 * ```sh
 * $ pulumi import gcp:firebase/appleApp:AppleApp default {{project}}/{{project}}/{{app_id}}
 * ```
 *
 * ```sh
 * $ pulumi import gcp:firebase/appleApp:AppleApp default iosApps/{{app_id}}
 * ```
 *
 * ```sh
 * $ pulumi import gcp:firebase/appleApp:AppleApp default {{app_id}}
 * ```
 */
class AppleApp extends pulumi.CustomResource {
    /**
     * Get an existing AppleApp resource's state with the given name, ID, and optional extra
     * properties used to qualify the lookup.
     *
     * @param name The _unique_ name of the resulting resource.
     * @param id The _unique_ provider ID of the resource to lookup.
     * @param state Any extra arguments used during the lookup.
     * @param opts Optional settings to control the behavior of the CustomResource.
     */
    static get(name, id, state, opts) {
        return new AppleApp(name, state, { ...opts, id: id });
    }
    /**
     * Returns true if the given object is an instance of AppleApp.  This is designed to work even
     * when multiple copies of the Pulumi SDK have been loaded into the same process.
     */
    static isInstance(obj) {
        if (obj === undefined || obj === null) {
            return false;
        }
        return obj['__pulumiType'] === AppleApp.__pulumiType;
    }
    constructor(name, argsOrState, opts) {
        let resourceInputs = {};
        opts = opts || {};
        if (opts.id) {
            const state = argsOrState;
            resourceInputs["apiKeyId"] = state?.apiKeyId;
            resourceInputs["appId"] = state?.appId;
            resourceInputs["appStoreId"] = state?.appStoreId;
            resourceInputs["bundleId"] = state?.bundleId;
            resourceInputs["deletionPolicy"] = state?.deletionPolicy;
            resourceInputs["displayName"] = state?.displayName;
            resourceInputs["name"] = state?.name;
            resourceInputs["project"] = state?.project;
            resourceInputs["teamId"] = state?.teamId;
        }
        else {
            const args = argsOrState;
            if (args?.bundleId === undefined && !opts.urn) {
                throw new Error("Missing required property 'bundleId'");
            }
            if (args?.displayName === undefined && !opts.urn) {
                throw new Error("Missing required property 'displayName'");
            }
            resourceInputs["apiKeyId"] = args?.apiKeyId;
            resourceInputs["appStoreId"] = args?.appStoreId;
            resourceInputs["bundleId"] = args?.bundleId;
            resourceInputs["deletionPolicy"] = args?.deletionPolicy;
            resourceInputs["displayName"] = args?.displayName;
            resourceInputs["project"] = args?.project;
            resourceInputs["teamId"] = args?.teamId;
            resourceInputs["appId"] = undefined /*out*/;
            resourceInputs["name"] = undefined /*out*/;
        }
        opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts);
        super(AppleApp.__pulumiType, name, resourceInputs, opts);
    }
}
exports.AppleApp = AppleApp;
/** @internal */
AppleApp.__pulumiType = 'gcp:firebase/appleApp:AppleApp';
//# sourceMappingURL=appleApp.js.map