geni_api_v1/
lib.rs

1use serde::Deserialize;
2use std::collections::HashMap;
3
4#[derive(PartialEq, Debug, Deserialize)]
5pub struct Name {
6    pub first_name: String,
7    pub middle_name: Option<String>,
8    pub last_name: String,
9    pub display_name: String,
10}
11
12#[derive(PartialEq, Debug, Deserialize)]
13pub struct Profile {
14    pub id: String,
15    pub profile_url: String,
16    pub public: bool,
17    pub guid: String,
18    pub first_name: String,
19    pub middle_name: String,
20    pub last_name: String,
21    pub display_name: String,
22    pub name: String,
23    pub account_type: String,
24    pub deleted: bool,
25    pub is_curator: bool,
26    pub names: HashMap<String, Name>,
27}
28
29#[derive(PartialEq, Debug, Deserialize)]
30pub struct Location {
31    pub city: String,
32    pub state: String,
33    pub country: String,
34    pub country_code: String,
35    pub latitude: f64,
36    pub longitude: f64,
37    pub formatted_location: String,
38}
39
40#[derive(PartialEq, Debug, Deserialize)]
41pub struct Document {
42    pub id: String,
43    pub guid: String,
44    pub created_at: String,
45    pub updated_at: String,
46    pub content_type: String,
47    pub public: bool,
48    pub url: String,
49    pub title: String,
50    pub description: String,
51    pub location: Location,
52}