aboutsummaryrefslogtreecommitdiff
path: root/lib/models/channel/message/attachment.ml
blob: 696df60c2cb2ce4d2a91e1221b39dedbdaf3f58e (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
let string_of_sexp = Base.String.t_of_sexp
let sexp_of_string = Base.String.sexp_of_t
let int_of_sexp    = Base.Int.t_of_sexp
let sexp_of_int    = Base.Int.sexp_of_t

type t = {
    id: Snowflake.t;
    filename: string;
    size: int;
    url: string;
    proxy_url: string;
    height: int [@default -1];
    width: int [@default -1];
} [@@deriving sexp, yojson { strict = false; exn = true }]