# IResourceWithAzureFunctionsConfig Methods

- Package: [Aspire.Hosting.Azure](/reference/api/csharp/aspire.hosting.azure.md)
- Type: [IResourceWithAzureFunctionsConfig](/reference/api/csharp/aspire.hosting.azure/iresourcewithazurefunctionsconfig.md)
- Kind: `Methods`
- Members: `1`

Represents an resource that can provide configuration for Azure Functions.

## ApplyAzureFunctionsConfiguration(IDictionary<string, object>, string)

- Name: `ApplyAzureFunctionsConfiguration(IDictionary<string, object>, string)`
- Modifiers: `abstract`

Applies the Azure Functions configuration to the target dictionary.

```csharp
public interface IResourceWithAzureFunctionsConfig
{
    public abstract void ApplyAzureFunctionsConfiguration(
        IDictionary<string, object> target,
        string connectionName)
    {
        // ...
    }
}
```

## Parameters

- `target` (`IDictionary<string, object>`)
  The dictionary to which the Azure Functions configuration will be applied.
- `connectionName` (`string`)
  The name of the connection key to be used for the given configuration.

## Remarks

Implementations should populate the `target` dictionary with keys that match the format expected by the Azure Functions runtime, and values that are valid connection strings or service URIs.

For Azure Functions listener initialization, use keys like:

- `{connectionName}` for connection strings (typically used with emulators)
- `{connectionName}__fullyQualifiedNamespace` for Azure Event Hubs and Azure Service Bus endpoints
- `{connectionName}__blobServiceUri` and `{connectionName}__queueServiceUri` for Azure Blob Storage and Azure Queue Storage
- `{connectionName}__accountEndpoint` for Azure Cosmos DB account endpoints

For Aspire client integration support, use keys following the pattern: `Aspire__{ServiceType}__{connectionName}__{Property}` where `{ServiceType}` is the service namespace (e.g., `Azure__Messaging__EventHubs`, `Azure__Messaging__ServiceBus`, `Azure__Storage__Blobs`, `Microsoft__Azure__Cosmos`) and `{Property}` is typically `ConnectionString`, `ServiceUri`, `FullyQualifiedNamespace`, or `AccountEndpoint`.
