unsplash_api/objects/
pagination.rs

1//! https://unsplash.com/documentation#pagination-headers
2
3use serde::{Deserialize, Serialize};
4
5pub const RESPONSE_HEADER_KEY_TOTAL: &str = "x-total";
6pub const RESPONSE_HEADER_KEY_PER_PAGE: &str = "x-per-page";
7
8#[derive(Deserialize, Serialize, Debug, Copy, Clone)]
9pub struct Pagination {
10    pub total: Option<usize>,
11    pub per_page: Option<usize>,
12}
13
14pub const MAX_PER_PAGE: usize = 30;