> For the complete documentation index, see [llms.txt](https://docs.dckapintegrator.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.dckapintegrator.com/developers/flows/timezone-converter-handler.md).

# Timezone Converter Handler

This  handler serves two purposes:&#x20;

1. Converts Date & Time (object/string) from one time zone to another timezone.&#x20;
2. Generates a timestamp for a given Date & Time (object/string).

The three options available in this Handler are explained in detail below:

## 1. Timezone Converter

The Timezone Converter converts a date-time input in a particular timezone to any selected timezone. The following tables list down the steps to configure the Timezone Converter Handler for two types of Output:  <br>

| **Output** | **Datetime Object Output**                                                                                                                                                                                                                                                                                                                                                                                                                                                  |
| ---------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Input      | <p><strong>(i) For String Input:</strong></p><p>Select String under the “Enter Date Time” field and give your input.</p><p>Enter Input Date Format for String Input (Refer to the table below).</p><p>Choose From Timezone and To Timezone from the drop-down list.</p><p><strong>(ii) For date-time input:</strong></p><p>Select Non-String under the “Enter Date Time” field and give your input.</p><p>Choose From Timezone and To Timezone from the drop-down list.</p> |

| Output | **2. String Output**                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               |
| ------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| Input  | <p><strong>(i) For String Input:</strong></p><p>Select String under the “Enter Date Time” field and give your input.</p><p>Enter Input Date Format for String Input by referring to the table below.</p><p>Enter Output Date Format for String Output by referring to the table below.</p><p>Choose From Timezone and To Timezone from the drop-down list.</p><p><strong>(ii) For date-time input:</strong></p><p>Select Non-String under the “Enter Date Time” field and give your input.</p><p>Choose From Timezone and To Timezone from the drop-down list.</p> |

## 2. Timestamp Generator

Generate timestamps from a date inputted previously (MM/DD/YYYY) to the entered Date and Time.&#x20;

**(i) For String Input**

* Select String under the “Enter Date Time” field and give your input
* Enter Input Date Format for String Input by referring to the table below
* Choose the input time zone from the drop-down in the “From timezone” field.

**(ii) For date-time input:**

* Select Non-String  under the “Enter Date Time” field and give your input.
* Choose the input time zone from the drop-down in the “From timezone” field.
* Consider this date for example, Saturday, 27 January 2018, 10:30:00.012345 AM +0530

The following formats are supporte&#x64;**:**

| Format | Value    | Description                                |
| ------ | -------- | ------------------------------------------ |
| %d     | 27       | numerical representation of day            |
| %a     | Sat      | short alphabetical representation of day   |
| %A     | Saturday | alphabetical representation of day         |
| %m     | 01       | numerical representation of month          |
| %b     | Jan      | short alphabetical representation of month |
| %B     | January  | alphabetical representation of month       |
| %y     | 18       | short representation of year               |
| %Y     | 2018     | numerical representation of year           |
| %H     | 10       | hour                                       |
| %M     | 30       | minute                                     |
| %f     | 012345   | microseconds                               |
| %p     | AM       | meridiem                                   |
| %z     | +0530    | timezone offset                            |

**Examples for reference**

| Input                           | Format                   |
| ------------------------------- | ------------------------ |
| 2021-05-27 01:30:00 PM          | %Y-%m-%d %H:%M:%S %p     |
| 2021-05-12T09:46:47-0400        | %Y-%m-%dT%H:%M:%S%z      |
| Sat, 27 Jan 2018 17:16:55 +0000 | %a, %d %b %Y %H:%M:%S %z |
| 2018-01-27T13:34:25.518993+0530 | %Y-%m-%dT%H:%M:%S.%f%z   |

## Modifier: Datetime to Timestamp Modifier

This Modifier is used to provide the timestamp starting from \<MM/DD/YYYY> to a given Date & Time input.&#x20;

* Give the input as a string&#x20;
* In the Parameters field, pass the string format using the table&#x20;
* Provide the timezone of the user input

The supported timezone parameters are listed [here: Supported Timezones](/developers/flows/supported-timezones.md)<br>


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.dckapintegrator.com/developers/flows/timezone-converter-handler.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
