edrmvs

module
v0.1.36 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 16, 2022 License: MIT

README

edrmvs

Tool for extracting infromation from government resources

Development

Build the binary

make

Start postgres

docker-compose up -Vd postgres

Run sql migrations

migrate -source file://migrations -database postgres://postgres:password@127.0.0.1/edrmvs\?sslmode=disable up

Run the web server

./bin/server

Test

Start postgres

docker-compose up -Vd postgres

Run sql migrations

migrate -source file://migrations -database postgres://postgres:password@127.0.0.1/edrmvs\?sslmode=disable up

Run tests

go test -v ./...

Usage

For example, you get information about this amazing Tesla Model X

http http://localhost:8080/api/v1/registrations/СХН484154
{
    "brand": "TESLA",
    "code": "CXH484154",
    "color": "ЧОРНИЙ",
    "date": "2019-06-05",
    "first_reg_date": "2016-10-13",
    "fuel": "ЕЛЕКТРО",
    "kind": "ЛЕГКОВИЙ УНІВЕРСАЛ-B",
    "model": "MODEL X",
    "num_seating": 7,
    "number": "AA9359PC",
    "own_weight": 2485,
    "rank_category": "B",
    "total_weight": 3021,
    "vin": "5YJXCCE40GF010543",
    "year": 2016
}

License

Project released under the terms of the MIT license.

Directories

Path Synopsis
cmd
pkg
domain/mocks
Package mocks is a generated GoMock package.
Package mocks is a generated GoMock package.
hsc
store/mockstore
Package mockstore is a generated GoMock package.
Package mockstore is a generated GoMock package.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL