Skip to content

Instantly share code, notes, and snippets.

@TheArmagan
Last active June 4, 2021 16:43
Show Gist options
  • Save TheArmagan/df9d8141e0133b9ad790e07d126cb389 to your computer and use it in GitHub Desktop.
Save TheArmagan/df9d8141e0133b9ad790e07d126cb389 to your computer and use it in GitHub Desktop.
Timezone DB - API Documentation

Timezone DB - API Documentation

BASE URL: https://timezonedb.armagan.rest/

Get only one user's info.

GET /api/get/timezone

Query Parameters:

  • id: The target user's platform id. (Example: 707309693449535599, Default: none)
Success response.
{
  "ok": true,
  "data": {
    "id": "707309693449535599",
    "timezone": "Europe/Istanbul"
  }
}
Error response.
{
  "ok": false,
  "error": "Invalid 'id' query."
}

Get multiple users info.

URL: POST /api/get/timezoneS

JSON Body Fields:

  • ids: Array of platform ids. (Example: ["707309693449535599","844247293762338821"], Default: none)
Success response.
{
  "ok": true,
  "data": [
    {
      "id": "707309693449535599",
      "timezone": "Europe/Istanbul"
    },
    {
      "id": "844247293762338821",
      "timezone": "Australia/Sydney"
    }
  ]
}
Error response.
{
  "ok": false,
  "error": "ValidationError: ids field must have at least 1 items"
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment