An open API service indexing awesome lists of open source software.

https://github.com/rjpearson94/terraform-twilio-autopilot

Terraform module for managing an autopilot assistant
https://github.com/rjpearson94/terraform-twilio-autopilot

autopilot hcl terraform terraform-module terratest twilio

Last synced: 5 months ago
JSON representation

Terraform module for managing an autopilot assistant

Awesome Lists containing this project

README

          

# terraform-twilio-autopilot

This is a terraform module for managing an Autopilot assistant.

This module uses the community Twilio Terraform Provider (also maintained by the module [author](https://github.com/RJPearson94))

- [Terraform Registry](https://registry.terraform.io/providers/RJPearson94/twilio/latest)
- [Github](https://github.com/RJPearson94/terraform-provider-twilio)

The following resources can be managed via the module:

- [Assistant](https://registry.terraform.io/providers/RJPearson94/twilio/latest/docs/resources/autopilot_assistant)
- [Field Type](https://registry.terraform.io/providers/RJPearson94/twilio/latest/docs/resources/autopilot_field_type)
- [Field Value](https://registry.terraform.io/providers/RJPearson94/twilio/latest/docs/resources/autopilot_field_value)
- [Model Build](https://registry.terraform.io/providers/RJPearson94/twilio/latest/docs/resources/autopilot_model_build)
- [Tasks](https://registry.terraform.io/providers/RJPearson94/twilio/latest/docs/resources/autopilot_task)
- [Task Fields](https://registry.terraform.io/providers/RJPearson94/twilio/latest/docs/resources/autopilot_task_field)
- [Task Samples](https://registry.terraform.io/providers/RJPearson94/twilio/latest/docs/resources/autopilot_task_sample)
- [Webhooks](https://registry.terraform.io/providers/RJPearson94/twilio/latest/docs/resources/autopilot_webhook)

~> **Disclaimer:** This project is not an official Twilio project and is not supported or endorsed by Twilio in any way. It is maintained in [my](https://github.com/RJPearson94) free time.

**NOTE:** The default branch for this project is called `main`

## Examples

Examples of how the Terraform module can be used can be found [here](./examples)

## Requirements

| Name | Version |
| --------- | -------- |
| terraform | >= 0.14 |
| twilio | >= 0.2.0 |

## Providers

| Name | Version |
| ------ | -------- |
| twilio | >= 0.2.0 |

## Modules

| Name | Source | Version |
| ------------------- | ------------------- | ------- |
| autopilot_assistant | ./modules/assistant | |
| autopilot_tasks | ./modules/task | |

## Resources

| Name |
| ------------------------------------------------------------------------------------------------------------------------------------- |
| [twilio_autopilot_model_build](https://registry.terraform.io/providers/RJPearson94/twilio/0.2.0/docs/resources/autopilot_model_build) |

## Inputs

| Name | Description | Type | Default | Required |
| ----------------- | ----------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------- | :------: |
| assistant_name | The unique name of the Autopilot assistant | `string` | n/a | yes |
| callback | The callback webhook |

object({
url = string
events = list(string)
})
| `null` | no |
| default_language | The default language to use for the task, sample and fields | `string` | n/a | yes |
| defaults | The defaults JSON of the Autopilot assistant | `string` | `null` | no |
| development_stage | Whether the assistant is in development stage | `bool` | `false` | no |
| enable_logging | Whether query logging is enabled | `bool` | `false` | no |
| polling | The polling config for the model build |
object({
enabled = bool
max_attempts = number
delay_in_ms = number
})
|
{
"delay_in_ms": null,
"enabled": true,
"max_attempts": null
}
| no |
| stylesheet | The stylesheet JSON of the Autopilot assistant | `string` | `null` | no |
| tasks | The tasks of the Autopilot assistants |
list(object({
name = string
actions = object({
json = string
url = string
})
fields = list(object({
name = string
type = object({
built_in = string
custom = object({
name = string
values = list(object({
language_override = string
value = string

synonyms = list(object({
language_override = string
value = string
}))
}))
})
})
}))
samples = list(object({
tagged_text = string
language_override = string
source_channel = string
}))
}))
| n/a | yes |
| webhooks | The webhooks which will be triggered on specific events |
list(object({
name = string
url = string
method = string
events = list(string)
}))
| `[]` | no |

## Outputs

| Name | Description |
| ----------- | ----------------------------------- |
| assistant | The generated Autopilot assistant |
| model_build | The generated Autopilot model build |
| tasks | The generated tasks |
| webhooks | The generated Autopilot webhooks |

## Sub Modules

This module utilises additional sub-modules which can be seen [here](./modules)