forked from birkhofflee/AnonyPages
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathconfig.sample.js
More file actions
231 lines (200 loc) · 5.1 KB
/
Copy pathconfig.sample.js
File metadata and controls
231 lines (200 loc) · 5.1 KB
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
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
// # AnonyPages Configuration
var path = require('path'),
config;
config = {
/**
* Version
* @type {String}
*/
version: "v0.0.1",
/**
* Facebook pages configuration
* Support multiple pages
*
* @type {Object}
*/
pages: {
/*
The page ID of the page.
*/
{PAGE_ID_HERE!}: {
/**
* The name of this page site
* @type {String}
*/
siteName: "靠北 XXX",
/**
* The name of the page
* Must be the real page name
* WILL BE DEPRECATED
*
* @type {String}
*/
pageName: "靠北XXX",
/**
* The hashtag of each posts
* If you change this, the hashtag
* count will reset to 1
*
* @type {String}
*/
hashtag: "#靠北XXX",
/**
* The facebook URL of the facebook page
* @type {String}
*/
pageUrl: "",
/**
* The text at the end of each posts
* @type {String}
*/
afterPost: "",
/**
* The label text above the post field
* @type {String}
*/
postLabel: "",
/**
* The placeholder of the post field
* @type {String}
*/
postPlaceholder: "",
/**
* Terms Of Service
* Use "\n" for newline
*
* @type {String}
*/
terms: "",
/**
* Page Access Token
* @type {String}
*/
access_token: "",
/**
* Rendering options
* @type {Object}
*/
option: {
/**
* Auto resize the ToS textarea?
* Recommended value: false
*
* @type {Boolean}
*/
autoResizeTerms: false,
/**
* The default "rows" value of the terms textarea
* @type {Number}
*/
TermsDefaultRows: 15
}
}
},
facebook: {
/*
Attention: The app MUST be general public or
other visitors can't see the posts. Fill the
contact mail field in the Settings page of
your facebook app. And go to Status & Review
to make the app general public.
*/
/**
* Facebook App ID
* @type {String}
*/
app_id: "",
/**
* Facebook App Secret.
* DO NOT make this known by anyone else.
*
* @type {String}
*/
app_secret: "",
/**
* The Graph API URL to get feed
* @type {String}
*/
getFeedURL: "https://graph.facebook.com/{pageID}/posts?access_token={accessToken}",
/**
* The Graph API URL to post article
* @type {String}
*/
postArticleURL: "https://graph.facebook.com/v2.5/{pageID}/feed",
/**
* The Graph API Doc URL of error explanations
* @type {String}
*/
graphAPIerrorRef: "https://developers.facebook.com/docs/graph-api/using-graph-api/v2.5#errors",
/**
* The Facebook URL of the post
* @type {String}
*/
postURL: "https://www.facebook.com/{page_id}/posts/{postID}",
/**
* The Facebook URL of the hashtag (including the post's id)
* @type {String}
*/
hashtagURL: "https://www.facebook.com/hashtag/{hashtag}?story_id={postID}"
},
/**
* Recaptcha is required
* @type {Object}
*/
googleRecaptcha: {
/*
Google Recaptcha Site Key for this site.
*/
gRsitekey: "",
/*
Google Recaptcha Secret Key for this site.
Do not make this known by untrusted people.
*/
gRsecret: "",
/*
The URL to verify g-recaptcha-response
*/
verifyURL: "https://www.google.com/recaptcha/api/siteverify"
},
/*
Web Server settings
*/
server: {
/**
* Host
* @type {String}
*/
host: '127.0.0.1',
/**
* Web Server port
* @type {String}
*/
port: 1020
},
/**
* Notify you when a new article was posted.
* Use this feature on /notification
*
* @type {Object}
*/
notification: {
/**
* Enabled or not.
* @type {Boolean}
*/
enabled: true,
/**
* The delay between the checkings in milliseconds.
* @type {Number}
*/
update_timeout: 5000
},
/**
* The lang we are using
* Check the available languages in /lang
*
* @type {String}
*/
lang: "en-US"
};
module.exports = config;