Header menu logo FSharp.ATProto

AtDateTime Module

Functions for creating, validating, and extracting data from AtDateTime values.

Functions and values

Function or value Description

parse s

Full Usage: parse s

Parameters:
    s : string - A datetime string in the format YYYY-MM-DDTHH:MM:SS[.fractional](Z|+HH:MM|-HH:MM). Must use uppercase T separator and uppercase Z for UTC. Seconds are required. The offset -00:00 is not allowed.

Returns: Result<AtDateTime, string> Ok with a validated AtDateTime, or Error with a message describing the validation failure. Validation failures include: null input, invalid format, or use of the prohibited -00:00 offset.

Parse and validate an AT Protocol datetime string.

s : string

A datetime string in the format YYYY-MM-DDTHH:MM:SS[.fractional](Z|+HH:MM|-HH:MM). Must use uppercase T separator and uppercase Z for UTC. Seconds are required. The offset -00:00 is not allowed.

Returns: Result<AtDateTime, string>

Ok with a validated AtDateTime, or Error with a message describing the validation failure. Validation failures include: null input, invalid format, or use of the prohibited -00:00 offset.

value arg1

Full Usage: value arg1

Parameters:
Returns: string The datetime string in RFC 3339 format (e.g. "2023-11-23T12:34:56.789Z").

Extract the string representation of an AT Protocol datetime.

arg0 : AtDateTime
Returns: string

The datetime string in RFC 3339 format (e.g. "2023-11-23T12:34:56.789Z").

Type something to start searching.