-
Notifications
You must be signed in to change notification settings - Fork 0
/
config.js
32 lines (28 loc) · 1.12 KB
/
config.js
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
module.exports = {
loginCred:{
EMAIL: process.env.EMAIL,
PASSWORD: process.env.PASSWORD
},
siteInfo: {
COUNTRY_CODE: process.env.COUNTRY_CODE || 'en-ca',
SCHEDULE_ID: process.env.SCHEDULE_ID,
FACILITY_ID: process.env.FACILITY_ID,
get APPOINTMENTS_JSON_URLS(){
const facilites = this.FACILITY_ID.split(',');
return facilites.map(facilityId => (
`https://ais.usvisa-info.com/${this.COUNTRY_CODE}/niv/schedule/${this.SCHEDULE_ID}/appointment/days/${facilityId}.json?appointments%5Bexpedite%5D=false`
));
},
get LOGIN_URL () {
return `https://ais.usvisa-info.com/${this.COUNTRY_CODE}/niv/users/sign_in`
}
},
IS_PROD: process.env.NODE_ENV === 'prod',
NEXT_SCHEDULE_POLL: process.env.NEXT_SCHEDULE_POLL || 30_000, // default to 30 seconds
MAX_NUMBER_OF_POLL: process.env.MAX_NUMBER_OF_POLL || 250, // number of polls before stopping
NOTIFY_ON_DATE_BEFORE: process.env.NOTIFY_ON_DATE_BEFORE, // in ISO format i.e YYYY-MM-DD
NOTIFY_EMAILS: process.env.NOTIFY_EMAILS, // comma separated list of emails
sendGrid: {
API_KEY: process.env.SENDGRID_API_KEY,
}
}