# parseDayOfWeekFromDateTime

Industry: Core

## Signature

```ts
parseDayOfWeekFromDateTime(value: string): number | null
```

Return the day of week (1-7) for a given ISO 8601 datetime string.

- Monday=1 through Sunday=7.
- Returns null for invalid input.

## Parameters

| Parameter | Type | Description |
| --- | --- | --- |
| `value` | `string` | ISO datetime string |

## Returns

Day of week (1-7) or null on invalid input

## Examples

```ts
import { parseDayOfWeekFromDateTime } from "@northguild/gmt/plain/parse";

parseDayOfWeekFromDateTime("2024-01-01T12:00:00") // 1 (Monday)
```

## Source

[plain/parse/parseDayOfWeekFromDateTime.ts](https://github.com/northguild/gmt/blob/main/packages/gmt/src/plain/parse/parseDayOfWeekFromDateTime.ts)
