1. Packages
  2. Oracle Cloud Infrastructure
  3. API Docs
  4. AnnouncementsService
  5. AnnouncementSubscriptionsActionsChangeCompartment
Oracle Cloud Infrastructure v2.11.0 published on Thursday, Sep 19, 2024 by Pulumi

oci.AnnouncementsService.AnnouncementSubscriptionsActionsChangeCompartment

Explore with Pulumi AI

oci logo
Oracle Cloud Infrastructure v2.11.0 published on Thursday, Sep 19, 2024 by Pulumi

    This resource provides the Announcement Subscriptions Actions Change Compartment resource in Oracle Cloud Infrastructure Announcements Service service.

    Moves the specified announcement subscription from one compartment to another compartment. When provided, If-Match is checked against ETag values of the resource.

    This call is subject to an Announcements limit that applies to the total number of requests across all read or write operations. Announcements might throttle this call to reject an otherwise valid request when the total rate of operations exceeds 20 requests per second for a given user. The service might also throttle this call to reject an otherwise valid request when the total rate of operations exceeds 100 requests per second for a given tenancy.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as oci from "@pulumi/oci";
    
    const testAnnouncementSubscriptionsActionsChangeCompartment = new oci.announcementsservice.AnnouncementSubscriptionsActionsChangeCompartment("test_announcement_subscriptions_actions_change_compartment", {
        announcementSubscriptionId: testAnnouncementSubscription.id,
        compartmentId: compartmentId,
    });
    
    import pulumi
    import pulumi_oci as oci
    
    test_announcement_subscriptions_actions_change_compartment = oci.announcements_service.AnnouncementSubscriptionsActionsChangeCompartment("test_announcement_subscriptions_actions_change_compartment",
        announcement_subscription_id=test_announcement_subscription["id"],
        compartment_id=compartment_id)
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-oci/sdk/v2/go/oci/AnnouncementsService"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := AnnouncementsService.NewAnnouncementSubscriptionsActionsChangeCompartment(ctx, "test_announcement_subscriptions_actions_change_compartment", &AnnouncementsService.AnnouncementSubscriptionsActionsChangeCompartmentArgs{
    			AnnouncementSubscriptionId: pulumi.Any(testAnnouncementSubscription.Id),
    			CompartmentId:              pulumi.Any(compartmentId),
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Oci = Pulumi.Oci;
    
    return await Deployment.RunAsync(() => 
    {
        var testAnnouncementSubscriptionsActionsChangeCompartment = new Oci.AnnouncementsService.AnnouncementSubscriptionsActionsChangeCompartment("test_announcement_subscriptions_actions_change_compartment", new()
        {
            AnnouncementSubscriptionId = testAnnouncementSubscription.Id,
            CompartmentId = compartmentId,
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.oci.AnnouncementsService.AnnouncementSubscriptionsActionsChangeCompartment;
    import com.pulumi.oci.AnnouncementsService.AnnouncementSubscriptionsActionsChangeCompartmentArgs;
    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 testAnnouncementSubscriptionsActionsChangeCompartment = new AnnouncementSubscriptionsActionsChangeCompartment("testAnnouncementSubscriptionsActionsChangeCompartment", AnnouncementSubscriptionsActionsChangeCompartmentArgs.builder()
                .announcementSubscriptionId(testAnnouncementSubscription.id())
                .compartmentId(compartmentId)
                .build());
    
        }
    }
    
    resources:
      testAnnouncementSubscriptionsActionsChangeCompartment:
        type: oci:AnnouncementsService:AnnouncementSubscriptionsActionsChangeCompartment
        name: test_announcement_subscriptions_actions_change_compartment
        properties:
          announcementSubscriptionId: ${testAnnouncementSubscription.id}
          compartmentId: ${compartmentId}
    

    Create AnnouncementSubscriptionsActionsChangeCompartment Resource

    Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

    Constructor syntax

    new AnnouncementSubscriptionsActionsChangeCompartment(name: string, args: AnnouncementSubscriptionsActionsChangeCompartmentArgs, opts?: CustomResourceOptions);
    @overload
    def AnnouncementSubscriptionsActionsChangeCompartment(resource_name: str,
                                                          args: AnnouncementSubscriptionsActionsChangeCompartmentArgs,
                                                          opts: Optional[ResourceOptions] = None)
    
    @overload
    def AnnouncementSubscriptionsActionsChangeCompartment(resource_name: str,
                                                          opts: Optional[ResourceOptions] = None,
                                                          announcement_subscription_id: Optional[str] = None,
                                                          compartment_id: Optional[str] = None)
    func NewAnnouncementSubscriptionsActionsChangeCompartment(ctx *Context, name string, args AnnouncementSubscriptionsActionsChangeCompartmentArgs, opts ...ResourceOption) (*AnnouncementSubscriptionsActionsChangeCompartment, error)
    public AnnouncementSubscriptionsActionsChangeCompartment(string name, AnnouncementSubscriptionsActionsChangeCompartmentArgs args, CustomResourceOptions? opts = null)
    public AnnouncementSubscriptionsActionsChangeCompartment(String name, AnnouncementSubscriptionsActionsChangeCompartmentArgs args)
    public AnnouncementSubscriptionsActionsChangeCompartment(String name, AnnouncementSubscriptionsActionsChangeCompartmentArgs args, CustomResourceOptions options)
    
    type: oci:AnnouncementsService:AnnouncementSubscriptionsActionsChangeCompartment
    properties: # The arguments to resource properties.
    options: # Bag of options to control resource's behavior.
    
    

    Parameters

    name string
    The unique name of the resource.
    args AnnouncementSubscriptionsActionsChangeCompartmentArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    resource_name str
    The unique name of the resource.
    args AnnouncementSubscriptionsActionsChangeCompartmentArgs
    The arguments to resource properties.
    opts ResourceOptions
    Bag of options to control resource's behavior.
    ctx Context
    Context object for the current deployment.
    name string
    The unique name of the resource.
    args AnnouncementSubscriptionsActionsChangeCompartmentArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args AnnouncementSubscriptionsActionsChangeCompartmentArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args AnnouncementSubscriptionsActionsChangeCompartmentArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

    Constructor example

    The following reference example uses placeholder values for all input properties.

    var announcementSubscriptionsActionsChangeCompartmentResource = new Oci.AnnouncementsService.AnnouncementSubscriptionsActionsChangeCompartment("announcementSubscriptionsActionsChangeCompartmentResource", new()
    {
        AnnouncementSubscriptionId = "string",
        CompartmentId = "string",
    });
    
    example, err := AnnouncementsService.NewAnnouncementSubscriptionsActionsChangeCompartment(ctx, "announcementSubscriptionsActionsChangeCompartmentResource", &AnnouncementsService.AnnouncementSubscriptionsActionsChangeCompartmentArgs{
    	AnnouncementSubscriptionId: pulumi.String("string"),
    	CompartmentId:              pulumi.String("string"),
    })
    
    var announcementSubscriptionsActionsChangeCompartmentResource = new AnnouncementSubscriptionsActionsChangeCompartment("announcementSubscriptionsActionsChangeCompartmentResource", AnnouncementSubscriptionsActionsChangeCompartmentArgs.builder()
        .announcementSubscriptionId("string")
        .compartmentId("string")
        .build());
    
    announcement_subscriptions_actions_change_compartment_resource = oci.announcements_service.AnnouncementSubscriptionsActionsChangeCompartment("announcementSubscriptionsActionsChangeCompartmentResource",
        announcement_subscription_id="string",
        compartment_id="string")
    
    const announcementSubscriptionsActionsChangeCompartmentResource = new oci.announcementsservice.AnnouncementSubscriptionsActionsChangeCompartment("announcementSubscriptionsActionsChangeCompartmentResource", {
        announcementSubscriptionId: "string",
        compartmentId: "string",
    });
    
    type: oci:AnnouncementsService:AnnouncementSubscriptionsActionsChangeCompartment
    properties:
        announcementSubscriptionId: string
        compartmentId: string
    

    AnnouncementSubscriptionsActionsChangeCompartment Resource Properties

    To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

    Inputs

    The AnnouncementSubscriptionsActionsChangeCompartment resource accepts the following input properties:

    AnnouncementSubscriptionId string
    The OCID of the announcement subscription.
    CompartmentId string

    The OCID of the compartment into which you want to move the announcement subscription.

    ** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values

    AnnouncementSubscriptionId string
    The OCID of the announcement subscription.
    CompartmentId string

    The OCID of the compartment into which you want to move the announcement subscription.

    ** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values

    announcementSubscriptionId String
    The OCID of the announcement subscription.
    compartmentId String

    The OCID of the compartment into which you want to move the announcement subscription.

    ** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values

    announcementSubscriptionId string
    The OCID of the announcement subscription.
    compartmentId string

    The OCID of the compartment into which you want to move the announcement subscription.

    ** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values

    announcement_subscription_id str
    The OCID of the announcement subscription.
    compartment_id str

    The OCID of the compartment into which you want to move the announcement subscription.

    ** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values

    announcementSubscriptionId String
    The OCID of the announcement subscription.
    compartmentId String

    The OCID of the compartment into which you want to move the announcement subscription.

    ** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values

    Outputs

    All input properties are implicitly available as output properties. Additionally, the AnnouncementSubscriptionsActionsChangeCompartment resource produces the following output properties:

    Id string
    The provider-assigned unique ID for this managed resource.
    Id string
    The provider-assigned unique ID for this managed resource.
    id String
    The provider-assigned unique ID for this managed resource.
    id string
    The provider-assigned unique ID for this managed resource.
    id str
    The provider-assigned unique ID for this managed resource.
    id String
    The provider-assigned unique ID for this managed resource.

    Look up Existing AnnouncementSubscriptionsActionsChangeCompartment Resource

    Get an existing AnnouncementSubscriptionsActionsChangeCompartment resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

    public static get(name: string, id: Input<ID>, state?: AnnouncementSubscriptionsActionsChangeCompartmentState, opts?: CustomResourceOptions): AnnouncementSubscriptionsActionsChangeCompartment
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            announcement_subscription_id: Optional[str] = None,
            compartment_id: Optional[str] = None) -> AnnouncementSubscriptionsActionsChangeCompartment
    func GetAnnouncementSubscriptionsActionsChangeCompartment(ctx *Context, name string, id IDInput, state *AnnouncementSubscriptionsActionsChangeCompartmentState, opts ...ResourceOption) (*AnnouncementSubscriptionsActionsChangeCompartment, error)
    public static AnnouncementSubscriptionsActionsChangeCompartment Get(string name, Input<string> id, AnnouncementSubscriptionsActionsChangeCompartmentState? state, CustomResourceOptions? opts = null)
    public static AnnouncementSubscriptionsActionsChangeCompartment get(String name, Output<String> id, AnnouncementSubscriptionsActionsChangeCompartmentState state, CustomResourceOptions options)
    Resource lookup is not supported in YAML
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    resource_name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    The following state arguments are supported:
    AnnouncementSubscriptionId string
    The OCID of the announcement subscription.
    CompartmentId string

    The OCID of the compartment into which you want to move the announcement subscription.

    ** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values

    AnnouncementSubscriptionId string
    The OCID of the announcement subscription.
    CompartmentId string

    The OCID of the compartment into which you want to move the announcement subscription.

    ** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values

    announcementSubscriptionId String
    The OCID of the announcement subscription.
    compartmentId String

    The OCID of the compartment into which you want to move the announcement subscription.

    ** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values

    announcementSubscriptionId string
    The OCID of the announcement subscription.
    compartmentId string

    The OCID of the compartment into which you want to move the announcement subscription.

    ** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values

    announcement_subscription_id str
    The OCID of the announcement subscription.
    compartment_id str

    The OCID of the compartment into which you want to move the announcement subscription.

    ** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values

    announcementSubscriptionId String
    The OCID of the announcement subscription.
    compartmentId String

    The OCID of the compartment into which you want to move the announcement subscription.

    ** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values

    Import

    AnnouncementSubscriptionsActionsChangeCompartment can be imported using the id, e.g.

    $ pulumi import oci:AnnouncementsService/announcementSubscriptionsActionsChangeCompartment:AnnouncementSubscriptionsActionsChangeCompartment test_announcement_subscriptions_actions_change_compartment "id"
    

    To learn more about importing existing cloud resources, see Importing resources.

    Package Details

    Repository
    oci pulumi/pulumi-oci
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the oci Terraform Provider.
    oci logo
    Oracle Cloud Infrastructure v2.11.0 published on Thursday, Sep 19, 2024 by Pulumi