VEMO is a project to be developed in Swift for iOS devices. The project aims to automate the search for car information for people who are interested, the point is that the application will be connected to a common database which contains information about many cars.
The user by entering the car number, get full information about the model of the car, year of manufacture, and general information, etc.
- The app is available on the new version of Xcode and iOS 16.0
- Ability to register and login using Firebase
- Ability to search for vehicle information using the VIN and auto.dev API
- Comfortable UI/UX Design
- Open to all devices
- API Request
let baseURL = "https://auto.dev/api/vin"
func getRequest(for vinCode: String, completion: @escaping ((Vehicle) -> ())) {
if let url = URL (string: (baseURL + "/\(vinCode)" + ("?apikey=YOURAPIKEY"))) {
let authtoken = "YOUR AUTH TOKEN"
var request = URLRequest(url: url)
request.addValue("application/json", forHTTPHeaderField: "content-type")
request.addValue("Bearer \(authtoken)", forHTTPHeaderField: "authorization")
request.httpMethod = "GET"
URLSession.shared.dataTask(with: request) { (data, response , error) in
guard let data = data else { return }
if let model = try? JSONDecoder().decode(Vehicle.self, from: data) {
print(model)
completion(model)
} else {
print("Error")
}
}
.resume()
}
}
- Vehicle Info
struct Vehicle: Decodable {
let make: VehicleMake?
let model: VehicleModel?
let transmission: VehicleTransmission?
let price: VehiclePrice?
let years: [VehicleYears]?
}
struct VehicleMake: Decodable {
let id: Int?
let name: String?
let niceName: String?
}
struct VehicleModel: Decodable {
let id: String?
let name: String?
let niceName: String?
}
struct VehicleTransmission: Decodable {
let numberOfSpeeds: String?
let availability: String?
let transmissionType: String?
let automaticType: String?
}
struct VehiclePrice: Decodable {
let baseMsrp: Int?
let deliveryCharges: Int?
let estimateTmv: Bool?
}
struct VehicleYears: Decodable {
let id: Int?
let year: Int?
}
- Xcode 13+ with an iOS 13.0+ simulator
- Firebase CocoaPods
- auto.dev API
- Clone the repo:
git clone https://github.com/manste1n/vemo_project_ios
- Register your Firebase Project by instructions in official page
Thx for attention :3
You can support me by following :>