# Create or update Secret (/secrets/Secret_create)

`POST /apps/{app_name}/secrets/{secret_name}`

## Parameters

| Name | In | Type | Required | Description |
| --- | --- | --- | --- | --- |
| `app_name` | path | `string` | Yes | Fly App Name |
| `secret_name` | path | `string` | Yes | App secret name |

## Request Body

Type: `SetAppSecretRequest`

| Property | Type | Required | Description |
| --- | --- | --- | --- |
| `value` | `string` | No |  |

## Responses

| Status | Description | Schema |
| --- | --- | --- |
| `201` | Created | `SetAppSecretResponse` |
| `400` | Bad Request | `ErrorResponse` |

The full machine-readable OpenAPI spec is available at /openapi.json.