Giter Site home page Giter Site logo

upmob-api's Introduction

upcoming_mobiles_api (UpMob API)

UpMob API scraps 91mobiles.com to get devices information which are yet to be released in the Indian market and stores it in a postgres db

API

Fetch all upcoming devices

  • URL

    /devices/top100

  • Method

    GET

  • URL Params

    None

  • Success Response:

    • Code: 200
      Content:
[
  {
        "device_name": "OnePlus 8T Pro",
        "last_updated": "Updated on: Jul 26, 2021",
        "expected": "August 7, 2021 (Unofficial)",
        "price": 57999,
        "img_url": "https://www.91-img.com/pictures/139350-v1-oneplus-8t-pro-mobile-phone-large-1.jpg?tr=q-60",
        "source_url": "https://www.91mobiles.com/oneplus-8t-pro-price-in-india",
        "spec_score": 0,
        "ram": {
            "String": "8 GB",
            "Valid": true
        },
        "processor": {
            "String": "Qualcomm Snapdragon 865 Plus",
            "Valid": true
        },
        "front_camera": {
            "String": "16 MP",
            "Valid": true
        },
        "rear_camera": {
            "String": "64 MP + 48 MP + 8 MP + 5 MP",
            "Valid": true
        },
        "battery": {
            "String": "4850 mAh",
            "Valid": true
        },
        "display": {
            "String": "6.78 inches",
            "Valid": true
        },
        "operating_system": {
            "String": "Android v10 (Q)",
            "Valid": true
        },
        "custom_ui": {
            "String": "Oxygen OS",
            "Valid": true
        },
        "chipset": {
            "String": "Qualcomm Snapdragon 865 Plus",
            "Valid": true
        },
        "cpu": {
            "String": "Octa core (3.09 GHz, Single core, Kryo 585 + 2.42 GHz, Tri core, Kryo 585 + 1.8 GHz, Quad core, Kryo 585)",
            "Valid": true
        },
        "architecture": {
            "String": "64 bit",
            "Valid": true
        },
        "graphics": {
            "String": "Adreno 650",
            "Valid": true
        },
        "display_type": {
            "String": "Fluid AMOLED",
            "Valid": true
        },
        "screen_size": {
            "String": "6.78 inches (17.22 cm)",
            "Valid": true
        },
        "resolution": {
            "String": "1440 x 3168 pixels",
            "Valid": true
        },
        "pixel_density": {
            "String": "513 ppi",
            "Valid": true
        },
        "touchscreen": {
            "String": "Yes, Capacitive Touchscreen, Multi-touch",
            "Valid": true
        },
        "internal_memory": {
            "String": "256 GB",
            "Valid": true
        },
        "expandable_memory": {
            "String": "No",
            "Valid": true
        },
        "m_camera_setup": {
            "String": "Quad",
            "Valid": true
        },
        "m_resolution": {
            "String": "64 MP Primary Camera48 MP, Wide Angle, Ultra-Wide Angle Camera8 MP Telephoto Camera5 MP Camera",
            "Valid": true
        },
        "m_autofocus": {
            "String": "Yes, Phase Detection autofocus",
            "Valid": true
        },
        "m_ois": {
            "String": "Yes",
            "Valid": true
        },
        "m_sensors": {
            "String": "",
            "Valid": false
        },
        "m_flash": {
            "String": "Yes, LED Flash",
            "Valid": true
        },
        "m_image_resolution": {
            "String": "",
            "Valid": false
        },
        "m_settings": {
            "String": "Exposure compensation, ISO control",
            "Valid": true
        },
        "m_shooting_modes": {
            "String": "Continuos ShootingHigh Dynamic Range mode (HDR)",
            "Valid": true
        },
        "m_camera_features": {
            "String": "Digital ZoomAuto FlashFace detectionTouch to focus",
            "Valid": true
        },
        "m_video_recording": {
            "String": "",
            "Valid": false
        },
        "s_camera_setup": {
            "String": "Single",
            "Valid": true
        },
        "s_resolution": {
            "String": "16 MP Primary Camera",
            "Valid": true
        },
        "s_video_recording": {
            "String": "",
            "Valid": false
        },
        "capacity": {
            "String": "4850 mAh",
            "Valid": true
        },
        "removable_battery": {
            "String": "No",
            "Valid": true
        },
        "wireless_charging": {
            "String": "",
            "Valid": false
        },
        "quick_charging": {
            "String": "Yes, Fast",
            "Valid": true
        },
        "usb": {
            "String": "Yes",
            "Valid": true
        },
        "sim_slots": {
            "String": "Dual SIM, GSM+GSM",
            "Valid": true
        },
        "network_support": {
            "String": "5G supported by device (network not rolled-out in India), 4G (supports Indian bands), 3G, 2G",
            "Valid": true
        },
        "fingerprint_sensor": {
            "String": "Yes",
            "Valid": true
        },
        "other_sensors": {
            "String": "Light sensor, Proximity sensor, Accelerometer, Compass, Gyroscope",
            "Valid": true
        },
        "scrape_timestamp": "2021-07-25T21:33:31.655995Z"
    }, ... ]

Get Started with the Installation

  1. Required Installations
    1. Install GoLang in your system
    2. Install Docker in your system
    3. Install Golang Migrate Tool
    4. Make sure you have make tool installed.
  2. Navigate into the project directory
  3. Run
       go mod download
       make postgres
       make createdb
       make migrateup 
    This sets up and runs your postgres container, creates db in it and migrates database.
  4. Run
        make server
    This runs main.go and you are good to Go ๐Ÿ˜‰

Development and Contributing

Yes, please! Feel free to contribute, raise issues and recommend best practices. Makefile is your friend.

A few resources:

upmob-api's People

Contributors

20gurpreet01 avatar gurpreetsingh2001 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.