Skip to content

Locale & Batch

BridgeTime includes locale packs and calendar-style formatting in both Python and Node bindings.

  • en
  • fr
  • es
  • de
  • pt

Use supported_locales() (Python) or supportedLocales() (Node.js) to inspect runtime locale availability.

from bridgetime import bridge_time
dt = bridge_time.parse("2026-06-15T11:30:00Z", "Europe/Paris")
print(dt.format_locale("dddd, D MMMM YYYY HH:mm", "fr"))
print(dt.calendar(locale="fr"))

Batch operations reduce call overhead for larger payloads.

  • parse_batch / parseBatch
  • parse_format_batch / parseFormatBatch
  • format_batch / formatBatch
from bridgetime import bridge_time
payload = [
"2026-01-02T10:00:00Z",
"2026-01-03T15:30:00Z",
"2026-01-04T08:05:00Z",
]
parsed = bridge_time.parse_batch(payload, "UTC")
rendered = bridge_time.format_batch(payload, "YYYY-MM-DD HH:mm", "UTC")
print(len(parsed), rendered[:2])