# Standard Format Date and Time

> Format a Unix timestamp into a standardized date and time string.

- ID: `machine_format_datetime`
- Type: Block
- Category: [Time](https://inventor.bot/docs/reference/blocks/time.md)

**Inputs**

| Name | Required | Description | Value |
| --- | --- | --- | --- |
| `unix_time` | yes | Unix timestamp to format. | e.g. `"1700000000"` |
| `format` | yes | Standard library format to use. | `"RFC 3339"`, `"ANSIC"`, `"Unix Date"`, `"Ruby Date"`, `"RFC 822"`, `"RFC 822Z"`, `"RFC 850"`, `"RFC 1123"`, `"RFC 1123Z"`, `"RFC 3339Nano"` |

**Outputs**

| Name | Description | Value |
| --- | --- | --- |
| `formatted_time` | Formatted date/time string. | e.g. `"2025-12-10T15:04:05Z"` |

**Example**

```go
machineFormatDatetime := machine_format_datetime(Args{unix_time: "1700000000", format: "RFC 3339"})
send_text_message(Args{
	channel_id:      trigger.channel_id,
	message_content: "Formatted Time: " + machineFormatDatetime.formatted_time,
})
```