com.pulumi.gitlab.kotlin.ServiceMicrosoftTeamsArgs.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of pulumi-gitlab-kotlin Show documentation
Show all versions of pulumi-gitlab-kotlin Show documentation
Build cloud applications and infrastructure by combining the safety and reliability of infrastructure as code with the power of the Kotlin programming language.
@file:Suppress("NAME_SHADOWING", "DEPRECATION")
package com.pulumi.gitlab.kotlin
import com.pulumi.core.Output
import com.pulumi.core.Output.of
import com.pulumi.gitlab.ServiceMicrosoftTeamsArgs.builder
import com.pulumi.kotlin.ConvertibleToJava
import com.pulumi.kotlin.PulumiTagMarker
import kotlin.Boolean
import kotlin.String
import kotlin.Suppress
import kotlin.jvm.JvmName
/**
* The `gitlab.ServiceMicrosoftTeams` resource allows to manage the lifecycle of a project integration with Microsoft Teams.
* > This resource is deprecated. use `gitlab.IntegrationMicrosoftTeams`instead!
* **Upstream API**: [GitLab REST API docs](https://docs.gitlab.com/ee/api/integrations.html#microsoft-teams)
* ## Example Usage
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as gitlab from "@pulumi/gitlab";
* const awesomeProject = new gitlab.Project("awesome_project", {
* name: "awesome_project",
* description: "My awesome project.",
* visibilityLevel: "public",
* });
* const teams = new gitlab.ServiceMicrosoftTeams("teams", {
* project: awesomeProject.id,
* webhook: "https://testurl.com/?token=XYZ",
* pushEvents: true,
* });
* ```
* ```python
* import pulumi
* import pulumi_gitlab as gitlab
* awesome_project = gitlab.Project("awesome_project",
* name="awesome_project",
* description="My awesome project.",
* visibility_level="public")
* teams = gitlab.ServiceMicrosoftTeams("teams",
* project=awesome_project.id,
* webhook="https://testurl.com/?token=XYZ",
* push_events=True)
* ```
* ```csharp
* using System.Collections.Generic;
* using System.Linq;
* using Pulumi;
* using GitLab = Pulumi.GitLab;
* return await Deployment.RunAsync(() =>
* {
* var awesomeProject = new GitLab.Project("awesome_project", new()
* {
* Name = "awesome_project",
* Description = "My awesome project.",
* VisibilityLevel = "public",
* });
* var teams = new GitLab.ServiceMicrosoftTeams("teams", new()
* {
* Project = awesomeProject.Id,
* Webhook = "https://testurl.com/?token=XYZ",
* PushEvents = true,
* });
* });
* ```
* ```go
* package main
* import (
* "github.com/pulumi/pulumi-gitlab/sdk/v8/go/gitlab"
* "github.com/pulumi/pulumi/sdk/v3/go/pulumi"
* )
* func main() {
* pulumi.Run(func(ctx *pulumi.Context) error {
* awesomeProject, err := gitlab.NewProject(ctx, "awesome_project", &gitlab.ProjectArgs{
* Name: pulumi.String("awesome_project"),
* Description: pulumi.String("My awesome project."),
* VisibilityLevel: pulumi.String("public"),
* })
* if err != nil {
* return err
* }
* _, err = gitlab.NewServiceMicrosoftTeams(ctx, "teams", &gitlab.ServiceMicrosoftTeamsArgs{
* Project: awesomeProject.ID(),
* Webhook: pulumi.String("https://testurl.com/?token=XYZ"),
* PushEvents: pulumi.Bool(true),
* })
* if err != nil {
* return err
* }
* return nil
* })
* }
* ```
* ```java
* package generated_program;
* import com.pulumi.Context;
* import com.pulumi.Pulumi;
* import com.pulumi.core.Output;
* import com.pulumi.gitlab.Project;
* import com.pulumi.gitlab.ProjectArgs;
* import com.pulumi.gitlab.ServiceMicrosoftTeams;
* import com.pulumi.gitlab.ServiceMicrosoftTeamsArgs;
* import java.util.List;
* import java.util.ArrayList;
* import java.util.Map;
* import java.io.File;
* import java.nio.file.Files;
* import java.nio.file.Paths;
* public class App {
* public static void main(String[] args) {
* Pulumi.run(App::stack);
* }
* public static void stack(Context ctx) {
* var awesomeProject = new Project("awesomeProject", ProjectArgs.builder()
* .name("awesome_project")
* .description("My awesome project.")
* .visibilityLevel("public")
* .build());
* var teams = new ServiceMicrosoftTeams("teams", ServiceMicrosoftTeamsArgs.builder()
* .project(awesomeProject.id())
* .webhook("https://testurl.com/?token=XYZ")
* .pushEvents(true)
* .build());
* }
* }
* ```
* ```yaml
* resources:
* awesomeProject:
* type: gitlab:Project
* name: awesome_project
* properties:
* name: awesome_project
* description: My awesome project.
* visibilityLevel: public
* teams:
* type: gitlab:ServiceMicrosoftTeams
* properties:
* project: ${awesomeProject.id}
* webhook: https://testurl.com/?token=XYZ
* pushEvents: true
* ```
*
* ## Import
* You can import a gitlab_service_microsoft_teams state using the project ID, e.g.
* ```sh
* $ pulumi import gitlab:index/serviceMicrosoftTeams:ServiceMicrosoftTeams teams 1
* ```
* @property branchesToBeNotified Branches to send notifications for. Valid options are “all”, “default”, “protected”, and “default*and*protected”. The default value is “default”
* @property confidentialIssuesEvents Enable notifications for confidential issue events
* @property confidentialNoteEvents Enable notifications for confidential note events
* @property issuesEvents Enable notifications for issue events
* @property mergeRequestsEvents Enable notifications for merge request events
* @property noteEvents Enable notifications for note events
* @property notifyOnlyBrokenPipelines Send notifications for broken pipelines
* @property pipelineEvents Enable notifications for pipeline events
* @property project ID of the project you want to activate integration on.
* @property pushEvents Enable notifications for push events
* @property tagPushEvents Enable notifications for tag push events
* @property webhook The Microsoft Teams webhook (Example, https://outlook.office.com/webhook/...). This value cannot be imported.
* @property wikiPageEvents Enable notifications for wiki page events
*/
public data class ServiceMicrosoftTeamsArgs(
public val branchesToBeNotified: Output? = null,
public val confidentialIssuesEvents: Output? = null,
public val confidentialNoteEvents: Output? = null,
public val issuesEvents: Output? = null,
public val mergeRequestsEvents: Output? = null,
public val noteEvents: Output? = null,
public val notifyOnlyBrokenPipelines: Output? = null,
public val pipelineEvents: Output? = null,
public val project: Output? = null,
public val pushEvents: Output? = null,
public val tagPushEvents: Output? = null,
public val webhook: Output? = null,
public val wikiPageEvents: Output? = null,
) : ConvertibleToJava {
override fun toJava(): com.pulumi.gitlab.ServiceMicrosoftTeamsArgs =
com.pulumi.gitlab.ServiceMicrosoftTeamsArgs.builder()
.branchesToBeNotified(branchesToBeNotified?.applyValue({ args0 -> args0 }))
.confidentialIssuesEvents(confidentialIssuesEvents?.applyValue({ args0 -> args0 }))
.confidentialNoteEvents(confidentialNoteEvents?.applyValue({ args0 -> args0 }))
.issuesEvents(issuesEvents?.applyValue({ args0 -> args0 }))
.mergeRequestsEvents(mergeRequestsEvents?.applyValue({ args0 -> args0 }))
.noteEvents(noteEvents?.applyValue({ args0 -> args0 }))
.notifyOnlyBrokenPipelines(notifyOnlyBrokenPipelines?.applyValue({ args0 -> args0 }))
.pipelineEvents(pipelineEvents?.applyValue({ args0 -> args0 }))
.project(project?.applyValue({ args0 -> args0 }))
.pushEvents(pushEvents?.applyValue({ args0 -> args0 }))
.tagPushEvents(tagPushEvents?.applyValue({ args0 -> args0 }))
.webhook(webhook?.applyValue({ args0 -> args0 }))
.wikiPageEvents(wikiPageEvents?.applyValue({ args0 -> args0 })).build()
}
/**
* Builder for [ServiceMicrosoftTeamsArgs].
*/
@PulumiTagMarker
public class ServiceMicrosoftTeamsArgsBuilder internal constructor() {
private var branchesToBeNotified: Output? = null
private var confidentialIssuesEvents: Output? = null
private var confidentialNoteEvents: Output? = null
private var issuesEvents: Output? = null
private var mergeRequestsEvents: Output? = null
private var noteEvents: Output? = null
private var notifyOnlyBrokenPipelines: Output? = null
private var pipelineEvents: Output? = null
private var project: Output? = null
private var pushEvents: Output? = null
private var tagPushEvents: Output? = null
private var webhook: Output? = null
private var wikiPageEvents: Output? = null
/**
* @param value Branches to send notifications for. Valid options are “all”, “default”, “protected”, and “default*and*protected”. The default value is “default”
*/
@JvmName("hbwrgxonevmibuhb")
public suspend fun branchesToBeNotified(`value`: Output) {
this.branchesToBeNotified = value
}
/**
* @param value Enable notifications for confidential issue events
*/
@JvmName("lsngqxybcrahfjsd")
public suspend fun confidentialIssuesEvents(`value`: Output) {
this.confidentialIssuesEvents = value
}
/**
* @param value Enable notifications for confidential note events
*/
@JvmName("gthaljdvosinrmox")
public suspend fun confidentialNoteEvents(`value`: Output) {
this.confidentialNoteEvents = value
}
/**
* @param value Enable notifications for issue events
*/
@JvmName("tfgpkihamqnjeaxi")
public suspend fun issuesEvents(`value`: Output) {
this.issuesEvents = value
}
/**
* @param value Enable notifications for merge request events
*/
@JvmName("bimcevwaqbmmnwxo")
public suspend fun mergeRequestsEvents(`value`: Output) {
this.mergeRequestsEvents = value
}
/**
* @param value Enable notifications for note events
*/
@JvmName("xycedwnbqwcimujl")
public suspend fun noteEvents(`value`: Output) {
this.noteEvents = value
}
/**
* @param value Send notifications for broken pipelines
*/
@JvmName("jatqhosfgglsxfrl")
public suspend fun notifyOnlyBrokenPipelines(`value`: Output) {
this.notifyOnlyBrokenPipelines = value
}
/**
* @param value Enable notifications for pipeline events
*/
@JvmName("wtngcnsmfkmyvxad")
public suspend fun pipelineEvents(`value`: Output) {
this.pipelineEvents = value
}
/**
* @param value ID of the project you want to activate integration on.
*/
@JvmName("ymmucipakjtnjavl")
public suspend fun project(`value`: Output) {
this.project = value
}
/**
* @param value Enable notifications for push events
*/
@JvmName("fywkbhwjanvmdeva")
public suspend fun pushEvents(`value`: Output) {
this.pushEvents = value
}
/**
* @param value Enable notifications for tag push events
*/
@JvmName("hdwvsgvfnbhqnpho")
public suspend fun tagPushEvents(`value`: Output) {
this.tagPushEvents = value
}
/**
* @param value The Microsoft Teams webhook (Example, https://outlook.office.com/webhook/...). This value cannot be imported.
*/
@JvmName("hupcodvkqittqevh")
public suspend fun webhook(`value`: Output) {
this.webhook = value
}
/**
* @param value Enable notifications for wiki page events
*/
@JvmName("xjiattwsmgoiqkrd")
public suspend fun wikiPageEvents(`value`: Output) {
this.wikiPageEvents = value
}
/**
* @param value Branches to send notifications for. Valid options are “all”, “default”, “protected”, and “default*and*protected”. The default value is “default”
*/
@JvmName("jpobwktwerqauokn")
public suspend fun branchesToBeNotified(`value`: String?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.branchesToBeNotified = mapped
}
/**
* @param value Enable notifications for confidential issue events
*/
@JvmName("wxdviqsffvufwdso")
public suspend fun confidentialIssuesEvents(`value`: Boolean?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.confidentialIssuesEvents = mapped
}
/**
* @param value Enable notifications for confidential note events
*/
@JvmName("mnisikevgetbrein")
public suspend fun confidentialNoteEvents(`value`: Boolean?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.confidentialNoteEvents = mapped
}
/**
* @param value Enable notifications for issue events
*/
@JvmName("keitauljaaaaarym")
public suspend fun issuesEvents(`value`: Boolean?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.issuesEvents = mapped
}
/**
* @param value Enable notifications for merge request events
*/
@JvmName("ssgtxgrnjclbahol")
public suspend fun mergeRequestsEvents(`value`: Boolean?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.mergeRequestsEvents = mapped
}
/**
* @param value Enable notifications for note events
*/
@JvmName("ahkhddjomugbayxm")
public suspend fun noteEvents(`value`: Boolean?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.noteEvents = mapped
}
/**
* @param value Send notifications for broken pipelines
*/
@JvmName("wdcdsbcigrrbftpo")
public suspend fun notifyOnlyBrokenPipelines(`value`: Boolean?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.notifyOnlyBrokenPipelines = mapped
}
/**
* @param value Enable notifications for pipeline events
*/
@JvmName("iqgnysyfwbrxnrlt")
public suspend fun pipelineEvents(`value`: Boolean?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.pipelineEvents = mapped
}
/**
* @param value ID of the project you want to activate integration on.
*/
@JvmName("exrqjhhiubhxlumb")
public suspend fun project(`value`: String?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.project = mapped
}
/**
* @param value Enable notifications for push events
*/
@JvmName("kapffwypoqwapatj")
public suspend fun pushEvents(`value`: Boolean?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.pushEvents = mapped
}
/**
* @param value Enable notifications for tag push events
*/
@JvmName("jrfnevayjypthoas")
public suspend fun tagPushEvents(`value`: Boolean?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.tagPushEvents = mapped
}
/**
* @param value The Microsoft Teams webhook (Example, https://outlook.office.com/webhook/...). This value cannot be imported.
*/
@JvmName("ldvobdastxmxhgfp")
public suspend fun webhook(`value`: String?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.webhook = mapped
}
/**
* @param value Enable notifications for wiki page events
*/
@JvmName("idhokkbgmeinnmml")
public suspend fun wikiPageEvents(`value`: Boolean?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.wikiPageEvents = mapped
}
internal fun build(): ServiceMicrosoftTeamsArgs = ServiceMicrosoftTeamsArgs(
branchesToBeNotified = branchesToBeNotified,
confidentialIssuesEvents = confidentialIssuesEvents,
confidentialNoteEvents = confidentialNoteEvents,
issuesEvents = issuesEvents,
mergeRequestsEvents = mergeRequestsEvents,
noteEvents = noteEvents,
notifyOnlyBrokenPipelines = notifyOnlyBrokenPipelines,
pipelineEvents = pipelineEvents,
project = project,
pushEvents = pushEvents,
tagPushEvents = tagPushEvents,
webhook = webhook,
wikiPageEvents = wikiPageEvents,
)
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy