19 releases (7 breaking)

0.8.7 Apr 2, 2024
0.8.6 Sep 5, 2023
0.8.3 Aug 29, 2023
0.4.0 Jul 27, 2023

#250 in Database interfaces

Download history 5/week @ 2024-02-26 6/week @ 2024-03-11 177/week @ 2024-04-01 3/week @ 2024-04-08 167/week @ 2024-04-15

347 downloads per month

MIT license

1MB
22K SLoC

SQL 20K SLoC // 0.0% comments Rust 1.5K SLoC // 0.1% comments

Vinted-rs: A Vinted API wrapper

githubcrates-iodocs-rs

Table of Contents

Installation

Via cargo you can add the library to your project's Cargo.toml

[dependencies]
vinted-rs = "0.8.7"

DB setup

Advanced filtering features must require this setup before running.

  • First start installing diesel-cli (in order to run the migrations in PostgreSQL database)

⚠️Very important: diesel-cli installation may fail if you do not have libpq library installed.

To install libpq, just install PostgreSQL package on your machine.

In Arch based is only necessary to install this package.

sudo pacman -S postgresql-libs

In Debian based distributions is only necessary to install this package.

sudo apt install libpq-dev
cargo install diesel_cli --features=postgres --no-default-features

Create a migration

mkdir migrations
diesel migration generate my_migration

Program after that up.sql and down.sql scripts.

Run a Docker container with PostgreSQL

make db

Run migrations

make diesel

Stop DB

make stop

Running Tests

⚠️Very important: Before running tests is important to do the DB setup

Then run the tests

cargo test

Dependencies

~15–31MB
~525K SLoC