summaryrefslogtreecommitdiffstats
path: root/internal/models/reddit.go
blob: bfe4172cc485babd6e82777144e8036d1bce5dba (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
package models

type RedditSubredditParams struct {
	Subreddit string `json:"subreddit"`
}

type RedditUserParams struct {
	Username string `json:"username"`
}

type RedditCredits struct {
	Remaining int  `json:"remaining"`
	Unlimited bool `json:"unlimited"`
}

type SubredditResponse struct {
	Subreddit string        `json:"subreddit"`
	Type      string        `json:"type"`
	Results   interface{}   `json:"results"`
	Credits   RedditCredits `json:"credits"`
	Error     string        `json:"error,omitempty"`
}

type UserResponse struct {
	Username string        `json:"username"`
	Type     string        `json:"type"`
	Results  interface{}   `json:"results"`
	Credits  RedditCredits `json:"credits"`
	Error    string        `json:"error,omitempty"`
}