add serde to Address
This commit is contained in:
parent
2b8a7278cc
commit
9373019f87
1
nominatimapi/Cargo.lock
generated
1
nominatimapi/Cargo.lock
generated
@ -595,6 +595,7 @@ name = "nominatimapi"
|
||||
version = "0.1.0"
|
||||
dependencies = [
|
||||
"reqwest",
|
||||
"serde",
|
||||
"serde_json",
|
||||
"tokio",
|
||||
]
|
||||
|
||||
@ -5,5 +5,6 @@ edition = "2021"
|
||||
|
||||
[dependencies]
|
||||
reqwest = { version = "0.12.4", features = ["json"] }
|
||||
serde = {version="1.0.201", features=["derive"]}
|
||||
serde_json = "1.0.116"
|
||||
tokio = { version = "^1", features = ["full"] }
|
||||
|
||||
@ -2,7 +2,9 @@ use reqwest;
|
||||
use serde_json;
|
||||
use std::error::Error;
|
||||
use reqwest::header::USER_AGENT;
|
||||
use serde::{Serialize, Deserialize};
|
||||
|
||||
#[derive(Serialize, Deserialize)]
|
||||
pub struct Address {
|
||||
pub street: String,
|
||||
pub city: String,
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user