codescalersinternships / home

home repo for internships
4 stars 0 forks source link

Datetime HTTP Client - RawanMostafa #288

Open RawanMostafa08 opened 2 months ago

RawanMostafa08 commented 2 months ago

Develop and Test HTTP Client for Datetime Server #144

Description: Create an HTTP client in Go that consumes the datetime server APIs implemented in the previous project #144 . This client will focus on building an HTTP client development and testing.

Requirements:

  1. [x] Client Functionality:

    • [x] Implement functions to call each datetime server endpoint
    • [x] Handle different response formats (JSON, plain text)
    • [x] Implement proper error handling and timeouts
  2. [x] Configuration:

    • [x] Allow configuration of server URLs and ports
    • [x] Support for environment variable configuration
  3. [x] Retry Mechanism:

  4. [x] Testing:

    • [x] Unit tests for client functions
    • [x] Integration tests using a mock server
  5. [x] Documentation:

    • [x] Provide godoc-style comments for all exported functions
    • [x] Include usage examples in the README
  6. [x] Logging:

    • [x] Implement structured logging for client operations

Optional Enhancements:

Acceptance Criteria:

After this one You can develop the one for pokeapi