UNPKG

@maienm/pulumi-prowlarr

Version:

A Pulumi package for creating and managing Prowlarr resources. Based on terraform-provider-prowlarr: version v2.3.0

254 lines 16.9 kB
"use strict"; // *** WARNING: this file was generated by the Pulumi Terraform Bridge (tfgen) Tool. *** // *** Do not edit by hand unless you're certain you know what you are doing! *** Object.defineProperty(exports, "__esModule", { value: true }); exports.Notification = void 0; const pulumi = require("@pulumi/pulumi"); const utilities = require("../utilities"); /** * <!-- subcategory:Notifications -->Generic Notification resource. When possible use a specific resource instead. * For more information refer to [Notification](https://wiki.servarr.com/prowlarr/settings#connect). * * ## Example Usage * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as prowlarr from "@maienm/pulumi-prowlarr"; * * const example = new prowlarr.notifications.Notification("example", { * configContract: "CustomScriptSettings", * implementation: "CustomScript", * includeHealthWarnings: false, * onApplicationUpdate: false, * onHealthIssue: false, * path: "/scripts/prowlarr.sh", * }); * ``` * * ## Import * * import using the API/UI ID * * ```sh * $ pulumi import prowlarr:Notifications/notification:Notification example 1 * ``` */ class Notification extends pulumi.CustomResource { /** * Get an existing Notification 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 Notification(name, state, Object.assign(Object.assign({}, opts), { id: id })); } /** * Returns true if the given object is an instance of Notification. 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'] === Notification.__pulumiType; } constructor(name, argsOrState, opts) { let resourceInputs = {}; opts = opts || {}; if (opts.id) { const state = argsOrState; resourceInputs["accessToken"] = state ? state.accessToken : undefined; resourceInputs["accessTokenSecret"] = state ? state.accessTokenSecret : undefined; resourceInputs["alwaysUpdate"] = state ? state.alwaysUpdate : undefined; resourceInputs["apiKey"] = state ? state.apiKey : undefined; resourceInputs["appToken"] = state ? state.appToken : undefined; resourceInputs["arguments"] = state ? state.arguments : undefined; resourceInputs["authPassword"] = state ? state.authPassword : undefined; resourceInputs["authToken"] = state ? state.authToken : undefined; resourceInputs["authUser"] = state ? state.authUser : undefined; resourceInputs["authUsername"] = state ? state.authUsername : undefined; resourceInputs["author"] = state ? state.author : undefined; resourceInputs["avatar"] = state ? state.avatar : undefined; resourceInputs["baseUrl"] = state ? state.baseUrl : undefined; resourceInputs["bccs"] = state ? state.bccs : undefined; resourceInputs["botToken"] = state ? state.botToken : undefined; resourceInputs["ccs"] = state ? state.ccs : undefined; resourceInputs["channel"] = state ? state.channel : undefined; resourceInputs["channelTags"] = state ? state.channelTags : undefined; resourceInputs["chatId"] = state ? state.chatId : undefined; resourceInputs["cleanLibrary"] = state ? state.cleanLibrary : undefined; resourceInputs["clickUrl"] = state ? state.clickUrl : undefined; resourceInputs["configContract"] = state ? state.configContract : undefined; resourceInputs["configurationKey"] = state ? state.configurationKey : undefined; resourceInputs["consumerKey"] = state ? state.consumerKey : undefined; resourceInputs["consumerSecret"] = state ? state.consumerSecret : undefined; resourceInputs["deviceIds"] = state ? state.deviceIds : undefined; resourceInputs["deviceNames"] = state ? state.deviceNames : undefined; resourceInputs["devices"] = state ? state.devices : undefined; resourceInputs["directMessage"] = state ? state.directMessage : undefined; resourceInputs["displayTime"] = state ? state.displayTime : undefined; resourceInputs["event"] = state ? state.event : undefined; resourceInputs["expire"] = state ? state.expire : undefined; resourceInputs["expires"] = state ? state.expires : undefined; resourceInputs["fieldTags"] = state ? state.fieldTags : undefined; resourceInputs["from"] = state ? state.from : undefined; resourceInputs["grabFields"] = state ? state.grabFields : undefined; resourceInputs["host"] = state ? state.host : undefined; resourceInputs["icon"] = state ? state.icon : undefined; resourceInputs["implementation"] = state ? state.implementation : undefined; resourceInputs["includeHealthWarnings"] = state ? state.includeHealthWarnings : undefined; resourceInputs["includeManualGrabs"] = state ? state.includeManualGrabs : undefined; resourceInputs["instanceName"] = state ? state.instanceName : undefined; resourceInputs["key"] = state ? state.key : undefined; resourceInputs["mapFrom"] = state ? state.mapFrom : undefined; resourceInputs["mapTo"] = state ? state.mapTo : undefined; resourceInputs["mention"] = state ? state.mention : undefined; resourceInputs["method"] = state ? state.method : undefined; resourceInputs["name"] = state ? state.name : undefined; resourceInputs["notificationType"] = state ? state.notificationType : undefined; resourceInputs["notify"] = state ? state.notify : undefined; resourceInputs["onApplicationUpdate"] = state ? state.onApplicationUpdate : undefined; resourceInputs["onGrab"] = state ? state.onGrab : undefined; resourceInputs["onHealthIssue"] = state ? state.onHealthIssue : undefined; resourceInputs["onHealthRestored"] = state ? state.onHealthRestored : undefined; resourceInputs["password"] = state ? state.password : undefined; resourceInputs["path"] = state ? state.path : undefined; resourceInputs["port"] = state ? state.port : undefined; resourceInputs["priority"] = state ? state.priority : undefined; resourceInputs["receiverId"] = state ? state.receiverId : undefined; resourceInputs["recipients"] = state ? state.recipients : undefined; resourceInputs["refreshToken"] = state ? state.refreshToken : undefined; resourceInputs["retry"] = state ? state.retry : undefined; resourceInputs["sendSilently"] = state ? state.sendSilently : undefined; resourceInputs["senderDomain"] = state ? state.senderDomain : undefined; resourceInputs["senderId"] = state ? state.senderId : undefined; resourceInputs["senderNumber"] = state ? state.senderNumber : undefined; resourceInputs["server"] = state ? state.server : undefined; resourceInputs["serverUrl"] = state ? state.serverUrl : undefined; resourceInputs["signIn"] = state ? state.signIn : undefined; resourceInputs["sound"] = state ? state.sound : undefined; resourceInputs["statelessUrls"] = state ? state.statelessUrls : undefined; resourceInputs["tags"] = state ? state.tags : undefined; resourceInputs["token"] = state ? state.token : undefined; resourceInputs["topicId"] = state ? state.topicId : undefined; resourceInputs["topics"] = state ? state.topics : undefined; resourceInputs["tos"] = state ? state.tos : undefined; resourceInputs["updateLibrary"] = state ? state.updateLibrary : undefined; resourceInputs["url"] = state ? state.url : undefined; resourceInputs["useEncryption"] = state ? state.useEncryption : undefined; resourceInputs["useEuEndpoint"] = state ? state.useEuEndpoint : undefined; resourceInputs["useSsl"] = state ? state.useSsl : undefined; resourceInputs["userKey"] = state ? state.userKey : undefined; resourceInputs["username"] = state ? state.username : undefined; resourceInputs["webHookUrl"] = state ? state.webHookUrl : undefined; } else { const args = argsOrState; if ((!args || args.configContract === undefined) && !opts.urn) { throw new Error("Missing required property 'configContract'"); } if ((!args || args.implementation === undefined) && !opts.urn) { throw new Error("Missing required property 'implementation'"); } if ((!args || args.includeHealthWarnings === undefined) && !opts.urn) { throw new Error("Missing required property 'includeHealthWarnings'"); } resourceInputs["accessToken"] = args ? args.accessToken : undefined; resourceInputs["accessTokenSecret"] = args ? args.accessTokenSecret : undefined; resourceInputs["alwaysUpdate"] = args ? args.alwaysUpdate : undefined; resourceInputs["apiKey"] = args ? args.apiKey : undefined; resourceInputs["appToken"] = args ? args.appToken : undefined; resourceInputs["arguments"] = args ? args.arguments : undefined; resourceInputs["authPassword"] = (args === null || args === void 0 ? void 0 : args.authPassword) ? pulumi.secret(args.authPassword) : undefined; resourceInputs["authToken"] = args ? args.authToken : undefined; resourceInputs["authUser"] = args ? args.authUser : undefined; resourceInputs["authUsername"] = args ? args.authUsername : undefined; resourceInputs["author"] = args ? args.author : undefined; resourceInputs["avatar"] = args ? args.avatar : undefined; resourceInputs["baseUrl"] = args ? args.baseUrl : undefined; resourceInputs["bccs"] = args ? args.bccs : undefined; resourceInputs["botToken"] = args ? args.botToken : undefined; resourceInputs["ccs"] = args ? args.ccs : undefined; resourceInputs["channel"] = args ? args.channel : undefined; resourceInputs["channelTags"] = args ? args.channelTags : undefined; resourceInputs["chatId"] = args ? args.chatId : undefined; resourceInputs["cleanLibrary"] = args ? args.cleanLibrary : undefined; resourceInputs["clickUrl"] = args ? args.clickUrl : undefined; resourceInputs["configContract"] = args ? args.configContract : undefined; resourceInputs["configurationKey"] = (args === null || args === void 0 ? void 0 : args.configurationKey) ? pulumi.secret(args.configurationKey) : undefined; resourceInputs["consumerKey"] = args ? args.consumerKey : undefined; resourceInputs["consumerSecret"] = args ? args.consumerSecret : undefined; resourceInputs["deviceIds"] = args ? args.deviceIds : undefined; resourceInputs["deviceNames"] = args ? args.deviceNames : undefined; resourceInputs["devices"] = args ? args.devices : undefined; resourceInputs["directMessage"] = args ? args.directMessage : undefined; resourceInputs["displayTime"] = args ? args.displayTime : undefined; resourceInputs["event"] = args ? args.event : undefined; resourceInputs["expire"] = args ? args.expire : undefined; resourceInputs["expires"] = args ? args.expires : undefined; resourceInputs["fieldTags"] = args ? args.fieldTags : undefined; resourceInputs["from"] = args ? args.from : undefined; resourceInputs["grabFields"] = args ? args.grabFields : undefined; resourceInputs["host"] = args ? args.host : undefined; resourceInputs["icon"] = args ? args.icon : undefined; resourceInputs["implementation"] = args ? args.implementation : undefined; resourceInputs["includeHealthWarnings"] = args ? args.includeHealthWarnings : undefined; resourceInputs["includeManualGrabs"] = args ? args.includeManualGrabs : undefined; resourceInputs["instanceName"] = args ? args.instanceName : undefined; resourceInputs["key"] = args ? args.key : undefined; resourceInputs["mapFrom"] = args ? args.mapFrom : undefined; resourceInputs["mapTo"] = args ? args.mapTo : undefined; resourceInputs["mention"] = args ? args.mention : undefined; resourceInputs["method"] = args ? args.method : undefined; resourceInputs["name"] = args ? args.name : undefined; resourceInputs["notificationType"] = args ? args.notificationType : undefined; resourceInputs["notify"] = args ? args.notify : undefined; resourceInputs["onApplicationUpdate"] = args ? args.onApplicationUpdate : undefined; resourceInputs["onGrab"] = args ? args.onGrab : undefined; resourceInputs["onHealthIssue"] = args ? args.onHealthIssue : undefined; resourceInputs["onHealthRestored"] = args ? args.onHealthRestored : undefined; resourceInputs["password"] = (args === null || args === void 0 ? void 0 : args.password) ? pulumi.secret(args.password) : undefined; resourceInputs["path"] = args ? args.path : undefined; resourceInputs["port"] = args ? args.port : undefined; resourceInputs["priority"] = args ? args.priority : undefined; resourceInputs["receiverId"] = args ? args.receiverId : undefined; resourceInputs["recipients"] = args ? args.recipients : undefined; resourceInputs["refreshToken"] = args ? args.refreshToken : undefined; resourceInputs["retry"] = args ? args.retry : undefined; resourceInputs["sendSilently"] = args ? args.sendSilently : undefined; resourceInputs["senderDomain"] = args ? args.senderDomain : undefined; resourceInputs["senderId"] = args ? args.senderId : undefined; resourceInputs["senderNumber"] = (args === null || args === void 0 ? void 0 : args.senderNumber) ? pulumi.secret(args.senderNumber) : undefined; resourceInputs["server"] = args ? args.server : undefined; resourceInputs["serverUrl"] = args ? args.serverUrl : undefined; resourceInputs["signIn"] = args ? args.signIn : undefined; resourceInputs["sound"] = args ? args.sound : undefined; resourceInputs["statelessUrls"] = args ? args.statelessUrls : undefined; resourceInputs["tags"] = args ? args.tags : undefined; resourceInputs["token"] = args ? args.token : undefined; resourceInputs["topicId"] = args ? args.topicId : undefined; resourceInputs["topics"] = args ? args.topics : undefined; resourceInputs["tos"] = args ? args.tos : undefined; resourceInputs["updateLibrary"] = args ? args.updateLibrary : undefined; resourceInputs["url"] = args ? args.url : undefined; resourceInputs["useEncryption"] = args ? args.useEncryption : undefined; resourceInputs["useEuEndpoint"] = args ? args.useEuEndpoint : undefined; resourceInputs["useSsl"] = args ? args.useSsl : undefined; resourceInputs["userKey"] = args ? args.userKey : undefined; resourceInputs["username"] = args ? args.username : undefined; resourceInputs["webHookUrl"] = args ? args.webHookUrl : undefined; } opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts); const secretOpts = { additionalSecretOutputs: ["authPassword", "configurationKey", "password", "senderNumber"] }; opts = pulumi.mergeOptions(opts, secretOpts); super(Notification.__pulumiType, name, resourceInputs, opts); } } exports.Notification = Notification; /** @internal */ Notification.__pulumiType = 'prowlarr:Notifications/notification:Notification'; //# sourceMappingURL=notification.js.map