github.com/pulumi/pulumi-aws/sdk/v6@v6.32.0/go/aws/scheduler/schedule.go (about) 1 // Code generated by the Pulumi Terraform Bridge (tfgen) Tool DO NOT EDIT. 2 // *** WARNING: Do not edit by hand unless you're certain you know what you are doing! *** 3 4 package scheduler 5 6 import ( 7 "context" 8 "reflect" 9 10 "errors" 11 "github.com/pulumi/pulumi-aws/sdk/v6/go/aws/internal" 12 "github.com/pulumi/pulumi/sdk/v3/go/pulumi" 13 ) 14 15 // Provides an EventBridge Scheduler Schedule resource. 16 // 17 // You can find out more about EventBridge Scheduler in the [User Guide](https://docs.aws.amazon.com/scheduler/latest/UserGuide/what-is-scheduler.html). 18 // 19 // > **Note:** EventBridge was formerly known as CloudWatch Events. The functionality is identical. 20 // 21 // ## Example Usage 22 // 23 // ### Basic Usage 24 // 25 // <!--Start PulumiCodeChooser --> 26 // ```go 27 // package main 28 // 29 // import ( 30 // 31 // "github.com/pulumi/pulumi-aws/sdk/v6/go/aws/scheduler" 32 // "github.com/pulumi/pulumi/sdk/v3/go/pulumi" 33 // 34 // ) 35 // 36 // func main() { 37 // pulumi.Run(func(ctx *pulumi.Context) error { 38 // _, err := scheduler.NewSchedule(ctx, "example", &scheduler.ScheduleArgs{ 39 // Name: pulumi.String("my-schedule"), 40 // GroupName: pulumi.String("default"), 41 // FlexibleTimeWindow: &scheduler.ScheduleFlexibleTimeWindowArgs{ 42 // Mode: pulumi.String("OFF"), 43 // }, 44 // ScheduleExpression: pulumi.String("rate(1 hours)"), 45 // Target: &scheduler.ScheduleTargetArgs{ 46 // Arn: pulumi.Any(exampleAwsSqsQueue.Arn), 47 // RoleArn: pulumi.Any(exampleAwsIamRole.Arn), 48 // }, 49 // }) 50 // if err != nil { 51 // return err 52 // } 53 // return nil 54 // }) 55 // } 56 // 57 // ``` 58 // <!--End PulumiCodeChooser --> 59 // 60 // ### Universal Target 61 // 62 // <!--Start PulumiCodeChooser --> 63 // ```go 64 // package main 65 // 66 // import ( 67 // 68 // "encoding/json" 69 // 70 // "github.com/pulumi/pulumi-aws/sdk/v6/go/aws/scheduler" 71 // "github.com/pulumi/pulumi-aws/sdk/v6/go/aws/sqs" 72 // "github.com/pulumi/pulumi/sdk/v3/go/pulumi" 73 // 74 // ) 75 // 76 // func main() { 77 // pulumi.Run(func(ctx *pulumi.Context) error { 78 // example, err := sqs.NewQueue(ctx, "example", nil) 79 // if err != nil { 80 // return err 81 // } 82 // _, err = scheduler.NewSchedule(ctx, "example", &scheduler.ScheduleArgs{ 83 // Name: pulumi.String("my-schedule"), 84 // FlexibleTimeWindow: &scheduler.ScheduleFlexibleTimeWindowArgs{ 85 // Mode: pulumi.String("OFF"), 86 // }, 87 // ScheduleExpression: pulumi.String("rate(1 hours)"), 88 // Target: &scheduler.ScheduleTargetArgs{ 89 // Arn: pulumi.String("arn:aws:scheduler:::aws-sdk:sqs:sendMessage"), 90 // RoleArn: pulumi.Any(exampleAwsIamRole.Arn), 91 // Input: example.Url.ApplyT(func(url string) (pulumi.String, error) { 92 // var _zero pulumi.String 93 // tmpJSON0, err := json.Marshal(map[string]interface{}{ 94 // "MessageBody": "Greetings, programs!", 95 // "QueueUrl": url, 96 // }) 97 // if err != nil { 98 // return _zero, err 99 // } 100 // json0 := string(tmpJSON0) 101 // return pulumi.String(json0), nil 102 // }).(pulumi.StringOutput), 103 // }, 104 // }) 105 // if err != nil { 106 // return err 107 // } 108 // return nil 109 // }) 110 // } 111 // 112 // ``` 113 // <!--End PulumiCodeChooser --> 114 // 115 // ## Import 116 // 117 // Using `pulumi import`, import schedules using the combination `group_name/name`. For example: 118 // 119 // ```sh 120 // $ pulumi import aws:scheduler/schedule:Schedule example my-schedule-group/my-schedule 121 // ``` 122 type Schedule struct { 123 pulumi.CustomResourceState 124 125 // ARN of the SQS queue specified as the destination for the dead-letter queue. 126 Arn pulumi.StringOutput `pulumi:"arn"` 127 // Brief description of the schedule. 128 Description pulumi.StringPtrOutput `pulumi:"description"` 129 // The date, in UTC, before which the schedule can invoke its target. Depending on the schedule's recurrence expression, invocations might stop on, or before, the end date you specify. EventBridge Scheduler ignores the end date for one-time schedules. Example: `2030-01-01T01:00:00Z`. 130 EndDate pulumi.StringPtrOutput `pulumi:"endDate"` 131 // Configures a time window during which EventBridge Scheduler invokes the schedule. Detailed below. 132 FlexibleTimeWindow ScheduleFlexibleTimeWindowOutput `pulumi:"flexibleTimeWindow"` 133 // Name of the schedule group to associate with this schedule. When omitted, the `default` schedule group is used. 134 GroupName pulumi.StringOutput `pulumi:"groupName"` 135 // ARN for the customer managed KMS key that EventBridge Scheduler will use to encrypt and decrypt your data. 136 KmsKeyArn pulumi.StringPtrOutput `pulumi:"kmsKeyArn"` 137 // Name of the schedule. If omitted, the provider will assign a random, unique name. Conflicts with `namePrefix`. 138 Name pulumi.StringOutput `pulumi:"name"` 139 // Creates a unique name beginning with the specified prefix. Conflicts with `name`. 140 NamePrefix pulumi.StringOutput `pulumi:"namePrefix"` 141 // Defines when the schedule runs. Read more in [Schedule types on EventBridge Scheduler](https://docs.aws.amazon.com/scheduler/latest/UserGuide/schedule-types.html). 142 ScheduleExpression pulumi.StringOutput `pulumi:"scheduleExpression"` 143 // Timezone in which the scheduling expression is evaluated. Defaults to `UTC`. Example: `Australia/Sydney`. 144 ScheduleExpressionTimezone pulumi.StringPtrOutput `pulumi:"scheduleExpressionTimezone"` 145 // The date, in UTC, after which the schedule can begin invoking its target. Depending on the schedule's recurrence expression, invocations might occur on, or after, the start date you specify. EventBridge Scheduler ignores the start date for one-time schedules. Example: `2030-01-01T01:00:00Z`. 146 StartDate pulumi.StringPtrOutput `pulumi:"startDate"` 147 // Specifies whether the schedule is enabled or disabled. One of: `ENABLED` (default), `DISABLED`. 148 State pulumi.StringPtrOutput `pulumi:"state"` 149 // Configures the target of the schedule. Detailed below. 150 // 151 // The following arguments are optional: 152 Target ScheduleTargetOutput `pulumi:"target"` 153 } 154 155 // NewSchedule registers a new resource with the given unique name, arguments, and options. 156 func NewSchedule(ctx *pulumi.Context, 157 name string, args *ScheduleArgs, opts ...pulumi.ResourceOption) (*Schedule, error) { 158 if args == nil { 159 return nil, errors.New("missing one or more required arguments") 160 } 161 162 if args.FlexibleTimeWindow == nil { 163 return nil, errors.New("invalid value for required argument 'FlexibleTimeWindow'") 164 } 165 if args.ScheduleExpression == nil { 166 return nil, errors.New("invalid value for required argument 'ScheduleExpression'") 167 } 168 if args.Target == nil { 169 return nil, errors.New("invalid value for required argument 'Target'") 170 } 171 opts = internal.PkgResourceDefaultOpts(opts) 172 var resource Schedule 173 err := ctx.RegisterResource("aws:scheduler/schedule:Schedule", name, args, &resource, opts...) 174 if err != nil { 175 return nil, err 176 } 177 return &resource, nil 178 } 179 180 // GetSchedule gets an existing Schedule resource's state with the given name, ID, and optional 181 // state properties that are used to uniquely qualify the lookup (nil if not required). 182 func GetSchedule(ctx *pulumi.Context, 183 name string, id pulumi.IDInput, state *ScheduleState, opts ...pulumi.ResourceOption) (*Schedule, error) { 184 var resource Schedule 185 err := ctx.ReadResource("aws:scheduler/schedule:Schedule", name, id, state, &resource, opts...) 186 if err != nil { 187 return nil, err 188 } 189 return &resource, nil 190 } 191 192 // Input properties used for looking up and filtering Schedule resources. 193 type scheduleState struct { 194 // ARN of the SQS queue specified as the destination for the dead-letter queue. 195 Arn *string `pulumi:"arn"` 196 // Brief description of the schedule. 197 Description *string `pulumi:"description"` 198 // The date, in UTC, before which the schedule can invoke its target. Depending on the schedule's recurrence expression, invocations might stop on, or before, the end date you specify. EventBridge Scheduler ignores the end date for one-time schedules. Example: `2030-01-01T01:00:00Z`. 199 EndDate *string `pulumi:"endDate"` 200 // Configures a time window during which EventBridge Scheduler invokes the schedule. Detailed below. 201 FlexibleTimeWindow *ScheduleFlexibleTimeWindow `pulumi:"flexibleTimeWindow"` 202 // Name of the schedule group to associate with this schedule. When omitted, the `default` schedule group is used. 203 GroupName *string `pulumi:"groupName"` 204 // ARN for the customer managed KMS key that EventBridge Scheduler will use to encrypt and decrypt your data. 205 KmsKeyArn *string `pulumi:"kmsKeyArn"` 206 // Name of the schedule. If omitted, the provider will assign a random, unique name. Conflicts with `namePrefix`. 207 Name *string `pulumi:"name"` 208 // Creates a unique name beginning with the specified prefix. Conflicts with `name`. 209 NamePrefix *string `pulumi:"namePrefix"` 210 // Defines when the schedule runs. Read more in [Schedule types on EventBridge Scheduler](https://docs.aws.amazon.com/scheduler/latest/UserGuide/schedule-types.html). 211 ScheduleExpression *string `pulumi:"scheduleExpression"` 212 // Timezone in which the scheduling expression is evaluated. Defaults to `UTC`. Example: `Australia/Sydney`. 213 ScheduleExpressionTimezone *string `pulumi:"scheduleExpressionTimezone"` 214 // The date, in UTC, after which the schedule can begin invoking its target. Depending on the schedule's recurrence expression, invocations might occur on, or after, the start date you specify. EventBridge Scheduler ignores the start date for one-time schedules. Example: `2030-01-01T01:00:00Z`. 215 StartDate *string `pulumi:"startDate"` 216 // Specifies whether the schedule is enabled or disabled. One of: `ENABLED` (default), `DISABLED`. 217 State *string `pulumi:"state"` 218 // Configures the target of the schedule. Detailed below. 219 // 220 // The following arguments are optional: 221 Target *ScheduleTarget `pulumi:"target"` 222 } 223 224 type ScheduleState struct { 225 // ARN of the SQS queue specified as the destination for the dead-letter queue. 226 Arn pulumi.StringPtrInput 227 // Brief description of the schedule. 228 Description pulumi.StringPtrInput 229 // The date, in UTC, before which the schedule can invoke its target. Depending on the schedule's recurrence expression, invocations might stop on, or before, the end date you specify. EventBridge Scheduler ignores the end date for one-time schedules. Example: `2030-01-01T01:00:00Z`. 230 EndDate pulumi.StringPtrInput 231 // Configures a time window during which EventBridge Scheduler invokes the schedule. Detailed below. 232 FlexibleTimeWindow ScheduleFlexibleTimeWindowPtrInput 233 // Name of the schedule group to associate with this schedule. When omitted, the `default` schedule group is used. 234 GroupName pulumi.StringPtrInput 235 // ARN for the customer managed KMS key that EventBridge Scheduler will use to encrypt and decrypt your data. 236 KmsKeyArn pulumi.StringPtrInput 237 // Name of the schedule. If omitted, the provider will assign a random, unique name. Conflicts with `namePrefix`. 238 Name pulumi.StringPtrInput 239 // Creates a unique name beginning with the specified prefix. Conflicts with `name`. 240 NamePrefix pulumi.StringPtrInput 241 // Defines when the schedule runs. Read more in [Schedule types on EventBridge Scheduler](https://docs.aws.amazon.com/scheduler/latest/UserGuide/schedule-types.html). 242 ScheduleExpression pulumi.StringPtrInput 243 // Timezone in which the scheduling expression is evaluated. Defaults to `UTC`. Example: `Australia/Sydney`. 244 ScheduleExpressionTimezone pulumi.StringPtrInput 245 // The date, in UTC, after which the schedule can begin invoking its target. Depending on the schedule's recurrence expression, invocations might occur on, or after, the start date you specify. EventBridge Scheduler ignores the start date for one-time schedules. Example: `2030-01-01T01:00:00Z`. 246 StartDate pulumi.StringPtrInput 247 // Specifies whether the schedule is enabled or disabled. One of: `ENABLED` (default), `DISABLED`. 248 State pulumi.StringPtrInput 249 // Configures the target of the schedule. Detailed below. 250 // 251 // The following arguments are optional: 252 Target ScheduleTargetPtrInput 253 } 254 255 func (ScheduleState) ElementType() reflect.Type { 256 return reflect.TypeOf((*scheduleState)(nil)).Elem() 257 } 258 259 type scheduleArgs struct { 260 // Brief description of the schedule. 261 Description *string `pulumi:"description"` 262 // The date, in UTC, before which the schedule can invoke its target. Depending on the schedule's recurrence expression, invocations might stop on, or before, the end date you specify. EventBridge Scheduler ignores the end date for one-time schedules. Example: `2030-01-01T01:00:00Z`. 263 EndDate *string `pulumi:"endDate"` 264 // Configures a time window during which EventBridge Scheduler invokes the schedule. Detailed below. 265 FlexibleTimeWindow ScheduleFlexibleTimeWindow `pulumi:"flexibleTimeWindow"` 266 // Name of the schedule group to associate with this schedule. When omitted, the `default` schedule group is used. 267 GroupName *string `pulumi:"groupName"` 268 // ARN for the customer managed KMS key that EventBridge Scheduler will use to encrypt and decrypt your data. 269 KmsKeyArn *string `pulumi:"kmsKeyArn"` 270 // Name of the schedule. If omitted, the provider will assign a random, unique name. Conflicts with `namePrefix`. 271 Name *string `pulumi:"name"` 272 // Creates a unique name beginning with the specified prefix. Conflicts with `name`. 273 NamePrefix *string `pulumi:"namePrefix"` 274 // Defines when the schedule runs. Read more in [Schedule types on EventBridge Scheduler](https://docs.aws.amazon.com/scheduler/latest/UserGuide/schedule-types.html). 275 ScheduleExpression string `pulumi:"scheduleExpression"` 276 // Timezone in which the scheduling expression is evaluated. Defaults to `UTC`. Example: `Australia/Sydney`. 277 ScheduleExpressionTimezone *string `pulumi:"scheduleExpressionTimezone"` 278 // The date, in UTC, after which the schedule can begin invoking its target. Depending on the schedule's recurrence expression, invocations might occur on, or after, the start date you specify. EventBridge Scheduler ignores the start date for one-time schedules. Example: `2030-01-01T01:00:00Z`. 279 StartDate *string `pulumi:"startDate"` 280 // Specifies whether the schedule is enabled or disabled. One of: `ENABLED` (default), `DISABLED`. 281 State *string `pulumi:"state"` 282 // Configures the target of the schedule. Detailed below. 283 // 284 // The following arguments are optional: 285 Target ScheduleTarget `pulumi:"target"` 286 } 287 288 // The set of arguments for constructing a Schedule resource. 289 type ScheduleArgs struct { 290 // Brief description of the schedule. 291 Description pulumi.StringPtrInput 292 // The date, in UTC, before which the schedule can invoke its target. Depending on the schedule's recurrence expression, invocations might stop on, or before, the end date you specify. EventBridge Scheduler ignores the end date for one-time schedules. Example: `2030-01-01T01:00:00Z`. 293 EndDate pulumi.StringPtrInput 294 // Configures a time window during which EventBridge Scheduler invokes the schedule. Detailed below. 295 FlexibleTimeWindow ScheduleFlexibleTimeWindowInput 296 // Name of the schedule group to associate with this schedule. When omitted, the `default` schedule group is used. 297 GroupName pulumi.StringPtrInput 298 // ARN for the customer managed KMS key that EventBridge Scheduler will use to encrypt and decrypt your data. 299 KmsKeyArn pulumi.StringPtrInput 300 // Name of the schedule. If omitted, the provider will assign a random, unique name. Conflicts with `namePrefix`. 301 Name pulumi.StringPtrInput 302 // Creates a unique name beginning with the specified prefix. Conflicts with `name`. 303 NamePrefix pulumi.StringPtrInput 304 // Defines when the schedule runs. Read more in [Schedule types on EventBridge Scheduler](https://docs.aws.amazon.com/scheduler/latest/UserGuide/schedule-types.html). 305 ScheduleExpression pulumi.StringInput 306 // Timezone in which the scheduling expression is evaluated. Defaults to `UTC`. Example: `Australia/Sydney`. 307 ScheduleExpressionTimezone pulumi.StringPtrInput 308 // The date, in UTC, after which the schedule can begin invoking its target. Depending on the schedule's recurrence expression, invocations might occur on, or after, the start date you specify. EventBridge Scheduler ignores the start date for one-time schedules. Example: `2030-01-01T01:00:00Z`. 309 StartDate pulumi.StringPtrInput 310 // Specifies whether the schedule is enabled or disabled. One of: `ENABLED` (default), `DISABLED`. 311 State pulumi.StringPtrInput 312 // Configures the target of the schedule. Detailed below. 313 // 314 // The following arguments are optional: 315 Target ScheduleTargetInput 316 } 317 318 func (ScheduleArgs) ElementType() reflect.Type { 319 return reflect.TypeOf((*scheduleArgs)(nil)).Elem() 320 } 321 322 type ScheduleInput interface { 323 pulumi.Input 324 325 ToScheduleOutput() ScheduleOutput 326 ToScheduleOutputWithContext(ctx context.Context) ScheduleOutput 327 } 328 329 func (*Schedule) ElementType() reflect.Type { 330 return reflect.TypeOf((**Schedule)(nil)).Elem() 331 } 332 333 func (i *Schedule) ToScheduleOutput() ScheduleOutput { 334 return i.ToScheduleOutputWithContext(context.Background()) 335 } 336 337 func (i *Schedule) ToScheduleOutputWithContext(ctx context.Context) ScheduleOutput { 338 return pulumi.ToOutputWithContext(ctx, i).(ScheduleOutput) 339 } 340 341 // ScheduleArrayInput is an input type that accepts ScheduleArray and ScheduleArrayOutput values. 342 // You can construct a concrete instance of `ScheduleArrayInput` via: 343 // 344 // ScheduleArray{ ScheduleArgs{...} } 345 type ScheduleArrayInput interface { 346 pulumi.Input 347 348 ToScheduleArrayOutput() ScheduleArrayOutput 349 ToScheduleArrayOutputWithContext(context.Context) ScheduleArrayOutput 350 } 351 352 type ScheduleArray []ScheduleInput 353 354 func (ScheduleArray) ElementType() reflect.Type { 355 return reflect.TypeOf((*[]*Schedule)(nil)).Elem() 356 } 357 358 func (i ScheduleArray) ToScheduleArrayOutput() ScheduleArrayOutput { 359 return i.ToScheduleArrayOutputWithContext(context.Background()) 360 } 361 362 func (i ScheduleArray) ToScheduleArrayOutputWithContext(ctx context.Context) ScheduleArrayOutput { 363 return pulumi.ToOutputWithContext(ctx, i).(ScheduleArrayOutput) 364 } 365 366 // ScheduleMapInput is an input type that accepts ScheduleMap and ScheduleMapOutput values. 367 // You can construct a concrete instance of `ScheduleMapInput` via: 368 // 369 // ScheduleMap{ "key": ScheduleArgs{...} } 370 type ScheduleMapInput interface { 371 pulumi.Input 372 373 ToScheduleMapOutput() ScheduleMapOutput 374 ToScheduleMapOutputWithContext(context.Context) ScheduleMapOutput 375 } 376 377 type ScheduleMap map[string]ScheduleInput 378 379 func (ScheduleMap) ElementType() reflect.Type { 380 return reflect.TypeOf((*map[string]*Schedule)(nil)).Elem() 381 } 382 383 func (i ScheduleMap) ToScheduleMapOutput() ScheduleMapOutput { 384 return i.ToScheduleMapOutputWithContext(context.Background()) 385 } 386 387 func (i ScheduleMap) ToScheduleMapOutputWithContext(ctx context.Context) ScheduleMapOutput { 388 return pulumi.ToOutputWithContext(ctx, i).(ScheduleMapOutput) 389 } 390 391 type ScheduleOutput struct{ *pulumi.OutputState } 392 393 func (ScheduleOutput) ElementType() reflect.Type { 394 return reflect.TypeOf((**Schedule)(nil)).Elem() 395 } 396 397 func (o ScheduleOutput) ToScheduleOutput() ScheduleOutput { 398 return o 399 } 400 401 func (o ScheduleOutput) ToScheduleOutputWithContext(ctx context.Context) ScheduleOutput { 402 return o 403 } 404 405 // ARN of the SQS queue specified as the destination for the dead-letter queue. 406 func (o ScheduleOutput) Arn() pulumi.StringOutput { 407 return o.ApplyT(func(v *Schedule) pulumi.StringOutput { return v.Arn }).(pulumi.StringOutput) 408 } 409 410 // Brief description of the schedule. 411 func (o ScheduleOutput) Description() pulumi.StringPtrOutput { 412 return o.ApplyT(func(v *Schedule) pulumi.StringPtrOutput { return v.Description }).(pulumi.StringPtrOutput) 413 } 414 415 // The date, in UTC, before which the schedule can invoke its target. Depending on the schedule's recurrence expression, invocations might stop on, or before, the end date you specify. EventBridge Scheduler ignores the end date for one-time schedules. Example: `2030-01-01T01:00:00Z`. 416 func (o ScheduleOutput) EndDate() pulumi.StringPtrOutput { 417 return o.ApplyT(func(v *Schedule) pulumi.StringPtrOutput { return v.EndDate }).(pulumi.StringPtrOutput) 418 } 419 420 // Configures a time window during which EventBridge Scheduler invokes the schedule. Detailed below. 421 func (o ScheduleOutput) FlexibleTimeWindow() ScheduleFlexibleTimeWindowOutput { 422 return o.ApplyT(func(v *Schedule) ScheduleFlexibleTimeWindowOutput { return v.FlexibleTimeWindow }).(ScheduleFlexibleTimeWindowOutput) 423 } 424 425 // Name of the schedule group to associate with this schedule. When omitted, the `default` schedule group is used. 426 func (o ScheduleOutput) GroupName() pulumi.StringOutput { 427 return o.ApplyT(func(v *Schedule) pulumi.StringOutput { return v.GroupName }).(pulumi.StringOutput) 428 } 429 430 // ARN for the customer managed KMS key that EventBridge Scheduler will use to encrypt and decrypt your data. 431 func (o ScheduleOutput) KmsKeyArn() pulumi.StringPtrOutput { 432 return o.ApplyT(func(v *Schedule) pulumi.StringPtrOutput { return v.KmsKeyArn }).(pulumi.StringPtrOutput) 433 } 434 435 // Name of the schedule. If omitted, the provider will assign a random, unique name. Conflicts with `namePrefix`. 436 func (o ScheduleOutput) Name() pulumi.StringOutput { 437 return o.ApplyT(func(v *Schedule) pulumi.StringOutput { return v.Name }).(pulumi.StringOutput) 438 } 439 440 // Creates a unique name beginning with the specified prefix. Conflicts with `name`. 441 func (o ScheduleOutput) NamePrefix() pulumi.StringOutput { 442 return o.ApplyT(func(v *Schedule) pulumi.StringOutput { return v.NamePrefix }).(pulumi.StringOutput) 443 } 444 445 // Defines when the schedule runs. Read more in [Schedule types on EventBridge Scheduler](https://docs.aws.amazon.com/scheduler/latest/UserGuide/schedule-types.html). 446 func (o ScheduleOutput) ScheduleExpression() pulumi.StringOutput { 447 return o.ApplyT(func(v *Schedule) pulumi.StringOutput { return v.ScheduleExpression }).(pulumi.StringOutput) 448 } 449 450 // Timezone in which the scheduling expression is evaluated. Defaults to `UTC`. Example: `Australia/Sydney`. 451 func (o ScheduleOutput) ScheduleExpressionTimezone() pulumi.StringPtrOutput { 452 return o.ApplyT(func(v *Schedule) pulumi.StringPtrOutput { return v.ScheduleExpressionTimezone }).(pulumi.StringPtrOutput) 453 } 454 455 // The date, in UTC, after which the schedule can begin invoking its target. Depending on the schedule's recurrence expression, invocations might occur on, or after, the start date you specify. EventBridge Scheduler ignores the start date for one-time schedules. Example: `2030-01-01T01:00:00Z`. 456 func (o ScheduleOutput) StartDate() pulumi.StringPtrOutput { 457 return o.ApplyT(func(v *Schedule) pulumi.StringPtrOutput { return v.StartDate }).(pulumi.StringPtrOutput) 458 } 459 460 // Specifies whether the schedule is enabled or disabled. One of: `ENABLED` (default), `DISABLED`. 461 func (o ScheduleOutput) State() pulumi.StringPtrOutput { 462 return o.ApplyT(func(v *Schedule) pulumi.StringPtrOutput { return v.State }).(pulumi.StringPtrOutput) 463 } 464 465 // Configures the target of the schedule. Detailed below. 466 // 467 // The following arguments are optional: 468 func (o ScheduleOutput) Target() ScheduleTargetOutput { 469 return o.ApplyT(func(v *Schedule) ScheduleTargetOutput { return v.Target }).(ScheduleTargetOutput) 470 } 471 472 type ScheduleArrayOutput struct{ *pulumi.OutputState } 473 474 func (ScheduleArrayOutput) ElementType() reflect.Type { 475 return reflect.TypeOf((*[]*Schedule)(nil)).Elem() 476 } 477 478 func (o ScheduleArrayOutput) ToScheduleArrayOutput() ScheduleArrayOutput { 479 return o 480 } 481 482 func (o ScheduleArrayOutput) ToScheduleArrayOutputWithContext(ctx context.Context) ScheduleArrayOutput { 483 return o 484 } 485 486 func (o ScheduleArrayOutput) Index(i pulumi.IntInput) ScheduleOutput { 487 return pulumi.All(o, i).ApplyT(func(vs []interface{}) *Schedule { 488 return vs[0].([]*Schedule)[vs[1].(int)] 489 }).(ScheduleOutput) 490 } 491 492 type ScheduleMapOutput struct{ *pulumi.OutputState } 493 494 func (ScheduleMapOutput) ElementType() reflect.Type { 495 return reflect.TypeOf((*map[string]*Schedule)(nil)).Elem() 496 } 497 498 func (o ScheduleMapOutput) ToScheduleMapOutput() ScheduleMapOutput { 499 return o 500 } 501 502 func (o ScheduleMapOutput) ToScheduleMapOutputWithContext(ctx context.Context) ScheduleMapOutput { 503 return o 504 } 505 506 func (o ScheduleMapOutput) MapIndex(k pulumi.StringInput) ScheduleOutput { 507 return pulumi.All(o, k).ApplyT(func(vs []interface{}) *Schedule { 508 return vs[0].(map[string]*Schedule)[vs[1].(string)] 509 }).(ScheduleOutput) 510 } 511 512 func init() { 513 pulumi.RegisterInputType(reflect.TypeOf((*ScheduleInput)(nil)).Elem(), &Schedule{}) 514 pulumi.RegisterInputType(reflect.TypeOf((*ScheduleArrayInput)(nil)).Elem(), ScheduleArray{}) 515 pulumi.RegisterInputType(reflect.TypeOf((*ScheduleMapInput)(nil)).Elem(), ScheduleMap{}) 516 pulumi.RegisterOutputType(ScheduleOutput{}) 517 pulumi.RegisterOutputType(ScheduleArrayOutput{}) 518 pulumi.RegisterOutputType(ScheduleMapOutput{}) 519 }