# CodeConfig

Result of binding `Code` into a `Function`.

- Source: [`aws-appsync/lib/code.ts`](https://github.com/aws/aws-cdk/blob/v2.277.0/packages/aws-cdk-lib/aws-appsync/lib/code.ts#L9)
- Type last changed: v2.60.0 · 12 Jan 2023

## Example

TypeScript:

```ts
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_appsync as appsync } from 'aws-cdk-lib';
const codeConfig: appsync.CodeConfig = {
  inlineCode: 'inlineCode',
  s3Location: 's3Location',
};
```

Python:

```python
# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk import aws_appsync as appsync

code_config = appsync.CodeConfig(
    inline_code="inlineCode",
    s3_location="s3Location"
)
```

Java:

```java
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.services.appsync.*;

CodeConfig codeConfig = CodeConfig.builder()
        .inlineCode("inlineCode")
        .s3Location("s3Location")
        .build();
```

C# / .NET:

```csharp
// Install: dotnet add package Amazon.CDK.Lib
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.AWS.AppSync;

var codeConfig = new CodeConfig {
    InlineCode = "inlineCode",
    S3Location = "s3Location"
};
```

Golang:

```go
// Install: go get github.com/aws/aws-cdk-go/awscdk/v2
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import "github.com/aws/aws-cdk-go/awscdk"

codeConfig := &CodeConfig{
	InlineCode: jsii.String("inlineCode"),
	S3Location: jsii.String("s3Location"),
}
```

## Properties

- `inlineCode`: string — Inline code (mutually exclusive with `s3Location`).

  **Default:** code is not inline code

- `s3Location`: string — The location of the code in S3 (mutually exclusive with `inlineCode`.

  **Default:** code is not an s3 location
