---
# ----------------------------------------------------------------------------
#
#     ***     AUTO GENERATED CODE    ***    Type: MMv1     ***
#
# ----------------------------------------------------------------------------
#
#     This file is automatically generated by Magic Modules and manual
#     changes will be clobbered when the file is regenerated.
#
#     Please read more about how to change this file in
#     .github/CONTRIBUTING.md.
#
# ----------------------------------------------------------------------------
subcategory: "Dialogflow"
description: |-
  By default, your agent responds to a matched intent with a static response.
---

# google\_dialogflow\_fulfillment

By default, your agent responds to a matched intent with a static response. If you're using one of the integration options, you can provide a more dynamic response by using fulfillment. When you enable fulfillment for an intent, Dialogflow responds to that intent by calling a service that you define. For example, if an end-user wants to schedule a haircut on Friday, your service can check your database and respond to the end-user with availability information for Friday.


To get more information about Fulfillment, see:

* [API documentation](https://cloud.google.com/dialogflow/es/docs/reference/rest/v2/projects.agent/getFulfillment)
* How-to Guides
    * [Official Documentation](https://cloud.google.com/dialogflow/es/docs/fulfillment-overview)

## Example Usage - Dialogflow Fulfillment Basic


```hcl
resource "google_dialogflow_agent" "basic_agent" {
  display_name = "example_agent"
  default_language_code = "en"
  time_zone = "America/New_York"
}

resource "google_dialogflow_fulfillment" "basic_fulfillment" {
  depends_on = [google_dialogflow_agent.basic_agent]
  display_name = "basic-fulfillment"
  enabled    = true
  generic_web_service {
			uri      = "https://google.com"
			username = "admin"
			password = "password"
			request_headers = { 
          name = "wrench"
			}
	}
}
```

## Argument Reference

The following arguments are supported:


* `display_name` -
  (Required)
  The human-readable name of the fulfillment, unique within the agent.


- - -


* `enabled` -
  (Optional)
  Whether fulfillment is enabled.

* `features` -
  (Optional)
  The field defines whether the fulfillment is enabled for certain features.
  Structure is [documented below](#nested_features).

* `generic_web_service` -
  (Optional)
  Represents configuration for a generic web service. Dialogflow supports two mechanisms for authentications: - Basic authentication with username and password. - Authentication with additional authentication headers.
  Structure is [documented below](#nested_generic_web_service).

* `project` - (Optional) The ID of the project in which the resource belongs.
    If it is not provided, the provider project is used.


<a name="nested_features"></a>The `features` block supports:

* `type` -
  (Required)
  The type of the feature that enabled for fulfillment.
  * SMALLTALK: Fulfillment is enabled for SmallTalk.
  Possible values are: `SMALLTALK`.

<a name="nested_generic_web_service"></a>The `generic_web_service` block supports:

* `uri` -
  (Required)
  The fulfillment URI for receiving POST requests. It must use https protocol.

* `username` -
  (Optional)
  The user name for HTTP Basic authentication.

* `password` -
  (Optional)
  The password for HTTP Basic authentication.

* `request_headers` -
  (Optional)
  The HTTP request headers to send together with fulfillment requests.

## Attributes Reference

In addition to the arguments listed above, the following computed attributes are exported:

* `id` - an identifier for the resource with format `{{name}}`

* `name` -
  The unique identifier of the fulfillment.
  Format: projects/<Project ID>/agent/fulfillment - projects/<Project ID>/locations/<Location ID>/agent/fulfillment


## Timeouts

This resource provides the following
[Timeouts](https://developer.hashicorp.com/terraform/plugin/sdkv2/resources/retries-and-customizable-timeouts) configuration options:

- `create` - Default is 20 minutes.
- `update` - Default is 20 minutes.
- `delete` - Default is 20 minutes.

## Import


Fulfillment can be imported using any of these accepted formats:

* `{{name}}`


In Terraform v1.5.0 and later, use an [`import` block](https://developer.hashicorp.com/terraform/language/import) to import Fulfillment using one of the formats above. For example:

```tf
import {
  id = "{{name}}"
  to = google_dialogflow_fulfillment.default
}
```

When using the [`terraform import` command](https://developer.hashicorp.com/terraform/cli/commands/import), Fulfillment can be imported using one of the formats above. For example:

```
$ terraform import google_dialogflow_fulfillment.default {{name}}
```

## User Project Overrides

This resource supports [User Project Overrides](https://registry.terraform.io/providers/hashicorp/google/latest/docs/guides/provider_reference#user_project_override).
